spriteatlas
Skill15 starsChanged 5 months agoMITView on GitHub
Skill for AI agents driving Unity SpriteAtlas assets in a project through the unity-open-mcp MCP server. This domain is embedded in the bridge and opt-in. Its tools use the built-in 2D module (SpriteAtlas / SpriteAtlasAsset / SpriteAtlasPackingSettings / SpriteAtlasTextureSettings in UnityEngine.U2D / UnityEditor.U2D) — no Unity package install is required, and they compile into every bridge build. Its tool group is hidden from ListTools until the connected session activates it. - Unity Editor is open with the target project. -…
In this repository26 other files it gives its agents.
- AGENTS.mdAGENTS.md
- demo/AGENTS.mdAGENTS.md
- hub/AGENTS.mdAGENTS.md
- mcp-server/AGENTS.mdAGENTS.md
- scripts/AGENTS.mdAGENTS.md
- skills/AGENTS.mdAGENTS.md
- animationSkill
- audioSkill
- cinemachineSkill
- constraintsSkill
- input-simulationSkill
- inputsystemSkill
- lightingSkill
- memoryprofilerSkill
- navigationSkill
- particlesystemSkill
- probuilderSkill
- shadergraphSkill
- splinesSkill
- terrainSkill
- textureSkill
- tilemapSkill
- timelineSkill
- uiSkill
- vfxSkill
- unity-open-mcpSkill
The file
We split this skill into the rules it gives an agent
1 rule. About 0 are common, 0 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈0
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 148
Every mutating tool requires a non-empty paths_hint scoped to the .spriteatlas asset path — the gate has no whole-project fallback.
≈ “Common” is an estimate: at least 1 in 5 of the 213,895 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Unity Open MCP — SpriteAtlas Extension
Skill for AI agents driving Unity SpriteAtlas assets in a project through the
unity-open-mcp MCP server.
This domain is embedded in the bridge and opt-in. Its tools use the built-in 2D module (
SpriteAtlas/SpriteAtlasAsset/SpriteAtlasPackingSettings/SpriteAtlasTextureSettingsinUnityEngine.U2D/UnityEditor.U2D) — no Unity package install is required, and they compile into every bridge build. Its tool group is hidden fromListToolsuntil the connected session activates it.
Preconditions
- Unity Editor is open with the target project.
unity_open_mcp_pingreturnsconnected: true.- The
sprite2dtool group is activated — callunity_open_mcp_manage_tools(action="activate", group="sprite2d")before invoking any SpriteAtlas (or Texture) tool. Fresh sessions start with two default-on groups (coreandgate-and-verify); activate the other groups you need on demand. Because the 2D module is built-in,capabilitiesalways reports thesprite2dgroup asavailable: true(nodomainDefine).
Tool prefix
unity_open_mcp_spriteatlas_* — SpriteAtlas authoring. The sprite2d group
is shared with the Texture import family (unity_open_mcp_texture_*); see the
Texture extension skill for the import half of the 2D art pipeline.
Mutating tools accept the standard paths_hint and run the full gate path
(editor_settle lifecycle — the .spriteatlas asset is written and
reimported); read-only tools (spriteatlas_get, spriteatlas_list) are
gate-free.
Authoring model
A .spriteatlas file stores a SpriteAtlasAsset (the authoring object); the
runtime SpriteAtlas is the packed artifact produced from it. These tools
author via SpriteAtlasAsset.Load / Save and mutate packables via Add /
Remove. Packables are Object references (Sprite / Texture /
DefaultAsset folder); they are resolved by Assets/-rooted path and
reported back by path + type so you can round-trip without instance ids.
Canonical workflow: build an atlas
- Create —
unity_open_mcp_spriteatlas_createwithasset_path: "Assets/Atlases/UI.spriteatlas"(intermediate folders are created).include_in_builddefaults to true. - Add packables —
unity_open_mcp_spriteatlas_add_packablewithpackable_paths: ["Assets/Sprites/Icons", "Assets/Textures/Icon.png"]. Folders add every sprite inside; individual textures add themselves. Per-path errors are accumulated (a bad path does not abort the batch). - Tune settings —
unity_open_mcp_spriteatlas_modifywith asettings_jsonpatch (see below). - Verify —
unity_open_mcp_spriteatlas_get(gate-free) reads the packables + packing/texture/platform settings back. - Iterate —
unity_open_mcp_spriteatlas_remove_packableto drop a packable;spriteatlas_modifyto retune.
Settings patch (spriteatlas_modify)
settings_json is a JSON object string with three optional sub-objects:
{
"include_in_build": false,
"packing": {
"padding": 4,
"enableRotation": true,
"enableTightPacking": false,
"enableAlphaDilation": false,
"blockOffset": 0
},
"texture": {
"anisoLevel": 1,
"filterMode": "Bilinear",
"generateMipMaps": false,
"readable": false,
"sRGB": true
}
}Unknown fields are reported in unknownFields and do not abort the patch.
texture.maxTextureSize is not settable here (no setter on the settings
struct; controlled via platform settings).
Persistence note: in this Unity version the packing and texture settings are applied to the in-memory
SpriteAtlasAsset(they take effect for the next pack) but are not written to the.spriteatlasfile's serialized form — Unity manages them via the internal Sprite Atlas packing pipeline, not the publicSavepath.include_in_buildlikewise does not round-trip through the serialized file. The settings are session-scoped; for permanent settings, use the Unity Editor's Sprite Atlas panel.
Listing atlases
unity_open_mcp_spriteatlas_list (gate-free) lists every .spriteatlas
under a folder (omit folder to search the whole project). Each entry
reports path + name. Cap 200; truncated reports the overflow.
Layered with Texture import
The sprite2d group covers atlas packing (this skill). It pairs with the
Texture import family (unity_open_mcp_texture_*) for the import side —
use texture_set_import to mark a texture as a Sprite (sprite_mode:
"Single") before adding it to an atlas.
Common recipes
UI icon atlas
texture_set_importon each icon PNG withsettings_json: '{"sprite_mode":"Single","sprite_pixels_per_unit":100}'(switchestextureTypeto Sprite).spriteatlas_createatAssets/Atlases/UIIcons.spriteatlas.spriteatlas_add_packablewithpackable_paths: ["Assets/Sprites/UI"](the folder).spriteatlas_modifywithsettings_json: '{"packing":{"padding":4}}'.spriteatlas_getto confirm.
Swap an atlas's contents
spriteatlas_getto read the current packables.spriteatlas_remove_packablewith the old paths.spriteatlas_add_packablewith the new paths.
Agent-sense pairing
unity_senses_screenshot(view:"game") visually confirms the packed atlas renders correctly in a UI scene.unity_open_mcp_texture_get_importerreads a packable texture's import config (e.g. confirmspriteImportModebefore adding to the atlas).
Tool reference
| Tool | Mutating | Lifecycle | Notes |
spriteatlas_create | yes | editor_settle | Creates intermediate folders. |
spriteatlas_get | no | none | Packables + settings (read-only). |
spriteatlas_add_packable | yes | editor_settle | Per-path errors accumulated. |
spriteatlas_remove_packable | yes | editor_settle | Matched by asset path. |
spriteatlas_modify | yes | editor_settle | settings_json patch; unknown fields reported. |
spriteatlas_delete | no | editor_settle | Destructive — no undo across restart. |
spriteatlas_list | no | none | Cap 200 (read-only). |
Every mutating tool requires a non-empty paths_hint scoped to the
.spriteatlas asset path — the gate has no whole-project fallback.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

