Sound and Music
A Jackbox-style party joust. One laptop or TV is the arena. Everyone else joins on their phone as a controller. Riders flap to fly, strike from above, and ride a live synthesized beat — flap on the pulse for extra lift, and watch out for "the drop" when gravity spikes.
Live: https://sound-and-motion.onrender.com
Team / judge talk track: see PRESENTATION.txt in this repo.
Phones do not need the same Wi‑Fi. Everything (pages + WebSocket) is hosted on Render.
Screenshots
Share card (Open Graph / Twitter / Discord) — https://sound-and-motion.onrender.com/og-image.png
Landing — host the arena on a laptop/TV, or join from a phone.
Host lobby — 4-letter room code, QR, and join link.
Phone join — room code is already filled from the QR / link.
<img src="screenshots/phone-join.png" alt="Phone join screen with room code filled in" width="320">
Phone waiting — rider is in the room until the host starts.
<img src="screenshots/phone-waiting.png" alt="Phone waiting for the host to start the joust" width="320">
Host with a rider ready.
Countdown, then the arena.
Phone controller during a match — left / right and FLAP.
<img src="screenshots/phone-controller.png" alt="Phone controller with FLAP button" width="320">
Play (for judges and teammates)
- Open https://sound-and-motion.onrender.com on a laptop (or a TV / shared screen). Tap Host the arena.
- A 4-letter room code and QR appear. The QR is always
https://sound-and-motion.onrender.com/controller?room=ABCD— scan it and the room code is already filled in. Or open Join a room and type the code + a name. - When names show up on the big screen, hit START JOUST.
- Last rider standing — or highest score when the 3:00 clock runs out — wins.
If the first load takes ~30 seconds, the free Render instance was asleep.
Wait, then refresh once if the code is still ----. Don’t close or
refresh the host tab mid-match.
Playing over Discord / Zoom: one person hosts and screen-shares the arena tab. Everyone else joins on their phone. If a camera can’t read the QR off a screen-share, tap Copy join link or type the 4-letter code.
Controls
On the phone:
- Tap left / right to move, tap FLAP to fly.
- The phone buzzes on every beat. Flap on that buzz for a stronger "perfect flap" (+10).
On the arena:
- Hit another rider from above to unhorse them (+100).
- Don’t fall in the lava. Each rider has 3 lives.
- Every 8 beats, the drop spikes gravity for two beats.
Optional: React Native controller
The laptop host stays in the browser. Phones can use a native app
instead of /controller — same WebSocket, plus a camera QR scanner.
The scanner is its own file: mobile/src/QrScanner.js.
cd mobile
npm install
npx expo start
Open it in Expo Go, then scan the host QR. Judges can still join in
the browser; this app is extra. Details: mobile/README.md.
Run it locally
Needs Node 18+. No npm install required to play.
node server.js
Then open http://localhost:3000 — landing page with Host the arena and Join a room.
Sound and Music server running
--------------------------------
Open this on any device: http://localhost:3000/
Host screen (laptop/TV): http://localhost:3000/host
Phones on the same WiFi, open:
http://192.168.1.42:3000/controller
Local LAN play: phones on the same Wi‑Fi can use the printed
/controller URL, or scan the QR (it prefers the LAN address when the
host page itself is on localhost).
npm test
How the pieces fit together
phone (controller) ──┐
phone (controller) ──┼── WebSocket ── server.js ── WebSocket ── host (big screen)
phone (controller) ──┘ (relay only, no game logic)
| Piece | Role |
|---|---|
public/index.html |
Landing: host vs join |
public/host.html / host.js |
The whole game: physics, scoring, canvas, music |
public/controller.html / controller.js |
Phone input + haptics only |
server.js |
Static files + room relay (up to 8 riders) |
public/shared/qr.js |
Join QR generated in the browser (no third-party API) |
The host is the single source of truth — same model as Jackbox. Phones
only send left / right / flap. A phone can drop and
rejoin as the same rider. If the host tab is gone for more than ~12
seconds, the room closes.
Music is synthesized live with the Web Audio API (no audio files).
- Perfect flaps — within ~130ms of a beat: 35% more lift and +10.
- The drop — every 8 beats, gravity ×1.4 for two beats; screen shake.
- Tempo ramp — 128 BPM climbs toward 176 as the match goes on.
Deploy
Pushes to main on molokochris/sound_and_motion
are what Render should serve. If the live site still looks old, open the
Render dashboard for sound-and-motion and Manual Deploy the latest
main commit.
Do not use GitHub Pages for this game. Pages cannot host the WebSocket relay.
Crawlers, social unfurlers, and LLMs are allowed. The live site
serves robots.txt, sitemap.xml, llms.txt, JSON-LD on the
landing page, and screenshots at /screenshots/*.png. Sharing the
game URL uses /og-image.png (1200×630).
Notes
- Up to 8 riders per room. The canvas gets cramped past that.
- If a camera can’t read the QR, type the 4-letter code at
/controller. - Click the big room code on the host screen to copy it.