mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-02-05 16:39:08 +01:00
Core/Spells: remove SetEffectDamage helper since SetEffectValue serves the exact same purpose
This commit is contained in:
@@ -555,16 +555,6 @@ void SpellScript::SetHitDamage(int32 damage)
|
||||
m_spell->m_damage = damage;
|
||||
}
|
||||
|
||||
void SpellScript::SetEffectDamage(int32 damage)
|
||||
{
|
||||
if (!IsInTargetHook())
|
||||
{
|
||||
TC_LOG_ERROR("scripts", "Script: `%s` Spell: `%u`: function SpellScript::SetHitDamage was called, but function has no effect in current hook!", m_scriptName->c_str(), m_scriptSpellId);
|
||||
return;
|
||||
}
|
||||
m_spell->damage = damage;
|
||||
}
|
||||
|
||||
int32 SpellScript::GetHitHeal() const
|
||||
{
|
||||
if (!IsInTargetHook())
|
||||
|
||||
@@ -427,7 +427,6 @@ class TC_GAME_API SpellScript : public _SpellScript
|
||||
int32 GetHitDamage() const;
|
||||
void SetHitDamage(int32 damage);
|
||||
void PreventHitDamage() { SetHitDamage(0); }
|
||||
void SetEffectDamage(int32 damage);
|
||||
// setter/getter for for heal done by spell to target of spell hit
|
||||
// returns healing calculated before hit, and real dmg done after hit
|
||||
int32 GetHitHeal() const;
|
||||
|
||||
@@ -963,7 +963,7 @@ class spell_warr_victory_rush : public SpellScript
|
||||
if (Player* modOwner = caster->GetSpellModOwner())
|
||||
modOwner->ApplySpellMod(m_scriptSpellId, SPELLMOD_EFFECT3, damage);
|
||||
|
||||
SetEffectDamage(damage);
|
||||
SetEffectValue(damage);
|
||||
}
|
||||
|
||||
caster->RemoveAurasDueToSpell(SPELL_WARRIOR_VICTORIOUS);
|
||||
|
||||
Reference in New Issue
Block a user