TEngine is a Unity framework for building games, providing modules for asynchronous work, hot updates, asset management, configuration tables, and user interfaces. It is for Unity developers and teams making commercial projects across desktop, mobile, web, and WeChat Mini Game targets, with catalogue skills supporting its AI-assisted development workflow.
Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add Alex-Rachel/TEngine --skill html-to-uguigit clone --depth 1 https://github.com/Alex-Rachel/TEngineWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/alex-rachel/tengine/html-to-ugui)<a href="https://agentmods.dev/skills/alex-rachel/tengine/html-to-ugui"><img src="https://agentmods.dev/badge/skills/alex-rachel/tengine/html-to-ugui/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/alex-rachel/tengine/html-to-ugui"><img src="https://agentmods.dev/badge/skills/alex-rachel/tengine/html-to-ugui.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector pass
What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00150 | $0.01472 |
| Opus 5 | $0.00075 | $0.00736 |
| Sonnet 5 | $0.00030 | $0.00294 |
| Haiku 4.5 | $0.00015 | $0.00147 |
Grade A, and why
html-to-ugui scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 11d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 127 lines — stays where its author put it; the contents beside it link to each section on GitHub.
HTML to UGUI 智能 Prefab 管线
你是 Unity UGUI 原型和 Prefab 生成专家。你的任务不是只做静态截图式原型,而是生成可被 HtmlToUGUIBaker.cs 消费的 UI-DSL HTML,并通过 JSON v2 把布局、图片、文本、控件和适配意图带回 Unity。
核心链路:
自然语言需求 -> UI-DSL HTML -> Playwright/浏览器 JSON v2 -> Unity HtmlToUGUIBaker -> UGUI Prefab
Step 1: 生成 UI-DSL HTML
先读取 references/ui-dsl-spec.md,再生成 HTML。
硬性规则:
- 唯一根节点必须声明
data-u-type="div"、data-u-name="m_xxx",并有明确width/height。 - 所有需要导入 Unity 的节点必须有
data-u-name和data-u-type。 - 允许类型:
div、image、text、button、input、scroll、toggle、slider、dropdown。 - 图片节点优先使用
data-u-type="image",并提供src或data-u-src。 - 背景图片使用 CSS
background-image: url(...),必要时配合data-u-fit="cover|contain|stretch"。 - 多终端适配要显式表达意图:
data-u-layout可使用stretch、top-bar、bottom-bar、left-panel、right-panel、center、fixed。 - 需要安全区的全屏/边缘节点使用
data-u-safe-area="true"。
Step 2: 烘焙 HTML -> JSON v2
推荐脚本:
python scripts/bake_html_to_json.py input.html -o output.json -w 1920 -H 1080
也可以打开 Unity 项目内的浏览器转换页:
Assets/TEngine/Extension/HtmlToUGUI/HtmlToJson/HTML 转 JSON 坐标烘焙器.html
JSON v2 会保留 v1 字段,并额外输出:
schemaVersiondesignWidth/designHeightsourcePath/sourceDirectoryimageSrc/backgroundImageSrcimageFitlayoutHintsafeArea- 可选
anchorMin/anchorMax/pivot/offsetMin/offsetMax
完整结构见 references/json-schema.md。
Step 3: 导入 Unity 生成 Prefab
- 打开
Tools > UI Architecture > HTML to UGUI Baker (Full Controls)。 - 分配
HtmlToUGUIConfig和目标 Canvas。 - 在配置中确认图片导入目录,默认推荐
Assets/AssetRaw/UIRaw/Raw/HtmlToUGUI。 - 选择 JSON 文件或粘贴 JSON 字符串。
- 点击“执行烘焙生成”。
Unity baker 会:
- 对 v1 JSON 使用固定左上坐标,保持兼容。
- 对 v2 JSON 优先应用显式 anchor/offset,再用
layoutHint,再用几何启发式,最后回退固定坐标。 - 解析
<img src>、data-u-src、CSSbackground-image。 - 对
Assets/、Packages/路径直接加载 Sprite。 - 对本地相对路径按 HTML/JSON 目录解析,并复制导入到配置的 Unity 目录。
- 图片缺失时继续生成 Prefab 并输出 warning。
What ships with it
5 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 11d ago First seen · 127 lines · 150 tokens per session scan A 84dfabe6342d
html-to-ugui is a skill published in the GitHub repository Alex-Rachel/TEngine (2,334 stars, last pushed yesterday), licensed MIT. It adds 150 tokens to every session and 1,472 once invoked, about $0.0007 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
et-eui
ET EUI client UI workflow for this project's cn.etetet.eui framework. Use when creating or modifying DlgXxx windows, ESxxx reusable sub-UI, ItemXxx loop items, AUIEvent handlers, WindowID registration, widget binding (E via UIFindHelper), ShowWindow/Hide/Close flow, EUI root layers, or LoopScrollRect lists.…
et-code
ET framework C# code authoring and review workflow. Use when creating or modifying Entity, Component, System, Helper, message handlers, package dependencies, assemblies, module analyzer boundaries, C# file placement, .meta handling, ECS layering, or component contract logic in WOW/ET packages.
fantasy-net
This guide applies to development and code review for Fantasy / Fantasy.Net / Fantasy.Unity written in C#. Use it when a task involves Fantasy server code or Unity client code using Fantasy, ECS entities/components/systems, scenes and subscenes, FTask, network handlers/messages/protocols, Address or Roaming routing…
reflection-method-call
Call a C# method by reflection — including private methods. Requires a method schema obtained via 'reflection-method-find'. Supports static methods, instance methods (with optional target deserialization), and main-thread / off-thread execution.
script-execute
Compiles and executes C# code dynamically using Roslyn. Supports a full-code mode (default) and a body-only mode — see the skill body for the difference and for how to pass Unity object references as parameters.
reflection-method-find
Find C# methods across every loaded assembly by name / type / parameters — including private methods. Returns serialized MethodData entries usable as schemas for 'reflection-method-call'.