Jump to content

String rounding bug in decimal numbers - 0.10


Myrddin2008
  • Branch: Live Branch Version: Windows Fixed

Decimals (possibly when >0.95) for some reason round to 0.10 instead of, say, 1.0. This is most obvious with sublimating materials like Polluted Water or Oxylite, but it happens with all materials as far as I can tell, so it's likely an issue with the tooltip.

The tooltip seems to be the only one affected by this, the Status panel shows the correct quantity:

image.png.bef5e0256d97cafac325169fdac9c2df.png

Timelapse of this happening:

image.png.2c07d3bfb3b3bdc7814d79d9081bb4fe.pngimage.png.b67e37ede517c60d09725a74aae6f939.pngimage.png.1eefc58c25719aac358c76c0df1bb441.png


Steps to Reproduce

Steps to Reproduce:

1) Find some material that has its mass between 0.95 and 1.0 of the current unit (g, kg, units, etc). This is easier with offgassing material, since you can wait for it to change.

2) mouse over the block to reveal the tooltip.

3) Observe the tooltip incorrectly formatting the mass with a ".10" decimal instead of rounding the 1's digit.




User Feedback


A developer has marked this issue as fixed. This means that the issue has been addressed in the current development build and will likely be in the next update.

Other reports of same bug here:

https://forums.kleientertainment.com/klei-bug-tracker/oni_so/strange-decimal-counting-behaviour-r27523/

https://forums.kleientertainment.com/klei-bug-tracker/oni_so/tiles-sometimes-show-n-110-instead-of-n-for-their-contents-bad-rounding-r26492/

Share this comment


Link to comment
Share on other sites



Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
  • Create New...