Debug Tools
While you’re playing your own draft, a Debug button appears in the bottom-right of the page. It opens a panel with four tabs that let you change anything about your character on the fly: variables, NPCs, factions, the Character dropdown, and which scene you’re on. There’s also a one-click button to undo your last choice.
Debug tools are only visible to the story’s team (creators, writers, and readers), and only while playing a draft. They never appear on a published version, so public readers won’t see them.
The Undo button
An Undo button sits next to the Debug button. One click rolls back your most recent choice. Your variables, NPC and faction sentiments, selected Character, and current scene all snap back to where they were just before that choice. Hit it again to go further back.
If you want to undo more than one at a time, open the terminal and type undo 3 (or any number).
Variables tab
This is the visual editor. Each section is a list of every relevant thing on your character:
- Player variables, with the current value next to a small input. Change the number, type a new string, or flip the toggle.
- NPCs, each with a sentiment number and a discovered toggle.
- Factions, same as NPCs.
- Character, a dropdown to switch which character you’re using.
Use the search box at the top to filter the list. The Reset all button puts every player variable back to its starting value. Each row also has its own reset button (the circular arrow) if you only want to revert one.
Terminal tab
If you’d rather type than click, the terminal lets you do almost everything in one line. There are two flavors of commands.
Direct commands
| Command | What it does |
|---|---|
goto "Scene Title" | Jumps to a scene by title. State stays where it is. |
goto chapter:2 "Scene Title" | Same, but disambiguates if two scenes share a title. |
goto home | Returns to the scene you were on before you started peeking. |
choose 1 | Picks the first choice in the current scene, the same as clicking it. |
choose "Take the rope" | Picks a choice by its display text. |
choose 2 "Alex" | For input choices, supplies the value you’d normally type in. |
undo | Rolls back your last choice. |
undo 3 | Rolls back the last 3 choices. back works as an alias. |
list vars | Prints every variable and its value. |
list npc:Mara | Prints info about one NPC. (Same shape for faction:.) |
list scene / list persona / list history | Prints what each tab would show. |
list scripts | Lists every saved script for this story. |
run setup-chapter-2 | Runs a saved script (see Scripts tab). |
script save <name> | Saves the recent terminal commands as a named script. |
script delete <name> | Deletes a saved script. |
help or ? | Prints the full command list. help goto shows help for one command. |
clear | Clears the terminal scrollback. |
Setting state
Anything that isn’t a direct command is treated as a state change. The syntax matches the Code Editor, so if you already know how to write effects there, the terminal will feel familiar.
Health = 50 // set a value
Gold += 10 // also -=, *=, /=
hasMansionKey = true // booleans
PlayerName = "Alice" // strings
npc:Mara += 5 // adjust an NPC's sentiment
npc:Mara discover // mark an NPC as discovered
faction:Guild = -10 // set a faction's sentiment
faction:Guild discover // mark a faction as discovered
persona:Rogue // switch to a character Conditions and probabilities are intentionally ignored here. A line like 30%: Gold += 10 always fires when you run it in the terminal. The terminal is for staging an exact test scenario; if you want randomness, run the actual choice in your story.
Autocomplete
Start typing and the terminal will suggest something useful: command verbs at the start of a line, scene titles after goto, the current scene’s choices after choose, your saved script names after run, NPC names after npc:, and so on. Up and down arrows recall what you’ve typed before, even after a page reload.
goto vs choose
Both move you to a new scene, but they’re different on purpose.
gotois for jumping. Variables, NPCs, factions, history - none of it changes. Use this to re-read a scene or skip ahead for QA.chooseis for playing. It runs the same path as clicking the choice would: effects fire, the choice gets added to your history, triggers run, the works. Use this in a script to fast-forward through a real playthrough, set up some state, thenchooseyour way through the chapter so the history reflects the path you’d actually take.
Scripts tab
A script is a saved sequence of terminal commands. They live on the story, so anyone on your team can use them. A common pattern is one script per test scenario.
// Setup: chapter 2 stealth route, well-equipped rogue
gold = 200
hasMansionKey = true
stealth = 8
persona:Rogue
faction:Guild = 25
goto "Mansion Entrance" To fast-forward through a real playthrough so history accumulates, use choose instead of goto:
// Walk through chapter 1 quickly so the chapter 2 setup is realistic
choose 1 // "Wake up"
choose "Talk to the innkeeper" // by display text
choose 2 "Alex" // input choice — supplies the typed value
choose 1 The script editor walks your script line by line as you type. After a goto or a choose that routes to a new scene, the autocomplete and the red squigglies follow you there: the next choose shows the destination scene’s choice list, not the one you started in. If a line uses a branch, dynamic, or back choice (or undo), the walker can’t predict where you end up, so it quietly stops checking the choose lines below, no false errors. Your runtime still catches anything that’s actually wrong when the script runs.
- + New script opens an editor with the same syntax as the terminal.
- Run executes the lines top to bottom. Each line’s result appears below the list. If a line fails, the script stops there.
- You can also Edit and Delete your scripts.
An alternative to writing in the script modal is to first clear, then write all your steps one by one in the terminal, then type script save <name>. This will create a script with all of your commands.
History tab
A list of every choice you’ve made on this character, most recent first. Each entry shows the scene the choice was made in, the chapter, the choice that fired, and any variables, NPCs, or factions that changed (with the before and after values).
Two buttons on every row:
- Go to sends the character to that scene without touching anything else. Variables, NPCs, factions, and selected Character stay where they are now, and history is preserved. Use this when you want to re-read a scene’s text or jump around for QA. Just type
goto homeor press the button to go back to where you were before. - Rewind properly undoes the character back to that point. State restores to the moment that scene was entered, and the trailing entries are dropped from history. It’s the same as
undo Nin the terminal where N is the row’s position.