mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-20 01:15:35 +01:00
*Fix: Don't apply an aura when it's duration is 0. (for example because of diminishing returns)
This should fix interrupts when casting fear, stun, etc, while the duration is 0. Fix based on havenard's patch. Fixes issue 1621 Fixes issue 2271 --HG-- branch : trunk
This commit is contained in:
@@ -1390,6 +1390,12 @@ SpellMissInfo Spell::DoSpellHitOnUnit(Unit *unit, const uint32 effectMask, bool
|
||||
if (IsChanneledSpell(m_spellInfo))
|
||||
m_originalCaster->ModSpellCastTime(aurSpellInfo, duration, this);
|
||||
|
||||
if (duration <= 0)
|
||||
{
|
||||
m_spellAura->Remove();
|
||||
return SPELL_MISS_IMMUNE;
|
||||
}
|
||||
|
||||
if (duration != m_spellAura->GetMaxDuration())
|
||||
{
|
||||
m_spellAura->SetMaxDuration(duration);
|
||||
|
||||
Reference in New Issue
Block a user