Scripts/Spells: moved all scripts into their own respective namespaces

This commit is contained in:
Ovahlord committed 2023-12-08 19:57:27 +01:00
1 parent d5f1aea2d2
commit 7e62a55074
15 files changed
+60

No files matched your search

+4
View File
@@ -33,6 +33,8 @@
#include "SpellMgr.h"
#include "SpellScript.h"
namespace Spells::DeathKnight
{
enum DeathKnightSpells
{
SPELL_DK_ANTI_MAGIC_SHELL_TALENT = 51052,
@@ -1871,9 +1873,11 @@ class spell_dk_strangulate : public SpellScript
OnEffectHitTarget.Register(&spell_dk_strangulate::HandleCreatureInterrupt, EFFECT_0, SPELL_EFFECT_APPLY_AURA);
}
};
}
void AddSC_deathknight_spell_scripts()
{
using namespace Spells::DeathKnight;
RegisterSpellScript(spell_dk_anti_magic_shell);
RegisterSpellScript(spell_dk_anti_magic_zone);
RegisterSpellScript(spell_dk_army_of_the_dead);
@@ -34,6 +34,8 @@
#include "SpellScript.h"
#include "TemporarySummon.h"
namespace Spells::Druid
{
enum DruidSpells
{
SPELL_DRUID_ASTRAL_ALIGNMENT = 90164,
@@ -2181,9 +2183,11 @@ class spell_dru_stampede_triggered : public AuraScript
AfterEffectRemove.Register(&spell_dru_stampede_triggered::AfterRemove, EFFECT_0, SPELL_AURA_ANY, AURA_EFFECT_HANDLE_REAL_OR_REAPPLY_MASK);
}
};
}
void AddSC_druid_spell_scripts()
{
using namespace Spells::Druid;
RegisterSpellScript(spell_dru_astral_alignment);
RegisterSpellScript(spell_dru_berserk);
RegisterSpellScript(spell_dru_blood_in_the_water);
@@ -43,6 +43,8 @@
#include "Vehicle.h"
#include "CreatureAIImpl.h"
namespace Spells::Generic
{
class spell_gen_absorb0_hitlimit1 : public SpellScriptLoader
{
public:
@@ -5189,9 +5191,11 @@ class spell_gen_arcane_torrent_racial : public SpellScript
OnEffectHitTarget.Register(&spell_gen_arcane_torrent_racial::HandleCreatureInterrupt, EFFECT_0, SPELL_EFFECT_APPLY_AURA);
}
};
}
void AddSC_generic_spell_scripts()
{
using namespace Spells::Generic;
new spell_gen_absorb0_hitlimit1();
new spell_gen_adaptive_warding();
new spell_gen_alchemist_stone();
@@ -33,6 +33,8 @@
#include "Vehicle.h"
#include "World.h"
namespace Spells::Holiday
{
// 45102 Romantic Picnic
enum SpellsPicnic
{
@@ -1891,9 +1893,11 @@ class spell_darkmoon_island_whack_a_gnoll_player_action_bar_removed : public Spe
OnEffectHitTarget.Register(&spell_darkmoon_island_whack_a_gnoll_player_action_bar_removed::DespawnUnits, EFFECT_1, SPELL_EFFECT_DUMMY);
}
};
}
void AddSC_holiday_spell_scripts()
{
using namespace Spells::Holiday;
// Love is in the Air
new spell_love_is_in_the_air_romantic_picnic();
// Hallow's End
@@ -30,6 +30,8 @@
#include "SpellMgr.h"
#include "SpellScript.h"
namespace Spells::Hunter
{
enum HunterSpells
{
SPELL_HUNTER_AIMED_SHOT = 19434,
@@ -1436,9 +1438,11 @@ class spell_hun_serpent_spread : public AuraScript
OnEffectProc.Register(&spell_hun_serpent_spread::HandleProc, EFFECT_0, SPELL_AURA_DUMMY);
}
};
}
void AddSC_hunter_spell_scripts()
{
using namespace Spells::Hunter;
RegisterSpellScript(spell_hun_ancient_hysteria);
RegisterSpellScript(spell_hun_camouflage);
RegisterSpellScript(spell_hun_camouflage_duration);
+4
View File
@@ -35,6 +35,8 @@
#include "SpellMgr.h"
#include "SpellScript.h"
namespace Spells::Items
{
// Generic script for handling item dummy effects which trigger another spell.
class spell_item_trigger_spell : public SpellScriptLoader
{
@@ -5172,9 +5174,11 @@ public:
private:
std::array<uint32, 3> _procSpellIds;
};
}
void AddSC_item_spell_scripts()
{
using namespace Spells::Items;
// 23074 Arcanite Dragonling
new spell_item_trigger_spell("spell_item_arcanite_dragonling", SPELL_ARCANITE_DRAGONLING);
// 23133 Gnomish Battle Chicken
+4
View File
@@ -31,6 +31,8 @@
#include "SpellMgr.h"
#include "SpellScript.h"
namespace Spells::Mage
{
enum MageSpells
{
SPELL_MAGE_ARCANE_POTENCY_RANK_1 = 31571,
@@ -1783,9 +1785,11 @@ class spell_mage_frostfire_bolt : public SpellScript
OnEffectHitTarget.Register(&spell_mage_frostfire_bolt::HandleGlyphDot, EFFECT_2, SPELL_EFFECT_APPLY_AURA);
}
};
}
void AddSC_mage_spell_scripts()
{
using namespace Spells::Mage;
RegisterSpellScript(spell_mage_arcane_missiles_trigger);
RegisterSpellScript(spell_mage_arcane_potency);
RegisterSpellScript(spell_mage_blast_wave);
@@ -31,6 +31,8 @@
#include "Spell.h"
#include "TemporarySummon.h"
namespace Spells::Paladin
{
enum PaladinSpells
{
SPELL_PALADIN_ANCIENT_HEALER = 86674,
@@ -1857,9 +1859,11 @@ class spell_pal_guarded_by_the_light : public AuraScript
OnEffectProc.Register(&spell_pal_guarded_by_the_light::HandleProc, EFFECT_0, SPELL_AURA_DUMMY);
}
};
}
void AddSC_paladin_spell_scripts()
{
using namespace Spells::Paladin;
RegisterSpellScript(spell_pal_ardent_defender);
RegisterSpellScript(spell_pal_ancient_healer);
RegisterSpellScript(spell_pal_ancient_crusader);
+4
View File
@@ -30,6 +30,8 @@
#include "SpellScript.h"
#include "Unit.h"
namespace Spells::Pets
{
enum HunterPetCalculate
{
SPELL_TAMED_PET_PASSIVE_09 = 34667,
@@ -1075,9 +1077,11 @@ class spell_mage_water_elemental_scaling_02 : public AuraScript
DoEffectCalcAmount.Register(&spell_mage_water_elemental_scaling_02::CalculateManaAmount, EFFECT_0, SPELL_AURA_MOD_INCREASE_ENERGY);
}
};
}
void AddSC_pet_spell_scripts()
{
using namespace Spells::Pets;
RegisterSpellScript(spell_warl_pet_scaling_01);
RegisterSpellScript(spell_warl_pet_scaling_02);
RegisterSpellScript(spell_warl_pet_scaling_03);
@@ -30,6 +30,8 @@
#include "SpellScript.h"
#include "TemporarySummon.h"
namespace Spells::Priest
{
enum PriestSpells
{
SPELL_PRIEST_ABSOLUTION = 33167,
@@ -1844,9 +1846,11 @@ class spell_pri_silence : public SpellScript
OnEffectHitTarget.Register(&spell_pri_silence::HandleCreatureInterrupt, EFFECT_0, SPELL_EFFECT_APPLY_AURA);
}
};
}
void AddSC_priest_spell_scripts()
{
using namespace Spells::Priest;
RegisterSpellScript(spell_pri_archangel);
RegisterSpellScript(spell_pri_atonement);
RegisterSpellScript(spell_pri_atonement_heal);
@@ -32,6 +32,8 @@
#include "SpellScript.h"
#include "Vehicle.h"
namespace Spells::Quests
{
class spell_generic_quest_update_entry_SpellScript : public SpellScript
{
private:
@@ -2735,9 +2737,11 @@ public:
return new spell_q14098_knocking_67869_SpellScript();
}
};
}
void AddSC_quest_spell_scripts()
{
using namespace Spells::Quests;
new spell_q55_sacred_cleansing();
new spell_q2203_thaumaturgy_channel();
new spell_q5206_test_fetid_skull();
@@ -32,6 +32,8 @@
#include "SpellMgr.h"
#include "SpellScript.h"
namespace Spells::Rogue
{
enum RogueSpells
{
SPELL_ROGUE_ADRENALIN_RUSH = 13750,
@@ -1381,9 +1383,11 @@ class spell_rogue_venomous_wounds : public AuraScript
AfterEffectProc.Register(&spell_rogue_venomous_wounds::HandleProc, EFFECT_0, SPELL_AURA_DUMMY);
}
};
}
void AddSC_rogue_spell_scripts()
{
using namespace Spells::Rogue;
RegisterSpellScript(spell_rog_bandits_guile);
RegisterSpellScript(spell_rog_blade_flurry);
RegisterSpellScript(spell_rog_cheat_death);
@@ -32,6 +32,8 @@
#include "TemporarySummon.h"
#include "Unit.h"
namespace Spells::Shaman
{
enum ShamanSpells
{
SPELL_SHAMAN_ANCESTRAL_AWAKENING = 52759,
@@ -1774,9 +1776,11 @@ class spell_sha_clearcasting : public AuraScript
DoEffectCalcAmount.Register(&spell_sha_clearcasting::CalculateAmount, EFFECT_1, SPELL_AURA_MOD_DAMAGE_PERCENT_DONE);
}
};
}
void AddSC_shaman_spell_scripts()
{
using namespace Spells::Shaman;
RegisterSpellScript(spell_sha_ancestral_awakening);
RegisterSpellScript(spell_sha_ancestral_awakening_proc);
RegisterSpellScript(spell_sha_ancestral_healing);
@@ -34,6 +34,8 @@
#include "SpellMgr.h"
#include "SpellScript.h"
namespace Spells::Warlock
{
enum WarlockSpells
{
SPELL_WARLOCK_AFTERMATH_STUN = 85387,
@@ -1808,9 +1810,11 @@ private:
return true;
}
};
}
void AddSC_warlock_spell_scripts()
{
using namespace Spells::Warlock;
RegisterSpellScript(spell_warl_aftermath);
RegisterSpellScript(spell_warl_bane_of_havoc);
RegisterSpellScript(spell_warl_bane_of_havoc_tracking_aura);
@@ -33,6 +33,8 @@
#include "SpellScript.h"
#include "GridNotifiersImpl.h"
namespace Spells::Warrior
{
enum WarriorSpells
{
SPELL_WARRIOR_BATTLE_TRANCE_TRIGGERED = 12964,
@@ -1089,9 +1091,11 @@ class spell_warr_enraged_regeneration_AuraScript: public AuraScript
AfterEffectRemove.Register(&spell_warr_enraged_regeneration_AuraScript::HandleRemove, EFFECT_0, SPELL_AURA_OBS_MOD_HEALTH, AURA_EFFECT_HANDLE_REAL);
}
};
}
void AddSC_warrior_spell_scripts()
{
using namespace Spells::Warrior;
RegisterSpellScript(spell_warr_blood_craze);
RegisterSpellScript(spell_warr_bloodthirst);
RegisterSpellScript(spell_warr_bloodthirst_heal);