diff --git a/Server/Server.cs b/Server/Server.cs index a1206f5..d71bfd4 100644 --- a/Server/Server.cs +++ b/Server/Server.cs @@ -138,9 +138,6 @@ public class Server { Client client = new Client(socket) {Server = this}; var remote = socket.RemoteEndPoint; IMemoryOwner memory = null!; - await client.Send(new InitPacket { - MaxPlayers = Settings.Instance.Server.MaxPlayers - }); bool first = true; try { @@ -206,6 +203,11 @@ public class Server { continue; } + // send server init + await client.Send(new InitPacket { + MaxPlayers = Settings.Instance.Server.MaxPlayers, + }); + bool wasFirst = connect.ConnectionType == ConnectPacket.ConnectionTypes.FirstConnection; // add client to the set of connected players