Navigation
API > API/Plugins > API/Plugins/GameplayStateTreeModule > API/Plugins/GameplayStateTreeModule/UGameplayStateTreeBlueprintFunct-
Description
Starts executing an instance of the provided state tree asset on the specified actor. This will use the existing required component if present or add it if missing.
| Name | RunStateTree |
| Type | function |
| Header File | /Engine/Plugins/Runtime/GameplayStateTree/Source/GameplayStateTreeModule/Public/GameplayStateTreeBlueprintFunctionLibrary.h |
| Include Path | #include "GameplayStateTreeBlueprintFunctionLibrary.h" |
| Source | /Engine/Plugins/Runtime/GameplayStateTree/Source/GameplayStateTreeModule/Private/GameplayStateTreeBlueprintFunctionLibrary.cpp |
UFUNCTION (BlueprintCallable, Category="AI", Meta=(ReturnDisplayName="bSuccess"))
static bool RunStateTree
(
AActor * Actor,
UStateTree * StateTreeAsset
)
Whether a state tree instance was successfully started
Parameters
| Name | Remarks |
|---|---|
| Actor | The actor on which the StateTree must be executed. |
| StateTreeAsset | The state tree asset to execute |