Merge pull request #14883 from tkrokli/omen_of_clarity
[3.3.5] Core/Spells: Avoid losing spell mod auras when check on spellcast fails
This commit is contained in:
commit
35f0d8e9c1
1 file changed
+8
@@ -2901,6 +2901,14 @@ void Spell::prepare(SpellCastTargets const* targets, AuraEffect const* triggered
|
||||
triggeredByAura->GetBase()->SetDuration(0);
|
||||
}
|
||||
|
||||
if (m_caster->GetTypeId() == TYPEID_PLAYER)
|
||||
{
|
||||
m_caster->ToPlayer()->RestoreSpellMods(this);
|
||||
// cleanup after mod system
|
||||
// triggered spell pointer can be not removed in some cases
|
||||
m_caster->ToPlayer()->SetSpellModTakingSpell(this, false);
|
||||
}
|
||||
|
||||
SendCastResult(result);
|
||||
|
||||
finish(false);
|
||||
|
||||
Reference in new issue
Block a user