Class ReceiverBaseMonoBehavior
A base class for detecting hand handling state changes from an Interactable Extend this class to build new events or receivers from Interactables
InteractableReceiver or InteractableReceiverList can be used with ReceiverBase - built-in receivers
Namespace: Microsoft.MixedReality.Toolkit.UI
Assembly: cs.temp.dll.dll
Syntax
public class ReceiverBaseMonoBehavior : MonoBehaviour, IInteractableHandler, MonoBehaviour
Fields
Interactable
Interactable to target
Declaration
public Interactable Interactable
Field Value
Type | Description |
---|---|
Interactable |
Interactable
Interactable to target
Declaration
public Interactable Interactable
Field Value
Type | Description |
---|---|
Interactable |
InteractableSearchScope
directions to search for Interactable component in transform hierarchy if none assigned
Declaration
public ReceiverBaseMonoBehavior.SearchScopes InteractableSearchScope
Field Value
Type | Description |
---|---|
ReceiverBaseMonoBehavior.SearchScopes |
InteractableSearchScope
directions to search for Interactable component in transform hierarchy if none assigned
Declaration
public ReceiverBaseMonoBehavior.SearchScopes InteractableSearchScope
Field Value
Type | Description |
---|---|
ReceiverBaseMonoBehavior.SearchScopes |
lastState
Declaration
protected State lastState
Field Value
Type | Description |
---|---|
State |
lastState
Declaration
protected State lastState
Field Value
Type | Description |
---|---|
State |
Methods
AddInteractable(Interactable)
Add an interactable and add it as a handler
Declaration
public void AddInteractable(Interactable interactable)
Parameters
Type | Name | Description |
---|---|---|
Interactable | interactable |
AddInteractable(Interactable)
Add an interactable and add it as a handler
Declaration
public void AddInteractable(Interactable interactable)
Parameters
Type | Name | Description |
---|---|---|
Interactable | interactable |
OnClick(InteractableStates, Interactable, IMixedRealityPointer)
Declaration
public virtual void OnClick(InteractableStates state, Interactable source, IMixedRealityPointer pointer = null)
Parameters
Type | Name | Description |
---|---|---|
InteractableStates | state | |
Interactable | source | |
IMixedRealityPointer | pointer |
OnClick(InteractableStates, Interactable, IMixedRealityPointer)
Declaration
public virtual void OnClick(InteractableStates state, Interactable source, IMixedRealityPointer pointer = null)
Parameters
Type | Name | Description |
---|---|---|
InteractableStates | state | |
Interactable | source | |
IMixedRealityPointer | pointer |
OnDisable()
Remove itself as a handler
Declaration
protected virtual void OnDisable()
OnDisable()
Remove itself as a handler
Declaration
protected virtual void OnDisable()
OnEnable()
look for an Interactable if not assigned
Declaration
protected virtual void OnEnable()
OnEnable()
look for an Interactable if not assigned
Declaration
protected virtual void OnEnable()
OnStateChange(InteractableStates, Interactable)
a state has changed
Declaration
public virtual void OnStateChange(InteractableStates state, Interactable source)
Parameters
Type | Name | Description |
---|---|---|
InteractableStates | state | |
Interactable | source |
OnStateChange(InteractableStates, Interactable)
a state has changed
Declaration
public virtual void OnStateChange(InteractableStates state, Interactable source)
Parameters
Type | Name | Description |
---|---|---|
InteractableStates | state | |
Interactable | source |
OnVoiceCommand(InteractableStates, Interactable, String, Int32, Int32)
Declaration
public virtual 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 |
OnVoiceCommand(InteractableStates, Interactable, String, Int32, Int32)
Declaration
public virtual 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 |
Update()
Declaration
protected virtual void Update()
Update()
Declaration
protected virtual void Update()
Implements
MonoBehaviour