|
Drag[en]gine Script Module DragonScript 1.32.1
|
State machine transition. More...
Classes | |
| enum | ConditionMode |
| Condition modes. More... | |
Public Member Functions | |
| void | addAction (SMStateAction action) |
| Add action. | |
| void | addCondition (String condition) |
| Add condition. | |
| bool | evaluateConditions (SMContext context) |
| Evaluate all conditions. | |
| SMStateAction | findAction (Block ablock) |
| Find action with block with parameter SMStateAction. | |
| String | findCondition (Block ablock) |
| Find condition with block with parameter String. | |
| void | forEachAction (Block ablock) |
| Visit actions with block with parameter SMStateAction. | |
| void | forEachCondition (Block ablock) |
| Visit conditions with block with parameter String. | |
| SMStateAction | getActionAt (int index) |
| Get action at index. | |
| int | getActionCount () |
| Count of actions. | |
| String | getConditionAt (int index) |
| Get condition at index. | |
| int | getConditionCount () |
| Count of conditions. | |
| ConditionMode | getConditionMode () |
| Condition mode from eConditionModes. | |
| String | getStateID () |
| Identifier of state to switch to or null to stay in the same state. | |
| SMTransition | new (SMTransition transition) |
| Create copy of state machine transition. | |
| SMTransition | new (String event) |
| Create state machine transition staying in the same state. | |
| SMTransition | new (String event, String stateID) |
| Create state machine transition. | |
| void | setConditionMode (ConditionMode mode) |
| Set condition mode from eConditionModes. | |
Public Attributes | |
| Array | pActions |
| ConditionMode | pConditionMode |
| String | pEvent |
| Dictionary | pParameters |
State machine transition.
Transitions run a set of actions before activating the new state in the state machine.
| void Dragengine.StateMachineSystem.SMTransition.addAction | ( | SMStateAction | action | ) |
Add action.
| void Dragengine.StateMachineSystem.SMTransition.addCondition | ( | String | condition | ) |
Add condition.
| bool Dragengine.StateMachineSystem.SMTransition.evaluateConditions | ( | SMContext | context | ) |
Evaluate all conditions.
If no condition is present true is returned.
| parameters | Dictionary with parameters of type String key and String value. Do not change the content of the dictionary as it is shared. |
| SMStateAction Dragengine.StateMachineSystem.SMTransition.findAction | ( | Block | ablock | ) |
Find action with block with parameter SMStateAction.
| String Dragengine.StateMachineSystem.SMTransition.findCondition | ( | Block | ablock | ) |
Find condition with block with parameter String.
| void Dragengine.StateMachineSystem.SMTransition.forEachAction | ( | Block | ablock | ) |
Visit actions with block with parameter SMStateAction.
| void Dragengine.StateMachineSystem.SMTransition.forEachCondition | ( | Block | ablock | ) |
Visit conditions with block with parameter String.
| SMStateAction Dragengine.StateMachineSystem.SMTransition.getActionAt | ( | int | index | ) |
Get action at index.
| int Dragengine.StateMachineSystem.SMTransition.getActionCount | ( | ) |
Count of actions.
| String Dragengine.StateMachineSystem.SMTransition.getConditionAt | ( | int | index | ) |
Get condition at index.
| int Dragengine.StateMachineSystem.SMTransition.getConditionCount | ( | ) |
Count of conditions.
| ConditionMode Dragengine.StateMachineSystem.SMTransition.getConditionMode | ( | ) |
Condition mode from eConditionModes.
| String Dragengine.StateMachineSystem.SMTransition.getStateID | ( | ) |
Identifier of state to switch to or null to stay in the same state.
| SMTransition Dragengine.StateMachineSystem.SMTransition.new | ( | SMTransition | transition | ) |
Create copy of state machine transition.
| SMTransition Dragengine.StateMachineSystem.SMTransition.new | ( | String | event | ) |
Create state machine transition staying in the same state.
| event | Event to react to. |
| SMTransition Dragengine.StateMachineSystem.SMTransition.new | ( | String | event, |
| String | stateID | ||
| ) |
Create state machine transition.
| event | Event to react to. |
| stateID | State to switch to or null to stay in the same state. |
| void Dragengine.StateMachineSystem.SMTransition.setConditionMode | ( | ConditionMode | mode | ) |
Set condition mode from eConditionModes.
| Array Dragengine.StateMachineSystem.SMTransition.pActions |
| ConditionMode Dragengine.StateMachineSystem.SMTransition.pConditionMode |
| String Dragengine.StateMachineSystem.SMTransition.pEvent |
| Dictionary Dragengine.StateMachineSystem.SMTransition.pParameters |