--- a/hedgewars/GSHandlers.inc Tue Aug 09 21:54:45 2011 -0400
+++ b/hedgewars/GSHandlers.inc Wed Aug 10 11:45:02 2011 -0400
@@ -2952,11 +2952,14 @@
begin
for i:= 0 to High(hogs) do
begin
- //d:= Distance(Gear^.X - hogs[i]^.X, Gear^.Y - hogs[i]^.Y);
- hogs[i]^.dX:= _0_25 * (Gear^.X - hogs[i]^.X) / _250;
- //if Gear^.X < hogs[i]^.X then hogs[i]^.dX.isNegative:= true;
- hogs[i]^.dY:= -_0_25;
- hogs[i]^.Active:= true;
+ if hogs[i] <> CurrentHedgehog^.Gear then
+ begin
+ //d:= Distance(Gear^.X - hogs[i]^.X, Gear^.Y - hogs[i]^.Y);
+ hogs[i]^.dX:= _0_25 * (Gear^.X - hogs[i]^.X) / _250;
+ //if Gear^.X < hogs[i]^.X then hogs[i]^.dX.isNegative:= true;
+ hogs[i]^.dY:= -_0_25;
+ hogs[i]^.Active:= true;
+ end
end;
end ;
AfterAttack;