LookAtComponent

@MainThread
class LookAtComponent : Component

A Component that controls the "look at" behavior of entities in 3D space, allowing entities to face specific targets (such as viewers or other entities) and providing control over alignment methods and forward direction.

Constructors

Link copied to clipboard
constructor()

The default constructor for LookAtComponent with no parameters.

Properties

Link copied to clipboard

Controls whether the entity's local up direction should be aligned with the world's up direction.

Link copied to clipboard

Specifies the forward direction of the entity's "look at" behavior.

Functions

Link copied to clipboard

Clears the target for the entity's "look at" behavior.

Link copied to clipboard
open override fun clone(): Component

Creates and returns a copy of this Component instance.

Link copied to clipboard
open operator override fun equals(other: Any?): Boolean
Link copied to clipboard

Gets the type of target currently set for the entity's "look at" behavior.

Link copied to clipboard
open override fun hashCode(): Int
Link copied to clipboard

Sets the specified entity as the target for the entity's "look at" behavior. If the entity is not valid, it will not be set as the target and will remain unchanged.

Link copied to clipboard

Sets the viewer as the target for the entity's "look at" behavior.

Link copied to clipboard
open override fun toString(): String