From 2d1905c887ba9eaa139dd450a484ed53868ec627 Mon Sep 17 00:00:00 2001 From: megamage Date: Wed, 3 Dec 2008 19:42:06 -0600 Subject: *Add new immune type: IMMUNITY_ID. This is usually done using dummy auras. *Let cloak of shadows immunes to flare. --HG-- branch : trunk --- src/game/Unit.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src/game/Unit.cpp') diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp index 771d6b30ae3..d43527d0f0b 100644 --- a/src/game/Unit.cpp +++ b/src/game/Unit.cpp @@ -9407,6 +9407,15 @@ bool Unit::IsImmunedToSpell(SpellEntry const* spellInfo, bool useCharges) } } + SpellImmuneList const& idList = m_spellImmune[IMMUNITY_ID]; + for(SpellImmuneList::const_iterator itr = idList.begin(); itr != idList.end(); ++itr) + { + if(itr->type == spellInfo->Id) + { + return true; + } + } + return false; } -- cgit v1.2.3