Modding Uptime
This folder holds the guides for people who make mods. A mod is a folder with a manifest.json. It is either a content pack, which adds hardware, scenarios, customers or services, or a script mod, which runs code against a running world. A mod can be both.
Start here
| Guide | Read it to |
|---|---|
| Quickstart | Make, check, run and package a first mod, and preview its upload. |
| The uptime-mod command | Use new, validate, package, run and upload, and read their exit codes. |
| Content packs | Write a manifest, add hardware or scenarios, and learn what makes the game refuse a pack. |
| Equipment models | Give a new host or switch its own 3D model: the three files, the conventions, every limit and the .pips.json fields. |
| Script mods | Learn what Lua and Rust mods share: declared reads, the 15 second quantum, commands and receipts, limits, faults, and what a modded run costs the player. |
| Lua mods | Write a mod in Lua: the entry table, require, the sandbox, determinism and hot reload. |
| Rust mods | Write a mod in Rust: the SDK, building to bin/mod.wasm, and determinism. |
| Other languages | Make a component in TinyGo, JavaScript or any language with no SDK: the WIT world, the msgpack encoding, the limits and the state contract. |
| Panels | Draw screens in the game: panel files, widgets, data timing, player input, text rules, the HUD card and keys. |
| Toasts | Raise a short notice every player sees: the call, the tones and the caps. |
| Config | Offer settings with a config schema, and set them on a dedicated server. |
| Workshop | Upload a mod, choose who sees it, push updates, and learn what players and dedicated server operators do with it. |
| Multiplayer | Learn which packs other players must install to join a world with your mod, and how panels behave with several players. |
| Reference | Find the generated schemas and ledgers, and learn how API versions work. |
Examples
The game’s ModSDK/examples folder carries ten working mods (in the repository they are in mods/examples/):
com.uptime.example-hardwareadds host and switch SKUs and overrides one built-in SKU.com.uptime.example-modeladds a switch SKU with its own 3D model. The model files are game art, not MIT, seeTERMS.md.com.uptime.example-scenarioadds a scenario and depends on the hardware pack.com.uptime.example-customersadds two customer archetypes and changes one built-in archetype.com.uptime.example-serviceadds aCold Storageoffering over object storage and a customer archetype that buys it.com.uptime.example-eventsadds two macro events and their English text.com.uptime.example-localecarries text in English and German.com.uptime.example-autoscaleris a Rust script mod.com.uptime.example-autoscaler-luais the same policy as a Lua script mod.com.uptime.example-alertsis a Lua script mod with a HUD card, a toast and two keys. It issues no command.
Which API version this reads
These guides describe API generation v1alpha1, minor 1. Set api_minor in your manifest to the minor of the SDK you built against. Reference explains the rule.