aboutsummaryrefslogtreecommitdiff
path: root/src/server/game/Globals/ObjectMgr.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/server/game/Globals/ObjectMgr.cpp')
-rw-r--r--src/server/game/Globals/ObjectMgr.cpp45
1 files changed, 5 insertions, 40 deletions
diff --git a/src/server/game/Globals/ObjectMgr.cpp b/src/server/game/Globals/ObjectMgr.cpp
index f5e93ede9af..13e390bc362 100644
--- a/src/server/game/Globals/ObjectMgr.cpp
+++ b/src/server/game/Globals/ObjectMgr.cpp
@@ -279,7 +279,6 @@ ObjectMgr::~ObjectMgr()
itr->second.Clear();
_cacheTrainerSpellStore.clear();
- _graveyardOrientations.clear();
for (DungeonEncounterContainer::iterator itr =_dungeonEncounterStore.begin(); itr != _dungeonEncounterStore.end(); ++itr)
for (DungeonEncounterList::iterator encounterItr = itr->second.begin(); encounterItr != itr->second.end(); ++encounterItr)
@@ -300,34 +299,6 @@ void ObjectMgr::AddLocaleString(std::string const& s, LocaleConstant locale, Str
}
}
-void ObjectMgr::LoadGraveyardOrientations()
-{
- uint32 oldMSTime = getMSTime();
-
- _graveyardOrientations.clear();
-
- QueryResult result = WorldDatabase.Query("SELECT id, orientation FROM graveyard_orientation");
-
- if (!result)
- return;
-
- do
- {
- Field* fields = result->Fetch();
-
- uint32 id = fields[0].GetUInt32();
- if (!sWorldSafeLocsStore.LookupEntry(id))
- {
- TC_LOG_ERROR("server.loading", "Graveyard %u referenced in graveyard_orientation doesn't exist.", id);
- continue;
- }
- _graveyardOrientations[id] = fields[1].GetFloat();
-
- } while (result->NextRow());
-
- TC_LOG_INFO("server.loading", ">> Loaded %lu graveyard orientations in %u ms", (unsigned long)_graveyardOrientations.size(), GetMSTimeDiffToNow(oldMSTime));
-}
-
void ObjectMgr::LoadCreatureLocales()
{
uint32 oldMSTime = getMSTime();
@@ -6204,19 +6175,13 @@ void ObjectMgr::LoadAreaTriggerTeleports()
continue;
}
- WorldSafeLocsEntry const* MapID = sWorldSafeLocsStore.LookupEntry(PortLocID);
- WorldSafeLocsEntry const* PositionX = sWorldSafeLocsStore.LookupEntry(PortLocID);
- WorldSafeLocsEntry const* PositionY = sWorldSafeLocsStore.LookupEntry(PortLocID);
- WorldSafeLocsEntry const* PositionZ = sWorldSafeLocsStore.LookupEntry(PortLocID);
- WorldSafeLocsEntry const* Orientation = sWorldSafeLocsStore.LookupEntry(PortLocID);
-
AreaTriggerStruct at;
- at.target_mapId = MapID->map_id;
- at.target_X = PositionX->x;
- at.target_Y = PositionY->y;
- at.target_Z = PositionZ->z;
- at.target_Orientation = ((Orientation->Facing) * M_PI) / 180; // Orientation is initially in degrees
+ at.target_mapId = portLoc->map_id;
+ at.target_X = portLoc->x;
+ at.target_Y = portLoc->y;
+ at.target_Z = portLoc->z;
+ at.target_Orientation = (portLoc->Facing * M_PI) / 180; // Orientation is initially in degrees
AreaTriggerEntry const* atEntry = sAreaTriggerStore.LookupEntry(Trigger_ID);
if (!atEntry)