r/ClaudeCode • u/Swimming-Ad6447 • 1h ago
Built with Claude Built a 60fps Three.js D-Day Omaha Beach tactical sim with Claude Code (Opus 5.5) + headless WebKit QA loop: what worked and what broke
I've been testing how far I can push Claude Code (Opus 5.5) on a real-time 3D browser RTS without paying for generative asset APIs. This 60s clip is an unscripted AI-vs-AI run of our Omaha Beach prototype (HUD is still in Korean while I'm iterating).
What I built:
- Browser-based Three.js WebGL2 tactical sim on a 640m Omaha Beach stretch running at ~60fps in WebKit
- 296 soldiers driven by 16-bone WebGL2 DataTexture GPU instanced skinning + 2-bone foot-plant IK
20 LCVPs, 2 LCTs, 7 deep-wading Shermans, barrage balloons, pre-fractured bunker chunks, and 32 real CC0/CC-BY WW2 audio clips with distance attenuation
How Claude Code was used:
I split the work across four separate sessions on a Mac Studio:
- Spec/contract pass: write hard numeric limits first (polygon budgets, vertex attribute cap <= 16, camera angles, FPS floor >= 55)
- Headless Blender pass: rig and optimize free Sketchfab CC models into LOD0/LOD1 GLBs
- Claude Code (Opus 5.5) pass: implement the single-file Three.js runtime, custom GLSL surf/wet-sand shaders, instanced skinning, and unit AI against the spec
- Separate headless WebKit QA + audit pass: capture 16-frame contact sheets, run pixel checks (zero console errors, zero neon artifacts, EBU R128 loudness), and bounce failures back to Claude Code
What I actually learned the hard way:
- Never let the coding session grade its own visuals. Early builds looked fine in text logs ("all tests pass") while soldiers were ice-skating and tracers looked like Star Wars lasers. Automated WebKit frame captures + a separate auditor caught way more real defects.
- Claude Code's procedural WebAudio gunfire gets called out in 5 seconds. An earlier wargame clip got roasted immediately for fake synth sounds. Real Freesound CC0 WW2 recordings with speed-of-sound delay upgraded immersion more than hours of shader tweaks.
- Hard physical numbers stop arcade defaults. Vague prompts like "make D-Day look dramatic" gave me neon green/pink laser beams and flat grey sand. Once I gave Claude Code exact numbers (tracer thickness <= 0.042m, 1-in-4 tracer ratio, 0.04 wet-sand roughness, bleach-bypass curve), the look flipped in one iteration.
Happy to share the spec/QA harness structure if anyone's trying Three.js or game loops with Claude Code.
(Modified CC models from Sketchfab: M4A3 Sherman by @tnikita CC BY 4.0, PaK 40 by @lossgraph CC BY-SA 4.0, infantry by @Crazydud & @britdawgmasterfunk CC BY 4.0; terrain/foliage Poly Haven CC0; audio Freesound CC0 & CC BY 4.0.)
