diff options
author | Machiavelli <machiavelli.trinity@gmail.com> | 2011-12-10 15:21:55 +0100 |
---|---|---|
committer | Machiavelli <machiavelli.trinity@gmail.com> | 2011-12-10 15:21:55 +0100 |
commit | b1c8226d58ecdda9a9af5b4e3e8d88c1d44f589f (patch) | |
tree | ed9d70ffb03d5a85fd8abe4ea618a20a5b297635 /src/server/game/Maps/Map.cpp | |
parent | fe69bd654a424f560f37774d5c3e763fd6589607 (diff) | |
parent | 11fb0beaf0cb877b14f24aa88f19832e0aa3dc88 (diff) |
Merge branch 'master' of github.com:TrinityCore/TrinityCore into 4.x
Diffstat (limited to 'src/server/game/Maps/Map.cpp')
-rwxr-xr-x | src/server/game/Maps/Map.cpp | 31 |
1 files changed, 13 insertions, 18 deletions
diff --git a/src/server/game/Maps/Map.cpp b/src/server/game/Maps/Map.cpp index 4b21f1c7d7d..34bc5f141f2 100755 --- a/src/server/game/Maps/Map.cpp +++ b/src/server/game/Maps/Map.cpp @@ -685,8 +685,7 @@ void Map::RemoveFromMap(T *obj, bool remove) } } -void -Map::PlayerRelocation(Player* player, float x, float y, float z, float orientation) +void Map::PlayerRelocation(Player* player, float x, float y, float z, float orientation) { ASSERT(player); @@ -710,8 +709,7 @@ Map::PlayerRelocation(Player* player, float x, float y, float z, float orientati player->UpdateObjectVisibility(false); } -void -Map::CreatureRelocation(Creature* creature, float x, float y, float z, float ang, bool respawnRelocationOnFail) +void Map::CreatureRelocation(Creature* creature, float x, float y, float z, float ang, bool respawnRelocationOnFail) { ASSERT(CheckGridIntegrity(creature, false)); @@ -1161,7 +1159,7 @@ bool GridMap::loadHeihgtData(FILE* in, uint32 offset, uint32 /*size*/) return true; } -bool GridMap::loadLiquidData(FILE* in, uint32 offset, uint32 /*size*/) +bool GridMap::loadLiquidData(FILE* in, uint32 offset, uint32 /*size*/) { map_liquidHeader header; fseek(in, offset, SEEK_SET); @@ -1203,12 +1201,12 @@ uint16 GridMap::getArea(float x, float y) return m_area_map[lx*16 + ly]; } -float GridMap::getHeightFromFlat(float /*x*/, float /*y*/) const +float GridMap::getHeightFromFlat(float /*x*/, float /*y*/) const { return m_gridHeight; } -float GridMap::getHeightFromFloat(float x, float y) const +float GridMap::getHeightFromFloat(float x, float y) const { if (!m_V8 || !m_V9) return m_gridHeight; @@ -1290,7 +1288,7 @@ float GridMap::getHeightFromFloat(float x, float y) const return a * x + b * y + c; } -float GridMap::getHeightFromUint8(float x, float y) const +float GridMap::getHeightFromUint8(float x, float y) const { if (!m_uint8_V8 || !m_uint8_V9) return m_gridHeight; @@ -1357,7 +1355,7 @@ float GridMap::getHeightFromUint8(float x, float y) const return (float)((a * x) + (b * y) + c)*m_gridIntHeightMultiplier + m_gridHeight; } -float GridMap::getHeightFromUint16(float x, float y) const +float GridMap::getHeightFromUint16(float x, float y) const { if (!m_uint16_V8 || !m_uint16_V9) return m_gridHeight; @@ -1424,7 +1422,7 @@ float GridMap::getHeightFromUint16(float x, float y) const return (float)((a * x) + (b * y) + c)*m_gridIntHeightMultiplier + m_gridHeight; } -float GridMap::getLiquidLevel(float x, float y) +float GridMap::getLiquidLevel(float x, float y) { if (!m_liquid_map) return m_liquidLevel; @@ -1443,7 +1441,7 @@ float GridMap::getLiquidLevel(float x, float y) return m_liquid_map[cx_int*m_liquid_width + cy_int]; } -uint8 GridMap::getTerrainType(float x, float y) +uint8 GridMap::getTerrainType(float x, float y) { if (!m_liquid_type) return 0; @@ -1826,7 +1824,7 @@ bool Map::CheckGridIntegrity(Creature* c, bool moved) const return true; } -const char* Map::GetMapName() const +char const* Map::GetMapName() const { return i_mapEntry ? i_mapEntry->name : "UNNAMEDMAP\x0"; } @@ -2623,20 +2621,17 @@ void BattlegroundMap::RemoveAllPlayers() player->TeleportTo(player->GetBattlegroundEntryPoint()); } -Creature* -Map::GetCreature(uint64 guid) +Creature* Map::GetCreature(uint64 guid) { return ObjectAccessor::GetObjectInMap(guid, this, (Creature*)NULL); } -GameObject* -Map::GetGameObject(uint64 guid) +GameObject* Map::GetGameObject(uint64 guid) { return ObjectAccessor::GetObjectInMap(guid, this, (GameObject*)NULL); } -DynamicObject* -Map::GetDynamicObject(uint64 guid) +DynamicObject* Map::GetDynamicObject(uint64 guid) { return ObjectAccessor::GetObjectInMap(guid, this, (DynamicObject*)NULL); } |