3 ms·
Kerbal Space Program required a lot of clever engineering to cram an entire solar system into the constrains of 32 bit floats. There are articles and videos out
by danhau 1y ago
Kerbal Space Program required a lot of clever engineering to cram an entire solar system into the constrains of 32 bit floats. There are articles and videos out there, highly recommended!
- mrguyorama 1y agoDidn't they just do the normal "The world is centered on you" trick? And then switched to 64 bit coordinates anyway?
- danhau 1y agoThat's one of the things, yeah. IIRC they tried 64-bit but gave up on it, one reason being the rendering code was hardwired to 32-bit, so there was no real benefit in the end. There are other solutions they had to find. The game has two "orbital mechanics engines". One runs a physics simulation and the other is just ellipse math, making the rocket "move on rails". That's why you can't time warp under a certain altitude (that's the real physics simulation). There are also things in rendering, how they faked the large-scale graphics of Kerbin, involving problems with the depth buffer I believe.