diff -r f682e134ac2e -r ba560c17c24c hedgewars/GSHandlers.inc --- a/hedgewars/GSHandlers.inc Mon May 21 15:42:21 2007 +0000 +++ b/hedgewars/GSHandlers.inc Mon May 21 18:07:25 2007 +0000 @@ -643,6 +643,7 @@ Gear^.Y:= Gear^.Y - Gear^.dY; Gear^.Elasticity:= Gear^.Elasticity + _1; HHGear:= PHedgehog(Gear^.Hedgehog)^.Gear; +DeleteCI(HHGear); if (HHGear^.State and gstFalling) <> 0 then if TestCollisionYwithGear(HHGear, 1) then begin @@ -662,8 +663,8 @@ ty:= _0; while tt > _20 do begin - if TestCollisionXwithXYShift(Gear, tx, hwRound(ty), hwSign(Gear^.dX)) - or TestCollisionYwithXYShift(Gear, hwRound(tx), hwRound(ty), hwSign(Gear^.dY)) then + if TestCollisionXwithXYShift(Gear, tx, hwRound(ty), -hwSign(Gear^.dX)) + or TestCollisionYwithXYShift(Gear, hwRound(tx), hwRound(ty), -hwSign(Gear^.dY)) then begin Gear^.X:= Gear^.X + tx; Gear^.Y:= Gear^.Y + ty; @@ -672,8 +673,8 @@ with HHGear^ do State:= State and not gstAttacking; tt:= _0 end; - tx:= tx + Gear^.dX - Gear^.dX; - ty:= ty + Gear^.dY - Gear^.dY; + tx:= tx + Gear^.dX + Gear^.dX; + ty:= ty + Gear^.dY + Gear^.dY; tt:= tt - _2; end; end; @@ -987,6 +988,7 @@ begin HHGear:= PHedgehog(Gear^.Hedgehog)^.Gear; HHGear^.State:= HHGear^.State and not gstAttacking; +DeleteCI(HHGear); inc(Gear^.Timer);