Tick
A new Tick object is instantiated every tick by BehaviorTree. It is passed as parameter to the nodes through the tree during the traversal.
The role of the Tick class is to store the instances of tree, debug, target and blackboard. So, all nodes can access these informations.
For internal uses, the Tick also is useful to store the open node after
the tick signal, in order to let BehaviorTree to keep track and close
them when necessary.
This class also makes a bridge between nodes and the debug, passing the node state to the debug if the last is provided.
Item Index
Properties
Methods
_closeNode
-
node
Callback when closing a node (called by BaseNode).
Parameters:
-
nodeObjectThe node that called this method.
_enterNode
-
node
Called when entering a node (called by BaseNode).
Parameters:
-
nodeObjectThe node that called this method.
_exitNode
-
node
Callback when exiting a node (called by BaseNode).
Parameters:
-
nodeObjectThe node that called this method.
_openNode
-
node
Callback when opening a node (called by BaseNode).
Parameters:
-
nodeObjectThe node that called this method.
_tickNode
-
node
Callback when ticking a node (called by BaseNode).
Parameters:
-
nodeObjectThe node that called this method.
initialize
()
Initialization method.
Properties
_nodeCount
Integer
protected
The number of nodes entered during the tick. Update during the tree traversal.
_openNodes
Array
protected
The list of open nodes. Update during the tree traversal.
blackboard
b3.Blackboard
The blackboard reference.
debug
Object
The debug reference.
target
Object
The target object reference.
tree
b3.BehaviorTree
The tree reference.
