Smaxx: only allow change direction when shift key is pressed
authorunc0rr
Sun, 25 Oct 2009 12:41:48 +0000
changeset 2585 0899ce8ad77f
parent 2584 cc049fbb65ef
child 2586 204e6b2885bc
Smaxx: only allow change direction when shift key is pressed
hedgewars/HHHandlers.inc
--- a/hedgewars/HHHandlers.inc	Sun Oct 25 12:40:47 2009 +0000
+++ b/hedgewars/HHHandlers.inc	Sun Oct 25 12:41:48 2009 +0000
@@ -431,7 +431,9 @@
          or TestCollisionYwithGear(Gear, -1)) then Gear^.Y:= Gear^.Y - _1;
       end;
 
-   if (not cArtillery) and (not TestCollisionXwithGear(Gear, hwSign(Gear^.dX))) then Gear^.X:= Gear^.X + SignAs(_1, Gear^.dX);
+   if (not cArtillery) and ((Gear^.Message and gm_Precise) = 0) and (not TestCollisionXwithGear(Gear, hwSign(Gear^.dX))) then
+      Gear^.X:= Gear^.X + SignAs(_1, Gear^.dX);
+
    SetAllHHToActive;
 
    if not TestCollisionYwithGear(Gear, 1) then
@@ -773,4 +775,4 @@
 		if Team^.hasGone then TeamGoneEffect(Team^);
 	doStepHedgehogDriven(Gear)
 	end;
-end;
\ No newline at end of file
+end;