Class StateMachine
- Namespace
- AO
- Assembly
- CoreAssembly.dll
State machine
public class StateMachine
- Inheritance
-
StateMachine
- Inherited Members
- Extension Methods
Methods
CreateLayer(string, int)
Create a new layer on the state machine
public StateMachineLayer CreateLayer(string name, int track = 0)
Parameters
Returns
- StateMachineLayer
CreateVariable(string, StateMachineVariableKind)
Create a new variable on the state machine
public StateMachineVariable CreateVariable(string name, StateMachineVariableKind kind)
Parameters
name
stringkind
StateMachineVariableKind
Returns
- StateMachineVariable
Destroy()
Destroy the state machine
public void Destroy()
Make()
Create a new state machine
public static StateMachine Make()
Returns
SetBool(string, bool)
Set a boolean on the state machine
public void SetBool(string variableName, bool value)
Parameters
SetFloat(string, double)
Set a float on the state machine
public void SetFloat(string variableName, double value)
Parameters
SetInt(string, int)
Set an integer on the state machine
public void SetInt(string variableName, int value)
Parameters
SetTrigger(string)
Set a trigger on the state machine
public void SetTrigger(string variableName)
Parameters
variableName
string
TryGetLayerByIndex(int)
Attempts to get a layer by index. Returns null if index is out of bounds.
public StateMachineLayer TryGetLayerByIndex(int index)
Parameters
index
int
Returns
- StateMachineLayer
TryGetLayerByName(string)
Attempts to get a layer by name. Returns null if no layer with that name was found.
public StateMachineLayer TryGetLayerByName(string name)
Parameters
name
string
Returns
- StateMachineLayer
TryGetVariableByName(string)
public StateMachineVariable TryGetVariableByName(string name)
Parameters
name
string
Returns
- StateMachineVariable
Update(float)
Update the state machine. Usually called every frame
public void Update(float dt)
Parameters
dt
float