Skip to main content

Functions

Get Narrative Component

When you want to start any dialogue or quest, you need to get hold of the Narrative component.

This component is the driver that handles all dialogue or quests.

This function will attempt to load the component from the target passed into it (self by default), then the owning controller then the pawn.

get-narrative-component.webp

note

Under the hood, this function simply calls Get Narrative Component From Target passing in GetPlayerController.

If you are working in a multi-player environment with multiple Narrative components, use Get Narrative Component From Target instead.

Output

NameTypeDescription
Return ValueUNarrativeComponentThe Narrative component found on the actor.

Get Narrative Component From Target

Another method of getting hold of the Narrative component.

This function allows you to specify which target you want to get the Narrative Component from.

get-narrative-component-from-target.webp

note

This function is more useful for multiplayer games when you have multiple Narrative Components.

If you are working in a single player environment, GetNarrativeComponent is sufficient.

Inputs

NameTypeDescription
TargetAActorThe actor to try and find the Narrative component on.

Output

NameTypeDescription
Return ValueUNarrativeComponentThe Narrative component found on the actor.