Write the computer your story needs. Print a recovered transmission, ask the operator for a decision, or connect clues across several machines with saved world state.
Programs are asynchronous JavaScript files that run inside Computers & Terminals for Foundry VTT 14.367, with support for 13.351. The module supplies five objects directly to your script. No imports or constructors are needed.
| Object | What it gives you |
|---|---|
| terminal | Shared text, typewriter output, pauses, and player prompts. |
| program | Arguments, computer and file documents, controller, and cancellation signal. |
| audio | Shared key, output, success, and lockout cues. |
| save | Durable JSON state on one computer or across the world. |
| load | Synchronous reads of that saved state. |
Create a Program in Configuration → Files & Menu → New Program and paste:
await terminal.typeLine("ESTABLISHING UPLINK...", { delay: 35 });
const operator = await terminal.input("Operator name:");
terminal.writeLine(`Welcome, ${operator || "anonymous"}.`);
audio.cue("success");
Save, then select it in VANTAGE or execute its path in FERRO. An online GM is required. The player controls its prompts and everyone with the computer open sees the output.
Start writing · Understand the context · Browse complete examples
Every Program runs once on the designated online GM's client with GM permissions,
even when that GM's computer window is closed. game.user is the GM;
program.controller is the player operating the computer. Foundry's client-local
UI appears on the GM's screen; terminal output and prompts are shared.
Programs are trusted macro-like code. Escape cancels the helpers, but does not undo Foundry actions already performed. See the execution and lifecycle guide before adding document actions or your own timers.
This reference covers executable New Program files. Installed extensions using
registerTerminalProgram have a separate screen/action contract.