mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-16 07:30:42 +01:00
Core/Movement: Do not remove movement flags that have special opcodes associated with them on teleport
Closes #10162
This commit is contained in:
@@ -2130,7 +2130,7 @@ bool Player::TeleportTo(uint32 mapid, float x, float y, float z, float orientati
|
||||
ExitVehicle();
|
||||
|
||||
// reset movement flags at teleport, because player will continue move with these flags after teleport
|
||||
SetUnitMovementFlags(0);
|
||||
SetUnitMovementFlags(GetUnitMovementFlags() & MOVEMENTFLAG_MASK_HAS_PLAYER_STATUS_OPCODE);
|
||||
DisableSpline();
|
||||
|
||||
if (m_transport)
|
||||
|
||||
@@ -735,8 +735,13 @@ enum MovementFlags
|
||||
|
||||
/// @todo if needed: add more flags to this masks that are exclusive to players
|
||||
MOVEMENTFLAG_MASK_PLAYER_ONLY =
|
||||
MOVEMENTFLAG_FLYING
|
||||
MOVEMENTFLAG_FLYING,
|
||||
|
||||
/// Movement flags that have change status opcodes associated for players
|
||||
MOVEMENTFLAG_MASK_HAS_PLAYER_STATUS_OPCODE = MOVEMENTFLAG_DISABLE_GRAVITY | MOVEMENTFLAG_ROOT |
|
||||
MOVEMENTFLAG_CAN_FLY | MOVEMENTFLAG_WATERWALKING | MOVEMENTFLAG_FALLING_SLOW | MOVEMENTFLAG_HOVER
|
||||
};
|
||||
|
||||
enum MovementFlags2
|
||||
{
|
||||
MOVEMENTFLAG2_NONE = 0x00000000,
|
||||
|
||||
Reference in New Issue
Block a user