Network.maxConnections doesn't work

I want to be able to create a server with 8 players and then when the game starts, close the server to new clients (i.e. no one should be allowed to enter in the middle of a game), so I set Network.maxConnections to prevent this.

I’ve tried setting it to the amount of players already logged in, to 0 and to -1, and still new clients are able to connect.

At the moment the only workaround I have is when a client connects while the game is running, the server will kick it, the problem is that not only it is an ugly way of doing it but also the client will see the buffered RPCs execute (e.g. level loading).

Is this bug going to be corrected for the next update?

Regards,
Afonso

A simple way is to disable connecting to a host where connected players == max players.
In our case, we do a GUI.disabled on the Join button.

Yeah, but that only works if the master server has the exact info from the server (it can have a out of date info).

Also, we have a direct IP connection, which doesn’t go through the master server :-\

any luck with this? i’m having the same issue and am also using direct ip connect.

thanks,
jason

Why not simply set your server correctly when you initialize it through

Network.InitializeServer (connections : int, listenPort : int)

I don’t see why you would want to alter the amount after the server is initialized because what is the server meant to do if more are connected then you want to set as max. Who is meant to be kicked?
That just as a simple obvious problem such an attempt will bring up

If you want to restrict it, you would instead send a specific RPC to the player in

and inform the player that the server is full and kick him again