From ec1de1033dd76b6eaf0febfba44bdc46f5895747 Mon Sep 17 00:00:00 2001 From: Vitaliy Date: Tue, 2 Mar 2021 13:16:11 +0300 Subject: [PATCH 1/3] fix for last PR ACE remove https://github.com/azerothcore/azerothcore-wotlk/pull/4608 --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 560d82b..13b2540 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -4,4 +4,4 @@ AC_ADD_SCRIPT("${CMAKE_CURRENT_LIST_DIR}/src/mod_congratsonlevel.cpp") AC_ADD_SCRIPT_LOADER("CongratsOnLevel" "${CMAKE_CURRENT_LIST_DIR}/src/loader_congratsonlevel.h") -CU_ADD_HOOK(AFTER_WORLDSERVER_CMAKE "${CMAKE_CURRENT_LIST_DIR}/src/cmake/after_ws_install.cmake") \ No newline at end of file +AC_ADD_CONFIG_FILE("${CMAKE_CURRENT_LIST_DIR}/conf/mod_congratsonlevel.conf.dist") From 237793f4ae7642855fda81b85eaae968be44460a Mon Sep 17 00:00:00 2001 From: Vitaliy Date: Tue, 2 Mar 2021 13:16:30 +0300 Subject: [PATCH 2/3] Delete after_ws_install.cmake --- src/cmake/after_ws_install.cmake | 15 --------------- 1 file changed, 15 deletions(-) delete mode 100644 src/cmake/after_ws_install.cmake diff --git a/src/cmake/after_ws_install.cmake b/src/cmake/after_ws_install.cmake deleted file mode 100644 index c340340..0000000 --- a/src/cmake/after_ws_install.cmake +++ /dev/null @@ -1,15 +0,0 @@ -if( WIN32 ) - if ( MSVC ) - add_custom_command(TARGET worldserver - POST_BUILD - COMMAND ${CMAKE_COMMAND} -E copy "${CMAKE_MOD_CONGRATSONLEVEL_DIR}/conf/mod_congratsonlevel.conf.dist" ${CMAKE_BINARY_DIR}/bin/$(ConfigurationName)/ - ) - elseif ( MINGW ) - add_custom_command(TARGET worldserver - POST_BUILD - COMMAND ${CMAKE_COMMAND} -E copy "${CMAKE_MOD_CONGRATSONLEVEL_DIR}/conf/mod_congratsonlevel.conf.dist" ${CMAKE_BINARY_DIR}/bin/ - ) - endif() -endif() - -install(FILES "${CMAKE_MOD_CONGRATSONLEVEL_DIR}/conf/mod_congratsonlevel.conf.dist" DESTINATION ${CONF_DIR}) \ No newline at end of file From 78e6452eb2a8e1e0b4df0b82b9ffc3b5fd0659db Mon Sep 17 00:00:00 2001 From: Vitaliy Date: Tue, 2 Mar 2021 13:16:56 +0300 Subject: [PATCH 3/3] Update mod_congratsonlevel.cpp --- src/mod_congratsonlevel.cpp | 20 -------------------- 1 file changed, 20 deletions(-) diff --git a/src/mod_congratsonlevel.cpp b/src/mod_congratsonlevel.cpp index 66f51fb..cbb92f4 100644 --- a/src/mod_congratsonlevel.cpp +++ b/src/mod_congratsonlevel.cpp @@ -65,25 +65,6 @@ config file for quick modifications. #include "Player.h" #include "Chat.h" - -class CongratsConfig : public WorldScript -{ -public: - CongratsConfig() : WorldScript("CongratsConfig") { } - - void OnBeforeConfigLoad(bool reload) override - { - if (!reload) { - std::string conf_path = _CONF_DIR; - std::string cfg_file = conf_path + "/mod_congratsonlevel.conf"; - - std::string cfg_def_file = cfg_file + ".dist"; - sConfigMgr->LoadMore(cfg_def_file.c_str()); - sConfigMgr->LoadMore(cfg_file.c_str()); - } - } -}; - class CongratsAnnounce : public PlayerScript { @@ -293,7 +274,6 @@ public: void AddCongratsOnLevelScripts() { - new CongratsConfig(); new CongratsAnnounce(); new CongratsOnLevel(); }