diff options
| author | megamage <none@none> | 2008-12-27 15:28:30 -0600 |
|---|---|---|
| committer | megamage <none@none> | 2008-12-27 15:28:30 -0600 |
| commit | f3d0021ce882a5fb3977bef53f3659823ac6f083 (patch) | |
| tree | eb4ff2275790ad652035fa8349ce59514649f166 /src | |
| parent | 536879150daec567a582cfeb1f125f733fc9d5bc (diff) | |
*Fix the bug that spirit of redemption can be killed.
--HG--
branch : trunk
Diffstat (limited to 'src')
| -rw-r--r-- | src/game/Spell.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/game/Spell.cpp b/src/game/Spell.cpp index 7aeb0159e9d..15259bf1af0 100644 --- a/src/game/Spell.cpp +++ b/src/game/Spell.cpp @@ -1111,6 +1111,14 @@ void Spell::DoSpellHitOnUnit(Unit *unit, const uint32 effectMask) if( m_caster != unit ) { + if (unit->GetCharmerOrOwnerGUID() != m_caster->GetGUID()) + { + if (unit->HasFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE)) + { + m_caster->SendSpellMiss(unit, m_spellInfo->Id, SPELL_MISS_EVADE); + return; + } + } if( !m_caster->IsFriendlyTo(unit) ) { // for delayed spells ignore not visible explicit target |
