todo and veloc fix
This commit is contained in:
1 parent
1c305bb677
commit
56ed2a4e89
2 files changed
+6
-2
No files matched your search
@@ -78,6 +78,10 @@ public class ShipControls : MonoBehaviour {
|
||||
// this is relative because it's easy to just multiply by the strafe vector
|
||||
rigidBody.AddRelativeForce(strafe, forceMode);
|
||||
|
||||
// little check to stop the ship bouncing between forward and back when holding decel
|
||||
if (rigidBody.velocity.magnitude < 0.2)
|
||||
rigidBody.velocity = Vector3.zero;
|
||||
|
||||
// rotating towards the camera's orientation
|
||||
// not being done by a force because of strange behaviour
|
||||
// needs investigation
|
||||
|
||||
Reference in new issue
Block a user