Drag[en]gine Script Module DragonScript 1.23
|
Base class for behavior tree rules using child rules. More...
Public Member Functions | |
void | addRule (BTRule rule) |
Add rule. | |
BTRule | find (Block ablock) |
Find rule with block with parameter BTRule. | |
void | forEach (Block ablock) |
Visit rules with block with parameter BTRule. | |
BTRule | getRuleAt (int index) |
Get rule at index. | |
int | getRuleCount () |
Number of rules. | |
int | indexOfRule (BTRule rule) |
Index of rule or -1 if absent. | |
BTRuleList | new (String id) |
Create behavior tree rule. | |
void | removeAllRules () |
Remove all rules. | |
void | removeRule (BTRule rule) |
Remove rule. | |
![]() | |
void | addCondition (String condition) |
Add condition. | |
bool | evaluateConditions (BTContext context) |
Evaluate all conditions. | |
String | findCondition (Block ablock) |
Find condition with block with parameter String. | |
void | forEachCondition (Block ablock) |
Visit conditions with block with parameter String. | |
String | getConditionAt (int index) |
Get condition at index. | |
int | getConditionCount () |
Number of conditions. | |
ConditionMode | getConditionMode () |
Condition mode from eConditionModes. | |
String | getID () |
Unique rule identifier or null. | |
Dictionary | getParameters () |
Parameters as Dictionary of type String key and String value. | |
BTRule | getParent () |
Parent rule or null if this is the root rule in a behavior tree. | |
int | indexOfCondition (String condition) |
Index of condition or -1 if absent. | |
void | removeAllConditions () |
Remove all conditions. | |
void | removeCondition (String condition) |
Remove condition. | |
void | setConditionMode (ConditionMode mode) |
Set condition mode from eConditionModes. | |
void | setParent (BTRule rule) |
Set parent rule or null if this is the root rule in a behavior tree. | |
Public Attributes | |
Array | pRules |
![]() | |
ConditionMode | pConditionMode |
Array | pConditions |
String | pID |
Dictionary | pParameters |
WeakReference | pParent |
Base class for behavior tree rules using child rules.
void Dragengine.BehaviorTreeSystem.BTRuleList.addRule | ( | BTRule | rule | ) |
Add rule.
BTRule Dragengine.BehaviorTreeSystem.BTRuleList.find | ( | Block | ablock | ) |
Find rule with block with parameter BTRule.
void Dragengine.BehaviorTreeSystem.BTRuleList.forEach | ( | Block | ablock | ) |
Visit rules with block with parameter BTRule.
BTRule Dragengine.BehaviorTreeSystem.BTRuleList.getRuleAt | ( | int | index | ) |
Get rule at index.
int Dragengine.BehaviorTreeSystem.BTRuleList.getRuleCount | ( | ) |
Number of rules.
int Dragengine.BehaviorTreeSystem.BTRuleList.indexOfRule | ( | BTRule | rule | ) |
Index of rule or -1 if absent.
BTRuleList Dragengine.BehaviorTreeSystem.BTRuleList.new | ( | String | id | ) |
Create behavior tree rule.
Reimplemented from Dragengine.BehaviorTreeSystem.BTRule.
Reimplemented in Dragengine.BehaviorTreeSystem.BTRuleChoice, and Dragengine.BehaviorTreeSystem.BTRuleSequence.
void Dragengine.BehaviorTreeSystem.BTRuleList.removeAllRules | ( | ) |
Remove all rules.
void Dragengine.BehaviorTreeSystem.BTRuleList.removeRule | ( | BTRule | rule | ) |
Remove rule.
Array Dragengine.BehaviorTreeSystem.BTRuleList.pRules |