Skip to content

Commit

Permalink
[10659] Fixed mistake in [10653] that causes player to fall from the …
Browse files Browse the repository at this point in the history
…transport at teleporting to another map
  • Loading branch information
SilverIce committed Oct 31, 2010
1 parent 1c1402c commit 0d13d5d
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 8 deletions.
17 changes: 10 additions & 7 deletions src/game/MovementHandler.cpp
Expand Up @@ -518,16 +518,19 @@ void WorldSession::HandleMoverRelocation(MovementInfo& movementInfo, Unit* mover

if (plMover)
{
if (movementInfo.HasMovementFlag(MOVEFLAG_ONTRANSPORT) && !plMover->m_transport)
if (movementInfo.HasMovementFlag(MOVEFLAG_ONTRANSPORT))
{
// elevators also cause the client to send MOVEFLAG_ONTRANSPORT - just unmount if the guid can be found in the transport list
for (MapManager::TransportSet::const_iterator iter = sMapMgr.m_Transports.begin(); iter != sMapMgr.m_Transports.end(); ++iter)
if (!plMover->m_transport)
{
if ((*iter)->GetObjectGuid() == movementInfo.GetTransportGuid())
// elevators also cause the client to send MOVEFLAG_ONTRANSPORT - just unmount if the guid can be found in the transport list
for (MapManager::TransportSet::const_iterator iter = sMapMgr.m_Transports.begin(); iter != sMapMgr.m_Transports.end(); ++iter)
{
plMover->m_transport = (*iter);
(*iter)->AddPassenger(plMover);
break;
if ((*iter)->GetObjectGuid() == movementInfo.GetTransportGuid())
{
plMover->m_transport = (*iter);
(*iter)->AddPassenger(plMover);
break;
}
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/shared/revision_nr.h
@@ -1,4 +1,4 @@
#ifndef __REVISION_NR_H__
#define __REVISION_NR_H__
#define REVISION_NR "10658"
#define REVISION_NR "10659"
#endif // __REVISION_NR_H__

0 comments on commit 0d13d5d

Please sign in to comment.