Skip to content

feat(root): add Scythe web PoC in sandbox/poc/scythe - #5544

Draft
shepherdjerred wants to merge 2 commits into
mainfrom
scythe-game-question
Draft

shepherdjerred wants to merge 2 commits into
mainfrom
scythe-game-question

Conversation

@shepherdjerred

@shepherdjerred shepherdjerred commented Dec 3, 2026 •

Copy link
Copy Markdown
Owner

Why

Preserve the standalone Scythe tabletop web PoC (2-5 players, 3D Europa tabletop, authentic physical player mats, Easy/Medium AI opponents, and external Steam asset preparation scripts) inside sandbox/poc/scythe without storing copyrighted game assets in Git or coupling root monorepo workspaces.

What

  • Add the standalone web PoC under sandbox/poc/scythe:
    • Engine & Rules: Deterministic Scythe state machine (src/engine/), 5 factions, 5 player mats, 28 encounters, 23 objectives, 18 factory cards, 42 combat cards, 6 structure bonuses, auction/overlap/undo, and replay.
    • Easy & Medium AI: Heuristic planners across auctions, movement/carry/encounters, top/bottom row actions, artillery, combat bidding, and star pursuit (src/engine/ai/), games.stepAi optimistic-versioned server endpoint (src/server/), lobby Solo vs AI / per-seat controller UI, and live client playback (Normal / Fast / Pause).
    • UI & 3D Board: Authentic physical player mats with Jakub Rozalski artwork, 14K 4×2 tiled stitched Europa board meshes (board/map_tile_{0..3}_{0..1}.webp), beveled crimson/forest-green/gold cardboard Encounter Tokens (icons/encounter_token.webp), and left-panel track overlays.
    • Asset Pipeline: External Python extractors/upscalers (scripts/prepare-assets.py, scripts/upscale-assets.py) writing prepared assets outside Git into $SCYTHE_ASSETS_DIR (~/.local/share/scythe-assets).
  • Register sandbox/poc/scythe in sandbox/poc/README.md.

Demo

Physical Player Mat + 3D Tabletop (1280×720):

preview-v5-physical-mat.png

14K Stitched Map & Beveled Cardboard Encounter Tokens Close-Up:

preview-v5-map-encounter-closeup.png

Solo vs AI (Medium) Live Playback Controls:

preview-v5-solo-vs-ai.png

Responsive Mobile Viewport (390×844):

preview-v5-mobile.png

Verification

  • Standalone checks (sandbox/poc/scythe, post-Prettier):
    • bun install --no-lockfile, bun run generate (Prisma Client), bun run build (Vite), bun run typecheck (tsc --noEmit): exited 0.
    • bun run test (Vitest): 6 passed (6) test files, 29 passed (29) tests.
    • bun run test:extended (PostgreSQL integration src/server/postgres.integration.test.ts): 1 passed (1) test file, 2 passed (2) tests.
    • bun run lint (eslint . --max-warnings=0): 0 semantic/type/hook lint warnings; 29 max-lines / max-lines-per-function line-count findings caused by Prettier wrapping (sandbox/** is excluded from repo package-quality and CI lint).
  • Repo pre-commit (bunx lefthook run pre-commit): All 9 safety & formatting hooks (large-files, env-var-names, line-endings, lockfile-check, merge-conflicts, check-agent-guidance, gitleaks, check-suppressions, prettier) passed cleanly.
  • Live browser verification (PinchTab, run prior to sandbox/poc/scythe move): Verified desktop (1280×720) & mobile (390×844) views, 14K tiled board, encounter discs, physical mats, and Solo vs AI playback with zero broken images and zero console errors.
  • Not run: Woodpecker full CI, PR review/merge, and cluster deployment (draft PR).

Why

Preserve the standalone Scythe tabletop web PoC (2-5 players, 3D Europa
tabletop, authentic physical player mats, Easy/Medium AI opponents, and
external Steam asset preparation scripts) inside sandbox/poc/scythe
without keeping private extracted game assets in Git or coupling root
workspaces.

What

- Add standalone PoC under sandbox/poc/scythe (client, deterministic
  engine, Easy/Medium AI policy & live playback driver, Hono + tRPC
  server, Prisma schema/migrations, Python asset pipeline scripts).
- Inline minimal Loaded/LoadingBlock helper (src/client/app/loaded.tsx)
  and adjust postgres test helper & tRPC client config for standalone
  execution outside root workspaces.
- Register sandbox/poc/scythe in sandbox/poc/README.md.

Verification

- Standalone post-Prettier checks inside sandbox/poc/scythe:
  - bun install --no-lockfile, bun run generate (Prisma Client), bun run build (Vite): exited 0
  - bun run typecheck (tsc --noEmit): exited 0
  - bun run test (Vitest): Test Files 6 passed (6), Tests 29 passed (29)
  - bun run test:extended (Postgres integration): Test Files 1 passed (1), Tests 2 passed (2)
  - bun run lint (eslint . --max-warnings=0): 0 semantic/type/hook lint warnings; 29 max-lines/max-lines-per-function findings after Prettier line wrapping (sandbox/** is excluded from repo package-quality/CI)
- Repo pre-commit suite (bunx lefthook run pre-commit): all 9 safety & Prettier jobs exited 0.
- Live browser verification via PinchTab (pre-move code/assets, desktop 1280x720 + mobile 390x844, Solo vs AI playback & 14K stitched board) passed with zero broken images and zero console errors.
- Not run: Woodpecker CI, PR creation/merge, and cluster deployment.
@shepherdjerred

Copy link
Copy Markdown
Owner Author

This change is part of the following stack:

Change managed by git-spice.

@greptile-apps

greptile-apps Bot commented Dec 3, 2026

Copy link
Copy Markdown
Contributor

Automatic reviews are disabled for this repository. Configure in Code Review Settings.

@coderabbitai

coderabbitai Bot commented Dec 3, 2026 •

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

Run configuration

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

…n scythe

Why

Keep large extracted Scythe Steam assets synced via Syncthing as a single
archive (~/Sync/Sync/scythe-assets.zip) that the standalone server loads
transparently without environment variables, and allow accessing the Vite
demo over Tailscale Serve.

What

- sandbox/poc/scythe/src/server/assets.ts: add async resolveAssetsRoot() to
  discover SCYTHE_ASSETS_DIR, ~/Sync/Sync/scythe-assets.zip, or
  ~/.local/share/scythe-assets, transparently unpacking .zip bundles into
  ~/.cache/scythe-assets/<hash> with stamp validation and in-flight
  extraction deduplication.
- sandbox/poc/scythe/scripts/prepare-assets.py: add --bundle-zip option for
  generating clean served-only asset zip archives.
- sandbox/poc/scythe/vite.config.ts: enable allowedHosts: true for Tailscale
  Serve proxying.
- sandbox/poc/scythe/src/server/server.test.ts: test transparent .zip asset
  bundle unpacking and HTTP serving.
- sandbox/poc/scythe/README.md: document automatic Syncthing zip discovery.

Verification

- cd sandbox/poc/scythe && bun run build && bun run typecheck && bun run test:
  Test Files 6 passed (6), Tests 30 passed (30).
- bunx eslint src/server/assets.ts vite.config.ts --max-warnings=0: exited 0.
- bunx lefthook run pre-commit: all safety & Prettier hooks passed.
- Live demo running via tailscale serve at https://macbook.tailnet-1a49.ts.net:7451/
  serving HTTP 200 and /api/assets/manifest in steam mode (194 images, 25 models)
  unpacked transparently from ~/Sync/Sync/scythe-assets.zip.
- Not run: full Woodpecker CI, PR merge, and cluster deployment.
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.

1 participant