mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-17 19:05:42 +00:00
fix(Core/Spells): implicit target selection for chain spells that should ignore crowd controlled targets (#20068)
replace free to move with ownerGUID check with crowd control check
This commit is contained in:
@@ -1870,7 +1870,7 @@ SpellCastResult SpellInfo::CheckTarget(Unit const* caster, WorldObject const* ta
|
||||
return SPELL_FAILED_TARGETS_DEAD;
|
||||
|
||||
// check this flag only for implicit targets (chain and area), allow to explicitly target units for spells like Shield of Righteousness
|
||||
if (implicit && AttributesEx6 & SPELL_ATTR6_DO_NOT_CHAIN_TO_CROWD_CONTROLLED_TARGETS && !unitTarget->CanFreeMove())
|
||||
if (implicit && AttributesEx6 & SPELL_ATTR6_DO_NOT_CHAIN_TO_CROWD_CONTROLLED_TARGETS && unitTarget->HasUnitState(UNIT_STATE_CONTROLLED))
|
||||
return SPELL_FAILED_BAD_TARGETS;
|
||||
|
||||
// checked in Unit::IsValidAttack/AssistTarget, shouldn't be checked for ENTRY targets
|
||||
|
||||
Reference in New Issue
Block a user