Skip to content
Back to search

game-ui-design-workflow

一套面向游戏 UI 设计的 Cursor Agent Skills 工作流,覆盖原型视觉生成、风格切换、页面延展与组件拆解,并通过 Spec-Kit 文档、视觉契约和资源清单保证多页面一致性与可交付性。

Safety scan

A static text scan, not a guarantee. Select the badge to see what was scanned and every finding.

Checked today
Badge for your README
findsafeskills safety rating

Markdown

[![findsafeskills safety rating](/api/listings/guiguiyan930-source--game-ui-design-workflow/badge.svg)](/listings/guiguiyan930-source--game-ui-design-workflow)

HTML

<a href="/listings/guiguiyan930-source--game-ui-design-workflow"><img src="/api/listings/guiguiyan930-source--game-ui-design-workflow/badge.svg" alt="findsafeskills safety rating" /></a>

Install

i

Install instructions from the README

As written by the repo's author. findsafeskills has not verified these steps.

使用一键安装脚本安装到指定项目:

./install.sh --project /path/to/your-game

安装为个人技能:

./install.sh --personal

默认不会覆盖同名技能;确认升级时增加 `--force`。不要安装到 Cursor 内置的 `~/.cursor/skills-cursor/`。

完整的安装、显式调用、分阶段确认、页面批准和组件拆解示例见 [游戏 UI 技能调用指南](docs/SKILL_USAGE.zh-CN.md)。

完整交付示例见 [云阙列传:国风卡牌 RPG 完整交付](examples/guofeng-card-rpg/README.md)。

Factory v2 资产生产示例见 [欧美卡通生存商店:Token、语义切图、Atlas 与引擎 JSON](examples/factory-v2-shop/README.md)。

更多分阶段示例见 [示例索引](examples/README.md):

- [云阙列传(主案例)](examples/guofeng-card-rpg/README.md) - [月宫列传](examples/moon-palace-rpg/README.md) - [UI 风格切换](examples/style-switch/README.md) - [UI 页面延展](examples/screen-extension/README.md) - [UI 组件包拆解](examples/component-pack/README.md) - [雪碧图拆分与 PNG 打包](examples/sprite-sheet-splitting/README.md) - [Game UI Factory v2 商店案例](examples/factory-v2-shop/README.md)

视觉对比和完整操作链路见 [效果演示](docs/DEMO.zh-CN.md)。

What was scanned

The files the safety scan read, as written by the repository's author and shown as plain text. Lines with a finding are marked.

README.md · README · 226 lines

View this file on GitHub (read at the repository's current version: the scan did not record which commit it read)

  1. # Game UI Design Workflow
  2. [![Validate](https://github.com/guiguiyan930-source/game-ui-design-workflow/actions/workflows/validate.yml/badge.svg)](https://github.com/guiguiyan930-source/game-ui-design-workflow/actions/workflows/validate.yml)
  3. [![Release](https://img.shields.io/github/v/release/guiguiyan930-source/game-ui-design-workflow)](https://github.com/guiguiyan930-source/game-ui-design-workflow/releases)
  4. [![License](https://img.shields.io/github/license/guiguiyan930-source/game-ui-design-workflow)](LICENSE)
  5. ![Game UI Design Workflow](docs/assets/social-preview.png)
  6. 一个面向 Cursor Agent 的游戏 UI 设计技能仓库。它用 Spec-Kit 风格的项目文档串联能力:
  7. 1. **策划与需求(生成第一步)**:游戏策划方案(GDD)、PRD、UI 交互逻辑 → `game-ui-product-design`
  8. 2. UI 规范:建立视觉语言、设计令牌、布局和交互规则。
  9. 3. UI 延展:从玩法与玩家旅程扩展完整屏幕地图。
  10. 4. 页面生成:逐页生成方案、提示词与视觉稿。
  11. 5. 组件拆解:把已批准页面拆成可复用、可交付的独立素材。
  12. 6. 雪碧图拆分:去掉元素文字,将组件合图切成单元素透明 PNG,并打包 ZIP。
  13. 7. 资产交付:语义命名、9-slice、Atlas 与 Godot / Unity / Cocos JSON。
  14. `game-ui-workflow` 是总控技能;阶段技能也可独立调用。项目事实保存在 `specs/<project>/`,避免只依赖对话上下文。
  15. ## 使用场景
  16. - 只有游戏概念,需要先写策划方案、PRD 和 UI 交互逻辑再生图。
  17. - 只有游戏概念或参考图,需要先生成一张可讨论的 UI 原型视觉。
  18. - 已有页面结构,需要切换国风、科幻、卡通等视觉方向并保留版本对比。
  19. - 已有首页,需要延展编队、关卡、战斗、商城、活动等完整页面系统。
  20. - 页面已批准,需要拆成透明背景按钮、图标、卡片、角色和装饰素材。
  21. - 已生成组件雪碧图,需要自动切成单元素 PNG 并提供 ZIP 下载包。
  22. - 已有语义 PNG,需要生成 9-slice、Atlas 和引擎交付清单。
  23. - 团队需要把 UI 决策沉淀为可复用契约,避免连续页面风格漂移。
  24. - 设计成果需要交付开发,希望页面、组件、状态、尺寸和资源来源可追踪。
  25. 不适合直接用来替代游戏客户端实现、服务端接口设计或未经确认的大批量最终生图。
  26. ## 30 秒使用方法
  27. 安装到当前项目:
  28. ```bash
  29. ./install.sh --project /path/to/your-game
  30. ```
  31. 初始化 UI 工作区:
  32. ```bash
  33. python3 scripts/init_project.py your-game-id
  34. ```
  35. 在 Cursor 中调用:
  36. ```text
  37. 使用 game-ui-workflow,读取 @specs/your-game-id 和我的参考图。
  38. 依次执行第 1 步策划与 PRD(game-ui-product-design),再执行原型生成视觉、UI 风格切换、UI 延展、UI 组件拆解、雪碧图拆分打包和 Atlas 引擎交付。
  39. 每一步完成后停止,列出检查项,并给出可直接复制的下一步调用文本。
  40. ```
  41. 详细方法见 [中文调用指南](docs/SKILL_USAGE.zh-CN.md)。
  42. ## 工作流(第 1 步起)
  43. ```text
  44. 第 1 步 策划方案 + PRD + UI 交互逻辑(批准)
  45. 第 2 步 原型生成视觉
  46. 第 3 步 UI 风格切换与批准
  47. 第 4 步 UI 页面延展与逐页生成
  48. 第 5 步 UI 组件拆解与雪碧图生成
  49. 第 6 步 雪碧图拆分、单元素 PNG 与 ZIP 打包
  50. 第 7 步 语义命名、9-slice、Atlas 与引擎 JSON
  51. ```
  52. 每一步都会说明输入、输出、检查项、人工门禁和可直接复制的下一步调用文本。**第 1 步未批准时不会进入原型生图**;页面未批准时不会提前拆解组件。
  53. ## 特性
  54. - 8 个可自动触发或显式调用的 Cursor Agent Skills
  55. - 需求、研究、计划、任务、契约和复现文档持久化
  56. - 页面和组件提示词、图片、状态、版本及来源可追踪
  57. - PNG 真实尺寸、透明通道和 SVG 尺寸校验
  58. - 自动化测试与 GitHub Actions 持续验证
  59. - 图片工具不可用时安全降级为 `pending-generation`
  60. ## 目录
  61. ```text
  62. skills/
  63. game-ui-workflow/
  64. game-ui-product-design/
  65. game-ui-specification/
  66. game-ui-extension/
  67. game-ui-page-generator/
  68. game-ui-component-breakdown/
  69. game-ui-sprite-sheet-splitter/
  70. game-ui-asset-pipeline/
  71. templates/
  72. spec-kit/
  73. contracts/
  74. scripts/
  75. init_project.py
  76. validate_project.py
  77. validate_skills.py
  78. split_sprite_sheet.py
  79. build_sprite_atlas.py
  80. export_engine_manifest.py
  81. schemas/
  82. config/
  83. tests/
  84. install.sh
  85. specs/
  86. examples/
  87. ```
  88. ## 安装
  89. 使用一键安装脚本安装到指定项目:
  90. ```bash
  91. ./install.sh --project /path/to/your-game
  92. ```
  93. 安装为个人技能:
  94. ```bash
  95. ./install.sh --personal
  96. ```
  97. 默认不会覆盖同名技能;确认升级时增加 `--force`。不要安装到 Cursor 内置的 `~/.cursor/skills-cursor/`。
  98. 完整的安装、显式调用、分阶段确认、页面批准和组件拆解示例见
  99. [游戏 UI 技能调用指南](docs/SKILL_USAGE.zh-CN.md)。
  100. 完整交付示例见 [云阙列传:国风卡牌 RPG 完整交付](examples/guofeng-card-rpg/README.md)。
  101. Factory v2 资产生产示例见 [欧美卡通生存商店:Token、语义切图、Atlas 与引擎 JSON](examples/factory-v2-shop/README.md)。
  102. 更多分阶段示例见 [示例索引](examples/README.md):
  103. - [云阙列传(主案例)](examples/guofeng-card-rpg/README.md)
  104. - [月宫列传](examples/moon-palace-rpg/README.md)
  105. - [UI 风格切换](examples/style-switch/README.md)
  106. - [UI 页面延展](examples/screen-extension/README.md)
  107. - [UI 组件包拆解](examples/component-pack/README.md)
  108. - [雪碧图拆分与 PNG 打包](examples/sprite-sheet-splitting/README.md)
  109. - [Game UI Factory v2 商店案例](examples/factory-v2-shop/README.md)
  110. 视觉对比和完整操作链路见 [效果演示](docs/DEMO.zh-CN.md)。
  111. ## 快速开始
  112. ```bash
  113. python3 scripts/init_project.py guofeng-card-rpg
  114. python3 scripts/validate_project.py examples/guofeng-card-rpg
  115. ```
  116. 然后在 Cursor 中提出:
  117. ```text
  118. 使用 game-ui-workflow,根据参考图为一款国风卡牌 RPG 建立完整 UI 项目,
  119. 先完成规范和屏幕地图,再生成首页视觉,批准后拆解首页组件。
  120. ```
  121. 端到端流程:
  122. ```text
  123. spec.md
  124. → research.md
  125. → contracts/style-contract.yaml
  126. → plan.md + contracts/screen-contract.yaml
  127. → assets/pages/ + asset-manifest.yaml
  128. → contracts/component-contract.yaml + assets/components/
  129. → tasks.md + quickstart.md + validation
  130. ```
  131. ## 阶段调用
  132. - “建立这个游戏的 UI 规范” → `game-ui-specification`
  133. - “基于现有首页延展完整页面” → `game-ui-extension`
  134. - “生成商城页视觉并保存图片” → `game-ui-page-generator`
  135. - “把这个页面拆成透明背景组件” → `game-ui-component-breakdown`
  136. - “把组件雪碧图切成单个 PNG 并打包” → `game-ui-sprite-sheet-splitter`
  137. - “生成 9-slice、Atlas 和引擎 JSON” → `game-ui-asset-pipeline`
  138. - “从需求一直做到组件交付” → `game-ui-workflow`
  139. 图片生成工具可用时,技能应实际生成并保存图片;不可用时保留完整提示词,将资源状态标为 `pending-generation`,不能伪造文件。
  140. ## 项目约束
  141. - `spec.md` 是需求与验收标准的唯一来源。
  142. - `contracts/` 是跨阶段视觉一致性的唯一来源;后续阶段不得静默改写。
  143. - 页面生成一次只处理一个页面,批准后才进入组件拆解。
  144. - 所有资源必须登记到 `contracts/asset-manifest.yaml`。
  145. - 修改项目后运行校验脚本;失败项修复前不得宣称交付完成。
  146. ## 质量检查
  147. ```bash
  148. python3 -m unittest discover -s tests -v
  149. python3 scripts/validate_skills.py
  150. python3 scripts/validate_project.py examples/guofeng-card-rpg --strict
  151. python3 scripts/validate_project.py examples/moon-palace-rpg --strict
  152. python3 scripts/validate_project.py examples/factory-v2-shop --strict
  153. ```
  154. GitHub Actions 会在 push 和 pull request 时自动运行这些检查。
  155. ## 参与贡献与版本
  156. - 贡献方式:[CONTRIBUTING.md](CONTRIBUTING.md)
  157. - 版本记录:[CHANGELOG.md](CHANGELOG.md)
  158. - 发布与安装:[docs/RELEASE.md](docs/RELEASE.md)
  159. - 兼容性说明:[docs/COMPATIBILITY.md](docs/COMPATIBILITY.md)
  160. - Factory v2 架构:[docs/GAME_UI_FACTORY_V2.zh-CN.md](docs/GAME_UI_FACTORY_V2.zh-CN.md)
  161. - 路线图与未实现能力:[docs/ROADMAP.md](docs/ROADMAP.md)
  162. - 隐私与版权:[docs/SECURITY.md](docs/SECURITY.md)
  163. - 契约迁移:[docs/MIGRATION.md](docs/MIGRATION.md)
  164. - 问题与建议:[GitHub Issues](https://github.com/guiguiyan930-source/game-ui-design-workflow/issues)
  165. ## 项目来源与演进
  166. 本仓库由作者此前创建并维护的四个游戏 UI 技能整合演进而来:
  167. - [Game-UI-Extension](https://github.com/guiguiyan930-source/Game-UI-Extension)
  168. - [game-ui-page-generator](https://github.com/guiguiyan930-source/game-ui-page-generator)
  169. - [game-ui-specification](https://github.com/guiguiyan930-source/game-ui-specification)
  170. - [game-ui-component-breakdown](https://github.com/guiguiyan930-source/game-ui-component-breakdown)
  171. 这些仓库属于同一作者的早期实践,并非本项目引入的第三方技能。整合原因、能力映射和新增内容见 [ORIGIN.md](ORIGIN.md)。

Ratings and comments

Sign in to rate this skill.

Sign in

Free to use. If it’s helped, pass it on.