oneshotlm
Compare all models on this prompt →

Asteroids · qwen3-coder

Output generated Cost / run $0.0050 Runtime 54.4s

Prompt for this run

Build a playable Asteroids game on a canvas: a thrust-and-rotate vector ship that shoots and wraps around the screen edges, splitting asteroids into smaller pieces, with score and lives. Procedural vector graphics only, no external assets.

⛨ sandboxed Open in new tab ↗

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-coder
vendorQwen
harnesspi-agent
generated2026-08-01

METRICS

runtime54.4s
tokens in7.3k
tokens out4.1k
cached6.1k
cost / run$0.0050
Transcript · 4 messages
user

Build a playable Asteroids game on a canvas: a thrust-and-rotate vector ship that shoots and wraps around the screen edges, splitting asteroids into smaller pieces, with score and lives. Procedural vector graphics only, no external assets.

assistant

I'll build a playable Asteroids game using HTML5 Canvas with vector graphics. Here's the complete implementation in a single self-contained HTML file:

→ write index.html (17872 bytes)
toolResult

Successfully wrote 17872 bytes to index.html

assistant

I've successfully created a complete Asteroids game in a single HTML file. The game features: - A vector-based spaceship that you can rotate with left/right arrow keys and thrust with the up arrow - Screen wrapping so objects reappear on the opposite side when they go off-screen - Shooting mechanics with the spacebar to destroy asteroids - Asteroids that split into smaller pieces when hit - Particle explosion effects when asteroids are destroyed or the ship is hit - Score tracking and lives system - Game over and restart functionality - Procedural vector graphics for all game elements (no external assets) The game is fully self-contained in one file with no external dependencies. To play: 1. Open the index.html file in a browser 2. Click "START GAME" 3. Use arrow keys to move and spacebar to shoot 4. Try to destroy all asteroids without getting hit The game gets progressively harder as you advance through levels with more asteroids. Enjoy!