Skip to content

Commit

Permalink
Scripts/Spells: Implement warlock talent Roaring Blaze (TrinityCore#3…
Browse files Browse the repository at this point in the history
  • Loading branch information
aquadeus authored Sep 12, 2024
1 parent 7e504ad commit 18519e6
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 0 deletions.
3 changes: 3 additions & 0 deletions sql/updates/world/master/2024_09_12_02_world.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
DELETE FROM `spell_script_names` WHERE `ScriptName` = 'spell_warl_roaring_blaze';
INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES
(17962, 'spell_warl_roaring_blaze');
30 changes: 30 additions & 0 deletions src/server/scripts/Spells/spell_warlock.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ enum WarlockSpells
{
SPELL_WARLOCK_ABSOLUTE_CORRUPTION = 196103,
SPELL_WARLOCK_AGONY = 980,
SPELL_WARLOCK_CONFLAGRATE_DEBUFF = 265931,
SPELL_WARLOCK_CONFLAGRATE_ENERGIZE = 245330,
SPELL_WARLOCK_CORRUPTION_DAMAGE = 146739,
SPELL_WARLOCK_CREATE_HEALTHSTONE = 23517,
Expand All @@ -64,6 +65,7 @@ enum WarlockSpells
SPELL_WARLOCK_PERPETUAL_UNSTABILITY_DAMAGE = 459461,
SPELL_WARLOCK_RAIN_OF_FIRE = 5740,
SPELL_WARLOCK_RAIN_OF_FIRE_DAMAGE = 42223,
SPELL_WARLOCK_ROARING_BLAZE = 205184,
SPELL_WARLOCK_SEED_OF_CORRUPTION_DAMAGE = 27285,
SPELL_WARLOCK_SEED_OF_CORRUPTION_GENERIC = 32865,
SPELL_WARLOCK_SHADOW_BOLT_ENERGIZE = 194192,
Expand Down Expand Up @@ -737,6 +739,33 @@ class spell_warl_random_sayaad : public SpellScript
}
};

// Called by 17962 - Conflagrate
class spell_warl_roaring_blaze : public SpellScript
{
bool Validate(SpellInfo const* /*spellInfo*/) override
{
return ValidateSpellInfo ({ SPELL_WARLOCK_ROARING_BLAZE, SPELL_WARLOCK_CONFLAGRATE_DEBUFF });
}

bool Load() override
{
return GetCaster()->HasAura(SPELL_WARLOCK_ROARING_BLAZE);
}

void HandleDummy(SpellEffIndex /*effIndex*/) const
{
GetCaster()->CastSpell(GetHitUnit(), SPELL_WARLOCK_CONFLAGRATE_DEBUFF, CastSpellExtraArgsInit{
.TriggerFlags = TRIGGERED_IGNORE_CAST_IN_PROGRESS | TRIGGERED_DONT_REPORT_CAST_ERROR,
.TriggeringSpell = GetSpell()
});
}

void Register() override
{
OnEffectHitTarget += SpellEffectFn(spell_warl_roaring_blaze::HandleDummy, EFFECT_0, SPELL_EFFECT_SCHOOL_DAMAGE);
}
};

// 366323 - Strengthen Pact - Succubus
// 366325 - Strengthen Pact - Incubus
// 366222 - Summon Sayaad
Expand Down Expand Up @@ -1387,6 +1416,7 @@ void AddSC_warlock_spell_scripts()
RegisterSpellScript(spell_warl_perpetual_unstability);
RegisterSpellScript(spell_warl_rain_of_fire);
RegisterSpellScript(spell_warl_random_sayaad);
RegisterSpellScript(spell_warl_roaring_blaze);
RegisterSpellScript(spell_warl_sayaad_precast_disorientation);
RegisterSpellScript(spell_warl_seduction);
RegisterSpellScript(spell_warl_seed_of_corruption);
Expand Down

0 comments on commit 18519e6

Please sign in to comment.