Safety check. The main place this can be a problem is on a mild bowl w/ multiple hogs. Could possibly add a hog collision check in here.
authornemo
Thu, 28 Feb 2013 22:10:49 -0500
changeset 8616 c4536e98c712
parent 8615 a4cb6168016e
child 8617 e7bea88096d2
Safety check. The main place this can be a problem is on a mild bowl w/ multiple hogs. Could possibly add a hog collision check in here.
hedgewars/uGearsHedgehog.pas
--- a/hedgewars/uGearsHedgehog.pas	Fri Mar 01 01:05:43 2013 +0100
+++ b/hedgewars/uGearsHedgehog.pas	Thu Feb 28 22:10:49 2013 -0500
@@ -1219,7 +1219,7 @@
 begin
     if (Gear^.Message and (gmAllStoppable or gmLJump or gmHJump) = 0)
     and (Gear^.State and (gstHHJumping or gstHHHJump or gstAttacking) = 0)
-    and (not Gear^.dY.isNegative) and (TestCollisionYwithGear(Gear, 1) and lfIce <> 0) then
+    and (not Gear^.dY.isNegative) and (TurnTimeLeft > 0) and (TestCollisionYwithGear(Gear, 1) and lfIce <> 0) then
         begin
         slope:= CalcSlopeBelowGear(Gear);
         if slope.QWordValue > 730144440 then // ignore mild slopes