Skip to content

Requirement Sets page

A requirement set is a named list of requirements that several schemes share. You write it once, and every scheme that uses it stays in step. This page is where you make, edit, test and delete sets.

  • Two schemes need the same rule, such as “the conspirator is of age and has gold”.
  • You wrote requirements inside a scheme and want to reuse them.
  • You want to know which schemes and nodes use a set before you change it.

The Requirement Sets page is a table on the left, with the Element Inspector beside it. Select a row and the inspector shows that set.

  1. The header. The title Requirement Sets and a count. The count reads 2 of 5 while a search hides some rows.
  2. The search box. Its hover text is Find requirement sets by name.
  3. The ⋮ menu. Hover text More actions. It holds Duplicate Selected and Delete Selected….
  4. New. Hover text New requirement set.
  5. The table. Four columns, each sortable: Name, Requirements (how many), Reads As (the names of the requirements, such as (unnamed), or a set name and is met, a missing set, or always met for an empty set) and Used By (the places that use the set, or not used).
  6. The Element Inspector, with a set selected: Name, Description, the Requirements section, Try it and Used By. With nothing selected it shows an overview: how many sets there are, and how many have problems.

With no set yet, the table shows No requirement sets yet, the line Create the first requirement set with New. and the button New Requirement Set.

Click New. A set called New Requirement Set appears, selected, with the focus in its name field. Type a name and press Return.

Name it for what it means, such as Noble plots: schemes and condition rows show the name.

To undo, choose Undo in Unity’s Edit menu, or delete the set.

Select the set. In the Requirements section, click Add requirement and pick a condition from the menu. The requirement is made with that condition and named after it.

The selected requirement shows a card:

  • Name: what the requirement says in the set.
  • Reason: the text shown when it is not met. Left empty, the requirement’s name is shown. Tokens such as {target.Name} work.
  • Conditions: a list of conditions. With none, the requirement is always met. + Add condition adds one. See Who? and condition lists.

The list shows one row for each requirement, with its number. The selected row has buttons to move it up or down (Move up, Move down) and Remove this requirement. Below the list, Reads as says the whole set in words.

A set keeps no timing. The entry that uses it in a scheme has its own.

To undo, use Undo in Unity’s Edit menu. Every edit is one step.

Open the Try it section of a set. Pick an actor in For (who the set is checked for, the conspirator of a scheme) and one in Against (the other actor, the target of a scheme). The panel shows which requirements of the set are met for them.

It reads every actor of the database, while the game has only the actors in the scene. In Play mode the panel says it works in Edit mode only.

Open the scheme and select nothing on the canvas, so the Element Inspector shows the scheme’s own settings. In its Requirements section, click Use a set… and pick the set. The scheme gets one entry. Its row reads Uses:, the set’s name and (2 requirements), and its card has a Set row to pick another set.

The entry has its own Counts, If not met and If it breaks rows, like any requirement of the scheme. See Scheme settings.

To undo, remove the entry with its Remove this requirement and its output button.

Select an entry that uses a set and click Copy into this scheme. The entry is replaced by editable copies of the set’s requirements, so each can count differently, and the set stays as it is. Links on When a Requirement Breaks may go with it: the Studio asks first.

To undo, use Undo in Unity’s Edit menu.

Open the scheme’s Requirements section. There are two ways:

  • Click the save button in the section’s header. It makes a set of all the requirements below. To save only some, pick them first: Cmd or Ctrl and click a requirement, or Shift and click to pick a range.
  • Select a requirement and open its More menu. Choose Save as a Requirement Set….

A small window titled Save as a Requirement Set · name of the set asks for the name, with a suggestion: the name of the single requirement, or the scheme’s title and requirements. Press Return or OK. If the name is taken, the Studio adds a number: Noble plots 2.

The saved requirements leave the scheme and are replaced by one entry that uses the new set. The set’s Description reads Saved from the requirements of and the scheme’s name. The entry that uses the new set counts the way the saved requirements did. A set has one timing for all its requirements, so when your picks count differently the Studio asks which timing to use: Use: and the first, Use: and the last, or Keep them as separate entries, which saves nothing. When links on When a Requirement Breaks would be lost, it asks first, with Save and remove the links or Cancel.

An entry that already uses a set is left out, and the Studio says so.

The whole command is one undo step. To undo, use Undo in Unity’s Edit menu.

Edit Name in the inspector. A rename keeps every scheme, row and node that uses the set working. A name that is empty, or already used by another set, is refused.

Right-click the row and choose Duplicate, or select it and choose Duplicate Selected in the ⋮ menu. The copy is called the original’s name and Copy, and comes after it in the list.

Right-click the row and choose Delete…, press Delete or Cmd or Ctrl plus Backspace, or choose Delete Selected…. A question asks you to confirm. When the set is used, it names the places and says what happens next.

Schemes that use it show Missing requirement set and count it as never met. Rows and nodes that name it show the same until you pick another set. The question ends You can undo this with Edit > Undo.

The Used By section of the inspector lists each place and the number of nodes. Go there opens it. A set no one uses shows Nothing refers to this requirement set yet.

You come from Test run: play a scheme in the Studio. A test run checks a scheme’s requirements when it starts, and Start anyway skips them. The next lesson is the Variables page, the first of the part on the world.

Three things ask a set whether it is met:

  • The condition row Meets, in any condition list.
  • The node Check Requirements, which continues with Met or Not Met.
  • Your code, with IM.Meets.

Schemes use a set with Use a set…. The node When a Requirement Breaks reacts when a requirement a scheme counts while it runs stops being met.

This page has no setting.

A scheme says Missing requirement set. The set was deleted. Open the scheme, select the entry and pick another set, or remove it.

I changed a set and a scheme behaves differently. That is how a set works: every scheme that uses it follows. Check Used By before you change one.

The save button is grey. It is off in Play mode, and when the scheme has no requirement yet.

Message Where it shows What to do
Type a name. A notice, after you clear Name Type a name.
Another requirement set is already called “…”. A notice, after you type a used name Choose another name.
The requirement set has no name. Message box in the inspector Type a name.
Another requirement set is also called “…”. Message box in the inspector Rename one of them.
“…” uses a requirement set that is missing, so it is never met. Message box in the inspector Pick another set or remove the entry.
A requirement set can only be saved in Edit mode. Dialog of Save as a Requirement Set Stop Play mode.
This scheme has no requirements yet. The same dialog Add a requirement first.
It includes itself, so it is never met where it reaches itself. Message box in the inspector Remove the entry that leads back to this set.
There is nothing else to save. Dialog of Save as a Requirement Set Every picked entry already uses a set. Pick others.
The requirements changed. Try again. The same dialog The list changed while you typed the name. Start again.
…cannot go into a requirement set. and the reason The same dialog Read the reason. Keep that requirement in the scheme.