From: Mario Date: Tue, 30 Aug 2016 18:03:10 +0000 (+1000) Subject: Don't allow magnet buff to pickup or capture flags, also fix item teaming potentially... X-Git-Tag: xonotic-v0.8.2~641 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=079ed071c2677f16f3b2e609f06457010f065a8d;p=xonotic%2Fxonotic-data.pk3dir.git Don't allow magnet buff to pickup or capture flags, also fix item teaming potentially attempting to team keyhunt keys --- 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) {