Class CustomAction
- Namespace
- Static
Custom actions are actions triggered by events outside of Interacting or combining (e.g. UI quizes) and can send parameters that are then checked against the statemachine.
This class is also what authors can use to trigger actions beyond the scope of TrainAR and can be handled by the statemachine by using the Action Node and the "Custom Action" type.
CustomAction can either be triggered form the instantiated or static context.
public class CustomAction : MonoBehaviour
- Inheritance
-
objectCustomAction
Methods
DynamicTrigger(string)
Triggers a CustomAction with the given parameter.
public void DynamicTrigger(string parameter)
Parameters
parameterstringThe parameter to be checked against the statemachine.
StaticTrigger(string)
Triggers a CustomAction with the given parameter from a static context.
public static bool StaticTrigger(string parameter)
Parameters
parameterstringThe parameter to be checked against the statemachine.
Returns
- bool
Whether this was a correct statechange and triggered to statemachine to proceed.