Space Invaders · muse-spark-1.2
Build a playable Space Invaders game on a canvas: a player cannon that moves and shoots, a descending grid of aliens that advance and fire back, destructible bunkers, score, and lives. Procedural graphics only, no external assets.
transcript · 6 messages
Build a playable Space Invaders game on a canvas: a player cannon that moves and shoots, a descending grid of aliens that advance and fire back, destructible bunkers, score, and lives. Procedural graphics only, no external assets.
index.html (39243 bytes)Successfully wrote 39243 bytes to index.html
{"command":"ls -lh index.html && head -n 20 index.html"}-rw-r--r--. 1 node node 39K Aug 13 01:34 index.html <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no"> <title>SPACE INVADERS — Vector Arcade</title> <style> :root{ --bg:#070b14; --panel:#0f1a2e; --accent:#38ff7c; --accent2:#00e5ff; --danger:#ff3b5c; --warn:#ffcc33; --text:#e6f0ff; --muted:#8ea0c0; --crt:rgba(56,255,124,0.08); } *{box-sizing:border-box;margin:0;padding:0} html,body{height:100%;background:var(--bg);color:var(--text);font-family:"Courier New",Courier,monospace;overflow-x:hidden}
Built `index.html` — playable Space Invaders with procedural graphics (no assets). **Features:** - **Player cannon:** smooth movement (Arrow/A/D + drag + hold buttons), single-shot with cooldown, invulnerability blink on respawn - **Alien grid:** 55 aliens (3 types, 30/20/10 pts) stepping classic style — horizontal march, dropping on edge, speed escalates as numbers thin + per level - **Alien firing:** bottom-most per column shoots with zigzag/straight bullets; bullet-vs-bullet cancels - **UFO:** random side spawn (100/150/200/300 pts) with glow - **Destructible bunkers:** 4 bunkers built from 8px blocks; any hit carves a crater (hit block + neighbors removed) - **Score/Lives/Level/Hi-Score** (persisted), speed meter, particle explosions, muzzle flash - **Audio:** Web Audio procedural synths (shoot, steps, explosion, UFO) - **Controls:** Keyboard (←→/A D, Space, P pause, R restart), touch hold + FIRE button, canvas drag/click, mute/pause/restart HUD All CSS/JS inline, no external requests, plays sandboxed.
TAKE IT TO CODE
A single self-contained HTML file — copy it and open in any browser, or reuse the prompt with your own pi-agent run.
RUN
EVALUATION
Menu loads, Enter/Space starts the game, aliens, bunkers, ship, UFO, and player move/fire correctly with keyboard input.
Vision grade · anthropic/claude-sonnet-5
MEASUREMENTS
Raw readings from the capture, not a verdict — the grade above is the only judgement. Percentages are how much of the screen changed; the measure under-reports sparse motion on a dark background.