# HG changeset patch # User nemo # Date 1312991102 14400 # Node ID cf32b5928cbe58ab0741b02a7cc1b3511599ca52 # Parent 52f4a5d9a222509648cbe801318af18fbe752c59 exclude current hedgehog diff -r 52f4a5d9a222 -r cf32b5928cbe hedgewars/GSHandlers.inc --- 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;