unity-material

Edit Unity material and shader properties across Built-in, URP, and HDRP render pipelines.

Updated Jun 21, 2026
One-click install
npx skills add https://github.com/du-qwq/Shader-Writing-Architecture-and-Specifications --skill unity-material-du-qwq
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: unity-material
Source: https://github.com/du-qwq/Shader-Writing-Architecture-and-Specifications/tree/main/.agents/skills/unity-skills/skills/material
Command: npx skills add https://github.com/du-qwq/Shader-Writing-Architecture-and-Specifications --skill unity-material-du-qwq

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Changing how objects look in Unity requires repetitive manual edits of material colors, textures, floats, keywords, and shaders in the editor, which becomes tedious when working across multiple render pipelines or many objects at once. ## Core Features & Use Cases - Material Property Editing: Set colors, emission, textures, floats, ints, vectors, keywords, render queue, and GI flags with automatic render pipeline detection (Built-in/URP/HDRP). - Batch Operations: Create, assign, and recolor materials on multiple objects in a single call using material_create_batch, material_assign_batch, and material_set_colors_batch. - Shader & Query Tools: Swap shaders, duplicate material assets, and inspect all properties or enabled keywords on any material. - Use Case: You need three colored materials assigned to three cubes. Instead of six individual calls, use one batch create, one batch color set, and one batch assign to finish the whole setup in three calls. ## Quick Start Create a red URP material saved to Assets/Materials and assign it to the GameObject named Cube.

Frequently Asked Questions about unity-material

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I change a material color in Unity with a script?

Use material_set_color with the GameObject name or material asset path, providing r, g, b values in the 0-1 range. The color property name is auto-detected based on your render pipeline, or you can pass propertyName explicitly.

How to set metallic or smoothness on a Unity material?

There is no dedicated metallic or smoothness setter. Use material_set_float with propertyName "_Metallic" or "_Glossiness" for the Standard shader, or "_Smoothness" for URP, along with the desired float value.

Does this work with URP and HDRP materials?

Yes, all material skills auto-detect the active render pipeline and adapt property names accordingly. Built-in uses _Color and _MainTex, URP uses _BaseColor and _BaseMap, and HDRP uses _BaseColor and _BaseColorMap.

How do I edit materials on many objects at once in Unity?

Use the batch variants: material_create_batch, material_assign_batch, material_set_colors_batch, and material_set_emission_batch. Each accepts a JSON array of per-item objects and returns per-item success results, reducing multiple operations to one call.

Why does material_set_color not change my material?

Color values must be in the 0-1 range, not 0-255. Also verify the propertyName matches your shader, since URP and HDRP use _BaseColor instead of _Color, and check that the target path points to the correct GameObject or .mat asset.

Can I delete a material asset with this module?

No, this module contains no delete operations. To delete a material asset, use the separate asset module, which handles asset deletion and other high-risk file operations.