--- a/hedgewars/VGSHandlers.inc Sun Oct 24 22:00:36 2010 +0200
+++ b/hedgewars/VGSHandlers.inc Mon Oct 25 17:39:50 2010 +0200
@@ -516,12 +516,16 @@
inc(Gear^.Timer, Steps );
if Gear^.Timer > 64 then
begin
+ if Gear^.State = 0 then
+ begin
+ DeleteVisualGear(Gear);
+ exit;
+ end;
dec(Gear^.State, Gear^.Timer div 65);
Gear^.Timer:= Gear^.Timer mod 65;
end;
Gear^.dX:= Gear^.dX + cWindSpeedf * Steps;
Gear^.X:= Gear^.X + Gear^.dX;
-if Gear^.State = 0 then DeleteVisualGear(Gear);
end;
////////////////////////////////////////////////////////////////////////////////