For a voxel game like mechaenetia, it could be easy to consider a Cartesian coordinate, and use fp32(float) for positions and movements, like in many games including Minecraft. Could other coordinate systems be better for such a game?
Here are some thoughts about it
-
Integer-based system
For an irl planet it would have a typical scale of 1E7m, so a local coordinate with int32 could reach a resolution of centimeter, which should be enough for such kind of game. -
Mixed type coordinates
If int16 is used, it can represent positions of large chunks, with a size less than 1km. Then inside a chunk the planet’s curvature is neglect-able, and another int16 or float can be used inside the chunk. -
Position-dependent coordinates
Like the way in this topic Trying to map a 2d array into a disk - #53 by Fyrstikkeske , draw non-Euclidean coordinates based on the planets’ shape. Could be simple for islands/caves, but may need some algorithms for customized planets, and the rendering system if it’s based on the octree structure. -
Fixed-direction voxels
Every voxel on a planet have the same facing direction, so it would be easy after planet initialization. But things like fluid simulation might be a little complex.