Teaching · Interactive resource

Making games in Twine

A playable tutorial and a visual guide to Twine and its SugarCube story format, built around the games my Interactivity students play before they make their own.

Playable tutorial

How to Use SugarCube

A Twine game that teaches SugarCube by being one. Twelve short sections cover links, variables, styling, images and packaging, then debugging, accessibility, a complete mini-project, saves and replay, with a quick reference.

Import the file into Twine to see the code behind every passage.

Companion guide

Visual techniques from the course games

How each game styles itself, with live demonstrations and CSS you can adapt for your own story.

Before you start

Setting up Twine

Twine is free and runs in a web browser or as an app. These five steps get you ready to work through the tutorial.

  1. Get Twine

    Use Twine in your browser with nothing to install, or download the app for Windows, macOS or Linux. The app is safer for a project you will work on over several weeks.

  2. Keep your work safe

    Browser Twine saves stories inside the browser, so clearing its storage or using a shared computer can lose your work. Do not use browser Twine in Safari on a Mac. Whichever version you use, choose Library, then Archive, at the end of each session and keep the file somewhere backed up.

  3. Import the tutorial

    Download the .twee file, then in the story library choose Library, then Import, and pick the file. Open the story and double-click any passage to see how it was made.

  4. Switch your story to SugarCube

    New stories may start in a different story format. In your story, choose Story, then Details, and pick SugarCube. Everything in the tutorial is SugarCube code.

  5. Find the stylesheet

    The CSS in the tutorial and the guide goes in Story, then Stylesheet, not in a passage.

How-to guides

The best places to look things up

The games

Play these first

These games provide the visual and mechanical examples. The tutorial also includes SugarCube features you can use in your own work.