aboutsummaryrefslogtreecommitdiff
path: root/src/main/java
diff options
context:
space:
mode:
authorHiZe_ <superhize@hotmail.com>2023-10-26 16:54:45 +0200
committerGitHub <noreply@github.com>2023-10-26 16:54:45 +0200
commit0b7cf28c3a8cf911ef85f079a49d4a1781e5915f (patch)
tree4972bd6d3aaa345a8f0fd515b00b17770fdf6a6d /src/main/java
parentc8471f6629aabcc887b58947706ee79d6b89bab9 (diff)
downloadskyhanni-0b7cf28c3a8cf911ef85f079a49d4a1781e5915f.tar.gz
skyhanni-0b7cf28c3a8cf911ef85f079a49d4a1781e5915f.tar.bz2
skyhanni-0b7cf28c3a8cf911ef85f079a49d4a1781e5915f.zip
Update: Option to disable chest value in dungeons (#591)
Chest value is now default disabled in dungeon, and added an option to enable it. #591
Diffstat (limited to 'src/main/java')
-rw-r--r--src/main/java/at/hannibal2/skyhanni/config/features/InventoryConfig.java8
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/inventory/ChestValue.kt3
2 files changed, 9 insertions, 2 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/InventoryConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/InventoryConfig.java
index 8d3c4a56d..9ddaae675 100644
--- a/src/main/java/at/hannibal2/skyhanni/config/features/InventoryConfig.java
+++ b/src/main/java/at/hannibal2/skyhanni/config/features/InventoryConfig.java
@@ -233,12 +233,18 @@ public class InventoryConfig {
public static class ChestValueConfig {
@Expose
- @ConfigOption(name = "Enabled", desc = "Enabled estimated value of chest")
+ @ConfigOption(name = "Enabled", desc = "Enable estimated value of chest")
@ConfigEditorBoolean
@FeatureToggle
public boolean enabled = false;
@Expose
+ @ConfigOption(name = "Enabled in dungeons", desc = "Enable the feature in dungeons.")
+ @ConfigEditorBoolean
+ @FeatureToggle
+ public boolean enableInDungeons = false;
+
+ @Expose
@ConfigOption(name = "Show Stacks", desc = "Show the item icon before name.")
@ConfigEditorBoolean
public boolean showStacks = true;
diff --git a/src/main/java/at/hannibal2/skyhanni/features/inventory/ChestValue.kt b/src/main/java/at/hannibal2/skyhanni/features/inventory/ChestValue.kt
index 52d1627d9..52e6d3b8d 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/inventory/ChestValue.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/inventory/ChestValue.kt
@@ -40,6 +40,7 @@ class ChestValue {
@SubscribeEvent
fun onBackgroundDraw(event: GuiRenderEvent.ChestGuiOverlayRenderEvent) {
if (!isEnabled()) return
+ if (LorenzUtils.inDungeons && !config.enableInDungeons) return
if (InventoryUtils.openInventoryName() == "") return
if (inInventory) {
config.position.renderStringsAndItems(
@@ -274,4 +275,4 @@ class ChestValue {
)
private fun isEnabled() = LorenzUtils.inSkyBlock && config.enabled
-} \ No newline at end of file
+}