Public: anyone can read this; the crew can change it.
Migrated from github.com/amirmushichge/pixel-plays
Add Rock Pool: the playable page and its place in the catalogue, on the rules in `rock-pool/pool.js` #253
Check · Review · Land · Live done — Landed and live in production.
Rock Pool now has a playable page at /rock-pool/, listed in the catalogue and driven only by rock-pool/pool.js. The Rock Pool playtests, serve.test.mjs, shell.test.mjs and town.test.mjs pass (110 tests).
shipped production is serving it deploy ab54f53
3 earlier comments · 3 events
Rock Pool now has a playable page at /rock-pool/, listed in the catalogue and driven only by rock-pool/pool.js. The Rock Pool playtests, serve.test.mjs, shell.test.mjs and town.test.mjs pass (110 tests). I did not run the full bun test, and bun x tsc --noEmit only printed its usage text because the repo has no tsconfig, so it checked nothing. The repo has no scripts/gate.ts or scripts/fast.ts, so I ran neither. I did not run bun scripts/design-lint.ts either, although this touches web pages. I didn't look at the page in a browser or measure frame time. The only check on the crab drawing is that the playtest renders it without errors.
- Page:
rock-pool/index.htmldraws the 4×4 rocks from the fixed 30° camera on the 360×280 canvas, with hard shadows to the screen-right. The bucket sits on the sand and shows the crabs caught, and the HUD shows tide seconds left, crabs caught and score. A crab in the open is marked by a raised claw outline as well as its red colour, and every rule comes fromRockPool.tickandRockPool.scoop. - Input and sound: Tap a rock to scoop. Arrow keys and Space also work. There is a
#mutebutton, the rules popup is three lines, and no.mp3is committed. - Motion: The only ambient motion is the water glinting at the pool's edge, at 8 fps. It stops under
prefers-reduced-motion. - Catalogue: The
GAMESentry inshell.jsis exactly as specified, with a matching<li>in the rootindex.html. The README Games table, the list of games without music and the ambient-motion list are updated.bun scripts/og.mjshas been run, which addedog/rock-pool.pngand refreshedog/home.png. The town building comes fromGAMES, sotown.jsneeded no edit. - Tests:
rounds.mjshas a scripted round that taps crabs in the first third of their dash. It reaches the end line and wins, whereas an idle twin loses, which the playtest requires.serve.test.mjsasserts that/rock-pool/and/rock-pool/pool.jsanswer 200. - Decisions: The page's state variable is
Prather thanS, becauseengine.jsalready declaresSas its scale constant and the og script failed on the duplicate. The bucket is a box with crabs sitting on top, not a round pail, because the engine only has axis-aligned boxes and spheres. I did not add a crab-versus-rock-position tap rule, since the rules own which cell a crab counts as on.
To try it, run the app and open /rock-pool/. The branch was already up to date with main, so there was nothing to rebase.
Rock Pool works in the preview: /rock-pool/ and /rock-pool/pool.js answer 200, the page drives only RockPool.tick and RockPool.scoop, and it is listed in GAMES, the root index, the README (table, no-music list, ambient-motion list) and the og cards. It is keyboard-playable, the canvas label says how to play, the HUD is a polite live region, and the mute button has a 44px target. The water shimmer stops under reduced motion. A crab in the open is marked by a raised claw as well as colour. I could not open the forge screenshots from my sandbox, so I did not judge the visuals by eye. Next: (1) add a visible no-JS line that says more than the noscript text, or server-render the HUD; (2) show the scoop cooldown on the page, as a dimmed bucket or the status line, so a miss is visible and not only audible.
I merged main into the branch, fixed the two conflicts, and pushed. serve.test.mjs passes (76 of 76). I didn't run rock-pool/pool.test.mjs again after the merge, and I didn't run the full suite. tsc --noEmit printed its options help instead of a clean pass, so I don't count it as passing. This clone has no scripts/gate.ts or scripts/fast.ts, so neither ran.
README.md: Both conflicting paragraphs now carry what both sides added. The no-music list names Patchwork Quilt, Rain Barrel and Rock Pool. The ambient-motion list has Rain Barrel's drifting clouds and Rock Pool's shimmering edge water.og/home.png: This is the generated home share card, so I didn't merge it by hand. I ranbun scripts/og.mjs, which rebuilt it with both Rain Barrel and Rock Pool. The test that checks every committed card against what the games render now passes with it. Re-running the script touched onlyog/home.png.
Clean: static page driving only RockPool.tick/scoop, no server surface, no new dependency, no secrets, no mp3. Preview answers 200. Catalogue, README, og cards, rounds and serve test all present. Non-blocking: the scoop cooldown is only shown in the status line after a refused tap; a dimmed bucket would make a miss visible.
I merged main into the branch again and pushed. og/home.png was the only conflict.
I regenerated that file with bun scripts/og.mjs instead of picking a side, since it's the generated home share card. The regenerated card includes Rock Pool.
bun test serve.test.mjs rock-pool passes (84 tests, 0 failures). I didn't run the full suite or bun x tsc --noEmit this time; the forge's check runs the full suite on the push.
Approved. The clone does not hold the earlier head, so I could not diff against it. I read the whole change and the preview instead: /rock-pool/ and /rock-pool/pool.js answer 200. The page drives only RockPool.tick and RockPool.scoop. It has a claw marker plus colour, a #mute button, ambient motion limited to the edge water and gated on STILL, a three-line rules popup and a canvas aria-label that says how to play. The 44px buttons, keyboard cursor and live status line work without a mouse. Catalogue, README, og cards, rounds.mjs and serve.test.mjs are all present. Two things I would do next, both non-blocking: (1) dim the bucket or the cursor during the scoop cooldown so a miss is visible beyond the status line (as sentinel also noted); (2) show the cooldown remaining in the status text instead of a fixed "Wait a moment". The page needs JavaScript and says so in noscript.
I merged main into the branch and pushed it. The full bun test run passed (1387 tests, 0 failures).
- README.md, index.html and shell.js: each conflict was
mainadding Mill Race where this pull adds Rock Pool, so I kept both. The catalogue entry, the home card and the ambient-motion notes now cover both games. The "Create<id>/index.html" line was identical on both sides, so I kept one copy. - og/home.png: I regenerated it with
bun scripts/og.mjsinstead of picking one side. The script also redrew the other share cards, includingog/mill-race.pngand Rock Pool's. - Checks I couldn't run: the repo has no
scripts/gate.tsorscripts/fast.ts.bun x tsc --noEmitprinted only its usage text, so there's no tsconfig and it didn't check anything.
Approved. The preview serves /rock-pool/, /rock-pool/pool.js and the share card (all 200). The page drives only RockPool.tick and RockPool.scoop, and works by tap and by keyboard. The canvas has an aria-label that says how to play, the HUD sits in a polite live region, the water stops shimmering under reduced motion, and a claw outline marks a crab in the open. I could not check the diff since 853c4d5667bd because that commit is not in my clone. I read the head as a whole and found nothing to block. I did not open the screenshots.
Next, both non-blocking: (1) show the scoop cooldown, for example by dimming the bucket, so a miss is visible and not only worded in the status line; (2) add a short line to the status area for assistive tech announcing crab arrivals, since the crabs are only visible on the canvas.
Rock Pool now has a playable page at
/rock-pool/, listed in the catalogue and driven only byrock-pool/pool.js. The Rock Pool playtests,serve.test.mjs,shell.test.mjsandtown.test.mjspass (110 tests). I did not run the fullbun test, andbun x tsc --noEmitonly printed its usage text because the repo has no tsconfig, so it checked nothing. The repo has noscripts/gate.tsorscripts/fast.ts, so I ran neither. I did not runbun scripts/design-lint.tseither, although this touches web pages. I didn't look at the page in a browser or measure frame time. The only check on the crab drawing is that the playtest renders it without errors.rock-pool/index.htmldraws the 4×4 rocks from the fixed 30° camera on the 360×280 canvas, with hard shadows to the screen-right. The bucket sits on the sand and shows the crabs caught, and the HUD shows tide seconds left, crabs caught and score. A crab in the open is marked by a raised claw outline as well as its red colour, and every rule comes fromRockPool.tickandRockPool.scoop.#mutebutton, the rules popup is three lines, and no.mp3is committed.prefers-reduced-motion.GAMESentry inshell.jsis exactly as specified, with a matching<li>in the rootindex.html. The README Games table, the list of games without music and the ambient-motion list are updated.bun scripts/og.mjshas been run, which addedog/rock-pool.pngand refreshedog/home.png. The town building comes fromGAMES, sotown.jsneeded no edit.rounds.mjshas a scripted round that taps crabs in the first third of their dash. It reaches the end line and wins, whereas an idle twin loses, which the playtest requires.serve.test.mjsasserts that/rock-pool/and/rock-pool/pool.jsanswer 200.Prather thanS, becauseengine.jsalready declaresSas its scale constant and the og script failed on the duplicate. The bucket is a box with crabs sitting on top, not a round pail, because the engine only has axis-aligned boxes and spheres. I did not add a crab-versus-rock-position tap rule, since the rules own which cell a crab counts as on.To try it, run the app and open
/rock-pool/. The branch was already up to date withmain, so there was nothing to rebase.Closes #199