Core/Auras: cleanly remove linked auras when unapplying effect

Closes #21588
This commit is contained in:
ariel-
2018-03-12 02:58:58 -03:00
parent ac97655063
commit 8a8c7793c4

View File

@@ -4902,12 +4902,10 @@ void AuraEffect::HandleAuraLinked(AuraApplication const* aurApp, uint8 mode, boo
if (apply)
{
Unit* caster = triggeredSpellInfo->NeedsToBeTriggeredByCaster(m_spellInfo) ? GetCaster() : target;
if (!caster)
return;
CastSpellExtraArgs args(this);
if (GetAmount()) // If amount avalible cast with basepoints (Crypt Fever for example)
args.AddSpellMod(SPELLVALUE_BASE_POINT0, GetAmount());
@@ -4916,7 +4914,7 @@ void AuraEffect::HandleAuraLinked(AuraApplication const* aurApp, uint8 mode, boo
else
{
ObjectGuid casterGUID = triggeredSpellInfo->NeedsToBeTriggeredByCaster(m_spellInfo) ? GetCasterGUID() : target->GetGUID();
target->RemoveAura(triggeredSpellId, casterGUID, 0, aurApp->GetRemoveMode());
target->RemoveAura(triggeredSpellId, casterGUID);
}
}
else if (mode & AURA_EFFECT_HANDLE_REAPPLY && apply)