Runtime integration

Intermediate Last updated Jul 9, 2026

On this page

Questwright is engine-native and standalone; the integration surface is deliberately small. This page covers every touch point between the plugin and your game code (C++ or Blueprint).

The quest component

Quest progress is a fact about (player, quest). It lives on UQuestwrightQuestComponent, auto-added to each PlayerState (never stored on NPCs). Resolve it from anywhere:

UQuestwrightQuestComponent* Comp = UQuestwrightQuestComponent::Get(SomeActor);
UQuestwrightQuestComponent* Local = UQuestwrightQuestComponent::GetLocalPlayer(World);

Crediting objectives

When something quest-relevant happens, such as a kill or a pickup, make one call (BlueprintCallable, server-authoritative, idempotent per EventSourceId):

Comp->ReportObjectiveEvent(Instigator, Type, MatchTags, LocationTags, EventSourceId);

Every active objective whose type and (hierarchically matched) target/location tags fit the event increments. Pass the killer as Instigator and only that player is credited; pass none and all players are (shared-world fallback). For story beats, a trigger or dialogue can instead call:

Comp->CompleteObjective(QuestId, ObjectiveId);

UI out of the box

Add UQuestwrightQuestHUDComponent to your PlayerController and you get the on-screen objective tracker, the quest journal (bind a key to ToggleJournal) and quest-state toasts.

The quest journal open in game, with the tracker and a state toast visible

All widgets are C++-built and replaceable with your own subclasses, or you can skip them entirely and drive a custom UI from the delegates below.

Provider seams

Instead of shipping its own inventory or stats, Questwright talks to yours through interfaces with working defaults:

SeamInterfaceImplementable in
Inventory (item conditions, item rewards)IQuestwrightInventoryProviderBlueprint or C++
Stats / attributes (attribute conditions)IQuestwrightStatProviderBlueprint or C++
Saving backendIQuestwrightSaveProviderC++
Voice synthesisIQuestwrightVoiceProviderC++ (editor)
Facial receiver, smart objectsprovider interfacesC++

Quest state as GameplayTags

Call SetTagTargetActor(Pawn) and the component projects Questwright.Quest.State.* tags onto an AbilitySystemComponent, so quest state becomes usable in ability activation requirements and any tag-based condition system you already have.

Delegates

For custom UI or game reactions:

  • OnQuestStateChanged: accepted / completed / declined / failed;
  • OnObjectivesChanged: a counter moved or an objective completed;
  • OnJournalDirty: anything the journal displays changed;
  • OnProgressLoaded: stored progress was applied (see Saving & multiplayer).

Dynamic text tokens

{PlayerName} and custom {Token} placeholders in dialogue and journal text are substituted at display time by a GameInstance subsystem:

UQuestwrightTextVarsSubsystem* Vars = GameInstance->GetSubsystem<UQuestwrightTextVarsSubsystem>();
Vars->SetPlayerName(TEXT("Ellie"));
Vars->SetTextVar(TEXT("Faction"), TEXT("Rangers"));   // used as {Faction}

Both setters are BlueprintCallable. Substitution uses FText::Format, so it is localization-safe.

Dialogue → quest bridge

Dialogue scenes mutate quest state through their on_end effects (quest: accept / turnin / decline / fail, set: flags, grant_tag, grant_quest), so you don’t write glue code between conversations and quests. See Objectives & progression.