aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhannibal2 <24389977+hannibal00212@users.noreply.github.com>2023-05-23 00:33:07 +0200
committerhannibal2 <24389977+hannibal00212@users.noreply.github.com>2023-05-23 00:33:07 +0200
commit4dec09c6d96567f69ca92199bc263a8fbd9cd166 (patch)
treec72ea26a2b314ca0944a72c55bd803f8b5775cf9
parent698e166a984499c402b9689696234fdbc707fdec (diff)
downloadskyhanni-4dec09c6d96567f69ca92199bc263a8fbd9cd166.tar.gz
skyhanni-4dec09c6d96567f69ca92199bc263a8fbd9cd166.tar.bz2
skyhanni-4dec09c6d96567f69ca92199bc263a8fbd9cd166.zip
Added extra setting to allow/block clicks for the 'hide not clickable' feature
-rw-r--r--CHANGELOG.md1
-rw-r--r--FEATURES.md5
-rw-r--r--src/main/java/at/hannibal2/skyhanni/config/features/Inventory.java8
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/inventory/HideNotClickableItems.kt1
4 files changed, 13 insertions, 2 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 1cafe7a83..290b3c312 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -24,6 +24,7 @@
+ Improved detection speed
+ Derpy double health support
+ More fair detection logic
++ Added extra setting to allow/block clicks for the 'hide not clickable' feature
### Fixes
= Fixed typos in Trevor Trapper texts (Contributed by CalMWolfs)
diff --git a/FEATURES.md b/FEATURES.md
index bd5a666c8..afeb6f931 100644
--- a/FEATURES.md
+++ b/FEATURES.md
@@ -44,7 +44,10 @@
- Visual highlight chests that have not yet been opened in the Croesus inventory.
## Inventory
-- Not Clickable Items: Mark items gray in your inventory when they are not supposed to be moved in certain GUIs, and make green lines around items that meet that requirement. (in NPC sell inventories, ender chests and backpacks, salvaging in the dungeon hub, player trade, bazaar, action house, accessory bag, sack of sacks, fishing bag, potion bag, chests on the private island, attribute fusion and equipment GUI)
+- Not Clickable Items
+ - Mark items gray in your inventory when they are not supposed to be moved in certain GUIs, and make green lines around items that meet that requirement.
+ - In NPC sell inventories, ender chests and backpacks, salvaging in the dungeon hub, player trade, bazaar, action house, accessory bag, sack of sacks, fishing bag, potion bag, chests on the private island, attribute fusion and equipment GUI
+ - Option to allow/block clicks
- Option to change the gray-out opacity for 'Not Clickable Items'.
- Set stack number for specific items (stars for crimson armor, minion tier, pet level, new year cake, for golden and diamond dungeon heads the floor number, the tier of master skull and master star, kuudra keys, skill level, and collection level)
- Sack name (show short name of sacks)
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()