Fix turn end if placing air attack in bouncy world edge map was denied
authorWuzzy <Wuzzy2@mail.ru>
Mon, 01 Apr 2019 20:08:34 +0200
changeset 14740 2d859d34e6f6
parent 14739 e57c8ace7d96
child 14741 8563cc40fc1e
Fix turn end if placing air attack in bouncy world edge map was denied Fixes bug #728.
hedgewars/uGearsHandlersMess.pas
hedgewars/uGearsHedgehog.pas
--- a/hedgewars/uGearsHandlersMess.pas	Mon Apr 01 19:27:13 2019 +0200
+++ b/hedgewars/uGearsHandlersMess.pas	Mon Apr 01 20:08:34 2019 +0200
@@ -3046,6 +3046,8 @@
 
     if (HHGear <> nil) then
         PlaySoundV(sndIncoming, Gear^.Hedgehog^.Team^.voicepack);
+    AfterAttack;
+    CurAmmoGear := nil;
 
     if Gear^.X.QWordValue = 0 then
         begin
--- a/hedgewars/uGearsHedgehog.pas	Mon Apr 01 19:27:13 2019 +0200
+++ b/hedgewars/uGearsHedgehog.pas	Mon Apr 01 20:08:34 2019 +0200
@@ -530,6 +530,8 @@
                 amFlamethrower, amLandGun,
                  amResurrector, amTardis,
                        amPiano, amIceGun,
+                   amAirAttack, amNapalm,
+                  amMineStrike, amDrillStrike,
                       amRubber, amMinigun: CurAmmoGear:= newGear;
             end;
             if CurAmmoType = amCake then FollowGear:= newGear;