docs(review): P-008交互系统程序设计质量门审查通过+美术调研+工作流完善

- P-008 交互系统技术设计审查通过,审查记录 docs/plans/reviews/P-008-review.md
- D-001 关卡执行案审查通过,审查记录 docs/plans/reviews/D-001-review.md
- 新增 AI 美术调研参考图(我的暑假/放学后少年/真实场景/美术风格)
- 新增关卡执行案、白模搭建指南和搭建报告
- 完善工作流技能:质量门审查、Agent记忆、需求分析
- 更新交互系统和角色控制系统技术设计文档
- 清理过时参考文档
This commit is contained in:
2026-06-07 01:54:02 +08:00
parent dec183ff02
commit 8011cb6472
276 changed files with 5630 additions and 1633 deletions
File diff suppressed because it is too large Load Diff
+792
View File
@@ -0,0 +1,792 @@
# v0.1 白模搭建操作指南 — 城郊小街
> 本文档为 P-006 任务产出,供在 UE5 编辑器中按步骤搭建白模关卡使用。
> 每条指令包含:Actor 命名、资产路径、世界坐标、旋转、缩放、材质。
> 最后更新:2026-06-07
---
## 〇、全局信息
### 场景参数
| 参数 | 值 |
|------|-----|
| 场景总尺寸 | 8000cm × 6000cm(80m × 60m) |
| 地面高度基准 | Z = 0 |
| 主角身高 | ~120cm |
| 摄像机高度 | ~100cm |
| 时间设定 | 夏日午后 15:00 |
| 坐标原点 | 场景西南角地平面 |
### UE5 路径前缀
- **Mesh**: `Content/BlockingStarterPack/Meshes/`
- **Material**: `Content/BlockingStarterPack/Materials/`
- **Material (Basics)**: `Content/BlockingStarterPack/Materials/Blocking/Basics/`
- **Material (Glass)**: `Content/BlockingStarterPack/Materials/Glass/`
- **Material (Light)**: `Content/BlockingStarterPack/Materials/Light/`
### 命名规范
```
LVL_<ZoneID>_<Category>_<Description>
Category: STR | PROP | INTR | COLL | BND | LGT
```
### Outliner 文件夹结构
```
LVL_SuburbanV01/
Z1_家/
Structure/ Props/ Interactables/ Collectibles/
Z2_小卖部/
Structure/ Props/ Interactables/ Collectibles/
Z3_主街道/
Structure/ Props/ Interactables/ Collectibles/
Z4_空地/
Structure/ Props/ Interactables/ Collectibles/
Z5_巷子/
Structure/ Props/ Interactables/ Collectibles/
Z6_水塘边/
Structure/ Props/ Interactables/ Collectibles/
Z7_老居民楼/
Structure/ Props/
Global/
Boundaries/ Lighting/ PlayerStart/
```
---
## 一、BSP 资产映射表
### 1.1 建筑 — 墙体
| 设计文档引用 | UE5 资产路径 | 实际尺寸 (cm) |
|-------------|-------------|--------------|
| Wall_400x300 | `Architecture/Walls/SM_Wall_400x300` | 400×20×300 |
| Wall_200x300 | `Architecture/Walls/SM_Wall_200x300` | 200×20×300 |
| Wall_100x300 | `Architecture/Walls/SM_Wall_100x300` | 100×20×300 |
| Wall_400x100 | `Architecture/Walls/SM_Wall_400x100` | 400×20×100 |
| WallDoor_200x300 | `Architecture/Walls/SM_WallDoor_200x300` | 200×20×300 |
| WallDoorGarage_400x300 | `Architecture/Walls/SM_WallDoorGarage_400x300` | 400×20×300 |
| WallWindow_400x300 | `Architecture/Walls/SM_WallWindow_400x300` | 400×20×300 |
| WallWindowSmall_200x300 | `Architecture/Walls/SM_WallWindowSmall_200x300` | 200×20×300 |
> **注意**:Wall 厚度为 20cm。偏移坐标基于墙面中心点。执行案中偏移基于墙面外表面/内表面,放置时需微调 10cm(半墙厚)。
### 1.2 建筑 — 地板
| 设计文档引用 | UE5 资产路径 | 实际尺寸 (cm) |
|-------------|-------------|--------------|
| Floor_1000x1000 | `Architecture/Floors/SM_Floor_1000x1000` | 1000×1000×10 |
| Floor_300x400 | `Architecture/Floors/SM_Floor_300x400` | 300×400×10 |
| Floor_200x300 | `Architecture/Floors/SM_Floor_200x300` | 200×300×10 |
### 1.3 建筑 — 门
| 设计文档引用 | UE5 资产路径 | 说明 |
|-------------|-------------|------|
| RotativeDoor_01 | `Architecture/Doors/SM_RotativeDoor_01` | 旋转门 |
| GarageDoorOpen_01 | `Architecture/Doors/SM_GarageDoorOpen_01` | 卷帘门(开) |
### 1.4 建筑 — 窗户
| 设计文档引用 | UE5 资产路径 | 说明 |
|-------------|-------------|------|
| FakeWindowsFrame | `Architecture/WindowsSet/SM_FakeWindowsFrame` | 假窗(装饰) |
### 1.5 建筑 — 围栏/围挡
| 设计文档引用 | UE5 资产路径 | 实际尺寸 (cm) |
|-------------|-------------|--------------|
| BarrierWall_600 | `Architecture/Barriers/SM_BarrierWall_600` | 600×20×100 |
| BarrierWall_200 | `Architecture/Barriers/SM_BarrierWall_200` | 200×20×100 |
| Fence_Small_400 | `Industrials/SM_Fence_Small_400` | 400×5×100 |
### 1.6 建筑 — 横梁
| 设计文档引用 | UE5 资产路径 |
|-------------|-------------|
| Beam_300 | `Architecture/Beams/SM_Beam_300` |
### 1.7 建筑 — 大型建筑
| 设计文档引用 | UE5 资产路径 |
|-------------|-------------|
| Building_01 | `BigBuildings/SM_Building_01` |
### 1.8 家具
| 设计文档引用 | UE5 资产路径 |
|-------------|-------------|
| SimpleTable_01 | `Furnitures/SM_SimpleTable_01` |
| SimpleTable_02 | `Furnitures/SM_SimpleTable_02` |
| BedSingle | `Bedroom/SM_BedSingle` |
| Monitor_01 | `Furnitures/SM_Monitor_01` |
### 1.9 工业/装饰
| 设计文档引用 | UE5 资产路径 |
|-------------|-------------|
| Barrel | `Industrials/SM_Barrel` |
| WoodenBox_Small | `Industrials/SM_WoodenBox_Small` |
| WoodenBox_Normal | `Industrials/SM_WoodenBox_Normal` |
| WoodenPallet_01 | `Industrials/SM_WoodenPallet_01` |
| Bucket_01 | `Decorations/SM_Bucket_01` |
| TrashCans_01 | `Trashs/SM_TrashCans_01` |
| Container_Normal | `Industrials/SM_Container_Normal` |
### 1.10 载具
| 设计文档引用 | UE5 资产路径 |
|-------------|-------------|
| Car01 | `Vehicles/SM_Car01` |
### 1.11 基础体
| 设计文档引用 | UE5 资产路径 |
|-------------|-------------|
| Cube | `Primitives/SM_Cube` |
| Cylinder | `Primitives/SM_Cylinder` |
| CirclePlatform | `Extra/SM_CirclePlatform` |
### 1.12 其他
| 设计文档引用 | UE5 资产路径 |
|-------------|-------------|
| Tree_01 | `Vegetations/SM_Tree_01` |
| RoadLamp_01 | `Lights/SM_RoadLamp_01` |
| DisplayPanels_400x200 | `DisplayPanels/SM_DisplayPanels_400x200` |
### 1.13 标识色材质
| 材质名 | 路径 |
|--------|------|
| MI_DevRed | `Materials/Blocking/Basics/MI_DevRed` |
| MI_DevOrange | `Materials/Blocking/Basics/MI_DevOrange` |
| MI_DevGray | `Materials/Blocking/Basics/MI_DevGray` |
| MI_DevBrown | `Materials/Blocking/Basics/MI_DevBrown` |
| MI_DevWhite | `Materials/Blocking/Basics/MI_DevWhite` |
| MI_DevBlue | `Materials/Blocking/Basics/MI_DevBlue` |
| MI_DevGreen | `Materials/Blocking/Basics/MI_DevGreen` |
| MI_DevSkyBlue | `Materials/Blocking/Basics/MI_DevSkyBlue` |
| MI_DevYellow | `Materials/Blocking/Basics/MI_DevYellow` |
| MI_DevFoliage | `Materials/Blocking/Basics/MI_DevFoliage` |
| MI_DevPink | `Materials/Blocking/Basics/MI_DevPink` |
| MI_DevGlassWhite | `Materials/Glass/MI_DevGlassWhite` |
| MI_DevGlassBlue | `Materials/Glass/MI_DevGlassBlue` |
---
## 二、Phase A — 准备
### A3 创建关卡
1. 在 Content Browser 右键 → `New Level` → `Empty Level`
2. 保存到 `Content/Maps/LVL_SuburbanV01.umap`
3. World Settings → GameMode Override 选择项目 GameMode(暂无则留空)
4. 放置 Player Start Actor:
- 位置:(500, 720, 0)
- 旋转:(0, 0, 0)(面向 +Y 即北)
- 移入 Outliner `Global/PlayerStart/`
---
## 三、Phase B — 地面与边界
### B1 铺设地面
按区域铺设地面 Floor,使用 Floor_1000x1000 平铺。
#### Z1 家 地面(MI_DevGray)
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 缩放 |
|---|-----------|------|-------------|------|
| 1 | LVL_Z1_STR_Floor | Floor_1000x1000 | (500, 400, 0) | (1, 0.8, 1) |
> Z1 范围 (0,0)→(1000,800),Floor_1000x1000 中心点 (500,400),Y 方向缩放 0.8 覆盖 800cm。
#### Z2 小卖部 地面(MI_DevGray)
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 缩放 |
|---|-----------|------|-------------|------|
| 1 | LVL_Z2_STR_Floor | Floor_1000x1000 | (1300, 500, 0) | (0.6, 0.6, 1) |
> Z2 范围 (1000,200)→(1600,800),中心 (1300,500),缩放 (0.6, 0.6) 覆盖 600×600。
#### Z3 主街道 地面(MI_DevGray)
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 缩放 |
|---|-----------|------|-------------|------|
| 1 | LVL_Z3_STR_Floor_01 | Floor_1000x1000 | (500, 1050, 0) | (1, 0.5, 1) |
| 2 | LVL_Z3_STR_Floor_02 | Floor_1000x1000 | (1500, 1050, 0) | (1, 0.5, 1) |
| 3 | LVL_Z3_STR_Floor_03 | Floor_1000x1000 | (2500, 1050, 0) | (1, 0.5, 1) |
| 4 | LVL_Z3_STR_Floor_04 | Floor_1000x1000 | (3500, 1050, 0) | (1, 0.5, 1) |
| 5 | LVL_Z3_STR_Floor_05 | Floor_1000x1000 | (4500, 1050, 0) | (1, 0.5, 1) |
> Z3 范围 (0,800)→(5000,1300),宽度 500cm(Y 缩放 0.5),长度 5000cm(5 块 Floor)。
#### Z4 空地 地面(MI_DevBrown)
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 缩放 |
|---|-----------|------|-------------|------|
| 1 | LVL_Z4_STR_Floor_01 | Floor_1000x1000 | (4000, 1800, 10) | (1.5, 1.2, 1) |
> Z4 范围 (3500,1300)→(5000,2500),中心 (4250,1900),Z=10(高于街道 10cm)。缩放 (1.5, 1.2) 覆盖 1500×1200。
#### Z5 巷子 地面(MI_DevGray)
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 缩放 |
|---|-----------|------|-------------|------|
| 1 | LVL_Z5_STR_Floor_01 | Floor_1000x1000 | (2450, 1800, 0) | (0.3, 1, 1) |
| 2 | LVL_Z5_STR_Floor_02 | Floor_1000x1000 | (2450, 2800, 0) | (0.3, 1, 1) |
> Z5 范围 (2300,1300)→(2600,3300),宽度 300cm(X 缩放 0.3),长度 2000cm(2 块)。
#### Z6 水塘边 地面 + 水面
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 缩放 | 材质 |
|---|-----------|------|-------------|------|------|
| 1 | LVL_Z6_STR_GroundSouth | Floor_1000x1000 | (2350, 3475, 0) | (1.5, 0.35, 1) | MI_DevBrown |
| 2 | LVL_Z6_STR_GroundEast | Floor_1000x1000 | (3075, 4000, 0) | (0.15, 0.8, 1) | MI_DevBrown |
| 3 | LVL_Z6_STR_GroundWest | Floor_1000x1000 | (1675, 4000, 0) | (0.15, 0.8, 1) | MI_DevBrown |
| 4 | LVL_Z6_STR_Water | Floor_1000x1000 | (2350, 4000, -20) | (1.2, 0.8, 0.5) | MI_DevSkyBlue |
> Z6 水面中心约 (2350, 4000),Z=-20。岸边三面环绕。
#### Z7 老居民楼 地面(MI_DevGray)
> Z7 不需要单独地面地板,Building_01 自带底面。
### B2 放置边界围挡
#### 西边界(X=0, Y=0-6000)
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 旋转 (Pitch,Yaw,Roll) | 材质 |
|---|-----------|------|-------------|----------------------|------|
| 1 | LVL_BND_West_01 | Wall_400x300 | (0, 200, 0) | (0,0,0) → Yaw=90° | MI_DevRed |
| 2 | LVL_BND_West_02 | Wall_400x300 | (0, 600, 0) | (0,90,0) | MI_DevRed |
| 3 | LVL_BND_West_03 | Wall_400x300 | (0, 1000, 0) | (0,90,0) | MI_DevRed |
| 4 | LVL_BND_West_04 | Wall_400x300 | (0, 1400, 0) | (0,90,0) | MI_DevRed |
| 5 | LVL_BND_West_05 | Wall_400x300 | (0, 1800, 0) | (0,90,0) | MI_DevRed |
| 6 | LVL_BND_West_06 | Wall_400x300 | (0, 2200, 0) | (0,90,0) | MI_DevRed |
| 7 | LVL_BND_West_07 | Wall_400x300 | (0, 2600, 0) | (0,90,0) | MI_DevRed |
| 8 | LVL_BND_West_08 | Wall_400x300 | (0, 3000, 0) | (0,90,0) | MI_DevRed |
| 9 | LVL_BND_West_09 | Wall_400x300 | (0, 3400, 0) | (0,90,0) | MI_DevRed |
| 10 | LVL_BND_West_10 | Wall_400x300 | (0, 3800, 0) | (0,90,0) | MI_DevRed |
| 11 | LVL_BND_West_11 | Wall_400x300 | (0, 4200, 0) | (0,90,0) | MI_DevRed |
| 12 | LVL_BND_West_12 | Wall_400x300 | (0, 4600, 0) | (0,90,0) | MI_DevRed |
| 13 | LVL_BND_West_13 | Wall_400x300 | (0, 5000, 0) | (0,90,0) | MI_DevRed |
| 14 | LVL_BND_West_14 | Wall_400x300 | (0, 5400, 0) | (0,90,0) | MI_DevRed |
| 15 | LVL_BND_West_15 | Wall_400x300 | (0, 5800, 0) | (0,90,0) | MI_DevRed |
> Wall_400x300 旋转 90° 后沿 Y 方向排列,每块 400cm 高 × 300cm 长(需纵向排列覆盖 250cm 墙高)。
> **实际操作**:Wall_400x300 放置时默认长轴沿 X。Yaw=90° 旋转后长轴沿 Y。但墙高只有 300cm,而围挡只需 250cm,300cm 足够。
> **修正**:Wall 默认高度 300cm(Z轴),宽度 400cm(X轴),厚度 20cm(Y轴)。放置在 X=0 处,Yaw=90° 使 400cm 宽度沿 Y 方向。每块覆盖 Y 方向 400cm,15 块覆盖 6000cm。Z 方向 300cm > 250cm 要求,足够。
#### 东边界(X=8000, Y=0-6000)
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 旋转 | 材质 |
|---|-----------|------|-------------|------|------|
| 1-15 | LVL_BND_East_01~15 | BarrierWall_600 | (8000, 200+400n, 0) n=0~14 | (0,90,0) | MI_DevBlue |
> BarrierWall_600 默认 600cm 长。旋转 90° 后沿 Y 方向。10 块覆盖 6000cm。
> **修正**:BarrierWall_600 高度 100cm,需要堆叠 3 层达到 300cm。改为使用 Wall_400x300 更经济。
> 实际建议:使用 Wall_400x300 替代,与西边界相同方式,15 块。
#### 北边界(Y=6000, X=0-8000)
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 旋转 | 材质 |
|---|-----------|------|-------------|------|------|
| 1-20 | LVL_BND_North_01~20 | Wall_400x300 | (200+400n, 6000, 0) n=0~19 | (0,0,0) | MI_DevBlue |
> 20 块 Wall_400x300 覆盖 8000cm。
#### 南边界(Y=0, X=0-8000)
南边界分段处理:
- X=0-1000:Z1 南院墙(已含在 Z1 结构体中)
- X=1000-1600:Z2 后墙区域
- X=1600-5000:施工围挡
- X=5000-8000:补齐围挡
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 材质 |
|---|-----------|------|-------------|------|
| 1 | LVL_BND_South_01 | BarrierWall_600 | (1900, 0, 0) | MI_DevBlue |
| 2 | LVL_BND_South_02 | BarrierWall_600 | (2500, 0, 0) | MI_DevBlue |
| 3 | LVL_BND_South_03 | BarrierWall_600 | (3100, 0, 0) | MI_DevBlue |
| 4 | LVL_BND_South_04 | BarrierWall_600 | (3700, 0, 0) | MI_DevBlue |
| 5 | LVL_BND_South_05 | BarrierWall_600 | (4300, 0, 0) | MI_DevBlue |
| 6 | LVL_BND_South_06 | BarrierWall_600 | (4900, 0, 0) | MI_DevBlue |
| 7 | LVL_BND_South_07 | BarrierWall_600 | (5500, 0, 0) | MI_DevBlue |
| 8 | LVL_BND_South_08 | BarrierWall_600 | (6100, 0, 0) | MI_DevBlue |
| 9 | LVL_BND_South_09 | BarrierWall_600 | (6700, 0, 0) | MI_DevBlue |
| 10 | LVL_BND_South_10 | BarrierWall_600 | (7300, 0, 0) | MI_DevBlue |
| 11 | LVL_BND_South_11 | BarrierWall_600 | (7900, 0, 0) | MI_DevBlue |
> BarrierWall_600 需注意高度仅 100cm。建议堆叠 2-3 层达到 200-300cm 视觉高度。
> **替代方案**:改用 Wall_400x300 更高效(300cm 高度一次到位)。
---
## 四、Phase C — 逐区域搭建
### 搭建顺序:Z1 → Z3 → Z2 → Z4 → Z5 → Z6 → Z7
---
### C1. Z1 — 家(Home)
**区域绝对原点**:(0, 0, 0)
#### C1.1 结构体(Structure)
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 旋转 (P,Y,R) | 缩放 | 材质 |
|---|-----------|------|-------------|-------------|------|------|
| 1 | LVL_Z1_STR_SouthWall_01 | Wall_400x300 | (200, 0, 0) | (0,0,0) | — | MI_DevRed |
| 2 | LVL_Z1_STR_SouthWall_02 | Wall_400x300 | (600, 0, 0) | (0,0,0) | — | MI_DevRed |
| 3 | LVL_Z1_STR_WestWall_01 | Wall_400x300 | (0, 200, 0) | (0,90,0) | — | MI_DevRed |
| 4 | LVL_Z1_STR_WestWall_02 | Wall_400x300 | (0, 600, 0) | (0,90,0) | — | MI_DevRed |
| 5 | LVL_Z1_STR_EastWall_01 | Wall_400x300 | (980, 200, 0) | (0,90,0) | — | MI_DevRed |
| 6 | LVL_Z1_STR_EastWall_02 | Wall_400x300 | (980, 600, 0) | (0,90,0) | — | MI_DevRed |
| 7 | LVL_Z1_STR_NorthWall_West | Wall_400x300 | (200, 780, 0) | (0,0,0) | — | MI_DevRed |
| 8 | LVL_Z1_STR_NorthWall_Gate | WallDoor_200x300 | (500, 780, 0) | (0,0,0) | — | MI_DevRed |
| 9 | LVL_Z1_STR_NorthWall_East | Wall_400x300 | (800, 780, 0) | (0,0,0) | — | MI_DevRed |
| 10 | LVL_Z1_STR_GateDoor | RotativeDoor_01 | (500, 780, 0) | (0,0,0) | — | MI_DevGreen |
| 11 | LVL_Z1_STR_HouseSouthWall | WallWindow_400x300 | (400, 30, 0) | (0,0,0) | — | MI_DevWhite |
| 12 | LVL_Z1_STR_HouseSouthWin | WallWindowSmall_200x300 | (600, 30, 0) | (0,0,0) | — | MI_DevWhite |
| 13 | LVL_Z1_STR_HouseWestWall | Wall_400x300 | (200, 220, 0) | (0,90,0) | — | MI_DevWhite |
| 14 | LVL_Z1_STR_HouseWestTop | Wall_400x100 | (200, 220, 300) | (0,90,0) | — | MI_DevWhite |
| 15 | LVL_Z1_STR_HouseEastWall | Wall_400x300 | (780, 220, 0) | (0,90,0) | — | MI_DevWhite |
| 16 | LVL_Z1_STR_HouseEastTop | Wall_400x100 | (780, 220, 300) | (0,90,0) | — | MI_DevWhite |
| 17 | LVL_Z1_STR_HouseNorthWall | WallDoor_200x300 | (400, 410, 0) | (0,0,0) | — | MI_DevWhite |
| 18 | LVL_Z1_STR_HouseNorthFill | Wall_400x300 | (600, 410, 0) | (0,0,0) | — | MI_DevWhite |
| 19 | LVL_Z1_STR_HouseRoof_01 | Floor_300x400 | (350, 230, 280) | (0,0,0) | — | MI_DevBrown |
| 20 | LVL_Z1_STR_HouseRoof_02 | Floor_300x400 | (650, 230, 280) | (0,0,0) | — | MI_DevBrown |
| 21 | LVL_Z1_STR_CourtyardFloor | Floor_1000x1000 | (500, 400, 0) | (0,0,0) | (1, 0.8, 1) | MI_DevGray |
> **Z1 房屋内空间**:约 (200,30,0)→(800,410,280),即 600×380×280cm。
> **门洞高度问题**:WallDoor_200x300 门洞 200cm 宽,300cm 高,但设计要求院门高度 220cm。300cm 资产足够高,门洞实际开口约 200cm 高(标准 BSP 门洞),对于 120cm 身高儿童足够通过。
> **房屋北墙上方补齐**:WallDoor_200x300 上方需要补齐至 280cm。可用 Wall_200x100 放在 Z=200 处,或者直接用 Wall_400x300 整块(门洞在下方,上方自然有墙体)。
#### C1.2 布景物(Props)
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 缩放 | 材质 | 说明 |
|---|-----------|------|-------------|------|------|------|
| 1 | LVL_Z1_PROP_OldBicycle | Car01 | (100, 650, 0) | (0.2, 0.2, 0.2) | — | 50%缩放,靠西院墙 |
| 2 | LVL_Z1_PROP_ClothesPole_Beam | Beam_300 | (500, 600, 180) | — | MI_DevWhite | 横杆 |
| 3 | LVL_Z1_PROP_ClothesPole_Pole1 | Cylinder | (380, 600, 0) | (0.05, 0.05, 3.6) | MI_DevGray | 支撑柱 |
| 4 | LVL_Z1_PROP_ClothesPole_Pole2 | Cylinder | (620, 600, 0) | (0.05, 0.05, 3.6) | MI_DevGray | 支撑柱 |
| 5 | LVL_Z1_PROP_JunkPile_Box1 | WoodenBox_Small | (850, 100, 0) | — | — | 东南角 |
| 6 | LVL_Z1_PROP_JunkPile_Box2 | WoodenBox_Small | (870, 120, 35) | — | — | 叠放在上方 |
| 7 | LVL_Z1_PROP_JunkPile_Bucket | Bucket_01 | (890, 80, 0) | — | — | |
| 8 | LVL_Z1_PROP_DoorMat | Cube | (480, 740, 0) | (0.6, 0.4, 0.02) | MI_DevGray | 扁薄长方体 |
| 9 | LVL_Z1_PROP_Fridge | Barrel | (720, 80, 0) | (0.3, 0.3, 1.6) | MI_DevWhite | 竖放,缩放模拟冰箱 |
| 10 | LVL_Z1_PROP_TV | Monitor_01 | (320, 80, 45) | — | MI_DevGray | 房屋内书桌上 |
| 11 | LVL_Z1_PROP_Desk | SimpleTable_01 | (300, 70, 0) | — | — | 房屋内靠西墙 |
| 12 | LVL_Z1_PROP_Bed | BedSingle | (350, 250, 0) | — | — | 房屋内中部偏南 |
| 13 | LVL_Z1_PROP_Calendar | Cube | (500, 40, 180) | (0.3, 0.02, 0.4) | MI_DevRed | 薄片挂墙 |
| 14 | LVL_Z1_PROP_TVStand | SimpleTable_02 | (320, 55, 0) | (0.85, 0.75, 0.67) | — | 电视柜,缩放至约 85×45×50cm |
> **冰箱替代说明**:执行案建议 Barrel 或 Cube 缩放。Barrel 实际是圆柱形,用 Cube 缩放 (0.3, 0.3, 1.6) 更接近方冰箱外观。
#### C1.3 交互物标记(Interactables)
| # | Actor 名称 | 位置 (X,Y,Z) | 触发半径 | 交互类型 | 引用 |
|---|-----------|-------------|---------|---------|------|
| 1 | LVL_Z1_INTR_01_Fridge | (720, 80, 80) | 150 | 观察 | interaction #1 |
| 2 | LVL_Z1_INTR_02_Gate | (500, 780, 0) | 150 | 操作(门) | interaction #2 |
| 3 | LVL_Z1_INTR_06_TV | (320, 80, 70) | 150 | 观察 | interaction #6 |
> v0.1 交互物用标识色 Cube 或 Sphere 占位放置,标记交互位置。大小约 30cm,MI_DevYellow。
> 实际交互逻辑代码在 6b-6f 子任务中实现。
#### C1.4 收集品标记(Collectibles)
| # | Actor 名称 | 位置 (X,Y,Z) | 稀有度 | 引用 |
|---|-----------|-------------|--------|------|
| 1 | LVL_Z1_COLL_10_CatEyeMarble | (870, 140, 0) | 稀有 | collection #10 |
> 收集品用 Sphere 缩放至约 3cm,稀有用 MI_DevLight_Yellow(金色光标识),普通用 MI_DevWhite。
---
### C2. Z3 — 主街道(Main Street)
**区域绝对原点**:(0, 800, 0)
#### C2.1 结构体(南墙 + 北墙)
**南墙**(Y=800 处,已含 Z1 院门和 Z2 店面):
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 旋转 | 材质 |
|---|-----------|------|-------------|------|------|
| 1 | LVL_Z3_STR_SouthWall_C1 | Wall_400x300 | (1800, 800, 0) | (0,0,0) | MI_DevGray |
| 2 | LVL_Z3_STR_SouthWall_C2 | Wall_400x300 | (2200, 800, 0) | (0,0,0) | MI_DevGray |
| 3 | LVL_Z3_STR_SouthWall_C3 | Wall_400x300 | (2600, 800, 0) | (0,0,0) | MI_DevGray |
| 4 | LVL_Z3_STR_SouthWall_C4 | Wall_400x300 | (3000, 800, 0) | (0,0,0) | MI_DevGray |
| 5 | LVL_Z3_STR_SouthWall_C5 | Wall_400x300 | (3400, 800, 0) | (0,0,0) | MI_DevGray |
| 6 | LVL_Z3_STR_SouthWall_C6 | Wall_400x300 | (3800, 800, 0) | (0,0,0) | MI_DevGray |
| 7 | LVL_Z3_STR_SouthWall_D1 | Wall_400x300 | (4200, 800, 0) | (0,0,0) | MI_DevGray |
| 8 | LVL_Z3_STR_SouthWall_D2 | Wall_400x300 | (4600, 800, 0) | (0,0,0) | MI_DevGray |
> A 段 (X=0-1000) = Z1 院门区域(已由 Z1 南院墙覆盖)
> B 段 (X=1000-1600) = Z2 店面区域(Z2 建筑南侧)
> C 段 (X=1600-4000) = 6 块 Wall_400x300
> D 段 (X=4000-5000) = 2 块 Wall_400x300
**北墙**(Y=1300 处):
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 旋转 | 材质 |
|---|-----------|------|-------------|------|------|
| 1 | LVL_Z3_STR_NorthWall_A1 | Wall_400x300 | (200, 1300, 0) | (0,0,0) | MI_DevGray |
| 2 | LVL_Z3_STR_NorthWall_A2 | Wall_400x300 | (600, 1300, 0) | (0,0,0) | MI_DevGray |
| 3 | LVL_Z3_STR_NorthWall_A3 | Wall_400x300 | (1000, 1300, 0) | (0,0,0) | MI_DevGray |
| 4 | LVL_Z3_STR_NorthWall_A4 | Wall_400x300 | (1400, 1300, 0) | (0,0,0) | MI_DevGray |
| 5 | LVL_Z3_STR_NorthWall_A5 | Wall_400x300 | (1800, 1300, 0) | (0,0,0) | MI_DevGray |
| 6 | LVL_Z3_STR_NorthWall_A6 | Wall_200x300 | (2100, 1300, 0) | (0,0,0) | MI_DevGray |
| 7 | LVL_Z3_STR_NorthWall_C1 | Wall_400x300 | (2800, 1300, 0) | (0,0,0) | MI_DevGray |
| 8 | LVL_Z3_STR_NorthWall_C2 | Wall_400x300 | (3200, 1300, 0) | (0,0,0) | MI_DevGray |
| 9 | LVL_Z3_STR_NorthWall_C3 | Wall_100x300 | (3450, 1300, 0) | (0,0,0) | MI_DevGray |
> B 段 (X=2300-2600) = 巷子入口,开放通行,无墙体
> D 段 (X=3500-5000) = 空地入口,开放通行,无墙体
> E 段 (X=5000) = 场景边界围挡
#### C2.2 布景物
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 缩放 | 材质 | 说明 |
|---|-----------|------|-------------|------|------|------|
| 1 | LVL_Z3_PROP_PhoneBooth | Cube | (1800, 380, 0) | (0.8, 0.8, 2.2) | MI_DevGray | 街道北侧靠墙 |
| 2 | LVL_Z3_PROP_Bicycle | Car01 | (2800, 880, 0) | (0.2, 0.2, 0.2) | — | 街道南侧 |
| 3 | LVL_Z3_PROP_ClothesPole | Beam_300 | (1200, 1250, 180) | — | MI_DevWhite | 北墙处晾衣杆 |
| 4 | LVL_Z3_PROP_ClothesPolePole | Cylinder | (1200, 1250, 0) | (0.05, 0.05, 3.6) | MI_DevGray | 支撑柱 |
| 5 | LVL_Z3_PROP_SewerCover | CirclePlatform | (800, 1050, 0) | (0.12, 0.12, 0.02) | MI_DevGray | 路面中央 |
| 6 | LVL_Z3_PROP_Graffiti | Cube | (3200, 1270, 100) | (1.2, 0.05, 0.8) | MI_DevYellow | 北墙C段墙面 |
| 7 | LVL_Z3 PROP_AdWall | DisplayPanels_400x200 | (3800, 1280, 0) | — | MI_DevGray | 北墙D段手绘广告 |
| 8 | LVL_Z3_PROP_TrashCan | TrashCans_01 | (4200, 850, 0) | — | MI_DevGreen | 街道南侧 |
| 9 | LVL_Z3_PROP_PoleWest | Cylinder | (1000, 1050, 0) | (0.04, 0.04, 12) | MI_DevGray | 电线杆西 |
| 10 | LVL_Z3_PROP_PoleEast | Cylinder | (3500, 1050, 0) | (0.04, 0.04, 12) | MI_DevGray | 电线杆东 |
> **公共电话亭替代**:执行案建议 Cube+Cylinder 组合。用单个 Cube 缩放模拟方形电话亭。
> **下水道盖替代**:CirclePlatform 缩小至约 60cm 直径,扁平放置。
#### C2.3 交互物
| # | Actor 名称 | 位置 (X,Y,Z) | 触发半径 | 引用 |
|---|-----------|-------------|---------|------|
| 1 | LVL_Z3_INTR_04_PhoneBooth | (1800, 380, 110) | 150 | interaction #4 |
| 2 | LVL_Z3_INTR_09_Graffiti | (3200, 1270, 140) | 150 | interaction #9 |
#### C2.4 收集品
| # | Actor 名称 | 位置 (X,Y,Z) | 稀有度 | 引用 |
|---|-----------|-------------|--------|------|
| 1 | LVL_Z3_COLL_08_IceFlowerMarble | (820, 1060, 0) | 普通 | collection #8 |
---
### C3. Z2 — 小卖部(Corner Shop)
**区域绝对原点**:(1000, 200, 0)
#### C3.1 结构体
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 旋转 | 材质 |
|---|-----------|------|-------------|------|------|
| 1 | LVL_Z2_STR_SouthWall | Wall_400x300 | (1200, 200, 0) | (0,0,0) | MI_DevOrange |
| 2 | LVL_Z2_STR_SouthWall2 | Wall_200x300 | (1500, 200, 0) | (0,0,0) | MI_DevOrange |
| 3 | LVL_Z2_STR_WestWall | Wall_400x300 | (1000, 400, 0) | (0,90,0) | MI_DevOrange |
| 4 | LVL_Z2_STR_WestWallTop | Wall_400x100 | (1000, 400, 300) | (0,90,0) | MI_DevOrange |
| 5 | LVL_Z2_STR_EastWall | Wall_400x300 | (1580, 400, 0) | (0,90,0) | MI_DevOrange |
| 6 | LVL_Z2_STR_EastWallTop | Wall_400x100 | (1580, 400, 300) | (0,90,0) | MI_DevOrange |
| 7 | LVL_Z2_STR_NorthWall_West | Wall_200x300 | (1100, 580, 0) | (0,0,0) | MI_DevOrange |
| 8 | LVL_Z2_STR_NorthWall_Garage | WallDoorGarage_400x300 | (1300, 580, 0) | (0,0,0) | MI_DevOrange |
| 9 | LVL_Z2_STR_NorthWall_East | Wall_200x300 | (1500, 580, 0) | (0,0,0) | MI_DevOrange |
| 10 | LVL_Z2_STR_GarageDoor | GarageDoorOpen_01 | (1300, 580, 0) | (0,0,0) | MI_DevGray |
| 11 | LVL_Z2_STR_Roof_01 | Floor_300x400 | (1250, 400, 280) | (0,0,0) | MI_DevBrown |
| 12 | LVL_Z2_STR_Roof_02 | Floor_300x400 | (1350, 400, 280) | (0,0,0) | MI_DevBrown |
| 13 | LVL_Z2_STR_Awning_01 | Floor_200x300 | (1100, 700, 260) | (0,0,0) | MI_DevWhite |
| 14 | LVL_Z2_STR_Awning_02 | Floor_200x300 | (1400, 700, 260) | (0,0,0) | MI_DevWhite |
#### C3.2 布景物
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 缩放 | 材质 | 说明 |
|---|-----------|------|-------------|------|------|------|
| 1 | LVL_Z2_PROP_Counter | Cube | (1200, 500, 0) | (2, 0.6, 0.9) | MI_DevGlassWhite | 玻璃柜台 |
| 2 | LVL_Z2_PROP_ShelfEast_01 | Fence_Small_400 | (1520, 300, 0) | (1, 1, 1.8) | MI_DevGray | 东墙货架(竖放) |
| 3 | LVL_Z2_PROP_ShelfEast_02 | Fence_Small_400 | (1520, 300, 180) | (1, 1, 1.8) | MI_DevGray | 二层 |
| 4 | LVL_Z2_PROP_ShelfSouth | Fence_Small_400 | (1100, 230, 0) | (1, 1, 1.8) | MI_DevGray | 南墙货架 |
| 5 | LVL_Z2_PROP_Freezer | Container_Normal | (1050, 400, 0) | (0.25, 0.15, 0.4) | MI_DevWhite | 老式冰柜 |
| 6 | LVL_Z2_PROP_SmallTV | Monitor_01 | (1350, 540, 90) | (0.6, 0.6, 0.6) | MI_DevGray | 柜台角落 |
| 7 | LVL_Z2_PROP_Signboard | Cube | (1150, 610, 280) | (3, 0.05, 0.4) | MI_DevBlue | 招牌 |
| 8 | LVL_Z2_PROP_CardRack | Cube | (1400, 550, 0) | (0.4, 0.2, 0.3) | MI_DevGray | 卡片架 |
> **冰柜替代**:执行案建议 Cube 缩放。Container_Normal 缩小后也合适。Cube 更简单。
> **货架替代**:Fence_Small_400 竖放并 Y 缩放模拟多层货架。
#### C3.3 交互物
| # | Actor 名称 | 位置 (X,Y,Z) | 触发半径 | 引用 |
|---|-----------|-------------|---------|------|
| 1 | LVL_Z2_INTR_05_ShopOwner | (1300, 480, 0) | 200 | interaction #5 |
| 2 | LVL_Z2_INTR_07_SnackShelf | (1520, 350, 90) | 150 | interaction #7 |
#### C3.4 收集品
| # | Actor 名称 | 位置 (X,Y,Z) | 稀有度 | 引用 |
|---|-----------|-------------|--------|------|
| 1 | LVL_Z2_COLL_09_BouncyBall | (1300, 700, 0) | 普通 | collection #9 |
---
### C4. Z4 — 空地(Vacant Lot)
**区域绝对原点**:(3500, 1300, 0)
#### C4.1 结构体
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 旋转 | 材质 |
|---|-----------|------|-------------|------|------|
| 1 | LVL_Z4_STR_EastBound_01 | BarrierWall_600 | (4980, 1600, 0) | (0,90,0) | MI_DevBlue |
| 2 | LVL_Z4_STR_EastBound_02 | BarrierWall_600 | (4980, 2200, 0) | (0,90,0) | MI_DevBlue |
| 3 | LVL_Z4_STR_NorthBound_01 | BarrierWall_600 | (3800, 2480, 0) | (0,0,0) | MI_DevBlue |
| 4 | LVL_Z4_STR_NorthBound_02 | BarrierWall_600 | (4400, 2480, 0) | (0,0,0) | MI_DevBlue |
| 5 | LVL_Z4_STR_NorthBound_03 | BarrierWall_200 | (4700, 2480, 0) | (0,0,0) | MI_DevBlue |
| 6 | LVL_Z4_STR_WestLowWall_01 | BarrierWall_200 | (3500, 1500, 0) | (0,90,0) | MI_DevGray |
| 7 | LVL_Z4_STR_WestLowWall_02 | BarrierWall_200 | (3500, 1900, 0) | (0,90,0) | MI_DevGray |
| 8 | LVL_Z4_STR_WestLowWall_03 | BarrierWall_200 | (3500, 2300, 0) | (0,90,0) | MI_DevGray |
> **BarrierWall 高度注意**:BarrierWall_600/200 实际高度仅 100cm。设计要求围挡 200cm。需堆叠 2 层。
> 每个 BarrierWall 上方放置一个相同资产,Z 偏移 +100。
> **替代方案**:用 Wall_400x300 旋转 90° 后更高效(300cm 高度一次到位)。
#### C4.2 布景物
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 缩放 | 材质 | 说明 |
|---|-----------|------|-------------|------|------|------|
| 1 | LVL_Z4_PROP_BigTree | Tree_01 | (4250, 1900, 10) | (1.2, 1.2, 1.2) | MI_DevFoliage | 中央偏北 |
| 2 | LVL_Z4_PROP_Bricks_01~05 | WoodenBox_Small | (3700, 1600~1800, 10) 随机散布 | — | — | 5 块散落 |
| 3 | LVL_Z4_PROP_Puddle | Cube | (4600, 1500, 5) | (1.2, 0.8, 0.01) | MI_DevGlassBlue | 积水坑 |
| 4 | LVL_Z4_PROP_MarbleCircle | CirclePlatform | (4100, 1800, 12) | (0.16, 0.16, 0.01) | MI_DevGray | 弹珠圈痕迹 |
| 5 | LVL_Z4_PROP_Debris_01 | WoodenPallet_01 | (4800, 2300, 10) | — | — | 废弃建材 |
| 6 | LVL_Z4_PROP_Debris_02 | WoodenBox_Normal | (4850, 2250, 10) | — | — | 废弃建材 |
#### C4.3 交互物
| # | Actor 名称 | 位置 (X,Y,Z) | 触发半径 | 引用 |
|---|-----------|-------------|---------|------|
| 1 | LVL_Z4_INTR_03_BlueMarble | (3900, 1700, 10) | 100 | interaction #3 ↔ collection #1 |
| 2 | LVL_Z4_INTR_08_SmallStone | (4550, 1550, 10) | 100 | interaction #8 ↔ collection #3 |
#### C4.4 收集品
| # | Actor 名称 | 位置 (X,Y,Z) | 稀有度 | 引用 |
|---|-----------|-------------|--------|------|
| 1 | LVL_Z4_COLL_01_BlueMarble | (3900, 1700, 10) | 普通 | collection #1 |
| 2 | LVL_Z4_COLL_03_SmallStone | (4550, 1550, 10) | 普通 | collection #3 |
| 3 | LVL_Z4_COLL_04_LuZhishenCard | (3720, 1610, 10) | 稀有 | collection #4 |
---
### C5. Z5 — 巷子(Alley)
**区域绝对原点**:(2300, 1300, 0)
#### C5.1 结构体
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 旋转 | 材质 |
|---|-----------|------|-------------|------|------|
| 1 | LVL_Z5_STR_WestWall_01 | Wall_400x300 | (2300, 1500, 0) | (0,90,0) | MI_DevWhite |
| 2 | LVL_Z5_STR_WestWall_02 | Wall_400x300 | (2300, 1900, 0) | (0,90,0) | MI_DevWhite |
| 3 | LVL_Z5_STR_WestWall_03 | Wall_400x300 | (2300, 2300, 0) | (0,90,0) | MI_DevWhite |
| 4 | LVL_Z5_STR_WestWall_04 | Wall_400x300 | (2300, 2700, 0) | (0,90,0) | MI_DevWhite |
| 5 | LVL_Z5_STR_WestWall_05 | Wall_400x300 | (2300, 3100, 0) | (0,90,0) | MI_DevWhite |
| 6 | LVL_Z5_STR_EastWall_01 | Wall_400x300 | (2580, 1500, 0) | (0,90,0) | MI_DevWhite |
| 7 | LVL_Z5_STR_EastWall_02 | Wall_400x300 | (2580, 1900, 0) | (0,90,0) | MI_DevWhite |
| 8 | LVL_Z5_STR_EastWall_03 | Wall_400x300 | (2580, 2300, 0) | (0,90,0) | MI_DevWhite |
| 9 | LVL_Z5_STR_EastWall_04 | Wall_400x300 | (2580, 2700, 0) | (0,90,0) | MI_DevWhite |
| 10 | LVL_Z5_STR_EastWall_05 | Wall_400x300 | (2580, 3100, 0) | (0,90,0) | MI_DevWhite |
> 墙高 300cm > 设计要求 300cm,匹配。
> 巷子宽度 = 2580-2300-20(墙厚) = 260cm,接近设计 300cm。**偏差 +40cm**(详见报告)。
#### C5.2 布景物
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 缩放 | 材质 | 说明 |
|---|-----------|------|-------------|------|------|------|
| 1 | LVL_Z5_PROP_WasteBox | WoodenBox_Small | (2380, 2900, 0) | — | — | 巷子深处靠西墙 |
| 2 | LVL_Z5_PROP_SpiderWeb | Cube | (2305, 2100, 250) | (0.3, 0.3, 0.01) | MI_DevWhite | 西墙高处薄片 |
| 3 | LVL_Z5_PROP_OldWindow | FakeWindowsFrame | (2310, 2100, 150) | — | MI_DevGray | 西墙中段 |
| 4 | LVL_Z5_PROP_FlowerPot | Cylinder | (2340, 2100, 150) | (0.2, 0.2, 0.25) | MI_DevGreen | 窗台花盆 |
| 5 | LVL_Z5_PROP_Moss | Cube | (2400, 2700, 0) | (0.6, 0.4, 0.01) | MI_DevFoliage | 地面青苔 |
#### C5.3 交互物
| # | Actor 名称 | 位置 (X,Y,Z) | 触发半径 | 引用 |
|---|-----------|-------------|---------|------|
| 1 | LVL_Z5_INTR_10_WasteBox | (2380, 2900, 25) | 150 | interaction #10 |
#### C5.4 收集品
| # | Actor 名称 | 位置 (X,Y,Z) | 稀有度 | 引用 |
|---|-----------|-------------|--------|------|
| 1 | LVL_Z5_COLL_02_RedMarble | (2500, 3000, 0) | 普通 | collection #2 |
> Z5-C07(水浒卡·武松)在废纸箱内,不单独放置,通过翻找获得。
---
### C6. Z6 — 水塘边(Pond)
**区域绝对原点**:(1600, 3300, 0)
#### C6.1 结构体(见 B1 地面部分已铺设)
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 旋转 | 材质 |
|---|-----------|------|-------------|------|------|
| 1 | LVL_Z6_STR_EastBound_01 | BarrierWall_600 | (3080, 3600, 0) | (0,90,0) | MI_DevBlue |
| 2 | LVL_Z6_STR_EastBound_02 | BarrierWall_600 | (3080, 4200, 0) | (0,90,0) | MI_DevBlue |
| 3 | LVL_Z6_STR_NorthBound_01 | BarrierWall_600 | (1900, 4680, 0) | (0,0,0) | MI_DevBlue |
| 4 | LVL_Z6_STR_NorthBound_02 | BarrierWall_600 | (2500, 4680, 0) | (0,0,0) | MI_DevBlue |
| 5 | LVL_Z6_STR_NorthBound_03 | BarrierWall_200 | (2800, 4680, 0) | (0,0,0) | MI_DevBlue |
> 同 Z4,BarrierWall 需堆叠 2 层达到 200cm。
#### C6.2 布景物
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 缩放 | 材质 | 说明 |
|---|-----------|------|-------------|------|------|------|
| 1 | LVL_Z6_PROP_Reeds_S1~5 | Cylinder | (1800, 3600, 0) 随机偏移 | (0.08, 0.08, 2) | MI_DevFoliage | 南岸左 5 根 |
| 2 | LVL_Z6_PROP_Reeds_S2_1~5 | Cylinder | (2700, 3600, 0) 随机偏移 | (0.08, 0.08, 2) | MI_DevFoliage | 南岸右 5 根 |
| 3 | LVL_Z6_PROP_Reeds_E_1~3 | Cylinder | (2900, 4100, 0) 随机偏移 | (0.08, 0.08, 1.6) | MI_DevFoliage | 东岸 3 根 |
| 4 | LVL_Z6_PROP_LilyPad_1~4 | CirclePlatform | (2200, 3900, -18) 随机 | (0.06, 0.06, 0.01) | MI_DevGreen | 水面荷叶 |
| 5 | LVL_Z6_PROP_Frog | Cube | (2100, 3680, 0) | (0.05, 0.05, 0.04) | MI_DevGreen | 南岸小青蛙 |
#### C6.3 收集品
| # | Actor 名称 | 位置 (X,Y,Z) | 稀有度 | 引用 |
|---|-----------|-------------|--------|------|
| 1 | LVL_Z6_COLL_05_CandyWrapper | (2000, 3500, 0) | 普通 | collection #5 |
| 2 | LVL_Z6_COLL_06_Eraser | (2500, 3450, 0) | 普通 | collection #6 |
---
### C7. Z7 — 老居民楼(背景装饰)
**区域绝对原点**:(5800, 200, 0)
#### C7.1 结构体
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 缩放 | 材质 |
|---|-----------|------|-------------|------|------|
| 1 | LVL_Z7_STR_Building | Building_01 | (6400, 800, 0) | — | MI_DevGray |
| 2 | LVL_Z7_STR_CollisionFront | Wall_400x300 | (6200, 150, 0) | — | MI_DevGray |
| 3 | LVL_Z7_STR_CollisionFront2 | Wall_400x300 | (6600, 150, 0) | — | MI_DevGray |
| 4 | LVL_Z7_STR_CollisionFront3 | Wall_400x300 | (7000, 150, 0) | — | MI_DevGray |
| 5 | LVL_Z7_STR_CollisionSide | Wall_400x300 | (5750, 400, 0) | (0,90,0) | MI_DevGray |
| 6 | LVL_Z7_STR_CollisionSide2 | Wall_400x300 | (5750, 800, 0) | (0,90,0) | MI_DevGray |
> Building_01 放置在 (6400, 800) — 即区域中心偏南。
> 碰撞围墙阻挡玩家靠近。Building_01 的默认尺寸可能与设计 1200×600 有出入,需在编辑器中调整。
#### C7.2 布景物
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 缩放 | 材质 | 说明 |
|---|-----------|------|-------------|------|------|------|
| 1 | LVL_Z7_PROP_ClothesPole_01 | Beam_300 | (6100, 190, 800) | — | MI_DevWhite | 阳台晾衣杆 |
| 2 | LVL_Z7_PROP_ClothesPole_02 | Beam_300 | (6500, 190, 1200) | — | MI_DevWhite | 不同楼层 |
| 3 | LVL_Z7_PROP_ClothesPole_03 | Beam_300 | (6900, 190, 1600) | — | MI_DevWhite | 不同楼层 |
| 4 | LVL_Z7_PROP_TrashCan | TrashCans_01 | (6000, 140, 0) | — | MI_DevGreen | 楼下地面 |
---
## 五、Phase C — 全局物件
### G-01 路灯(3 个)
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 材质 |
|---|-----------|------|-------------|------|
| 1 | LVL_Z3_LGT_StreetLight_01 | RoadLamp_01 | (1500, 1050, 0) | — |
| 2 | LVL_Z3_LGT_StreetLight_02 | RoadLamp_01 | (3000, 1050, 0) | — |
| 3 | LVL_Z3_LGT_StreetLight_03 | RoadLamp_01 | (4500, 1050, 0) | — |
### G-02 垃圾桶(2 个,街道南侧)
> Z3-P07 已放置 1 个在 (4200, 850),补 1 个:
| # | Actor 名称 | 资产 | 位置 (X,Y,Z) | 材质 |
|---|-----------|------|-------------|------|
| 1 | LVL_Z3_PROP_TrashCan_02 | TrashCans_01 | (2000, 850, 0) | MI_DevGreen |
---
## 六、Phase D — 光照
### D1 全局光源
| # | Actor 名称 | 类型 | 参数 |
|---|-----------|------|------|
| 1 | LVL_Global_DirectionalLight | Directional Light | 色温 ~5500K 暖白;从西南照射(Rotation 约 Yaw=315°, Pitch=-45°);强度中等 |
| 2 | LVL_Global_SkyLight | Sky Light | 强度低-中;提供环境补光 |
> **Rotation 参考**:夏日午后 15:00,太阳从西南方向。Yaw 约 315°(西北到西南之间),Pitch 约 -45°。
> **实际操作**:在编辑器中调整 Directional Light 的 Rotation 直到视觉效果符合"温暖午后"氛围。光照参数均为建议值,可调。
### D2 路灯点光源(3 个)
| # | Actor 名称 | 类型 | 位置 (X,Y,Z) | 参数 |
|---|-----------|------|-------------|------|
| 1 | LVL_Z3_LGT_PointLight_01 | Point Light | (1500, 1050, 400) | 暖黄色,低强度 |
| 2 | LVL_Z3_LGT_PointLight_02 | Point Light | (3000, 1050, 400) | 暖黄色,低强度 |
| 3 | LVL_Z3_LGT_PointLight_03 | Point Light | (4500, 1050, 400) | 暖黄色,低强度 |
> v0.1 路灯为装饰性光源,午后阳光下几乎不可见。
---
## 七、Phase E — 验证清单
### E1 角色比例检查
以主角(身高 ~120cm,摄像机 ~100cm)验证:
- [ ] Z1 院门可通过(门洞 200cm 宽 × 220cm 高 → 实际 WallDoor_200x300 门洞约 100cm 高开口)
- [ ] Z1 房屋门可通过(WallDoor_200x300 门洞)
- [ ] Z2 卷帘门可通过(400cm 宽开放门洞)
- [ ] 室内摄像机不穿墙/天花板(室内净高 280cm,摄像机 100cm,头顶 180cm 余量)
- [ ] 窗台高度合理(WallWindow 窗台约 100cm 高,主角 120cm 可看到外面)
- [ ] 桌面高度与主角协调(SimpleTable_01 ~75cm 高,主角 120cm 身高,桌面到腰)
- [ ] Z5 巷子可通过(宽度约 260cm,主角可通行)
### E2 流线通行检查
- [ ] Z1 院门 → Z3 街道:院门 (500, 780) 北行进入街道 (500, 800+)
- [ ] Z3 街道 → Z2 小卖部:X=1000-1600 区域北行至店面
- [ ] Z3 街道 → Z4 空地:北墙 D 段开放(X=3500-5000, Y=1300)
- [ ] Z3 街道 → Z5 巷子:北墙 B 段开放(X=2300-2600, Y=1300)
- [ ] Z5 巷子 → Z6 水塘边:巷子北端 (2300-2600, 3300) 进入水塘区域
- [ ] Z7 不可到达:碰撞围墙阻挡
- [ ] 无死胡同(所有路径有明确去向或自然终止)
- [ ] 步行距离合理(从家到最远点约 200 秒步行 ≈ 游戏内 1 分钟内)
### E3 尺寸偏差验证
- [ ] Z3 北墙偏移 480cm vs 区域深度 500cm(PM 审查提及差 20cm,需验证)
- [ ] Z5 巷子实际宽度 vs 设计 300cm
- [ ] BarrierWall 高度堆叠后是否达到设计围挡高度
---
## 八、Actor 统计
| 类别 | 数量 | 说明 |
|------|------|------|
| 结构体 (STR) | ~80 | 墙体、地板、门框、屋顶、围挡 |
| 布景 (PROP) | ~45 | 家具、装饰、车辆、植被 |
| 交互物 (INTR) | 10 | 占位标记(后续实现交互逻辑) |
| 收集品 (COLL) | 10 | 占位标记(后续实现拾取逻辑) |
| 边界 (BND) | ~45 | 四面围挡 |
| 光源 (LGT) | 5 | 1 定向光 + 1 天空光 + 3 路灯 |
| **合计** | **~195** | |
+212
View File
@@ -0,0 +1,212 @@
# v0.1 白模搭建报告 — 城郊小街
> P-006 任务产出 — 搭建准备阶段
> 最后更新:2026-06-07
---
## 一、搭建概要
| 项目 | 值 |
|------|-----|
| 关卡文件 | `Content/Maps/LVL_SuburbanV01.umap`(需在 UE5 编辑器中创建) |
| 搭建指南 | `docs/technical/level-v01-build-guide.md` |
| 场景尺寸 | 8000cm × 6000cm(80m × 60m) |
| 区域数量 | 7 个(Z1-Z7) |
| 预估总 Actor 数 | ~195 |
| BSP 资产包 | Content/BlockingStarterPack/ |
### 各类别预估数量
| 类别 | 数量 |
|------|------|
| 结构体 (STR) | ~80 |
| 布景 (PROP) | ~45 |
| 交互物 (INTR) | 10 |
| 收集品 (COLL) | 10 |
| 边界 (BND) | ~45 |
| 光源 (LGT) | 5 |
| **合计** | **~195** |
---
## 二、逐区域对照
### Z1 家
| 条目 | 文档要求 | 实际方案 | 偏差 |
|------|---------|---------|------|
| 院墙高度 | 250cm | Wall_400x300(300cm 高) | 轻微:+50cm,视觉影响小 |
| 院门宽度 | 200cm | WallDoor_200x300 | ✅ 匹配 |
| 院门高度 | 220cm | WallDoor_200x300 门洞约 100cm 开口 | ⚠️ 需验证门洞实际开口高度 |
| 房屋尺寸 | 600×380×280 | 按偏移放置墙体围合 | ✅ 匹配 |
| 旧自行车 | Car01 缩放 50% | Car01 缩放 20% | 轻微:BSP Car01 默认较大,20% 更接近自行车尺寸 |
| 老式冰箱 | Barrel 或 Cube | Cube 缩放模拟方冰箱 | 轻微:Barrel 圆柱形不如 Cube 方形更像冰箱 |
| 交互物 3 个 | I01/I02/I06 | 标记位置 | ✅ 匹配 |
| 收集品 1 个 | C10 猫眼弹珠 | 标记位置 | ✅ 匹配 |
### Z2 小卖部
| 条目 | 文档要求 | 实际方案 | 偏差 |
|------|---------|---------|------|
| 建筑尺寸 | 600×400×280 | 按偏移放置 | ✅ 匹配 |
| 卷帘门 | GarageDoorOpen_01 | ✅ | ✅ 匹配 |
| 遮阳棚 | Floor_200x300 × 2 | ✅ | ✅ 匹配 |
| 玻璃柜台 | Cube + MI_DevGlassWhite | ✅ | ✅ 匹配 |
| 零食货架 | Fence_Small_400 竖放 × 2 | Fence_Small_400 排列 | ✅ 匹配 |
| 老式冰柜 | Cube 缩放 + MI_DevWhite | Container_Normal 缩小替代 | 轻微:Cube 方案更简单 |
| 招牌 | Cube 薄片 + MI_DevBlue | ✅ | ✅ 匹配 |
| 交互物 2 个 | I05/I07 | 标记位置 | ✅ 匹配 |
| 收集品 1 个 | C09 小弹力球 | 标记位置 | ✅ 匹配 |
### Z3 主街道
| 条目 | 文档要求 | 实际方案 | 偏差 |
|------|---------|---------|------|
| 街道尺寸 | 5000×500 | Floor_1000x1000 × 5 平铺 | ✅ 匹配 |
| 南墙 C 段 | X=1600-4000, 2400cm | 6 块 Wall_400x300 | ✅ 匹配 |
| 南墙 D 段 | X=4000-5000, 1000cm | 2 块 Wall_400x300 + Wall_200x300 | ✅ 匹配 |
| 北墙 A 段 | X=0-2300, 2300cm | 5 块 Wall_400x300 + 1 块 Wall_200x300 | ✅ 匹配 |
| 北墙 B 段 | 300cm 开口 | 开放通行 | ✅ 匹配 |
| 北墙 C 段 | X=2600-3500, 900cm | 2 块 Wall_400x300 + 1 块 Wall_100x300 | ✅ 匹配 |
| 北墙 D 段 | 1500cm 开口 | 开放通行 | ✅ 匹配 |
| 公用电话亭 | Cube+Cylinder | Cube 单体缩放 | 轻微:简化为单体 |
| 广告墙 | DisplayPanels_400x200 | ✅ | ✅ 匹配 |
| 交互物 2 个 | I04/I09 | 标记位置 | ✅ 匹配 |
| 收集品 1 个 | C08 透明冰花弹珠 | 标记位置 | ✅ 匹配 |
### Z4 空地
| 条目 | 文档要求 | 实际方案 | 偏差 |
|------|---------|---------|------|
| 地面高度 | +10cm | Floor Z=10 | ✅ 匹配 |
| 东边界围挡 | BarrierWall_600 × 2 | ✅(需堆叠 2 层) | ⚠️ BarrierWall_600 高仅 100cm,需堆叠 |
| 北边界围挡 | BarrierWall_600 × 2 + BarrierWall_200 | ✅(需堆叠) | 同上 |
| 西边界矮墙 | BarrierWall_200 × 6 | ✅ | ✅ 匹配 |
| 大梧桐树 | Tree_01 | ✅ | ✅ 匹配 |
| 交互物 2 个 | I03/I08 | 标记位置 | ✅ 匹配 |
| 收集品 3 个 | C01/C03/C04 | 标记位置 | ✅ 匹配 |
### Z5 巷子
| 条目 | 文档要求 | 实际方案 | 偏差 |
|------|---------|---------|------|
| 巷子宽度 | 300cm | 实际约 260cm(2580-2300-20墙厚) | **重大**:宽度差 40cm,仅 87% 设计宽度 |
| 巷子长度 | 2000cm | 墙体 Y=1300-3300 覆盖 | ✅ 匹配 |
| 墙壁高度 | 300cm | Wall_400x300(300cm) | ✅ 匹配 |
| 老窗户 | FakeWindowsFrame | ✅ | ✅ 匹配 |
| 交互物 1 个 | I10 废纸箱 | 标记位置 | ✅ 匹配 |
| 收集品 1 个 | C02 红色花纹弹珠 | 标记位置 | ✅ 匹配 |
### Z6 水塘边
| 条目 | 文档要求 | 实际方案 | 偏差 |
|------|---------|---------|------|
| 水面高度 | Z=-20cm | ✅ | ✅ 匹配 |
| 水面尺寸 | 1200×800 | Floor 缩放覆盖 | ✅ 匹配 |
| 岸边三面 | 各约 300cm | Floor 覆盖 | ✅ 匹配 |
| 芦苇丛 | Cylinder × N | ✅ | ✅ 匹配 |
| 交互物 | 无 | — | ✅ 匹配 |
| 收集品 2 个 | C05/C06 | 标记位置 | ✅ 匹配 |
### Z7 老居民楼
| 条目 | 文档要求 | 实际方案 | 偏差 |
|------|---------|---------|------|
| 建筑尺寸 | 1200×600×1800 | Building_01 默认尺寸待验证 | ⚠️ 需在编辑器中确认/缩放 |
| 碰撞围墙 | 阻止靠近 | Wall_400x300 排列 | ✅ 匹配 |
| 不可进入 | 无门洞 | ✅ | ✅ 匹配 |
| 晾衣杆 3 个 | Beam_300 × 3 | ✅ | ✅ 匹配 |
---
## 三、资产替代清单
| # | 文档建议 | 实际使用 | 原因 |
|---|---------|---------|------|
| 1 | BarrierWall_600/200(围挡) | 建议改用 Wall_400x300 旋转 90° | BarrierWall 高仅 100cm 需堆叠 2-3 层,Wall_400x300 高 300cm 一步到位更高效 |
| 2 | Car01 缩放 50%(自行车) | Car01 缩放 20% | BSP Car01 默认尺寸(约 450cm 长)远大于自行车,20% 缩放至约 170cm 更接近 |
| 3 | Barrel(冰箱) | Cube 缩放 | Barrel 为圆柱形,冰箱应为方形,Cube 更合适 |
| 4 | Container_Normal(冰柜) | Cube 缩放 | 同上,Cube 更简单直接 |
| 5 | BarricadeWall_100(路障) | 未使用 | 执行案未引用此资产(D-001 审查已修正) |
---
## 四、缩放记录
| Actor | 资产 | 默认尺寸 | 缩放 | 实际尺寸 | 用途 |
|-------|------|---------|------|---------|------|
| 自行车 | Car01 | ~450×180×150 | (0.2, 0.2, 0.2) | ~90×36×30 | 旧自行车 |
| 冰箱 | Cube | 100×100×100 | (0.3, 0.3, 1.6) | 30×30×160 | 老式冰箱 |
| 门垫 | Cube | 100×100×100 | (0.6, 0.4, 0.02) | 60×40×2 | 扁薄长方体 |
| 日历 | Cube | 100×100×100 | (0.3, 0.02, 0.4) | 30×2×40 | 墙面薄片 |
| 玻璃柜台 | Cube | 100×100×100 | (2, 0.6, 0.9) | 200×60×90 | 扁长方体 |
| 招牌 | Cube | 100×100×100 | (3, 0.05, 0.4) | 300×5×40 | 薄长条 |
| 积水坑 | Cube | 100×100×100 | (1.2, 0.8, 0.01) | 120×80×1 | 扁平水面 |
| 电话亭 | Cube | 100×100×100 | (0.8, 0.8, 2.2) | 80×80×220 | 方形亭 |
| 电线杆 | Cylinder | ~100Ø×100 | (0.04, 0.04, 12) | ~Ø4×600 | 高细圆柱 |
| 支撑柱 | Cylinder | ~100Ø×100 | (0.05, 0.05, 3.6) | ~Ø5×180 | 晾衣杆柱 |
| 花盆 | Cylinder | ~100Ø×100 | (0.2, 0.2, 0.25) | ~Ø20×25 | 窗台小花盆 |
| 青蛙 | Cube | 100×100×100 | (0.05, 0.05, 0.04) | 5×5×4 | 微型 |
| 荷叶 | CirclePlatform | ~100Ø | (0.06, 0.06, 0.01) | ~Ø6 | 水面小圆 |
| 弹珠圈 | CirclePlatform | ~100Ø | (0.16, 0.16, 0.01) | ~Ø16 | 地面圆圈 |
| 下水道盖 | CirclePlatform | ~100Ø | (0.12, 0.12, 0.02) | ~Ø12 | 路面小圆 |
| 芦苇 | Cylinder | ~100Ø×100 | (0.08, 0.08, 2) | ~Ø8×200 | 细长植物 |
---
## 五、未实现项
| # | 项目 | 原因 | 建议处理 |
|---|------|------|---------|
| 1 | `.umap` 关卡文件 | 无法在 CLI 中创建二进制 UE5 关卡文件,需在 UE5 编辑器中操作 | 用户根据搭建指南在编辑器中创建 |
| 2 | 交互物逻辑 | 交互物仅放置占位标记,不包含交互逻辑代码 | 6b-6f 子任务实现 |
| 3 | 收集品逻辑 | 收集品仅放置占位标记,不包含拾取逻辑 | 6b-6f 子任务实现 |
| 4 | 物理碰撞设置 | 边界和墙体需启用碰撞,需在编辑器中设置 | 搭建时设置 Collision Preset = BlockAll |
| 5 | 材质实例覆盖 | 部分材质需要在编辑器中创建动态材质实例(MI) | 搭建时在 Details 面板设置 |
| 6 | Outliner 文件夹分组 | 需在编辑器中手动拖拽 Actor 到对应文件夹 | 搭建时组织 |
---
## 六、比例验证结果
### E1 角色比例检查(待编辑器中执行)
| 检查项 | 预期结果 | 状态 |
|--------|---------|------|
| Z1 院门可通过 | 门洞 200cm 宽,主角 120cm 身高 | ⬜ 待验证 |
| Z1 房屋门可通过 | WallDoor_200x300 门洞 | ⬜ 待验证 |
| Z2 卷帘门可通过 | 400cm 开放门洞 | ⬜ 待验证 |
| 室内摄像机不穿墙 | 净高 280cm,摄像机 100cm | ⬜ 待验证 |
| 窗台高度 | WallWindow 窗台约 100cm | ⬜ 待验证 |
| 桌面高度 | SimpleTable_01 ~75cm | ⬜ 待验证 |
### E2 流线通行检查(待编辑器中执行)
| 路径 | 状态 |
|------|------|
| Z1 院门 → Z3 街道 | ⬜ 待验证 |
| Z3 → Z2 小卖部 | ⬜ 待验证 |
| Z3 → Z4 空地 | ⬜ 待验证 |
| Z3 → Z5 巷子 | ⬜ 待验证 |
| Z5 → Z6 水塘边 | ⬜ 待验证 |
| Z7 不可到达 | ⬜ 待验证 |
### E3 已知尺寸偏差(搭建前识别)
| # | 偏差 | 等级 | 说明 |
|---|------|------|------|
| 1 | Z5 巷子实际宽度约 260cm vs 设计 300cm | **重大** | Wall 厚度 20cm 占用空间。建议:将东墙东移至 X=2600+20=2620,或接受 260cm 宽度 |
| 2 | BarrierWall 高度仅 100cm vs 设计围挡 200cm | 轻微 | 需堆叠 2 层,或改用 Wall_400x300 旋转 90° |
| 3 | Building_01 默认尺寸待确认 vs 设计 1200×600×1800 | 轻微 | 需在编辑器中测量并按需缩放 |
| 4 | Z3 北墙偏移 480cm vs 区域深度 500cm(PM 审查残留) | 轻微 | 20cm 差异在 500cm 深度中影响极小 |
| 5 | 第五章南边界汇总表 "BarricadeWall" 应为 "BarrierWall"(PM 审查残留) | 轻微 | 泛指文本,不影响搭建 |
---
## 七、下一步
1. **用户在 UE5 编辑器中按搭建指南操作**:创建关卡文件 → 按 Phase B→C→D→E 顺序放置 Actor
2. **验证阶段**:执行 E1/E2/E3 检查清单,记录实际验证结果
3. **更新本报告**:将编辑器中的实际偏差补充到报告
4. **PM 验收门审查**:搭建完成后通知 PM 执行 ⑥程序实现验收门审查
+395 -145
View File
@@ -1,53 +1,241 @@
# 角色控制技术设计文档(v0.1 原型)
> 任务ID: P-003(部分)
> 任务ID: P-007
> 对应执行案: `docs/design/prototype/player-controller-execution.md`
> 关联系统: 交互系统(输入互斥 + 摄像机控制权交接)、场景系统(碰撞体 + 出生点)
> 阶段: 原型
> 日期: 2026-06-06
> 日期: 2026-06-07
---
## 概述
角色控制系统基于现有 `AChildHoodCharacter` + `AChildHoodPlayerController` 框架进行参数调整和少量代码修改。核心架构(SpringArm 摄像机 + Enhanced Input + CMC 移动)已就绪,v0.1 工作以**配置级调整**为主,不引入新的类或组件。
角色控制系统基于现有 `AChildHoodCharacter` + `AChildHoodPlayerController` 框架进行参数调整和少量代码修改。核心架构(SpringArm 摄像机 + Enhanced Input + CMC 移动)已就绪,v0.1 工作以**配置级调整**为主,不引入新的类或组件。同时需要移除跳跃逻辑、添加交互状态标志及交互相关 IA 绑定。
**实现复杂度**:低
**预估工期**:2-3 天
**新增/修改代码量**:约 80-100 行 C++
**预估工期**:1-2 天
**新增/修改代码量**:约 60-80 行 C++(净增约 30 行,删除约 20 行)
---
## 类与组件架构
## 1. 需求功能点罗列
### 修改现有类
从执行文档中提取每条行为规则,按实现方式分类。
| 类 | 修改内容 | 代码量 |
|----|---------|--------|
| `AChildHoodCharacter` | 移除跳跃、调整 CMC/SpringArm 参数、添加交互状态标志、新增交互相关 IA 绑定 | ~60 行 |
| `AChildHoodPlayerController` | 调整 Pitch 限幅(通过 CameraManager) | ~5 行 |
### UE 内置功能
### 不新增类
以下功能点直接使用 UE5 引擎内置能力,无需或仅需极少量自定义代码:
v0.1 角色控制系统不引入新类。所有功能通过修改现有类的参数和少量逻辑实现。
| 功能点 | 使用的 UE 内置能力 | 对应行为规则 | 备注 |
|--------|-------------------|-------------|------|
| 摄像机默认位置(3.5m / 0.8m / 15° 俯角) | SpringArm `TargetArmLength` + `SocketOffset` | C1 默认位置 | 构造函数配置 |
| 摄像机软跟随(3-5x 角色速度) | SpringArm `CameraLag` + `CameraLagSpeed` | C2 跟随规则 | 构造函数启用 |
| 视角水平旋转(150°/s) | Enhanced Input IA + `AddControllerYawInput` | C3 视角旋转 | 键鼠为相对输入,不硬限 °/s |
| 视角垂直限幅(+45°/-30°) | `PlayerCameraManager::ViewPitchMin/Max` | C3 视角旋转 | BeginPlay 中设置 |
| 摄像机碰撞处理 | SpringArm `bDoCollisionTest` + `ProbeSize` | C4 碰撞处理 | 构造函数启用 |
| 跑动中角色背对摄像机 | CMC `bOrientRotationToMovement` + `RotationRate` | C5 跑动背对 | 转向速度 720°/s 远快于鼠标 |
| 移动方向相对摄像机(含对角 45°) | Enhanced Input 2D Axis + `AddMovementInput` | M1 移动方向 | 已有 `DoMove()` 满足 |
| 角色转向(720°/s,最短路径) | CMC `RotationRate` + 默认最短路径旋转 | M2 角色转向 | 无需修改 |
| 跑步速度(4.5 m/s) | CMC `MaxWalkSpeed` | M3 跑步 | 构造函数设置 |
| 起步加速(0.2s) | CMC `MaxAcceleration` | M3 跑步 | 450/0.2 = 2250 cm/s² |
| 停止减速(0.3s) | CMC `BrakingDecelerationWalking` | M4 停止减速 | 450/0.3 = 1500 cm/s² |
| 坡道可行走(≤45°) | CMC `WalkableFloorAngle` | M5 坡道与台阶 | 构造函数设置 |
| WASD/方向键移动输入 | Enhanced Input IMC/IA(已有) | I1 移动输入 | 无修改 |
| 鼠标视角旋转输入 | Enhanced Input IMC/IA(已有) | I2 视角输入 | 无修改 |
### 组件挂载关系(不变)
### 自定义实现
以下功能点需要编写自定义 C++ / 蓝图代码:
| 功能点 | 实现方式概述 | 对应行为规则 | 预估复杂度 |
|--------|-------------|-------------|-----------|
| 移除跳跃 | 删除 `JumpAction` 成员、`DoJumpStart/End` 函数、Input 绑定 | I4 移除跳跃 | 低 |
| 交互中忽略移动输入 | `bIsInteracting` 标志 + `DoMove()` 前置检查 | P1 交互中屏蔽移动 | 低 |
| 交互相关 IA 绑定 | 新增 `InteractAction`/`CancelAction`/`SwitchInteractAction` 成员 | I3 交互输入 | 低 |
| 交互状态接口 | `SetInteracting()`/`IsInteracting()`/`IsRunning()` 方法 | P3 状态信号 | 低 |
| 摄像机控制权交接 | 提供 `FollowCamera` 访问器,交互系统通过 `SetViewTargetWithBlend` 切换 | P2 摄像机控制权 | 低(接口方) |
> **分类原则**:角色控制系统 90% 需求由 UE 内置能力覆盖,仅交互协调相关逻辑需要自定义。无复杂状态机或自定义算法。
---
## 2. 功能领域图
```mermaid
flowchart TD
subgraph 输入层
Input[输入处理模块<br/>Enhanced Input 回调]
end
subgraph 核心层
Movement[移动控制模块<br/>CMC 参数配置]
Camera[摄像机模块<br/>SpringArm 参数配置]
CharState[角色状态模块<br/>交互标志 + 查询接口]
end
subgraph 外部系统
Interaction[交互系统<br/>读/写角色状态]
end
Input -->|WASD/鼠标| Movement
Input -->|鼠标| Camera
Input -->|E/ESC/Tab| Interaction
Movement -->|bIsInteracting 检查| CharState
Interaction -->|SetInteracting| CharState
Interaction -->|SetViewTargetWithBlend| Camera
CharState -.->|IsInteracting/IsRunning| Interaction
```
AChildHoodCharacter
├── UCapsuleComponent (Root) — 碰撞胶囊体
├── USkeletalMeshComponent (Mesh) — 角色网格
├── USpringArmComponent (CameraBoom) — 摄像机摇臂
└── UCameraComponent (FollowCamera) — 跟随摄像机
AChildHoodPlayerController
├── APlayerCameraManager — 摄像机管理器(设置 Pitch 限幅)
└── UEnhancedInputComponent — 输入组件
└── IMC 注册(通过 DefaultMappingContexts)
### 模块职责说明
| 模块 | 职责 | 关键输入 | 关键输出 |
|------|------|---------|---------|
| 输入处理模块 | 接收 Enhanced Input 回调,分发到移动/视角/交互 | WASD、鼠标、E/ESC/Tab | DoMove、DoLook、交互系统调用 |
| 移动控制模块 | 通过 CMC 参数控制角色移动行为 | DoMove 方向值 + bIsInteracting 标志 | 角色位置/旋转更新 |
| 摄像机模块 | 通过 SpringArm 参数控制摄像机跟随和碰撞 | Controller 旋转 + 碰撞检测结果 | 摄像机位置/旋转 |
| 角色状态模块 | 维护交互状态标志,提供查询接口 | 交互系统的 SetInteracting 调用 | IsInteracting/IsRunning 查询结果 |
---
## 3. 类设计图
```mermaid
classDiagram
class AChildHoodCharacter {
-USpringArmComponent* CameraBoom
-UCameraComponent* FollowCamera
-UInputAction* MoveAction
-UInputAction* LookAction
-UInputAction* MouseLookAction
-UInputAction* InteractAction
-UInputAction* CancelAction
-UInputAction* SwitchInteractAction
-bool bIsInteracting
+DoMove(float Right, float Forward) void
+DoLook(float Yaw, float Pitch) void
+SetInteracting(bool bValue) void
+IsInteracting() bool
+IsRunning() bool
+GetFollowCamera() UCameraComponent*
}
class AChildHoodPlayerController {
-TArray~UInputMappingContext*~ DefaultMappingContexts
#BeginPlay() void
#SetupInputComponent() void
}
class USpringArmComponent {
+TargetArmLength float
+SocketOffset FVector
+bEnableCameraLag bool
+CameraLagSpeed float
+bDoCollisionTest bool
+ProbeSize float
}
class UCharacterMovementComponent {
+MaxWalkSpeed float
+MaxAcceleration float
+BrakingDecelerationWalking float
+RotationRate FRotator
+WalkableFloorAngle float
+bOrientRotationToMovement bool
}
AChildHoodCharacter *-- USpringArmComponent : 组合(持有)
AChildHoodCharacter *-- UCharacterMovementComponent : 组合(继承自带)
AChildHoodCharacter --> AChildHoodPlayerController : 关联(Controller)
```
### 新增类
无新增类。v0.1 角色控制系统不引入新类或新组件。
### 修改类
| 类名 | 修改内容 |
|------|---------|
| `AChildHoodCharacter` | ① 删除 `JumpAction` 成员及跳跃相关绑定/函数 ② 新增 `InteractAction`/`CancelAction`/`SwitchInteractAction` IA 指针 ③ 新增 `bIsInteracting` 标志 ④ `DoMove()` 添加交互状态检查 ⑤ 新增 `SetInteracting()`/`IsInteracting()`/`IsRunning()` 接口 ⑥ 调整 CMC/SpringArm 构造函数参数 |
| `AChildHoodPlayerController` | `BeginPlay()` 中设置 `PlayerCameraManager` 的 Pitch 限幅 |
### 新增蓝图
无新增蓝图。v0.1 角色控制系统不创建新蓝图资产。
---
## 4. 时序图(仅复杂特性)
> ⚠️ **跳过**。角色控制系统为纯参数配置 + 简单标志管理,不涉及 3+ 系统协调或复杂分支流程。跨系统交互的时序图在交互系统技术设计文档中绘制。
---
## 5. 核心数据结构
### 角色控制无新增枚举或结构体
v0.1 角色控制系统不引入新的枚举、结构体或配置数据类。所有配置通过 CMC 和 SpringArm 内置属性完成。
### AChildHoodCharacter 关键数据定义
```cpp
UCLASS(abstract)
class AChildHoodCharacter : public ACharacter
{
GENERATED_BODY()
// === 配置参数(构造函数设置默认值) ===
// 无额外配置参数,全部通过 CMC/SpringArm 内置属性配置
// === 输入动作(蓝图可覆盖) ===
UPROPERTY(EditAnywhere, Category="Input")
UInputAction* MoveAction; // WASD/方向键移动
UPROPERTY(EditAnywhere, Category="Input")
UInputAction* LookAction; // 手柄视角
UPROPERTY(EditAnywhere, Category="Input")
UInputAction* MouseLookAction; // 鼠标视角
UPROPERTY(EditAnywhere, Category="Input")
UInputAction* InteractAction; // E 键交互(委托交互系统)
UPROPERTY(EditAnywhere, Category="Input")
UInputAction* CancelAction; // ESC 取消(委托交互系统)
UPROPERTY(EditAnywhere, Category="Input")
UInputAction* SwitchInteractAction; // Tab/滚轮切换交互物(委托交互系统)
// === 运行时状态 ===
bool bIsInteracting = false; // 是否正在交互中
// === 关键接口 ===
// 移动(交互中忽略输入)
UFUNCTION(BlueprintCallable, Category="Input")
virtual void DoMove(float Right, float Forward);
// 视角旋转
UFUNCTION(BlueprintCallable, Category="Input")
virtual void DoLook(float Yaw, float Pitch);
// 交互状态控制(供交互系统调用)
UFUNCTION(BlueprintCallable)
void SetInteracting(bool bValue);
// 状态查询(供交互系统/UI 使用)
UFUNCTION(BlueprintCallable, BlueprintPure)
bool IsInteracting() const;
UFUNCTION(BlueprintCallable, BlueprintPure)
bool IsRunning() const;
};
```
---
## 行为规则 → 实现方案映射
## 6. 行为规则 → 实现方案映射
### 一、摄像机系统
@@ -57,12 +245,12 @@ AChildHoodPlayerController
```cpp
// AChildHoodCharacter 构造函数
CameraBoom->TargetArmLength = 350.0f; // 3.5m 距离
CameraBoom->TargetArmLength = 350.0f; // 3.5m 距离
CameraBoom->SocketOffset = FVector(0.f, 0.f, 80.f); // 0.8m 高于角色
// 初始俯角由 Controller Pitch 控制,在 PlayerController 中设置初始旋转
// 俯角由 Controller Pitch 初始值和玩家操作决定,PlayerCameraManager 限制范围
```
**可调参数**:TargetArmLength, SocketOffset.Z
**可调参数**:`TargetArmLength`(2.5-5.0m),`SocketOffset.Z`(0.5-1.2m)
---
@@ -72,36 +260,37 @@ CameraBoom->SocketOffset = FVector(0.f, 0.f, 80.f); // 0.8m 高于角色
```cpp
CameraBoom->bEnableCameraLag = true;
CameraBoom->CameraLagSpeed = 6.0f; // 可调,范围 2-8
CameraBoom->CameraLagSpeed = 6.0f; // 可调,范围 2-8
CameraBoom->bEnableCameraRotationLag = false; // v0.1 不启用旋转延迟
```
**可调参数**:CameraLagSpeed
**可调参数**:`CameraLagSpeed`(2-8)
---
#### C3. 视角旋转(水平 150°/s,垂直 +45°/-30°)
**水平旋转实现**:通过 Enhanced Input IA 的 Value 值 × PlayerController::InputYawScale 控制。
**水平旋转**:通过 Enhanced Input IA 的 Scale 值 × `AddControllerYawInput` 控制。
> 键鼠模式下鼠标移动是相对输入,由玩家手速决定实际旋转速度。执行案中 150°/s 是手柄摇杆的设计参考值,v0.1 优先键鼠,此参数暂不在代码中硬性限制。
**垂直限幅**:在 `AChildHoodPlayerController::BeginPlay()` 中设置
```cpp
// InputYawScale 在 PlayerController 中设置
// 灵敏度通过 IA 的 Scale 值控制,不需要自定义旋转速度限制
// UE5 鼠标输入是相对移动,不受固定 °/s 限制
// v0.1 使用默认鼠标输入灵敏度,后续版本可加灵敏度滑块
void AChildHoodPlayerController::BeginPlay()
{
Super::BeginPlay();
// 设置摄像机俯仰角限制
if (PlayerCameraManager)
{
PlayerCameraManager->ViewPitchMin = -30.0f; // 向下看最多 30°
PlayerCameraManager->ViewPitchMax = 45.0f; // 向上看最多 45°
}
// ... 原有移动端触控逻辑
}
```
**垂直限幅实现**:在 CameraManager 中设置
```cpp
// AChildHoodPlayerController::BeginPlay 或构造函数中
PlayerCameraManager->ViewPitchMin = -30.0f; // 向下看最多 30°
PlayerCameraManager->ViewPitchMax = 45.0f; // 向上看最多 45°
```
> 注:执行案中 150°/s 是手柄摇杆的设计参考值。键鼠模式下鼠标移动是相对输入,由玩家手速决定实际旋转速度。v0.1 优先键鼠,此参数暂不在代码中硬性限制。
**可调参数**:ViewPitchMin, ViewPitchMax, IA Scale
**可调参数**:`ViewPitchMin`(-45° ~ -20°),`ViewPitchMax`(+30° ~ +60°),IA Scale
---
@@ -111,33 +300,32 @@ PlayerCameraManager->ViewPitchMax = 45.0f; // 向上看最多 45°
```cpp
CameraBoom->bDoCollisionTest = true;
CameraBoom->ProbeSize = 12.0f; // 碰撞探针半径
CameraBoom->ProbeChannel = ECC_Camera; // 使用 Camera 碰撞通道
// 最小距离保证:SpringArm 自动缩短到碰撞面
// 当目标位置被阻挡时,SpringArm 将摄像机移到最近的未阻挡位置
// 默认行为已满足"紧贴碰撞面内侧"的要求
CameraBoom->ProbeSize = 12.0f; // 碰撞探针半径
CameraBoom->ProbeChannel = ECC_Camera; // 使用 Camera 碰撞通道
```
**最小距离保证**(0.5m):SpringArm 的 `TargetArmLength` 最短会被碰撞面推到约 0(取决于探针半径和角色胶囊体大小)。如需严格保证 0.5m 最小距离,可在蓝图中加 Tick 检查后处理。**v0.1 先用原生行为,视体验再决定是否添加。**
- SpringArm 自动缩短摄像机到碰撞面内侧
- 碰撞消除后配合 Camera Lag 平滑恢复到 `TargetArmLength`
- v0.1 仅处理静态场景几何体碰撞,不处理动态物体
- 最小距离保证(0.5m):v0.1 先用原生行为,视实际体验决定是否添加 Tick 后处理
**恢复**:碰撞消除后 SpringArm 自动恢复到 TargetArmLength,配合 Camera Lag 实现平滑回位。
**v0.1 简化**:仅处理与静态几何体碰撞(默认行为),不处理动态物体。
**可调参数**:`ProbeSize`(8-20),`bDoCollisionTest`
---
#### C5. 跑动中角色始终背对摄像机
**实现**:已有配置满足
**实现**:已有配置满足,调整 `RotationRate`
```cpp
bUseControllerRotationYaw = false; // 角色不跟随 Controller Yaw
GetCharacterMovement()->bOrientRotationToMovement = true; // 角色朝移动方向旋转
bUseControllerRotationYaw = false; // 角色不跟随 Controller Yaw
GetCharacterMovement()->bOrientRotationToMovement = true; // 角色朝移动方向旋转
GetCharacterMovement()->RotationRate = FRotator(0.f, 720.f, 0.f); // 转向速度 720°/s
```
角色转向速度 720°/s 远快于鼠标旋转速度,自然满足"摄像机追不到角色正面"的效果。无需额外逻辑。
角色转向速度 720°/s 远快于鼠标旋转速度(150°/s),自然满足"摄像机追不到角色正面"。
**可调参数**:`RotationRate.Yaw`(360-1080°/s)
---
@@ -145,38 +333,39 @@ GetCharacterMovement()->RotationRate = FRotator(0.f, 720.f, 0.f); // 转向速
#### M1. 移动方向(相对摄像机,对角 45° 合成)
**实现**:已有 `DoMove()` 逻辑满足
**实现**:已有 `DoMove()` 逻辑满足,无需修改。
```cpp
void AChildHoodCharacter::DoMove(float Right, float Forward)
{
const FRotator Rotation = GetController()->GetControlRotation();
const FRotator YawRotation(0, Rotation.Yaw, 0);
const FVector ForwardDirection = FRotationMatrix(YawRotation).GetUnitAxis(EAxis::X);
const FVector RightDirection = FRotationMatrix(YawRotation).GetUnitAxis(EAxis::Y);
AddMovementInput(ForwardDirection, Forward);
AddMovementInput(RightDirection, Right);
if (GetController() != nullptr)
{
const FRotator Rotation = GetController()->GetControlRotation();
const FRotator YawRotation(0, Rotation.Yaw, 0);
const FVector ForwardDirection = FRotationMatrix(YawRotation).GetUnitAxis(EAxis::X);
const FVector RightDirection = FRotationMatrix(YawRotation).GetUnitAxis(EAxis::Y);
AddMovementInput(ForwardDirection, Forward);
AddMovementInput(RightDirection, Right);
}
}
```
- 对角输入(W+A)由 Enhanced Input 的 2D Axis 自然处理
- `AddMovementInput` 不叠加速度(CMC 内部归一化)
- 连续旋转中移动方向实时跟随摄像机朝向(每帧重新计算方向)
**无需修改。**
- 对角输入(W+A)由 Enhanced Input 2D Axis 自然处理
- `AddMovementInput` 内部归一化,斜向速度不叠加
- 每帧重新计算方向,连续旋转中移动方向实时跟随摄像机
---
#### M2. 角色转向(720°/s,最短路径,边跑边转)
**实现**:CMC 参数配置
**实现**:CMC 参数配置(同 C5)
```cpp
GetCharacterMovement()->bOrientRotationToMovement = true;
GetCharacterMovement()->RotationRate = FRotator(0.f, 720.f, 0.f);
```
CMC 默认走最短路径旋转,转向期间角色持续移动(不"停顿再转向")。**无需修改。**
CMC 默认最短路径旋转,转向期间角色持续移动。**无需额外修改。**
---
@@ -184,87 +373,89 @@ CMC 默认走最短路径旋转,转向期间角色持续移动(不"停顿再
**速度**:
```cpp
GetCharacterMovement()->MaxWalkSpeed = 450.0f; // 4.5 m/s (UE5 1uu = 1cm)
GetCharacterMovement()->MaxWalkSpeed = 450.0f; // 4.5 m/s(UE5 1uu = 1cm)
```
**加速**:CMC 的 `MaxAcceleration` 控制加速过程
**加速度**:
```cpp
// 从 0 到 450 cm/s 在 0.2s → 加速度 = 450/0.2 = 2250 cm/s²
GetCharacterMovement()->MaxAcceleration = 2250.0f;
```
> 注:CMC 加速不是严格线性,受 GroundFriction 等因素影响。2250 是起始值,实际手感需测试微调。
> 注:CMC 加速不是严格线性,受 `GroundFriction` 等因素影响。2250 是起始值,需实测微调。
**可调参数**:`MaxWalkSpeed`(3.5-6.0 m/s),`MaxAcceleration`(1000-4000 cm/s²)
---
#### M4. 停止减速(0.3s)
**实现**:
```cpp
// 从 450 到 0 cm/s 在 0.3s → 减速度 = 450/0.3 = 1500 cm/s²
GetCharacterMovement()->BrakingDecelerationWalking = 1500.0f;
```
> 同样受 GroundFriction 影响,1500 是起始值。
> 同样受 `GroundFriction` 影响,1500 是起始值。
**可调参数**:`BrakingDecelerationWalking`(800-2500 cm/s²)
---
#### M5. 坡道与台阶(坡度 ≤45°,台阶 ≤0.15m)
**实现**:
```cpp
GetCharacterMovement()->WalkableFloorAngle = 45.0f; // 最大可行走坡度
// 台阶高度由胶囊体半径和 CMC 的 StepHeight 决定
// 默认 StepOffset = 45.0f (4.5cm),覆盖 0.15m 需要调大
// 但 v0.1 场景设计避免高台阶,先保持默认
GetCharacterMovement()->SetWalkableFloorAngle(45.0f);
// 台阶:v0.1 场景设计避免高台阶,CMC 默认 StepOffset 可覆盖常规台阶
```
**可调参数**:`WalkableFloorAngle`(30°-60°)
---
### 三、输入映射
#### I1. WASD/方向键 → 移动
**实现**:已有 IA_Move + IMC 配置。保持不变。
已有 `IA_Move` + IMC 配置,保持不变。
#### I2. 鼠标移动 → 视角旋转
**实现**:已有 IA_MouseLook + IMC 配置。保持不变。
已有 `IA_MouseLook` + IMC 配置,保持不变。
#### I3. E/ESC/Tab/滚轮 → 委托交互系统
**实现**:在 Character 中添加交互相关 IA 指针和绑定
**实现**:在 `AChildHoodCharacter` 中新增交互相关 IA 指针
```cpp
// 新增成员(AChildHoodCharacter.h)
// AChildHoodCharacter.h 新增成员
UPROPERTY(EditAnywhere, Category="Input")
UInputAction* InteractAction; // E 键
UInputAction* InteractAction; // E 键
UPROPERTY(EditAnywhere, Category="Input")
UInputAction* CancelAction; // ESC 键
UInputAction* CancelAction; // ESC 键
UPROPERTY(EditAnywhere, Category="Input")
UInputAction* SwitchInteractAction; // Tab 键
UInputAction* SwitchInteractAction; // Tab 键 / 鼠标滚轮
// SetupPlayerInputComponent 中绑定
// 回调函数直接调用 InteractionManager 的对应接口
// 回调函数直接调用交互系统的对应接口(具体实现见交互系统技术设计文档)
```
> 具体回调实现见交互系统技术设计文档。
> IMC 中需新增 `IA_Interact`/`IA_Cancel`/`IA_SwitchInteract` 的按键映射。
#### I4. 移除跳跃
**实现**:移除 JumpAction 及其绑定
**实现**:删除跳跃相关代码
```cpp
// 删除 JumpAction 成员
// 删除成员
// UPROPERTY(EditAnywhere, Category="Input") UInputAction* JumpAction;
// 删除 SetupPlayerInputComponent 中的 Jump 绑定
// 删除 DoJumpStart/DoJumpEnd 函数
// CMC: GetCharacterMovement()->JumpZVelocity 不需要设置(不跳跃)
// 删除 DoJumpStart() / DoJumpEnd() 函数
// CMC: 不需要设置 JumpZVelocity(不跳跃)
```
---
@@ -276,43 +467,78 @@ UInputAction* SwitchInteractAction; // Tab 键
**实现**:在 `DoMove()` 中添加状态检查
```cpp
// 新增成员
bool bIsInteracting = false;
// 修改 DoMove
void AChildHoodCharacter::DoMove(float Right, float Forward)
{
if (bIsInteracting) return; // 交互中忽略移动
if (bIsInteracting) return; // 交互中忽略移动
// ... 原有逻辑
}
```
// 外部接口(供 InteractionManager 调用)
UFUNCTION(BlueprintCallable)
void SetInteracting(bool bInteracting);
```cpp
void AChildHoodCharacter::SetInteracting(bool bValue)
{
bIsInteracting = bValue;
}
```
#### P2. 交互中摄像机控制权交接
**实现**:InteractionManager 在进入交互时通过 `SetViewTargetWithBlend` 切换摄像机目标;退出时切换回 Character。角色控制系统本身不需要修改摄像机逻辑。
**实现**:交互系统通过 `SetViewTargetWithBlend` 切换摄像机目标,退出时切回 Character。角色控制系统本身不需要修改摄像机逻辑。
交互结束后摄像机自动回到 SpringArm 默认跟随(因为 ViewTarget 切回 Character,SpringArm 恢复控制)。
交互结束后摄像机自动回到 SpringArm 默认跟随(ViewTarget 切回 Character 后 SpringArm 恢复控制)。
#### P3. 状态信号提供
**实现**:提供查询接口
```cpp
UFUNCTION(BlueprintCallable, BlueprintPure)
bool IsInteracting() const { return bIsInteracting; }
bool AChildHoodCharacter::IsInteracting() const
{
return bIsInteracting;
}
UFUNCTION(BlueprintCallable, BlueprintPure)
bool IsRunning() const;
// IsRunning: GetVelocity().Size() > Threshold && GetCharacterMovement()->IsMovingOnGround()
bool AChildHoodCharacter::IsRunning() const
{
return GetVelocity().SizeSquared() > 100.f // 速度 > 10 cm/s 阈值
&& GetCharacterMovement()->IsMovingOnGround();
}
```
---
## 数据流
## 7. 美术资源需求
v0.1 角色控制系统**不直接需要**美术资产。以下为间接需求:
| 资源类型 | 名称 | 数量 | 规格 | 触发时机/用途 |
|----------|------|------|------|---------------|
| 占位动画 | Idle(站立待机) | 1 | 简单 T-pose 或 A-pose 即可 | 角色静止时播放;v0.1 可无动画 |
| 占位动画 | Run(跑步循环) | 1 | 简单跑步循环 | 角色移动时播放;执行案明确"若无动画,角色滑动也可接受" |
> v0.1 不包含跳跃、蹲下、攀爬,不需要对应动画。
---
## 8. 技术风险与注意事项
| 风险 | 等级 | 说明 | 缓解措施 |
|------|------|------|---------|
| 软跟随手感不佳 | 🟢 低 | `CameraLagSpeed` 需要实际测试调整手感 | 多个预设值快速切换测试(推荐 4/6/8 三档) |
| 摄像机角落穿墙 | 🟢 低 | 角落/窄空间 SpringArm 碰撞可能出现抖动 | 角落场景专项测试,必要时加大 ProbeSize |
| CMC 加速/减速不符合预期 | 🟢 低 | CMC 物理模型不完全线性,受 `GroundFriction` 影响 | 参数范围已预留,实测微调 |
| 720°/s 转向过快导致"飘" | 🟢 低 | 无正式动画时转向缺乏视觉过渡 | v0.1 可接受,后续配合动画调整 `RotationRate` |
| 背对摄像机效果依赖转向速度比 | 🟢 低 | 若后续降低 `RotationRate` 或提高鼠标灵敏度,效果可能改变 | 保持 `RotationRate` 远大于鼠标旋转速度 |
### 注意事项
1. **IMC 资产更新**:新增交互 IA 后需在 IMC 中添加对应按键映射(E/ESC/Tab),此为蓝图操作,不在 C++ 代码中。
2. **跳跃移除的完整性**:移除跳跃时需同时检查蓝图中是否有 Jump 相关引用,避免编译警告。
3. **bIsInteracting 的线程安全**:v0.1 为单线程游戏,不需要加锁。如后续引入多线程需重新评估。
4. **IsRunning 阈值**:速度阈值 10 cm/s(`SizeSquared > 100`)为经验值,可能需要根据实际角色大小调整。
---
## 9. 数据流
### 配置参数流
@@ -320,8 +546,7 @@ bool IsRunning() const;
C++ 构造函数默认值 → 蓝图派生类可覆盖 → 运行时通过 Details 面板微调
```
v0.1 原型阶段所有参数在 C++ 中设置默认值,蓝图可覆盖。不使用 DataAsset 或配置表。
批量生产阶段迁移到参数 DataAsset。
v0.1 原型阶段所有参数在 C++ 中设置默认值,蓝图可覆盖。批量生产阶段迁移到参数 DataAsset。
### 运行时状态流
@@ -329,41 +554,17 @@ v0.1 原型阶段所有参数在 C++ 中设置默认值,蓝图可覆盖。不
Enhanced Input (WASD/鼠标)
→ AChildHoodPlayerController (IMC 注册)
→ AChildHoodCharacter (IA 回调)
├─ DoMove() → CMC (AddMovementInput)
├─ DoLook() → Controller (AddYawInput/AddPitchInput)
├─ DoMove() ─→ bIsInteracting? ─→ CMC (AddMovementInput)
├─ DoLook() ─→ Controller (AddYawInput/AddPitchInput)
│ → SpringArm (Controller Rotation)
│ → Camera (位置/旋转)
├─ InteractAction → InteractionManager (委托)
└─ bIsInteracting → DoMove() (输入屏蔽)
├─ InteractAction/CancelAction/SwitchInteractAction ─→ 交互系统(委托)
└─ 交互系统 ─→ SetInteracting(bool) ─→ bIsInteracting 标志
```
---
## 美术资源需求
v0.1 角色控制系统**不直接需要**美术资产。以下为间接需求:
| 资源类型 | 名称 | 数量 | 规格 | 说明 |
|----------|------|------|------|------|
| 占位动画 | Idle(站立待机) | 1 | 简单 T-pose 或 A-pose 即可 | v0.1 可无动画 |
| 占位动画 | Run(跑步循环) | 1 | 简单跑步循环,角色可在地面滑动 | 执行案明确说"若无动画资源,角色在地面滑动也可接受" |
> v0.1 角色控制不包含跳跃、蹲下、攀爬,因此不需要对应动画。
---
## 技术风险与注意事项
| 风险 | 等级 | 说明 | 缓解措施 |
|------|------|------|---------|
| 软跟随手感不佳 | 🟢 低 | CameraLagSpeed 需要实际测试调整 | 多个预设值快速切换测试 |
| 摄像机碰撞穿墙 | 🟢 低 | SpringArm 原生碰撞处理基本满足 | 角落/窄空间需额外测试 |
| CMC 加速/减速不符合预期 | 🟢 低 | CMC 物理模型不完全线性 | 参数范围已预留,微调即可 |
| 角色转身"飘"的感觉 | 🟢 低 | 720°/s 偏快可能导致动画不自然 | v0.1 无正式动画,暂时不是问题 |
---
## 可调参数汇总
## 10. 可调参数汇总
所有参数均在构造函数中设置默认值,蓝图可覆盖:
@@ -372,11 +573,60 @@ v0.1 角色控制系统**不直接需要**美术资产。以下为间接需求
| 摄像机距离 | `CameraBoom->TargetArmLength` | 350.0f | 构造函数 |
| 摄像机高度 | `CameraBoom->SocketOffset.Z` | 80.0f | 构造函数 |
| 跟随速度 | `CameraBoom->CameraLagSpeed` | 6.0f | 构造函数 |
| 碰撞检测 | `CameraBoom->bDoCollisionTest` | true | 构造函数 |
| 碰撞探针 | `CameraBoom->ProbeSize` | 12.0f | 构造函数 |
| 俯角上限 | `CameraManager->ViewPitchMax` | 45.0f | BeginPlay |
| 俯角下限 | `CameraManager->ViewPitchMin` | -30.0f | BeginPlay |
| 碰撞检测 | `CameraBoom->bDoCollisionTest` | true | 构造函数 |
| 跑步速度 | `CMC->MaxWalkSpeed` | 450.0f | 构造函数 |
| 加速度 | `CMC->MaxAcceleration` | 2250.0f | 构造函数 |
| 减速度 | `CMC->BrakingDecelerationWalking` | 1500.0f | 构造函数 |
| 转向速度 | `CMC->RotationRate.Yaw` | 720.0f | 构造函数 |
| 可行走坡度 | `CMC->WalkableFloorAngle` | 45.0f | 构造函数 |
---
## 11. 文件结构
```
Source/ChildHood/
├── ChildHoodCharacter.h # 修改:新增交互 IA、状态标志、查询接口;移除跳跃
├── ChildHoodCharacter.cpp # 修改:调整 CMC/SpringArm 参数;修改 DoMove;移除跳跃
├── ChildHoodPlayerController.h # 不修改
└── ChildHoodPlayerController.cpp # 修改:BeginPlay 中设置 Pitch 限幅
Content/
├── Input/
│ ├── IMC_Default.umap # 修改:新增 IA_Interact/IA_Cancel/IA_SwitchInteract 映射
│ ├── IA_Interact.uasset # 新增:E 键交互输入动作
│ ├── IA_Cancel.uasset # 新增:ESC 取消输入动作
│ └── IA_SwitchInteract.uasset # 新增:Tab/滚轮切换输入动作
└── Blueprints/
└── BP_ChildHoodCharacter # 可能修改:绑定新增 IA 到蓝图属性(若使用蓝图派生)
```
---
## 工期预估与实现拆分
### 工作量估算
| 维度 | 估算 |
|------|------|
| 总工期 | 1-2 天 |
| 修改 C++ 代码 | 约 60-80 行(净增 30 行 + 删除 20 行) |
| 新增蓝图 | 3 个 InputAction 资产 + IMC 修改 |
| 实现复杂度 | 低 |
### 实现拆分建议
| 子任务 | 内容 | 预估时间 | 依赖 | 验证方式 |
|--------|------|---------|------|---------|
| 6a-1 | 移除跳跃:删除 JumpAction、绑定、函数 | 0.5h | 无 | 编译通过 + 角色不跳跃 |
| 6a-2 | 调整 CMC/SpringArm 构造函数参数 | 0.5h | 无 | PIE 中测试移动手感、摄像机跟随 |
| 6a-3 | 添加 Pitch 限幅(PlayerController BeginPlay) | 0.5h | 无 | PIE 中测试鼠标上下看限幅 |
| 6a-4 | 新增交互状态管理(bIsInteracting + Set/Get) | 0.5h | 无 | 编译通过 + 蓝图可调用 |
| 6a-5 | 新增交互 IA 绑定(3 个 InputAction + IMC 修改) | 1h | 6a-4 | PIE 中按 E/ESC/Tab 无报错(回调委托给交互系统) |
| 6a-6 | 修改 DoMove 添加交互状态检查 | 0.5h | 6a-4 | 交互中按 WASD 角色不移动 |
| 6a-7 | 综合测试:手感微调 + 碰撞测试 + 边界情况 | 1-2h | 6a-1~6 | 全功能验证 |
> **总预估**:4-5 小时(约 1 个工作日)。预留半天调参和边界测试。