mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-13 01:08:35 +00:00
fix(Scripts/Spells): Implement Blade Barrier Script (#24154)
Co-authored-by: Ariel Silva <ariel-@users.noreply.github.com>
This commit is contained in:
@@ -0,0 +1,4 @@
|
||||
-- bb
|
||||
DELETE FROM `spell_script_names` WHERE `spell_id` = -49182;
|
||||
INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES
|
||||
(-49182, 'spell_dk_blade_barrier');
|
||||
@@ -2314,6 +2314,26 @@ class spell_dk_army_of_the_dead_passive : public AuraScript
|
||||
}
|
||||
};
|
||||
|
||||
// -49182 Blade Barrier
|
||||
class spell_dk_blade_barrier : public AuraScript
|
||||
{
|
||||
PrepareAuraScript(spell_dk_blade_barrier);
|
||||
|
||||
bool CheckProc(ProcEventInfo& /*eventInfo*/)
|
||||
{
|
||||
if (Player* player = GetCaster()->ToPlayer())
|
||||
if (player->getClass() == CLASS_DEATH_KNIGHT && player->IsBaseRuneSlotsOnCooldown(RUNE_BLOOD))
|
||||
return true;
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
void Register() override
|
||||
{
|
||||
DoCheckProc += AuraCheckProcFn(spell_dk_blade_barrier::CheckProc);
|
||||
}
|
||||
};
|
||||
|
||||
void AddSC_deathknight_spell_scripts()
|
||||
{
|
||||
RegisterSpellScript(spell_dk_wandering_plague);
|
||||
@@ -2362,4 +2382,5 @@ void AddSC_deathknight_spell_scripts()
|
||||
RegisterSpellScript(spell_dk_will_of_the_necropolis);
|
||||
RegisterSpellScript(spell_dk_ghoul_thrash);
|
||||
RegisterSpellScript(spell_dk_army_of_the_dead_passive);
|
||||
RegisterSpellScript(spell_dk_blade_barrier);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user