mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-18 00:18:43 +01:00
Change the way #22332 moved spell damage calculations from SpellEffectDMG to scripts, using OnEffectLaunchTarget and SetEffectValue instead
(cherry picked from commit 20772dbf5d)
This commit is contained in:
@@ -144,12 +144,12 @@ class spell_rajaxx_thundercrash : public SpellScript
|
||||
if (damage < 200)
|
||||
damage = 200;
|
||||
|
||||
SetHitDamage(damage);
|
||||
SetEffectValue(damage);
|
||||
}
|
||||
|
||||
void Register() override
|
||||
{
|
||||
OnEffectHitTarget += SpellEffectFn(spell_rajaxx_thundercrash::HandleDamageCalc, EFFECT_0, SPELL_EFFECT_SCHOOL_DAMAGE);
|
||||
OnEffectLaunchTarget += SpellEffectFn(spell_rajaxx_thundercrash::HandleDamageCalc, EFFECT_0, SPELL_EFFECT_SCHOOL_DAMAGE);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -752,12 +752,12 @@ class boss_four_horsemen_sir : public CreatureScript
|
||||
void HandleDamageCalc(SpellEffIndex /*effIndex*/)
|
||||
{
|
||||
uint32 damage = GetCaster()->GetMap()->IsHeroic() ? 4250 : 2750;
|
||||
SetHitDamage(damage);
|
||||
SetEffectValue(damage);
|
||||
}
|
||||
|
||||
void Register() override
|
||||
{
|
||||
OnEffectHitTarget += SpellEffectFn(spell_four_horsemen_consumption::HandleDamageCalc, EFFECT_0, SPELL_EFFECT_SCHOOL_DAMAGE);
|
||||
OnEffectLaunchTarget += SpellEffectFn(spell_four_horsemen_consumption::HandleDamageCalc, EFFECT_0, SPELL_EFFECT_SCHOOL_DAMAGE);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user