mirror of
https://github.com/Sanae6/SmoOnlineServer.git
synced 2024-11-22 03:05:16 +00:00
Handle max player count correctly
This commit is contained in:
parent
a554af2a44
commit
557a926a68
1 changed files with 1 additions and 1 deletions
|
@ -31,7 +31,7 @@ public class Server {
|
|||
Logger.Warn($"Accepted connection for client {socket.RemoteEndPoint}");
|
||||
|
||||
try {
|
||||
if (Clients.Count > Constants.MaxClients) {
|
||||
if (Clients.Count == Constants.MaxClients) {
|
||||
Logger.Warn("Turned away client due to max clients");
|
||||
await socket.DisconnectAsync(false);
|
||||
continue;
|
||||
|
|
Loading…
Reference in a new issue