Skip to content

Add portable game saves and resume lobbies - #601

Merged
saffronjam merged 2 commits into
mainfrom
feat/212-game-save-json
Oct 10, 2026
Merged

saffronjam merged 2 commits into
mainfrom
feat/212-game-save-json

Conversation

@saffronjam

@saffronjam saffronjam commented Oct 10, 2026 •

Copy link
Copy Markdown
Collaborator

Hosts can export an in-progress game as JSON and load it into a paused resume lobby. Players reclaim their saved seats through an invite, game code, or Browse; the host resumes once everyone is ready.

  • Add a versioned save document containing game state, logs, and replay history, with strict validation and runtime restoration. Export is host-only because saves contain hidden cards. Bot credentials are excluded.
  • Add file and pasted-JSON loading with size and filename limits, concise errors, responsive transitions, and full-screen mobile forms. Resume lobbies show a static roster, owner, and readiness; competing claims show “Seat already taken.”
  • Cover round trips, pending selections, continued gameplay, malformed saves, HTTP/WebSocket contracts, concurrent claims, reconnects, and desktop/mobile flows. This supplies the serialization foundation; database persistence and automatic recovery after server restart remain outside this change.

Validation: just prepare-for-commit, frontend production build, the full backend race suite and production-wiring export/import/resume tests, and save/load plus resume-lobby Playwright suites passed (10 desktop and 20 mobile tests, with layout-specific skips). Desktop and iPhone/Android landscape screenshots were inspected; mobile tests use Chromium device emulation.

Closes #212

- Add host-only JSON export, validated import, and safe errors
- Restore gameplay, pending actions, history, and logs
- Add responsive load and resume screens with seat claiming and bot reconnection
- Adapt saves to production wiring and WebSocket identity APIs
- Restore snapshot-based score enrichment
- Test production export/import/resume, seat collisions and reconnects
@saffronjam
saffronjam merged commit ec305b5 into main Oct 10, 2026
9 checks passed
@saffronjam
saffronjam deleted the feat/212-game-save-json branch October 10, 2026 20:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Save and load game with json

1 participant