diff options
author | hannibal2 <24389977+hannibal00212@users.noreply.github.com> | 2023-05-23 00:33:07 +0200 |
---|---|---|
committer | hannibal2 <24389977+hannibal00212@users.noreply.github.com> | 2023-05-23 00:33:07 +0200 |
commit | 4dec09c6d96567f69ca92199bc263a8fbd9cd166 (patch) | |
tree | c72ea26a2b314ca0944a72c55bd803f8b5775cf9 /src/main/java/at/hannibal2/skyhanni | |
parent | 698e166a984499c402b9689696234fdbc707fdec (diff) | |
download | skyhanni-4dec09c6d96567f69ca92199bc263a8fbd9cd166.tar.gz skyhanni-4dec09c6d96567f69ca92199bc263a8fbd9cd166.tar.bz2 skyhanni-4dec09c6d96567f69ca92199bc263a8fbd9cd166.zip |
Added extra setting to allow/block clicks for the 'hide not clickable' feature
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni')
-rw-r--r-- | src/main/java/at/hannibal2/skyhanni/config/features/Inventory.java | 8 | ||||
-rw-r--r-- | src/main/java/at/hannibal2/skyhanni/features/inventory/HideNotClickableItems.kt | 1 |
2 files changed, 8 insertions, 1 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/Inventory.java b/src/main/java/at/hannibal2/skyhanni/config/features/Inventory.java index c6085250f..0a357a8f3 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/features/Inventory.java +++ b/src/main/java/at/hannibal2/skyhanni/config/features/Inventory.java @@ -15,12 +15,18 @@ public class Inventory { public boolean hideNotClickable = false; @Expose - @ConfigOption(name = "Not Clickable Items Enabled", desc = "Hide items that are not clickable in the current inventory: ah, bz, accessory bag, etc.") + @ConfigOption(name = "Enabled", desc = "Hide items that are not clickable in the current inventory: ah, bz, accessory bag, etc.") @ConfigEditorBoolean @ConfigAccordionId(id = 0) public boolean hideNotClickableItems = false; @Expose + @ConfigOption(name = "Block Clicks", desc = "Block the clicks on these items.") + @ConfigEditorBoolean + @ConfigAccordionId(id = 0) + public boolean hideNotClickableItemsBlockClicks = true; + + @Expose @ConfigOption( name = "Opacity", desc = "How strong should the items be grayed out?" diff --git a/src/main/java/at/hannibal2/skyhanni/features/inventory/HideNotClickableItems.kt b/src/main/java/at/hannibal2/skyhanni/features/inventory/HideNotClickableItems.kt index 1b53bbf0e..6b061d1bc 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/inventory/HideNotClickableItems.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/inventory/HideNotClickableItems.kt @@ -125,6 +125,7 @@ class HideNotClickableItems { @SubscribeEvent fun onSlotClick(event: GuiContainerEvent.SlotClickEvent) { if (isDisabled()) return + if (!SkyHanniMod.feature.inventory.hideNotClickableItemsBlockClicks) return if (event.gui !is GuiChest) return val chestName = InventoryUtils.openInventoryName() |