From fdf5c89d272beb3a8c903de1bcdaa594ad2de3d9 Mon Sep 17 00:00:00 2001 From: jani270 <69345714+jani270@users.noreply.github.com> Date: Wed, 17 Apr 2024 22:26:47 +0200 Subject: Improvement: Patcher Coords Color and Duration (#1476) --- .../skyhanni/config/ConfigUpdaterMigrator.kt | 2 +- .../skyhanni/config/features/misc/MiscConfig.java | 12 ++++------ .../features/misc/PatcherCoordsWaypointConfig.java | 28 ++++++++++++++++++++++ 3 files changed, 34 insertions(+), 8 deletions(-) create mode 100644 src/main/java/at/hannibal2/skyhanni/config/features/misc/PatcherCoordsWaypointConfig.java (limited to 'src/main/java/at/hannibal2/skyhanni/config') diff --git a/src/main/java/at/hannibal2/skyhanni/config/ConfigUpdaterMigrator.kt b/src/main/java/at/hannibal2/skyhanni/config/ConfigUpdaterMigrator.kt index 817be7867..77c732678 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/ConfigUpdaterMigrator.kt +++ b/src/main/java/at/hannibal2/skyhanni/config/ConfigUpdaterMigrator.kt @@ -12,7 +12,7 @@ import com.google.gson.JsonPrimitive object ConfigUpdaterMigrator { val logger = LorenzLogger("ConfigMigration") - const val CONFIG_VERSION = 38 + const val CONFIG_VERSION = 39 fun JsonElement.at(chain: List, init: Boolean): JsonElement? { if (chain.isEmpty()) return this if (this !is JsonObject) return null diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/misc/MiscConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/misc/MiscConfig.java index 8ee2cc926..8b21e3e85 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/features/misc/MiscConfig.java +++ b/src/main/java/at/hannibal2/skyhanni/config/features/misc/MiscConfig.java @@ -102,6 +102,11 @@ public class MiscConfig { @Accordion public NoBitsWarningConfig noBitsWarning = new NoBitsWarningConfig(); + @Expose + @ConfigOption(name = "Patcher Coords Waypoints", desc = "") + @Accordion + public PatcherCoordsWaypointConfig patcherCoordsWaypoint = new PatcherCoordsWaypointConfig(); + @Expose @ConfigOption(name = "Show Outside SB", desc = "Show these features outside of SkyBlock.") @ConfigEditorDraggableList @@ -187,13 +192,6 @@ public class MiscConfig { @FeatureToggle public boolean restorePieceOfWizardPortalLore = true; - @Expose - @ConfigOption(name = "Patcher Coords Waypoint", desc = "Highlight the coordinates sent by Patcher.") - @ConfigEditorBoolean - @FeatureToggle - public boolean patcherSendCoordWaypoint = false; - - @Expose @ConfigOption(name = "Account Upgrade Reminder", desc = "Remind you to claim account upgrades when complete.") @ConfigEditorBoolean diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/misc/PatcherCoordsWaypointConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/misc/PatcherCoordsWaypointConfig.java new file mode 100644 index 000000000..00820e966 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/misc/PatcherCoordsWaypointConfig.java @@ -0,0 +1,28 @@ +package at.hannibal2.skyhanni.config.features.misc; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.notenoughupdates.moulconfig.annotations.ConfigEditorBoolean; +import io.github.notenoughupdates.moulconfig.annotations.ConfigEditorColour; +import io.github.notenoughupdates.moulconfig.annotations.ConfigEditorSlider; +import io.github.notenoughupdates.moulconfig.annotations.ConfigOption; + +public class PatcherCoordsWaypointConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Highlight the coordinates sent by Patcher.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Color", desc = "Color of the waypoint.") + @ConfigEditorColour + public String color = "0:194:75:197:64"; + + @Expose + @ConfigOption(name = "Duration", desc = "Duration of the waypoint.") + @ConfigEditorSlider(minStep = 5, maxValue = 120, minValue = 1) + public int duration = 60; + +} \ No newline at end of file -- cgit