reflection-method-call

Invokes C# methods in Unity projects via reflection with serialized parameters.

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

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires unity-mcp-cli.

What problem does it solve? Calling C# methods inside a Unity project normally requires writing and compiling test code, which slows down debugging and automation. This Skill lets you invoke any method, including private ones, directly through the unity-mcp-cli tool with structured JSON input. ## Core Features & Use Cases - Reflection-Based Invocation: Call any C# method, including private and static methods, without modifying project code. - Flexible Method Matching: Configure match levels for namespace, type name, method name, and parameters to target the exact overload. - Serialized Input and Output: Pass typed input parameters and receive the return value as a structured SerializedMember JSON object. - Use Case: While debugging a Unity scene, invoke a private SaveGame method on a GameManager instance with specific arguments to verify its behavior without adding temporary test code. ## Quick Start Ask the AI to call a specific C# method in your Unity project by providing the class name, method name, and input parameters through the reflection-method-call tool.

Frequently Asked Questions about reflection-method-call

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

FAQPage Schema
How do I call a private C# method in Unity without modifying code?

Use the reflection-method-call tool with a filter specifying the type name and method name. Reflection allows invoking private methods directly, and you supply input parameters as serialized JSON with full type names.

How to pass parameters when calling a C# method via reflection?

Provide inputParameters as a list of serialized members, each with a typeName (full type like System.String or UnityEngine.Vector3), a name, and a value. The value is deserialized to the specified type before invocation.

Can reflection-method-call invoke static methods in Unity?

Yes, static methods are supported. Set targetObject to null when calling a static method, since no instance is required. For instance methods, either provide a targetObject or let a new instance be created.

What should I do before using reflection-method-call?

Use the reflection-method-find skill first to discover available methods and their exact signatures. This ensures the filter and parameter schema you pass to reflection-method-call match an actual method in the codebase.

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. Refer to the unity-initial-setup skill for detailed installation instructions.