mirror of
https://github.com/mangosfour/server.git
synced 2025-12-13 13:37:05 +00:00
[12123] Move BattleGround code to separate BattleGround directory. Also some corrects to unload BG's
This commit is contained in:
parent
19cae15ea0
commit
de95d1d480
57 changed files with 293 additions and 280 deletions
|
|
@ -49,7 +49,7 @@
|
|||
#include "ScriptMgr.h"
|
||||
#include "CreatureAIRegistry.h"
|
||||
#include "Policies/SingletonImp.h"
|
||||
#include "BattleGroundMgr.h"
|
||||
#include "BattleGround/BattleGroundMgr.h"
|
||||
#include "OutdoorPvP/OutdoorPvP.h"
|
||||
#include "TemporarySummon.h"
|
||||
#include "VMapFactory.h"
|
||||
|
|
@ -141,6 +141,14 @@ World::~World()
|
|||
// TODO free addSessQueue
|
||||
}
|
||||
|
||||
/// Cleanups before world stop
|
||||
void World::CleanupsBeforeStop()
|
||||
{
|
||||
KickAll(); // save and kick all players
|
||||
UpdateSessions(1); // real players unload required UpdateSessions call
|
||||
sBattleGroundMgr.DeleteAllBattleGrounds(); // unload battleground templates before different singletons destroyed
|
||||
}
|
||||
|
||||
/// Find a player in a specified zone
|
||||
Player* World::FindPlayerInZone(uint32 zone)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue