Skip to reading
The Dialogue Designer

51. Add a new topic while the game is running

Edition 0.86.3.4

Build branching conversations with choices, conditions, actions, timed responses, voices, portraits and custom windows.

Download PDFView illustrations

Dialogue-editing actions can add a clue topic after a discovery. Add the answer first, then add the response that points to it. Both IDs must be new in the intended scope.

Code example
await AddDialogueLine({
    "dialogueId":"archive_chat",
    "nodeId":"lantern_reply",
    "speakerId":"elias",
    "text":"The lantern is by the workshop door.",
    "returnToPrevious":true
})
await AddDialogueChoice({
    "dialogueId":"archive_chat", "nodeId":"topics",
    "choiceId":"ask_lantern",
    "text":"Where is the lantern?",
    "next":"lantern_reply"
})

Figure 37. The new lantern question appears in the running conversation.

The same actions are available visually. Add Dialogue Choice Node creates a menu node; it does not automatically invent its options or connect that menu into the conversation.

These changes affect the running game’s project data. They do not silently rewrite your authored editor file. Save/load can preserve the runtime changes, so test both a fresh game and a loaded save.

Page 55 of 77Permalink
Go to page