fix(Core/Movement): set proper flying animations for creatures with INHABIT_GROUND (#7589)
- Closes #7579
This commit is contained in:
parent
d97863dc6c
commit
7965ea5aaa
1 changed files with 8 additions and 0 deletions
|
|
@ -3108,7 +3108,10 @@ void Creature::UpdateMovementFlags()
|
|||
if (isInAir && !IsFalling())
|
||||
{
|
||||
if (info->InhabitType & INHABIT_GROUND)
|
||||
{
|
||||
SetCanFly(true);
|
||||
SetByteValue(UNIT_FIELD_BYTES_1, UNIT_BYTES_1_OFFSET_ANIM_TIER, UNIT_BYTE1_FLAG_FLY);
|
||||
}
|
||||
else
|
||||
SetDisableGravity(true);
|
||||
|
||||
|
|
@ -3120,6 +3123,11 @@ void Creature::UpdateMovementFlags()
|
|||
SetCanFly(false);
|
||||
SetDisableGravity(false);
|
||||
|
||||
if (info->InhabitType & INHABIT_GROUND)
|
||||
{
|
||||
SetByteValue(UNIT_FIELD_BYTES_1, UNIT_BYTES_1_OFFSET_ANIM_TIER, UNIT_BYTE1_FLAG_GROUND);
|
||||
}
|
||||
|
||||
if (IsAlive() && (CanHover() || HasAuraType(SPELL_AURA_HOVER)))
|
||||
SetHover(true);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue