
wilson520403/fgui-agent-bridge
Developer toolsThis page was translated automatically. Technical details may differ from the original. View the original
Safely operate FairyGUI Editor via MCP, CLI, and local JSON queues
Overview
Through MCP (Model Context Protocol) or CLI, AI programming agents (such as Cursor, Claude, Codex, VS Code, etc.) can directly operate FairyGUI Editor using structured instructions, enabling automatic UI creation, animation creation, and one-click publishing. - :0.8.1 - :1.0 - :6.1.4 - :Local JSON queue + MCP Stdio :Bridge repository and business FairyGUI projects are stored separately. FairyGUI projects only need to install lightweight plugins; Skill can be installed on demand in the host IDE to improve AI operation accuracy. After installation, enter a command like the following directly in the AI dialog box supporting MCP / Skill: - Help me create a login interface with account input box, password input box, and login button - Piece together this backpack interface based on the sliced image exported from Bluelake MCP - Add a pop-up zoom animation effect to StartBtn in the MainMenu interface - Help me check the large image set settings of the current interface, save and publish the lobby package If you have Skill installed, you can also create a login page for me via /fgui-agent-bridge to trigger it precisely. - Python 3.10+ - uv Package Manager - FairyGUI Editor (Recommended 6.1.4) Send the following prompts to AI programming agents capable of operating local terminals and files (such as Cursor, Claude Code, Codex, etc.):
Overview (machine translated)
Using natural language, let AI directly operate FairyGUI Editor.
The FairyGUI Agent Bridge builds a bridge between FairyGUI Editor and the AI programming assistant. Through MCP or CLI, agents in Cursor, Claude Code, Codex, and VS Code can read engineering structures, create and modify interfaces, produce animations, import resources, and publish products. You describe requirements, and it is responsible for transferring changes into the editor.
v0.8.23 · Queue protocol 1.0 · Developed and validated based on FairyGUI Editor 6.1.4.
This repository only contains the Bridge itself. The FairyGUI project only installs one lightweight plugin; MCP/CLI always runs from this repository. If using an agent that supports Skills, you can also install additional Skills to help AI become more familiar with FairyGUI’s operational conventions.
What can it do?
- Pinjie: Create new components and buttons, insert existing resources, and adjust position, size, style, layout, and controllers.
- Import Resources: Import images, fonts, and sounds locally, or generate MovieClip animations from image sequences.
- Animation Effects: Read, create, and modify Transitions, supports all native tracks, can be adjusted by keyframe, and can be preheated directly in the editor.
- Organize resource relationships: Replace image references, query ‘Who cited it’ and ‘Who does it depend on.’
- Branch Collaboration: List, create, and switch project branches so that experimental changes are placed in independent directories without affecting the trunk.
- Instance-level coverage: The same component displays different text and styles (button title, font size, color) on different instances.
- Verify changes: After saving, compare the document with the disk XML to confirm that the content is indeed included.
- Publish: Publish according to event packages, specified packages, or all packages, and process large images according to the real set constraints before release.
Working Principle
Agent and Bridge communicate via MCP Stdio or CLI; Bridge writes requests to the target project’s .agent/ directory, and the Editor plugin polls queues and calls the native FairyGUI API to execute. All changes happen in real Editor sessions, and you can see the results immediately in the editor interface.
Environmental Requirements
- Python
3.10+ - UV Package Manager
- FairyGUI Editor (Recommended
6.1.4)
Installation
Method 1: Let AI Install for You (Recommended)
Send the following prompts to your commonly used AI programming assistants (Cursor, Claude Code, Codex, etc.):
Method 2: Manual installation
1. Clone the warehouse and prepare the environment
2. Install the FairyGUI Editor plugin
Run the sync script and select your FairyGUI project directory in the pop-up window:
You can also directly specify the project path using the command line:
This page was translated automatically. Technical details may differ from the original.
Install
npx -y -p [email protected] tsc -p plugin/tsconfig.json --pretty falseConfiguration
{
"mcpServers": {
"fgui": {
"command": "uv",
"args": [
"run",
"--project",
"/ABSOLUTE/PATH/TO/fgui-agent-bridge",
"fgui-agent-mcp"
],
"env": {
"FGUI_PROJECT_PATH": "/ABSOLUTE/PATH/TO/FAIRYGUI-PROJECT"
}
}
}
}