Class InteractableReceiver
Example of building an event system for Interactable that still uses ReceiverBase events
Implements
Inherited Members
Namespace: Microsoft.MixedReality.Toolkit.UI
Assembly: cs.temp.dll.dll
Syntax
public class InteractableReceiver : ReceiverBaseMonoBehavior, IInteractableHandler
Fields
Events
Declaration
public List<InteractableEvent> Events
Field Value
Type | Description |
---|---|
List<InteractableEvent> |
Methods
Awake()
Declaration
protected virtual void Awake()
OnClick(InteractableStates, Interactable, IMixedRealityPointer)
click happened
Declaration
public override void OnClick(InteractableStates state, Interactable source, IMixedRealityPointer pointer = null)
Parameters
Type | Name | Description |
---|---|---|
InteractableStates | state | |
Interactable | source | |
IMixedRealityPointer | pointer |
Overrides
OnStateChange(InteractableStates, Interactable)
A state has changed
Declaration
public override void OnStateChange(InteractableStates state, Interactable source)
Parameters
Type | Name | Description |
---|---|---|
InteractableStates | state | |
Interactable | source |
Overrides
OnVoiceCommand(InteractableStates, Interactable, String, Int32, Int32)
voice command happened
Declaration
public override void OnVoiceCommand(InteractableStates state, Interactable source, string command, int index = 0, int length = 1)
Parameters
Type | Name | Description |
---|---|---|
InteractableStates | state | |
Interactable | source | |
String | command | |
Int32 | index | |
Int32 | length |
Overrides
SetupEvents()
set up only one event
Declaration
protected virtual void SetupEvents()