Try turning off follow gear while ammo menu is open - needs testing w/ rope/parachute/jetpack
authornemo
Sun, 05 Jul 2009 16:37:05 +0000
changeset 2226 e35b62cb7a1c
parent 2225 162d8f6bca25
child 2227 743218daf878
Try turning off follow gear while ammo menu is open - needs testing w/ rope/parachute/jetpack
hedgewars/GSHandlers.inc
hedgewars/uWorld.pas
--- a/hedgewars/GSHandlers.inc	Sun Jul 05 13:44:11 2009 +0000
+++ b/hedgewars/GSHandlers.inc	Sun Jul 05 16:37:05 2009 +0000
@@ -2244,7 +2244,7 @@
 Gear^.X:= HHGear^.X;
 Gear^.Y:= HHGear^.Y;
 // For some reason I need to reapply followgear here, something else grabs it otherwise.
-FollowGear:= HHGear;
+if not bShowAmmoMenu then FollowGear:= HHGear;
 doStepHedgehogMoving(HHGear);
 
 if  (Gear^.Health = 0)
--- a/hedgewars/uWorld.pas	Sun Jul 05 13:44:11 2009 +0000
+++ b/hedgewars/uWorld.pas	Sun Jul 05 16:37:05 2009 +0000
@@ -85,6 +85,7 @@
 if (TurnTimeLeft = 0) or (((CurAmmoGear = nil) or ((CurAmmoGear^.Ammo^.Propz and ammoprop_AltAttack) = 0)) and KbdKeyPressed) then bShowAmmoMenu:= false;
 if bShowAmmoMenu then
    begin
+   FollowGear:= nil;
    if AMxShift = 210 then prevPoint.X:= 0;
    if cReducedQuality then
        AMxShift:= 0