From 73a2b5155db2bdac4746e681d5d770bd7f0c3aaf Mon Sep 17 00:00:00 2001 From: hannibal2 <24389977+hannibal002@users.noreply.github.com> Date: Wed, 4 Sep 2024 08:53:10 +0200 Subject: Fix: Profit Tracker coin formatting (#2444) Co-authored-by: hannibal2 <24389977+hannibal00212@users.noreply.github.com> --- src/main/java/at/hannibal2/skyhanni/data/SlayerAPI.kt | 8 ++++++-- .../at/hannibal2/skyhanni/utils/tracker/SkyHanniItemTracker.kt | 1 + 2 files changed, 7 insertions(+), 2 deletions(-) (limited to 'src/main/java/at/hannibal2') diff --git a/src/main/java/at/hannibal2/skyhanni/data/SlayerAPI.kt b/src/main/java/at/hannibal2/skyhanni/data/SlayerAPI.kt index 4f3b3713c..0d91c7f62 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/SlayerAPI.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/SlayerAPI.kt @@ -47,9 +47,13 @@ object SlayerAPI { val totalPrice = maxPrice * amount val format = totalPrice.shortFormat() - val priceFormat = " §7(§6$format coins§7)" - "$amountFormat$displayName$priceFormat" to totalPrice + if (internalName == NEUInternalName.SKYBLOCK_COIN) { + "§6$format coins" to totalPrice + } else { + val priceFormat = " §7(§6$format coins§7)" + "$amountFormat$displayName$priceFormat" to totalPrice + } } @SubscribeEvent diff --git a/src/main/java/at/hannibal2/skyhanni/utils/tracker/SkyHanniItemTracker.kt b/src/main/java/at/hannibal2/skyhanni/utils/tracker/SkyHanniItemTracker.kt index f249cce3e..684a7eb00 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/tracker/SkyHanniItemTracker.kt +++ b/src/main/java/at/hannibal2/skyhanni/utils/tracker/SkyHanniItemTracker.kt @@ -43,6 +43,7 @@ class SkyHanniItemTracker( it.get(DisplayMode.SESSION).items[internalName]!!.hidden = hidden } + // TODO move the function to common val (itemName, price) = SlayerAPI.getItemNameAndPrice(internalName, amount) if (config.warnings.chat && price >= config.warnings.minimumChat) { ChatUtils.chat("§a+Tracker Drop§7: §r$itemName") -- cgit