|
Project SkyFire Core
SkyFire 5.4.8 server core API documentation
|
#include <MapManager.h>
Static Public Member Functions | |
| static bool | ExistMapAndVMap (uint32 mapid, float x, float y) |
| static bool | IsValidMAP (uint32 mapid, bool startUp) |
| static bool | IsValidMapCoord (uint32 mapid, float x, float y) |
| static bool | IsValidMapCoord (uint32 mapid, float x, float y, float z) |
| static bool | IsValidMapCoord (uint32 mapid, float x, float y, float z, float o) |
| static bool | IsValidMapCoord (WorldLocation const &loc) |
Private Types | |
| typedef std::vector< bool > | InstanceIds |
| typedef UNORDERED_MAP< uint32, Map * > | MapMapType |
Private Member Functions | |
| void | checkAndCorrectGridStatesArray () |
| Map * | FindBaseMap (uint32 mapId) const |
| MapManager () | |
| MapManager (const MapManager &) | |
| MapManager & | operator= (const MapManager &) |
| ~MapManager () | |
Private Attributes | |
| InstanceIds | _instanceIds |
| uint32 | _nextInstanceId |
| uint32 | i_gridCleanUpDelay |
| int | i_GridStateErrorCount |
| GridState * | i_GridStates [MAX_GRID_STATE] = { } |
| MapMapType | i_maps |
| IntervalTimer | i_timer |
| std::mutex | Lock |
| MapUpdater | m_updater |
Friends | |
| class | Skyfire::Singleton< MapManager, Skyfire::Mutex > |
Definition at line 21 of file MapManager.h.
|
private |
Definition at line 117 of file MapManager.h.
|
private |
Definition at line 116 of file MapManager.h.
|
private |
Definition at line 31 of file MapManager.cpp.
References _nextInstanceId, CONFIG_INTERVAL_GRIDCLEAN, CONFIG_INTERVAL_MAPUPDATE, i_gridCleanUpDelay, i_GridStateErrorCount, i_timer, and sWorld.
Referenced by GetAreaFlag(), MapManager(), and operator=().
|
private |
Definition at line 37 of file MapManager.cpp.
|
private |
References MapManager().
Definition at line 174 of file MapManager.cpp.
References Player::CheckInstanceCount(), CONFIG_INSTANCE_IGNORE_RAID, Group::GetBoundInstance(), Player::GetCorpse(), Player::GetDifficulty(), GetDownscaledMapDifficultyData(), Player::GetDungeonDifficulty(), Player::GetGroup(), InstanceSave::GetInstanceId(), Player::GetInstanceSave(), GetMapDifficultyData(), WorldObject::GetName(), Player::GetSession(), Unit::IsAlive(), Unit::isDead(), Player::IsGameMaster(), MapEntry::IsInstance(), Group::isLFGGroup(), MapEntry::IsNonRaidInstance(), MapEntry::IsRaid(), Group::isRaidGroup(), LANG_INSTANCE_RAID_GROUP_ONLY, MapEntry::MapID, MapEntry::name, InstanceTemplate::Parent, Player::ResurrectPlayer(), Player::Satisfy(), InstanceGroupBind::save, WorldSession::SendNotification(), WorldSession::SendPacket(), Player::SendTransferAborted(), SF_LOG_DEBUG, sMapMgr, sMapStore, SMSG_CORPSE_NOT_IN_INSTANCE, sObjectMgr, Player::SpawnCorpseBones(), sWorld, TRANSFER_ABORT_DIFFICULTY, and TRANSFER_ABORT_TOO_MANY_INSTANCES.
|
private |
Definition at line 63 of file MapManager.cpp.
References i_GridStateErrorCount, i_GridStates, MAX_GRID_STATE, SF_LOG_ERROR, and si_GridStates.
Definition at line 87 of file MapManager.cpp.
References ASSERT, CreateBaseMap(), DIFFICULTY_NONE, MapEntry::entrance_map, FindBaseMap(), i_gridCleanUpDelay, i_maps, MapEntry::Instanceable(), Map::LoadRespawnTimes(), Lock, MapEntry::MapID, sMapStore, and sTransportMgr.
Referenced by CreateBaseMap(), CreateMap(), and GetAreaFlag().
Definition at line 152 of file MapManager.cpp.
References CreateBaseMap(), and Map::Instanceable().
| void MapManager::DoDelayedMovesAndRemoves | ( | ) |
Definition at line 319 of file MapManager.cpp.
|
static |
Definition at line 321 of file MapManager.cpp.
References Skyfire::ComputeGridCoord(), Map::ExistMap(), Map::ExistVMap(), CoordPair< LIMIT >::x_coord, and CoordPair< LIMIT >::y_coord.
Referenced by World::SetInitialWorldSettings().
Definition at line 127 of file MapManager.h.
References i_maps.
Referenced by CreateBaseMap(), FindBaseNonInstanceMap(), and FindMap().
Definition at line 144 of file MapManager.cpp.
References FindBaseMap(), and Map::Instanceable().
Definition at line 162 of file MapManager.cpp.
References FindBaseMap(), and Map::Instanceable().
| void MapManager::FreeInstanceId | ( | uint32 | instanceId | ) |
Definition at line 450 of file MapManager.cpp.
References _instanceIds, _nextInstanceId, and SetNextInstanceId().
| uint32 MapManager::GenerateInstanceId | ( | ) |
Definition at line 413 of file MapManager.cpp.
References _instanceIds, _nextInstanceId, ERROR_EXIT_CODE, SF_LOG_ERROR, and World::StopNow().
Definition at line 31 of file MapManager.h.
References CreateBaseMap(), Map::GetAreaFlag(), GetAreaFlag(), and MapManager().
Referenced by GetAreaFlag(), GetAreaId(), GetZoneAndAreaId(), and GetZoneId().
Definition at line 36 of file MapManager.h.
References GetAreaFlag(), and Map::GetAreaIdByAreaFlag().
|
inline |
Definition at line 113 of file MapManager.h.
References m_updater.
|
inline |
Definition at line 110 of file MapManager.h.
References _nextInstanceId.
| uint32 MapManager::GetNumInstances | ( | ) |
Definition at line 358 of file MapManager.cpp.
References i_maps, Map::Instanceable(), and Lock.
| uint32 MapManager::GetNumPlayersInInstances | ( | ) |
Definition at line 375 of file MapManager.cpp.
References i_maps, Map::Instanceable(), and Lock.
|
inline |
Definition at line 44 of file MapManager.h.
References GetAreaFlag(), and Map::GetZoneAndAreaIdByAreaFlag().
Definition at line 40 of file MapManager.h.
References GetAreaFlag(), and Map::GetZoneIdByAreaFlag().
| void MapManager::Initialize | ( | void | ) |
Definition at line 39 of file MapManager.cpp.
References CONFIG_NUMTHREADS, i_GridStateErrorCount, i_GridStates, Map::InitStateMachine(), m_updater, MAX_GRID_STATE, si_GridStates, and sWorld.
| void MapManager::InitializeVisibilityDistanceInfo | ( | ) |
Definition at line 56 of file MapManager.cpp.
References i_maps.
| void MapManager::InitInstanceIds | ( | ) |
Definition at line 393 of file MapManager.cpp.
References _instanceIds, _nextInstanceId, and CharacterDatabase.
|
static |
Definition at line 331 of file MapManager.cpp.
References MapEntry::IsInstance(), sMapStore, and sObjectMgr.
Referenced by IsValidMapCoord(), IsValidMapCoord(), IsValidMapCoord(), and ObjectMgr::LoadInstanceTemplate().
|
inlinestatic |
Definition at line 75 of file MapManager.h.
References IsValidMAP(), and Skyfire::IsValidMapCoord().
Referenced by Player::_LoadHomeBind(), gobject_commandscript::HandleGameObjectMoveCommand(), go_commandscript::HandleGoCreatureCommand(), go_commandscript::HandleGoGraveyardCommand(), go_commandscript::HandleGoGridCommand(), go_commandscript::HandleGoObjectCommand(), go_commandscript::HandleGoTaxinodeCommand(), go_commandscript::HandleGoTriggerCommand(), go_commandscript::HandleGoXYZCommand(), go_commandscript::HandleGoZoneXYCommand(), WorldSession::HandleMoveWorldportAckOpcode(), IsValidMapCoord(), ObjectMgr::LoadGameobjects(), ObjectMgr::LoadGameTele(), ObjectMgr::LoadPlayerInfo(), LuaPlayer::SummonPlayer(), lfg::LFGMgr::TeleportPlayer(), and Player::TeleportTo().
|
inlinestatic |
Definition at line 80 of file MapManager.h.
References IsValidMAP(), and Skyfire::IsValidMapCoord().
|
inlinestatic |
Definition at line 85 of file MapManager.h.
References IsValidMAP(), and Skyfire::IsValidMapCoord().
|
inlinestatic |
Definition at line 90 of file MapManager.h.
References WorldLocation::GetMapId(), Position::GetOrientation(), Position::GetPositionX(), Position::GetPositionY(), Position::GetPositionZ(), and IsValidMapCoord().
|
private |
References MapManager().
| void MapManager::RegisterInstanceId | ( | uint32 | instanceId | ) |
Definition at line 407 of file MapManager.cpp.
References _instanceIds.
|
inline |
Definition at line 52 of file MapManager.h.
References i_gridCleanUpDelay, and MIN_GRID_DELAY.
|
inline |
Definition at line 60 of file MapManager.h.
References i_timer, and MIN_MAP_UPDATE_DELAY.
|
inline |
Definition at line 111 of file MapManager.h.
References _nextInstanceId.
Referenced by FreeInstanceId().
| void MapManager::UnloadAll | ( | ) |
Definition at line 343 of file MapManager.cpp.
References Map::DeleteStateMachine(), i_maps, and m_updater.
| void MapManager::Update | ( | uint32 | diff | ) |
Definition at line 292 of file MapManager.cpp.
References Skyfire::Diagnostics::GetRuntimeMetrics(), i_maps, i_timer, m_updater, Skyfire::Diagnostics::RuntimeMetrics::RecordMapUpdatePass(), and sObjectAccessor.
|
friend |
Definition at line 1 of file MapManager.h.
|
private |
Definition at line 141 of file MapManager.h.
Referenced by FreeInstanceId(), GenerateInstanceId(), InitInstanceIds(), and RegisterInstanceId().
|
private |
Definition at line 142 of file MapManager.h.
Referenced by FreeInstanceId(), GenerateInstanceId(), GetNextInstanceId(), InitInstanceIds(), MapManager(), and SetNextInstanceId().
|
private |
Definition at line 137 of file MapManager.h.
Referenced by CreateBaseMap(), MapManager(), and SetGridCleanUpDelay().
|
private |
Definition at line 122 of file MapManager.h.
Referenced by checkAndCorrectGridStatesArray(), Initialize(), and MapManager().
|
private |
Definition at line 121 of file MapManager.h.
Referenced by checkAndCorrectGridStatesArray(), and Initialize().
|
private |
Definition at line 138 of file MapManager.h.
Referenced by CreateBaseMap(), FindBaseMap(), GetNumInstances(), GetNumPlayersInInstances(), InitializeVisibilityDistanceInfo(), UnloadAll(), and Update().
|
private |
Definition at line 139 of file MapManager.h.
Referenced by MapManager(), SetMapUpdateInterval(), and Update().
|
private |
Definition at line 136 of file MapManager.h.
Referenced by CreateBaseMap(), GetNumInstances(), and GetNumPlayersInInstances().
|
private |
Definition at line 143 of file MapManager.h.
Referenced by GetMapUpdater(), Initialize(), UnloadAll(), and Update().