协作头脑风暴
brainstorming
在实现前澄清需求、探索设计选择,并形成清晰的开发方向。
umg-material-mcp【开发与工程】Use when Codex needs to create, inspect, edit, delete, or validate UE5.8 material assets through Unreal Motion Graphics MCP/FabUmgMcp HLSL material tools, especially one-HLSL Custom-node authoring, UI-default versus non-UI material type selection, union-only writes, semantic outputs, hlsl_delete recovery, or Material ToolMode protocol work.
独立 GitHub 快照 · 自动分类 · 以原作者文档为准
Use the Material HLSL MCP path for material authoring. Do not mutate .uasset files directly. Keep Unreal Editor open with the UMG MCP bridge listening before runtime tool calls.
For concrete command examples and regression cases, read demo-cases.md.
Set or create the HLSL target with hlsl_set_target.
hlsl_set_target: domain, blend_mode, shading_model, two_sided.material_modify_type; that command is compatibility-only.Read with hlsl_get.
output_contract.Write with hlsl_set(hlsl?, parameters?, outputs?).
hlsl_set is union-only: update existing entries and append missing entries.parameters for Custom node inputs such as {"name":"Intensity","kind":"Scalar"}.outputs for root material outputs such as "Roughness", "Metallic", "Normal", or objects with name, target, and type.AdditionalOutputs; assign same-name variables in HLSL, for example Roughness = 0.35;.Delete with hlsl_delete(names, confirm_delete=true, kind?).
kind in the normal path.requires_kind: true; retry with kind="parameter" or kind="output".hlsl_delete_parameter or hlsl_delete_output in primary flows; they are compatibility aliases.Compile with hlsl_compile.
hlsl_set(hlsl=...) rather than resetting the target.float4.output_contract describes where rgb/a and any additional outputs are wired.EmissiveColor; lit Surface output rgb usually maps to BaseColor.Opacity, masked to OpacityMask.material_* graph editing unless the requested operation cannot be modeled by HLSL target, parameters, outputs, delete, and compile.Use the narrowest relevant checks:
python -m py_compile Resources\Python\UmgMcpServer.py Resources\Python\Material\UMGMaterial.py Resources\Python\APITest\Material_HLSL_Type_Demo.py Resources\Python\APITest\Material_Protocol_Static_Check.py
python Resources\Python\APITest\Material_Protocol_Static_Check.py
& 'D:\UE_5.8\Engine\Build\BatchFiles\Build.bat' FabUMGMCPEditor Win64 Development -Project='D:\UE5Project\FabUMGMCP\FabUMGMCP.uproject' -NoHotReloadFromIDE -Progress
python Resources\Python\APITest\Material_HLSL_Type_Demo.py
The runtime demo requires Unreal Editor to be open and the MCP socket in Resources/Python/mcp_config.py to be reachable.