Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MATH variable precision #440

Closed
MOARdV opened this issue Nov 17, 2015 · 1 comment
Closed

MATH variable precision #440

MOARdV opened this issue Nov 17, 2015 · 1 comment
Assignees
Labels
Milestone

Comments

@MOARdV
Copy link
Collaborator

MOARdV commented Nov 17, 2015

Now that we're using PERSISTENT for things other than simple counting numbers, I'm seeing precision problems. For instance, alexustas is making a timer that counts the difference from a set point (in UTSECS) to the present. In his save, the time was updating every 2 seconds. In my game (KSP Y13), it's every eight.

Note - it could be something in MATH that's the problem.

@MOARdV MOARdV added the bug label Nov 17, 2015
@MOARdV MOARdV self-assigned this Nov 17, 2015
@MOARdV MOARdV added this to the v0.24.1 milestone Nov 17, 2015
@MOARdV MOARdV changed the title PERSISTENT or MATH variable precision MATH variable precision Nov 17, 2015
@MOARdV
Copy link
Collaborator Author

MOARdV commented Nov 17, 2015

Okay, it was the MATH variable. I treat the value as a float, and UTSECS is well past the point where float precision provides an adequate number of bits to provide one second resolution.

MOARdV added a commit to MOARdV/RasterPropMonitor that referenced this issue Nov 17, 2015
Some values (like UTSECS) easily exceed the precision of a float.  Issue
Mihara#440.
@MOARdV MOARdV closed this as completed Nov 17, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant