aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/server/scripts/Pet/pet_mage.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/server/scripts/Pet/pet_mage.cpp b/src/server/scripts/Pet/pet_mage.cpp
index f626159a650..d1cedaa0e69 100644
--- a/src/server/scripts/Pet/pet_mage.cpp
+++ b/src/server/scripts/Pet/pet_mage.cpp
@@ -174,7 +174,7 @@ class npc_pet_mage_mirror_image : public CreatureScript
bool CanAIAttack(Unit const* who) const override
{
Unit* owner = me->GetOwner();
- return owner && who->IsAlive() &&
+ return owner && who->IsAlive() && me->IsValidAttackTarget(who) &&
!who->HasBreakableByDamageCrowdControlAura() &&
who->IsInCombatWith(owner) && ScriptedAI::CanAIAttack(who);
}