From 079ed071c2677f16f3b2e609f06457010f065a8d Mon Sep 17 00:00:00 2001 From: Mario Date: Wed, 31 Aug 2016 04:03:10 +1000 Subject: [PATCH] Don't allow magnet buff to pickup or capture flags, also fix item teaming potentially attempting to team keyhunt keys --- qcsrc/common/mutators/mutator/buffs/sv_buffs.qc | 2 +- qcsrc/common/t_items.qc | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/qcsrc/common/mutators/mutator/buffs/sv_buffs.qc b/qcsrc/common/mutators/mutator/buffs/sv_buffs.qc index 73f6b6393..82fa2d33c 100644 --- a/qcsrc/common/mutators/mutator/buffs/sv_buffs.qc +++ b/qcsrc/common/mutators/mutator/buffs/sv_buffs.qc @@ -826,7 +826,7 @@ MUTATOR_HOOKFUNCTION(buffs, PlayerPreThink) if(player.buffs & BUFF_MAGNET.m_itemid) { vector pickup_size; - IL_EACH(g_items, true, + IL_EACH(g_items, it.classname != "item_flag_team" && it.classname != "item_kh_key", { if(it.buffs) pickup_size = '1 1 1' * autocvar_g_buffs_magnet_range_buff; diff --git a/qcsrc/common/t_items.qc b/qcsrc/common/t_items.qc index 8a4446678..f9f89a73f 100644 --- a/qcsrc/common/t_items.qc +++ b/qcsrc/common/t_items.qc @@ -837,7 +837,7 @@ LABEL(pickup) RandomSelection_Init(); IL_EACH(g_items, it.team == this.team, { - if(it.classname != "item_flag_team" && it.classname != "item_key_team") + if(it.classname != "item_flag_team" && it.classname != "item_kh_key") { Item_Show(it, -1); RandomSelection_Add(it, 0, string_null, it.cnt, 0); @@ -881,7 +881,7 @@ void Item_FindTeam(entity this) RandomSelection_Init(); IL_EACH(g_items, it.team == this.team, { - if(it.classname != "item_flag_team" && it.classname != "item_key_team") + if(it.classname != "item_flag_team" && it.classname != "item_kh_key") RandomSelection_Add(it, 0, string_null, it.cnt, 0); }); @@ -891,7 +891,7 @@ void Item_FindTeam(entity this) IL_EACH(g_items, it.team == this.team, { - if(it.classname != "item_flag_team" && it.classname != "item_key_team") + if(it.classname != "item_flag_team" && it.classname != "item_kh_key") { if(it != e) { -- 2.39.2