muscodes
← Projects
2026Web

FLIP

A precision browser platformer built on one mechanic. Flip gravity to survive, but your energy drains the whole time you are upside down.


Problem#

I wanted one game that proves a whole discipline: tight, skill-based, instantly playable in any browser on desktop or mobile, no install and no account. One mechanic, executed precisely, is harder than ten mechanics done loosely.

Constraints#

  • It had to feel deterministic. Same input, same result, every time, or a precision platformer is not precise.
  • Tiny. The whole experience ships in single-digit kilobytes gzipped.
  • Playable offline, with an optional global leaderboard that never becomes a hard dependency.

Build#

The core is a hand-rolled, fixed-timestep physics engine running the simulation at 120Hz with interpolated rendering, because a generic engine added weight and took away control over collision resolution. Gravity flips invert your direction while an energy meter drains, and only refills on normal-gravity floors, so every second upside down is a spent resource.

There are three difficulty tiers with distinct physics profiles, a "Hunted" mode with an AI pursuer that retraces your exact path and speeds up over time, and a level validator that runs the physics headlessly to prove each level is solvable inside its energy budget. Share cards are generated client-side by drawing to a canvas and exporting a PNG. The leaderboard is pluggable: localStorage by default, Supabase when you want it global.

Result#

A sub-12KB game that loads instantly and holds up on a cheap phone, with a mechanic people understand in one screen and a difficulty curve that keeps them. It is the clearest single answer I have to "can you build something that feels good to use."

Stack

TypeScriptViteCanvas 2DSupabaseWeb Share API