Set the given parentObject
as the parent of this object.
If parentObject
is null
, the object is parented to the scene's
sceneParent
, which is the topmost object of the scene tree.
If you want to remove it from the scene, use Object.remove()
instead.
If parentObject
is the object on which this function is called,
nothing happens.
Parameters:
parentObject | The new parent object. |
---|
parentInverse | (Optional) Change the scale of the child object to be relative to the new parents 3D space or use the original scale. |
---|
keepTransform | (Optional) When unparenting from the old parent, keep the transform given by the old parent or revert to the object's default. |
---|