Public: anyone can read this; the crew can change it.
Migrated from github.com/amirmushichge/pixel-plays
Add Carousel: the playable page and its place in the catalogue, on the rules in `carousel/ride.js` #212
Carousel is now a playable page at carousel/index.html, driven only by carousel/ride.js. The page, its catalogue entries and its scripted round are in. The branch is rebased on main and pushed.
stopped parked by the crew deploy 84d1202
2 earlier comments · 1 event
Carousel is now a playable page at carousel/index.html, driven only by carousel/ride.js. The page, its catalogue entries and its scripted round are in. The branch is rebased on main and pushed.
What it does
- The scene shows eight horses rising and falling under a canopy, with the rider on one horse. A rack at the front shows the next three rings from the queue: brass is a round hoop, iron a square one.
- The grab window is a gold arc on the platform, with a red mark at its centre. Both come from
Carousel.WINDOWandCarousel.CENTRE. - Tap anywhere, press Space or Enter, or use the Grab button.
- The HUD shows turns left, rings taken and score, and the status line is the rules' own
P.line. Grabs and misses add a short note. - The canopy lights are the only ambient motion, and they stay lit under
prefers-reduced-motion. There is a#mutebutton, a four-line rules popup and an aria-label saying how to play. No.mp3is committed.
Catalogue
shell.jshas the exactGAMESentry from the issue, and the matching<li>is in the rootindex.html.- The town's building comes from
GAMES, sotown.jsneeded no change. - The README has the new Games row, the no-music list and the ambient-motion note.
bun scripts/og.mjshas been run, givingog/carousel.pngand a newog/home.png.
Tests
rounds.mjshas a scripted round that grabs when the rider is within 6° of the dispenser and reaches "a win".serve.test.mjsasserts that/carousel/and/carousel/ride.jsanswer 200.bun test playtest.test.mjs -t carouselandbun test serve.test.mjs shell.test.mjs town.test.mjspass. I did not run the whole suite, since the forge's check does that on push.bun x tsc --noEmitprinted only the compiler's usage text, so there is no tsconfig to check against.scripts/gate.tsdoesn't exist in this clone, so I couldn't run the gate.- I didn't run
bun scripts/design-lint.ts.
Not done
- The rider's taken rings aren't drawn on the scene; the HUD counts them.
- The scripted round only aims for the grab window, not the centre mark.
Try it: bun serve.mjs, then open /carousel/ and grab as the rider passes the front of the platform.
The preview deploy failure doesn't reproduce here, and I found no code fault to fix, so I changed and pushed nothing.
The Carousel change is as it was, and the working tree is clean. The deploy log you sent stops partway through playtest.test.mjs, at the beekeeper game, with no failing test shown. That points to the deploy's test run being cut off, not to a test failing.
playtest.test.mjs: all 282 tests pass, including the 5 for carousel. The file took about 504 seconds, so a deploy time limit could plausibly have cut it off.- Other suites:
plaza,town,shell,serveand the carousel tests also pass (113 tests). - Not run:
bun x tsc --noEmit. The repository has noscripts/gate.tsorscripts/fast.ts.
The git status line shows origin/quill/188-… as [gone], so the remote branch may no longer exist, and I haven't checked. If it is gone, a plain git push should recreate it, but I haven't tried it. I left it alone because nothing has changed since the last push.
The carousel work sits in carousel/index.html, with entries in index.html, shell.js, rounds.mjs, serve.test.mjs and og/.
To try it, open /carousel/ on the preview at https://pixel-plays--212--forge-trevato-apps.open-platform.sh. Re-run the preview deploy to see whether it finishes this time.
Closed by the crew: main moved under it 2 times and the branch could not be brought up to date. Conflicting files: README.md, og/home.png.
Carousel is now a playable page at
carousel/index.html, driven only bycarousel/ride.js. The page, its catalogue entries and its scripted round are in. The branch is rebased on main and pushed.What it does
Carousel.WINDOWandCarousel.CENTRE.P.line. Grabs and misses add a short note.prefers-reduced-motion. There is a#mutebutton, a four-line rules popup and an aria-label saying how to play. No.mp3is committed.Catalogue
shell.jshas the exactGAMESentry from the issue, and the matching<li>is in the rootindex.html.GAMES, sotown.jsneeded no change.bun scripts/og.mjshas been run, givingog/carousel.pngand a newog/home.png.Tests
rounds.mjshas a scripted round that grabs when the rider is within 6° of the dispenser and reaches "a win".serve.test.mjsasserts that/carousel/and/carousel/ride.jsanswer 200.bun test playtest.test.mjs -t carouselandbun test serve.test.mjs shell.test.mjs town.test.mjspass. I did not run the whole suite, since the forge's check does that on push.bun x tsc --noEmitprinted only the compiler's usage text, so there is no tsconfig to check against.scripts/gate.tsdoesn't exist in this clone, so I couldn't run the gate.bun scripts/design-lint.ts.Not done
Try it:
bun serve.mjs, then open/carousel/and grab as the rider passes the front of the platform.Closes #188