unity-probuilder
ProBuilder editable mesh modeling for blockout and level geometry. Use when users want to create ProBuilder shapes, extrude faces, bevel edges, subdivide meshes, weld/move vertices, paint per-face materials, or run procedural mesh operations. Triggers: ProBuilder, ProBuilderMesh, mesh modeling, blockout, level geometry, shape, face, edge, vertex, extrude, bevel, chamfer, subdivide, weld, merge, bridge, flip normals, conform normals, project UV, 3D 建模, 建模, 拉伸, 挤出, 倒角, 细分, 焊接, 法线, 面, 边, 顶点, 关卡白模. Requires com.unity.probuilder package; missing-package calls return a diagnostic stub.
- License 许可
- MIT
- 最近更新
- 2026-07-25
- Stars
- ★ 8
- Forks
- 0
01 前言 Front Matter
- name
- unity-probuilder
- metadata
- { "tier": 2, "source": "https://github.com/Besty0728/Unity-Skills", "version": "1.9.2" }
- use-when
- Load when the task requires: ProBuilder editable mesh modeling for blockout and level geometry. Use when users want to create ProBuilder shapes, extrude faces, bevel edges, subdivide meshes, weld/move vertices, paint per-face materials, or run procedural mesh operations. Unity Editor must be running with the unity-skills REST server reachable at http://localhost:8090.
- platforms
- [ "unity-editor", "claude-code" ]
- description
- ProBuilder editable mesh modeling for blockout and level geometry. Use when users want to create ProBuilder shapes, extrude faces, bevel edges, subdivide meshes, weld/move vertices, paint per-face materials, or run procedural mesh operations. Triggers: ProBuilder, ProBuilderMesh, mesh modeling, blockout, level geometry, shape, face, edge, vertex, extrude, bevel, chamfer, subdivide, weld, merge, bridge, flip normals, conform normals, project UV, 3D 建模, 建模, 拉伸, 挤出, 倒角, 细分, 焊接, 法线, 面, 边, 顶点, 关卡白模. Requires com.unity.probuilder package; missing-package calls return a diagnostic stub.
- do-not-use-when
- Do not load when Unity Editor is not running locally. Do not load when unity-skills REST server is unreachable at http://localhost:8090.
- task-categories
- [ "mesh-editing", "probuilder", "editor-automation" ]
02 资源文件 1
- 参考文档MODELING_REFERENCE.md5.2 KB
03 SKILL.md 正文
Unity ProBuilder Skills
Use this module for editable ProBuilder meshes, not regular primitive GameObjects. It is best for blockout, level geometry, and procedural mesh refinement.
Requires:
com.unity.probuilderpackage. Batch-first: For scene blockout or level generation, preferprobuilder_create_batchwhen creating2+shapes.
Guardrails
Operating Mode (v1.9 three-tier):
- Approval (default): query skills (e.g.
probuilder_get_info,probuilder_get_vertices) run directly. Create/modify skills are FullAuto — call once, getMODE_RESTRICTED, run the grant protocol; a successful/permission/grantexecutes the skill server-side and returns the result in the same response. - Auto / Bypass: SemiAuto and FullAuto run directly.
- Auto-forbidden in this module:
probuilder_combine_meshes(SkillOperation.Modify | Delete, theDeletebit triggers NeverInSemi). It is callable only under Bypass mode or after the user adds it to the Allowlist; the grant flow returnsMODE_FORBIDDEN. Noteprobuilder_delete_facesisOperation = SkillOperation.Modifyonly and remains grantable under Approval/Auto. - When
com.unity.probuilderis missing, every skill returns a package-missing diagnostic instead of executing.
DO NOT (common hallucinations):
probuilder_create_meshdoes not exist -> useprobuilder_create_shapeprobuilder_edit_facedoes not exist -> use the specific face skills such asprobuilder_extrude_faces,probuilder_delete_faces,probuilder_merge_facesprobuilder_set_materialandprobuilder_set_face_materialare different -> whole object vs selected faces- Regular meshes do not become ProBuilder meshes automatically
- Mesh rebuild calls (
ToMesh()+Refresh()) are already handled by the skills. Do not invent a manual rebuild step
Routing:
- For ordinary primitive objects without editable topology -> use
gameobject_create - For material asset creation or shader work -> use
material - For large blockout generation -> combine this module with
materialandlight, but keep geometry creation here
Object Targeting
Most edit/query skills accept one of:
nameinstanceIdpath
Prefer instanceId when multiple scene objects share the same name.
Skills
Create and Batch
| Skill | Use | Key parameters |
|---|---|---|
probuilder_create_shape |
Create a parametric ProBuilder shape | shape, name?, x/y/z?, sizeX/Y/Z?, rotX/Y/Z? |
probuilder_create_batch |
Create multiple shapes in one call | items, defaultParent? |
Supported shape values: Cube, Sphere, Cylinder, Cone, Torus, Prism, Arch, Pipe, Stairs, Door, Plane.
Face and Edge Editing
| Skill | Use | Key parameters |
|---|---|---|
probuilder_extrude_faces |
Extrude selected faces | target, faceIndexes?, distance?, method? |
probuilder_delete_faces |
Delete faces by index | target, faceIndexes |
probuilder_merge_faces |
Merge faces into one | target, faceIndexes? |
probuilder_flip_normals |
Reverse face direction | target, faceIndexes? |
probuilder_detach_faces |
Split faces from shared vertices | target, faceIndexes?, deleteSourceFaces? |
probuilder_bevel_edges |
Chamfer edges | target, edgeIndexes?, amount? |
probuilder_extrude_edges |
Extrude edges outward | target, edgeIndexes, distance?, extrudeAsGroup? |
probuilder_bridge_edges |
Bridge two edges with new face | target, edgeA, edgeB, allowNonManifold? |
Mesh, Vertex, UV, Material
| Skill | Use | Key parameters |
|---|---|---|
probuilder_subdivide |
Add detail by subdivision | target, faceIndexes? |
probuilder_conform_normals |
Make normals point consistently outward | target, faceIndexes? |
probuilder_move_vertices |
Offset vertices by delta | target, vertexIndexes, deltaX/Y/Z? |
probuilder_set_vertices |
Set absolute vertex positions | target, vertices |
probuilder_get_vertices |
Query vertex positions | target, vertexIndexes?, verbose? |
probuilder_weld_vertices |
Merge close vertices | target, vertexIndexes, radius? |
probuilder_project_uv |
Box-project UVs | target, faceIndexes?, channel? |
probuilder_set_face_material |
Assign material to faces | target, faceIndexes?, materialPath?, submeshIndex? |
probuilder_set_material |
Assign whole-object material or quick color | target, materialPath?, r/g/b/a? |
probuilder_combine_meshes |
Merge multiple meshes | names |
Query and Pivot
| Skill | Use | Key parameters |
|---|---|---|
probuilder_get_info |
Get face/vertex/material stats | target |
probuilder_center_pivot |
Center or reposition pivot | target, worldX/Y/Z? |
Blockout Workflow
- Create major volumes with
probuilder_create_batch. - Verify traversal and gameplay scale before adding detail.
- Refine surfaces with face/edge operations.
- Use vertex edits for ramps, slopes, and irregular silhouettes.
- Apply quick colors or real materials after layout stabilizes.
Minimal Example
import unity_skills
unity_skills.call_skill("probuilder_create_batch", items=[
{"shape": "Cube", "name": "Ground", "sizeX": 20, "sizeY": 0.5, "sizeZ": 12, "y": -0.25},
{"shape": "Cube", "name": "Platform_A", "sizeX": 3, "sizeY": 0.3, "sizeZ": 3, "x": 4, "y": 1.5},
{"shape": "Cube", "name": "Ramp", "sizeX": 3, "sizeY": 1, "sizeZ": 5, "x": 8, "y": 0.5}
])
unity_skills.call_skill("probuilder_move_vertices",
name="Ramp",
vertexIndexes="4,5",
deltaY=-0.8
)
unity_skills.call_skill("probuilder_set_material",
name="Platform_A",
r=0.2, g=0.6, b=1.0
)
Important Notes
- ProBuilder objects keep editable topology through
ProBuilderMesh. - Use
probuilder_get_infobefore face edits andprobuilder_get_verticesbefore vertex edits. - MeshCollider on physics-driven props must be convex.
- Quick color assignment is fine for prototype passes; use material assets for production.
- Package missing errors are expected if ProBuilder is not installed.
Exact Signatures
Exact names, parameters, defaults, and returns are defined by GET /skills/schema or unity_skills.get_skill_schema(), not by this file.
Load MODELING_REFERENCE.md for scene design heuristics, furniture decomposition, detailed examples, and extended modeling tips.
04 同仓库更多 Skills
dots-update-groups
How to choose the right ECS system group and ordering so per-frame and per-fixed-step work is deterministic and never races its own readers. Covers InitializationSystemGroup / SimulationSystemGroup / PresentationSystemGroup / FixedStepSimulationSystemGroup / VariableRateSimulationSystemGroup, UpdateBefore / UpdateAfter peer ordering, OrderFirst / OrderLast group-boundary placement, RateManager, and the cross-group ordering trap. Use when adding an ISystem, fixing "value visible one frame late" bugs, or coupling simulation to a fixed timestep.
dots-transform-patterns
The Entities 1.x transform model — LocalTransform (writable input) vs LocalToWorld (system-owned matrix), Parent/Child hierarchy, reparenting cost, uniform vs non-uniform scale (PostTransformMatrix), and when to opt out with custom transform systems. Use when designing parent/child hierarchies, runtime reparenting (mount/dismount/socket), or choosing transform components at the Baker boundary.
dots-singleton-patterns
Model cross-system shared configuration and game state as a single-entity component with a strict single-writer contract. Covers RequireForUpdate gating, SystemAPI.GetSingleton / GetSingletonRW / HasSingleton / TryGetSingleton, bake-time vs runtime-created vs ECB-system singletons, the "exactly one entity" runtime invariant, and the single-writer rule. Use when designing frame-stable global config, shared mutable state, or any component intended to exist on exactly one entity.
dots-hybrid-bridge
The one-way bridge between DOTS-owned runtime state and Unity-owned presentation. Covers UnityObjectRef for managed asset refs in components, the DOTS-writes / Unity-reads ownership rule, when to use managed IComponentData vs UnityObjectRef vs CompanionComponent, baker-bridge vs runtime-bridge, and SubScene boundary rules. Use when an entity must reference Unity assets (Mesh, Material, AudioClip, ScriptableObject), a MonoBehaviour view must read entity state, or input/UI must trigger ECS work.
dots-event-driven-ecs
Model one-frame events and external requests in ECS without dual ownership, polling, or persistent state leaks. Covers request-tag pattern with ECB, enableable command components (no structural change), event buffers (IBufferElementData), explicit consumer ownership, one-frame latency rules, and the banned C# event / UnityEvent / static bus anti-patterns. Use when input/UI/network must trigger ECS work, when a one-frame signal fans out to N consumers (damage, hit, collision), or when state changes must be processed exactly once.
valid_skill
A complete, well-formed test fixture skill for SkillHub validation testing. Covers basic task routing and code review for Unity projects.