Merge pull request #12 from Mitradis/patch-1
fix for last PR ACE remove
This commit is contained in:
commit
162bf8a92a
3 changed files with 1 additions and 36 deletions
|
|
@ -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")
|
||||
AC_ADD_CONFIG_FILE("${CMAKE_CURRENT_LIST_DIR}/conf/mod_congratsonlevel.conf.dist")
|
||||
|
|
|
|||
|
|
@ -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})
|
||||
|
|
@ -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();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue