diff options
author | hannibal2 <24389977+hannibal00212@users.noreply.github.com> | 2023-03-17 12:52:03 +0100 |
---|---|---|
committer | hannibal2 <24389977+hannibal00212@users.noreply.github.com> | 2023-03-17 12:52:03 +0100 |
commit | 7ea3248b48ff5df9c20d272e051bfa75d36407e4 (patch) | |
tree | fdcfcc43c7cdc0a02f381a57936b56ab2b388597 /src | |
parent | c2517a08d5cb83deb91047f0e09c815947ef7ef5 (diff) | |
download | skyhanni-7ea3248b48ff5df9c20d272e051bfa75d36407e4.tar.gz skyhanni-7ea3248b48ff5df9c20d272e051bfa75d36407e4.tar.bz2 skyhanni-7ea3248b48ff5df9c20d272e051bfa75d36407e4.zip |
removed enchanted paper from money per hour display
Diffstat (limited to 'src')
-rw-r--r-- | src/main/java/at/hannibal2/skyhanni/features/garden/CropMoneyDisplay.kt | 24 |
1 files changed, 11 insertions, 13 deletions
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<List<Any>>() - 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<List<Any>> { val newDisplay = mutableListOf<List<Any>>() + 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 |