removeAll(keepCapacity:preservingWorldTransforms:)
Removes all children from this entity.
Declaration
@MainActor @preconcurrency func removeAll(keepCapacity: Bool = false, preservingWorldTransforms: Bool = false)Parameters
- keepCapacity:
trueto keep the memory reserved for storing the children.falseto free the reserved memory. - preservingWorldTransforms:
trueto preserve the world transform.falseto preserve the relative transform. (Usetrueif the entities should keep its effective location and size in the scene!)