aboutsummaryrefslogtreecommitdiff
path: root/src/server/game/Maps/Map.cpp
diff options
context:
space:
mode:
authorSebastian Valle <s.v.h21@hotmail.com>2013-10-04 22:23:17 -0500
committerSebastian Valle <s.v.h21@hotmail.com>2013-10-04 22:23:17 -0500
commita27237dedd1b770ab4e66570e7a236a44d2c9e00 (patch)
tree55dc122371571e055b9c6da07aae2d5a9e7e39d3 /src/server/game/Maps/Map.cpp
parente62f64b5912fb1b249680d0bd026b8e4c7d7a022 (diff)
Core/MMaps: MMaps are now correctly loaded into TC
P.S: They do behave better in some places, but are still a bit weird in some others, will have to look into that. P.P.S: I'll have to re-implement all the previous PathGenerator code
Diffstat (limited to 'src/server/game/Maps/Map.cpp')
-rw-r--r--src/server/game/Maps/Map.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/server/game/Maps/Map.cpp b/src/server/game/Maps/Map.cpp
index 3156a071854..aaeb06462ef 100644
--- a/src/server/game/Maps/Map.cpp
+++ b/src/server/game/Maps/Map.cpp
@@ -121,7 +121,11 @@ bool Map::ExistVMap(uint32 mapid, int gx, int gy)
void Map::LoadMMap(int gx, int gy)
{
- bool mmapLoadResult = MMAP::MMapFactory::CreateOrGetMMapManager()->LoadMapTile(GetId(), gx, gy);
+ bool mmapLoadResult = false;
+ if (GetEntry()->Instanceable())
+ mmapLoadResult = MMAP::MMapFactory::CreateOrGetMMapManager()->LoadMapTile(GetId(), 0, 0); // Ignore the tile entry for instances, as they only have 1 tile.
+ else
+ mmapLoadResult = MMAP::MMapFactory::CreateOrGetMMapManager()->LoadMapTile(GetId(), gx, gy);
if (mmapLoadResult)
TC_LOG_INFO(LOG_FILTER_MAPS, "MMAP loaded name: %s, id: %d, x: %d, y: %d", GetMapName(), GetId(), gx, gy);