From 7ea3248b48ff5df9c20d272e051bfa75d36407e4 Mon Sep 17 00:00:00 2001 From: hannibal2 <24389977+hannibal00212@users.noreply.github.com> Date: Fri, 17 Mar 2023 12:52:03 +0100 Subject: removed enchanted paper from money per hour display --- .../skyhanni/features/garden/CropMoneyDisplay.kt | 24 ++++++++++------------ 1 file changed, 11 insertions(+), 13 deletions(-) (limited to 'src/main/java/at/hannibal2') diff --git a/src/main/java/at/hannibal2/skyhanni/features/garden/CropMoneyDisplay.kt b/src/main/java/at/hannibal2/skyhanni/features/garden/CropMoneyDisplay.kt index fcfaceae4..8af8bf742 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/garden/CropMoneyDisplay.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/garden/CropMoneyDisplay.kt @@ -43,32 +43,29 @@ class CropMoneyDisplay { @SubscribeEvent fun onTick(event: TickEvent.ClientTickEvent) { if (!isEnabled()) return - if (tick++ % (20 * 5) != 0) return - if (!hasCropInHand && !config.moneyPerHourAlwaysOn) return + update() } private fun update() { init() - if (ready) { - val newDisplay = drawNewDisplay() - display.clear() - display.addAll(newDisplay) - } else { - val newDisplay = mutableListOf>() - newDisplay.add(Collections.singletonList("§7Money per hour when selling:")) - newDisplay.add(Collections.singletonList("§eLoading...")) - display.clear() - display.addAll(newDisplay) - } + val newDisplay = drawNewDisplay() + display.clear() + display.addAll(newDisplay) } private fun drawNewDisplay(): MutableList> { val newDisplay = mutableListOf>() + if (!ready) { + newDisplay.add(Collections.singletonList("§7Money per hour when selling:")) + newDisplay.add(Collections.singletonList("§eLoading...")) + return newDisplay + } + if (!hasCropInHand && !config.moneyPerHourAlwaysOn) return newDisplay newDisplay.add(Collections.singletonList("§7Money per hour when selling:")) @@ -152,6 +149,7 @@ class CropMoneyDisplay { for ((internalName, _) in NotEnoughUpdates.INSTANCE.manager.itemInformation) { if (!BazaarApi.isBazaarItem(internalName)) continue + if (internalName == "ENCHANTED_PAPER") continue val (newId, amount) = NEUItems.getMultiplier(internalName) if (amount < 10) continue -- cgit