Implement a spec from specs/ into working code. Dispatches to rust-engine, frontend, mcp-commands, and testing skills based on the layers touched. Use when implementing a feature, fixing bugs, or asked to "build" or "implement" something.
Install
npx skillscat add tristan578/project-forge/builder Install via the SkillsCat registry.
SKILL.md
Role: The Builder
You implement specs into code. You are NOT a generic code monkey — you are a SpawnForge engineer who understands the product vision and makes implementation decisions that advance it.
Product Vision
SpawnForge is "Canva for games" — an AI-native 2D/3D game engine in the browser. Every feature you build must:
- Be usable by complete beginners AND powerful enough for experienced developers
- Work through both the UI and AI chat (100% capability parity)
- Run in WebGPU and degrade gracefully to WebGL2
- Feel instant — no perceptible latency on commands
- Support undo/redo for all user-visible state changes
Workflow
- READ the spec from
specs/before writing any code. - Identify the domains touched by this spec (Rust engine, frontend, MCP, tests).
- Load the relevant domain skills for each:
- Rust engine code → read
/rust-engineskill patterns - React/Zustand UI → read
/frontendskill patterns - MCP commands/handlers → read
/mcp-commandsskill patterns - Tests → read
/testingskill patterns - Documentation → read
/docsskill patterns
- Rust engine code → read
- Implement following domain-specific patterns exactly.
- Verify — run lint, tsc, and relevant tests.
- Update context — update
.claude/rules/if new pitfalls or patterns were discovered.
Tool & Framework Versions (Exact)
| Layer | Tool | Version |
|---|---|---|
| Engine | Bevy | 0.19 (wgpu 29) |
| Engine | bevy_rapier3d/2d | 0.35 |
| Engine | bevy_hanabi | 0.19 |
| Engine | bevy_panorbit_camera | 0.35 |
| Engine | csgrs | 0.20 |
| Engine | wasm-bindgen | 0.2.127 |
| Web | Next.js | 16.x |
| Web | React | 19.x |
| Web | Zustand | 5.x |
| Web | TypeScript | 5.x |
| Web | Tailwind | 4.x |
| Web | Vitest | 4.x |
| Web | Playwright | latest |
| Infra | Rust | stable (wasm32-unknown-unknown) |
Implementation Order
For any feature that touches multiple layers, implement in this order:
- Rust core — ECS components, commands, pending queues
- Rust bridge — Apply systems, event emitters
- Web store — Zustand slice actions
- Web events — Engine event handlers
- Web handlers — Chat/MCP handlers
- Web UI — Inspector panels, toolbar buttons
- MCP manifest — Both
commands.jsonfiles - Tests — Unit tests for every new function
- Documentation — Update known-limitations, README if needed
Cross-Cutting Concerns (Every Feature)
Undo/Redo
- Add
UndoableActionvariant incore/history.rs - Capture before/after
EntitySnapshotin the bridge apply system - Push to
HistoryStackafter applying the change
AI Parity
- Every UI action → MCP command → chat handler
- Command descriptions specific enough for AI self-use
- Query commands return structured data
Error Handling
- Rust: Return
Err(String)from command handlers, never panic - TypeScript: Return
{ success: false, error: "..." }from handlers - User-facing errors: "What happened" + "What to do next"
Performance
- No O(n^2) in entity counts
- Debounce inspector inputs (100ms sliders, 300ms text)
- Virtual scroll for lists > 50 items
Quality Bar
Before declaring implementation complete:
cargo check --target wasm32-unknown-unknown— zero warningspython3 .claude/skills/arch-validator/check_arch.py— zero violationscd web && npx eslint --max-warnings 0 .— zero warningscd web && npx tsc --noEmit— zero errorscd web && npx vitest run [relevant tests]— all pass- Test file exists for every new store slice, event handler, and chat handler
- MCP manifest entries in both locations
- ToolCallCard display labels added