diff -r 37891ba5e10b -r 1e32628eb167 hedgewars/uGearsHedgehog.pas --- a/hedgewars/uGearsHedgehog.pas Fri Dec 20 15:06:18 2013 +0400 +++ b/hedgewars/uGearsHedgehog.pas Sat Dec 21 01:14:59 2013 +0400 @@ -1349,7 +1349,7 @@ if (WorldEdge = weWrap) and ((TestCollisionXwithGear(Gear, 1) <> 0) or (TestCollisionXwithGear(Gear, -1) <> 0)) then begin Gear^.X:= tX; - Gear^.dX.isNegative:= (hwRound(tX) > leftX+Gear^.Radius*2) + Gear^.dX.isNegative:= (hwRound(tX) > LongInt(leftX) + Gear^.Radius * 2) end end;