All-or-nothing Publish: your server loads new content beside the live world, checks it, and switches over in one step — or changes nothing.
Flip Publishing
Normally Publish copies your content into the live game table by table, while players are on. If a publish stops part-way — the connection drops, the server restarts, a row is refused — the live world can end up running a mix of old and new content until you publish again.
Flip publishing removes that in-between state. Your game server loads the new content beside the live world first, checks it, and only then switches everything over in a single step. Until that switch, players keep playing exactly the content they had. If anything goes wrong before it, nothing live changes.
Where to turn it on#
Flip publishing is an environment setting on the editor (your Studio Web deployment, or the .env of your local / desktop editor):
PUBLISH_MODE=flipLeave it unset (the default) to publish the way you always have. There is nothing to change in the Publish panel — the same Publish button and the same step list are used.
How a flip publish runs#
- Click Publish. The version opens and your content is preflighted and snapshotted, as usual.
- Optimize media → Media manifest → Game definitions: the changed rows travel to the game server, which stages them. The live world does not see them yet. (New media files do upload straight away — nothing live uses them until the flip.)
- Maps & rendering begins with the flip: the server checks every staged row, writes all of them in one step, and rebuilds the parts of the world they feed. The step line reads Flipped live (N written, M removed).
- Maps & rendering, Terrain chunks, Apply on live server, Stamp live version then finish as before.
If the publish stops at step 2 or 3, the version is marked failed, the staged rows are thrown away and the live world is unchanged. Fix the problem and publish again.
Rolling back to an earlier version uses exactly the same flip: the editor restores that version's content and publishes it, so the rollback also lands in one step.
Settings#
| Setting | Where | Default | What it does |
|---|---|---|---|
PUBLISH_MODE | Editor environment | unset | flip turns on flip publishing. Any other value (or unset) keeps the direct publish. |
PUBLISH_STAGE_MAX_BYTES | Game server environment (self-hosted) | 192 MB | Largest set of changes the server will hold while staging. A bigger publish is refused before anything live changes. |
PUBLISH_STAGE_LEASE_MS | Game server environment (self-hosted) | 15 minutes | How long a staged publish may sit idle before the server drops it and frees the lease. |
Gotchas#
- One publish at a time. While a publish is staging, a second one to the same server is refused with "Another publish is staging on this server". If the first one failed or was closed, the editor clears its lease automatically; otherwise wait for it to finish, or for its 15-minute lease to lapse.
- "too large to stage on this server" — your changes are bigger than the server's staging limit. Nothing was changed. Raise the limit on a server you host yourself if it has the memory, or publish once without
PUBLISH_MODE=flip. - "No staged publish … is open on this server" — the game server restarted (or the lease lapsed) mid-publish, so the staged rows were lost. Nothing was changed; publish again.
- "This game server does not support flip publishing" — the server is older than your editor. Update the server (roll it to the latest version), or unset
PUBLISH_MODE. - A row the checks refuse stops the flip with its table, id and column in the message (for example an invalid loot table). Fix it in its editor and publish again — the live world was not touched.
- What still writes directly: map-object and tileset definitions and terrain chunks are written after the flip, in the Maps & Terrain steps, because they belong to maps the flip may have just created.
- Shared database setups (an editor and server that use the same database) have nothing to stage — the editor's own saves are already the live rows — so a flip there changes nothing.
- This is an editor environment setting, not a World → Features toggle — see the Feature Flags page.