From c693e97a2193d46afab8ff5d4110654a5953ec75 Mon Sep 17 00:00:00 2001 From: biglad Date: Fri, 10 Apr 2009 10:33:54 +0100 Subject: [PATCH 1/2] * Fix BG start teams, make them even, send only corrent amount of invites. thanks Machiavelli for help --HG-- branch : trunk --- src/game/BattleGroundMgr.cpp | 22 ++++++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-) diff --git a/src/game/BattleGroundMgr.cpp b/src/game/BattleGroundMgr.cpp index 259ee1fed13..aecb706f73d 100644 --- a/src/game/BattleGroundMgr.cpp +++ b/src/game/BattleGroundMgr.cpp @@ -653,16 +653,34 @@ void BattleGroundQueue::Update(uint32 bgTypeId, uint32 queue_id, uint8 arenatype std::list::iterator itr; + //Send corrent ammount of invites to both faction at start of BG, not all in current queue, makes starting teams even + unsigned int QUEUED_HORDE = m_SelectionPools[NORMAL_HORDE].SelectedGroups.size(); + unsigned int QUEUED_ALLIANCE= m_SelectionPools[NORMAL_ALLIANCE].SelectedGroups.size(); + unsigned int maxbginvites = 0; + + if(QUEUED_ALLIANCE <= QUEUED_HORDE) + maxbginvites = QUEUED_ALLIANCE; + else + maxbginvites = QUEUED_HORDE; + // invite groups from horde selection pool + int invitecounter = 0; for(itr = m_SelectionPools[NORMAL_HORDE].SelectedGroups.begin(); itr != m_SelectionPools[NORMAL_HORDE].SelectedGroups.end(); ++itr) { + if (invitecounter >= maxbginvites) + return; InviteGroupToBG((*itr),bg2,HORDE); + ++invitecounter; } - // invite groups from ally selection pools + // invite groups from ally selection pool + invitecounter = 0; for(itr = m_SelectionPools[NORMAL_ALLIANCE].SelectedGroups.begin(); itr != m_SelectionPools[NORMAL_ALLIANCE].SelectedGroups.end(); ++itr) - { + { + if (invitecounter >= maxbginvites) + return; InviteGroupToBG((*itr),bg2,ALLIANCE); + ++invitecounter; } if (isRated) From 2ba0af3d8fda27516b0a5c93402fba416087e220 Mon Sep 17 00:00:00 2001 From: raczman Date: Sun, 12 Apr 2009 11:05:19 +0200 Subject: [PATCH 2/2] Correct spell_affect mask for spell 12472 - by _krz/Asael --HG-- branch : trunk --- sql/updates/1340_world.sql | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 sql/updates/1340_world.sql diff --git a/sql/updates/1340_world.sql b/sql/updates/1340_world.sql new file mode 100644 index 00000000000..eba0b719dbc --- /dev/null +++ b/sql/updates/1340_world.sql @@ -0,0 +1,2 @@ +DELETE FROM `spell_affect` WHERE `entry`='12472' AND `effectId`='1'; +INSERT INTO `spell_affect` VALUES ('12472', '1', "18446744073709551615");