From 4a3da937882d287344fb3298d9cb018c20df3ffc Mon Sep 17 00:00:00 2001 From: Ovahlord Date: Tue, 30 May 2023 15:31:30 +0200 Subject: [PATCH] Core/Spells: fixed a logic mistake in Combustion's script which was causing the damage effect to fire for each selected DoT effect instead of summing up all of their values and firing once --- src/server/scripts/Spells/spell_mage.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/server/scripts/Spells/spell_mage.cpp b/src/server/scripts/Spells/spell_mage.cpp index 0f07e6e65c..f4cb972bd1 100644 --- a/src/server/scripts/Spells/spell_mage.cpp +++ b/src/server/scripts/Spells/spell_mage.cpp @@ -1734,10 +1734,11 @@ class spell_mage_combustion : public SpellScript if (!aurEff->GetSpellInfo()->IsAffected(SPELLFAMILY_MAGE, GetSpellInfo()->Effects[effIndex].SpellClassMask)) continue; - basePoints = CalculatePct(aurEff->GetAmount(), scalingFactor); - if (basePoints > 0) - caster->CastSpell(target, SPELL_MAGE_COMBUSTION_DAMAGE, CastSpellExtraArgs(true).AddSpellBP0(basePoints)); + basePoints += CalculatePct(aurEff->GetAmount(), scalingFactor); } + + if (basePoints > 0) + caster->CastSpell(target, SPELL_MAGE_COMBUSTION_DAMAGE, CastSpellExtraArgs(true).AddSpellBP0(basePoints)); } void Register() override