aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/at/hannibal2/skyhanni/features/garden
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/features/garden')
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/garden/farming/GardenCropMilestoneDisplay.kt6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/features/garden/farming/GardenCropMilestoneDisplay.kt b/src/main/java/at/hannibal2/skyhanni/features/garden/farming/GardenCropMilestoneDisplay.kt
index 0442e4ffe..7145c77d2 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/garden/farming/GardenCropMilestoneDisplay.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/garden/farming/GardenCropMilestoneDisplay.kt
@@ -312,6 +312,9 @@ class GardenCropMilestoneDisplay {
lineMap[5] = Collections.singletonList("§7Blocks/Second§8: §e$lastBlocksPerSecond")
}
+ val percentageFormat = LorenzUtils.formatPercentage(have.toDouble() / need.toDouble())
+ lineMap[6] = Collections.singletonList("§7Percentage: §e$percentageFormat")
+
if (GardenAPI.mushroomCowPet && crop != CropType.MUSHROOM) {
if (mushroom_cow_nether_warts && crop == CropType.NETHER_WART) {
mushroomCowPerkDisplay = listOf(
@@ -377,6 +380,9 @@ class GardenCropMilestoneDisplay {
lineMap[2] = Collections.singletonList("§e$haveFormat§8/§e$needFormat")
lineMap[3] = Collections.singletonList("§7In §b$duration")
+ val percentageFormat = LorenzUtils.formatPercentage(have.toDouble() / need.toDouble())
+ lineMap[4] = Collections.singletonList("§7Percentage: §e$percentageFormat")
+
val newList = mutableListOf<List<Any>>()
for (index in config.cropMilestoneMushroomPetPerkText) {
lineMap[index]?.let {