diff --git a/2006Redone Server/src/redone/game/bots/Bot.java b/2006Redone Server/src/redone/game/bots/Bot.java index 0e2ad95d..ec95ff28 100644 --- a/2006Redone Server/src/redone/game/bots/Bot.java +++ b/2006Redone Server/src/redone/game/bots/Bot.java @@ -9,10 +9,8 @@ import redone.util.GameLogger; import redone.util.Misc; import java.nio.charset.StandardCharsets; -import java.util.ArrayList; -import java.util.Random; -import java.util.Timer; -import java.util.TimerTask; +import java.text.DecimalFormat; +import java.util.*; import static redone.game.players.PlayerSave.loadPlayerInfo; @@ -85,12 +83,13 @@ public class Bot { } private String formatSellPrice(int price) { - if (price > 1e9) { - return (Math.floor(price / 1e8) / 10) + "B"; - } else if (price > 1e6) { - return (Math.floor(price / 1e5) / 10) + "M"; - } else if (price > 1e3) { - return (Math.floor(price / 100) / 10) + "K"; + DecimalFormat df = new DecimalFormat("#.##"); + if (price >= 1e9) { + return df.format(Math.floor(price / 1e8) / 10) + "B"; + } else if (price >= 1e6) { + return df.format(Math.floor(price / 1e5) / 10) + "M"; + } else if (price >= 1e3) { + return df.format(Math.floor(price / 100) / 10) + "K"; } else { return "" + price; } diff --git a/CompiledServer/production/2006rebotted/redone/game/bots/Bot$TradeChat.class b/CompiledServer/production/2006rebotted/redone/game/bots/Bot$TradeChat.class index 09731f46..77bb9577 100644 Binary files a/CompiledServer/production/2006rebotted/redone/game/bots/Bot$TradeChat.class and b/CompiledServer/production/2006rebotted/redone/game/bots/Bot$TradeChat.class differ diff --git a/CompiledServer/production/2006rebotted/redone/game/bots/Bot.class b/CompiledServer/production/2006rebotted/redone/game/bots/Bot.class index 24a23ee3..ca311869 100644 Binary files a/CompiledServer/production/2006rebotted/redone/game/bots/Bot.class and b/CompiledServer/production/2006rebotted/redone/game/bots/Bot.class differ