Core/Console: start CliRunnable thread after all log messages have been printed.
Port From (https://github.com/TrinityCore/TrinityCore/commit/2344671af5dfd15db980b81b5c433d50c718970f)
This commit is contained in:
@@ -95,13 +95,6 @@ namespace WorldServer
|
|||||||
Global.WorldMgr.GetRealm().PopulationLevel = 0.0f;
|
Global.WorldMgr.GetRealm().PopulationLevel = 0.0f;
|
||||||
Global.WorldMgr.GetRealm().Flags = Global.WorldMgr.GetRealm().Flags & ~RealmFlags.VersionMismatch;
|
Global.WorldMgr.GetRealm().Flags = Global.WorldMgr.GetRealm().Flags & ~RealmFlags.VersionMismatch;
|
||||||
|
|
||||||
//- Launch CliRunnable thread
|
|
||||||
if (ConfigMgr.GetDefaultValue("Console.Enable", true))
|
|
||||||
{
|
|
||||||
Thread commandThread = new(CommandManager.InitConsole);
|
|
||||||
commandThread.Start();
|
|
||||||
}
|
|
||||||
|
|
||||||
GC.Collect();
|
GC.Collect();
|
||||||
GC.WaitForPendingFinalizers();
|
GC.WaitForPendingFinalizers();
|
||||||
GC.Collect();
|
GC.Collect();
|
||||||
@@ -109,6 +102,13 @@ namespace WorldServer
|
|||||||
uint startupDuration = Time.GetMSTimeDiffToNow(startupBegin);
|
uint startupDuration = Time.GetMSTimeDiffToNow(startupBegin);
|
||||||
Log.outInfo(LogFilter.Server, "World initialized in {0} minutes {1} seconds", (startupDuration / 60000), ((startupDuration % 60000) / 1000));
|
Log.outInfo(LogFilter.Server, "World initialized in {0} minutes {1} seconds", (startupDuration / 60000), ((startupDuration % 60000) / 1000));
|
||||||
|
|
||||||
|
//- Launch CliRunnable thread
|
||||||
|
if (ConfigMgr.GetDefaultValue("Console.Enable", true))
|
||||||
|
{
|
||||||
|
Thread commandThread = new(CommandManager.InitConsole);
|
||||||
|
commandThread.Start();
|
||||||
|
}
|
||||||
|
|
||||||
WorldUpdateLoop();
|
WorldUpdateLoop();
|
||||||
|
|
||||||
try
|
try
|
||||||
|
|||||||
Reference in New Issue
Block a user