From ae12bcc74fa51b3c255fec5acfc419f4e62d3b15 Mon Sep 17 00:00:00 2001 From: Ovahlord Date: Mon, 23 Jul 2018 14:45:20 +0200 Subject: [PATCH] Core/Spells: apply coding standards to Mirror Image handling --- sql/updates/world/custom/custom_2018_07_23_00_world.sql | 4 ++-- src/server/scripts/Spells/spell_mage.cpp | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/sql/updates/world/custom/custom_2018_07_23_00_world.sql b/sql/updates/world/custom/custom_2018_07_23_00_world.sql index 29af57ab01e..ed9ffc1914c 100644 --- a/sql/updates/world/custom/custom_2018_07_23_00_world.sql +++ b/sql/updates/world/custom/custom_2018_07_23_00_world.sql @@ -1,10 +1,10 @@ DELETE FROM `spell_script_names` WHERE `ScriptName` IN ('spell_mage_mirror_image', -'spell_initialize_images'); +'spell_mage_initialize_images'); INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES (55342, 'spell_mage_mirror_image'), -(58836, 'spell_initialize_images'); +(58836, 'spell_mage_initialize_images'); UPDATE `creature_template` SET `unit_class`= 8, `ScriptName`= 'npc_pet_mage_mirror_image' WHERE `entry` IN (47244, 47243, 31216); diff --git a/src/server/scripts/Spells/spell_mage.cpp b/src/server/scripts/Spells/spell_mage.cpp index 336f85b92d3..a93f51bb76a 100644 --- a/src/server/scripts/Spells/spell_mage.cpp +++ b/src/server/scripts/Spells/spell_mage.cpp @@ -2089,9 +2089,9 @@ class SummonerCheck Unit* summoner; }; -class spell_initialize_images : public SpellScript +class spell_mage_initialize_images : public SpellScript { - PrepareSpellScript(spell_initialize_images); + PrepareSpellScript(spell_mage_initialize_images); void FilterTargets(std::list& targets) { @@ -2103,7 +2103,7 @@ class spell_initialize_images : public SpellScript void Register() override { - OnObjectAreaTargetSelect += SpellObjectAreaTargetSelectFn(spell_initialize_images::FilterTargets, EFFECT_0, TARGET_UNIT_SRC_AREA_ENTRY); + OnObjectAreaTargetSelect += SpellObjectAreaTargetSelectFn(spell_mage_initialize_images::FilterTargets, EFFECT_0, TARGET_UNIT_SRC_AREA_ENTRY); } }; @@ -2127,7 +2127,7 @@ void AddSC_mage_spell_scripts() new spell_mage_ice_barrier(); new spell_mage_ignite(); new spell_mage_improved_hot_streak(); - RegisterSpellScript(spell_initialize_images); + RegisterSpellScript(spell_mage_initialize_images); new spell_mage_glyph_of_ice_block(); new spell_mage_glyph_of_icy_veins(); new spell_mage_glyph_of_polymorph();