Skip to content

Commit

Permalink
Implement AURA_INTERRUPT_FLAG_LANDING Fixes auto-off parachutes
Browse files Browse the repository at this point in the history
(based on cmangos/mangos-wotlk@b80a10e96)

Signed-off-by: Xfurry <xfurry.cmangos@outlook.com>
  • Loading branch information
boxa authored and xfurry committed Dec 10, 2017
1 parent c8868d5 commit 3ecd445
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions src/game/MovementHandler.cpp
Expand Up @@ -335,6 +335,10 @@ void WorldSession::HandleMovementOpcodes(WorldPacket& recv_data)
if (opcode == CMSG_MOVE_FALL_LAND && plMover && !plMover->IsTaxiFlying())
plMover->HandleFall(movementInfo);

// Remove auras that should be removed at landing on ground or water
if (opcode == MSG_MOVE_FALL_LAND || opcode == MSG_MOVE_START_SWIM)
mover->RemoveAurasWithInterruptFlags(AURA_INTERRUPT_FLAG_LANDING); // Parachutes

/* process position-change */
HandleMoverRelocation(movementInfo);

Expand Down
2 changes: 1 addition & 1 deletion src/game/Unit.h
Expand Up @@ -91,7 +91,7 @@ enum SpellAuraInterruptFlags
AURA_INTERRUPT_FLAG_TELEPORTED = 0x00400000, // 22
AURA_INTERRUPT_FLAG_ENTER_PVP_COMBAT = 0x00800000, // 23 removed by entering pvp combat
AURA_INTERRUPT_FLAG_DIRECT_DAMAGE = 0x01000000, // 24 removed by any direct damage
AURA_INTERRUPT_FLAG_UNK25 = 0x02000000, // 25
AURA_INTERRUPT_FLAG_LANDING = 0x02000000, // 25 removed by hitting the ground or water
AURA_INTERRUPT_FLAG_UNK26 = 0x04000000, // 26
AURA_INTERRUPT_FLAG_DAMAGE2 = 0x08000000, // 27 removed by damage spells + removed by damage, other than .. (diseases, Censure)
AURA_INTERRUPT_FLAG_ENTER_COMBAT2 = 0x10000000, // 28
Expand Down

0 comments on commit 3ecd445

Please sign in to comment.