Backed out changeset 98824a464230 (disable GetLaunchX/Y again)
authorWuzzy <almikes@aol.com>
Mon, 24 Apr 2017 19:21:43 +0200
changeset 12317 b81a1d1497c4
parent 12316 d09eba2e1dd8
child 12318 f4d3810a3b54
Backed out changeset 98824a464230 (disable GetLaunchX/Y again) Reason: GetLaunchX/GetLaunchY were buggy
hedgewars/uUtils.pas
hedgewars/uVariables.pas
--- a/hedgewars/uUtils.pas	Mon Apr 24 09:59:10 2017 -0400
+++ b/hedgewars/uUtils.pas	Mon Apr 24 19:21:43 2017 +0200
@@ -536,18 +536,22 @@
 
 function GetLaunchX(at: TAmmoType; dir: LongInt; angle: LongInt): LongInt;
 begin
+GetLaunchX:= 0
+(*
     if (Ammoz[at].ejectX <> 0) or (Ammoz[at].ejectY <> 0) then
         GetLaunchX:= sign(dir) * (8 + hwRound(AngleSin(angle) * Ammoz[at].ejectX) + hwRound(AngleCos(angle) * Ammoz[at].ejectY))
     else
-        GetLaunchX:= 0
+        GetLaunchX:= 0 *)
 end;
 
 function GetLaunchY(at: TAmmoType; angle: LongInt): LongInt;
 begin
+GetLaunchY:= 0
+(*
     if (Ammoz[at].ejectX <> 0) or (Ammoz[at].ejectY <> 0) then
         GetLaunchY:= hwRound(AngleSin(angle) * Ammoz[at].ejectY) - hwRound(AngleCos(angle) * Ammoz[at].ejectX) - 2
     else
-        GetLaunchY:= 0
+        GetLaunchY:= 0*)
 end;
 
 function CheckNoTeamOrHH: boolean;
--- a/hedgewars/uVariables.pas	Mon Apr 24 09:59:10 2017 -0400
+++ b/hedgewars/uVariables.pas	Mon Apr 24 19:21:43 2017 +0200
@@ -900,7 +900,7 @@
             PosCount: 1;
             PosSprite: sprWater;
             ejectX: 0; //20;
-            ejectY: 0), //-6;
+            ejectY: -6),
 
 // Bee
             (NameId: sidBee;
@@ -953,7 +953,7 @@
             PosCount: 1;
             PosSprite: sprWater;
             ejectX: 0; //26;
-            ejectY: 0), //-6;
+            ejectY: -6),
 
 // PickHammer
             (NameId: sidPickHammer;
@@ -1089,7 +1089,7 @@
             PosCount: 1;
             PosSprite: sprWater;
             ejectX: 0; //23;
-            ejectY: 0), //-6;
+            ejectY: -6),
 
 // Dynamite
             (NameId: sidDynamite;
@@ -1413,7 +1413,7 @@
             PosCount: 1;
             PosSprite: sprWater;
             ejectX: 0; //20;
-            ejectY: 0), //-6;
+            ejectY: -6),
 
 // Kamikaze
             (NameId: sidKamikaze;
@@ -1600,7 +1600,7 @@
             PosCount: 1;
             PosSprite: sprDrill;
             ejectX: 0; //20;
-            ejectY: 0), //-6;
+            ejectY: -6),
 
 // Ballgun
             (NameId: sidBallgun;
@@ -1626,7 +1626,7 @@
             PosCount: 1;
             PosSprite: sprWater;
             ejectX: 0; //20;
-            ejectY: 0), //-3;
+            ejectY: -3),
 
 // RC-Plane
             (NameId: sidRCPlane;
@@ -1855,7 +1855,7 @@
             PosCount: 1;
             PosSprite: sprWater;
             ejectX: 0; //40;
-            ejectY: 0), //-5;
+            ejectY: -5),
 
 // Jetpack ("Flying Saucer")
             (NameId: sidJetpack;
@@ -1965,8 +1965,8 @@
             SkipTurns: 0;
             PosCount: 1;
             PosSprite: sprWater;
-            ejectX: 0; //-5, 29;
-            ejectY: 0), //-7
+            ejectX: -5; //29;
+            ejectY: -7),
 
 // Piano
             (NameId: sidPiano;
@@ -2073,7 +2073,7 @@
             PosCount: 1;
             PosSprite: sprWater;
             ejectX: 0; //20;
-            ejectY: 0), //-3;
+            ejectY: -3),
 
 // Sticky Mine
             (NameId: sidSMine;
@@ -2287,7 +2287,7 @@
             PosCount: 1;
             PosSprite: sprWater;
             ejectX: 0; //20;
-            ejectY: 0), //-3;
+            ejectY: -3),
 // Freezer
             (NameId: sidIceGun;
             NameTex: nil;
@@ -2312,7 +2312,7 @@
             PosCount: 1;
             PosSprite: sprWater;
             ejectX: 0; //20;
-            ejectY: 0), //-3;
+            ejectY: -3),
 // Knife
             (NameId: sidKnife;
             NameTex: nil;