feat: more attempted fixes for models and animations
This commit is contained in:
@@ -83,7 +83,7 @@ namespace Reset.Units{
|
||||
|
||||
// Tell every unit to set the new health value
|
||||
if (UnitIsNetworked()) {
|
||||
SetHealthRpc(newHealth);
|
||||
SetHealthRpc(newHealth);
|
||||
} else {
|
||||
SetHealth(newHealth);
|
||||
}
|
||||
|
||||
@@ -204,7 +204,16 @@ namespace Reset.Units{
|
||||
|
||||
// Construct the direction and move
|
||||
Vector3 finalDir = new Vector3(moveXZDir.x, moveYDir, moveXZDir.y);
|
||||
controller.Move(finalDir);
|
||||
|
||||
Vector3 rootDir = GetComponent<Animator>().deltaPosition * 5f;
|
||||
SetNewSpeed(10f, 1, true);
|
||||
|
||||
Debug.Log(rootDir);
|
||||
// controller.Move(finalDir + rootDir);
|
||||
|
||||
rootDir = Quaternion.AngleAxis(90f, Vector3.left) * rootDir;
|
||||
|
||||
// controller.Move(rootDir * 1f);
|
||||
}
|
||||
|
||||
// Setting absolute to true will cause the current gravity to snap to the new gravity value.
|
||||
|
||||
Reference in New Issue
Block a user