fix portal/hammer interaction, ban freezer from portal
authornemo
Sun, 03 Mar 2013 20:59:27 -0500
changeset 8634 5dcb1dc9e01b
parent 8633 b9f5adfa81cc
child 8635 c1c6b815691e
fix portal/hammer interaction, ban freezer from portal
hedgewars/GSHandlers.inc
--- a/hedgewars/GSHandlers.inc	Sun Mar 03 20:08:55 2013 -0500
+++ b/hedgewars/GSHandlers.inc	Sun Mar 03 20:59:27 2013 -0500
@@ -3635,7 +3635,7 @@
             break;
 
         // don't port portals or other gear that wouldn't make sense
-        if (iterator^.Kind in [gtPortal, gtRope, gtAirAttack])
+        if (iterator^.Kind in [gtPortal, gtRope, gtAirAttack, gtIceGun])
         or (iterator^.PortalCounter > 32) then
             continue;
 
@@ -4584,8 +4584,8 @@
         if CheckLandValue(hwRound(Gear^.X + Gear^.dX + SignAs(_6,Gear^.dX)), hwRound(Gear^.Y + _1_9)
            , lfIndestructible) then
             begin
-            Gear^.X := Gear^.X + Gear^.dX;
-            Gear^.Y := Gear^.Y + _1_9;
+            //Gear^.X := Gear^.X + Gear^.dX;
+            Gear^.Y := Gear^.Y + _1_9
             end;
         end;
     if TestCollisionYwithGear(Gear, 1) <> 0 then
@@ -4596,14 +4596,15 @@
         end
     else
         begin
-        Gear^.dY := Gear^.dY + cGravity;
-        Gear^.Y := Gear^.Y + Gear^.dY;
+        //Gear^.dY := Gear^.dY + cGravity;
+        //Gear^.Y := Gear^.Y + Gear^.dY;
         if hwRound(Gear^.Y) > cWaterLine then
             Gear^.Timer := 1
         end;
 
-    Gear^.X := Gear^.X + HitGear^.dX;
+    //Gear^.X := Gear^.X + HitGear^.dX;
     HitGear^.X := Gear^.X;
+    HitGear^.Y := Gear^.Y;
     SetLittle(HitGear^.dY);
     HitGear^.Active:= true;
 end;