TreeRootNode | |
Hierarchy: | |
Namespace | BehaviorTreeEngine |
Parent class | MonoBehaviorNodeBase |
Description: | |
Tree Root Node represents the entire behavior tree and can be considered as the top level task that the whole tree accomplishes. The TreeRootNode class is a MonoBehaviorNodeBase and performs the corresponding responses of a behavior tree instance from the behavior tree engine on the Unity engine side. The TreeRootNode class inherits some virtual functions of OnExecute, OnReport, OnNotify, OnPause, OnStop, OnConstruct, OnDestruct and OnReset for a derived class, i.e., NewTreeRootNode, to override. | |
Inherited Variables: | |
nodeType | The node type of this mono behavior node. |
forestIndex | The forest index of this mono behavior node. |
treeIndex | The tree index of this mono behavior node. |
forestName | The forest name of this mono behavior node. |
treeName | The tree name of this mono behavior node. |
Deprecated Variables: | |
nodeIndex, nodeName. | |
Inherited Functions: | |
Init | Initialize the properties of this mono behavior node. |
OnExecute | A node operation that is invoked when executing the tree. |
OnReport | A node operation that is invoked when the tree completes an execution traversal with a result status, i.e., when the Tree Root Node was reported a node status of Success or Failure from its child node. |
OnNotify | A node operation that is invoked when the tree execution traversal was suspended due to re-execution request or interruption, i.e., when the Tree Root Node was notified executing by a Decorator Node or a Condition Node whose OnExecute or OnTest operation returned a node status of Executing, or was notified interrupt by an interrupted node when pausing, stopping, resetting or destroying an executing tree. |
OnPause | A node operation that is invoked when pausing the tree. |
OnStop | A node operation that is invoked when stopping the tree. |
OnConstruct | A node operation that is invoked when loading the tree. |
OnDestruct | A node operation that is invoked when destroying the tree. |
OnReset | A node operation that is invoked when resetting the tree. |
Deprecated Functions: | |
OnExecute, OnReport, OnTest, OnStep. | |
TreeRootNode.nodeType | |
Signature: | |
MonoBehaviorNodeType TreeRootNode.nodeType | |
Description: | |
The node type of this mono behavior node, which is always MonoBehaviorNodeType.TreeRoot. | |
TreeRootNode.forestIndex | |
Signature: | |
uint TreeRootNode.forestIndex | |
Description: | |
The forest index of this mono behavior node. | |
TreeRootNode.treeIndex | |
Signature: | |
uint TreeRootNode.treeIndex | |
Description: | |
The tree index of this mono behavior node. | |
TreeRootNode.forestName | |
Signature: | |
string TreeRootNode.forestName | |
Description: | |
The forest name of this mono behavior node. | |
TreeRootNode.treeName | |
Signature: | |
string TreeRootNode.treeName | |
Description: | |
The tree name of this mono behavior node. | |
TreeRootNode.Init | |
Signature: | |
void TreeRootNode.Init(uint ForestIndex, uint TreeIndex, string ForestName, string TreeName) void TreeRootNode.Init(uint ForestIndex, uint TreeIndex, string TreeName) |
|
Description: | |
Initializes the properties of this mono behavior node. | |
Parameters: | |
ForestIndex | The forest index of this mono behavior node. |
TreeIndex | The forest index of this mono behavior node. |
ForestName | The forest name of this mono behavior node. |
TreeName | The tree name of this mono behavior node. |
TreeRootNode.OnExecute | |
Signature: | |
void TreeRootNode.OnExecute(uint AccuLoopCount) | |
Description: | |
A node operation that is invoked when executing the tree. Override this method in a derived class of TreeRootNode. | |
Parameters: | |
AccuLoopCount | The accumulated loop count when invoking this operation as specified by the basic play mode. |
TreeRootNode.OnReport | |
Signature: | |
void TreeRootNode.OnReport(NodeStatus Status, uint AccuLoopCount) | |
Description: | |
A node operation that is invoked when the tree completes an execution traversal with a result status, i.e., when the Tree Root Node was reported a node status of Success or Failure from its child node. Override this method in a derived class of TreeRootNode. | |
Parameters: | |
Status | The result node status (can be either a Success or a Failure) that was reported from its child node. |
AccuLoopCount | The accumulated loop count when invoking this operation as specified by the basic play mode. |
TreeRootNode.OnNotify | |
Signature: | |
void TreeRootNode.OnNotify(NotifyStatus Status, uint NodeIndex, uint AccuLoopCount) | |
Description: | |
A node operation that is invoked when the tree execution traversal was suspended due to re-execution request or interruption, i.e., when the Tree Root Node was notified executing by a Decorator Node or a Condition Node whose OnExecute or OnTest operation returned a node status of Executing, or was notified interrupt by an interrupted node when pausing, stopping, resetting or destroying an executing tree. Override this method in a derived class of TreeRootNode. | |
Parameters: | |
Status | A status of notification that indicates the tree execution traversal was suspended due to re-execution request from an arbitrary executing node (NotifyStatus.Executing) or interruption when pausing, stopping, resetting or destroying the tree from an arbitrary interrupted node (NotifyStatus.Interrupt). |
NodeIndex | The node index of an arbitrary executing node or interrupted node that notified executing or interrupt. |
AccuLoopCount | The accumulated loop count when invoking this operation as specified by the basic play mode. |
TreeRootNode.OnPause | |
Signature: | |
void TreeRootNode.OnPause() | |
Description: | |
A node operation that is invoked when pausing the tree. Override this method in a derived class of TreeRootNode. | |
TreeRootNode.OnStop | |
Signature: | |
void TreeRootNode.OnStop() | |
Description: | |
A node operation that is invoked when stopping the tree. Override this method in a derived class of TreeRootNode. | |
TreeRootNode.OnConstruct | |
Signature: | |
void TreeRootNode.OnConstruct() | |
Description: | |
A node operation that is invoked when loading the tree. Override this method in a derived class of TreeRootNode. | |
TreeRootNode.OnDestruct | |
Signature: | |
void TreeRootNode.OnDestruct() | |
Description: | |
A node operation that is invoked when destroying the tree. Override this method in a derived class of TreeRootNode. | |
TreeRootNode.OnReset | |
Signature: | |
void TreeRootNode.OnReset() | |
Description: | |
A node operation that is invoked when resetting the tree. Override this method in a derived class of TreeRootNode. |
Copyright © 2016-2020 Qualgame, LLC