Class StateGraph
Represents a nested directed graph designed to work with states (HFSM - Hierarchical Finite State Machine).
Inheritance
System.Object
StateGraph
Namespace: AlchemyBow.Core.States
Assembly: AlchemyBow.Core.dll
Syntax
public sealed class StateGraph
Methods
Build(StateGraphComposer)
Builds a node of the state graph.
Declaration
public static StateGraph Build(StateGraphComposer composer)
Parameters
Type | Name | Description |
---|---|---|
StateGraphComposer | composer | The description of the node. |
Returns
Type | Description |
---|---|
StateGraph | The built node. |
Remarks
The composer is not automatically validated.
Enter()
Enters the state.
Declaration
public void Enter()
EnumerateDown(Action<IState>, Boolean)
Invokes the specified action on the active (nested) states (starting from the root).
Declaration
public void EnumerateDown(Action<IState> action, bool ignoreNulls)
Parameters
Type | Name | Description |
---|---|---|
System.Action<IState> | action | The action to invoke on the states. |
System.Boolean | ignoreNulls | Only invokes the action on the non-null states if |
Exit()
Exits the state.
Declaration
public void Exit()