Fixup rounding for millions

This commit is contained in:
RedSparr0w
2019-11-23 16:47:32 +13:00
parent e42394fdbe
commit f4ea14f2bf
4 changed files with 2 additions and 1 deletions
@@ -88,7 +88,7 @@ public class Bot {
if (price > 1e9) {
return (Math.floor(price / 1e8) / 10) + "B";
} else if (price > 1e6) {
return (Math.floor(price / 1e8) / 10) + "M";
return (Math.floor(price / 1e5) / 10) + "M";
} else if (price > 1e3) {
return (Math.floor(price / 100) / 10) + "K";
} else {
@@ -74,6 +74,7 @@ public class ShopHandler {
ShopItemsDelay[i][j] = 0;
DidUpdate = true;
}
refreshShop(i);
}
ShopItemsDelay[i][j]++;
}