mirror of
https://git.lewd.wtf/PGR/ascnet
synced 2025-12-13 11:54:35 +01:00
command yay!
This commit is contained in:
@@ -19,12 +19,16 @@ namespace AscNet.GameServer
|
||||
}
|
||||
}
|
||||
|
||||
public Server()
|
||||
static Server()
|
||||
{
|
||||
// TODO: add loglevel based on appsettings
|
||||
LogLevel logLevel = LogLevel.DEBUG;
|
||||
LogLevel fileLogLevel = LogLevel.DEBUG;
|
||||
log = new(typeof(Server), logLevel, fileLogLevel);
|
||||
}
|
||||
|
||||
public Server()
|
||||
{
|
||||
listener = new(IPAddress.Parse("0.0.0.0"), Common.Common.config.GameServer.Port);
|
||||
}
|
||||
|
||||
@@ -54,5 +58,10 @@ namespace AscNet.GameServer
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public Session? SessionFromUID(long uid)
|
||||
{
|
||||
return Sessions.FirstOrDefault(x => x.Value.player.PlayerData.Id == uid).Value;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user