Optional_Reference to the component that this cursor will visualize. The cursor will update its position and appearance based on the interactor's state.
ReadonlyapiGeneric object accessible by other instances of ScriptComponent. Use this object to store references to properties and methods that need to be accessible from other ScriptComponents.
Enable debug rendering for this cursor (propagated to the internal view model)
Controls the "stickiness" of the cursor when hovering over interactable objects. When enabled, the cursor maintains its position on the target object, even when the hand moves slightly, making interaction with small targets easier. Only applies to hand-based interactions, not other input types like mouse. Disable for immediate 1:1 cursor movement that follows the hand position exactly.
If disabled, the Component will stop enacting its behavior.
Applies smoothing to cursor movement for hand-based interactions. When enabled, reduces jitter and makes cursor motion appear more stable, improving precision when interacting with small targets. Only applies to hand-based interactions.
ReadonlyisReturns true if this Component, its SceneObject, and all of that SceneObjects parents are enabled.
Called whenever the cursor changes enabled state (showing / hiding the cursor visual)
Called whenever the ray visibility changes (becomes visible or invisible based on rayAlpha threshold).
ReadonlysceneThe SceneObject this component is on.
ReadonlyuniqueSet the CursorMode of the cursor to change the visual To return the cursor to its default StateMachine logic, use CursorMode.Auto
The new mode of the cursor visual
the transform and material parameters of the cursor to allow other cursor implementations to re-use the same values.
Set the world position of this interactor's cursor visual
vec3 of the worldPosition, null to revert to default behavior to follow raycast
Set the Texture of the cursor when using the CursorMode.Custom mode Must explicitly set the CursorMode to CursorMode.Custom before the texture appears.
The custom texture (typically cached via requireAsset(.../assetName.png) as Texture) to use
Gets the current ray alpha value.
Sets the ray alpha value and triggers visibility change events when crossing the threshold.
Set the render order of the cursor visual.
Whether the cursor is using the V2 cursor implementation.
Adds a new SceneEvent, triggered by eventType events, to the ScriptComponent.
Destroys the component.
Returns the SceneObject the component is attached to.
Returns the Transform this component is attached to.
StaticgetReturns the name of this object's type.
Hides the cursor visual.
The fade out duration.
Initializes the cursor with the useV2 setting from the CursorController.
The CursorController that initialized this cursor.
Whether to use the V2 cursor implementation.
Returns true if the object matches or derives from the passed in type.
Returns true if this object is the same as other. Useful for checking if two references point to the same thing.
Removes a previously added SceneEvent from the ScriptComponent.
Shows the cursor visual.
The fade in duration.
This class represents a cursor for interactors, providing visual feedback for different interaction states. It manages the cursor's appearance, including its circle visual and manipulation line, and handles state changes and events.