Scripts/Warrior: Implement Shield Charge

Port From (https://github.com/TrinityCore/TrinityCore/commit/807c3555b5631bf6441db0b90887b7e7713c9a99)
This commit is contained in:
hondacrx
2023-05-23 07:01:18 -04:00
parent 45f81d7b78
commit 8c4f2ab12d
+20
View File
@@ -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
{