02 — 2026

Disc Mayhem

Cartoon 3D disc golf with real flick throws, a procedural 18-hole course, and 8-player online rounds.

Role
Solo — design, build, ship
Year
2026
Stack
JavaScript (ES modules, no build step) · Three.js · WebSocket (ws) · Node · Electron
Links
Source
Hole 1 from the tee: a low-poly fairway rolls toward a basket between cartoon trees; the HUD shows par, strokes, wind and the disc selector

What it is

Disc Mayhem is a browser game: hold the mouse, flick, and the disc flies. Flick speed is power, and a curved flick bends the shot — hyzer or anhyzer — the way a real disc does. Every hole of the 18-hole course is generated from a seed, so a daily seed means everyone plays the same course that day. Rounds are simultaneous race golf: lowest strokes wins, and ties go to the clock.

Power discs keep it from being a simulator. A Blade flies flat and fast and “poofs” any opponent it hits — they respawn at their lie with a penalty stroke. A Bomb flattens nearby trees for twelve seconds to open new sightlines. Up to eight players share a room with a four-letter code; it also runs as a desktop app through Electron, and on a phone with one-finger flicks and pinch zoom.

How it's built

  • Plain ES modules with an import map — no bundler, no TypeScript, no asset files. Every tree, character, disc and particle is procedural geometry with toon materials.
  • Disc flight uses real disc-golf flight numbers (speed, glide, turn, fade) per disc type; wind is rolled per hole; water and trees are collision checks against the generated course.
  • shared/ holds the seeded RNG, constants and wire protocol with zero imports, so the same files load in the browser and in Node. The server is a static file server plus WebSocket rooms that relay validated messages.
  • The game loop, HUD, scorecard, lobby and menus are vanilla DOM; the Electron wrapper is the path to a Steam build.

Highlights

  1. 01Flick-to-throw maps a 2D mouse gesture to a 3D launch vector with spin, tuned until a hyzer flick fades the way a real driver does.
  2. 02Deterministic course generation from a 32-bit seed: the daily course is reproduced on every client without sending geometry over the wire.
  3. 03Networked rounds with host authority — the relay validates message shapes and room state, so a misbehaving client can't corrupt a round.
  4. 04Touch controls were added without forking the input code: one gesture model serves mouse and finger.
  5. 0551 commits, physics first, then course generation, netcode and polish — each module's contract was written in DESIGN.md before its code.

What I'd do next

  • Host the relay on a small VPS so public lobbies work anywhere.
  • Package with electron-builder and integrate Steamworks for achievements.
  • Practice bots exist; teach them to use power discs.

More screens

Hole 4, par 5, 180 m: the golfer stands on a sand tee pad in a clearing, with the course seed shown in the corner
After a Bomb throw: flattened tree canopies lie on the fairway, opening a sightline to the basket
The game lobby: enter a name, play solo, host a room, or join with a four-letter code