InteractableStateChangeArgs Struct
IInteractableStateChangeArgs instances contain information relevant to the changing state of an IInteractableView.
This information is used internally by the Interaction SDK for a variety of tasks and can be leveraged directly in custom code. However, it is typically easier to observe IInteractable state changes using an InteractableUnityEventWrapper, which will unpack this information into discrete events which can be accessed and manipulated in the Unity Editor.
InteractableState PreviousState[Get]
The InteractableState of the emitting IInteractable prior to this state change.
Note that state change events are emitted after the change has already taken place, and thus querying the state in a handler of such an event returns the new state, not the previous state.
InteractableState NewState[Get]
The InteractableState of the emitting IInteractable after this state change.
State change events are emitted after the change has already taken place, so querying the state in a handler of such an event will return this new state.
InteractableStateChangeArgs ( InteractableState previousState,
InteractableState newState )
Constructor for InteractableStateChangeArgs.
In general, only IInteractable instances are expected to invoke this.
ParameterspreviousStateThe IInteractable's prior InteractableState
newStateThe IInteractable's new InteractableState