review-game

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Review Game

游戏代码评审

Analyze an existing game codebase and provide a structured review. This is the final step in the pipeline — it checks everything is wired up correctly and gives you a quality score.
分析现有游戏代码库并提供结构化评审报告。这是流水线的最后一步——检查所有内容是否正确关联,并给出质量评分。

Instructions

操作说明

Analyze the game at
$ARGUMENTS
(or the current directory if no path given).
分析位于
$ARGUMENTS
的游戏(若未指定路径则分析当前目录)。

Step 1: Identify the game

步骤1:识别游戏

  • Detect the engine (Three.js, Phaser, or other)
  • Read
    package.json
    for dependencies and scripts
  • Read the main entry point and index.html
  • Identify the game concept/genre
  • 检测引擎(Three.js、Phaser或其他)
  • 读取
    package.json
    以查看依赖项和脚本
  • 读取主入口文件和index.html
  • 确定游戏概念/类型

Step 2: Architecture Review

步骤2:架构评审

Check for these required patterns and report compliance:
  • EventBus: Is there a centralized event system? Are modules decoupled?
  • GameState: Is there a centralized state singleton?
  • Constants: Are config values centralized or scattered as magic numbers?
  • Orchestrator: Is there a main Game class that initializes everything?
  • Directory Structure: Is code organized into core/systems/gameplay/ui/level layers?
  • Event Constants: Are events defined as named constants or raw strings?
检查以下必填模式并报告合规情况:
  • EventBus:是否存在集中式事件系统?模块是否解耦?
  • GameState:是否存在集中式状态单例?
  • Constants:配置值是集中管理还是分散为魔法数字?
  • Orchestrator:是否存在初始化所有内容的主Game类?
  • 目录结构:代码是否按core/systems/gameplay/ui/level层级组织?
  • Event Constants:事件是定义为命名常量还是原始字符串?

Step 3: Performance Review

步骤3:性能评审

Check for common issues:
  • Delta time capping: Is
    getDelta()
    capped to prevent death spirals?
  • Object pooling: Are temp objects reused in hot loops?
  • Resource disposal: Are Three.js geometries/materials/textures disposed?
  • Event cleanup: Are event listeners cleaned up on scene transitions?
  • Asset loading: Are assets preloaded with progress feedback?
检查常见问题:
  • Delta time 限制:是否对
    getDelta()
    进行限制以防止死亡螺旋?
  • 对象池化:临时对象在热循环中是否被复用?
  • 资源释放:Three.js的几何体/材质/纹理是否被释放?
  • 事件清理:场景切换时是否清理事件监听器?
  • 资源加载:是否预加载资源并提供进度反馈?

Step 4: Code Quality

步骤4:代码质量

  • No circular dependencies: Modules flow one direction
  • Single responsibility: Each module has one clear job
  • Error handling: Event handlers wrapped in try/catch
  • Consistent naming: Events use
    domain:action
    , files use PascalCase
  • 无循环依赖:模块单向依赖
  • 单一职责:每个模块有明确的单一职责
  • 错误处理:事件处理器是否包裹在try/catch中?
  • 命名一致性:事件使用
    domain:action
    格式,文件使用PascalCase命名法

Step 5: Monetization Readiness

步骤5:变现准备情况

  • Points system: Is there a scoring/points mechanism?
  • Session tracking: Can game sessions be identified?
  • Anti-cheat potential: Is score validation server-side or at least structured for it?
  • Play.fun integration: Any existing SDK integration?
  • 积分系统:是否存在计分/积分机制?
  • 会话追踪:能否识别游戏会话?
  • 反作弊潜力:分数验证是否在服务端进行,或至少具备相关结构?
  • Play.fun 集成:是否已有SDK集成?

Output Format

输出格式

Provide a structured report with:
  1. Game Overview - What the game is, tech stack, game loop
  2. Architecture Score (out of 6 checks)
  3. Performance Score (out of 5 checks)
  4. Code Quality Score (out of 4 checks)
  5. Monetization Readiness (out of 4 checks)
  6. Top Recommendations - Prioritized list of improvements with plain-English explanations
  7. What's Working Well - Positive findings
提供包含以下内容的结构化报告:
  1. 游戏概述 - 游戏内容、技术栈、游戏循环
  2. 架构评分(满分6分,基于检查项)
  3. 性能评分(满分5分,基于检查项)
  4. 代码质量评分(满分4分,基于检查项)
  5. 变现准备情况(满分4分,基于检查项)
  6. 首要改进建议 - 按优先级排列的改进列表,附通俗易懂的解释
  7. 亮点总结 - 正面发现

Next Step

后续步骤

Tell the user:
Your game has been through the full pipeline! Here's what you have:
  • Scaffolded architecture (
    /make-game
    )
  • Visual polish (
    /design-game
    )
  • Music and sound effects (
    /add-audio
    )
  • Automated tests (
    /qa-game
    )
  • Architecture review (
    /review-game
    )
What's next?
  • Add new gameplay features with
    /game-creator:add-feature [description]
  • Deploy to the web — run
    npm run build
    then host the
    dist/
    folder on GitHub Pages, Vercel, Netlify, or itch.io
  • Keep iterating! Run
    /design-game
    ,
    /add-audio
    , or
    /review-game
    again anytime after making changes.
告知用户:
你的游戏已完成全流程处理!目前已完成以下内容:
  • 架构搭建(
    /make-game
  • 视觉优化(
    /design-game
  • 音乐与音效添加(
    /add-audio
  • 自动化测试(
    /qa-game
  • 架构评审(
    /review-game
下一步可以做什么?
  • 使用
    /game-creator:add-feature [description]
    添加新的游戏玩法功能
  • 部署到网页——运行
    npm run build
    ,然后将
    dist/
    文件夹托管到GitHub Pages、Vercel、Netlify或itch.io
  • 持续迭代!修改后可随时再次运行
    /design-game
    /add-audio
    /review-game