gameobject-component-modify

Modifies fields and properties of a Component on a Unity GameObject via unity-mcp-cli.

1|Updated Apr 1, 2026
One-click install
npx skills add https://github.com/Fermisloth/Project-Aegis-Adaptive-Outbreak-Containment --skill gameobject-component-modify-fermisloth
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: gameobject-component-modify
Source: https://github.com/Fermisloth/Project-Aegis-Adaptive-Outbreak-Containment/tree/main/.agent/skills/gameobject-component-modify
Command: npx skills add https://github.com/Fermisloth/Project-Aegis-Adaptive-Outbreak-Containment --skill gameobject-component-modify-fermisloth

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires unity-mcp-cli.

What problem does it solve? Editing individual Component values on Unity GameObjects normally requires manual work in the Unity Editor Inspector. This Skill lets you programmatically modify specific fields and properties of a Component in an opened Prefab or active Scene through the unity-mcp-cli tool. ## Core Features & Use Cases - Targeted Component Modification: Apply partial diffs containing only the fields or properties you want to change, without rewriting the whole GameObject structure. - Flexible Referencing: Locate GameObjects by instanceID, hierarchy path, name, or asset GUID, and Components by index, type name, or instanceID. - Structured Feedback: Receive a response indicating success, the updated component info, and logs of applied changes plus any invalid fields. - Use Case: Adjust a Light component's intensity and color on a scene GameObject, or update a RectTransform's anchored position in a prefab, directly from an AI-driven workflow. ## Quick Start Ask the AI to modify a specific component property on a named GameObject in the active Unity scene, for example changing the Transform position of the Player object.

Frequently Asked Questions about gameobject-component-modify

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

FAQPage Schema
How do I modify a component on a Unity GameObject from the command line?

Run unity-mcp-cli with the gameobject-component-modify tool, passing a gameObjectRef, componentRef, and componentDiff JSON payload. The diff only needs the fields or properties you want to change, and the response reports success plus any invalid entries.

How do I reference a GameObject and Component in Unity MCP?

GameObjects can be referenced by instanceID, hierarchy path, name, asset path, or asset GUID, with instanceID taking priority. Components are referenced by index, full type name like UnityEngine.Transform, or instanceID.

Should I inspect the component before modifying it in Unity?

Yes, use the gameobject-component-get skill first to inspect the component's structure. This reveals the exact field and property names so your componentDiff only includes valid entries, since unknown fields are reported in the response logs.

What happens if I pass invalid fields in componentDiff?

Unknown or invalid fields and properties are not applied silently; they are reported in the Logs array of the response. The valid modifications still apply, and the Success flag indicates the overall result.

Why is unity-mcp-cli not found when running the command?

The CLI must be installed globally with npm install -g unity-mcp-cli, or invoked via npx unity-mcp-cli. The unity-initial-setup skill contains detailed installation instructions.