Skyward - an endless climber game that lives in one HTML file
Skyward is a vertical climber -you bounce upward forever, the camera only follows you up, and one missed platform ends the run. Moving platforms, breakable ones,springs, a jetpack, and enemies you can stomp.
The constraint I set was that it had to be ONE file. No build step, no bundler, no CDN, no asset folder. You double-click the .html and it runs. The splash artwork is embedded as a base64 data URI, and every sound effect is synthesized live with the Web Audio API instead of loading audio files -- a bounce blip that rises in pitch as you climb, a boing for the spring, a filtered noise whoosh for the jetpack, a crack when a plank breaks, a thud for stomping an enemy, and four descending notes when you fall. That is the whole reason there are no .mp3 files: the file had to stay self-contained.
The most useful thing I got out of this was a bug. After a few seconds of play, the character just vanished. I sent a screenshot and said "check everything." The diagnosis came from what was MISSING in that screenshot: platforms were still drawn, but the player, the score badges, and the on-screen buttons were all gone -- which is exactly everything drawn AFTER the particle loop.
The cause: spent particles were being filtered out BEFORE their life value decayed, so a particle with negative life reached ctx.arc with a negative radius. Browsers throw IndexSizeError on that. The exception killed render partway through, and because requestAnimationFrame was called at the END of the game loop, that call never ran. One bad frame froze the game permanently.
Two lessons I will actually reuse. First: schedule the next frame at the TOP of the loop, never the bottom, so a single bad frame cannot end the game forever. Second, and this one stung , the test harness had 38 passing tests while the game was frozen solid, because the fake canvas happily accepted a negative radius that a real browser rejects. A test double that is more forgiving than reality will confidently
tell you everything is fine. I made the stub throw in exactly the places a browser
throws, and the bug surfaced immediately.
loading picture = make with nano banana pro
Tech stack
- Claude
- Vercel
- Nano Banana Pro
Links
Prompt
Build "Skyward": a complete arcade game in ONE self-contained HTML file.
HARD CONSTRAINT: runs by double-clicking. No build step, bundler, CDN, or external assets. Embed images as data URIs, synthesize all sound with Web Audio.
GAME: vertical endless climber. Auto-bounce on platform contact, no jump button.
Camera follows upward only. Screen edges wrap left/right. Score is altitude. Falling off the bottom ends the run. Persist the best score.
PLATFORMS: static, side-to-side moving (faster with altitude), and brittle ones that break on landing. Keep spacing under the jump apex. Solid ground at the start that scrolls away for good once you climb.
POWER-UPS riding on platforms: spring (one strong bounce), jetpack (~0.7s thrust with exhaust particles).
ENEMIES: drifting creatures. Stomp from above to squash and bounce; any other contact kills; a jetpack ploughs through. Spawn only after a decent climb.
CONTROLS, all three at once: arrows and A/D, hold-to-steer touch buttons, phone tilt.
LOOK: hand-drawn sketch style, jittered outlines, dark ink on soft colours. Sky deepens with altitude, drifting clouds, a sun that fades as you rise. Screen shake,particle bursts, squash-and-str…
13 likes · 3 comments · 11 views
Comments (3)
Fun game. Reminds me of doodle jump. Thanks for sharing Anita!
<p>That negative radius bug story is very good.</p>
<p>One HTML file with everything embedded is impressive.</p>