diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/server/worldserver/Main.cpp | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/src/server/worldserver/Main.cpp b/src/server/worldserver/Main.cpp index 335b553a018..e163dd2566d 100644 --- a/src/server/worldserver/Main.cpp +++ b/src/server/worldserver/Main.cpp @@ -307,17 +307,6 @@ extern int main(int argc, char** argv) ClearOnlineAccounts(); }); - // Launch CliRunnable thread - std::shared_ptr<std::thread> cliThread; -#ifdef _WIN32 - if (sConfigMgr->GetBoolDefault("Console.Enable", true) && (m_ServiceStatus == -1)/* need disable console in service mode*/) -#else - if (sConfigMgr->GetBoolDefault("Console.Enable", true)) -#endif - { - cliThread.reset(new std::thread(CliThread), &ShutdownCLIThread); - } - // Set server online (allow connecting now) LoginDatabase.DirectPExecute("UPDATE realmlist SET flag = flag & ~%u, population = 0 WHERE id = '%u'", REALM_FLAG_OFFLINE, realm.Id.Realm); realm.PopulationLevel = 0.0f; @@ -336,6 +325,17 @@ extern int main(int argc, char** argv) sScriptMgr->OnStartup(); + // Launch CliRunnable thread + std::shared_ptr<std::thread> cliThread; +#ifdef _WIN32 + if (sConfigMgr->GetBoolDefault("Console.Enable", true) && (m_ServiceStatus == -1)/* need disable console in service mode*/) +#else + if (sConfigMgr->GetBoolDefault("Console.Enable", true)) +#endif + { + cliThread.reset(new std::thread(CliThread), &ShutdownCLIThread); + } + WorldUpdateLoop(); // Shutdown starts here |