mirror of
https://github.com/Nan1t/NanoLimbo.git
synced 2026-02-10 02:46:13 +01:00
Ability to set infinite number of connections
This commit is contained in:
@@ -139,7 +139,8 @@ public class ClientConnection extends ChannelInboundHandlerAdapter {
|
||||
}
|
||||
|
||||
if (packet instanceof PacketLoginStart) {
|
||||
if (server.getConnections().getCount() >= server.getConfig().getMaxPlayers()) {
|
||||
if (server.getConfig().getMaxPlayers() > 0 &&
|
||||
server.getConnections().getCount() >= server.getConfig().getMaxPlayers()) {
|
||||
disconnectLogin("Too many players connected");
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user