A class containing utility functions related to Unreal Engine Behavior Trees.
More...
#include <BehaviorTreeUtils.h>
|
static void | PrintBehaviorTree (UBehaviorTree *behaviorTree, AActor *owner=NULL) |
| Print a behavior tree to the log. More...
|
|
static void | MapBehaviorTree (UNodeMapper *mapper, UBehaviorTree *behaviorTree) |
| Map all nodes in a given behavior tree using a UNodeMapper. More...
|
|
static FString | CompositeToString (int indentLevel, UBTCompositeNodeGene *node) |
| Converts the given CompositeNodeGene to a string. More...
|
|
static void | CompositeToLog (int indentLevel, UBTCompositeNodeGene *node) |
|
static FString | ServicesToString (int indentLevel, const UBTCompositeNodeGene *node) |
| Converts the given CompositeNodeGene's Services to a string. More...
|
|
static void | ServicesToLog (int indentLevel, const UBTCompositeNodeGene *node) |
|
static FString | ServicesToString (int indentLevel, const UBTTaskNodeGene *node) |
| Converts the given TaskNodeGene's Services to a string. More...
|
|
static void | ServicesToLog (int indentLevel, const UBTTaskNodeGene *node) |
|
static FString | DecoratorsToString (int indentLevel, const TArray< UBTDecoratorGene * > &decorators) |
| Converts an array of decorators into a string. More...
|
|
static void | DecoratorsToLog (int indentLevel, const TArray< UBTDecoratorGene * > &decorators) |
|
static FString | ServicesToString (int indentLevel, const TArray< UBTServiceGene * > &services) |
|
static void | ServicesToLog (int indentLevel, const TArray< UBTServiceGene * > &services) |
|
static bool | AssertEquals (UBehaviorTree *left, UBehaviorTree *right) |
| Checks that the given behavior trees are exactly alike. More...
|
|
|
static FString | DecoratorsToString (int indentLevel, const UBTChildContainerGene *compositeChild) |
|
static void | DecoratorsToLog (int indentLevel, const UBTChildContainerGene *compositeChild) |
|
static bool | AssertBaseDataEquals (UBTNode *left, UBTNode *right) |
|
static bool | AssertEquals (UBTCompositeNode *left, UBTCompositeNode *right) |
|
static bool | AssertEquals (FBTCompositeChild &left, FBTCompositeChild &right) |
|
static bool | AssertEquals (TArray< UBTDecorator * > &left, TArray< UBTDecorator * > &right) |
|
static bool | AssertEquals (TArray< UBTService * > &left, TArray< UBTService * > &right) |
|
A class containing utility functions related to Unreal Engine Behavior Trees.
- Author
- npc
- Date
- 12/01/17
◆ AssertEquals()
bool UBehaviorTreeUtils::AssertEquals |
( |
UBehaviorTree * |
left, |
|
|
UBehaviorTree * |
right |
|
) |
| |
|
static |
Checks that the given behavior trees are exactly alike.
- Parameters
-
left | The left behavior tree. |
right | The right behavior tree. |
- Returns
- True if the trees are the same, false otherwise.
◆ CompositeToString()
Converts the given CompositeNodeGene to a string.
- Parameters
-
indentLevel | The indent level at which to indent each line. |
node | The CompositeNodeGene to convert. |
- Returns
- The string.
◆ DecoratorsToString()
FString UBehaviorTreeUtils::DecoratorsToString |
( |
int |
indentLevel, |
|
|
const TArray< UBTDecoratorGene * > & |
decorators |
|
) |
| |
|
static |
Converts an array of decorators into a string.
- Parameters
-
indentLevel | The indent level at which to indent each line. |
decorators | The array of decorators. |
- Returns
- The resulting string.
◆ MapBehaviorTree()
void UBehaviorTreeUtils::MapBehaviorTree |
( |
UNodeMapper * |
mapper, |
|
|
UBehaviorTree * |
behaviorTree |
|
) |
| |
|
static |
Map all nodes in a given behavior tree using a UNodeMapper.
- Parameters
-
mapper | The mapper to use. |
behaviorTree | The Behavior Tree to map. |
◆ PrintBehaviorTree()
void UBehaviorTreeUtils::PrintBehaviorTree |
( |
UBehaviorTree * |
behaviorTree, |
|
|
AActor * |
owner = NULL |
|
) |
| |
|
static |
Print a behavior tree to the log.
- Parameters
-
behaviorTree | The Behavior Tree to print. |
owner | The Actor that owns this tree - may be null. |
If an Actor is provided as the owner, will use the Visual log.
◆ ServicesToString() [1/2]
Converts the given CompositeNodeGene's Services to a string.
- Parameters
-
indentLevel | The indent level at which to indent each line. |
node | The CompositeNodeGene who's services to convert. |
- Returns
- The string.
◆ ServicesToString() [2/2]
FString UBehaviorTreeUtils::ServicesToString |
( |
int |
indentLevel, |
|
|
const UBTTaskNodeGene * |
node |
|
) |
| |
|
static |
Converts the given TaskNodeGene's Services to a string.
- Parameters
-
indentLevel | The indent level at which to indent each line. |
node | The TaskNodeGene who's services to convert. |
- Returns
- The string.
The documentation for this class was generated from the following files:
- Source/EvolvingBehavior/Public/BehaviorTreeUtils.h
- Source/EvolvingBehavior/Private/BehaviorTreeUtils.cpp