Navigation
API > API/Plugins > API/Plugins/CommonConversationRuntime
Task are leaf nodes of behavior tree, which perform actual actions
Because some of them can be instanced for specific AI, following virtual functions are not marked as const:
- ExecuteTask
- AbortTask
- TickTask
- OnMessage
If your node is not being instanced (default behavior), DO NOT change any properties of object within those functions! Template nodes are shared across all behavior tree components using the same tree asset and must store their runtime properties in provided NodeMemory block (allocation size determined by GetInstanceMemorySize() ) The ConversationTaskNode is the basis of any task in the conversation graph, that task may be as simple as saying some text to the user, and providing some choices. However more complex tasks can fire off quests, can spawn actors, pretty much any arbitrary thing you want.
The conversation system is less about just a dialogue tree, and more about a graph of actions the NPC can take, and choices they can provide to the player.
| Name | UConversationTaskNode |
| Type | class |
| Header File | /Engine/Plugins/Experimental/CommonConversation/Source/CommonConversationRuntime/Public/ConversationTaskNode.h |
| Include Path | #include "ConversationTaskNode.h" |
Syntax
UCLASS (MinimalAPI, Abstract, Blueprintable)
class UConversationTaskNode : public UConversationNodeWithLinks
Inheritance Hierarchy
- UObjectBase → UObjectBaseUtility → UObject → UConversationNode → UConversationNodeWithLinks → UConversationTaskNode
Derived Classes
Variables
Public
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| bHasDynamicChoices | uint32 | EDITOR ONLY VISUALS: Does this task generate dynamic choices? | ConversationTaskNode.h |
|
| bHasRequirements | uint32 | EDITOR ONLY VISUALS: Does this task internally have requirements? | ConversationTaskNode.h |
|
| bIgnoreRequirementsWhileAdvancingConversations | bool | This setting is designed for requirements that only matter when option is generated. | ConversationTaskNode.h |
|
| SubNodes | TArray< TObjectPtr< UConversationSubNode > > | Requirements and side effects. | ConversationTaskNode.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
EConversationRequirementResult CheckRequirements
(
const FConversationContext& InContext |
Returns the highest priority EConversationRequirementResult, so Passed, having the least priority and FailedHidden having the highest priority. | ConversationTaskNode.h | |
FConversationTaskResult ExecuteTaskNodeWithSideEffects
(
const FConversationContext& Context |
ConversationTaskNode.h | ||
virtual void GenerateNextChoices
(
FConversationBranchPointBuilder& BranchBuilder, |
Generates this task nodes' next possible conversation chioces. | ConversationTaskNode.h | |
bool GetNodeBodyColor
(
FLinearColor& BodyColor |
ConversationTaskNode.h |
|
Overridden from UConversationNode
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual FName GetNodeIconName() |
Get the name of the icon used to display this node in the editor | ConversationTaskNode.h |
Protected
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void ExecuteClientEffects
(
const FConversationContext& Context |
ConversationTaskNode.h |
|
|
FConversationTaskResult ExecuteTaskNode
(
const FConversationContext& Context |
ConversationTaskNode.h |
|
|
virtual void GatherChoices
(
FConversationBranchPointBuilder& BranchBuilder, |
ConversationTaskNode.h | ||
virtual void GatherDynamicChoices
(
FConversationBranchPointBuilder& BranchBuilder, |
ConversationTaskNode.h | ||
virtual void GatherStaticChoices
(
FConversationBranchPointBuilder& BranchBuilder, |
ConversationTaskNode.h | ||
void GatherStaticExtraData
(
const FConversationContext& Context, |
ConversationTaskNode.h |
|
|
EConversationRequirementResult IsRequirementSatisfied
(
const FConversationContext& Context |
ConversationTaskNode.h |
|
Static
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
static void GenerateChoicesForDestinations
(
FConversationBranchPointBuilder& BranchBuilder, |
ConversationTaskNode.h |