From 408b490851628a55720dd6c5d1bf0b7fd0cb0b83 Mon Sep 17 00:00:00 2001 From: Shauren Date: Sun, 6 Jul 2014 00:01:24 +0200 Subject: Scripts/Magister's Terrace: Fixed typo in SetEncounterState --- .../EasternKingdoms/MagistersTerrace/instance_magisters_terrace.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/server/scripts/EasternKingdoms/MagistersTerrace/instance_magisters_terrace.cpp b/src/server/scripts/EasternKingdoms/MagistersTerrace/instance_magisters_terrace.cpp index e0050420a08..1f8ccfbd5d8 100644 --- a/src/server/scripts/EasternKingdoms/MagistersTerrace/instance_magisters_terrace.cpp +++ b/src/server/scripts/EasternKingdoms/MagistersTerrace/instance_magisters_terrace.cpp @@ -159,7 +159,7 @@ class instance_magisters_terrace : public InstanceMapScript switch (type) { case DATA_DELRISSA: - if (type == IN_PROGRESS) + if (state == IN_PROGRESS) DelrissaDeathCount = 0; break; default: -- cgit v1.2.3 From 0f8c1d4a475f9779fd2bd1f76763b7407adcd33e Mon Sep 17 00:00:00 2001 From: jackpoz Date: Sun, 6 Jul 2014 18:27:32 +0200 Subject: Core/Maps: Don't load vmaps/mmaps if disabled in configs Don't try to load vmaps/mmaps if they are disabled in the configs. Fixes #12392 --- src/server/game/Maps/Map.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src') diff --git a/src/server/game/Maps/Map.cpp b/src/server/game/Maps/Map.cpp index 01e3af149dc..a49e69ec311 100644 --- a/src/server/game/Maps/Map.cpp +++ b/src/server/game/Maps/Map.cpp @@ -119,6 +119,9 @@ bool Map::ExistVMap(uint32 mapid, int gx, int gy) void Map::LoadMMap(int gx, int gy) { + if (!MMAP::MMapFactory::IsPathfindingEnabled(GetId())) + return; + bool mmapLoadResult = MMAP::MMapFactory::createOrGetMMapManager()->loadMap((sWorld->GetDataPath() + "mmaps").c_str(), GetId(), gx, gy); if (mmapLoadResult) @@ -129,6 +132,8 @@ void Map::LoadMMap(int gx, int gy) void Map::LoadVMap(int gx, int gy) { + if (!VMAP::VMapFactory::createOrGetVMapManager()->isMapLoadingEnabled()) + return; // x and y are swapped !! int vmapLoadResult = VMAP::VMapFactory::createOrGetVMapManager()->loadMap((sWorld->GetDataPath()+ "vmaps").c_str(), GetId(), gx, gy); switch (vmapLoadResult) -- cgit v1.2.3 From a6494375f9839b8c428c8daa508b9ca93caa0575 Mon Sep 17 00:00:00 2001 From: jackpoz Date: Sun, 6 Jul 2014 18:32:27 +0200 Subject: Core/Wintergrasp: Spawn npcs only after initial map configs have been set Spawn BATTLEFIELD_WG_NPC_STALKER only after the MapID has been set otherwise it will try to spawn it on map 0 --- src/server/game/Battlefield/Zones/BattlefieldWG.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/server/game/Battlefield/Zones/BattlefieldWG.cpp b/src/server/game/Battlefield/Zones/BattlefieldWG.cpp index 5555f2a824c..41539b9cda6 100644 --- a/src/server/game/Battlefield/Zones/BattlefieldWG.cpp +++ b/src/server/game/Battlefield/Zones/BattlefieldWG.cpp @@ -41,14 +41,14 @@ BattlefieldWG::~BattlefieldWG() bool BattlefieldWG::SetupBattlefield() { - InitStalker(BATTLEFIELD_WG_NPC_STALKER, WintergraspStalkerPos[0], WintergraspStalkerPos[1], WintergraspStalkerPos[2], WintergraspStalkerPos[3]); - m_TypeId = BATTLEFIELD_WG; // See enum BattlefieldTypes m_BattleId = BATTLEFIELD_BATTLEID_WG; m_ZoneId = BATTLEFIELD_WG_ZONEID; m_MapId = BATTLEFIELD_WG_MAPID; m_Map = sMapMgr->FindMap(m_MapId, 0); + InitStalker(BATTLEFIELD_WG_NPC_STALKER, WintergraspStalkerPos[0], WintergraspStalkerPos[1], WintergraspStalkerPos[2], WintergraspStalkerPos[3]); + m_MaxPlayer = sWorld->getIntConfig(CONFIG_WINTERGRASP_PLR_MAX); m_IsEnabled = sWorld->getBoolConfig(CONFIG_WINTERGRASP_ENABLE); m_MinPlayer = sWorld->getIntConfig(CONFIG_WINTERGRASP_PLR_MIN); -- cgit v1.2.3