planetkit icon indicating copy to clipboard operation
planetkit copied to clipboard

Separate nphysics world per globe

Open jeffparsons opened this issue 7 years ago • 0 comments

At the moment I have a single global nphysics world:

/// `World`-global resource for nphysics `World`.
pub struct WorldResource {
    pub world: World<Real>,
}

But all coordinates given to nphysics are globe-local, because (as far as I know?) nphysics doesn't use any kind of hierarchical coordinate system. (Trying to use some kind of universal coordinates in a solar system would result in huge uselessly-imprecise numbers being thrown at nphysics.)

Things on different globes aren't going to interact with each other, so we're better off having a separate nphysics world per globe so we can keep using globe-local coordinates.

jeffparsons avatar Aug 03 '18 11:08 jeffparsons