aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/at/hannibal2/skyhanni/features/fame
diff options
context:
space:
mode:
authorhannibal2 <24389977+hannibal00212@users.noreply.github.com>2024-06-14 15:56:08 +0200
committerhannibal2 <24389977+hannibal00212@users.noreply.github.com>2024-06-14 15:56:08 +0200
commit34e2d19a32f36ddef298668788447aed01c62703 (patch)
tree65db564add674443a43bf65e71091e9d965f117a /src/main/java/at/hannibal2/skyhanni/features/fame
parenta996d8150ef2367e7c839f3565d60bdb68d2125d (diff)
downloadskyhanni-34e2d19a32f36ddef298668788447aed01c62703.tar.gz
skyhanni-34e2d19a32f36ddef298668788447aed01c62703.tar.bz2
skyhanni-34e2d19a32f36ddef298668788447aed01c62703.zip
fixing and using shortFormat()
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/features/fame')
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/fame/CityProjectFeatures.kt23
1 files changed, 14 insertions, 9 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/features/fame/CityProjectFeatures.kt b/src/main/java/at/hannibal2/skyhanni/features/fame/CityProjectFeatures.kt
index c707e2209..c411951c3 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/fame/CityProjectFeatures.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/fame/CityProjectFeatures.kt
@@ -23,8 +23,8 @@ import at.hannibal2.skyhanni.utils.NEUInternalName
import at.hannibal2.skyhanni.utils.NEUItems
import at.hannibal2.skyhanni.utils.NEUItems.getItemStack
import at.hannibal2.skyhanni.utils.NEUItems.getPrice
-import at.hannibal2.skyhanni.utils.NumberUtil
import at.hannibal2.skyhanni.utils.NumberUtil.addSeparators
+import at.hannibal2.skyhanni.utils.NumberUtil.shortFormat
import at.hannibal2.skyhanni.utils.RegexUtils.matchFirst
import at.hannibal2.skyhanni.utils.RegexUtils.matches
import at.hannibal2.skyhanni.utils.RenderUtils.highlight
@@ -158,16 +158,21 @@ object CityProjectFeatures {
list.add(" §7- ")
list.add(stack)
- list.add(Renderable.optionalLink("$name §ex${amount.addSeparators()}", {
- if (Minecraft.getMinecraft().currentScreen is GuiEditSign) {
- LorenzUtils.setTextIntoSign("$amount")
- } else {
- BazaarApi.searchForBazaarItem(name, amount)
- }
- }) { inInventory && !NEUItems.neuHasFocus() })
+ list.add(
+ Renderable.optionalLink(
+ "$name §ex${amount.addSeparators()}",
+ {
+ if (Minecraft.getMinecraft().currentScreen is GuiEditSign) {
+ LorenzUtils.setTextIntoSign("$amount")
+ } else {
+ BazaarApi.searchForBazaarItem(name, amount)
+ }
+ }
+ ) { inInventory && !NEUItems.neuHasFocus() }
+ )
val price = internalName.getPrice(false) * amount
- val format = NumberUtil.format(price)
+ val format = price.shortFormat()
list.add(" §7(§6$format§7)")
add(list)
}