API reference

reparentChildInWorldCoordinates Function

Changes the parent of an entity while preserving where it renders.
Position and orientation are always preserved. With TickTransformSystem.applyScale on, the child's own Scale is also adjusted so its rendered size is unchanged under the new parent's scale.

Signature

fun reparentChildInWorldCoordinates(parent: Entity, child: Entity)

Parameters

parent: Entity Parent entity in the scene hierarchy.
child: Entity Child.