hedgewars/uGearsHandlersMess.pas
changeset 10379 caa5b40e405b
parent 10372 e49b76a12800
child 10411 ee4e6d392b31
--- a/hedgewars/uGearsHandlersMess.pas	Tue Aug 12 17:58:36 2014 +0400
+++ b/hedgewars/uGearsHandlersMess.pas	Wed Aug 13 13:36:35 2014 +0200
@@ -2197,7 +2197,8 @@
             Gear^.Y:= Gear^.Y+_6;
             if (landPixel and lfIce <> 0) or (TestCollisionYwithGear(Gear, 1) and lfIce <> 0) then
                 begin
-                gY := gy-6;
+                gX := hwRound(Gear^.X);
+                gY := hwRound(Gear^.Y) - 6;
                 DrawExplosion(gX, gY, 4);
                 PlaySound(sndVaporize);
                 AddVisualGear(gX - 3 + Random(6), gY - 2, vgtSteam);
@@ -2227,6 +2228,8 @@
             end
         else
             begin
+            gX := hwRound(Gear^.X);
+            gY := hwRound(Gear^.Y);
             // Standard fire
             if not sticky then
                 begin
@@ -2276,6 +2279,8 @@
         end;
     if Gear^.Health = 0 then
         begin
+        gX := hwRound(Gear^.X);
+        gY := hwRound(Gear^.Y);
         if not sticky then
             begin
             if ((GameTicks and $3) = 0) and (Random(1) = 0) then