Namespace: TommoJProductions.ModApi.StateMachine
Represents the ModAPI State Machine.
public class StateMachine
Inheritance Object → StateMachine
public StateMachine()
Represents the update method.
public void update()
Sets the current state.
public void setState(IState state)
state IState The state to set.
state
Exits the current state.
public void exitCurrentState()
Adds a Transition to transfer from state to another.
public void addTransition(IState from, IState to, Func<bool> predicate)
from IState The state to transition from
from
to IState The state to transition to
to
predicate Func<Boolean> Predicate. The function that predicates whether to transition.
predicate
Adds a Global Transition to transfer to another state.
public void addGlobalTransition(IState state, Func<bool> predicate)
state IState The state to transition to
There was an error while loading. Please reload this page.