Files
FlowScope/docs/superpowers/specs/2026-05-14-game-core-requirement-tiers.md
2026-05-15 15:38:40 +08:00

90 lines
2.6 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# FlowScope Game Core 需求分档
## 背景
FlowScope Game Core 的 P0 需求已经从早期“大而全框架蓝图”收敛为一套可执行的最小纵向切片。旧讨论中的部分能力已经重新分档:
- DI 自动注入进入 P0但 Container 核心保持轻量。
- UI 层级从固定三层改为可配置层级。
- UI 层内 LIFO 栈进入 P0完整导航路由延后。
- 配置 P0 只支持 JSON。
- 存档 P0 只支持本地轻量实现。
- 资源 P0 支持引用计数,但只保留 Addressables 默认后端。
- 音频 P0 只保留基础 BGM/SFX 能力和轻量 AudioHandle。
## 当前 P0 单一事实来源
P0 详细需求以以下文档为准:
- `docs/requirements/p0-requirements-set.md`
- `docs/requirements/p0-container.md`
- `docs/requirements/p0-gameflow.md`
- `docs/requirements/p0-feature.md`
- `docs/requirements/p0-data-r3.md`
- `docs/requirements/p0-configprovider.md`
- `docs/requirements/p0-saveservice.md`
- `docs/requirements/p0-resourceservice.md`
- `docs/requirements/p0-uimanager.md`
- `docs/requirements/p0-audioservice.md`
并行实施计划:
- `docs/superpowers/plans/2026-05-15-p0-parallel-implementation-plan.md`
---
## P0最小可运行核心
目标:跑通一个真实休闲/超休闲 Unity 游戏的启动、配置加载、存档加载、Feature 生命周期、MVVM UI、资源释放、音频播放和退出保存。
P0 包含:
| 模块 | P0 决策 |
|------|---------|
| Container | 显式工厂、Source Generator 自动注入、运行时反射降级 |
| GameFlow | 全局生命周期编排和 FeatureContext 所有权 |
| Feature | 消费 FeatureContext负责业务行为和引用清理 |
| R3 + Data | 直接使用 R3Data 保持纯 C# |
| ConfigProvider | JSON-only 强类型配置 |
| SaveService | 本地轻量存档 |
| ResourceService | Addressables-only 默认后端,支持引用计数 |
| UIManager | 可配置层级,层内 LIFO |
| AudioService | BGM/SFX、音量、静音、简单 SFX 池 |
---
## P1生产能力扩展
P1 只在 P0 接口稳定后推进,优先做成扩展而不是污染核心。
- CSV / Luban 配置插件。
- 按模块配置加载。
- 存档版本迁移。
- Resources / YooAsset 后端。
- UI 返回策略。
- Panel 预加载。
- AudioMixer / 3D 音频。
---
## P2包分发与编辑器体验
- Unity Package 分发。
- Samples~。
- Editor 导入向导。
- 配置检查工具。
- 资源扫描工具。
- 云存档适配。
- AssetBundle 适配。
---
## P3长期演进
- `[Inject]` 属性/方法注入。
- 全局 EventBus。
- 网络长连接。
- 热更新框架。
- UI 自动绑定。
- 大型项目资源预算和内存分析。