Agent skill

Unity UI

by Besty0728 in Besty0728/Unity-Skills

“Create and lay out Unity UGUI screens”

— description from SKILL.md by Besty0728
MITAuto-check passedGame Development

Install Unity UI

skills CLI
$ npx skills add Besty0728/Unity-Skills --skill unity-ui -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install Besty0728/Unity-Skills unity-ui --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/Besty0728/Unity-Skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/'SkillsForUnity/unity-skills~/skills/ui' .claude/skills/unity-ui && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
unity-ui
GitHub stars
1.8k
Token cost
~3k tokens
SKILL.md length
1,119 words
Files
2
Skills in repo
82
Repo updated
First seen
Licence
MIT

At a glance

  • Works in 8 steps: Create a Canvas first. → Use panels to group related controls. → Prefer ui_create_batch for menus, HUD… → …
  • SKILL.md covers Triggers, Operating Mode, Skills and High-Frequency Defaults, plus 4 more sections
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

About this skill

Unity UI is a skill in Besty0728/Unity-Skills (1.8k stars). Its SKILL.md is about 3k tokens, with 1 other file in the folder. Licence: MIT.

Workflow steps

8 steps, taken from the first numbered list in SKILL.md.

  1. Create a Canvas first.
  2. Use panels to group related controls.
  3. Prefer ui_create_batch for menus, HUD groups, and repeated widgets.
  4. Use anchors and layout groups before hand-placing every child.
  5. Text creation auto-detects TextMeshPro. Responses indicate whether TMP was used.
  6. For world-space gameplay UI, build the Canvas here first, then convert for XR only if needed.
  7. ui_create_batch is mainly for bulk creation, not precise positioning. Follow it with layout or rect/anchor adjustments.
  8. ui_create_batch.items is a JSON string parameter in the current REST/API layer, not a raw array object.

What it can do on your machine

Read from SKILL.md and the folder at commit ec8aa7c. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are python).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Unity UI loads about 3k tokens when it runs. Until then it costs about 12 tokens; SKILL.md has 1,119 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~12
When it runs · the whole SKILL.md, loaded when a task matches
~3k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from Besty0728/Unity-Skills at commit ec8aa7c, republished under its MIT licence (© Besty0728). 1,119 words, ~2,963 tokens.

Download SKILL.mdSave it as .claude/skills/unity-ui/SKILL.md (or your agent's skills folder). This skill also uses 1 other file; get the full folder from GitHub.
name
unity-ui
description
Create and lay out Unity UGUI screens

Before calling any skill in this module: if you are about to call a skill with parameters guessed from its name or description, STOP — read this file (or fetch its schema via GET /skills/recommend?includeSchema=true) first. If you already have the parameter definitions from recommend/schema, you may proceed straight to dryRun.

Triggers

  • Building UGUI screens
  • Adding Canvas elements
  • Arranging UI layout
  • 搭建 UGUI 界面、添加 Canvas 元素、排布 UI 布局

Unity UI Skills

Use this module for Unity UGUI / Canvas workflows. It is separate from UI Toolkit.

Batch-first: Prefer ui_create_batch when creating 2+ UI elements.

Operating Mode

  • Approval:查询类 skill(ui_find_all,源码标 SkillMode.SemiAuto)直接执行;其余创建/修改类(ui_create_* / ui_set_* / ui_add_* / ui_layout_children / ui_align_selected 等,标 SkillMode.FullAuto)需用户 grant,grant 后服务端一步执行返结果。
  • Auto / Bypass:所有 skill 直接执行;Auto 走 AI 自我评估,Bypass 全放行。
  • 本模块不含 Delete / PlayMode / Reload / 高危 skill,无 Bypass-only 拦截项。删除 UI 节点请走 gameobject 模块。

DO NOT (common hallucinations):

  • ui_add_canvas does not exist -> use ui_create_canvas
  • ui_create_label does not exist -> use ui_create_text
  • ui_create_checkbox does not exist -> use ui_create_toggle
  • ui_set_color does not exist -> use component_set_property on Image/Text, or the dedicated UI property skills when available
  • Do not confuse UGUI (ui) with UI Toolkit (uitoolkit)

Routing:

  • For UXML/USS/UIDocument -> use uitoolkit
  • For XR-compatible world-space Canvas conversion -> use xr_setup_ui_canvas
  • For text updates after creation -> use ui_set_text
  • For layout and alignment -> use ui_layout_children, ui_align_selected, ui_distribute_selected

Skills

Create Skills
SkillUseKey parameters
ui_create_canvasCreate Canvasname?, renderMode?
ui_create_panelCreate panel containername?, parent?, r/g/b/a?
ui_create_buttonCreate buttonname?, parent?, text?, width/height?
ui_create_textCreate text labelname?, parent?, text?, fontSize?, r/g/b?
ui_create_imageCreate imagename?, parent?, spritePath?, width/height?
ui_create_inputfieldCreate input fieldname?, parent?, placeholder?, width/height?
ui_create_sliderCreate slidername?, parent?, minValue?, maxValue?, value?
ui_create_toggleCreate togglename?, parent?, label?, isOn?
ui_create_dropdownCreate dropdownname?, parent?, options?, width/height?
ui_create_scrollviewCreate ScrollRect hierarchyname?, parent?, width/height?, horizontal?, vertical?
ui_create_rawimageCreate RawImagename?, parent?, texturePath?, width/height?
ui_create_scrollbarCreate scrollbarname?, parent?, direction?, value?, size?
ui_create_batchCreate multiple UI elementsitems (JSON string array)
Query and Layout Skills
SkillUseKey parameters
ui_find_allFind scene UI elementsuiType?, limit?
ui_set_textUpdate text contentname, text
ui_set_rectSet RectTransform size/offsetstarget, width, height, posX, posY, left/right/top/bottom?
ui_get_rect_transformRead full RectTransform datatarget
ui_set_rect_transformSet full RectTransform dataanchors, pivot, offsets, local transform, width/height
ui_set_rect_transform_batchSet full RectTransform data for multiple elementsitems
ui_set_anchorApply anchor presettarget, preset?, setPivot?
ui_layout_childrenVertical/Horizontal/Grid layouttarget, layoutType?, spacing?
ui_align_selectedAlign current selectionalignment?
ui_distribute_selectedDistribute current selectiondirection?
Property and Effect Skills
SkillUseKey parameters
ui_set_imageImage type/fill/spritetarget, type?, fillMethod?, fillAmount?, spritePath?
ui_add_layout_elementAdd LayoutElement constraintstarget, width/height prefs, flex values
ui_add_canvas_groupAdd CanvasGrouptarget, alpha?, interactable?, blocksRaycasts?
ui_add_maskAdd Mask or RectMask2Dtarget, maskType?, showMaskGraphic?
ui_add_outlineAdd Shadow/Outline effecttarget, effectType?, r/g/b/a?, distanceX/Y?
ui_configure_selectableConfigure transitions/navigation/colorstarget, transition?, navigationMode?, color values

High-Frequency Defaults

Canvas and Parenting
  • ui_create_canvas defaults to ScreenSpaceOverlay.
  • Most create skills accept parent; if omitted, Unity will create under the active Canvas or scene root depending on the implementation context.
  • For reusable menu groups, create the Canvas once, then create a Panel and put all child controls under that panel.
Common Create Parameters
SkillHigh-frequency fields
ui_create_buttontext, width, height
ui_create_texttext, fontSize, r/g/b
ui_create_imagespritePath, width, height
ui_create_sliderminValue, maxValue, value
ui_create_togglelabel, isOn
ui_create_dropdownoptions
ui_create_scrollviewhorizontal, vertical, movementType

Important:

  • Most create skills do not take explicit x/y placement.
  • Create first, then place/anchor with ui_set_rect, ui_set_anchor, or ui_layout_children.
Full RectTransform Editing

Use ui_set_rect_transform when you need Inspector-level RectTransform coverage instead of a preset.

SkillParameters
ui_get_rect_transformname, instanceId, path
ui_set_rect_transformtarget + anchorMinX/Y, anchorMaxX/Y, pivotX/Y, anchoredPosX/Y/Z, sizeDeltaX/Y, offsetMinX/Y, offsetMaxX/Y, localPosX/Y/Z, localRotX/Y/Z, localScaleX/Y/Z, width, height
ui_set_rect_transform_batchitems JSON array with the same per-target fields
ui_get_rect_transform

Get full RectTransform data for a UI element.

ParameterTypeRequiredDefaultDescription
namestringNo*nullGameObject name
instanceIdintNo*0GameObject instance ID
pathstringNo*nullHierarchy path

Returns: { success, name, instanceId, path, anchorMin, anchorMax, pivot, anchoredPosition3D, sizeDelta, offsetMin, offsetMax, localPosition, localEulerAngles, localScale, rect }

Show full SKILL.md (485 more words)Show less
ui_set_rect_transform

Set full RectTransform data for a UI element.

ParameterTypeRequiredDefaultDescription
namestringNo*nullGameObject name
instanceIdintNo*0GameObject instance ID
pathstringNo*nullHierarchy path
anchorMinX / anchorMinYfloatNonullAnchor min
anchorMaxX / anchorMaxYfloatNonullAnchor max
pivotX / pivotYfloatNonullPivot
anchoredPosX / anchoredPosY / anchoredPosZfloatNonullAnchored position 3D
sizeDeltaX / sizeDeltaYfloatNonullSize delta
offsetMinX / offsetMinYfloatNonullOffset min
offsetMaxX / offsetMaxYfloatNonullOffset max
localPosX / localPosY / localPosZfloatNonullLocal position
localRotX / localRotY / localRotZfloatNonullLocal euler rotation
localScaleX / localScaleY / localScaleZfloatNonullLocal scale
width / heightfloatNonullSize with current anchors

Returns: same shape as ui_get_rect_transform.

ui_set_rect_transform_batch

Set full RectTransform data for multiple UI elements.

ParameterTypeRequiredDefaultDescription
itemsjson stringYes-JSON array of per-item target and RectTransform fields

Returns: { success, totalItems, successCount, failCount, results }

Layout and Anchoring Rules
  • ui_set_anchor is the fastest way to move a control into a standard layout position.
  • ui_set_rect is better for precise size/offset edits after anchoring.
  • ui_layout_children is preferred over hand-positioning every child when building vertical, horizontal, or grid menus.

Anchor presets commonly used in production:

  • MiddleCenter for modal/menu panels
  • TopLeft or TopRight for HUD corners
  • StretchAll for full-screen backgrounds
TextMeshPro Note

Text creation auto-detects TMP:

  • TMP available -> TextMeshProUGUI
  • TMP unavailable -> legacy Text

Read the response payload if you need to know which one was created before later component-specific edits.

Workflow Notes

  1. Create a Canvas first.
  2. Use panels to group related controls.
  3. Prefer ui_create_batch for menus, HUD groups, and repeated widgets.
  4. Use anchors and layout groups before hand-placing every child.
  5. Text creation auto-detects TextMeshPro. Responses indicate whether TMP was used.
  6. For world-space gameplay UI, build the Canvas here first, then convert for XR only if needed.
  7. ui_create_batch is mainly for bulk creation, not precise positioning. Follow it with layout or rect/anchor adjustments.
  8. ui_create_batch.items is a JSON string parameter in the current REST/API layer, not a raw array object.

Minimal Example

python
import unity_skills
import json

unity_skills.call_skill("ui_create_canvas", name="MainMenu")
unity_skills.call_skill("ui_create_panel", name="MenuPanel", parent="MainMenu", a=0.7)
unity_skills.call_skill("ui_set_rect", name="MenuPanel", width=320, height=240)
unity_skills.call_skill("ui_create_batch", items=json.dumps([
    {"type": "Button", "name": "StartBtn", "parent": "MenuPanel", "text": "Start", "width": 220, "height": 44},
    {"type": "Button", "name": "OptionsBtn", "parent": "MenuPanel", "text": "Options", "width": 220, "height": 44},
    {"type": "Button", "name": "QuitBtn", "parent": "MenuPanel", "text": "Quit", "width": 220, "height": 44}
]))

unity_skills.call_skill("ui_set_anchor", name="MenuPanel", preset="MiddleCenter")
unity_skills.call_skill("ui_layout_children", name="MenuPanel", layoutType="Vertical", spacing=12)

Exact Signatures

Exact names, parameters, defaults, and returns are defined by GET /skills/schema or unity_skills.get_skill_schema(), not by this file. Load UI_REFERENCE.md for extended element creation details, property tables, and larger UGUI examples.

Common Errors

Full transport-level codes (COMPILING/RATE_LIMIT etc.) → ../../references/protocol-error-codes.md

ErrorTriggerFix
TARGET_NOT_FOUNDThe parent GameObject, UI element, RectTransform, Text/Image/Selectable component, or sprite asset could not be found.Use ui_find_all, gameobject_find, or scene_get_hierarchy to locate the element, and verify sprite paths with asset_find.
SEMANTIC_INVALIDAn invalid value was supplied, such as an unknown anchor preset, layout type, alignment, or name/path with separators.Choose a valid preset/type from the error context (e.g., MiddleCenter, Vertical, TopLeft) and retry.
SKILL_ERRORA selection-based operation failed because fewer than the required number of UI elements were selected (e.g., Select at least 2 UI elements).Select the required UI elements in the Hierarchy before calling alignment/distribution skills.

© Besty0728, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 1 other file in SkillsForUnity/unity-skills~/skills/ui of Besty0728/Unity-Skills.

  • SKILL.md
  • UI_REFERENCE.md

Open the folder on GitHubat commit ec8aa7c

Compare with similar skills

Unity UI next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Unity UI compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Unity UI this skillBesty0728/Unity-Skills1.8k—~3kAutomated safety check: PassMIT
Image to Three.js Modelimg2threejs/img2threejs18k1 repos~8.2kAutomated safety check: PassApache-2.0
Web CloneJane-xiaoer/claude-skill-web-clone1k2 repos~2.7kAutomated safety check: PassMIT
Threejs Game Directormajidmanzarpour/threejs-game-skills2.4k—~2.2kAutomated safety check: PassMIT
Game Asset Generatorhtdt/godogen7.1k—~2.8kAutomated safety check: PassMIT
Threejs Gameplay Systemsvalkor-ai/loom1.2k1 repos~1.4kAutomated safety check: PassApache-2.0

Similar skills

  • Image to Three.js Model

    img2threejs/img2threejs

    Rebuilds the object in a reference image as a procedural, animation-ready Three.js model written entirely in code, using staged sculpting with quality checks.

    18k GitHub starsUsed in 1 repo~8.2k tokens
    Game DevelopmentAuto-check passed
  • Web Clone

    Jane-xiaoer/claude-skill-web-clone

    网站复刻 / 克隆方法论。USE WHEN 用户说 复刻网站、克隆网站、clone website、抄个站、仿站、 照着这个站做一个、reproduce site、还原某个网页效果、把这个站搬下来改成我的、 复刻某个交互/WebGL/Canvas/Three.js 效果。提供「先拿真源码 → 判路径 → 逆向拆解 → 搭工程 → 替换内容」的可移植决策树,覆盖静态站 /…

    1k GitHub starsUsed in 2 repos~2.7k tokens
    Game DevelopmentAuto-check passed
  • Threejs Game Director

    majidmanzarpour/threejs-game-skills

    Entrypoint for building, upgrading, and finishing Three.js browser games.

    2.4k GitHub stars~2.2k tokensUpdated 10 days ago
    Game DevelopmentAuto-check passed
  • Generates game art from text prompts: PNG images, GLB 3D models, rigged characters, animations and sprites, with background removal.

    7.1k GitHub stars~2.8k tokensUpdated 6 days ago
    Game DevelopmentAuto-check passed
  • Build and iterate playable Three.js game systems: starter scaffold, architecture, design briefs, core loops, level and encounter design, entities, input, camera, collision and physics, scoring…

    1.2k GitHub starsUsed in 1 repo~1.4k tokens
    Game DevelopmentAuto-check passed
  • Uloop Execute Dynamic Code

    CyberAgentGameEntertainment/NovaShader

    Execute C with Unity APIs when existing uloop tools cannot inspect or edit enough.

    1.6k GitHub starsUsed in 1 repo~1.9k tokens
    Game DevelopmentAuto-check passed

More from Besty0728/Unity-Skills

All 82 skills in this repo
  • Unity Skills

    Besty0728/Unity-Skills

    Automate the Unity Editor through a local REST API — scripts, scenes, prefabs, assets, materials, lighting, tests and hundreds of other Editor operations.

    1.8k GitHub stars~2k tokensUpdated yesterday
    Auto-check passed
  • Unity Animator

    Besty0728/Unity-Skills

    Edit Unity Animator Controllers and drive runtime parameters

    1.8k GitHub stars~2.4k tokensUpdated yesterday
    Auto-check passed
  • Unity Architecture

    Besty0728/Unity-Skills

    Advise on Unity gameplay and system architecture. An agent skill from Besty0728/Unity-Skills.

    1.8k GitHub stars~1.3k tokensUpdated yesterday
    Auto-check passed
  • Unity Batch

    Besty0728/Unity-Skills

    Unified batch and async-job orchestration. An agent skill from Besty0728/Unity-Skills.

    1.8k GitHub stars~2k tokensUpdated yesterday
    Auto-check passed
  • Unity Behavior

    Besty0728/Unity-Skills

    Drive Unity Behavior behavior graphs and blackboard variables

    1.8k GitHub stars~3k tokensUpdated yesterday
    Auto-check passed
  • Unity Console

    Besty0728/Unity-Skills

    Capture and query the Unity Editor console. An agent skill from Besty0728/Unity-Skills.

    1.8k GitHub stars~1.8k tokensUpdated yesterday
    Auto-check passed

Questions about Unity UI

How do I install Unity UI in Claude Code?

Run `npx skills add Besty0728/Unity-Skills --skill unity-ui -a claude-code`. Or copy the skill folder (SkillsForUnity/unity-skills~/skills/ui in Besty0728/Unity-Skills) into .claude/skills/unity-ui in your project. Claude Code loads it when a task matches its description.

How do I install Unity UI in Codex?

Run `npx skills add Besty0728/Unity-Skills --skill unity-ui -a codex`. Or copy the skill folder (SkillsForUnity/unity-skills~/skills/ui in Besty0728/Unity-Skills) into .agents/skills/unity-ui in your project. Codex loads it when a task matches its description.

Can I use Unity UI in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add Besty0728/Unity-Skills --skill unity-ui -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/unity-ui, .gemini/skills/unity-ui, .github/skills/unity-ui and .opencode/skills/unity-ui in your project.

What does Unity UI need to run?

SKILL.md names no scripts, command-line tools or credentials: Unity UI is instructions for the agent only.

Does Unity UI access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Unity UI safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Unity UI use?

Unity UI is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Unity UI use?

About 3k tokens (SKILL.md is roughly 12k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Unity UI?

Skills that share tags, products or a category with Unity UI: Image to Three.js Model (img2threejs/img2threejs, 18k stars), Web Clone (Jane-xiaoer/claude-skill-web-clone, 1k stars), Threejs Game Director (majidmanzarpour/threejs-game-skills, 2.4k stars) and Game Asset Generator (htdt/godogen, 7.1k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Unity UI?

Besty0728 (a GitHub user) maintains it in Besty0728/Unity-Skills, which has 1,815 GitHub stars. The repository holds 82 skills in this directory. The repository was last updated on October 7, 2026.

Source: Besty0728/Unity-Skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.