Force-disable gfPerHogAmmo and gfSharedAmmo for RW and BRW
authorWuzzy <Wuzzy2@mail.ru>
Fri, 31 Aug 2018 16:51:33 +0200
changeset 13722 8e3d2f7d8737
parent 13721 7edaeca8f816
child 13723 61095cb5f58a
Force-disable gfPerHogAmmo and gfSharedAmmo for RW and BRW
ChangeLog.txt
share/hedgewars/Data/Scripts/Multiplayer/Balanced_Random_Weapon.lua
share/hedgewars/Data/Scripts/Multiplayer/Random_Weapon.lua
--- a/ChangeLog.txt	Fri Aug 31 12:09:40 2018 +0200
+++ b/ChangeLog.txt	Fri Aug 31 16:51:33 2018 +0200
@@ -50,6 +50,9 @@
 Balanced Random Weapon:
  + Can adjust weapon start and crate probabilities
 
+Random Weapon:
+ * Fix breakage when enabling per-hog ammo
+
 Continental supplies:
  + Continents are now selected before the game starts
  + Continents give hog different start health
--- a/share/hedgewars/Data/Scripts/Multiplayer/Balanced_Random_Weapon.lua	Fri Aug 31 12:09:40 2018 +0200
+++ b/share/hedgewars/Data/Scripts/Multiplayer/Balanced_Random_Weapon.lua	Fri Aug 31 16:51:33 2018 +0200
@@ -146,7 +146,7 @@
 end
 
 function onGameInit()
-    DisableGameFlags(gfPerHogAmmo)
+    DisableGameFlags(gfPerHogAmmo, gfSharedAmmo)
     EnableGameFlags(gfResetWeps)
     Goals = loc("Each turn you get 1-3 random weapons")
 
--- a/share/hedgewars/Data/Scripts/Multiplayer/Random_Weapon.lua	Fri Aug 31 12:09:40 2018 +0200
+++ b/share/hedgewars/Data/Scripts/Multiplayer/Random_Weapon.lua	Fri Aug 31 16:51:33 2018 +0200
@@ -47,7 +47,7 @@
 
 function onGameInit()
     -- Limit flags that can be set, but allow game schemes to be used
-    DisableGameFlags(gfInfAttack)
+    DisableGameFlags(gfInfAttack, gfPerHogAmmo, gfSharedAmmo)
     EnableGameFlags(gfResetWeps)
     -- Set a custom game goal that will show together with the scheme ones
     Goals = loc("Each turn you get one random weapon")