LoginServer should also use the Network.ini configuration file.
This commit is contained in:
@@ -1121,9 +1121,9 @@ public class Config
|
||||
public static boolean PACKET_FLOOD_DISCONNECT;
|
||||
public static boolean PACKET_FLOOD_DROP;
|
||||
public static boolean PACKET_FLOOD_LOGGED;
|
||||
public static boolean TCP_NO_DELAY;
|
||||
public static boolean PACKET_ENCRYPTION;
|
||||
public static boolean FAILED_DECRYPTION_LOGGED;
|
||||
public static boolean TCP_NO_DELAY;
|
||||
|
||||
public static boolean SHOW_LICENCE;
|
||||
public static boolean FLOOD_PROTECTION;
|
||||
@@ -1238,9 +1238,9 @@ public class Config
|
||||
PACKET_FLOOD_DISCONNECT = networkConfig.getBoolean("PacketFloodDisconnect", false);
|
||||
PACKET_FLOOD_DROP = networkConfig.getBoolean("PacketFloodDrop", false);
|
||||
PACKET_FLOOD_LOGGED = networkConfig.getBoolean("PacketFloodLogged", true);
|
||||
TCP_NO_DELAY = networkConfig.getBoolean("TcpNoDelay", true);
|
||||
PACKET_ENCRYPTION = networkConfig.getBoolean("PacketEncryption", false);
|
||||
FAILED_DECRYPTION_LOGGED = networkConfig.getBoolean("FailedDecryptionLogged", true);
|
||||
TCP_NO_DELAY = networkConfig.getBoolean("TcpNoDelay", true);
|
||||
}
|
||||
|
||||
public static void loadRatesConfig()
|
||||
@@ -3048,6 +3048,7 @@ public class Config
|
||||
else if (SERVER_MODE == ServerMode.LOGIN)
|
||||
{
|
||||
loadLoginStartConfig();
|
||||
loadNetworkConfig();
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@@ -478,8 +478,8 @@ public class GameServer
|
||||
server.getNetConfig().setPacketFloodDisconnect(Config.PACKET_FLOOD_DISCONNECT);
|
||||
server.getNetConfig().setPacketFloodDrop(Config.PACKET_FLOOD_DROP);
|
||||
server.getNetConfig().setPacketFloodLogged(Config.PACKET_FLOOD_LOGGED);
|
||||
server.getNetConfig().setTcpNoDelay(Config.TCP_NO_DELAY);
|
||||
server.getNetConfig().setFailedDecryptionLogged(Config.FAILED_DECRYPTION_LOGGED);
|
||||
server.getNetConfig().setTcpNoDelay(Config.TCP_NO_DELAY);
|
||||
server.start();
|
||||
|
||||
LoginServerThread.getInstance().start();
|
||||
|
@@ -135,12 +135,15 @@ public class LoginServer
|
||||
|
||||
final NetServer<LoginClient> server = new NetServer<>(Config.LOGIN_BIND_ADDRESS, Config.PORT_LOGIN, new LoginPacketHandler(), LoginClient::new);
|
||||
server.setName(getClass().getSimpleName());
|
||||
server.getNetConfig().setReadPoolSize(2000);
|
||||
server.getNetConfig().setSendPoolSize(2000);
|
||||
server.getNetConfig().setExecutePoolSize(2000);
|
||||
server.getNetConfig().setPacketQueueLimit(10);
|
||||
server.getNetConfig().setPacketFloodDisconnect(true);
|
||||
server.getNetConfig().setFailedDecryptionLogged(false);
|
||||
server.getNetConfig().setReadPoolSize(Config.CLIENT_READ_POOL_SIZE);
|
||||
server.getNetConfig().setSendPoolSize(Config.CLIENT_SEND_POOL_SIZE);
|
||||
server.getNetConfig().setExecutePoolSize(Config.CLIENT_EXECUTE_POOL_SIZE);
|
||||
server.getNetConfig().setPacketQueueLimit(Config.PACKET_QUEUE_LIMIT);
|
||||
server.getNetConfig().setPacketFloodDisconnect(Config.PACKET_FLOOD_DISCONNECT);
|
||||
server.getNetConfig().setPacketFloodDrop(Config.PACKET_FLOOD_DROP);
|
||||
server.getNetConfig().setPacketFloodLogged(Config.PACKET_FLOOD_LOGGED);
|
||||
server.getNetConfig().setFailedDecryptionLogged(Config.FAILED_DECRYPTION_LOGGED);
|
||||
server.getNetConfig().setTcpNoDelay(Config.TCP_NO_DELAY);
|
||||
server.start();
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user