--- a/hedgewars/VGSHandlers.inc Thu Oct 14 16:01:43 2010 +0200
+++ b/hedgewars/VGSHandlers.inc Thu Oct 14 22:01:33 2010 +0200
@@ -36,7 +36,7 @@
if (round(X) >= cLeftScreenBorder) and
(round(X) <= cRightScreenBorder) and
- (round(Y) <= (LAND_HEIGHT + 75)) and
+ (round(Y) <= (int64(LAND_HEIGHT) + 75)) and
(Timer > 0) and (Timer-Steps > 0) then
begin
if tdX > 0 then sign := 1
@@ -54,7 +54,7 @@
if round(X) < cLeftScreenBorder then X:= X + cScreenSpace else
if round(X) > cRightScreenBorder then X:= X - cScreenSpace;
// if round(Y) < (LAND_HEIGHT - 1024 - 75) then Y:= Y + float(25); // For if flag is set for flakes rising upwards?
- if round(Y) > (LAND_HEIGHT + 75) then Y:= Y - float(1024 + 150); // TODO - configure in theme (jellies for example could use limited range)
+ if round(Y) > (int64(LAND_HEIGHT) + 75) then Y:= Y - float(1024 + 150); // TODO - configure in theme (jellies for example could use limited range)
Timer:= 0;
tdX:= 0;
tdY:= 0
@@ -84,7 +84,7 @@
t := 8 * AngleSin(s mod 2048).QWordValue / 4294967296;
if (s < 2048) then t := -t;
-Gear^.Y := LAND_HEIGHT-1184 + Gear^.Timer mod 8 + t;
+Gear^.Y := int64(LAND_HEIGHT) - 1184 + Gear^.Timer mod 8 + t;
if round(Gear^.X) < cLeftScreenBorder then Gear^.X:= Gear^.X + cScreenSpace else
if round(Gear^.X) > cRightScreenBorder then Gear^.X:= Gear^.X - cScreenSpace
@@ -480,7 +480,7 @@
procedure doStepHealthTagWorkUnderWater(Gear: PVisualGear; Steps: Longword);
begin
-if round(Gear^.Y) < cWaterLine + 10 then
+if round(Gear^.Y) < int64(cWaterLine) + 10 then
DeleteVisualGear(Gear)
else
Gear^.Y:= Gear^.Y - 0.08 * Steps;