World plugins Contenido

Plugins

World plugins

Small programs that make your world's own rules happen in play: when to use one, Hob writing them for you, the Plugins tab, the catalog, and who can write them now.

Rules that happen in play

A plugin is a small program your world runs while people play. It listens for moments in play (a character dies, rests, arrives somewhere, meets someone, a new day begins, a player presses a button) and makes your world's own rules happen: it moves a character, takes or gives money, turns the clock, keeps a record, puts a card in front of the player, and tells the storyteller what is now true.

Some of what the plugins in the catalog do:

  • Lamp return. Dying drops the money you carried where you fell. You wake at the last Lamp you rested at, at nightfall, and can walk back to get it.
  • The revel gamble. Leave a fae revel and the dice decide how long you were really gone: a night, a week, a season, or seven years.
  • Let the years pass. A button that lets five, ten or twenty years go by between adventures.
  • World firsts. The first player in the world to beat a named foe gets a title nobody else can ever hold.
  • Evolution path. A monster's next forms sit on its sheet with what each one asks of it; when it has done one and grown enough, the player picks the change.

The rule is the one the whole engine follows: code holds the state and tells the storyteller facts; the storyteller narrates them. A plugin that wakes a dead character at their Lamp moves them there, sets the clock to nightfall and says so to the storyteller. It does not write the waking scene: the storyteller does, and keeps to those facts.

A plugin, a setting, lore or a rule card?

Most of a world needs no plugin. Reach for one when something has to happen in play, done by code, and the tools you already have can't say it.

What you wantUse
How the world feels, its history, who lives whereLore
Death, danger, pacing, money: the switches every world hasWorld rules
"When this happens, then that" on a rule system's sheet: a critical gives Inspiration, poison hurts each turnRule cards
Something that happens in play and needs its own memory, places, clock or buttons: a death that wakes you somewhere else, years lost at a revel, a world-wide record, a secret only the storyteller knowsA plugin

Plugins work in any world, with or without a rule system. Only rule-system effects (tracks, conditions, pools) need one; on Worldtable's own engine a plugin moves money, growth, health, places and the clock, and can call any of the storyteller's tools.

Hob writes them for you

You don't need to write code. Open Hob in the Studio and say what should happen, in plain words. Hob reads the plugin API, starts from the catalog when one fits, writes the plugin and saves it. Every plugin is loaded and checked before it is saved, and a problem comes back to Hob in words. Then Hob tries it on a dry run, on the moments it handles, before telling you it works.

A request
When someone dies they should wake at the last campfire they slept at, and lose the coin they carried where they fell.
Hob adds Lamp return from the catalog and sets its rest places to any place with "Campfire" in its name, then tries a death on your own character: their coin would be left where they fell, they would wake at the campfire at nightfall, whole, and a card would tell them so.

Hob explains a plugin in words ("when you die, you wake at your last campfire") and shows the code only if you ask. It can also switch a plugin on or off, change its settings and its words, move it earlier or later in the run order, read what it did in play, and remove it.

The Plugins tab

In the Studio, Plugins has its own tab. Down the left is the world's list:

  • Each plugin with its on/off switch, its version, a Catalog mark if it came from the catalog (Newer in the catalog when there is an update), and the reason if it was switched off.
  • What it listens to, and the buttons it gives players.
  • Run order: plugins listening to the same moment at the same priority run top to bottom. Move one up or down to run it earlier or later.

Open one and you see:

Name and What it does
In plain words, for you, your builders and Hob.
The code
One JavaScript module, up to 64 KB, in an editor that completes what wt can do when you type wt. and the moments it can listen to inside wt.on.
What it set up
As of its last save: the moments it listens to, its buttons for players, the questions it asks after each scene, and how a death is told in this world if it takes deaths over.
Settings
The choices the plugin offers your world (a tag, a list of names, a number of years), as a form. Lists take one entry per line.
Words players see
Every piece of text the plugin shows players, by key. Change the words without touching the code; language editions translate them.

Three panels open beside it:

Try it
Pick a moment, adjust what it carries, and run the plugin as it stands in the editor (saved or not) on your own character in this world. It is a dry run: what the plugin would do is listed, and nothing is changed.
What it did
Its latest runs in play, newest first: the moment, the character, whether it finished or why it stopped, what it called, its log lines, and the values it keeps.
API reference
Everything wt can do and what each moment carries, with every storyteller's tool and its arguments.

Nothing is saved until you press Save, which puts back the whole list at once. A plugin that doesn't load (a typo, an error as it starts) comes back as a problem under it, and nothing is saved.

Start from the catalog

The catalog holds ready-made plugins, each made for one of the showcase worlds and usable in any. Press Add from the catalog, pick one, then change its settings and its words to fit your world. A copy remembers which catalog plugin it came from; when the catalog's version moves on, the tab offers Take the new version, which replaces the code and keeps your settings and your own words.

The plugin catalog describes each one: what it does in play, its settings, and what to name or tag in your world.

What players see

  • Cards in the story, between the scenes: a title, a few lines, and up to four buttons. A card can take the player to the room they are now in (after a death, to where they woke).
  • Sheet sections on the character sheet: a bounty, a rank, where they fell. A headline section sits at the top.
  • Buttons over the box where they type, under This world's actions: Let the years pass, Leave a message, The tavern board.

The storyteller reads what a plugin tells it as facts stated by the world's rules, and narrates them.

Beta: who can write plugins now

Plugins are in Beta. For now, writing, changing and trying them is open to Worldtable's operators; it opens to every builder later. Until then you can open the Plugins tab and read what your world runs, and Hob can read and explain plugins, but saving one is refused.

A language edition runs its source world's plugins, with their words translated; the Plugins tab is in the source world only. See Limits and safety.

Undo and plugins

Undo doesn't reverse what a plugin did, yet. When a plugin changed something in a turn (it called a storyteller's tool, moved money or a character, turned the clock, or kept a value), undo refuses that turn and says which plugin changed it and how. A change a plugin makes outside a turn (on a new day, a timer coming due, a button) also stops undo of the turns before it.

What the player sees when they try
Can't undo: Lamp return changed this turn (money -40; moved to Feldon; clock to day 6 nightfall).