Imported from stxtrata/xtrata (
xtrata-1.0/recursive-apps/21-arcade/game02_neon_runner-v2/AGENTS.md). Install upstream withnpx skills add stxtrata/xtrata --skill game02_neon_runner-v2. Copyright stays with the author.
AGENTS - game02_neon_runner-v2 Workspace
This file governs updates inside recursive-apps/21-arcade/game02_neon_runner-v2/.
Core Rules
- Preserve launcher contract invariants:
- Global symbol remains
Game02. idremainsneon_runner.scoreModemust stay aligned with live slot behavior unless explicitly changed.
- Global symbol remains
- Treat
recursive-apps/21-arcade/games/game02_neon_runner-v2.jsas generated output only. - Make source changes in
src/; keeptests/deterministic and dependency-light.
Workspace Structure
src/: modular source (systems, state, entities, rendering, balancing data).tests/: deterministic tests for game logic and regressions.scripts/: build/test tooling for workspace output.README.md: implementation notes and promotion flow.
Game-Type Strategy Review (Required)
- Keep
GAME_STRATEGY.jsonupdated for this workspace archetype, scaling priorities, and test focus. - Before promoting a version, run strict review:
npm run arcade:strategy:review -- --game game02_neon_runner --strict
- If game archetype or core loop changes, update
GAME_STRATEGY.json, thisAGENTS.md, andREADME.mdbefore promotion.
Build and Test Workflow
- Implement or update modules in
src/. - Run this workspace build command (add in root
package.jsonif missing):npm run arcade:neon_runner:v2:build
- Run this workspace test command (add in root
package.jsonif missing):npm run arcade:neon_runner:v2:test
- Validate generated JS:
node --check recursive-apps/21-arcade/games/game02_neon_runner-v2.js
Promotion to Runtime games/
- Confirm workspace build and tests pass.
- Ensure output exists at
recursive-apps/21-arcade/games/game02_neon_runner-v2.js. - Regenerate manifest:
npm run arcade:games:manifest
- Launch arcade and verify slot
02resolves to latest file. - Run quick sanity pass:
- launch -> play -> game over -> score submit prompt -> restart -> exit.
New Version Iteration (Default v2.x)
- Keep minor decimal progression by default:
v2 -> v2.1 -> v2.2 -> v2.3. - Get suggested next target:
npm run arcade:next-version -- --game game02_neon_runner
- Explicit major jump only when requested:
npm run arcade:next-version -- --game game02_neon_runner --version 3
- Copy this workspace to the chosen version folder and update runtime output path to match.
- Add tests for every new module/mechanic before promotion.
- Keep global symbol, game id, and launcher API shape backward-compatible.
Test Suite Maintenance Rules
- Every new module/function must include matching tests.
- Keep tests deterministic (seed randomness, fixed clocks, controlled inputs).
- Add regression tests for score calculation, round flow, pause/resume, and cleanup.
- If UI hooks change, add a smoke test for launcher lifecycle compatibility.
- Do not promote new versions without updated tests.