--- name: blender-lpm-skill description: Blender Low Poly Modelling Skill — build stylized, flat-shaded, game-ready low-poly assets (weapons, shields, armor, props, modular architecture) from primitives with a fixed triangle budget, a single palette material, Unity-ready FBX + BaseColor/MaskMap export, and a measured render-inspect loop. Use for any "make a low-poly X", "stylized game asset", "flat-shaded", "palette texture", "1000 tris" request in Blender, headless or through MCP. --- # Blender Low Poly Modelling Skill (LPM) Low-poly is a discipline, not a decimate button: **silhouette first, one palette material, every triangle earns its place, numbers before opinions.** This skill gives you a procedure and a toolkit (`scripts/lpm.py`) that turns a brief into a finished, exported, measured asset in one headless run. ## Procedure 1. **Brief → budget.** Write one line: *asset, real size in metres, triangle budget, palette cells, target engine.* Budgets: hero weapon 1 200 · shield/helmet 1 500 · prop 800 · kit module 600–3 000 · character 8 000 (see [references/budgets-and-style.md](references/budgets-and-style.md)). 2. **Part list.** Decompose the object into 4–12 primitive parts, top-down (a gladius = blade, ridge, guard, grip, rings, pommel, rivet). Give each part a palette colour. Note which parts are mirrored. 3. **Recipe script.** Write a short Python recipe using `lpm` (copy the pattern from `examples/`): `box`, `prism`, `lathe`, `sweep`, `plate`, then `bend` / `taper` / `mirror_x` / `rotate` / `move`. Metres, Z up, front = −Y. Finish with `lpm.finish(name, parts, palette, budget)` and `lpm.export_unity(...)`. Run: `python scripts/bl.py --script my_recipe.py -- --out _work//`. 4. **Look at it.** Render five views + contact sheet: `python scripts/bl.py --script scripts/render_views.py -- --input _work//.blend --out _work//views --ortho` Read the sheet. Judge silhouette (front, side), proportion (compare against the brief's metres), read-ability of parts (do colours separate parts?), facet count (is any curve wasting triangles?). Fix the recipe, re-run. Three iterations is normal; more than five means the part list was wrong — redo step 2. 5. **Reference overlay** when a concept exists: `scripts/compare_silhouette.py --ref concept.png --render views/front.png` → IoU ≥ 0.90, aspect diff ≤ 3 %, then argue about details. 6. **Gates.** `python scripts/bl.py --script scripts/inspect_scene.py -- --input .blend --out .inspect.json` then `python scripts/gate_report.py .inspect.json --class --budget `. PASS required: budget, transforms applied, base at z = 0, UVs present, no empty slots, no degenerate faces, no loose vertices. 8. **Deliver**: `.blend`, `.fbx` (Unity axes −Z forward / Y up), `tex/_BaseColor.png`, `tex/_MaskMap.png` (R metallic · G AO · A smoothness), plus the contact sheet and the gate report. Bundle prompt + recipe + metrics + renders into one shareable file with `python scripts/asset_card.py --name --prompt "" --recipe --render … --out _card.html` (self-contained HTML with embedded images, Markdown twin next to it). Report triangles vs budget, dimensions, and any deliberate deviation from the reference. ## From a reference image (concept art → model) Follow [references/reference-to-lowpoly.md](references/reference-to-lowpoly.md): **turnaround first** (`scripts/make_turnaround.py`: one concept → front/side/back/top via fal.ai, ≈ $0.16), then the **audit table** (parts → primitives/kit builders, proportions as ratios, camera angle, palette, organic parts), then recipe, then a quarter ortho front/side renders compared with the turnaround (`compare_silhouette.py`, IoU ≥ 0.85), max 3 iterations, accept by IoU/aspect + the 5-view sheet. Kit builders for Roman/stylized sets live in `scripts/lpm_kit.py` (banner, medallion, rivets, meander band, block course, flame, handle arc, column, plinth steps, wall ring, ring_of) plus organic stand-ins (`blob`, `wedge`, `limb`). Organic parts are built from those — faceted, readable, cheap — not generated. ## Style rules - **Flat shading everywhere**; curvature comes from facet count: 6–8 sides for grips and rivets, 8–12 for domes and shafts, 10–16 for hero wheels and shields. Never subdivide. - **Silhouette > surface.** Spend triangles where the outline changes (tips, guards, crests, capitals); flat regions are single quads. - **PBR = definitions, not textures.** One material, one 8×N-cell palette image (`Closest` interpolation), each face's UV in the centre of its cell. Every cell is a *definition*: `(name, baseColor, metallic, roughness[, emission])` — exported as `.materials.json` (URP Lit parameter names) next to the tiny palette PNGs. No bakes, no generated textures, no seams. Detail like rings, bands and rivets is *geometry* so it shows in the palette. - **Real scale.** 1 unit = 1 m; a gladius is 0.65 m, a scutum 1.05 m, a helmet 0.30 m, a door 2.2 m. Base on z = 0, centred on x = 0, pivot at the base centre (props) or the snapping corner (kit modules). - **Read-ability at 3 m**: contrast between neighbouring parts (wood next to steel next to bronze); avoid two similar mid-greys touching. - **Symmetry by mirror**, never by remodeling; asymmetric details only when the reference has them. - **No coplanar faces between parts**: sink a part ≥ 2 mm into its neighbour or let it stand ≥ 2 mm proud. Coplanar twins z-fight and render black in Cycles. `finish()` welds only inside each part for the same reason. - **Kit modules** sit on a metric grid (0.5 / 1 m), share the palette, and have flat contact faces. ## Toolkit summary (`scripts/lpm.py`) | Call | Makes | | --- | --- | | `Palette([(name, "#hex", metallic, roughness), …])` / `PALETTE_ROMAN` | palette cells; `P["steel"]` → index | | `box(name, (x, y, z), at, color, taper)` | block, optional top taper | | `prism(name, sides, r, h, at, color, radius_top, rotate)` | n-gon column / ring / rivet | | `lathe(name, [(r, z), …], segments, at, color)` | revolved profile (pommel, boss, dome, base) | | `sweep(name, [(x, z), …], depth, at, color, axis)` | extruded outline (blade, plate, crest, cheek) | | `plate(name, w, h, t, corner, at, color)` | rounded rectangular plate (shield body) | | `bend(ob, radius, axis)` · `taper(ob, f, z0, z1)` · `mirror_x(ob)` · `rotate` · `move` · `scale` | deformers | | `finish(name, parts, palette, budget)` | join, weld (per part), ground, centre, palette UVs, single material, budget check | | `collision_box(ob)` | 12-tri collision proxy `_COL` (parented, wire, hidden in renders, exported with `extra=[…]`) | | `export_unity(ob, stem, extra=[collider])` | `.blend` + Unity FBX (asset + helpers) + palette PNGs; prints `##JSON##` report | Kit: `scripts/lpm_kit.py` (Roman set builders). Companion scripts: `bl.py` (run Blender headless), `render_views.py` (5 views + sheet), `beauty_render.py` (presentation render), `turntable.py` (360° MP4 + 8-frame sheet), `inspect_scene.py`, `gate_report.py` (ignores `_COL`/LOD helpers), `compare_silhouette.py`, `asset_card.py` (prompt + recipe + metrics + renders → one HTML/MD file). Worked recipes in `examples/`: gladius, scutum, galea helmet, arena column, chest, roman_chest (with collider + turntable). ## With Blender MCP instead of headless Paste the recipe into `execute_blender_code` after `sys.path.insert(0, "/scripts")`; use the server's screenshot/render tool instead of `render_views.py`. The procedure does not change. ## Do not - Do not decimate a high-poly mesh and call it low-poly; rebuild from primitives. Do not call generators. - Do not add a normal map to fake detail on a flat-shaded asset. - Do not accept an asset from one flattering view; the side and top views expose thickness and proportion errors. - Do not exceed the budget "just a little": remove a facet ring, merge two parts, or drop a rivet.