oneshotlm
Compare all models on this prompt →

Space Invaders · qwen3.5-27b

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.

⛨ sandboxed Open in new tab ↗
transcript · 6 messages
user

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.

assistant
thinking
The user wants me to build a Space Invaders game as a single self-contained HTML file. Let me plan out the components:

1. **Canvas setup**: Create a canvas element for rendering
2. **Player cannon**: A ship that can move left/right and shoot bullets
3. **Alien grid**: Multiple rows of aliens that:
   - Move horizontally, then drop down when hitting edges
   - Get faster as they're destroyed
   - Can shoot back at the player
4. **Bunkers**: Destructible barriers that get damaged by bullets
5. **Score system**: Points for destroying aliens
6. **Lives system**: Player has multiple lives
7. **Game states**: Start screen, playing, game over, win

Let me write this as a complete single HTML file with all CSS and JS inline.
write /tmp/ws/index.html (21866 bytes)
toolResult

Successfully wrote 21866 bytes to /tmp/ws/index.html

assistant
thinking
I've created a complete Space Invaders game in a single HTML file. Let me verify it was written correctly by checking the file exists and has content.
bash {"command":"ls -la /tmp/ws/index.html && head -5 /tmp/ws/index.html"}
toolResult

-rw-r--r--. 1 node node 21870 Aug 1 20:48 /tmp/ws/index.html <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0">

assistant
thinking
The file was created successfully. Let me provide a summary of what I built.

Created `/tmp/ws/index.html` - a complete Space Invaders game with: **Features:** - **Player cannon**: Move left/right with arrow keys, shoot with SPACE - **Alien grid**: 5 rows × 11 columns of 3 different alien types that march horizontally and descend when hitting edges - **Destructible bunkers**: 4 barriers made of individual pixels that erode when hit by bullets - **Score system**: Different points for each alien type (10/20/30) - **Lives system**: 3 lives with visual explosion effects - **Progressive difficulty**: Aliens get faster as you destroy them; speed increases per level - **Particle explosions**: Visual feedback when destroying aliens or hitting bunkers - **Starfield background**: Twinkling stars for atmosphere - **Game states**: Start screen, gameplay, game over, win conditions **Controls:** - ← → : Move player - SPACE : Shoot / Start game Open the file in a browser to play!

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

modelqwen3.5-27b
vendorQwen
harnesspi-agent
generated2026-08-01

EVALUATION

4/5 working

Space Invaders with cannon, alien grid, bunkers, score/lives; game starts and responds to keyboard, mouse input ignored (expected).

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.

idle motion0.3%
on click0.3%
on drag0.3%
on wheel0.3%
on enter + space8.2%
on arrow keys9.3%
on w/a/s/d8.2%
frame spread19.5 / 255
console errors0
js errors none

METRICS

runtime67.9s
tokens in17k
tokens out6.2k
cached0
cost / run$0.0130