Vibe coding Contra with Claude: one HTML file, zero assets, self-testing AI
prasadpilla · reddit · 2026-11-11
A developer used Claude (Fable 5.2) with plain-English prompts to build a Contra-style shooter as a single HTML file — no engine, no image or audio assets.
Key implementation details:
- 960x540 world rendered into a 384x216 buffer with pixel snapping, then integer-scaled for crisp pixels
- Sprites are rigged skeletons, not sprite sheets: two-segment IK legs, layered body parts with 1px outlines and cached frames — an 8-frame run cycle in 5 aim directions from a few dozen lines of code
- Tiles, dithered sky bands and parallax layers come from a seeded RNG; the font is a 3x5 pixel grid
- Web Audio only: oscillator/noise SFX plus a 16-step sequencer scheduling notes 150ms ahead
- Three-phase boss state machine with ballistic arc-solving shots
- The model self-tested: thousands of frames with random inputs in a stubbed environment, plus headless Chrome screenshots it inspected and fixed
Notably, when asked for a 1:1 copy of the original game, Claude declined and designed original characters instead. Playable as a Claude Artifact.
More from coding & agent
- Matt Shumer's new video clarifies when to use Fable 5.2 vs Opus 5.5 — prasenx · 2026-11-11
- Rabbit insider: OS3 auto-responds to bug reports and drafts fixes in seconds — jesselyu · 2026-11-11
- Anthropic launches Claude Meetings: Claude joins Google Meet calls and does tasks live — No-Gazelle1365 · 2026-11-11
- GitHub's 2GB Cache Limit Bites as Celesto CI Offers 25GB Per Repo — aniketmaurya · 2026-11-11
- One Prompt Designs PCB, Enclosure and Firmware: Indian Manufacturer Urges Peers to Adopt AI — DrDatta_AIIMS · 2026-11-11
- Solo creators: keep a one-pager, decision log, and dated progress log — dSebastien · 2026-11-11