hedgewars/uGearsHandlersMess.pas
changeset 9473 a51a69094c24
parent 9470 9ed07a96349d
child 9477 0463f747e839
--- a/hedgewars/uGearsHandlersMess.pas	Fri Sep 27 21:52:21 2013 -0400
+++ b/hedgewars/uGearsHandlersMess.pas	Sun Sep 29 16:10:32 2013 -0400
@@ -284,6 +284,8 @@
     collV, collH: LongInt;
     land: word;
 begin
+    WorldWrap(Gear);
+
     // clip velocity at 2 - over 1 per pixel, but really shouldn't cause many actual problems.
     if Gear^.dX.Round > 2 then
         Gear^.dX.QWordValue:= 8589934592;
@@ -302,8 +304,6 @@
     tdX := Gear^.dX;
     tdY := Gear^.dY;
 
-
-
 // might need some testing/adjustments - just to avoid projectiles to fly forever (accelerated by wind/skips)
     if (hwRound(Gear^.X) < min(LAND_WIDTH div -2, -2048))
     or (hwRound(Gear^.X) > max(LAND_WIDTH * 3 div 2, 6144)) then
@@ -889,6 +889,7 @@
     flower: PVisualGear;
 
 begin
+    WorldWrap(Gear);
     AllInactive := false;
     gX := hwRound(Gear^.X);
     gY := hwRound(Gear^.Y);
@@ -4637,6 +4638,7 @@
 ////////////////////////////////////////////////////////////////////////////////
 procedure doStepPoisonCloud(Gear: PGear);
 begin
+    WorldWrap(Gear);
     if Gear^.Timer = 0 then
         begin
         DeleteGear(Gear);