@@ -14,8 +14,6 @@ import net.minecraft.util.Identifier;
|
|||||||
import net.minecraft.util.math.Vec3d;
|
import net.minecraft.util.math.Vec3d;
|
||||||
import org.lwjgl.glfw.GLFW;
|
import org.lwjgl.glfw.GLFW;
|
||||||
|
|
||||||
import net.minecraft.text.Text;
|
|
||||||
|
|
||||||
import skybot.commands.CommandManager;
|
import skybot.commands.CommandManager;
|
||||||
import skybot.controller.Controller;
|
import skybot.controller.Controller;
|
||||||
import skybot.farmers.Farmer;
|
import skybot.farmers.Farmer;
|
||||||
@@ -141,11 +139,7 @@ public class SkybotClient implements ClientModInitializer {
|
|||||||
tickCount++;
|
tickCount++;
|
||||||
if (botEnabled && tickCount % HEALTHCHECK_INTERVAL_TICKS == 0 && !activeFarmer.healthcheck()) {
|
if (botEnabled && tickCount % HEALTHCHECK_INTERVAL_TICKS == 0 && !activeFarmer.healthcheck()) {
|
||||||
ChatMenu.send("§cHealthcheck failed, stopping bot.§r");
|
ChatMenu.send("§cHealthcheck failed, stopping bot.§r");
|
||||||
ChatMenu.send("§cDisconnecting in 3 seconds...§r");
|
|
||||||
stopBot();
|
stopBot();
|
||||||
TickScheduler.schedule(
|
|
||||||
() -> MinecraftClient.getInstance().disconnect(Text.literal("Skybot healthcheck failed")),
|
|
||||||
60);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user