From b99fc8a750a577cd8d985d3c54245d7556d87851 Mon Sep 17 00:00:00 2001 From: hannibal2 <24389977+hannibal00212@users.noreply.github.com> Date: Sun, 28 Jan 2024 18:45:54 +0100 Subject: lazy nether warts --- .../at/hannibal2/skyhanni/features/inventory/HideNotClickableItems.kt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/main/java/at') 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 9b1cc5e26..4088a4264 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/inventory/HideNotClickableItems.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/inventory/HideNotClickableItems.kt @@ -60,6 +60,8 @@ class HideNotClickableItems { "SEEDS|CARROT_ITEM|POTATO_ITEM|PUMPKIN_SEEDS|SUGAR_CANE|MELON_SEEDS|CACTUS|INK_SACK-3" ) + private val netherWart by lazy { "NETHER_STALK".asInternalName() } + @SubscribeEvent fun onRepoReload(event: RepositoryReloadEvent) { val hideNotClickable = event.getConstant("HideNotClickableItems") @@ -382,7 +384,7 @@ class HideNotClickableItems { return true } - if (stack.getInternalName() == "NETHER_STALK".asInternalName()) return false + if (stack.getInternalName() == netherWart) return false hideReason = "This item is not a nether wart!" return true -- cgit