Skip to content

Twine Nodes

Graham Earley edited this page Feb 7, 2017 · 3 revisions
  • TODO Write and link to article on adding Associated Twine Nodes component.
  • TODO Images for decision nodes.

Once Twine is imported into Unity, a Twine graph is stored as an asset named after your Twine story (so if your story was named "Life at the Workhouse", the asset will be named "Life at the Workhouse - Twine" in Unity).

This asset will go into the Assets folder by default (for more information on where this asset could go, read about importing Twine data into Unity. The story object is made up of several objects known as Twine Nodes, which each correspond to a node, or event, in your Twine story.

Twine Node Import Location

Note: Each node holds important data relevant to the Twine story, and shouldn't be edited by hand!

We'll use the story object and its nodes to connect the story we made in Twine to the Unity game.

What does a Twine Node do within the game?

All of the Twine Nodes will sit (invisibly) in your story, with one node activated at any time. The activated node represents the part of the story that the player is currently in. As you progress through the story, a node that follows the currently activated node will become active (and the previous node will de-activate), and so on.

How do Twine Nodes activate and de-activate?

There are two ways to activate a successor Twine Node and thus progress your story:

  1. Trigger the next step in a story through an interaction with an object in the world.
  2. Trigger the next step in a story through a decision that the player makes.

In either case, you must add an Associated Twine Nodes component to your object (see tutorial here) TODO: WRITE AND LINK TUTORIAL) to associate one or more Twine Nodes with a component.

To trigger a Twine progression through an interaction, simply attach an interaction to a component with some Associated Twine Nodes. When the interaction is triggered, the associated Twine node that is a child of the currently activated Twine node will activate (if such a Twine node is associated with the object).

To trigger a Twine progression through an internal decision that the player makes, go to the Twine node where this decision will take place and designate it as a "decision node" by checking the "Decision node" checkbox. TODO: Images for this process!