From: terencehill Date: Wed, 20 Apr 2016 17:12:10 +0000 (+0200) Subject: Don't pick specific weapons X-Git-Tag: xonotic-v0.8.2~949^2~1 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=9f31ea5b6985165c96d94d8c7f2de9c2e14738c1;p=xonotic%2Fxonotic-data.pk3dir.git Don't pick specific weapons --- diff --git a/qcsrc/client/hud/panel/weapons.qc b/qcsrc/client/hud/panel/weapons.qc index 52fcc549a..8fa22dd5e 100644 --- a/qcsrc/client/hud/panel/weapons.qc +++ b/qcsrc/client/hud/panel/weapons.qc @@ -106,12 +106,14 @@ void HUD_Weapons() { if(!weapons_stat) { - weapons_stat |= WepSet_FromWeapon(Weapons_from(WEP_BLASTER.m_id)); - weapons_stat |= WepSet_FromWeapon(Weapons_from(WEP_SHOTGUN.m_id)); - weapons_stat |= WepSet_FromWeapon(Weapons_from(WEP_MORTAR.m_id)); - weapons_stat |= WepSet_FromWeapon(Weapons_from(WEP_CRYLINK.m_id)); - weapons_stat |= WepSet_FromWeapon(Weapons_from(WEP_VORTEX.m_id)); - weapons_stat |= WepSet_FromWeapon(Weapons_from(WEP_DEVASTATOR.m_id)); + int j = 0; + FOREACH(Weapons, it != WEP_Null && it.impulse >= 0 && (it.impulse % 3 != 0) && j < 6, { + if(!(it.spawnflags & WEP_FLAG_MUTATORBLOCKED)) + { + weapons_stat |= it.m_wepset; + ++j; + } + }); } #if 0