aboutsummaryrefslogtreecommitdiff
path: root/src/game/Creature.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/game/Creature.cpp')
-rw-r--r--src/game/Creature.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/game/Creature.cpp b/src/game/Creature.cpp
index 3d11c4a0941..330c93429b6 100644
--- a/src/game/Creature.cpp
+++ b/src/game/Creature.cpp
@@ -2185,6 +2185,9 @@ bool Creature::canCreatureAttack(Unit const *pVictim, bool force) const
if(!pVictim->isInAccessiblePlaceFor(this))
return false;
+ if(!AI()->CanAIAttack(pVictim))
+ return false;
+
if(sMapStore.LookupEntry(GetMapId())->IsDungeon())
return true;