unity-script

Installation
SKILL.md

When to use

  • Authoring or editing C# code
  • Searching across scripts
  • Refactoring file layout
  • Checking compile errors

Unity Script Skills

Create, edit, move and inspect C# scripts and get their compile result. Parameters come from the schema (recommend includeSchema=true or /skills/schema?names=), which notes the non-obvious ones — never from a skill's name. Execution and dryRun rules: root SKILL.md.

Rules

  • All seven writers (script_create, script_create_batch, script_replace, script_append, script_rename, script_move, script_delete) trigger a domain reload and are high-risk, so Approval and Auto refuse them with MODE_FORBIDDEN. Do not request a grant for them.

Compile and reload

  • Every write returns at once: {success, status: "accepted", path, jobId, waitUrl, serverAvailability}; compilation follows, and the server is briefly unreachable during the domain reload.
  • One call gets the compile result: GET the returned waitUrl (/jobs/<jobId>?wait=90&expectInstance=<instanceId>, already pinned to this Editor), adding expectProject, e.g. curl -s --retry 20 --retry-connrefused --retry-all-errors --retry-delay 2 "http://localhost:<port><waitUrl>&expectProject=<project>". It answers once compilation settles: job status completed, or failed on compile errors, with diagnostics in resultData.compilation (isCompiling, hasErrors, errorCount, errors: [{type, message, file, line}]). During the reload it may refuse or return 503: repeat the same URL; waitTimedOut: true means GET it again.
  • script_get_compile_feedback(scriptPath) returns the same diagnostics on demand. Fix errors first: component_add finds a new MonoBehaviour only after a clean compile.
  • checkCompile: false skips the diagnostics; diagnosticLimit caps them (default 20).
Installs
90
GitHub Stars
1.9K
First Seen
Mar 14, 2026