Added client-side ping response handling #96

Closed
huper1 wants to merge 1 commits from patch-1 into main
pull from: patch-1
@@ -99,6 +99,9 @@ public class Bot extends Thread {
client.send(new ServerboundAcceptTeleportationPacket(p.getTeleportId()));
}
else if (packet instanceof ClientboundPingPacket) {
client.send(new ServerboundPongPacket(((ClientboundPingPacket) packet).getId()));
}
else if (packet instanceof ClientboundPlayerCombatKillPacket){
if (Main.autoRespawnDelay >= 0) {
Log.info("Bot " + nickname + " died. Respawning in " + Main.autoRespawnDelay + " ms.");