Core/Movement: Fixed players being able to control their characters after teleporting to a different map while feared or confused
(cherry picked from commit e5bee26e2ef5c48e1fabf21174e265d1f6cc9252)
This commit is contained in:
@@ -25061,7 +25061,7 @@ void Player::SendInitialPacketsAfterAddToMap()
|
|||||||
// same auras state lost at far teleport, send it one more time in this case also
|
// same auras state lost at far teleport, send it one more time in this case also
|
||||||
static constexpr AuraType auratypes[] =
|
static constexpr AuraType auratypes[] =
|
||||||
{
|
{
|
||||||
SPELL_AURA_MOD_FEAR, SPELL_AURA_TRANSFORM, SPELL_AURA_WATER_WALK,
|
SPELL_AURA_TRANSFORM, SPELL_AURA_WATER_WALK,
|
||||||
SPELL_AURA_FEATHER_FALL, SPELL_AURA_HOVER, SPELL_AURA_SAFE_FALL,
|
SPELL_AURA_FEATHER_FALL, SPELL_AURA_HOVER, SPELL_AURA_SAFE_FALL,
|
||||||
SPELL_AURA_FLY, SPELL_AURA_MOD_INCREASE_MOUNTED_FLIGHT_SPEED, SPELL_AURA_ADV_FLYING
|
SPELL_AURA_FLY, SPELL_AURA_MOD_INCREASE_MOUNTED_FLIGHT_SPEED, SPELL_AURA_ADV_FLYING
|
||||||
};
|
};
|
||||||
@@ -25107,6 +25107,9 @@ void Player::SendInitialPacketsAfterAddToMap()
|
|||||||
SendDirectMessage(setCompoundState.Write());
|
SendDirectMessage(setCompoundState.Write());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (HasUnitState(UNIT_STATE_FLEEING | UNIT_STATE_CONFUSED) || HasAuraType(SPELL_AURA_MOD_CONFUSE) || HasAuraType(SPELL_AURA_MOD_FEAR))
|
||||||
|
SetClientControl(this, false);
|
||||||
|
|
||||||
SendAurasForTarget(this);
|
SendAurasForTarget(this);
|
||||||
SendEnchantmentDurations(); // must be after add to map
|
SendEnchantmentDurations(); // must be after add to map
|
||||||
SendItemDurations(); // must be after add to map
|
SendItemDurations(); // must be after add to map
|
||||||
|
|||||||
Reference in New Issue
Block a user