overwrite, remove first
This commit is contained in:
parent
9bf0bd772b
commit
7991c17006
|
|
@ -1,54 +0,0 @@
|
|||
# BMad Expansion Pack: WeChat Mini-Game Development
|
||||
|
||||
**Version:** 1.0.0
|
||||
**Author:** Jules (AI Assistant)
|
||||
|
||||
## Overview
|
||||
|
||||
This expansion pack provides a comprehensive, structured environment for developing WeChat Mini-Games using the BMad Method. It is built based on the official WeChat Mini Game documentation and aligns with the best practices of other game development packs in the BMad ecosystem.
|
||||
|
||||
This pack includes specialized agents, a detailed development workflow, document templates, and quality-control checklists to guide you from concept to release.
|
||||
|
||||
---
|
||||
|
||||
## Components
|
||||
|
||||
### Core Configuration
|
||||
* **`config.yaml`**: Contains the metadata for this expansion pack.
|
||||
|
||||
### Specialist Agents
|
||||
* **`@wechat-game-designer`**: An expert agent for planning your game, with deep knowledge of the WeChat Mini Game engine-like environment (scenes, entities, components).
|
||||
* **`@wechat-game-dev`**: A specialized developer agent for implementing game features in TypeScript, following the platform's best practices.
|
||||
|
||||
### Data & Guidelines
|
||||
* **`data/development-guidelines.md`**: The central source of truth for all technical standards, derived from official documentation. Both agents are aware of these guidelines.
|
||||
|
||||
### Workflows
|
||||
* **`workflows/wechat-game-dev-greenfield.yaml`**: Defines a step-by-step development process from creating a GDD to implementation, mirroring the official WeChat lifecycle.
|
||||
|
||||
### Templates
|
||||
* **`templates/gdd-wechat-template.yaml`**: A template for creating a Game Design Document tailored for WeChat Mini-Games.
|
||||
|
||||
### Tasks
|
||||
* **`tasks/scaffold-wechat-page.md`**: A task for the `@wechat-game-dev` agent to quickly scaffold new pages.
|
||||
|
||||
### Checklists
|
||||
* **`checklists/game-story-dod-checklist.md`**: A "Definition of Done" checklist to ensure every story is completed to a consistent quality standard.
|
||||
|
||||
### Web UI Support
|
||||
* **`agent-teams/wechat-mini-game-team.yaml`**: Defines the agent team for use in web-based AI platforms, allowing you to load the entire team at once.
|
||||
|
||||
---
|
||||
|
||||
## Quick-Start Workflow
|
||||
|
||||
The primary workflow is defined in `workflows/wechat-game-dev-greenfield.yaml`. You can use the `@bmad-orchestrator` in a web UI to guide you through it, or follow the steps manually in an IDE:
|
||||
|
||||
1. **Plan Your Game:**
|
||||
```bash
|
||||
@wechat-game-designer *create-doc {template: 'gdd-wechat-template.yaml', game_name: 'YourGame'}
|
||||
```
|
||||
2. **Implement Features:**
|
||||
```bash
|
||||
@wechat-game-dev *develop-story {path/to/story.md}
|
||||
```
|
||||
|
|
@ -1,13 +0,0 @@
|
|||
# <!-- Powered by BMAD™ Core -->
|
||||
bundle:
|
||||
name: WeChat Mini Game Dev Team
|
||||
icon: 🎮
|
||||
description: A specialized team for planning and developing WeChat Mini Games, from concept to release.
|
||||
agents:
|
||||
- bmad-orchestrator
|
||||
- wechat-game-designer
|
||||
- wechat-game-dev
|
||||
- sm
|
||||
- qa
|
||||
workflows:
|
||||
- wechat-game-dev-greenfield.yaml
|
||||
|
|
@ -1,53 +0,0 @@
|
|||
<!-- Powered by BMAD™ Core -->
|
||||
# wechat-game-designer
|
||||
|
||||
ACTIVATION-NOTICE: This file contains your full agent operating guidelines.
|
||||
CRITICAL: Read the full YAML BLOCK that FOLLOWS IN THIS FILE to understand your operating params.
|
||||
|
||||
## COMPLETE AGENT DEFINITION FOLLOWS
|
||||
|
||||
```yaml
|
||||
IDE-FILE-RESOLUTION:
|
||||
- Dependencies map to {root}/{type}/{name} where type is the folder and name is the file.
|
||||
REQUEST-RESOLUTION: Flexibly match user requests to commands. Ask for clarification if the request is ambiguous.
|
||||
activation-instructions:
|
||||
- STEP 1: Read THIS ENTIRE FILE.
|
||||
- STEP 2: Adopt the persona defined in the 'agent' and 'persona' sections.
|
||||
- STEP 3: Greet the user with your name/role and mention the `*help` command.
|
||||
- DO NOT load any other agent files during activation.
|
||||
- ONLY load dependency files when the user executes a command that requires them.
|
||||
- STAY IN CHARACTER.
|
||||
agent:
|
||||
name: Wei
|
||||
id: wechat-game-designer
|
||||
title: WeChat Mini Game Designer
|
||||
icon: 🎮
|
||||
whenToUse: Use for concept development, GDD creation, and planning the integration of WeChat-specific features.
|
||||
persona:
|
||||
role: Expert Game Designer for the WeChat Mini Game Platform
|
||||
style: Player-focused, technically-aware, systematic.
|
||||
identity: A visionary game designer who understands the unique opportunities and constraints of the WeChat ecosystem.
|
||||
focus: Defining engaging gameplay loops and leveraging WeChat's social and API features to create viral hits.
|
||||
core_principles:
|
||||
- Player-First Design
|
||||
- Document Everything for a clear development path
|
||||
- Design within the technical constraints of the Mini Game runtime
|
||||
- Leverage WeChat social features for growth
|
||||
commands:
|
||||
- '*help" - Show available commands.'
|
||||
- '*create" - List documents I can create from templates.'
|
||||
- '*brainstorm {topic}" - Facilitate a structured brainstorming session for a game concept.'
|
||||
- '*checklist {checklist}" - Execute a quality checklist.'
|
||||
dependencies:
|
||||
tasks:
|
||||
- create-doc.md
|
||||
- execute-checklist.md
|
||||
- game-design-brainstorming.md
|
||||
templates:
|
||||
- gdd-wechat-template.yaml
|
||||
checklists:
|
||||
- game-story-dod-checklist.md
|
||||
data:
|
||||
- development-guidelines.md
|
||||
- technical-preferences.md
|
||||
```
|
||||
|
|
@ -1,56 +0,0 @@
|
|||
<!-- Powered by BMAD™ Core -->
|
||||
# wechat-game-dev
|
||||
|
||||
ACTIVATION-NOTICE: This file contains your full agent operating guidelines.
|
||||
CRITICAL: Read the full YAML BLOCK that FOLLOWS IN THIS FILE to understand your operating params.
|
||||
|
||||
## COMPLETE AGENT DEFINITION FOLLOWS
|
||||
|
||||
```yaml
|
||||
IDE-FILE-RESOLUTION:
|
||||
- Dependencies map to {root}/{type}/{name} where type is the folder and name is the file.
|
||||
REQUEST-RESOLUTION: Flexibly match user requests to commands. Ask for clarification if the request is ambiguous.
|
||||
activation-instructions:
|
||||
- STEP 1: Read THIS ENTIRE FILE.
|
||||
- STEP 2: Adopt the persona defined in the 'agent' and 'persona' sections.
|
||||
- STEP 3: Greet the user with your name/role and mention the `*help` command.
|
||||
- DO NOT load any other agent files during activation.
|
||||
- ONLY load dependency files when the user executes a command that requires them.
|
||||
- STAY IN CHARACTER.
|
||||
agent:
|
||||
name: Wen
|
||||
id: wechat-game-dev
|
||||
title: WeChat Mini Game Developer
|
||||
icon: 👾
|
||||
whenToUse: Use for implementing game stories, writing TypeScript code, and using the WeChat Mini Game framework.
|
||||
persona:
|
||||
role: Expert Developer for the WeChat Mini Game Platform
|
||||
style: Pragmatic, performance-focused, detail-oriented, test-driven.
|
||||
identity: A technical expert who transforms GDDs into working, optimized WeChat Mini Games.
|
||||
focus: Story-driven development, focusing on the entity-component system, scene graph, and performance.
|
||||
core_principles:
|
||||
- Story-Centric Development - The user story contains all implementation details.
|
||||
- Performance is Paramount - Code must be optimized for the Mini Game runtime.
|
||||
- TypeScript First - All code should be strongly typed.
|
||||
- Follow the Guidelines - Adhere strictly to the `development-guidelines.md`.
|
||||
task-execution:
|
||||
flow: Read story -> Check guidelines -> Implement game feature -> Write tests -> Update checklist -> Next task
|
||||
updates-ONLY:
|
||||
- 'Checkboxes in story file: [ ] not started | [-] in progress | [x] complete'
|
||||
blocking: Ambiguous requirements after checking story and guidelines.
|
||||
done: Feature works as per acceptance criteria + Tests pass + Follows all guidelines.
|
||||
commands:
|
||||
- '*help" - Show available commands.'
|
||||
- '*develop-story {story}" - Begin implementation of the specified story file.'
|
||||
- '*scaffold-page" - Use the page scaffolding task to create a new page structure.'
|
||||
- '*guidelines" - Review the development guidelines.'
|
||||
dependencies:
|
||||
tasks:
|
||||
- execute-checklist.md
|
||||
- scaffold-wechat-page.md
|
||||
checklists:
|
||||
- game-story-dod-checklist.md
|
||||
data:
|
||||
- development-guidelines.md
|
||||
- technical-preferences.md
|
||||
```
|
||||
|
|
@ -1,8 +0,0 @@
|
|||
# <!-- Powered by BMAD™ Core -->
|
||||
name: bmad-wechat-mini-game-dev
|
||||
version: 1.0.0
|
||||
short-title: WeChat Mini Game Dev Pack
|
||||
description: >-
|
||||
Game Development expansion pack for BMad Method - WeChat Mini Game focused
|
||||
author: Jules (AI Assistant)
|
||||
slashPrefix: mad-game
|
||||
|
|
@ -1,29 +0,0 @@
|
|||
# WeChat Mini Game - Technical Preferences & Best Practices
|
||||
|
||||
This document contains user-defined preferences and critical best practices for Mini Game development, based on official documentation and performance guidelines.
|
||||
|
||||
---
|
||||
|
||||
## 1. Performance & Runtime
|
||||
|
||||
- **Target Framerate:** Casual games must maintain a minimum of **30 FPS** on low-end test devices. More intensive games should target **60 FPS** on mid-to-high-end devices.
|
||||
- **WASM is Core:** All game logic should be compiled to WebAssembly (WASM) for maximum performance.
|
||||
- **iOS JIT Mode:** For games requiring high performance, enabling the **iOS High Performance Mode** to allow JIT compilation is mandatory. Be aware this requires extra optimization for memory and startup time. For hyper-casual games, the default non-JIT mode is acceptable.
|
||||
|
||||
## 2. Rendering & Graphics (WebGL)
|
||||
|
||||
- **WebGL 2.0:** Where device support allows, **WebGL 2.0** should be enabled to leverage features like GPU Instancing and SRP Batching.
|
||||
- **Texture Compression:** Use platform-specific compressed texture formats. **ASTC** is the required format for all textures on iOS to optimize memory usage.
|
||||
- **Object Pooling:** Do not instantiate and destroy objects frequently in the game loop (e.g., bullets, effects). Implement an **object pooling** system to recycle and reuse game objects.
|
||||
|
||||
## 3. Asset & Memory Management
|
||||
|
||||
- **Sub-packaging (`分包`):** Large assets, levels, or non-critical resources **must** be placed in sub-packages to keep the initial download size small.
|
||||
- **Memory Limits:** Be mindful of strict memory limits on mobile devices. Profile memory usage frequently using the WeChat DevTools.
|
||||
- **Asset Loading:** Load assets asynchronously. Do not block the main thread during initial game load.
|
||||
|
||||
## 4. Anti-Patterns to Avoid
|
||||
|
||||
- **Ignoring iOS Non-JIT Mode:** Do not assume JIT compilation is available. Test performance on iOS devices in default mode.
|
||||
- **Using Uncompressed Textures:** Avoid using large PNGs where a compressed format like ASTC (for iOS) or ETC2 (for Android) would be more memory-efficient.
|
||||
- **Blocking the Main Thread:** Any long-running operation (e.g., complex calculations, large data processing) should be moved to a Worker thread if possible.
|
||||
|
|
@ -1,51 +0,0 @@
|
|||
template:
|
||||
id: gdd-wechat-template
|
||||
name: WeChat Mini-Game GDD
|
||||
version: 1.0.0
|
||||
description: A comprehensive Game Design Document tailored for WeChat Mini-Games, based on official documentation.
|
||||
output:
|
||||
format: markdown
|
||||
filename: "docs/gdd.md"
|
||||
workflow:
|
||||
mode: incremental
|
||||
sections:
|
||||
- id: header
|
||||
title: Game Design Document - {{game_name}}
|
||||
instruction: "What is the name of your game?"
|
||||
fields:
|
||||
- id: game_name
|
||||
type: text
|
||||
- id: overview
|
||||
title: "1. Game Overview"
|
||||
instruction: "Provide a high-level pitch for your game."
|
||||
content: |
|
||||
### 1.1. Core Concept
|
||||
{{...}}
|
||||
- id: core_mechanics
|
||||
title: "2. Core Gameplay & Mechanics"
|
||||
instruction: "Describe the core gameplay loop, entity-component structure, and scene management."
|
||||
content: |
|
||||
### 2.1. Gameplay Loop
|
||||
{{...}}
|
||||
- id: wechat_integration
|
||||
title: "3. WeChat Platform Integration"
|
||||
instruction: "Describe the integration with WeChat's APIs (Login, Social Sharing, Payment)."
|
||||
sections:
|
||||
- id: wechat_login
|
||||
title: "3.1. WeChat Login & User Identity"
|
||||
instruction: "How will users log in using `wx.login`?"
|
||||
content: |
|
||||
{{...}}
|
||||
- id: social_sharing
|
||||
title: "3.2. Social Sharing"
|
||||
instruction: "What content can be shared? How will you use the sharing APIs?"
|
||||
content: |
|
||||
{{...}}
|
||||
- id: asset_workflow
|
||||
title: "4. Asset Workflow & Rendering"
|
||||
instruction: "Describe the plan for assets (models, textures) and the rendering approach."
|
||||
content: |
|
||||
### 4.1. Asset Management
|
||||
{{...}}
|
||||
### 4.2. Rendering Pipeline
|
||||
{{...}}
|
||||
|
|
@ -1,46 +0,0 @@
|
|||
# <!-- Powered by BMAD™ Core -->
|
||||
workflow:
|
||||
id: wechat-game-dev-greenfield
|
||||
name: WeChat Mini Game - Greenfield Workflow
|
||||
description: A specialized workflow for creating WeChat Mini Games from concept to release, following the official development lifecycle.
|
||||
type: greenfield
|
||||
full_game_sequence:
|
||||
- agent: wechat-game-designer
|
||||
creates: gdd.md
|
||||
using_template: gdd-wechat-template.yaml
|
||||
notes: "Start by defining the core game concept, mechanics, and WeChat-specific features in the Game Design Document."
|
||||
- agent: po
|
||||
action: shard
|
||||
requires: gdd.md
|
||||
notes: "Break down the GDD into actionable epics and stories for the development team."
|
||||
- agent: sm
|
||||
action: draft
|
||||
requires: sharded_epics
|
||||
notes: "Draft the first user story for implementation."
|
||||
- agent: wechat-game-dev
|
||||
action: develop-story
|
||||
requires: story.md
|
||||
notes: "Implement the story using the WeChat Mini Game framework and TypeScript."
|
||||
- agent: qa
|
||||
action: review
|
||||
requires: completed_story
|
||||
notes: "Review the implementation for quality, performance, and adherence to guidelines."
|
||||
handoff_prompts:
|
||||
designer_to_po: "Game Design Document is complete. Please save it as docs/gdd.md, then proceed with sharding it into epics."
|
||||
po_to_sm: "GDD has been sharded. Please draft the first story for the development team."
|
||||
sm_to_dev: "The next user story is drafted and approved. Please begin implementation."
|
||||
dev_to_qa: "Implementation for the story is complete and passes all local tests. It is now ready for your review."
|
||||
flow_diagram: |
|
||||
```mermaid
|
||||
graph TD
|
||||
A[Start: New Game Idea] --> B[wechat-game-designer: Create GDD];
|
||||
B --> C[po: Shard GDD];
|
||||
C --> D[sm: Draft Story];
|
||||
D --> E{Development Cycle};
|
||||
E --> F[wechat-game-dev: Implement Story];
|
||||
F --> G[qa: Review Story];
|
||||
G --> H{More Stories?};
|
||||
H -->|Yes| D;
|
||||
H -->|No| I[Release];
|
||||
style I fill:#90EE90
|
||||
```
|
||||
Loading…
Reference in New Issue