Core/Spells: check UNIT_FLAG_OOC_NOT_ATTACKABLE only for AOE spells targeting enemies, fixes some interactions with npcs.

This commit is contained in:
QAston
2011-08-20 12:08:37 +02:00
parent 919a8ecf0e
commit b838aad7d0
3 changed files with 4 additions and 2 deletions
+3
View File
@@ -727,6 +727,9 @@ namespace Trinity
case SPELL_TARGETS_ENEMY:
if (target->isTotem())
continue;
// can't be checked in SpellInfo::CheckTarget - needs more research
if (target->HasFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_OOC_NOT_ATTACKABLE))
continue;
if (i_source->IsControlledByPlayer())
{
if (i_source->IsFriendlyTo(target))