diff --git a/src/api/java/baritone/api/Settings.java b/src/api/java/baritone/api/Settings.java index a835ed73..1a3fef08 100644 --- a/src/api/java/baritone/api/Settings.java +++ b/src/api/java/baritone/api/Settings.java @@ -553,6 +553,12 @@ public class Settings { */ public final List> allSettings; + public void reset() { + for (Setting setting : allSettings) { + setting.value = setting.defaultValue; + } + } + public class Setting { public T value; public final T defaultValue; diff --git a/src/main/java/baritone/utils/ExampleBaritoneControl.java b/src/main/java/baritone/utils/ExampleBaritoneControl.java index 2c112ee3..958af776 100644 --- a/src/main/java/baritone/utils/ExampleBaritoneControl.java +++ b/src/main/java/baritone/utils/ExampleBaritoneControl.java @@ -277,6 +277,11 @@ public class ExampleBaritoneControl extends Behavior implements Helper { }); return true; } + if (msg.equals("reset")) { + Baritone.settings().reset(); + logDirect("Baritone settings reset"); + return true; + } if (msg.startsWith("followplayers")) { baritone.getFollowProcess().follow(EntityPlayer.class::isInstance); // O P P A logDirect("Following any players");