Update Program.cs

This commit is contained in:
sonic 2024-08-18 11:36:32 +02:00 committed by GitHub
parent 489f262116
commit 3de3367fb7
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -11,6 +11,13 @@ using System.Net;
var builder = WebApplication.CreateBuilder(args);
// Add services to the container.
bool ConsoleOptions = builder.Configuration.GetSection("ConsoleOptions").GetValue<bool>("Show logs");
// shows information about loading assets/api stuff
if (ConsoleOptions == true)
{
VerboseLogging.log();
}
builder.Services.Configure<AssetServerConfig>(builder.Configuration.GetSection("AssetServer"));
builder.Services.Configure<ApiServerConfig>(builder.Configuration.GetSection("ApiServer"));
@ -66,4 +73,8 @@ app.UseAuthorization();
app.MapControllers();
// Shows message that server started
VerboseLogging.ServerStartedMessage();
OpenGamePrompt.prompt();
PrintInfo.print();
app.Run();