]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Add an extra mode to g_showweaponspawns which shows all weapon locations with the...
authorMario <mario@smbclan.net>
Mon, 8 Aug 2016 05:44:32 +0000 (15:44 +1000)
committerMario <mario@smbclan.net>
Mon, 8 Aug 2016 05:44:32 +0000 (15:44 +1000)
qcsrc/server/weapons/selection.qc

index 8e3e1075899707fdcf6248ce297f5e0394ec061d..8a787241a095695376a8879484d6c8c7390c7b07 100644 (file)
@@ -101,7 +101,15 @@ bool client_hasweapon(entity this, Weapon wpn, float andammo, bool complain)
                if (weaponsInMap & WepSet_FromWeapon(wpn))
                {
                        Send_WeaponComplain(this, wpn.m_id, 1);
-                       Weapon_whereis(wpn, this);
+                       if(autocvar_g_showweaponspawns < 3)
+                               Weapon_whereis(wpn, this);
+                       else
+                       {
+                               FOREACH(Weapons, it.impulse == wpn.impulse,
+                               {
+                                       Weapon_whereis(it, this);
+                               });
+                       }
                }
                else
                {