Tutorial 20 minutes
A screen of your own
Design a HUD with a title and a Quit button, and show it over the whole adventure.
What you'll make
A HUD: a screen that stays on top while the adventure plays. It shows the adventure's name at the top left and a Quit button at the top right. Clicking Quit ends the adventure.

Before you start
- Finish Remember what the player did. This tutorial carries on in the same adventure.
- Have My First Adventure open in the editor.
1. Make a user interface
A user interface is a screen you design yourself, with text, pictures and buttons.
- In the navigator, click the arrow beside Story, then click User interfaces.
- Click + New User Interface. A card called User Interface appears, and the inspector on the right shows it.
- In the inspector, click the name User Interface. Press
Ctrl+A(⌘Aon a Mac), typeHUD, and pressEnter.

The card reads HUD, with 0 modules · 1920 × 1080 under it.
2. Add a title
- Click the HUD card. The 2D editor opens, with an empty canvas in the middle.
- In the bar above the canvas, click T (the Text tool). Click near the top left of the canvas.
- A box reading Type the text appears. Type
My First Adventureand pressEnter. The new text is selected, and the inspector shows its settings. - Click the inspector's Name box, press
Ctrl+A(⌘Aon a Mac), typeTitle, and pressEnter. - Under Layout, give the box its size, then its place. In each box, click, press
Ctrl+A(⌘A), type the number and pressEnter: W900, H80, then X60, Y70.
Clicking a box puts the cursor in it without selecting what's there. Ctrl+A (⌘A) selects it, so what you type
replaces it.
W and H change the box's size around its middle, which moves its corner. Setting them first leaves X and Y where you typed them.
3. Add a Quit button
- Click T again, then click near the top right of the canvas.
- Type
Quitand pressEnter. - In the Name box, select Text with
Ctrl+A(⌘A), typeQuit, and pressEnter. - Under Layout, the same way: W
200, H80, then X1560, Y70.

The Layers list on the left shows Quit and Title, and the canvas shows both near its top edge.
4. Make Quit end the adventure
Any piece of a screen can be a button: give it a trigger, logic that runs when the player does something to it.
With Quit still selected, click Logic at the top of the inspector.
Under Add, click + Trigger, then click On Tap End. A section called On Tap End appears.
Next to Trigger Logic, click ✎. The Trigger Logic window opens.
Click Add. In the Result window, next to Outcomes, click Add.
In the Category column, click Actions. In the Action column, click End Adventure. The top of the window reads Outcome: End the Current Adventure Execute.

Click Save, then Save in the Result window, then Save in the Trigger Logic window.

Under On Tap End, Trigger Logic counts one logic line and shows it: End the Current Adventure Execute.
5. Show the HUD over the whole adventure
A user interface shows only when something puts it on screen. A UI layer shows interfaces over the whole adventure.
- In the navigator, under Story, click UI layers.
- Click Add layer. A layer called Layer appears, with its name selected. Type
Top barand pressEnter. - Under Shows at start, click + Add interface. The Add interfaces to Top bar window opens.
- Click HUD to tick it, then click Add 1 interface.
- In the list on the left, Top bar sits under Events and their interfaces. Drag the ≡ at the left of Top bar up onto Events and their interfaces. Top bar moves to the top of the list.

The higher a layer is in the list, the more it draws on top. A layer under Events and their interfaces hides while a conversation is on screen, and this adventure is all conversation. Above it, the HUD stays on top of every line.
The list reads, top first: Top bar (with HUD under its name), then Events and their interfaces. HUD is under Shows at start.
6. Play it
- At the top right of the editor, click ⟲ Restart. If there's no ⟲ Restart, click ▶ Play.
- On the title screen, click Play. My First Adventure is at the top left, and Quit at the top right, above the harbor's line.
- Click Quit. The adventure ends, and the title screen comes back.
- Click ◀ Editor.
The HUD doesn't show on the title screen: UI layers show only while the adventure plays.
What you learned
- A user interface is a screen you design in the 2D editor. Its pieces, such as text, are modules.
- Layout in the inspector places a module exactly: X and Y from the top left, W and H for its size.
- A trigger on a module makes it a button: On Tap End runs logic when the player clicks it.
- A UI layer shows interfaces over the whole adventure. Above Events and their interfaces, it stays on top of conversations.
Next
- The 2D editor covers every tool, the inspector and the other triggers.
- User interfaces describes the page where you made the HUD.
- UI layers covers layers, and the logic that shows and hides interfaces on them.
- Screens on screens explains what draws over what while the adventure plays.