In my scenario, I have a series of meshes organized in a hierarchy as follows:
Scene
-scene.add(SpaceMesh)
-SpaceMesh.add(ShipMesh)
SpaceMesh
is currently in motion within the scene. However, ShipMesh
remains stationary.
When I request the x-coordinate of ShipMesh
with ShipMesh.position.x
, it understandably returns 0.
How can I obtain the coordinates of ShipMesh
in relation to SpaceMesh
?
--
For instance:
SpaceMesh.position.x = 100
ShipMesh.position.x = 0
The expected result would be ShipMesh.PositionInSpaceMesh.x = -100