Scripts/Spells: Implement hunter talent Surging Shots (#30787)

This commit is contained in:
Aqua Deus
2025-04-18 16:05:05 +02:00
committed by GitHub
parent f2ede236ab
commit d8b790ef0c
2 changed files with 28 additions and 0 deletions

View File

@@ -0,0 +1,7 @@
DELETE FROM `spell_script_names` WHERE `ScriptName`='spell_hun_surging_shots';
INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES
(391559, 'spell_hun_surging_shots');
DELETE FROM `spell_proc` WHERE `SpellId` IN (391559);
INSERT INTO `spell_proc` (`SpellId`,`SchoolMask`,`SpellFamilyName`,`SpellFamilyMask0`,`SpellFamilyMask1`,`SpellFamilyMask2`,`SpellFamilyMask3`,`ProcFlags`,`ProcFlags2`,`SpellTypeMask`,`SpellPhaseMask`,`HitMask`,`AttributesMask`,`DisableEffectsMask`,`ProcsPerMinute`,`Chance`,`Cooldown`,`Charges`) VALUES
(391559,0x00,9,0x00020000,0x00000000,0x00000000,0x00000000,0x0,0x0,0x1,0x2,0x403,0x0,0x0,0,0,0,0); -- Surging Shots

View File

@@ -68,6 +68,7 @@ enum HunterSpells
SPELL_HUNTER_PET_HEART_OF_THE_PHOENIX_DEBUFF = 55711,
SPELL_HUNTER_POSTHASTE_INCREASE_SPEED = 118922,
SPELL_HUNTER_POSTHASTE_TALENT = 109215,
SPELL_HUNTER_RAPID_FIRE = 257044,
SPELL_HUNTER_RAPID_FIRE_DAMAGE = 257045,
SPELL_HUNTER_RAPID_FIRE_ENERGIZE = 263585,
SPELL_HUNTER_STEADY_SHOT = 56641,
@@ -822,6 +823,25 @@ class spell_hun_steady_shot : public SpellScript
}
};
// 391559 - Surging Shots
class spell_hun_surging_shots : public AuraScript
{
bool Validate(SpellInfo const* /*spellInfo*/) override
{
return ValidateSpellInfo({ SPELL_HUNTER_RAPID_FIRE });
}
void HandleProc(ProcEventInfo const& /*eventInfo*/) const
{
GetTarget()->GetSpellHistory()->ResetCooldown(SPELL_HUNTER_RAPID_FIRE, true);
}
void Register() override
{
OnProc += AuraProcFn(spell_hun_surging_shots::HandleProc);
}
};
// 1515 - Tame Beast
class spell_hun_tame_beast : public SpellScript
{
@@ -986,6 +1006,7 @@ void AddSC_hunter_spell_scripts()
RegisterSpellScript(spell_hun_scatter_shot);
RegisterSpellScript(spell_hun_scrappy);
RegisterSpellScript(spell_hun_steady_shot);
RegisterSpellScript(spell_hun_surging_shots);
RegisterSpellScript(spell_hun_tame_beast);
RegisterSpellScript(spell_hun_t9_4p_bonus);
RegisterSpellScript(spell_hun_t29_2p_marksmanship_bonus);