Interface IAffordanceStateReceiver
An interface that represents the core capabilities of an affordance receiver. Its job is to receive updates from an affordance state provider and generate tween jobs to be scheduled, then update the affordance state according to the tween job output.
Namespace: UnityEngine.XR.Interaction.Toolkit.AffordanceSystem.Receiver
Syntax
public interface IAffordanceStateReceiver
Properties
currentAffordanceStateData
Bindable variable holding the last affordance state passed in by the affordance state provider.
Declaration
IReadOnlyBindableVariable<AffordanceStateData> currentAffordanceStateData { get; }
Property Value
Type | Description |
---|---|
IReadOnlyBindableVariable<AffordanceStateData> |
Methods
OnAffordanceStateUpdated(AffordanceStateData, AffordanceStateData)
Called by the affordance state provider to inform the receiver of the previous state and new state.
Declaration
void OnAffordanceStateUpdated(AffordanceStateData previousState, AffordanceStateData newState)
Parameters
Type | Name | Description |
---|---|---|
AffordanceStateData | previousState | Previous affordance state. |
AffordanceStateData | newState | New Affordance state. |