From 8c4f2ab12dd2be130ca923b5bb70d4f2bb701808 Mon Sep 17 00:00:00 2001 From: hondacrx Date: Tue, 23 May 2023 07:01:18 -0400 Subject: [PATCH] Scripts/Warrior: Implement Shield Charge Port From (https://github.com/TrinityCore/TrinityCore/commit/807c3555b5631bf6441db0b90887b7e7713c9a99) --- Source/Scripts/Spells/Warrior.cs | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/Source/Scripts/Spells/Warrior.cs b/Source/Scripts/Spells/Warrior.cs index 11945473a..482e37ce4 100644 --- a/Source/Scripts/Spells/Warrior.cs +++ b/Source/Scripts/Spells/Warrior.cs @@ -36,6 +36,7 @@ namespace Scripts.Spells.Warrior public const uint MortalStrike = 12294; public const uint MortalWounds = 213667; public const uint RallyingCry = 97463; + public const uint ShieldChargeEffect = 385953; public const uint Shockwave = 46968; public const uint ShockwaveStun = 132168; public const uint Stoicism = 70845; @@ -388,6 +389,25 @@ namespace Scripts.Spells.Warrior } } + [Script] // 385952 - Shield Charge + class spell_warr_shield_charge : SpellScript + { + public override bool Validate(SpellInfo spellInfo) + { + return ValidateSpellInfo(SpellIds.ShieldChargeEffect); + } + + void HandleDummy(uint effIndex) + { + GetCaster().CastSpell(GetHitUnit(), SpellIds.ShieldChargeEffect, true); + } + + public override void Register() + { + OnEffectHitTarget.Add(new EffectHandler(HandleDummy, 0, SpellEffectName.Dummy)); + } + } + [Script] // 46968 - Shockwave class spell_warr_shockwave : SpellScript {