[8405] Fixed possible crash in BGQueueRemoveEvent::Execute() when two paralell BattleGroundQueue Updates are called, optimalized code.

Signed-off-by: Triply <[email protected]>

--HG--
branch : trunk
This commit is contained in:
megamage
2009-08-24 19:34:56 -05:00
parent 785577e170
commit 19bfa37ec6
2 changed files with 37 additions and 1 deletions
+2
View File
@@ -220,6 +220,7 @@ class BattleGroundMgr
BGFreeSlotQueueType BGFreeSlotQueue[MAX_BATTLEGROUND_TYPE_ID];
void ScheduleQueueUpdate(BattleGroundQueueTypeId bgQueueTypeId, BattleGroundTypeId bgTypeId, BGQueueIdBasedOnLevel queue_id);
uint32 GetMaxRatingDifference() const;
uint32 GetRatingDiscardTimer() const;
uint32 GetPrematureFinishTime() const;
@@ -252,6 +253,7 @@ class BattleGroundMgr
/* Battlegrounds */
BattleGroundSet m_BattleGrounds[MAX_BATTLEGROUND_TYPE_ID];
std::vector<uint32>m_QueueUpdateScheduler;
std::set<uint32> m_ClientBattleGroundIds[MAX_BATTLEGROUND_TYPE_ID][MAX_BATTLEGROUND_QUEUES]; //the instanceids just visible for the client
uint32 m_NextRatingDiscardUpdate;
time_t m_NextAutoDistributionTime;