Readonly
apiGeneric 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.
The material applied to the toggle button when it's disabled and cannot be interacted with. This provides visual feedback that the button is currently inactive.
If disabled, the Component will stop enacting its behavior.
An array of RenderMeshVisual components whose materials will be updated to reflect the toggle button's current state.
Readonly
sceneThe scene object this component is on.
The material applied to the toggle button when it's in the "off" state and not being interacted with. This defines the button's default visual appearance when it's unchecked.
The material applied to the toggle button when it's in the "off" state and being actively triggered. This provides visual feedback during active interaction with an unchecked button.
The material applied to the toggle button when it's in the "on" state and not being interacted with. This defines the button's visual appearance when it's enabled/checked.
The material applied to the toggle button when it's in the "on" state and being actively triggered. This provides visual feedback during active interaction with a checked button.
Readonly
uniqueAdds 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.
Static
getReturns the name of this object's type.
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.
This class provides visual feedback for a ToggleButton by changing the material of the provided RenderMeshVisuals when the button is toggled on or off.