Builtin Library
README.md
world_status.module
world.status() + world.status_text() — snapshots of the world's
current state. Pure Luau; composes existing globals.
world.status() → table
{
world = { guid, branch, title },
mode = "edit" | "play",
running = boolean, -- equals (mode == "play")
primary_scene = { asset, name, entrypoint } | nil,
scenes = { { asset, name, additive, parent }, ... },
players = {
local_player = { id, name, identity } | nil,
by_scene = { ["main"] = { ... }, ... },
count = number,
},
}
world.status_text() → string
Pretty-printed multi-line companion. Useful from print(world.status_text())
or from the in-engine bash shell.
World: Scratch World (00000000-…) — branch main
Mode: edit (running=false)
Primary: scenes.dungeon (layer "main", entrypoint scenes.dungeon.entrypoint)
Loaded:
scenes.dungeon (root)
scenes.hud (additive, child of main)
Players: 2 (local: alice@zeromind)
main: alice@zeromind*, bob@zeromind
hud: —
When to use
Run world.status() (or world.status_text()) when:
- An agent boots into an unfamiliar world — first move.
- Diagnosing why a player or camera isn't spawning.
- Verifying that mode-swap flowed (running flag flipped).
- Querying which scenes are layered on the root.
See man getting-started for the full world / scene / players / camera flow.