mirror of
https://github.com/LOOHP/Limbo.git
synced 2026-06-07 21:41:43 +00:00
Clean up
This commit is contained in:
@@ -308,10 +308,7 @@ public class ClientConnection extends Thread {
|
||||
|
||||
state = ClientState.LEGACY;
|
||||
channel.output.writeByte(255);
|
||||
String str = inetAddress.getHostName() + ":" + clientSocket.getPort();
|
||||
if(!properties.isLogPlayerIPAddresses()) {
|
||||
str = "<ip address withheld>" + ":" + clientSocket.getPort();
|
||||
}
|
||||
String str = (properties.isLogPlayerIPAddresses() ? inetAddress.getHostName() : "<ip address withheld>") + ":" + clientSocket.getPort();
|
||||
Limbo.getInstance().getConsole().sendMessage("[/" + str + "] <-> Legacy Status has pinged");
|
||||
ServerProperties p = Limbo.getInstance().getServerProperties();
|
||||
StatusPingEvent event = Limbo.getInstance().getEventsManager().callEvent(new StatusPingEvent(this, p.getVersionString(), p.getProtocol(), p.getMotd(), p.getMaxPlayers(), Limbo.getInstance().getPlayers().size(), p.getFavicon().orElse(null)));
|
||||
@@ -343,10 +340,7 @@ public class ClientConnection extends Thread {
|
||||
if (packetIn instanceof PacketStatusInRequest) {
|
||||
ServerProperties properties = Limbo.getInstance().getServerProperties();
|
||||
|
||||
String str = inetAddress.getHostName() + ":" + clientSocket.getPort();
|
||||
if(!properties.isLogPlayerIPAddresses()) {
|
||||
str = "<ip address withheld>" + ":" + clientSocket.getPort();
|
||||
}
|
||||
String str = (properties.isLogPlayerIPAddresses() ? inetAddress.getHostName() : "<ip address withheld>") + ":" + clientSocket.getPort();
|
||||
if (Limbo.getInstance().getServerProperties().handshakeVerboseEnabled()) {
|
||||
Limbo.getInstance().getConsole().sendMessage("[/" + str + "] <-> Handshake Status has pinged");
|
||||
}
|
||||
@@ -505,10 +499,7 @@ public class ClientConnection extends Thread {
|
||||
PacketPlayOutPlayerAbilities abilities = new PacketPlayOutPlayerAbilities(0.05F, 0.1F, flags.toArray(new PlayerAbilityFlags[flags.size()]));
|
||||
sendPacket(abilities);
|
||||
|
||||
String str = inetAddress.getHostName() + ":" + clientSocket.getPort() + "|" + player.getName() + "(" + player.getUniqueId() + ")";
|
||||
if(!properties.isLogPlayerIPAddresses()) {
|
||||
str = "<ip address withheld>" + ":" + clientSocket.getPort() + "|" + player.getName() + "(" + player.getUniqueId() + ")";
|
||||
}
|
||||
String str = (properties.isLogPlayerIPAddresses() ? inetAddress.getHostName() : "<ip address withheld>") + ":" + clientSocket.getPort() + "|" + player.getName() + "(" + player.getUniqueId() + ")";
|
||||
Limbo.getInstance().getConsole().sendMessage("[/" + str + "] <-> Player had connected to the Limbo server!");
|
||||
|
||||
player.playerInteractManager.update();
|
||||
@@ -676,15 +667,9 @@ public class ClientConnection extends Thread {
|
||||
|
||||
Limbo.getInstance().getEventsManager().callEvent(new PlayerQuitEvent(player));
|
||||
|
||||
str = inetAddress.getHostName() + ":" + clientSocket.getPort() + "|" + player.getName();
|
||||
if(!properties.isLogPlayerIPAddresses()) {
|
||||
str = "<ip address withheld>" + ":" + clientSocket.getPort() + clientSocket.getPort() + "|" + player.getName();
|
||||
}
|
||||
|
||||
str = (properties.isLogPlayerIPAddresses() ? inetAddress.getHostName() : "<ip address withheld>") + ":" + clientSocket.getPort() + "|" + player.getName();
|
||||
Limbo.getInstance().getConsole().sendMessage("[/" + str + "] <-> Player had disconnected!");
|
||||
|
||||
}
|
||||
|
||||
} catch (Exception ignored) {
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user