refactor(editor): reorganize Editor directory and unify menu hierarchy
File directory changes (mirror Scripts/ module structure): - AbilityTypeDrawer.cs → Equipment/ - CharacterWizardWindow.cs → Character/ - FormEditorWindow.cs → Player/ - GMToolWindow.cs → Tools/ - SOManagerWindow.cs → Tools/ - Map/MapRoomDataEditor.cs → World/Map/ - Navigation/ (root) → Enemies/Navigation/ - Achievements/ → Progression/ Menu hierarchy changes (BaseGames/ top-level): - Data/: +Character Wizard (from Tools/), +Boss Skill Sequence (from Tools/) - Addressables/: +Addressable Batch Tool, +Asset Reference Graph, +Validate Address Keys (from Tools/Verification/) - Scene/Setup/: +Boot Flow Wizard, +Scaffold *, +Auto-Open Persistent (from Tools/) - Scene/: +Camera Area Setup (from Camera/), +Bake All NavSurfaces (from Tools/) - Events/: +Event Bus Monitor, +Event Chain Viewer, +Create/Reimport Event Channels (from Tools/) - Tools/Validation/: +Validate All SOs, +Apply/Validate Script Order (from Tools/ flat) - Tools/Maintenance/: +Missing Scripts/*, +Physics2D Layer Matrix/* (from Tools/ flat) Result: BaseGames/Tools/ reduced from 16 flat items to 4 items + 2 submenus Docs: update AssetFolderSpec §12 editor tool table with new menu paths Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
@@ -652,11 +652,11 @@ var (prefab, _) = await AssetLoader.LoadAsync<GameObject>(AddressKeys.PrefabPlay
|
||||
4. 在 Animations/ 下创建动画片段(.anim)和 Animator Controller
|
||||
5. 在 Materials/ 下创建材质(引用 _Game/Shaders/ 中的角色 Shader,关联主纹理和 Emission 贴图)
|
||||
6. 在 Atlases/ 下创建 Atlas_Enemy_{ID}.spriteatlas,包含该敌人所有 Sprite
|
||||
7. 在 Enemy Data Manager(菜单 BaseGames → Data → Enemy Data Manager)创建 ENM_{ID}_Stats.asset
|
||||
7. 在 Enemy Data Manager(菜单 BaseGames/Data/Enemy Data Manager)创建 ENM_{ID}_Stats.asset
|
||||
8. 在 _Game/Prefabs/Enemies/{EnemyID}/ 下创建 ENM_{Name}.prefab
|
||||
9. 在 AddressKeys.cs 中添加 PrefabEnemy{Name} 常量
|
||||
10. 使用 Rule Sync(菜单 BaseGames → Addressables → Rule Sync)Scan → Fix All,自动分组并打 Enemy 标签
|
||||
11. 运行 AddressKeyValidator(菜单 BaseGames → Verification → Validate Address Keys)验证
|
||||
10. 使用 Rule Sync(菜单 BaseGames/Addressables/Rule Sync)Scan → Fix All,自动分组并打 Enemy 标签
|
||||
11. 运行 AddressKeyValidator(菜单 BaseGames/Addressables/Validate Address Keys)验证
|
||||
```
|
||||
|
||||
### 10.2 新增武器(Weapon)
|
||||
@@ -665,10 +665,10 @@ var (prefab, _) = await AssetLoader.LoadAsync<GameObject>(AddressKeys.PrefabPlay
|
||||
|
||||
```
|
||||
1. 在 _Game/Art/Characters/Player/{FormID}/Sprites/ 下放置武器帧动画 Sprite Sheet,配置 Import Settings
|
||||
2. 在 Weapon Editor(菜单 BaseGames → Data → Weapon Editor)左栏 [New] 创建 WPN_{Name}_Data.asset
|
||||
2. 在 Weapon Editor(菜单 BaseGames/Data/Weapon Editor)左栏 [New] 创建 WPN_{Name}_Data.asset
|
||||
- 路径:_Game/Data/Combat/Weapons/WPN_{Name}_Data.asset
|
||||
- 命名:WPN_{Name}(示例:WPN_SkyBlade、WPN_EarthClaw)
|
||||
3. 使用 Weapon HitBox Wizard(菜单 BaseGames → Create → Weapon HitBox Prefab)生成
|
||||
3. 使用 Weapon HitBox Wizard(菜单 BaseGames/Create/Weapon HitBox Prefab)生成
|
||||
_Game/Prefabs/Weapons/WPN_{Name}_HitBox.prefab(自动创建 4 方向 Ground/Up/Down/Air)
|
||||
4. 在 _Game/Prefabs/Player/ 下创建或更新武器顶级 Prefab WPN_{Name}.prefab
|
||||
5. 在 AddressKeys.cs 中添加 PrefabWeapon{Name} 常量
|
||||
@@ -682,10 +682,10 @@ var (prefab, _) = await AssetLoader.LoadAsync<GameObject>(AddressKeys.PrefabPlay
|
||||
|
||||
```
|
||||
1. 在 _Game/Art/Characters/Player/{FormID}/Animations/ 下创建技能动画片段(.anim)
|
||||
2. 在 Skill Editor(菜单 BaseGames → Data → Skill Editor)左栏 [New] 创建 SKL_{SkillID}_Data.asset
|
||||
2. 在 Skill Editor(菜单 BaseGames/Data/Skill Editor)左栏 [New] 创建 SKL_{SkillID}_Data.asset
|
||||
- 路径:_Game/Data/Player/Skills/SKL_{SkillID}_Data.asset
|
||||
- 命名:SKL_{SkillID}(示例:SKL_DashSlash、SKL_SpiritWave)
|
||||
3. 使用 Skill HitBox Wizard(菜单 BaseGames → Create → Skill HitBox Prefab)生成
|
||||
3. 使用 Skill HitBox Wizard(菜单 BaseGames/Create/Skill HitBox Prefab)生成
|
||||
_Game/Prefabs/Skills/SKL_{SkillID}_HitBox.prefab(支持多段伤害配置)
|
||||
4. 在 AddressKeys.cs 中添加对应常量(如需独立 Addressable 加载)
|
||||
5. 运行 AddressKeyValidator 验证(如已注册 Addressable)
|
||||
@@ -709,11 +709,11 @@ var (prefab, _) = await AssetLoader.LoadAsync<GameObject>(AddressKeys.PrefabPlay
|
||||
> **推荐工具**:`BaseGames → Tools → Character Wizard`(`CharacterWizardWindow`)统一入口——创建 FormSO、绑定武器引用、跳转到 Form Editor;`BaseGames → Data → Form Editor`(`FormEditorWindow`)进行三魂列阵可视化编辑。
|
||||
|
||||
```
|
||||
1. 在 Character Wizard(菜单 BaseGames → Tools → Character Wizard)切换到 Player 标签
|
||||
1. 在 Character Wizard(菜单 BaseGames/Data/Character Wizard)切换到 Player 标签
|
||||
- 填写 FormID,点击 [Create Form Assets],自动在正确路径创建 FormSO 和相关 SO
|
||||
2. 在 _Game/Art/Characters/Player/{FormID}/ 下创建 Sprites/ Animations/ Materials/ Atlases/ 目录
|
||||
3. 导入 Sprite Sheet,配置 Import Settings(PPU=32, Filter=Point, Multiple)
|
||||
4. 在 Form Editor(菜单 BaseGames → Data → Form Editor)三栏网格中选择形态格位,绑定武器和技能列表
|
||||
4. 在 Form Editor(菜单 BaseGames/Data/Form Editor)三栏网格中选择形态格位,绑定武器和技能列表
|
||||
5. 在 _Game/Prefabs/Player/ 下创建 PLY_{FormID}.prefab
|
||||
6. 在 AddressKeys.cs 中添加 PrefabPlayer{FormID} 常量(如为独立 Addressable)
|
||||
7. 使用 Rule Sync 自动分组(Player 组)并打 Preload 标签
|
||||
@@ -783,40 +783,56 @@ var (prefab, _) = await AssetLoader.LoadAsync<GameObject>(AddressKeys.PrefabPlay
|
||||
|
||||
| 工具名称 | 菜单路径 | 负责资产类型 | 说明 |
|
||||
|---------|---------|------------|------|
|
||||
| **Character Wizard** | `BaseGames → Tools → Character Wizard` | 角色 SO(玩家形态 / Minion / Boss 通用入口) | 统一入口,自动在正确路径创建所有配套 SO,内含快捷跳转按钮 |
|
||||
| **Form Editor** | `BaseGames → Data → Form Editor` | 玩家三魂形态(FormSO) | 三栏可视化网格,自动绑定武器/技能引用,支持 TianHun / DiHun / MingHun |
|
||||
| **Enemy Data Manager** | `BaseGames → Data → Enemy Data Manager` | 敌人配置 SO(`ENM_*_Stats.asset`)+ 掉落表 | 双面板列表编辑,左栏搜索 + [New],右栏 Stats/Loot 标签 |
|
||||
| **Weapon Editor** | `BaseGames → Data → Weapon Editor` | 武器配置 SO(`WPN_*_Data.asset`) | 双面板列表,右栏全属性 + HitBox Prefab 验证 + 快捷操作 |
|
||||
| **Weapon HitBox Wizard** | `BaseGames → Create → Weapon HitBox Prefab` | 武器 HitBox Prefab(4 方向 Ground/Up/Down/Air) | 自动生成 `WPN_{ID}_HitBox.prefab`,支持各方向碰撞体形状配置 |
|
||||
| **Skill Editor** | `BaseGames → Data → Skill Editor` | 技能配置 SO(`SKL_*_Data.asset`) | 按 SkillEffectType 分组筛选,右栏含 HitBox 验证 + 资源费预览 |
|
||||
| **Skill HitBox Wizard** | `BaseGames → Create → Skill HitBox Prefab` | 技能 HitBox Prefab(多段伤害支持) | 自动生成 `SKL_{ID}_HitBox.prefab`,可配置 1–4 段 hitBoxCount |
|
||||
| **Boss Skill Sequence** | `BaseGames → Tools → Boss Skill Sequence Viewer` | Boss 技能阶段(BossSkillSO / SkillSequenceSO) | Gantt 时间轴可视化,Windup / Active / Recovery 三段颜色标记 |
|
||||
| **Character Wizard** | `BaseGames/Data/Character Wizard` | 角色 SO(玩家形态 / Minion / Boss 通用入口) | 统一入口,自动在正确路径创建所有配套 SO,内含快捷跳转按钮 |
|
||||
| **Form Editor** | `BaseGames/Data/Form Editor` | 玩家三魂形态(FormSO) | 三栏可视化网格,自动绑定武器/技能引用,支持 TianHun / DiHun / MingHun |
|
||||
| **Enemy Data Manager** | `BaseGames/Data/Enemy Data Manager` | 敌人配置 SO(`ENM_*_Stats.asset`)+ 掉落表 | 双面板列表编辑,左栏搜索 + [New],右栏 Stats/Loot 标签 |
|
||||
| **Boss Skill Sequence** | `BaseGames/Data/Boss Skill Sequence` | Boss 技能阶段(BossSkillSO / SkillSequenceSO) | Gantt 时间轴可视化,Windup / Active / Recovery 三段颜色标记 |
|
||||
| **Skill Editor** | `BaseGames/Data/Skill Editor` | 技能配置 SO(`SKL_*_Data.asset`) | 按 SkillEffectType 分组筛选,右栏含 HitBox 验证 + 资源费预览 |
|
||||
| **Weapon Editor** | `BaseGames/Data/Weapon Editor` | 武器配置 SO(`WPN_*_Data.asset`) | 双面板列表,右栏全属性 + HitBox Prefab 验证 + 快捷操作 |
|
||||
| **Weapon HitBox Wizard** | `BaseGames/Create/Weapon HitBox Prefab` | 武器 HitBox Prefab(4 方向 Ground/Up/Down/Air) | 自动生成 `WPN_{ID}_HitBox.prefab`,支持各方向碰撞体形状配置 |
|
||||
| **Skill HitBox Wizard** | `BaseGames/Create/Skill HitBox Prefab` | 技能 HitBox Prefab(多段伤害支持) | 自动生成 `SKL_{ID}_HitBox.prefab`,可配置 1–4 段 hitBoxCount |
|
||||
|
||||
### 12.2 场景搭建工具
|
||||
|
||||
| 工具名称 | 菜单路径 | 说明 |
|
||||
|---------|---------|------|
|
||||
| **Boot Flow Wizard** | `BaseGames → Tools → Boot Flow Wizard` | 4 步启动流程一键配置(事件频道 → Persistent 场景 → MainMenu → 验证) |
|
||||
| **Scene Scaffold** | `BaseGames → Tools → Scaffold Persistent Scene` | 一键创建 Persistent 场景的 Services/Input/Camera/UI 层次结构 |
|
||||
| **Scene Object Placer** | `BaseGames → Scene → Place → {类型}` | 场景中快速放置角色/陷阱/检查点/摄像机等,自动绑定组件和事件频道 |
|
||||
| **Persistent Auto-Loader** | `BaseGames → Tools → Edit Mode: Auto-Open Persistent Scene` | 编辑模式下打开任意场景时自动附加 Persistent(仅编辑模式) |
|
||||
| **Boot Flow Wizard** | `BaseGames/Scene/Setup/Boot Flow Wizard` | 4 步启动流程一键配置(事件频道 → Persistent 场景 → MainMenu → 验证) |
|
||||
| **Scaffold Persistent Scene** | `BaseGames/Scene/Setup/Scaffold Persistent Scene` | 一键创建 Persistent 场景的 Services/Input/Camera/UI 层次结构 |
|
||||
| **Scaffold Main Menu Scene** | `BaseGames/Scene/Setup/Scaffold Main Menu Scene` | 一键创建 MainMenu 场景基础层次结构 |
|
||||
| **Scaffold Game Room** | `BaseGames/Scene/Setup/Scaffold Game Room` | 一键创建关卡房间场景基础层次结构 |
|
||||
| **Persistent Auto-Loader** | `BaseGames/Scene/Setup/Auto-Open Persistent Scene` | 编辑模式下打开任意场景时自动附加 Persistent(Toggle,仅编辑模式) |
|
||||
| **Scene Object Placer** | `BaseGames/Scene/Place/{类型}` | 场景中快速放置角色/陷阱/检查点/摄像机等,自动绑定组件和事件频道 |
|
||||
| **Camera Area Setup** | `BaseGames/Scene/Camera Area Setup` | 在当前场景中快速创建并配置摄像机区域 |
|
||||
| **Bake All NavSurfaces** | `BaseGames/Scene/Bake All NavSurfaces` (Ctrl+Shift+B) | 一键烘焙场景中所有 NavSurface,仅编辑模式可用 |
|
||||
|
||||
### 12.3 Addressables 管理工具
|
||||
|
||||
| 工具名称 | 菜单路径 | 说明 |
|
||||
|---------|---------|------|
|
||||
| **Rule Sync** | `BaseGames → Addressables → Rule Sync` | 批量扫描/修复分组和标签(基于 `AddressableRules.cs` 规则,支持导出 CSV) |
|
||||
| **Addressable Batch Tool** | `BaseGames → Tools → Addressable Batch Tool` | 三标签操作:① 同步 AddressKeys → ② 文件夹批量注册 → ③ Selection 注册 |
|
||||
| **Validate Address Keys** | `BaseGames → Verification → Validate Address Keys` | 验证 `AddressKeys.cs` 所有常量在 Addressables 中均已注册,构建前自动触发 |
|
||||
| **Rule Sync** | `BaseGames/Addressables/Rule Sync` | 批量扫描/修复分组和标签(基于 `AddressableRules.cs` 规则,支持导出 CSV) |
|
||||
| **Addressable Batch Tool** | `BaseGames/Addressables/Addressable Batch Tool` (Alt+Shift+A) | 三标签操作:① 同步 AddressKeys → ② 文件夹批量注册 → ③ Selection 注册 |
|
||||
| **Asset Reference Graph** | `BaseGames/Addressables/Asset Reference Graph` | 可视化 Addressable 地址间的引用依赖关系 |
|
||||
| **Validate Address Keys** | `BaseGames/Addressables/Validate Address Keys` | 验证 `AddressKeys.cs` 所有常量在 Addressables 中均已注册,构建前自动触发 |
|
||||
|
||||
### 12.4 数据/调试工具
|
||||
### 12.4 事件系统工具
|
||||
|
||||
| 工具名称 | 菜单路径 | 说明 |
|
||||
|---------|---------|------|
|
||||
| **SO Manager** | `BaseGames → Tools → SO Manager` | 全项目 ScriptableObject 浏览器,支持类型/路径搜索 + Ping |
|
||||
| **Event Bus Monitor** | `BaseGames → Tools → Event Bus Monitor` | 运行时事件派发监控(类型/侦听器数/触发次数实时显示) |
|
||||
| **Create Event Channel Assets** | `BaseGames → Tools → Create Event Channel Assets` | 一键生成全局事件频道 SO(幂等,跳过已存在资产) |
|
||||
| **GM Debug Tool** | `BaseGames → Tools → GM Debug Tool` | 运行时快速注入资源/切换形态/解锁技能(仅 PlayMode) |
|
||||
| **Validate All ScriptableObjects** | `BaseGames → Tools → Validate All ScriptableObjects` | 扫描所有 `IValidatable` SO 并报告错误(构建前自动触发) |
|
||||
| **Event Bus Monitor** | `BaseGames/Events/Event Bus Monitor` (Ctrl+Shift+E) | 运行时事件派发监控(类型/侦听器数/触发次数实时显示) |
|
||||
| **Event Chain Viewer** | `BaseGames/Events/Event Chain Viewer` | 叙事事件链可视化,运行时显示完成/满足/等待状态 |
|
||||
| **Create Event Channels** | `BaseGames/Events/Create Event Channels` | 一键生成全局事件频道 SO(幂等,跳过已存在资产) |
|
||||
| **Reimport Event Channels** | `BaseGames/Events/Reimport Event Channels` | 重新导入/刷新全局事件频道 SO |
|
||||
|
||||
> **原则**:新增资产类型时,必须同步在对应编辑器工具中增加创建入口;严禁绕过工具手动在 Project 窗口 "Create" 并手动填写路径/命名,否则将导致 Addressables Rule Sync 工具误报分组或标签不一致。
|
||||
### 12.5 工具与维护
|
||||
|
||||
| 工具名称 | 菜单路径 | 说明 |
|
||||
|---------|---------|------|
|
||||
| **SO Manager** | `BaseGames/Tools/SO Manager` | 全项目 ScriptableObject 浏览器,支持类型/路径搜索 + Ping |
|
||||
| **GM Debug Tool** | `BaseGames/Tools/GM Debug Tool` | 运行时快速注入资源/切换形态/解锁技能(仅 PlayMode) |
|
||||
| **Validate All SOs** | `BaseGames/Tools/Validation/Validate All ScriptableObjects` | 扫描所有 `IValidatable` SO 并报告错误(构建前自动触发) |
|
||||
| **Apply Script Order** | `BaseGames/Tools/Validation/Apply Script Execution Order Preset` | 将脚本执行顺序预设应用到项目 |
|
||||
| **Validate Script Order** | `BaseGames/Tools/Validation/Validate Script Execution Order Preset` | 验证当前脚本执行顺序是否符合预设 |
|
||||
| **Missing Scripts (Scene)** | `BaseGames/Tools/Maintenance/Missing Scripts/...` | 在场景/Prefab 中查找或清除 Missing Script 引用 |
|
||||
| **Physics2D Layer Matrix** | `BaseGames/Tools/Maintenance/Physics2D Layer Matrix/...` | 检查或自动修复 Physics2D 层碰撞矩阵配置 |
|
||||
|
||||
> **原则**:新增资产类型时,必须同步在对应编辑器工具中增加创建入口;严禁绕过工具手动在 Project 窗口 "Create" 并手动填写路径/命名,否则将导致 Addressables Rule Sync 工具误报分组或标签不一致。
|
||||
Reference in New Issue
Block a user