aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLinnea Gräf <nea@nea.moe>2025-06-07 23:18:45 +0200
committerLinnea Gräf <nea@nea.moe>2025-06-07 23:19:12 +0200
commit029fd1527816a05de1a81efbc93fca37f2cb3411 (patch)
tree653ed82cdd8ac94a6566855bd2468b955c1685ea
parentdf8c8a02a04d48345e8e44d868f18e12dff01aab (diff)
downloadFirmament-029fd1527816a05de1a81efbc93fca37f2cb3411.tar.gz
Firmament-029fd1527816a05de1a81efbc93fca37f2cb3411.tar.bz2
Firmament-029fd1527816a05de1a81efbc93fca37f2cb3411.zip
feat: add "showing prices for x" message to multiply prices
-rw-r--r--src/main/kotlin/features/inventory/PriceData.kt14
1 files changed, 10 insertions, 4 deletions
diff --git a/src/main/kotlin/features/inventory/PriceData.kt b/src/main/kotlin/features/inventory/PriceData.kt
index 9f6a8bb..77ea03c 100644
--- a/src/main/kotlin/features/inventory/PriceData.kt
+++ b/src/main/kotlin/features/inventory/PriceData.kt
@@ -35,7 +35,7 @@ object PriceData : FirmamentFeature {
.append(": ")
.append(
Text.literal(formatCommas(price, fractionalDigits = 1))
- .append(if(price != 1.0) " coins" else " coin")
+ .append(if (price != 1.0) " coins" else " coin")
.gold()
.bold()
)
@@ -48,10 +48,16 @@ object PriceData : FirmamentFeature {
}
val sbId = it.stack.skyBlockId
val stackSize = it.stack.count
- val multiplier = if (TConfig.stackSizeKey.isPressed(atLeast = true)) stackSize else 1
+ val isShowingStack = TConfig.stackSizeKey.isPressed(atLeast = true)
+ val multiplier = if (isShowingStack) stackSize else 1
val multiplierText =
- Text.literal("[").append(TConfig.stackSizeKey.format().string).append(" to show x").append("${stackSize}]")
- .darkGrey()
+ if (isShowingStack)
+ tr("firmament.tooltip.multiply", "Showing prices for x${stackSize}").darkGrey()
+ else
+ tr(
+ "firmament.tooltip.multiply.hint",
+ "[${TConfig.stackSizeKey.format()}] to show x${stackSize}"
+ ).darkGrey()
val bazaarData = HypixelStaticData.bazaarData[sbId]
val lowestBin = HypixelStaticData.lowestBin[sbId]
if (bazaarData != null) {