AI: Switch to amNothing instead of amSkip to unselect weapon
authorWuzzy <Wuzzy2@mail.ru>
Sun, 05 Jul 2020 21:37:35 +0200
changeset 15681 a92220611821
parent 15680 3224d0d970ac
child 15682 842385b5e0f6
AI: Switch to amNothing instead of amSkip to unselect weapon
hedgewars/uAI.pas
--- a/hedgewars/uAI.pas	Sun Jul 05 21:25:15 2020 +0200
+++ b/hedgewars/uAI.pas	Sun Jul 05 21:37:35 2020 +0200
@@ -293,9 +293,9 @@
 BestRate:= RatePlace(Me);
 BaseRate:= Max(BestRate, 0);
 
-// switch to 'skip' if we cannot move because of mouse cursor being shown
+// unselect weapon if we cannot move because of mouse cursor being shown
 if (Ammoz[Me^.Hedgehog^.CurAmmoType].Ammo.Propz and ammoprop_NeedTarget) <> 0 then
-    AddAction(Actions, aia_Weapon, Longword(amSkip), 100 + random(200), 0, 0);
+    AddAction(Actions, aia_Weapon, Longword(amNothing), 100 + random(200), 0, 0);
 
 if ((CurrentHedgehog^.MultiShootAttacks = 0) or ((Ammoz[Me^.Hedgehog^.CurAmmoType].Ammo.Propz and ammoprop_NoMoveAfter) = 0))
     and (CurrentHedgehog^.Effects[heArtillery] = 0) and (cGravityf <> 0) then