kRPC: Control the game using C#, C++, Java, Lua, Python...

kRPC: Control the game using C#, C++, Java, Lua, Python...

7.8k Downloads

CelestialBody parameters (e.g. `GravitationalParameter` and `RotationalPeriod`) could be returned as doubles

ThePuzzlemaker opened this issue ยท 3 comments

commented

What would you like to be added?

A way to obtain double-precision parameters about CelestialBody objects

Why is this needed?

Parameters in the CelestialBody class are represented internally in KSP via doubles, so I don't see why not to expose that level of precision via kRPC. For backwards-compatibility, new procedures could be added which do the same things as the existing parameters but returning double instead of float.

commented

I think it's ok to just change the existing functions to use double, and break backwards compatibility. Clients like python wouldn't really break (due to their type system) and clients like C++ would at least catch the change as a compiler error.

commented

If you'd like, I can make a PR

commented

Yes please!