diff options
author | Aqua Deus <95978183+aquadeus@users.noreply.github.com> | 2024-09-16 01:05:53 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-09-16 01:05:53 +0200 |
commit | 76b9d8554265bc1f359905695c26759fe227b234 (patch) | |
tree | bece5608c58a7a08113c6f5b10e740fa4f402e38 | |
parent | aa358e9815d10b29a070aeb24c4ef1f9a8b9d498 (diff) |
Scripts/Spells: Implemented warlock talent Pyrogenics (#30190)
Co-authored-by: Shauren <shauren.trinity@gmail.com>
-rw-r--r-- | sql/updates/world/master/2024_09_16_00_world.sql | 7 | ||||
-rw-r--r-- | src/server/scripts/Spells/spell_warlock.cpp | 25 |
2 files changed, 32 insertions, 0 deletions
diff --git a/sql/updates/world/master/2024_09_16_00_world.sql b/sql/updates/world/master/2024_09_16_00_world.sql new file mode 100644 index 00000000000..1b5ed037eec --- /dev/null +++ b/sql/updates/world/master/2024_09_16_00_world.sql @@ -0,0 +1,7 @@ +DELETE FROM `spell_script_names` WHERE `ScriptName` = 'spell_warl_pyrogenics'; +INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES +(387095, 'spell_warl_pyrogenics'); + +DELETE FROM `spell_proc` WHERE `SpellId` IN (387095); +INSERT INTO `spell_proc` (`SpellId`,`SchoolMask`,`SpellFamilyName`,`SpellFamilyMask0`,`SpellFamilyMask1`,`SpellFamilyMask2`,`SpellFamilyMask3`,`ProcFlags`,`ProcFlags2`,`SpellTypeMask`,`SpellPhaseMask`,`HitMask`,`AttributesMask`,`DisableEffectsMask`,`ProcsPerMinute`,`Chance`,`Cooldown`,`Charges`) VALUES +(387095,0x00,5,0x00000000,0x00000000,0x10000000,0x00000000,0x50000,0x0,0x1,0x2,0x0,0x2,0x0,0,100,0,0); -- Pyrogenics diff --git a/src/server/scripts/Spells/spell_warlock.cpp b/src/server/scripts/Spells/spell_warlock.cpp index c7e41790d4b..fc810d573e6 100644 --- a/src/server/scripts/Spells/spell_warlock.cpp +++ b/src/server/scripts/Spells/spell_warlock.cpp @@ -67,6 +67,8 @@ enum WarlockSpells SPELL_WARLOCK_INCUBUS_PACT = 365355, SPELL_WARLOCK_PERPETUAL_UNSTABILITY_DAMAGE = 459461, SPELL_WARLOCK_PERPETUAL_UNSTABILITY_TALENT = 459376, + SPELL_WARLOCK_PYROGENICS_DEBUFF = 387096, + SPELL_WARLOCK_PYROGENICS_TALENT = 387095, SPELL_WARLOCK_RAIN_OF_FIRE = 5740, SPELL_WARLOCK_RAIN_OF_FIRE_DAMAGE = 42223, SPELL_WARLOCK_ROARING_BLAZE = 205184, @@ -728,6 +730,28 @@ class spell_warl_perpetual_unstability : public SpellScript } }; +// 387095 - Pyrogenics +class spell_warl_pyrogenics : public AuraScript +{ + bool Validate(SpellInfo const* /*spellInfo*/) override + { + return ValidateSpellInfo({ SPELL_WARLOCK_PYROGENICS_DEBUFF }); + } + + void HandleProc(AuraEffect const* aurEff, ProcEventInfo const& procInfo) const + { + GetTarget()->CastSpell(procInfo.GetActionTarget(), SPELL_WARLOCK_PYROGENICS_DEBUFF, CastSpellExtraArgsInit{ + .TriggerFlags = TRIGGERED_IGNORE_CAST_IN_PROGRESS | TRIGGERED_DONT_REPORT_CAST_ERROR, + .TriggeringAura = aurEff + }); + } + + void Register() override + { + OnEffectProc += AuraEffectProcFn(spell_warl_pyrogenics::HandleProc, EFFECT_0, SPELL_AURA_ADD_FLAT_MODIFIER_BY_SPELL_LABEL); + } +}; + // 5740 - Rain of Fire /// Updated 11.0.2 class spell_warl_rain_of_fire : public AuraScript @@ -1468,6 +1492,7 @@ void AddSC_warlock_spell_scripts() RegisterSpellScript(spell_warl_healthstone_heal); RegisterSpellScript(spell_warl_immolate); RegisterSpellScript(spell_warl_perpetual_unstability); + RegisterSpellScript(spell_warl_pyrogenics); RegisterSpellScript(spell_warl_rain_of_fire); RegisterSpellScript(spell_warl_random_sayaad); RegisterSpellScript(spell_warl_roaring_blaze); |