[8403] Fixed cast spell opcode parsing for some cases with additional data.

This commit is contained in:
VladimirMangos 2009-08-22 04:44:51 +04:00
parent 38fa6b241c
commit 6ced2e979d
3 changed files with 30 additions and 1 deletions

View file

@ -234,7 +234,10 @@ void WorldSession::HandleMovementOpcodes( WorldPacket & recv_data )
}
if (!MaNGOS::IsValidMapCoord(movementInfo.x, movementInfo.y, movementInfo.z, movementInfo.o))
{
recv_data.rpos(recv_data.wpos()); // prevent warnings spam
return;
}
/* handle special cases */
if (movementInfo.HasMovementFlag(MOVEMENTFLAG_ONTRANSPORT))
@ -242,11 +245,17 @@ void WorldSession::HandleMovementOpcodes( WorldPacket & recv_data )
// transports size limited
// (also received at zeppelin leave by some reason with t_* as absolute in continent coordinates, can be safely skipped)
if( movementInfo.t_x > 50 || movementInfo.t_y > 50 || movementInfo.t_z > 50 )
{
recv_data.rpos(recv_data.wpos()); // prevent warnings spam
return;
}
if( !MaNGOS::IsValidMapCoord(movementInfo.x+movementInfo.t_x, movementInfo.y + movementInfo.t_y,
movementInfo.z + movementInfo.t_z, movementInfo.o + movementInfo.t_o) )
{
recv_data.rpos(recv_data.wpos()); // prevent warnings spam
return;
}
// if we boarded a transport, add us to it
if (plMover && !plMover->m_transport)