Fix being able to join direct connection lobbies past max players
This commit is contained in:
parent
270244d02d
commit
ef43b197d0
|
@ -80,6 +80,7 @@ void network_send_join(struct Packet* joinRequestPacket) {
|
|||
u8 globalIndex = joinRequestPacket->localIndex;
|
||||
if (globalIndex == UNKNOWN_LOCAL_INDEX) {
|
||||
for (u32 i = 1; i < MAX_PLAYERS; i++) {
|
||||
if (i >= gServerSettings.maxPlayers) { break; }
|
||||
if (!gNetworkPlayers[i].connected) {
|
||||
globalIndex = i;
|
||||
break;
|
||||
|
|
Loading…
Reference in New Issue