hedgewars/GSHandlers.inc
changeset 100 f324a18698fe
parent 95 1ef5e2c41115
child 107 b08ce0293a51
--- a/hedgewars/GSHandlers.inc	Sun Aug 06 17:11:33 2006 +0000
+++ b/hedgewars/GSHandlers.inc	Sun Aug 06 20:08:15 2006 +0000
@@ -459,7 +459,7 @@
 
 if not TestCollisionYwithGear(HHGear, 1) then HHGear.dY:= HHGear.dY + cGravity;
 
-HHGear.DirAngle:= arctan(Gear.dY + HHGear.dY, Gear.dX + HHGear.dX);
+HHGear.DirAngle:= arctan2(Gear.dY + HHGear.dY, Gear.dX + HHGear.dX);
 cs:= sin(HHGear.DirAngle);
 cc:= cos(HHGear.DirAngle);
 
@@ -509,7 +509,7 @@
 
 Gear.dX:= HHGear.X - Gear.X;
 Gear.dY:= HHGear.Y - Gear.Y;
-HHGear.DirAngle:= arctan(Gear.dY + HHGear.dY, Gear.dX + HHGear.dX);
+HHGear.DirAngle:= arctan2(Gear.dY + HHGear.dY, Gear.dX + HHGear.dX);
 cs:= sin(HHGear.DirAngle);
 cc:= cos(HHGear.DirAngle);