Issue #581
authornemo
Mon, 07 Oct 2013 21:31:28 -0400
changeset 9497 1813b682c6bd
parent 9495 2fc346fadae3
child 9499 bbc093acb91e
issue #581
hedgewars/uGears.pas
--- a/hedgewars/uGears.pas	Mon Oct 07 23:36:40 2013 +0400
+++ b/hedgewars/uGears.pas	Mon Oct 07 21:31:28 2013 -0400
@@ -401,7 +401,8 @@
             if (CurrentHedgehog^.Gear <> nil) and (CurrentHedgehog^.Gear^.State and gstAttacked = 0)
             and (CurAmmoGear = nil) then
                 SweepDirty;
-            CheckNoDamage;
+            if (CurrentHedgehog^.Gear = nil) or (CurrentHedgehog^.Gear^.State and gstHHDriven = 0) or (CurrentHedgehog^.Gear^.Damage = 0) then
+                CheckNoDamage;
             AliveCount:= 0; // shorter version of check for win to allow typical step activity to proceed
             for i:= 0 to Pred(ClansCount) do
                 if ClansArray[i]^.ClanHealth > 0 then