diff options
author | hannibal2 <24389977+hannibal00212@users.noreply.github.com> | 2023-01-15 22:38:13 +0100 |
---|---|---|
committer | hannibal2 <24389977+hannibal00212@users.noreply.github.com> | 2023-01-15 22:38:13 +0100 |
commit | 762cfe41c1317935b9390a759c14aaf197e688f4 (patch) | |
tree | eaa28e0402a567e9c1aa6e98eb33bdfc02a6e5ae | |
parent | ee7538da5cb41c299794ba04ff3ee43a4cbbf9be (diff) | |
download | skyhanni-762cfe41c1317935b9390a759c14aaf197e688f4.tar.gz skyhanni-762cfe41c1317935b9390a759c14aaf197e688f4.tar.bz2 skyhanni-762cfe41c1317935b9390a759c14aaf197e688f4.zip |
Added toggle config.
7 files changed, 32 insertions, 8 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md index 76cb4b0a8..bd19924f9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,7 +3,8 @@ ## Version 0.14.1 ### Features -+ Added Bazaar Update Timer - Forrick ++ Added Bazaar Update Timer - Forrick. ++ Added Crimson Isle Reputation Helper. ## Version 0.14 diff --git a/FEATURES.md b/FEATURES.md index efdc25808..73aca5573 100644 --- a/FEATURES.md +++ b/FEATURES.md @@ -162,4 +162,5 @@ - Display the active non-god potion effects. - Option to hide blaze particles. - Wishing compass uses amount display. -- Brewing Stand Overlay.
\ No newline at end of file +- Brewing Stand Overlay. +- Crimson Isle Reputation Helper.
\ No newline at end of file diff --git a/src/main/java/at/hannibal2/skyhanni/config/Features.java b/src/main/java/at/hannibal2/skyhanni/config/Features.java index 0f3b52c2a..61bdf55a1 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/Features.java +++ b/src/main/java/at/hannibal2/skyhanni/config/Features.java @@ -111,6 +111,11 @@ public class Features extends Config { editOverlay(activeConfigCategory, 200, 16, bazaar.updateTimerPos); return; } + + if (runnableId.equals("crimsonIsleReputationHelper")) { + editOverlay(activeConfigCategory, 200, 16, misc.crimsonIsleReputationHelperPos); + return; + } } @Expose diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/Misc.java b/src/main/java/at/hannibal2/skyhanni/config/features/Misc.java index 58186b08e..9ac1057ed 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/features/Misc.java +++ b/src/main/java/at/hannibal2/skyhanni/config/features/Misc.java @@ -131,11 +131,6 @@ public class Misc { public boolean hideBlazeParticles = false; @Expose - @ConfigOption(name = "Config Button", desc = "Add a button to the pause menu to configure SkyHanni.") - @ConfigEditorBoolean - public boolean configButtonOnPause = true; - - @Expose @ConfigOption(name = "Collection Counter Position", desc = "Tracking the number of items you collect. §cDoes not work with sacks.") @ConfigEditorButton(runnableId = "collectionCounter", buttonText = "Edit") public Position collectionCounterPos = new Position(10, 10, false, true); @@ -144,4 +139,19 @@ public class Misc { @ConfigOption(name = "Brewing Stand Overlay", desc = "Display the Item names directly inside the Brewing Stand") @ConfigEditorBoolean public boolean brewingStandOverlay = true; + + @Expose + @ConfigOption(name = "Crimson Isle Reputation", desc = "Enable features around Reputation features in the Crimson Isle") + @ConfigEditorBoolean + public boolean crimsonIsleReputationHelper = true; + + @Expose + @ConfigOption(name = "Collection Counter Position", desc = "Tracking the number of items you collect. §cDoes not work with sacks.") + @ConfigEditorButton(runnableId = "crimsonIsleReputationHelper", buttonText = "Edit") + public Position crimsonIsleReputationHelperPos = new Position(10, 10, false, true); + + @Expose + @ConfigOption(name = "Config Button", desc = "Add a button to the pause menu to configure SkyHanni.") + @ConfigEditorBoolean + public boolean configButtonOnPause = true; }
\ No newline at end of file diff --git a/src/main/java/at/hannibal2/skyhanni/features/nether/reputationhelper/CrimsonIsleReputationHelper.kt b/src/main/java/at/hannibal2/skyhanni/features/nether/reputationhelper/CrimsonIsleReputationHelper.kt index c86c968d1..cf936c9fb 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/nether/reputationhelper/CrimsonIsleReputationHelper.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/nether/reputationhelper/CrimsonIsleReputationHelper.kt @@ -47,6 +47,7 @@ class CrimsonIsleReputationHelper(skyHanniMod: SkyHanniMod) { fun onTick(event: TickEvent.ClientTickEvent) { if (!HyPixelData.skyBlock) return if (LorenzUtils.skyBlockIsland != IslandType.CRIMSON_ISLE) return + if (!SkyHanniMod.feature.misc.crimsonIsleReputationHelper) return if (dirty) { dirty = false updateRender() @@ -64,11 +65,12 @@ class CrimsonIsleReputationHelper(skyHanniMod: SkyHanniMod) { @SubscribeEvent(priority = EventPriority.LOWEST) fun renderOverlay(event: RenderGameOverlayEvent.Post) { if (event.type != RenderGameOverlayEvent.ElementType.ALL) return + if (!SkyHanniMod.feature.misc.crimsonIsleReputationHelper) return if (!HyPixelData.skyBlock) return if (LorenzUtils.skyBlockIsland != IslandType.CRIMSON_ISLE) return - SkyHanniMod.feature.dev.debugPos.renderStrings(display) + SkyHanniMod.feature.misc.crimsonIsleReputationHelperPos.renderStrings(display) } fun update() { diff --git a/src/main/java/at/hannibal2/skyhanni/features/nether/reputationhelper/dailyquest/DailyQuestHelper.kt b/src/main/java/at/hannibal2/skyhanni/features/nether/reputationhelper/dailyquest/DailyQuestHelper.kt index 463cd3347..f0e6b9fdb 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/nether/reputationhelper/dailyquest/DailyQuestHelper.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/nether/reputationhelper/dailyquest/DailyQuestHelper.kt @@ -34,6 +34,7 @@ class DailyQuestHelper(val reputationHelper: CrimsonIsleReputationHelper) { fun onTick(event: TickEvent.ClientTickEvent) { if (!HyPixelData.skyBlock) return if (LorenzUtils.skyBlockIsland != IslandType.CRIMSON_ISLE) return + if (!SkyHanniMod.feature.misc.crimsonIsleReputationHelper) return tick++ if (tick % 20 == 0) { loader.checkInventory() @@ -80,6 +81,8 @@ class DailyQuestHelper(val reputationHelper: CrimsonIsleReputationHelper) { fun onBackgroundDrawn(event: GuiContainerEvent.BackgroundDrawnEvent) { if (!HyPixelData.skyBlock) return if (LorenzUtils.skyBlockIsland != IslandType.CRIMSON_ISLE) return + if (!SkyHanniMod.feature.misc.crimsonIsleReputationHelper) return + if (event.gui !is GuiChest) return val chest = event.gui.inventorySlots as ContainerChest val chestName = chest.getInventoryName() @@ -136,6 +139,7 @@ class DailyQuestHelper(val reputationHelper: CrimsonIsleReputationHelper) { fun onChat(event: LorenzChatEvent) { if (!HyPixelData.skyBlock) return if (LorenzUtils.skyBlockIsland != IslandType.CRIMSON_ISLE) return + if (!SkyHanniMod.feature.misc.crimsonIsleReputationHelper) return val message = event.message if (message == "§aYou completed your Dojo quest! Visit the Town Board to claim the rewards.") { diff --git a/src/main/java/at/hannibal2/skyhanni/features/nether/reputationhelper/miniboss/DailyMiniBossHelper.kt b/src/main/java/at/hannibal2/skyhanni/features/nether/reputationhelper/miniboss/DailyMiniBossHelper.kt index 9e72ff2c5..14892dff6 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/nether/reputationhelper/miniboss/DailyMiniBossHelper.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/nether/reputationhelper/miniboss/DailyMiniBossHelper.kt @@ -30,6 +30,7 @@ class DailyMiniBossHelper(private val reputationHelper: CrimsonIsleReputationHel fun onChat(event: LorenzChatEvent) { if (!HyPixelData.skyBlock) return if (LorenzUtils.skyBlockIsland != IslandType.CRIMSON_ISLE) return + if (!SkyHanniMod.feature.misc.crimsonIsleReputationHelper) return val message = event.message for (miniBoss in miniBosses) { |