Skip to main content

Creating Dialogue Entries

Typewriter requires setup in two places: the Typewriter Editor and the scene. This guide covers the Editor side: creating the actors, facts, events, and rules that make up your dialogue content. For the scene setup, see Setting Up Dialogue in a Scenario.

1
Create an Actor entry

Every character who speaks or receives messages must have an Actor entry.

  1. Open the editor from Tools > Typewriter > Editor.
  2. Select your table in the Table Panel.
  3. Click the + button in the Entry Panel and select Actor.
  4. Fill in the fields in the Inspector:
Actor Entry
Field
Description
Name
The display name shown in the UI header of each message.
Profile Picture
The avatar used in chat and notification bubbles.

Actor entry selected in the editor, right panel showing the Name and Profile Picture fields filled in

tip

Create one Actor entry per character. The same entry is reused across all of their lines.

2
Create an Event entry

Events are the triggers that start dialogue. Create one for each moment in your scenario that should launch a message.

  1. Click the + button in the Entry Panel and select Event.
  2. Give it a descriptive name (for example, Event_EgoEntersCrosswalk).

No other configuration is needed. Events are named signals with no content of their own.

Event entry created in the sidebar, showing a named event with no extra fields in the right panel

3
(Optional) Create Fact entries

Skip this step if your message should always play when the event fires. Create a Fact only if you need a condition, for example, to prevent a greeting from playing more than once.

  1. If your table has no scope yet, click the + button and select Scopes > Global or Scopes > Scene Scope to create one.
  2. Click the + button in the Entry Panel and select Fact.
  3. Name it (for example, Fact_HasGreetedPlayer).
  4. In the Inspector, set its Scope to a GlobalScopeEntry or SceneScopeEntry from the database.

Facts have no default value field. Every fact starts at 0 (off) and changes only when a rule's Modifications update it.

Fact entry inspector showing the Scope field

4
Create a Rule entry

A Rule wraps a message and defines when it fires.

  1. Click the + button in the Entry Panel and choose the message type: Dialogue, Chat Message, Notification, or Instruction.
  2. Set Triggered by to the Event entry that should activate this rule. You can also pick another rule; this rule then plays right after that rule finishes.
  3. On the Criteria tab, add the Facts that must match (using =, ≥, ≤, or a [...] range). Leave it empty if the rule should always fire.
  4. On the Modifications tab, add the Facts to update after the rule fires. A modification can set a fact (=) or change it with +, -, *, /, or %.
  5. (Optional) Use the OnApply and OnInvoke tabs to fire other Event entries after the rule is processed or when it is invoked.
  6. Enable Once if this rule should fire only a single time (for example, a one-shot greeting). Under the hood, every rule stores the number of times it has fired as a fact; Once is shorthand for "only if that count is zero."
caution

A rule only records how many times it has fired when its own Scope field is set. If you leave the rule's Scope empty, Once has no effect.

note

A new rule is automatically Triggered by the rule above it in the list. Remove that reference if you don't want the new rule chained to the previous one.

Sequential dialogue

When an event fires, only the first matching rule is selected. Rules with more Criteria (plus Padding) are tested first. To play lines in order across separate triggers, stack multiple rules under the same event and enable Once on each. The first trigger picks rule 1 and marks it as used, the next trigger skips rule 1 and picks rule 2, and so on. Rules with the same number of criteria are not guaranteed to be tested in list order, so give earlier lines a higher Padding value to control the order.

Rule entry inspector showing the Triggered by, Criteria, and Modifications sections with example values filled in

Then fill in the message content. Most message types have a Speaker field (the Actor delivering the line) and a Listeners field (the Actors who receive it).

Select the tab matching your message type:

TODO: Screenshot - in-game dialogue bubble UI showing a character's name, avatar, and speech text

Dialogue Entry
Field
Description
Text
The spoken line of dialogue.
Dialogue Type
Speaking Dialogue (the character speaks aloud) or Internal Thought (thought bubble style).
Speaker
The Actor who says this line.
Audio
(Optional) A sound clip to play with the line. Enable the checkbox to activate it.
Auto Play
(Optional) If enabled, the sequencer waits this many seconds before moving on to the rules triggered by this line.
Lifetime
(Optional) If enabled, the message is removed from the UI after this duration.
note

If neither Auto Play nor Lifetime is enabled, the sequencer moves on to the next rule in the chain right away. If only Lifetime is enabled, it moves on when the lifetime ends.