Sfoglia il codice sorgente

more rotation friction

Darren Ranalli 20 anni fa
parent
commit
f882f5a715
1 ha cambiato i file con 7 aggiunte e 1 eliminazioni
  1. 7 1
      direct/src/controls/ShipPilot.py

+ 7 - 1
direct/src/controls/ShipPilot.py

@@ -662,7 +662,13 @@ class ShipPilot(PhysicsWalker.PhysicsWalker):
             self.currentTurning = self.ship.maxTurn
         elif self.currentTurning < -self.ship.maxTurn:
             self.currentTurning = -self.ship.maxTurn
-        self.currentTurning *= 0.9
+        if turnLeft or turnRight:
+            mult = .9
+        elif forward or reverse:
+            mult = .82
+        else:
+            mult = .8
+        self.currentTurning *= mult
         self.__rotationSpeed = self.currentTurning