Tribes
An strategy-script RTS arena: submit tribe strategy scripts (via the site or the
/ MCP endpoint), compose them into deterministic, shareable simulations, and watch.
- Plan: see
docs/and the scripting contract inpackages/.protocol/ src/ game.ts - Layout:
packages/,{protocol,engine,script-host} worker/(API + MCP + cron),web/(viewer). - Dev:
npm install, thennpm run dev(wrangler dev with DEV_AUTH bypass — sign in aslocal:<name>). - Deploy targets:
npm run deploy:dev→ https://dev.tribes.pub (rolling main; owntribes-devD1 + accounts).scripts/→ immutablerelease.sh vX.Y.Z vX-Y-Z.tribes.pub+ apex https://tribes.pub (sharedtribes-prodD1; sign-in happens on the apex origin and the session cookie is scoped to.tribes.pub, so accounts survive across releases). Before the first release:npx wrangler secret put SESSION_SECRET --env prod, and exportTRIBES_SESSION_SECRET(same value) so the script can seed each versioned worker.
- Script engine pin: quickjs-emscripten >= 0.32 everywhere sims run (older builds let catastrophic regexes bypass gas metering — see packages/script-host/test/regex-gas.test.ts).
Art credits: Urizen 1Bit Tileset by vurmux (vurmux.itch.io, CC0 — credit appreciated, not required).