From 11f56a8a37855fabe128b5fe3a840b732aaefd51 Mon Sep 17 00:00:00 2001 From: Cristian Vintila <127750549+cristianvnt@users.noreply.github.com> Date: Wed, 31 Dec 2025 00:35:07 +0200 Subject: Scripts/Spells: Implement priest talent Binding Heals (#31452) --- src/server/scripts/Spells/spell_priest.cpp | 34 ++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) (limited to 'src') diff --git a/src/server/scripts/Spells/spell_priest.cpp b/src/server/scripts/Spells/spell_priest.cpp index f624db6729f..bb4d07fa971 100644 --- a/src/server/scripts/Spells/spell_priest.cpp +++ b/src/server/scripts/Spells/spell_priest.cpp @@ -54,6 +54,7 @@ enum PriestSpells SPELL_PRIEST_ATONEMENT_EFFECT = 194384, SPELL_PRIEST_ATONEMENT_HEAL = 81751, SPELL_PRIEST_BENEDICTION = 193157, + SPELL_PRIEST_BINDING_HEALS_HEAL = 368276, SPELL_PRIEST_BLAZE_OF_LIGHT = 215768, SPELL_PRIEST_BLAZE_OF_LIGHT_INCREASE = 355851, SPELL_PRIEST_BLAZE_OF_LIGHT_DECREASE = 356084, @@ -723,6 +724,38 @@ class spell_pri_benediction : public SpellScript } }; +// 368275 - Binding Heals +class spell_pri_binding_heals : public AuraScript +{ + bool Validate(SpellInfo const* /*spellInfo*/) override + { + return ValidateSpellInfo({ SPELL_PRIEST_BINDING_HEALS_HEAL }); + } + + static bool CheckProc(AuraScript const&, ProcEventInfo const& eventInfo) + { + return eventInfo.GetActor() != eventInfo.GetProcTarget(); + } + + static void HandleEffectProc(AuraScript const&, AuraEffect const* aurEff, ProcEventInfo const& eventInfo) + { + Unit* caster = eventInfo.GetActor(); + + caster->CastSpell(caster, SPELL_PRIEST_BINDING_HEALS_HEAL, CastSpellExtraArgsInit{ + .TriggerFlags = TRIGGERED_IGNORE_CAST_IN_PROGRESS | TRIGGERED_DONT_REPORT_CAST_ERROR, + .TriggeringSpell = eventInfo.GetProcSpell(), + .TriggeringAura = aurEff, + .SpellValueOverrides = { { SPELLVALUE_BASE_POINT0, int32(CalculatePct(eventInfo.GetHealInfo()->GetHeal(), aurEff->GetAmount())) } } + }); + } + + void Register() override + { + DoCheckProc += AuraCheckProcFn(spell_pri_binding_heals::CheckProc); + OnEffectProc += AuraEffectProcFn(spell_pri_binding_heals::HandleEffectProc, EFFECT_0, SPELL_AURA_DUMMY); + } +}; + // 215768 - Blaze of Light class spell_pri_blaze_of_light : public AuraScript { @@ -4232,6 +4265,7 @@ void AddSC_priest_spell_scripts() RegisterSpellScript(spell_pri_atonement_effect_aura); RegisterSpellScript(spell_pri_atonement_passive); RegisterSpellScript(spell_pri_benediction); + RegisterSpellScript(spell_pri_binding_heals); RegisterSpellScript(spell_pri_blaze_of_light); RegisterSpellScript(spell_pri_circle_of_healing); RegisterSpellScript(spell_pri_crystalline_reflection); -- cgit v1.2.3