diff options
author | hannibal2 <24389977+hannibal00212@users.noreply.github.com> | 2023-11-19 23:23:46 +0100 |
---|---|---|
committer | hannibal2 <24389977+hannibal00212@users.noreply.github.com> | 2023-11-19 23:23:46 +0100 |
commit | ca6533796afc38290199a693617dc43b16cd32bb (patch) | |
tree | 0156d79ee853aa2bcf73a19b225b65657268068a /src/main/java/at | |
parent | 48b57914c726993bbe76886e44f580c89f6e8d3b (diff) | |
download | skyhanni-ca6533796afc38290199a693617dc43b16cd32bb.tar.gz skyhanni-ca6533796afc38290199a693617dc43b16cd32bb.tar.bz2 skyhanni-ca6533796afc38290199a693617dc43b16cd32bb.zip |
better saving latest ff tool, and showing old saved ff while switching
Diffstat (limited to 'src/main/java/at')
-rw-r--r-- | src/main/java/at/hannibal2/skyhanni/features/garden/FarmingFortuneDisplay.kt | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/features/garden/FarmingFortuneDisplay.kt b/src/main/java/at/hannibal2/skyhanni/features/garden/FarmingFortuneDisplay.kt index 6f468bd83..ac48b1ec2 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/garden/FarmingFortuneDisplay.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/garden/FarmingFortuneDisplay.kt @@ -19,6 +19,7 @@ import at.hannibal2.skyhanni.utils.LorenzUtils import at.hannibal2.skyhanni.utils.LorenzUtils.addAsSingletonList import at.hannibal2.skyhanni.utils.LorenzUtils.nextAfter import at.hannibal2.skyhanni.utils.NEUInternalName +import at.hannibal2.skyhanni.utils.NumberUtil.addSeparators import at.hannibal2.skyhanni.utils.RenderUtils.renderString import at.hannibal2.skyhanni.utils.RenderUtils.renderStringsAndItems import at.hannibal2.skyhanni.utils.SimpleTimeMark @@ -112,11 +113,13 @@ class FarmingFortuneDisplay { list.add( "§6Farming Fortune§7: §e" + if (!recentlySwitchedTool && farmingFortune != -1.0) { LorenzUtils.formatDouble(farmingFortune, 0) - } else "?" + } else "§7" + (displayCrop.getLatestTrueFarmingFortune()?.addSeparators() ?: "?") ) if (GardenAPI.cropInHand == currentCrop) { - latestFF?.put(currentCrop, getCurrentFarmingFortune(true)) + if (!recentlySwitchedTool) { + latestFF?.put(currentCrop, getCurrentFarmingFortune(true)) + } } }) |