Instance Method

setOrientation(_:relativeTo:)

Sets the orientation of the entity relative to the given reference entity.

Declaration

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 nil to indicate world space.

See Also

Rotating an Entity

var orientation: simd_quatf

The rotation of the entity relative to its parent.

func orientation(relativeTo: Entity?) -> simd_quatf

Gets the orientation of an entity relative to the given entity.