From fd42105f7f05261073145a0030659fb1472d6e61 Mon Sep 17 00:00:00 2001 From: blockparole <48992448+blockparole@users.noreply.github.com> Date: Sun, 24 Nov 2019 17:02:39 +0100 Subject: [PATCH] AFP min max values and visibility predicate for timeout ticks --- .../kami/module/modules/combat/AutoFeetPlace.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/main/java/me/zeroeightsix/kami/module/modules/combat/AutoFeetPlace.java b/src/main/java/me/zeroeightsix/kami/module/modules/combat/AutoFeetPlace.java index e4767ddd..bc7cf26b 100644 --- a/src/main/java/me/zeroeightsix/kami/module/modules/combat/AutoFeetPlace.java +++ b/src/main/java/me/zeroeightsix/kami/module/modules/combat/AutoFeetPlace.java @@ -42,8 +42,8 @@ public class AutoFeetPlace extends Module { }; private Setting triggerable = register(Settings.b("Triggerable", true)); - private Setting triggerableTimeoutTicks = register(Settings.i("Triggerable Timeout (Ticks)", 20)); - private Setting blockPerTick = register(Settings.integerBuilder("Blocks per Tick").withMinimum(1).withValue(4).withMaximum(9).build()); + private Setting timeoutTicks = register(Settings.integerBuilder("TimeoutTicks").withMinimum(1).withValue(20).withMaximum(100).withVisibility(b -> triggerable.getValue()).build()); + private Setting blocksPerTick = register(Settings.integerBuilder("Blocks per Tick").withMinimum(1).withValue(4).withMaximum(9).build()); private Setting rotate = register(Settings.b("Rotate", true)); private int playerHotbarSlot = -1; @@ -97,7 +97,7 @@ public class AutoFeetPlace extends Module { return; } - if (triggerable.getValue() && totalTickRuns >= triggerableTimeoutTicks.getValue()) { + if (triggerable.getValue() && totalTickRuns >= timeoutTicks.getValue()) { totalTickRuns = 0; this.disable(); return; @@ -105,7 +105,7 @@ public class AutoFeetPlace extends Module { int blocksPlaced = 0; - while (blocksPlaced < blockPerTick.getValue()) { + while (blocksPlaced < blocksPerTick.getValue()) { if (offsetStep >= surroundTargets.length) { offsetStep = 0;