A multiplayer platform-physics game inspired by Pong and Spy vs Spy, built with Three.js and React.
Two players compete to score points by getting the ball into their opponent's portal:
- Red player uses WASD to move and E to cast spells
- Blue player uses IJKL to move and O to cast spells
- Players can bounce the ball by touching it or using spell explosions
- The map loops horizontally (go right, appear on left)
- Match setup screen with seeded procedural generation controls
- Background selector for
bg1throughbg7, plus random rotation mode - Parallax edge layers for cave depth and better visual motion
- Improved spell explosions with cooldown and radial impulse behavior
- Win condition flow with end-match overlay and quick arena reroll
npm install
npm run devnpm run build- Import this repository into Vercel.
- Framework preset: Other.
- Build command:
npm run build - Output directory:
build - Deploy.
vercel.json is already included with SPA rewrite routing so all paths resolve to index.html.
Room sync across different devices uses Redis-backed Vercel serverless APIs:
POST /api/match/controlGET /api/match/state
To enable this in production:
- Add a Redis integration from Vercel Marketplace (Upstash Redis).
- In project environment variables, set:
UPSTASH_REDIS_REST_URLUPSTASH_REDIS_REST_TOKEN
- Redeploy.
If Redis env vars are missing, matchmaking API calls fail and matches fall back to local AI behavior.



