From 462f6725b653eabc7c969a2fa74fae48c3fd2b72 Mon Sep 17 00:00:00 2001 From: MagicBot Date: Sat, 17 Aug 2024 15:26:59 -0400 Subject: [PATCH] Sometimes bad floats. --- src/engine/wpak/PowersParser.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/engine/wpak/PowersParser.java b/src/engine/wpak/PowersParser.java index 85f2c8f7..9924da1d 100644 --- a/src/engine/wpak/PowersParser.java +++ b/src/engine/wpak/PowersParser.java @@ -95,7 +95,7 @@ public class PowersParser { powerEntry.costType = iterator.next(); powerEntry.cost = Float.parseFloat(iterator.next()); powerEntry.difficulty = Float.parseFloat(iterator.next()); - powerEntry.precision = Float.parseFloat(iterator.next()); + powerEntry.precision = Float.parseFloat(iterator.next().replaceAll("(\\.0)+$", "")); powerEntry.init_time = Float.parseFloat(iterator.next()); powerEntry.release_time = Float.parseFloat(iterator.next()); powerEntry.recycle_time = Float.parseFloat(iterator.next());