fix: Updates first load configuration (#680)
<img width="814" alt="Screen Shot 2021-08-08 at 11 33 24 PM" src="https://user-images.githubusercontent.com/3953314/128667907-be43bf24-df7b-481b-ab0a-8b9094f01188.png">
This commit is contained in:
parent
b0f8fe0350
commit
f795ab4698
2 changed files with 91 additions and 51 deletions
|
|
@ -384,7 +384,7 @@ namespace Server
|
|||
|
||||
if (Assembly == null)
|
||||
{
|
||||
throw new Exception("Core: Assembly entry is missing.");
|
||||
throw new Exception("Assembly entry is missing.");
|
||||
}
|
||||
|
||||
if (Thread != null)
|
||||
|
|
@ -417,6 +417,17 @@ namespace Server
|
|||
".TrimMultiline());
|
||||
Utility.PopColor();
|
||||
|
||||
ProcessorCount = Environment.ProcessorCount;
|
||||
|
||||
if (ProcessorCount > 1)
|
||||
{
|
||||
MultiProcessor = true;
|
||||
}
|
||||
|
||||
Console.CancelKeyPress += Console_CancelKeyPressed;
|
||||
|
||||
ServerConfiguration.Load();
|
||||
|
||||
logger.Information($"Running on {RuntimeInformation.FrameworkDescription}");
|
||||
|
||||
var s = Arguments;
|
||||
|
|
@ -426,20 +437,11 @@ namespace Server
|
|||
logger.Information($"Running with arguments: {s}");
|
||||
}
|
||||
|
||||
ProcessorCount = Environment.ProcessorCount;
|
||||
|
||||
if (ProcessorCount > 1)
|
||||
{
|
||||
MultiProcessor = true;
|
||||
}
|
||||
|
||||
if (MultiProcessor)
|
||||
{
|
||||
logger.Information($"Optimizing for {ProcessorCount} processor{(ProcessorCount == 1 ? "" : "s")}");
|
||||
}
|
||||
|
||||
Console.CancelKeyPress += Console_CancelKeyPressed;
|
||||
|
||||
if (GCSettings.IsServerGC)
|
||||
{
|
||||
logger.Information("Server garbage collection mode enabled");
|
||||
|
|
@ -447,8 +449,6 @@ namespace Server
|
|||
|
||||
logger.Information($"High resolution timing ({(Stopwatch.IsHighResolution ? "Supported" : "Unsupported")})");
|
||||
|
||||
ServerConfiguration.Load();
|
||||
|
||||
var assemblyPath = Path.Join(BaseDirectory, AssembliesConfiguration);
|
||||
|
||||
// Load UOContent.dll
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue