A Demo Project for the UnrealEngineSDK
Loading...
Searching...
No Matches
UDlgContext Class ReferenceBlueprintType

UCLASS(BlueprintType) More...

#include <DlgContext.h>

Inheritance diagram for UDlgContext:
[legend]

Public Member Functions

 UDlgContext (const FObjectInitializer &ObjectInitializer)
 
bool ChooseChild (int32 OptionIndex)
 UFUNCTION(BlueprintCallable, Category = "Dialogue|Control", meta = (DeprecatedFunction, DeprecationMessage = "ChooseChild has been deprecated in favour of ChooseOption"))
 
bool ChooseChildBasedOnAllOptionIndex (int32 Index)
 UFUNCTION(BlueprintCallable, Category = "Dialogue|Control|All", meta = (DeprecatedFunction, DeprecationMessage = "ChooseChildBasedOnAllOptionIndex has been deprecated in Favour of ChooseOptionBasedOnAllOptionIndex"))
 
bool ChooseOption (int32 OptionIndex)
 UFUNCTION(BlueprintCallable, Category = "Dialogue|Control")
 
bool ChooseOptionBasedOnAllOptionIndex (int32 Index)
 UFUNCTION(BlueprintCallable, Category = "Dialogue|Control|All")
 
bool ChooseSpeechSequenceOptionFromReplicated (int32 OptionIndex)
 UFUNCTION(BlueprintCallable, Category = "Dialogue|Control")
 
UDlgContextCreateCopy () const
 
bool EnterNode (int32 NodeIndex, TSet< const UDlgNode * > NodesEnteredWithThisStep)
 
const UDlgNodeGetActiveNode () const
 
const UDlgNode_SpeechSequenceGetActiveNodeAsSpeechSequence () const
 
UDlgNodeDataGetActiveNodeData () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")
 
UObjectGetActiveNodeGenericData () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")
 
FGuid GetActiveNodeGUID () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")
 
int32 GetActiveNodeIndex () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")
 
UObjectGetActiveNodeParticipant () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")
 
FText GetActiveNodeParticipantDisplayName () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")
 
UTexture2D * GetActiveNodeParticipantIcon () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")
 
FName GetActiveNodeParticipantName () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")
 
FName GetActiveNodeSpeakerState () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")
 
const FTextGetActiveNodeText () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")
 
UDialogueWave * GetActiveNodeVoiceDialogueWave () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")
 
USoundBase * GetActiveNodeVoiceSoundBase () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")
 
USoundWave * GetActiveNodeVoiceSoundWave () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")
 
TArray< FDlgEdgeData > & GetAllMutableOptionsArray ()
 
const TArray< FDlgEdgeData > & GetAllOptionsArray () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Options|All")
 
int32 GetAllOptionsNum () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Options|All")
 
FString GetContextString () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Context")
 
UDlgDialogueGetDialogue () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Data")
 
FGuid GetDialogueGUID () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Data")
 
FName GetDialogueName () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Data")
 
FString GetDialoguePathName () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Data")
 
const FDlgHistoryGetHistoryOfThisContext () const
 
void GetLifetimeReplicatedProps (TArray< FLifetimeProperty > &OutLifetimeProps) const override
 
UDlgNodeGetMutableActiveNode () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode", DisplayName = "Get Active Node")
 
UDlgNode_SpeechSequenceGetMutableActiveNodeAsSpeechSequence () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode", DisplayName = "Get Active Node As Speech Sequence")
 
UDlgNodeGetMutableNodeFromGUID (const FGuid &NodeGUID) const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Data", DisplayName = "Get Node From GUID")
 
UDlgNodeGetMutableNodeFromIndex (int32 NodeIndex) const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Data", DisplayName = "Get Node From Index")
 
TArray< FDlgEdge > & GetMutableOptionsArray ()
 
UObjectGetMutableParticipant (FName ParticipantName) const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Data", DisplayName = "Get Participant")
 
const UDlgNodeGetNodeFromGUID (const FGuid &NodeGUID) const
 
const UDlgNodeGetNodeFromIndex (int32 NodeIndex) const
 
FGuid GetNodeGUIDForIndex (int32 NodeIndex) const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Data", DisplayName = "Get Node GUID For Index")
 
int32 GetNodeIndexForGUID (const FGuid &NodeGUID) const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Data", DisplayName = "Get Node Index For GUID")
 
const FDlgEdgeGetOption (int32 OptionIndex) const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Options|Satisfied")
 
const TArray< FDlgCondition > & GetOptionEnterConditions (int32 OptionIndex) const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Options|Satisfied")
 
const FDlgEdgeDataGetOptionFromAll (int32 Index) const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Options|All")
 
const TArray< FDlgEdge > & GetOptionsArray () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Options|Satisfied")
 
int32 GetOptionsNum () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Options|Satisfied")
 
FName GetOptionSpeakerState (int32 OptionIndex) const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Options|Satisfied")
 
FName GetOptionSpeakerStateFromAll (int32 Index) const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Options|All")
 
const FTextGetOptionText (int32 OptionIndex) const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Options|Satisfied")
 
const FTextGetOptionTextFromAll (int32 Index) const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Options|All")
 
const UObjectGetParticipant (FName ParticipantName) const
 
const TMap< FName, UObject * > & GetParticipants () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Data")
 
const TMap< FName, UObject * > & GetParticipantsMap () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Data")
 
const TSet< FGuid > & GetVisitedNodeGUIDs () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Context|History")
 
const TSet< int32 > & GetVisitedNodeIndices () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Context|History")
 
UWorld * GetWorld () const override
 
bool HasDialogueEnded () const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Control")
 
bool IsNodeEnterable (int32 NodeIndex, TSet< const UDlgNode * > AlreadyVisitedNodes) const
 
bool IsOptionConnectedToEndNode (int32 Index, bool bIndexSkipsUnsatisfiedEdges=true) const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Data")
 
bool IsOptionConnectedToVisitedNode (int32 Index, bool bLocalHistory=false, bool bIndexSkipsUnsatisfiedEdges=true) const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Data")
 
bool IsOptionSatisfied (int32 Index) const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Options|All")
 
bool IsSupportedForNetworking () const override
 
bool IsValidAllOptionIndex (int32 Index) const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Options|All")
 
bool IsValidNodeGUID (const FGuid &NodeGUID) const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Data")
 
bool IsValidNodeIndex (int32 NodeIndex) const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Data")
 
bool IsValidOptionIndex (int32 OptionIndex) const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Options|Satisfied")
 
void OnRep_SerializedParticipants ()
 UFUNCTION()
 
void PostInitProperties () override
 
bool ReevaluateChildren ()
 UFUNCTION(BlueprintCallable, Category = "Dialogue|Control", meta = (DeprecatedFunction, DeprecationMessage = "ReevaluateChildren has been deprecated in Favour of ReevaluateOptions"))
 
bool ReevaluateOptions ()
 UFUNCTION(BlueprintCallable, Category = "Dialogue|Control")
 
void SerializeParticipants ()
 
void SetNodeVisited (int32 NodeIndex, const FGuid &NodeGUID)
 
bool Start (UDlgDialogue *InDialogue, const TMap< FName, UObject * > &InParticipants)
 
bool StartFromNode (UDlgDialogue *InDialogue, const TMap< FName, UObject * > &InParticipants, int32 StartNodeIndex, const FGuid &StartNodeGUID, const FDlgHistory &StartHistory, bool bFireEnterEvents)
 
bool StartFromNodeGUID (UDlgDialogue *InDialogue, const TMap< FName, UObject * > &InParticipants, const FGuid &StartNodeGUID, const FDlgHistory &StartHistory, bool bFireEnterEvents)
 
bool StartFromNodeIndex (UDlgDialogue *InDialogue, const TMap< FName, UObject * > &InParticipants, int32 StartNodeIndex, const FDlgHistory &StartHistory, bool bFireEnterEvents)
 
bool StartWithContext (const FString &ContextString, UDlgDialogue *InDialogue, const TMap< FName, UObject * > &InParticipants)
 
bool StartWithContextFromNode (const FString &ContextString, UDlgDialogue *InDialogue, const TMap< FName, UObject * > &InParticipants, int32 StartNodeIndex, const FGuid &StartNodeGUID, const FDlgHistory &StartHistory, bool bFireEnterEvents)
 
bool StartWithContextFromNodeGUID (const FString &ContextString, UDlgDialogue *InDialogue, const TMap< FName, UObject * > &InParticipants, const FGuid &StartNodeGUID, const FDlgHistory &StartHistory, bool bFireEnterEvents)
 
bool StartWithContextFromNodeIndex (const FString &ContextString, UDlgDialogue *InDialogue, const TMap< FName, UObject * > &InParticipants, int32 StartNodeIndex, const FDlgHistory &StartHistory, bool bFireEnterEvents)
 
bool WasNodeGUIDVisitedInThisContext (const FGuid &NodeGUID) const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Context|History", DisplayName = "Was Node GUID Visited In This Context")
 
bool WasNodeIndexVisitedInThisContext (int32 NodeIndex) const
 UFUNCTION(BlueprintPure, Category = "Dialogue|Context|History", DisplayName = "Was Node Index Visited In This Context")
 

Static Public Member Functions

static bool CanBeStarted (UDlgDialogue *InDialogue, const TMap< FName, UObject * > &InParticipants)
 
static bool ConvertArrayOfParticipantsToMap (const FString &ContextString, const UDlgDialogue *Dialogue, const TArray< UObject * > &ParticipantsArray, TMap< FName, UObject * > &OutParticipantsMap, bool bLog=true)
 
static EDlgValidateStatus IsValidParticipantForDialogue (const UDlgDialogue *Dialogue, const UObject *Participant)
 
static bool ValidateParticipantForDialogue (const FString &ContextString, const UDlgDialogue *Dialogue, const UObject *Participant, bool bLog=true)
 
static bool ValidateParticipantsMapForDialogue (const FString &ContextString, const UDlgDialogue *Dialogue, const TMap< FName, UObject * > &ParticipantsMap, bool bLog=true)
 

Public Attributes

FOnNodeEntered OnNodeEntered
 UPROPERTY(BlueprintAssignable, Category = "Events")
 

Protected Member Functions

FString GetErrorMessageWithContext (const FString &ErrorMessage) const
 
void LogErrorWithContext (const FString &ErrorMessage) const
 
void SetParticipants (const TMap< FName, UObject * > &InParticipants)
 

Protected Attributes

int32 ActiveNodeIndex = INDEX_NONE
 
TArray< FDlgEdgeDataAllChildren
 
TArray< FDlgEdgeAvailableChildren
 
bool bDialogueEnded = false
 
UDlgDialogueDialogue = nullptr
 UPROPERTY(Replicated)
 
FDlgHistory History
 
TMap< FName, UObject * > Participants
 UPROPERTY()
 
TArray< UObject * > SerializedParticipants
 UPROPERTY(Replicated, ReplicatedUsing = OnRep_SerializedParticipants)
 

Private Member Functions

 GENERATED_BODY ()
 

Detailed Description

UCLASS(BlueprintType)

Class representing an active dialogue, can be used to gain information and to control it Should be controlled from Player Character/Player controller For starting a dialogue check UDlgManager - the proper function creates an UDlgContext for you

Call ChooseOption() if an option is selected If the return value is false the dialogue is over and the context should be dropped This abstract class contains the outer functionality only

Definition at line 95 of file DlgContext.h.

Constructor & Destructor Documentation

◆ UDlgContext()

UDlgContext::UDlgContext ( const FObjectInitializer & ObjectInitializer)

Definition at line 15 of file DlgContext.cpp.

Member Function Documentation

◆ CanBeStarted()

bool UDlgContext::CanBeStarted ( UDlgDialogue * InDialogue,
const TMap< FName, UObject * > & InParticipants )
static

Definition at line 619 of file DlgContext.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ChooseChild()

bool UDlgContext::ChooseChild ( int32 OptionIndex)
inlineBlueprintCallable

UFUNCTION(BlueprintCallable, Category = "Dialogue|Control", meta = (DeprecatedFunction, DeprecationMessage = "ChooseChild has been deprecated in favour of ChooseOption"))

Definition at line 127 of file DlgContext.h.

◆ ChooseChildBasedOnAllOptionIndex()

bool UDlgContext::ChooseChildBasedOnAllOptionIndex ( int32 Index)
inlineBlueprintCallable

UFUNCTION(BlueprintCallable, Category = "Dialogue|Control|All", meta = (DeprecatedFunction, DeprecationMessage = "ChooseChildBasedOnAllOptionIndex has been deprecated in Favour of ChooseOptionBasedOnAllOptionIndex"))

Definition at line 159 of file DlgContext.h.

◆ ChooseOption()

bool UDlgContext::ChooseOption ( int32 OptionIndex)
BlueprintCallable

UFUNCTION(BlueprintCallable, Category = "Dialogue|Control")

Chooses the option with index OptionIndex of the active node index and it enters that node. Typically called based on user input. NOTICE: If the return value is false the dialogue is over and the context should be dropped

Returns
true if the dialogue did not end, false otherwise

Definition at line 49 of file DlgContext.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ChooseOptionBasedOnAllOptionIndex()

bool UDlgContext::ChooseOptionBasedOnAllOptionIndex ( int32 Index)
BlueprintCallable

UFUNCTION(BlueprintCallable, Category = "Dialogue|Control|All")

Exactly as ChooseChild but expects an index from the AllOptions array If the index is invalid or the selected edge is not satisfied the call fails

Definition at line 79 of file DlgContext.cpp.

Here is the call graph for this function:

◆ ChooseSpeechSequenceOptionFromReplicated()

bool UDlgContext::ChooseSpeechSequenceOptionFromReplicated ( int32 OptionIndex)
BlueprintCallable

UFUNCTION(BlueprintCallable, Category = "Dialogue|Control")

Chooses the option with OptionIndex that is replicated NOTE: the ActiveNodeIndex must be a speech sequence node, otherwise the dialogue will end

Returns
true if the dialogue did not end, false otherwise

Definition at line 64 of file DlgContext.cpp.

Here is the call graph for this function:

◆ ConvertArrayOfParticipantsToMap()

bool UDlgContext::ConvertArrayOfParticipantsToMap ( const FString & ContextString,
const UDlgDialogue * Dialogue,
const TArray< UObject * > & ParticipantsArray,
TMap< FName, UObject * > & OutParticipantsMap,
bool bLog = true )
static

Definition at line 971 of file DlgContext.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ CreateCopy()

UDlgContext * UDlgContext::CreateCopy ( ) const

Definition at line 520 of file DlgContext.cpp.

◆ EnterNode()

bool UDlgContext::EnterNode ( int32 NodeIndex,
TSet< const UDlgNode * > NodesEnteredWithThisStep )

Definition at line 502 of file DlgContext.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GENERATED_BODY()

UDlgContext::GENERATED_BODY ( )
private

◆ GetActiveNode()

const UDlgNode * UDlgContext::GetActiveNode ( ) const
inline

Definition at line 449 of file DlgContext.h.

Here is the caller graph for this function:

◆ GetActiveNodeAsSpeechSequence()

const UDlgNode_SpeechSequence * UDlgContext::GetActiveNodeAsSpeechSequence ( ) const

Definition at line 559 of file DlgContext.cpp.

Here is the call graph for this function:

◆ GetActiveNodeData()

UDlgNodeData * UDlgContext::GetActiveNodeData ( ) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")

Definition at line 290 of file DlgContext.cpp.

Here is the call graph for this function:

◆ GetActiveNodeGenericData()

UObject * UDlgContext::GetActiveNodeGenericData ( ) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")

Definition at line 278 of file DlgContext.cpp.

Here is the call graph for this function:

◆ GetActiveNodeGUID()

FGuid UDlgContext::GetActiveNodeGUID ( ) const
inlineBlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")

Definition at line 442 of file DlgContext.h.

◆ GetActiveNodeIndex()

int32 UDlgContext::GetActiveNodeIndex ( ) const
inlineBlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")

Definition at line 436 of file DlgContext.h.

◆ GetActiveNodeParticipant()

UObject * UDlgContext::GetActiveNodeParticipant ( ) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")

Definition at line 325 of file DlgContext.cpp.

Here is the call graph for this function:

◆ GetActiveNodeParticipantDisplayName()

FText UDlgContext::GetActiveNodeParticipantDisplayName ( ) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")

Definition at line 360 of file DlgContext.cpp.

Here is the call graph for this function:

◆ GetActiveNodeParticipantIcon()

UTexture2D * UDlgContext::GetActiveNodeParticipantIcon ( ) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")

Definition at line 302 of file DlgContext.cpp.

Here is the call graph for this function:

◆ GetActiveNodeParticipantName()

FName UDlgContext::GetActiveNodeParticipantName ( ) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")

Definition at line 348 of file DlgContext.cpp.

Here is the call graph for this function:

◆ GetActiveNodeSpeakerState()

FName UDlgContext::GetActiveNodeSpeakerState ( ) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")

Definition at line 230 of file DlgContext.cpp.

Here is the call graph for this function:

◆ GetActiveNodeText()

const FText & UDlgContext::GetActiveNodeText ( ) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")

Definition at line 218 of file DlgContext.cpp.

Here is the call graph for this function:

◆ GetActiveNodeVoiceDialogueWave()

UDialogueWave * UDlgContext::GetActiveNodeVoiceDialogueWave ( ) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")

Definition at line 266 of file DlgContext.cpp.

Here is the call graph for this function:

◆ GetActiveNodeVoiceSoundBase()

USoundBase * UDlgContext::GetActiveNodeVoiceSoundBase ( ) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")

Definition at line 254 of file DlgContext.cpp.

Here is the call graph for this function:

◆ GetActiveNodeVoiceSoundWave()

USoundWave * UDlgContext::GetActiveNodeVoiceSoundWave ( ) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode")

Definition at line 242 of file DlgContext.cpp.

Here is the call graph for this function:

◆ GetAllMutableOptionsArray()

TArray< FDlgEdgeData > & UDlgContext::GetAllMutableOptionsArray ( )
inline

Definition at line 304 of file DlgContext.h.

Here is the caller graph for this function:

◆ GetAllOptionsArray()

const TArray< FDlgEdgeData > & UDlgContext::GetAllOptionsArray ( ) const
inlineBlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Options|All")

Definition at line 303 of file DlgContext.h.

◆ GetAllOptionsNum()

int32 UDlgContext::GetAllOptionsNum ( ) const
inlineBlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Options|All")

Definition at line 261 of file DlgContext.h.

◆ GetContextString()

FString UDlgContext::GetContextString ( ) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Context")

Definition at line 743 of file DlgContext.cpp.

Here is the caller graph for this function:

◆ GetDialogue()

UDlgDialogue * UDlgContext::GetDialogue ( ) const
inlineBlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Data")

Definition at line 510 of file DlgContext.h.

◆ GetDialogueGUID()

FGuid UDlgContext::GetDialogueGUID ( ) const
inlineBlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Data")

Definition at line 522 of file DlgContext.h.

Here is the caller graph for this function:

◆ GetDialogueName()

FName UDlgContext::GetDialogueName ( ) const
inlineBlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Data")

Definition at line 516 of file DlgContext.h.

◆ GetDialoguePathName()

FString UDlgContext::GetDialoguePathName ( ) const
inlineBlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Data")

Definition at line 528 of file DlgContext.h.

◆ GetErrorMessageWithContext()

FString UDlgContext::GetErrorMessageWithContext ( const FString & ErrorMessage) const
protected

Definition at line 765 of file DlgContext.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetHistoryOfThisContext()

const FDlgHistory & UDlgContext::GetHistoryOfThisContext ( ) const
inline

Definition at line 584 of file DlgContext.h.

Here is the caller graph for this function:

◆ GetLifetimeReplicatedProps()

void UDlgContext::GetLifetimeReplicatedProps ( TArray< FLifetimeProperty > & OutLifetimeProps) const
override

Definition at line 21 of file DlgContext.cpp.

◆ GetMutableActiveNode()

UDlgNode * UDlgContext::GetMutableActiveNode ( ) const
inlineBlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode", DisplayName = "Get Active Node")

Definition at line 448 of file DlgContext.h.

Here is the caller graph for this function:

◆ GetMutableActiveNodeAsSpeechSequence()

UDlgNode_SpeechSequence * UDlgContext::GetMutableActiveNodeAsSpeechSequence ( ) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|ActiveNode", DisplayName = "Get Active Node As Speech Sequence")

Definition at line 554 of file DlgContext.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetMutableNodeFromGUID()

UDlgNode * UDlgContext::GetMutableNodeFromGUID ( const FGuid & NodeGUID) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Data", DisplayName = "Get Node From GUID")

Definition at line 586 of file DlgContext.cpp.

Here is the call graph for this function:

◆ GetMutableNodeFromIndex()

UDlgNode * UDlgContext::GetMutableNodeFromIndex ( int32 NodeIndex) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Data", DisplayName = "Get Node From Index")

Definition at line 564 of file DlgContext.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetMutableOptionsArray()

TArray< FDlgEdge > & UDlgContext::GetMutableOptionsArray ( )
inline

Definition at line 249 of file DlgContext.h.

Here is the caller graph for this function:

◆ GetMutableParticipant()

UObject * UDlgContext::GetMutableParticipant ( FName ParticipantName) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Data", DisplayName = "Get Participant")

Definition at line 383 of file DlgContext.cpp.

Here is the caller graph for this function:

◆ GetNodeFromGUID()

const UDlgNode * UDlgContext::GetNodeFromGUID ( const FGuid & NodeGUID) const

Definition at line 597 of file DlgContext.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetNodeFromIndex()

const UDlgNode * UDlgContext::GetNodeFromIndex ( int32 NodeIndex) const

Definition at line 575 of file DlgContext.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetNodeGUIDForIndex()

FGuid UDlgContext::GetNodeGUIDForIndex ( int32 NodeIndex) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Data", DisplayName = "Get Node GUID For Index")

Definition at line 415 of file DlgContext.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetNodeIndexForGUID()

int32 UDlgContext::GetNodeIndexForGUID ( const FGuid & NodeGUID) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Data", DisplayName = "Get Node Index For GUID")

Definition at line 420 of file DlgContext.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetOption()

const FDlgEdge & UDlgContext::GetOption ( int32 OptionIndex) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Options|Satisfied")

Definition at line 158 of file DlgContext.cpp.

Here is the call graph for this function:

◆ GetOptionEnterConditions()

const TArray< FDlgCondition > & UDlgContext::GetOptionEnterConditions ( int32 OptionIndex) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Options|Satisfied")

Definition at line 145 of file DlgContext.cpp.

Here is the call graph for this function:

◆ GetOptionFromAll()

const FDlgEdgeData & UDlgContext::GetOptionFromAll ( int32 Index) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Options|All")

Definition at line 206 of file DlgContext.cpp.

Here is the call graph for this function:

◆ GetOptionsArray()

const TArray< FDlgEdge > & UDlgContext::GetOptionsArray ( ) const
inlineBlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Options|Satisfied")

Definition at line 248 of file DlgContext.h.

Here is the caller graph for this function:

◆ GetOptionsNum()

int32 UDlgContext::GetOptionsNum ( ) const
inlineBlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Options|Satisfied")

Definition at line 203 of file DlgContext.h.

◆ GetOptionSpeakerState()

FName UDlgContext::GetOptionSpeakerState ( int32 OptionIndex) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Options|Satisfied")

Definition at line 133 of file DlgContext.cpp.

Here is the call graph for this function:

◆ GetOptionSpeakerStateFromAll()

FName UDlgContext::GetOptionSpeakerStateFromAll ( int32 Index) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Options|All")

Definition at line 194 of file DlgContext.cpp.

Here is the call graph for this function:

◆ GetOptionText()

const FText & UDlgContext::GetOptionText ( int32 OptionIndex) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Options|Satisfied")

Definition at line 121 of file DlgContext.cpp.

Here is the call graph for this function:

◆ GetOptionTextFromAll()

const FText & UDlgContext::GetOptionTextFromAll ( int32 Index) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Options|All")

Definition at line 170 of file DlgContext.cpp.

Here is the call graph for this function:

◆ GetParticipant()

const UObject * UDlgContext::GetParticipant ( FName ParticipantName) const

Definition at line 394 of file DlgContext.cpp.

Here is the caller graph for this function:

◆ GetParticipants()

const TMap< FName, UObject * > & UDlgContext::GetParticipants ( ) const
inlineBlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Data")

Definition at line 534 of file DlgContext.h.

◆ GetParticipantsMap()

const TMap< FName, UObject * > & UDlgContext::GetParticipantsMap ( ) const
inlineBlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Data")

Definition at line 430 of file DlgContext.h.

◆ GetVisitedNodeGUIDs()

const TSet< FGuid > & UDlgContext::GetVisitedNodeGUIDs ( ) const
inlineBlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Context|History")

Definition at line 503 of file DlgContext.h.

◆ GetVisitedNodeIndices()

const TSet< int32 > & UDlgContext::GetVisitedNodeIndices ( ) const
inlineBlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Context|History")

Definition at line 496 of file DlgContext.h.

◆ GetWorld()

UWorld * UDlgObject::GetWorld ( ) const
overrideinherited

Definition at line 22 of file DlgObject.cpp.

Here is the call graph for this function:

◆ HasDialogueEnded()

bool UDlgContext::HasDialogueEnded ( ) const
inlineBlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Control")

Definition at line 192 of file DlgContext.h.

◆ IsNodeEnterable()

bool UDlgContext::IsNodeEnterable ( int32 NodeIndex,
TSet< const UDlgNode * > AlreadyVisitedNodes ) const

Definition at line 608 of file DlgContext.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ IsOptionConnectedToEndNode()

bool UDlgContext::IsOptionConnectedToEndNode ( int32 Index,
bool bIndexSkipsUnsatisfiedEdges = true ) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Data")

Checks if the node is connected directly to an end node or not Does not handle complicated logic - if the said node is a logical one it will still check that node, and not one of its option

Parameters
IndexIndex of the edge/player option to test
bIndexSkipsUnsatisfiedEdgesDecides if the index is in the [0, GetOptionsNum()[ interval (if true), or in the [0, GetAllOptionsNum()[ (if false)
Returns
true if the node is an end node

Definition at line 463 of file DlgContext.cpp.

Here is the call graph for this function:

◆ IsOptionConnectedToVisitedNode()

bool UDlgContext::IsOptionConnectedToVisitedNode ( int32 Index,
bool bLocalHistory = false,
bool bIndexSkipsUnsatisfiedEdges = true ) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Data")

Checks if the node connected directly to one of the active player choices was already visited or not Does not handle complicated logic - if the said node is a logical one it will still check that node, and not one of its options

Parameters
IndexIndex of the edge/player option to test
bLocalHistoryIf true, only the history of this dialogue context is checked. If false, it is a global check
bIndexSkipsUnsatisfiedEdgesDecides if the index is in the [0, GetOptionsNum()[ interval (if true), or in the [0, GetAllOptionsNum()[ (if false)
Returns
true if the node was already IsOptionConnectedToVisitedNode

Definition at line 425 of file DlgContext.cpp.

Here is the call graph for this function:

◆ IsOptionSatisfied()

bool UDlgContext::IsOptionSatisfied ( int32 Index) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Options|All")

Definition at line 182 of file DlgContext.cpp.

Here is the call graph for this function:

◆ IsSupportedForNetworking()

bool UDlgContext::IsSupportedForNetworking ( ) const
inlineoverride

Definition at line 109 of file DlgContext.h.

◆ IsValidAllOptionIndex()

bool UDlgContext::IsValidAllOptionIndex ( int32 Index) const
inlineBlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Options|All")

Definition at line 268 of file DlgContext.h.

◆ IsValidNodeGUID()

bool UDlgContext::IsValidNodeGUID ( const FGuid & NodeGUID) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Data")

Definition at line 410 of file DlgContext.cpp.

Here is the call graph for this function:

◆ IsValidNodeIndex()

bool UDlgContext::IsValidNodeIndex ( int32 NodeIndex) const
BlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Data")

Definition at line 405 of file DlgContext.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ IsValidOptionIndex()

bool UDlgContext::IsValidOptionIndex ( int32 OptionIndex) const
inlineBlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Options|Satisfied")

Definition at line 210 of file DlgContext.h.

◆ IsValidParticipantForDialogue()

EDlgValidateStatus UDlgContext::IsValidParticipantForDialogue ( const UDlgDialogue * Dialogue,
const UObject * Participant )
static

Definition at line 770 of file DlgContext.cpp.

Here is the caller graph for this function:

◆ LogErrorWithContext()

void UDlgContext::LogErrorWithContext ( const FString & ErrorMessage) const
protected

Definition at line 760 of file DlgContext.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ OnRep_SerializedParticipants()

void UDlgContext::OnRep_SerializedParticipants ( )

UFUNCTION()

Definition at line 37 of file DlgContext.cpp.

◆ PostInitProperties()

void UDlgContext::PostInitProperties ( )
inlineoverride

Definition at line 104 of file DlgContext.h.

◆ ReevaluateChildren()

bool UDlgContext::ReevaluateChildren ( )
inlineBlueprintCallable

UFUNCTION(BlueprintCallable, Category = "Dialogue|Control", meta = (DeprecatedFunction, DeprecationMessage = "ReevaluateChildren has been deprecated in Favour of ReevaluateOptions"))

Definition at line 176 of file DlgContext.h.

◆ ReevaluateOptions()

bool UDlgContext::ReevaluateOptions ( )
BlueprintCallable

UFUNCTION(BlueprintCallable, Category = "Dialogue|Control")

Normally the options of the active node are checked only once, when the conversation enters the node. If an option can appear/disappear real time in the middle of the conversation this function should be called manually each frame

Definition at line 108 of file DlgContext.cpp.

Here is the call graph for this function:

◆ SerializeParticipants()

void UDlgContext::SerializeParticipants ( )

Definition at line 28 of file DlgContext.cpp.

◆ SetNodeVisited()

void UDlgContext::SetNodeVisited ( int32 NodeIndex,
const FGuid & NodeGUID )

Definition at line 548 of file DlgContext.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SetParticipants()

void UDlgContext::SetParticipants ( const TMap< FName, UObject * > & InParticipants)
inlineprotected

Definition at line 764 of file DlgContext.h.

Here is the caller graph for this function:

◆ Start()

bool UDlgContext::Start ( UDlgDialogue * InDialogue,
const TMap< FName, UObject * > & InParticipants )
inline

Definition at line 592 of file DlgContext.h.

◆ StartFromNode()

bool UDlgContext::StartFromNode ( UDlgDialogue * InDialogue,
const TMap< FName, UObject * > & InParticipants,
int32 StartNodeIndex,
const FGuid & StartNodeGUID,
const FDlgHistory & StartHistory,
bool bFireEnterEvents )
inline

Definition at line 688 of file DlgContext.h.

◆ StartFromNodeGUID()

bool UDlgContext::StartFromNodeGUID ( UDlgDialogue * InDialogue,
const TMap< FName, UObject * > & InParticipants,
const FGuid & StartNodeGUID,
const FDlgHistory & StartHistory,
bool bFireEnterEvents )
inline

Definition at line 644 of file DlgContext.h.

◆ StartFromNodeIndex()

bool UDlgContext::StartFromNodeIndex ( UDlgDialogue * InDialogue,
const TMap< FName, UObject * > & InParticipants,
int32 StartNodeIndex,
const FDlgHistory & StartHistory,
bool bFireEnterEvents )
inline

Definition at line 602 of file DlgContext.h.

◆ StartWithContext()

bool UDlgContext::StartWithContext ( const FString & ContextString,
UDlgDialogue * InDialogue,
const TMap< FName, UObject * > & InParticipants )

Definition at line 661 of file DlgContext.cpp.

Here is the call graph for this function:

◆ StartWithContextFromNode()

bool UDlgContext::StartWithContextFromNode ( const FString & ContextString,
UDlgDialogue * InDialogue,
const TMap< FName, UObject * > & InParticipants,
int32 StartNodeIndex,
const FGuid & StartNodeGUID,
const FDlgHistory & StartHistory,
bool bFireEnterEvents )

Definition at line 694 of file DlgContext.cpp.

Here is the call graph for this function:

◆ StartWithContextFromNodeGUID()

bool UDlgContext::StartWithContextFromNodeGUID ( const FString & ContextString,
UDlgDialogue * InDialogue,
const TMap< FName, UObject * > & InParticipants,
const FGuid & StartNodeGUID,
const FDlgHistory & StartHistory,
bool bFireEnterEvents )
inline

Definition at line 661 of file DlgContext.h.

◆ StartWithContextFromNodeIndex()

bool UDlgContext::StartWithContextFromNodeIndex ( const FString & ContextString,
UDlgDialogue * InDialogue,
const TMap< FName, UObject * > & InParticipants,
int32 StartNodeIndex,
const FDlgHistory & StartHistory,
bool bFireEnterEvents )
inline

Definition at line 619 of file DlgContext.h.

◆ ValidateParticipantForDialogue()

bool UDlgContext::ValidateParticipantForDialogue ( const FString & ContextString,
const UDlgDialogue * Dialogue,
const UObject * Participant,
bool bLog = true )
static

Definition at line 805 of file DlgContext.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ValidateParticipantsMapForDialogue()

bool UDlgContext::ValidateParticipantsMapForDialogue ( const FString & ContextString,
const UDlgDialogue * Dialogue,
const TMap< FName, UObject * > & ParticipantsMap,
bool bLog = true )
static

Definition at line 866 of file DlgContext.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ WasNodeGUIDVisitedInThisContext()

bool UDlgContext::WasNodeGUIDVisitedInThisContext ( const FGuid & NodeGUID) const
inlineBlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Context|History", DisplayName = "Was Node GUID Visited In This Context")

Definition at line 578 of file DlgContext.h.

◆ WasNodeIndexVisitedInThisContext()

bool UDlgContext::WasNodeIndexVisitedInThisContext ( int32 NodeIndex) const
inlineBlueprintPure

UFUNCTION(BlueprintPure, Category = "Dialogue|Context|History", DisplayName = "Was Node Index Visited In This Context")

Definition at line 568 of file DlgContext.h.

Member Data Documentation

◆ ActiveNodeIndex

int32 UDlgContext::ActiveNodeIndex = INDEX_NONE
protected

Definition at line 793 of file DlgContext.h.

◆ AllChildren

TArray<FDlgEdgeData> UDlgContext::AllChildren
protected

List of options which is possible, or would be with satisfied conditions (e.g. in case of virtual parent it isn't necessary the node's child, that's why we have this array here instead of simply returning something from active node

Definition at line 803 of file DlgContext.h.

◆ AvailableChildren

TArray<FDlgEdge> UDlgContext::AvailableChildren
protected

Definition at line 796 of file DlgContext.h.

◆ bDialogueEnded

bool UDlgContext::bDialogueEnded = false
protected

Definition at line 810 of file DlgContext.h.

◆ Dialogue

UDlgDialogue* UDlgContext::Dialogue = nullptr
protectedReplicated

UPROPERTY(Replicated)

Definition at line 776 of file DlgContext.h.

◆ History

FDlgHistory UDlgContext::History
protected

Definition at line 807 of file DlgContext.h.

◆ OnNodeEntered

FOnNodeEntered UDlgContext::OnNodeEntered
BlueprintAssignable

UPROPERTY(BlueprintAssignable, Category = "Events")

Definition at line 817 of file DlgContext.h.

◆ Participants

TMap<FName, UObject*> UDlgContext::Participants
protected

UPROPERTY()

Definition at line 790 of file DlgContext.h.

◆ SerializedParticipants

TArray<UObject*> UDlgContext::SerializedParticipants
protectedReplicated

UPROPERTY(Replicated, ReplicatedUsing = OnRep_SerializedParticipants)

Definition at line 783 of file DlgContext.h.


The documentation for this class was generated from the following files: