mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-16 07:30:42 +01:00
Core/Scripts: Add SpellInfo argument to ScriptMgr::ModifySpellDamageTaken (#26141)
This commit is contained in:
@@ -2193,10 +2193,10 @@ void ScriptMgr::ModifyMeleeDamage(Unit* target, Unit* attacker, uint32& damage)
|
||||
FOREACH_SCRIPT(PlayerScript)->ModifyMeleeDamage(target, attacker, damage);
|
||||
}
|
||||
|
||||
void ScriptMgr::ModifySpellDamageTaken(Unit* target, Unit* attacker, int32& damage)
|
||||
void ScriptMgr::ModifySpellDamageTaken(Unit* target, Unit* attacker, int32& damage, SpellInfo const* spellInfo)
|
||||
{
|
||||
FOREACH_SCRIPT(UnitScript)->ModifySpellDamageTaken(target, attacker, damage);
|
||||
FOREACH_SCRIPT(PlayerScript)->ModifySpellDamageTaken(target, attacker, damage);
|
||||
FOREACH_SCRIPT(UnitScript)->ModifySpellDamageTaken(target, attacker, damage, spellInfo);
|
||||
FOREACH_SCRIPT(PlayerScript)->ModifySpellDamageTaken(target, attacker, damage, spellInfo);
|
||||
}
|
||||
|
||||
// Conversation
|
||||
|
||||
@@ -409,7 +409,7 @@ class TC_GAME_API UnitScript : public ScriptObject
|
||||
virtual void ModifyMeleeDamage(Unit* /*target*/, Unit* /*attacker*/, uint32& /*damage*/) { }
|
||||
|
||||
// Called when Spell Damage is being Dealt
|
||||
virtual void ModifySpellDamageTaken(Unit* /*target*/, Unit* /*attacker*/, int32& /*damage*/) { }
|
||||
virtual void ModifySpellDamageTaken(Unit* /*target*/, Unit* /*attacker*/, int32& /*damage*/, SpellInfo const* /*spellInfo*/) { }
|
||||
};
|
||||
|
||||
class TC_GAME_API CreatureScript : public UnitScript
|
||||
@@ -1127,7 +1127,7 @@ class TC_GAME_API ScriptMgr
|
||||
void OnDamage(Unit* attacker, Unit* victim, uint32& damage);
|
||||
void ModifyPeriodicDamageAurasTick(Unit* target, Unit* attacker, uint32& damage);
|
||||
void ModifyMeleeDamage(Unit* target, Unit* attacker, uint32& damage);
|
||||
void ModifySpellDamageTaken(Unit* target, Unit* attacker, int32& damage);
|
||||
void ModifySpellDamageTaken(Unit* target, Unit* attacker, int32& damage, SpellInfo const* spellInfo);
|
||||
|
||||
public: /* AreaTriggerEntityScript */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user