Decorators¶
Decorators can modify the result of a node. These decorators can be added as a node or as a modifier in the output of a node.
Inverter¶
Inverts the result. Success becomes Failure and Failure becomes Success. Error and Running remain unchanged.
In |
Out |
---|---|
Running |
Running |
Success |
Fail |
Fail |
Success |
Error |
Error |
Always Succeed¶
A node always succeed.
In |
Out |
---|---|
Running |
Success |
Success |
Success |
Fail |
Success |
Error |
Success |
Always Fail¶
A node always fails.
In |
Out |
---|---|
Running |
Fail |
Success |
Fail |
Fail |
Fail |
Error |
Fail |
Until Success¶
Node keeps running until a Success or an Error is returned.
Until Fail¶
Node keeps running until a Fail or an Error. In case of a failure a Success is returned.
Limiter¶
With this decorator you can limit the number of times the subtree is evaluated.
Limit: Max number of times the subtree may be evaluated. Returns Fail when limit is met. Otherwise the result of the child subtree is returned.
Guard¶
With the Guard decorator you can limit the number of times a subtree is evaluated in the current frame.
Limit: Max number of times the subtree may be evaluated in a frame. Returns Fail when limit is met. Otherwise the result of the child subtree is returned.
Max Time¶
With this decorator you can set the maximum time in frames for the child node to be evaluated.
Frames: Max number of frames a node may run before finishing. Returns Fail when limit is met. Otherwise the result of the child subtree is returned.
Repeat¶
Loop the subtree a number of times. Each agent selects a random number between minimum and maximum repeats that will be used as its loop count.
Min Repeat: Minimum number of times an agent should loop the subtree.
Max Repeat: Maximum number of times an agent should loop the subtree.