FAQ
m2ui is a Claude Code plugin with 2 hand-picked skills for development work, indexed on Flowy. Install it with the command on its page. It includes m2ui, m2ui. Its skills do not fire on their own yet. Request auto-invocation to have Flowy route them as you prompt. Free and open source.
Repo: martysama0134/m2ui-skill
A skill for AI coding assistants that generates and modifies Metin2 client UI code. It works with screenshots, natural language descriptions, or existing scripts โ and outputs correct, production-ready uiscript dicts, root ui*.py classes, and locale string entries.
m2ui works with all major AI coding tools. Each tool picks up the skill through its native integration mechanism:
| Agent | Mechanism | Auto-activates? |
|---|---|---|
| Claude Code | Plugin system (/m2ui skill) | Yes |
| Codex | Plugin in plugins/m2ui/ | Yes |
| Cursor | .cursor/rules/m2ui.mdc | Yes |
| Windsurf | .windsurf/rules/m2ui.md | Yes |
| Cline | .clinerules/m2ui.md | Yes |
| GitHub Copilot | .github/copilot-instructions.md | Yes |
| Gemini CLI | GEMINI.md extension | Yes |
| Any other agent | AGENTS.md at repo root | Read on demand |
All agents share the same reference documentation. The source of truth is rules/m2ui-activate.md โ a CI workflow syncs it to each tool's native format automatically.
Paste this to your AI agent:
Install the m2ui skill from https://github.com/martysama0134/m2ui-skill into my project. For Claude Code, register the repo as a marketplace via `/plugin marketplace add <path>` and then `/plugin install m2ui@m2ui` โ the repo ships a ready-to-use `.claude-plugin/marketplace.json` so symlinking alone is NOT enough.
Claude Code does not auto-discover plugins under ~/.claude/plugins/local/. Plugins must be registered via a marketplace and then installed. This repo ships a ready-to-use marketplace descriptor at .claude-plugin/marketplace.json so the same clone serves as both marketplace and plugin source.
Step 1 โ clone the repo somewhere local:
# Anywhere on disk; the path doesn't have to be ~/.claude/plugins/local/
git clone https://github.com/martysama0134/m2ui-skill.git /path/to/m2ui-skill
Step 2 โ register the marketplace in Claude Code:
/plugin marketplace add /path/to/m2ui-skill
Step 3 โ install the plugin from that marketplace:
/plugin install m2ui@m2ui
(The first m2ui is the plugin name; the second is the marketplace name declared in .claude-plugin/marketplace.json.)
Step 4 โ restart Claude Code (or run /reload-plugins) to pick up the slash command and skill. Verify with /help โ you should see /m2ui in the slash-command list.
To upgrade later: git pull in the cloned dir + restart Claude Code. The marketplace registration persists.
These agents look for rule files at your project root. Copy the relevant directories from this repo into your Metin2 project:
# Clone the skill repo
git clone https://github.com/martysama0134/m2ui-skill.git /tmp/m2ui-skill
# Copy the rule files and reference docs to your project root
cp -r /tmp/m2ui-skill/.cursor /tmp/m2ui-skill/.windsurf /tmp/m2ui-skill/.clinerules your-project/
cp -r /tmp/m2ui-skill/.github/copilot-instructions.md your-project/.github/
cp -r /tmp/m2ui-skill/skills your-project/
Alternatively, add as a submodule at your project root and symlink the rule directories.
The rule files are thin pointers that tell the agent to read the full reference docs in skills/m2ui/reference/.
The Codex plugin is in plugins/m2ui/. Point your Codex configuration to this directory.
Install as a Gemini extension using gemini-extension.json at the repo root.
m2ui exposes both a slash command and a Skill. They reach the same engine โ the slash command is a thin entry point that delegates to the skill, which does the actual work. Use whichever feels natural:
Slash command (discoverable via /help):
/m2ui Interactive mode โ asks what you want to do
/m2ui screenshot Analyze an attached image, generate matching UI code
/m2ui talk make a shop window Describe a UI in plain language, get generated code
/m2ui script uimovechannel.py Modify an existing UI file
/m2ui diagnose uixxx.py Audit an existing UI file for memory leaks and anti-patterns
Natural language (the skill auto-activates from context):
use m2ui to make a shop window
m2ui screenshot: <attach image>
modify uimovechannel.py with m2ui
m2ui diagnose uixxx.py
audit my UI files with m2ui
The keywords (m2ui, screenshot, diagnose), plus a .py file reference, an attached image, or a plain text description drive auto-detection of the right mode (see Auto-Detection below).
Just describe what you want in natural language. The agent will automatically read the reference docs and follow the m2ui rules:
When no explicit mode is specified, the skill auto-detects from your input:
.py file โ script mode (modify existing)Restart needed after updates. When you upgrade m2ui (pull a new version, or land a SKILL.md / commands/ / metadata change), quit and relaunch Claude Code so the new skill, slash commands, and metadata are picked up. Existing sessions keep the previously-loaded version. Verify a restart worked by checking the version in .claude-plugin/plugin.json against /help output.
Project scope. The recommended Claude Code install is global (~/.claude/plugins/local/m2ui โ junction on Windows, symlink on macOS/Linux), not per-project. The skill targets client code (pack/pack/uiscript/, pack/pack/root/); a server-only project will not auto-engage the skill unless client UI files are in scope. Other agents (Cursor / Windsurf / Cline / Copilot / Gemini) are project-scoped โ copy the relevant rule files into the client project root.
Subagent. v2.5.0+ ships an optional m2ui-pre-emit-reviewer subagent for high-stakes generations (screenshot mode, multi-file edits, gated windows). It runs an independent audit before emission and surfaces findings without proposing fixes. See agents/m2ui-pre-emit-reviewer.md.
Every invocation produces the appropriate combination of:
pack/pack/uiscript/uiscript/ui*.py class โ event handling and logic, written to pack/pack/root/The skill supports both Metin2 UI patterns and auto-picks based on complexity:
LoadScriptFile() and GetChild() to wire layout to logic.__LoadDialog() method using SetParent() and InsertChild().All generated code enforces these rules to prevent common Metin2 UI bugs. Before emitting any output, the agent runs a silent Pre-Emit Self-Review gate against this checklist (see skills/m2ui/SKILL.md โ ## Pre-Emit Self-Review):
@ui.WindowDestroy decorator on every Destroy() method โ ensures proper cleanup of child windows and instance attributesself MUST use ui.__mem_func__(), SAFE_SetEvent (if fork provides it), or lambda r=proxy(self): r.X(). Never bare bound methods or self-capturing lambdas. See skills/m2ui/reference/event-binding.md for the full matrix and decision flow.Initialize() / Destroy() / Open() / Close() / OnPressEscapeKey() pattern โ standard window lifecycleOnPressEscapeKey() returns True always; OnMouseWheel() returns True/False based on whether it consumed the eventlocaleInfo / uiScriptLocale โ never hardcoded, always externalizednot_pick flag on decorative elements โ prevents click interception by backgrounds, separators, and linesconstInfo.intWithCommas() for large numbers โ consistent number formattingapp.__BL_CLIP_MASK__) โ proper clipping for scrollable contentD:\ymir work\ui\ before reference; absent assets emitted as # TBD ASSET: ... placeholders, not inventednet.X / player.X / etc. checked against skills/m2ui/reference/bindings.md before emit; absent functions emitted as # TODO: verify ... stubs, not fabricatedm2ui/
โโโ .claude-plugin/
โ โโโ marketplace.json Claude Code marketplace descriptor (this repo IS a marketplace)
โ โโโ plugin.json Claude Code plugin manifest
โโโ commands/
โ โโโ m2ui.md /m2ui slash command (delegates to skill)
โโโ plugins/m2ui/
โ โโโ .codex-plugin/
โ โโโ plugin.json Codex plugin manifest
โโโ rules/
โ โโโ m2ui-activate.md Source of truth โ synced to all tools by CI
โโโ skills/m2ui/
โ โโโ SKILL.md Entry point โ mode detection, Critical Rules, Pre-Emit Self-Review gate
โ โโโ modes/
โ โ โโโ screenshot.md Screenshot interpretation workflow
โ โ โโโ talk.md Natural language generation workflow
โ โ โโโ script.md Existing file modification workflow
โ โ โโโ diagnose.md Anti-pattern audit workflow
โ โโโ reference/
โ โโโ event-binding.md Callback wrapping matrix โ single source of truth for memory-safe event hookup
โ โโโ widgets.md All 34 widget types with properties (995 lines)
โ โโโ patterns.md Code templates and best practices (2,700+ lines)
โ โโโ bindings.md C++ Python module catalog (1,281 lines)
โ โโโ locale.md Locale string format and rules
โโโ .cursor/rules/m2ui.mdc Auto-synced Cursor rules
โโโ .windsurf/rules/m2ui.md Auto-synced Windsurf rules
โโโ .clinerules/m2ui.md Auto-synced Cline rules
โโโ .github/
โ โโโ copilot-instructions.md Auto-synced Copilot instructions
โ โโโ workflows/sync-skill.yml CI workflow for syncing copies
โโโ AGENTS.md Generic agent entry point (Codex, etc.)
โโโ GEMINI.md Gemini CLI entry point
โโโ gemini-extension.json Gemini CLI extension metadata
โโโ README.md
The reference documentation in skills/m2ui/reference/ is the core of this skill. To improve it:
event-binding.md โ Update callback wrapping matrix when fork conventions changewidgets.md โ Add missing widget properties or document new widget typespatterns.md โ Add new code patterns or update templatesbindings.md โ Update when new C++ Python module functions are addedlocale.md โ Update if locale path conventions changeImportant: Do not edit the tool-specific rule copies (.cursor/rules/, .windsurf/rules/, etc.) directly. Edit rules/m2ui-activate.md instead โ the CI workflow propagates changes to all copies automatically.
pack/pack/root/ and pack/pack/uiscript/uiscript/ directories.agents/
plugins/
marketplace.json
.claude-plugin/
marketplace.json
plugin.json
.clinerules/
m2ui.md
.cursor/
rules/
m2ui.mdc
.github/
copilot-instructions.md
workflows/
release.yml
sync-skill.yml
.gitignore
.windsurf/
rules/
m2ui.md
agents/
AGENTS.md
m2ui-pre-emit-reviewer.md
commands/
m2ui.md
gemini-extension.json
GEMINI.md
plugins/
m2ui/
.codex-plugin/
plugin.json
agents/
m2ui-pre-emit-reviewer.md
skills/
m2ui/
modes/
diagnose.md
screenshot.md
script.md
talk.md
reference/
anchors/
01-simple-dialog.md
02-board-with-list.md
03-list-selector.md
04-9slice-panel.md
05-feature-gated.md
06-tooltip-bound.md
07-shop-exchange.md
08-inventory-equipment.md
09-options-settings.md
10-paginated-slot-grid.md
11-quest-npc-dialog.md
12-storage-warehouse.md
13-craft-refine-window.md
14-drag-and-drop.md
15-network-coupled-flow.md
16-tabbed-content.md
17-search-filter-dialog.md
18-mailbox-two-pane.md
19-daily-reward-grid.md
20-leaderboard-table.md
21-wheel-roulette.md
22-compare-tooltip.md
23-auto-hide-chrome.md
24-page-history-browser.md
25-expandable-tree-list.md
README.md
bindings.md
event-binding.md
failure-atlas.md
framework-augmentations.md
integration.md
locale.md
mental-model.md
patterns.md
timer-patterns.md
visual-conventions.md
widgets.md
SKILL.md
README.md
rules/
m2ui-activate.md
skills/
m2ui/
modes/
diagnose.md
screenshot.md
script.md
talk.md
reference/
anchors/
01-simple-dialog.md
02-board-with-list.md
03-list-selector.md
04-9slice-panel.md
05-feature-gated.md
06-tooltip-bound.md
07-shop-exchange.md
08-inventory-equipment.md
09-options-settings.md
10-paginated-slot-grid.md
11-quest-npc-dialog.md
12-storage-warehouse.md
13-craft-refine-window.md
14-drag-and-drop.md
15-network-coupled-flow.md
16-tabbed-content.md
17-search-filter-dialog.md
18-mailbox-two-pane.md
19-daily-reward-grid.md
20-leaderboard-table.md
21-wheel-roulette.md
22-compare-tooltip.md
23-auto-hide-chrome.md
24-page-history-browser.md
25-expandable-tree-list.md
README.md
bindings.md
event-binding.md
failure-atlas.md
framework-augmentations.md
integration.md
locale.md
mental-model.md
patterns.md
timer-patterns.md
visual-conventions.md
widgets.md
SKILL.md
tests/
README.md
run-all.sh
similarity-allowlist.txt
test-decision-tree.sh
test-mode-dispatch.sh
test-pre-emit-invariants.sh
test-required-refs.sh
test-similarity-scan.shยฉ 2026 Flowy ยท Free and open source
Built for Claude Code ยท Not affiliated with Anthropic