setOrientation(_:relativeTo:)
Sets the orientation of the entity relative to the given reference entity.
Declaration
@MainActor @preconcurrency func setOrientation(_ orientation: simd_quatf, relativeTo referenceEntity: Entity?)Parameters
- orientation:
A new orientation, relative to
referenceEntity. - referenceEntity:
The entity that defines a frame of reference. Set this to
nilto indicate world space.