Scripts/Spells: Fix DK talent Permafrost
Port From (https://github.com/TrinityCore/TrinityCore/commit/24539e8d2779f6181d578009907982808edcd497)
This commit is contained in:
@@ -40,6 +40,7 @@ namespace Scripts.Spells.DeathKnight
|
|||||||
public const uint Frost = 137006;
|
public const uint Frost = 137006;
|
||||||
public const uint FrostFever = 55095;
|
public const uint FrostFever = 55095;
|
||||||
public const uint FrostScythe = 207230;
|
public const uint FrostScythe = 207230;
|
||||||
|
public const uint FrostShield = 207203;
|
||||||
public const uint GlyphOfFoulMenagerie = 58642;
|
public const uint GlyphOfFoulMenagerie = 58642;
|
||||||
public const uint GlyphOfTheGeist = 58640;
|
public const uint GlyphOfTheGeist = 58640;
|
||||||
public const uint GlyphOfTheSkeleton = 146652;
|
public const uint GlyphOfTheSkeleton = 146652;
|
||||||
@@ -682,6 +683,27 @@ namespace Scripts.Spells.DeathKnight
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
[Script] // 207200 - Permafrost
|
||||||
|
class spell_dk_permafrost : AuraScript
|
||||||
|
{
|
||||||
|
public override bool Validate(SpellInfo spellInfo)
|
||||||
|
{
|
||||||
|
return ValidateSpellInfo(SpellIds.FrostShield);
|
||||||
|
}
|
||||||
|
|
||||||
|
void HandleEffectProc(AuraEffect aurEff, ProcEventInfo eventInfo)
|
||||||
|
{
|
||||||
|
CastSpellExtraArgs args = new(aurEff);
|
||||||
|
args.AddSpellMod(SpellValueMod.BasePoint0, (int)MathFunctions.CalculatePct(eventInfo.GetDamageInfo().GetDamage(), aurEff.GetAmount()));
|
||||||
|
GetTarget().CastSpell(GetTarget(), SpellIds.FrostShield, args);
|
||||||
|
}
|
||||||
|
|
||||||
|
public override void Register()
|
||||||
|
{
|
||||||
|
OnEffectProc.Add(new(HandleEffectProc, 0, AuraType.Dummy));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// 121916 - Glyph of the Geist (Unholy)
|
// 121916 - Glyph of the Geist (Unholy)
|
||||||
[Script] /// 6.x, does this belong here or in spell_generic? apply this in creature_template_addon? sniffs say this is always cast on raise dead.
|
[Script] /// 6.x, does this belong here or in spell_generic? apply this in creature_template_addon? sniffs say this is always cast on raise dead.
|
||||||
class spell_dk_pet_geist_transform : SpellScript
|
class spell_dk_pet_geist_transform : SpellScript
|
||||||
|
|||||||
Reference in New Issue
Block a user