From 5d8fd87ce7fa455103f3d1927750ed38e536e3fe Mon Sep 17 00:00:00 2001 From: Lyberta Date: Fri, 28 Jul 2017 05:01:51 +0300 Subject: [PATCH] Player templates: fixed unlimited ammo. --- .../mutator/playertemplates/sv_playertemplates.qc | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) 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; -- 2.39.5