From: Lyberta Date: Fri, 28 Jul 2017 02:01:51 +0000 (+0300) Subject: Player templates: fixed unlimited ammo. X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=5d8fd87ce7fa455103f3d1927750ed38e536e3fe;p=xonotic%2Fxonotic-data.pk3dir.git Player templates: fixed unlimited ammo. --- diff --git a/qcsrc/common/mutators/mutator/playertemplates/sv_playertemplates.qc b/qcsrc/common/mutators/mutator/playertemplates/sv_playertemplates.qc index 7e86eca111..eda6b8683b 100644 --- a/qcsrc/common/mutators/mutator/playertemplates/sv_playertemplates.qc +++ b/qcsrc/common/mutators/mutator/playertemplates/sv_playertemplates.qc @@ -23,10 +23,6 @@ string PlayerTemplate_GetDefaultCvarName(string variable) { return "g_balance_armor_start"; } - case "unlimited_ammo": - { - return "g_use_ammunition"; - } case "start_ammo_shells": { return "g_start_ammo_shells"; @@ -65,7 +61,6 @@ float PlayerTemplate_GetDefaultFloatValue(string variable) { case "start_health": case "start_armor": - case "unlimited_ammo": case "start_ammo_shells": case "start_ammo_bullets": case "start_ammo_rockets": @@ -75,6 +70,10 @@ float PlayerTemplate_GetDefaultFloatValue(string variable) { return cvar(PlayerTemplate_GetDefaultCvarName(variable)); } + case "unlimited_ammo": + { + return !autocvar_g_use_ammunition; + } case "default_start_weapons": { return 1;