From 70bf73ea04007e1bc5b230f161d7bbbf88bd094d Mon Sep 17 00:00:00 2001 From: Yehonal Date: Sat, 9 Jul 2016 13:57:29 +0200 Subject: [PATCH] fixed AzthPlgLoader --- .../src/server/game/PluginsLoader.h | 1 - .../server/plugins/AzthCustomPlgLoader.cpp | 28 ------------------- .../src/server/plugins/AzthCustomPlgLoader.h | 1 - .../src/server/plugins/AzthPlgLoader.cpp | 16 +++++++++++ src/server/game/Scripting/ScriptMgr.cpp | 10 +++++-- 5 files changed, 24 insertions(+), 32 deletions(-) delete mode 100644 modules/azerothshard/src/server/plugins/AzthCustomPlgLoader.cpp delete mode 100644 modules/azerothshard/src/server/plugins/AzthCustomPlgLoader.h diff --git a/modules/azerothshard/src/server/game/PluginsLoader.h b/modules/azerothshard/src/server/game/PluginsLoader.h index f730e33299..5904c73e2c 100644 --- a/modules/azerothshard/src/server/game/PluginsLoader.h +++ b/modules/azerothshard/src/server/game/PluginsLoader.h @@ -1,4 +1,3 @@ -#include "AzthCustomPlgLoader.h" #include "AzthPlgLoader.h" /* diff --git a/modules/azerothshard/src/server/plugins/AzthCustomPlgLoader.cpp b/modules/azerothshard/src/server/plugins/AzthCustomPlgLoader.cpp deleted file mode 100644 index 214e210eeb..0000000000 --- a/modules/azerothshard/src/server/plugins/AzthCustomPlgLoader.cpp +++ /dev/null @@ -1,28 +0,0 @@ -#include "AzthCustomPlgLoader.h" - -#ifndef AZTH_PLG_LOADER_CPP -#define AZTH_PLG_LOADER_CPP - -/* This is where custom AzerothShard function scripts declarations should be added. */ -// void AddSC_azth_commandscript(); -// void AddSC_CrossFactionGroups(); -// void AddSC_azth_player_plg(); -// void AddSC_Custom_Rates(); -// void AddSC_PWS_Transmogrification(); -// void AddSC_CS_Transmogrification(); -// void AddSC_npc_1v1arena(); - -void AddAzthCustomScripts() { - /* This is where custom AzerothShard scripts should be added. */ -// AddSC_azth_commandscript(); -// AddSC_CrossFactionGroups(); -// AddSC_azth_player_plg(); -// AddSC_Custom_Rates(); -// AddSC_PWS_Transmogrification(); -// AddSC_CS_Transmogrification(); -// AddSC_npc_1v1arena(); -} - - -#endif /* AZTH_PLG_LOADER_CPP */ - diff --git a/modules/azerothshard/src/server/plugins/AzthCustomPlgLoader.h b/modules/azerothshard/src/server/plugins/AzthCustomPlgLoader.h deleted file mode 100644 index a52faab43c..0000000000 --- a/modules/azerothshard/src/server/plugins/AzthCustomPlgLoader.h +++ /dev/null @@ -1 +0,0 @@ -void AddAzthCustomScripts(); \ No newline at end of file diff --git a/modules/azerothshard/src/server/plugins/AzthPlgLoader.cpp b/modules/azerothshard/src/server/plugins/AzthPlgLoader.cpp index 847907ab19..1f41656342 100644 --- a/modules/azerothshard/src/server/plugins/AzthPlgLoader.cpp +++ b/modules/azerothshard/src/server/plugins/AzthPlgLoader.cpp @@ -1,13 +1,29 @@ #include "AzthPlgLoader.h" +#include "Log.h" #ifndef SCRIPTLOADER_CPP #define SCRIPTLOADER_CPP /* This is where custom AzerothShard function scripts declarations should be added. */ +// void AddSC_azth_commandscript(); +// void AddSC_CrossFactionGroups(); +// void AddSC_azth_player_plg(); +// void AddSC_Custom_Rates(); +// void AddSC_PWS_Transmogrification(); +// void AddSC_CS_Transmogrification(); +// void AddSC_npc_1v1arena(); void AddAzthScripts() { + sLog->outString("Loading AzerothShard Plugins..."); /* This is where custom AzerothShard scripts should be added. */ +// AddSC_azth_commandscript(); +// AddSC_CrossFactionGroups(); +// AddSC_azth_player_plg(); +// AddSC_Custom_Rates(); +// AddSC_PWS_Transmogrification(); +// AddSC_CS_Transmogrification(); +// AddSC_npc_1v1arena(); } diff --git a/src/server/game/Scripting/ScriptMgr.cpp b/src/server/game/Scripting/ScriptMgr.cpp index 4c744753ff..93edf02e05 100644 --- a/src/server/game/Scripting/ScriptMgr.cpp +++ b/src/server/game/Scripting/ScriptMgr.cpp @@ -1,6 +1,6 @@ /* - * Copyright (C) - * Copyright (C) + * Copyright (C) + * Copyright (C) * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License as published by the @@ -33,6 +33,9 @@ #include "Player.h" #include "WorldPacket.h" +// [AZTH] +#include "PluginsLoader.h" + // This is the global static registry of scripts. /*template class ScriptRegistry @@ -178,6 +181,9 @@ void ScriptMgr::Initialize() sLog->outString("Loading C++ scripts"); FillSpellSummary(); + + AddAzthScripts(); // [AZTH] Loading AzerothShard Scripts + AddScripts(); CheckIfScriptsInDatabaseExist();