Core/Maps: Improvements to terrain swap handling

* Fixed memory leak when unloading grids
* Handle child maps being entered
* Allow chaining more child maps (Draenor -> Tanaan Jungle -> Tanaan Jungle - No Hubs Phase)
This commit is contained in:
Shauren authored and Ovahlord committed 2020-06-11 01:35:27 +02:00
1 parent 8adca7637b
commit 40f80fc0ed
13 files changed
+185 -159

No files matched your search

+1 -1
View File
@@ -442,7 +442,7 @@ void WorldSession::HandleMovementOpcode(uint16 opcode, MovementInfo& movementInf
plrMover->UpdateFallInformationIfNeed(movementInfo, opcode);
if (movementInfo.pos.GetPositionZ() < plrMover->GetMap()->GetMinHeight(movementInfo.pos.GetPositionX(), movementInfo.pos.GetPositionY()))
if (movementInfo.pos.GetPositionZ() < plrMover->GetMap()->GetMinHeight(plrMover->GetPhaseShift(), movementInfo.pos.GetPositionX(), movementInfo.pos.GetPositionY()))
{
if (!(plrMover->GetBattleground() && plrMover->GetBattleground()->HandlePlayerUnderMap(_player)))
{