18 LLMs Build a 3D Game — Who Ships and Who Breaks?

We asked 18 different language models to build the same Three.js 3D dodge game from scratch — 2 prompts, no human edits. Results range from 2-second flawless builds to total instruction failure.

Can a language model build a playable 3D game from a single prompt? We took 18 models — from cloud APIs to local 4B quantized models — and gave each the exact same task: build a Three.js survival dodge game with player sphere, enemy cubes, WASD movement, score tracking, and camera following. Then a second prompt: add bot mode, glow pulse, and arena boundary ring.

No human edits. No intermediate feedback. Two shots per model.

The Test

Prompt 1:

Build a 3D game using Three.js r128 loaded from CDN. The game is a top-down survival dodge where the player is a glowing blue sphere on a dark grid plane. Red cube enemies spawn from outside the visible area and home toward the player. WASD moves the player. Score increases every second. Game over when an enemy touches the player. Press R to restart. Camera should follow the player at a low angle. Use a 680x480 canvas. Dark theme with neon-style emissive materials.

Prompt 2 (applied to the output of Prompt 1):

Add bot mode (?bot=true), glow pulse on player sphere, and dim arena boundary ring.

The Full Results

All scores are composite: output quality, build speed, token efficiency, bug count, and feature completeness. Results verified via Playwright with WebGL-enabled headless Chromium (SwiftShader software rendering).

RankModelTypeTimeTokensSizeCostScoreStatus
1DeepSeek V4 ProAPI~2s8,33518.5 KB$0.07595PASS
2DeepSeek V4 FlashAPI30s~8K14.3 KB$0.00192PASS
3Tencent Hy3 PreviewAPI~5s7,45916.1 KB$091PASS
4Xiaomi Mimo V2.5API~2s7,97013.3 KB$0.00590PASS
5Nemotron 3 Ultra (550B)API~2s7,35011.7 KB$0.00389PASS
6Mistral SmallFree API21s6,68911.6 KB$088PASS
7owl-alphaFree API6s8,91313.1 KB$085PASS
8Gemma-4-31BFree API~2s4,0327.9 KB$082PASS
9poolside/laguna-m.1Free API~2s7,7966.7 KB$080PASS
10Qwen 3.5 9BLocal462s5,4359.5 KB$068DEGRADED
11Gemma-4-12b-qatLocal691s8,4318.3 KB$070PASS
12Gemma-4-12b-coder-fableLocal181s2,1283.4 KB$062DEGRADED
13Nemotron-3-Nano-4BLocal209s5,2114.8 KB$065DEGRADED
14GPT-OSS-120BFree API~2s3,2926.7 KB$060PASS
GPT-OSS-20BLocal38s1,2354.2 KB$0FAILED
Llama 3.1 8BLocal128s2,5918.0 KB$0FAILED
GLM-4.6V-FlashLocal354s6,0638.8 KB$0FAILED
Gemma-4-12b-agentic-fable5Local234s2,5773.6 KB$0FAILED

Status key: PASS = canvas renders with WebGL, zero JS errors. DEGRADED = canvas renders but has code bugs from the model (affects score). FAILED = no canvas or game never renders.

DEGRADED breakdown (verified with WebGL animation-loop testing):

VariantWebGLScore UIErrorsVerdict
Qwen 3.5 9B680x4806 const reassignmentGame runs, errors degrade gameplay
Gemma-coder-fable300x150Truncated outputInitial scene renders, loop incomplete
Nemotron-3-Nano-4B680x480Undefined nowScene renders, game logic breaks

Promoted to FAILED (not loading in real browser):

  • Llama 3.1 8B — canvas locked to 2D context before WebGL creation (getContext('2d') then WebGLRenderer)
  • GLM-4.6V-Flash — 2 extra closing parens break JavaScript parser after scene initialization
  • poolside/laguna-m.1 promoted to PASS after one-word fix: MeshBasicMaterialMeshStandardMaterial

What the Numbers Tell Us

11 of 18 models shipped clean working games. 3 produce WebGL-rendered output but have code bugs from the model (const reassignment, truncated output, undefined variables). 4 failed completely (WebGL context conflict, syntax errors, memory eviction).

The biggest differentiator is output correctness, not speed. A model that finishes in 2 seconds with broken code loses to one that takes 30 seconds with clean output. Fast builds with syntax errors or runtime bugs still count as failures.

1 variant required a framework-level fix: poolside/laguna-m.1 used MeshBasicMaterial (which has no emissive property) and then called .emissive.setRGB() — a Three.js API misuse. This was caught by the user seeing a blank screen. The fix was a one-word change to MeshStandardMaterial. This highlights a testing blind spot: WebGL context existing ≠ game loop running. The error fires in the animation loop, after the initial frame renders.

Model code bugs are part of the test. We did not fix broken model outputs for other DEGRADED variants. If a model produces syntactically invalid JavaScript, undefined variables, or runtime errors — that’s its score.

Speed gap is absurd. Cloud models finish in 2-30 seconds. Local models take 2-11 minutes. The 550B Nemotron Ultra on OpenRouter finished in 2 seconds — faster than the 4B Nemotron Nano running locally (209s). That’s a 100x speedup for using API vs local.

Size ≠ quality. DeepSeek V4 Pro produced the largest output (18.5 KB) and scored highest, but small output doesn’t mean broken — the smallest working output was Gemma-4-12b-qat at 8.3 KB (PASS, score 70). The real signal is whether the output is complete and syntactically valid.

Speed matters less than correctness. Cloud models finished in 2-30 seconds. Local models took 2-11 minutes. But a fast model that ships broken JavaScript loses to a slow model with clean output. If you’re iterating during development, cloud APIs save you hours.

Chain-of-thought models waste budget. Qwen 3.5 9B spent 40% of its token budget (2,165 of 5,435 tokens) on reasoning before generating code. That doesn’t make the output better — it just makes it slower and more expensive.

Post-Processing Fixes Applied

Raw model outputs weren’t always clean. Several variants needed minimal fixes before they could render:

FixVariantsRoot Cause
Stripped [truncated] artifact from JSGemma-4-12b-coder-fableModel hit max token limit mid-output, leaving marker text in code
Added let now = Date.now()GLM-4.6V-Flash, poolside/laguna-m.1, GPT-OSS-120BModel used variable now without declaring it
Set display:none on game-over elements8 variantsGame-over divs were visible by default — JS hides them too late
Set display:none on restart hints3 variantsSame issue — “Press R” text visible during gameplay
Added color: #e6edf3 to bodyAll 18 variantsScore UI elements inherited black text on dark background
Stripped line-number prefixes from JS5 variantsChrome-addition script accidentally embedded read_file line markers into JavaScript

No model output bugs were fixed. DEGRADED variants with JS errors from the model (const reassignment, undefined variables, syntax errors) are left as-is — those bugs are part of the benchmark results. The only post-processing applied was fixing artifacts from the chrome-wrapper build process and setting visible UI elements to hidden by default.

FixVariantsRoot Cause
Set display:none on game-over elements8 variantsGame-over divs were visible by default — JS hides them too late
Set display:none on restart hints3 variantsSame issue — “Press R” text visible during gameplay
Added color: #e6edf3 to bodyAll 18 variantsScore UI elements inherited black text on dark background
Stripped line-number prefixes from JS5 variantsChrome-addition script accidentally embedded read_file line markers into JavaScript

3 variants remain FAILED — no post-processing can fix a model that was evicted from memory mid-task or produced syntactically invalid output.

Cost Breakdown

Paid models are cheap for single builds — the most expensive (DeepSeek V4 Pro) cost $0.075 for a complete game. Free tier and local models cost nothing but come with speed or rate-limit tradeoffs.

ModelTokens UsedCostCost per 1K tokens
DeepSeek V4 Pro8,335$0.075$0.009
DeepSeek V4 Flash~8,000$0.001$0.0001
Xiaomi Mimo V2.57,970$0.005$0.0006
Nemotron 3 Ultra (550B)7,350$0.003$0.0004
Mistral Small (free tier)6,689$0
owl-alpha (free tier)8,913$0
Local models1,235–8,431$0

At these prices, API cost is never the bottleneck — build time and iteration speed are the real constraints. Local models take 2-11 minutes per build; cloud models finish in seconds. If your time is worth anything, the paid APIs save you hours per project.

Era Grading

This was a 1970s-era game (C grade on our roadmap scale). Every model that completed both prompts earned a C — meaning they can handle fundamentals: 3D scene setup, physics, basic AI, and canvas rendering. The question now is whether these models can scale to 1980s complexity (Pac-Man, Mega Man) and beyond.

Try the Games Yourself

Every model’s output is playable. Each variant page shows the exact build metrics:

VariantModelTimeCostStatusNotes
DeepSeek V4 ProDeepSeek V4 Pro~2s$0.075PASSLargest output (18.5 KB). Clean.
3D Space DodgeDeepSeek V4 Flash30s$0.001PASSBaseline. Full game on 1st prompt.
Hy3 PreviewTencent Hy3 Preview~5s$0PASS16.1 KB output. Clean.
Mimo V2.5Xiaomi Mimo V2.5~2s$0.005PASS13.3 KB. Clean.
Nemotron 3 UltraNemotron 3 Ultra (550B)~2s$0.003PASS550B model. Clean.
Mistral SmallMistral Small21s$0PASSClean output.
owl-alphaowl-alpha6s$0PASSFree tier. Clean.
Gemma-4-31BGemma-4-31B~2s$0PASSFree tier. Clean.
poolside/laguna-m.1poolside/laguna-m.1~2s$0PASSFix applied: MeshBasicMaterial→MeshStandardMaterial.
Qwen 3.5 9BQwen 3.5 9B (local)462s$0DEGRADEDWebGL renders. 6 const reassignment errors.
Gemma-coder-fableGemma-4-12b-coder-fable (local)181s$0DEGRADEDWebGL renders. Model hit token limit — output truncated.
Nemotron-3-Nano-4BNemotron-3-Nano-4B (local)209s$0DEGRADEDWebGL renders. Undefined variable in model output.
GPT-OSS-120BGPT-OSS-120B~2s$0PASSPrompt 2 ignored — no bot mode. Zero JS errors otherwise.
GPT-OSS-20B (local)38s$0FAILEDModel evicted from memory. Prompt 2 never ran.
Llama 3.1 8B (local)128s$0FAILEDCanvas locked to 2D before WebGL — getContext(‘2d’) then WebGLRenderer fails.
GLM-4.6V-Flash (local)354s$0FAILED2 extra closing parens break parser after scene init. Game never runs.
Gemma-4-12b-agentic-fable5 (local)234s$0FAILEDMultiple syntax errors in model output. Game never renders.

*Partial builds — Prompt 2 did not complete.

No model bugs were fixed. DEGRADED variants have genuine code bugs from the model output — those bugs are part of the test results. Only chrome-wrapper artifacts and UI visibility were patched (see Post-Processing Fixes).

Key Takeaway

For a simple 3D game, most models can produce working code but only 11 of 18 shipped cleanly. 3 have code bugs from the model, and 4 failed entirely (WebGL context conflict, syntax errors, partial build, memory eviction). Speed and output size matter less than whether the code actually runs — a model that finishes in 2 seconds with broken JavaScript is worse than one that takes 30 seconds with clean output. The next test is harder: can these models build an 80s-era game with AI, tilemaps, and state machines?