# HG changeset patch # User nemo # Date 1320541281 14400 # Node ID 0cd63375e80b9e6e67d9ea7c19ca949a02cab445 # Parent 5b2b304a91ecfff4d258b50713fae35b66f55393 not sure why this condition wasn't here before diff -r 5b2b304a91ec -r 0cd63375e80b hedgewars/uWorld.pas --- a/hedgewars/uWorld.pas Sat Nov 05 20:51:15 2011 -0400 +++ b/hedgewars/uWorld.pas Sat Nov 05 21:01:21 2011 -0400 @@ -1206,21 +1206,21 @@ uCursor.updatePosition(); {$ENDIF} z:= round(200/zoom); -if (not PlacingHogs) and (FollowGear <> nil) and (not isCursorVisible) and (not fastUntilLag) then +if not PlacingHogs and (FollowGear <> nil) and not isCursorVisible and not bShowAmmoMenu and not fastUntilLag then if (not autoCameraOn) or ((abs(CursorPoint.X - prevPoint.X) + abs(CursorPoint.Y - prevpoint.Y)) > 4) then - begin + begin FollowGear:= nil; prevPoint:= CursorPoint; exit - end + end else - begin + begin CursorPoint.X:= (prevPoint.X * 7 + hwRound(FollowGear^.X) + hwSign(FollowGear^.dX) * z + WorldDx) div 8; if isPhone() or (cScreenHeight < 600) or ((hwSign(FollowGear^.dY) * z) < 10) then CursorPoint.Y:= (prevPoint.Y * 7 + cScreenHeight - (hwRound(FollowGear^.Y) + WorldDy)) div 8 else CursorPoint.Y:= (prevPoint.Y * 7 + cScreenHeight - (hwRound(FollowGear^.Y) + hwSign(FollowGear^.dY) * z + WorldDy)) div 8; - end; + end; wdy:= trunc(cScreenHeight / cScaleFactor) + cScreenHeight div 2 - cWaterLine - cVisibleWater; if WorldDy < wdy then WorldDy:= wdy;