505 lines
17 KiB
Markdown
505 lines
17 KiB
Markdown
# 英雄管理组件交互
|
||
|
||
<cite>
|
||
**本文档引用的文件**
|
||
- [MissionHeroComp.ts](file://assets/script/game/map/MissionHeroComp.ts)
|
||
- [SingletonModuleComp.ts](file://assets/script/game/common/SingletonModuleComp.ts)
|
||
- [GameEvent.ts](file://assets/script/game/common/config/GameEvent.ts)
|
||
- [heroSet.ts](file://assets/script/game/common/config/heroSet.ts)
|
||
- [Hero.ts](file://assets/script/game/hero/Hero.ts)
|
||
- [HeroViewComp.ts](file://assets/script/game/hero/HeroViewComp.ts)
|
||
- [BattleMoveComp.ts](file://assets/script/game/common/ecs/position/BattleMoveComp.ts)
|
||
</cite>
|
||
|
||
## 目录
|
||
1. [简介](#简介)
|
||
2. [项目结构概览](#项目结构概览)
|
||
3. [核心组件分析](#核心组件分析)
|
||
4. [架构概览](#架构概览)
|
||
5. [详细组件分析](#详细组件分析)
|
||
6. [英雄生命周期管理](#英雄生命周期管理)
|
||
7. [事件处理机制](#事件处理机制)
|
||
8. [数据绑定关系](#数据绑定关系)
|
||
9. [时序图示例](#时序图示例)
|
||
10. [性能考虑](#性能考虑)
|
||
11. [故障排除指南](#故障排除指南)
|
||
12. [总结](#总结)
|
||
|
||
## 简介
|
||
|
||
MissionHeroCompComp类是游戏战斗系统中负责管理英雄生命周期的核心组件。它通过ECS架构模式,实现了英雄的初始化、召唤、战斗管理和清理等完整生命周期流程。该组件与SingletonModuleComp单例、GameEvent事件系统以及Hero实体组件紧密协作,形成了一个完整的英雄管理系统。
|
||
|
||
## 项目结构概览
|
||
|
||
```mermaid
|
||
graph TB
|
||
subgraph "战斗系统架构"
|
||
MissionHeroComp[MissionHeroCompComp<br/>英雄管理组件]
|
||
SingletonModule[SingletonModuleComp<br/>单例模块]
|
||
HeroEntity[Hero实体]
|
||
GameEvents[GameEvent事件系统]
|
||
end
|
||
subgraph "英雄组件体系"
|
||
HeroView[HeroViewComp<br/>英雄视图组件]
|
||
BattleMove[BattleMoveComp<br/>战斗移动组件]
|
||
HeroModel[HeroModelComp<br/>英雄模型组件]
|
||
end
|
||
subgraph "配置数据层"
|
||
HeroSet[heroSet配置]
|
||
GameConfig[GameEvent配置]
|
||
SMData[SMC数据]
|
||
end
|
||
MissionHeroComp --> SingletonModule
|
||
MissionHeroComp --> HeroEntity
|
||
MissionHeroComp --> GameEvents
|
||
HeroEntity --> HeroView
|
||
HeroEntity --> BattleMove
|
||
HeroEntity --> HeroModel
|
||
SingletonModule --> SMData
|
||
GameEvents --> GameConfig
|
||
HeroEntity --> HeroSet
|
||
```
|
||
|
||
**图表来源**
|
||
- [MissionHeroComp.ts](file://assets/script/game/map/MissionHeroComp.ts#L1-L81)
|
||
- [SingletonModuleComp.ts](file://assets/script/game/common/SingletonModuleComp.ts#L1-L195)
|
||
- [Hero.ts](file://assets/script/game/hero/Hero.ts#L15-L101)
|
||
|
||
## 核心组件分析
|
||
|
||
### MissionHeroCompComp类结构
|
||
|
||
MissionHeroCompComp继承自CCComp基类,注册为ECS系统中的MissionHero组件。该类维护以下核心状态:
|
||
|
||
- **timer**: 定时器组件,用于控制英雄召唤间隔
|
||
- **Friend_is_dead**: 标记友方英雄是否死亡
|
||
- **current_hero_uuid**: 当前英雄的唯一标识符
|
||
- **current_hero_num**: 当前英雄数量
|
||
- **heros**: 英雄数组,存储所有战斗中的英雄信息
|
||
|
||
**章节来源**
|
||
- [MissionHeroComp.ts](file://assets/script/game/map/MissionHeroComp.ts#L11-L18)
|
||
|
||
## 架构概览
|
||
|
||
```mermaid
|
||
classDiagram
|
||
class MissionHeroCompComp {
|
||
+Timer timer
|
||
+boolean Friend_is_dead
|
||
+number current_hero_uuid
|
||
+number current_hero_num
|
||
+any[] heros
|
||
+onLoad() void
|
||
+clear_heros() void
|
||
+fight_ready() void
|
||
+zhao_huan(event, args) void
|
||
+addHero(uuid, is_zhaohuan) void
|
||
+reset() void
|
||
}
|
||
class SingletonModuleComp {
|
||
+number fight_hero
|
||
+any heros
|
||
+any vmdata
|
||
+updateFihgtHero(heroId) void
|
||
+addHero(hero_uuid) void
|
||
}
|
||
class Hero {
|
||
+HeroModelComp HeroModel
|
||
+HeroViewComp HeroView
|
||
+BattleMoveComp BattleMove
|
||
+load(pos, scale, uuid, fight_pos) void
|
||
+hero_init(uuid, node) HeroViewComp
|
||
}
|
||
class GameEvent {
|
||
<<enumeration>>
|
||
FightReady
|
||
Zhaohuan
|
||
FightEnd
|
||
}
|
||
MissionHeroCompComp --> SingletonModuleComp : "使用"
|
||
MissionHeroCompComp --> Hero : "创建"
|
||
MissionHeroCompComp --> GameEvent : "监听"
|
||
SingletonModuleComp --> Hero : "配置"
|
||
```
|
||
|
||
**图表来源**
|
||
- [MissionHeroComp.ts](file://assets/script/game/map/MissionHeroComp.ts#L11-L81)
|
||
- [SingletonModuleComp.ts](file://assets/script/game/common/SingletonModuleComp.ts#L20-L50)
|
||
- [Hero.ts](file://assets/script/game/hero/Hero.ts#L15-L101)
|
||
|
||
## 详细组件分析
|
||
|
||
### fight_ready方法实现
|
||
|
||
fight_ready方法是战斗准备阶段的核心入口点,负责初始化战斗环境中的英雄配置。
|
||
|
||
```mermaid
|
||
sequenceDiagram
|
||
participant Player as "玩家"
|
||
participant MissionHero as "MissionHeroCompComp"
|
||
participant SMC as "SingletonModuleComp"
|
||
participant Hero as "Hero实体"
|
||
participant ECS as "ECS系统"
|
||
Player->>MissionHero : 战斗准备开始
|
||
MissionHero->>SMC : 获取战斗英雄配置
|
||
SMC-->>MissionHero : 返回fight_hero配置
|
||
MissionHero->>MissionHero : 设置hero_num=0
|
||
MissionHero->>MissionHero : 调用addHero(fight_hero, false)
|
||
MissionHero->>ECS : 获取Hero实体
|
||
ECS-->>MissionHero : 返回Hero实例
|
||
MissionHero->>Hero : load(position, scale, uuid)
|
||
Hero->>Hero : 初始化英雄属性
|
||
Hero->>Hero : 设置战斗位置
|
||
Hero-->>Player : 英雄出现在战场
|
||
```
|
||
|
||
**图表来源**
|
||
- [MissionHeroComp.ts](file://assets/script/game/map/MissionHeroComp.ts#L32-L42)
|
||
- [Hero.ts](file://assets/script/game/hero/Hero.ts#L30-L60)
|
||
|
||
该方法执行以下关键步骤:
|
||
|
||
1. **状态重置**: 将`smc.vmdata.mission_data.hero_num`设置为0,清空当前英雄计数
|
||
2. **英雄加载**: 调用`addHero(smc.fight_hero, false)`加载玩家选择的英雄
|
||
3. **配置应用**: 使用SMC单例中的fight_hero配置作为英雄标识
|
||
|
||
**章节来源**
|
||
- [MissionHeroComp.ts](file://assets/script/game/map/MissionHeroComp.ts#L32-L42)
|
||
|
||
### addHero方法实现
|
||
|
||
addHero方法是英雄加载的核心逻辑,负责通过ECS系统获取Hero实体并调用其load方法。
|
||
|
||
```mermaid
|
||
flowchart TD
|
||
Start([开始addHero]) --> GetHero["获取Hero实体<br/>ecs.getEntity<Hero>(Hero)"]
|
||
GetHero --> SetParams["设置参数<br/>hero_pos=0<br/>scale=1"]
|
||
SetParams --> GetPos["获取英雄位置<br/>HeroPos[hero_pos].pos"]
|
||
GetPos --> LoadHero["调用hero.load()<br/>加载英雄实体"]
|
||
LoadHero --> InitProps["初始化英雄属性<br/>调用hero_init()"]
|
||
InitProps --> SetDirection["设置移动方向<br/>根据英雄类型"]
|
||
SetDirection --> UpdateCount["更新英雄计数<br/>smc.vmdata.mission_data.hero_num++"]
|
||
UpdateCount --> End([结束])
|
||
LoadHero --> ErrorHandler["错误处理"]
|
||
ErrorHandler --> End
|
||
```
|
||
|
||
**图表来源**
|
||
- [MissionHeroComp.ts](file://assets/script/game/map/MissionHeroComp.ts#L64-L70)
|
||
- [Hero.ts](file://assets/script/game/hero/Hero.ts#L30-L60)
|
||
|
||
addHero方法的具体实现细节:
|
||
|
||
1. **实体获取**: 使用`ecs.getEntity<Hero>(Hero)`从ECS系统中获取Hero实体
|
||
2. **参数设置**: 固定英雄位置索引为0,缩放比例为1
|
||
3. **位置计算**: 从HeroPos配置中获取英雄的战斗位置
|
||
4. **英雄加载**: 调用hero.load()方法完成英雄实体的初始化和渲染
|
||
|
||
**章节来源**
|
||
- [MissionHeroComp.ts](file://assets/script/game/map/MissionHeroComp.ts#L64-L70)
|
||
|
||
### zhao_huan事件处理
|
||
|
||
zhao_huan方法响应召唤指令事件,实现实时英雄召唤功能。
|
||
|
||
```mermaid
|
||
sequenceDiagram
|
||
participant UI as "用户界面"
|
||
participant MissionHero as "MissionHeroCompComp"
|
||
participant EventSys as "事件系统"
|
||
participant Hero as "Hero实体"
|
||
UI->>EventSys : 发送Zhaohuan事件
|
||
EventSys->>MissionHero : 触发zhao_huan回调
|
||
MissionHero->>MissionHero : addHero(args.uuid, false)
|
||
MissionHero->>Hero : 创建新英雄实例
|
||
Hero-->>UI : 新英雄出现在战场
|
||
```
|
||
|
||
**图表来源**
|
||
- [MissionHeroComp.ts](file://assets/script/game/map/MissionHeroComp.ts#L50-L52)
|
||
|
||
该方法的特点:
|
||
- **实时响应**: 接收召唤事件参数中的英雄UUID
|
||
- **即时召唤**: 直接调用addHero方法加载新英雄
|
||
- **非召唤模式**: 第二个参数为false,表示这不是召唤模式的英雄
|
||
|
||
**章节来源**
|
||
- [MissionHeroComp.ts](file://assets/script/game/map/MissionHeroComp.ts#L50-L52)
|
||
|
||
### clear_heros方法
|
||
|
||
clear_heros方法在战斗结束时执行英雄清理逻辑,确保战斗环境的正确重置。
|
||
|
||
```mermaid
|
||
flowchart TD
|
||
Start([战斗结束]) --> ClearMethod["调用clear_heros()"]
|
||
ClearMethod --> LogCheck{"检查日志输出"}
|
||
LogCheck --> |启用| LogMessage["打印清理消息"]
|
||
LogCheck --> |禁用| SkipLog["跳过日志"]
|
||
LogMessage --> End([清理完成])
|
||
SkipLog --> End
|
||
Note1["目前方法体为空<br/>预留扩展空间"]
|
||
```
|
||
|
||
**图表来源**
|
||
- [MissionHeroComp.ts](file://assets/script/game/map/MissionHeroComp.ts#L28-L30)
|
||
|
||
当前实现特点:
|
||
- **空方法体**: 目前方法体为空,但预留了扩展空间
|
||
- **日志占位**: 包含注释掉的日志输出语句
|
||
- **扩展性**: 为未来的清理逻辑提供了接口
|
||
|
||
**章节来源**
|
||
- [MissionHeroComp.ts](file://assets/script/game/map/MissionHeroComp.ts#L28-L30)
|
||
|
||
## 英雄生命周期管理
|
||
|
||
### 英雄创建流程
|
||
|
||
```mermaid
|
||
stateDiagram-v2
|
||
[*] --> 初始化
|
||
初始化 --> 配置加载 : fight_ready事件
|
||
配置加载 --> 实体获取 : ecs.getEntity<Hero>()
|
||
实体获取 --> 位置设置 : HeroPos配置
|
||
位置设置 --> 属性初始化 : hero_init()
|
||
属性初始化 --> 移动设置 : BattleMove配置
|
||
移动设置 --> 计数更新 : hero_num++
|
||
计数更新 --> 战场就绪 : 英雄出现在战场
|
||
战场就绪 --> 战斗中 : 开始战斗
|
||
战斗中 --> 死亡检测 : 英雄死亡
|
||
死亡检测 --> 清理处理 : 英雄移除
|
||
清理处理 --> [*]
|
||
```
|
||
|
||
**图表来源**
|
||
- [Hero.ts](file://assets/script/game/hero/Hero.ts#L30-L80)
|
||
- [MissionHeroComp.ts](file://assets/script/game/map/MissionHeroComp.ts#L64-L70)
|
||
|
||
### 英雄属性系统
|
||
|
||
HeroViewComp组件负责管理英雄的所有属性和状态:
|
||
|
||
| 属性类别 | 属性名称 | 描述 | 类型 |
|
||
|---------|---------|------|------|
|
||
| 基础属性 | base_hp/base_mp | 基础生命值/魔法值 | number |
|
||
| 核心属性 | hp/mp | 当前生命值/魔法值 | number |
|
||
| 攻击属性 | base_ap/base_map | 基础物理攻击/魔法攻击 | number |
|
||
| 防御属性 | base_def/mdef | 基础物理防御/魔法防御 | number |
|
||
| 移动属性 | base_speed/base_dis | 基础移动速度/攻击距离 | number |
|
||
| BUFF系统 | BUFFS/BUFFS_TEMP | 持久/临时BUFF数组 | Record |
|
||
|
||
**章节来源**
|
||
- [HeroViewComp.ts](file://assets/script/game/hero/HeroViewComp.ts#L72-L120)
|
||
|
||
## 事件处理机制
|
||
|
||
### 事件监听配置
|
||
|
||
MissionHeroCompComp通过on方法注册三个关键事件的处理器:
|
||
|
||
```mermaid
|
||
graph LR
|
||
subgraph "事件监听"
|
||
FightReady[FightReady<br/>战斗准备]
|
||
Zhaohuan[Zhaohuan<br/>英雄召唤]
|
||
FightEnd[FightEnd<br/>战斗结束]
|
||
end
|
||
subgraph "处理方法"
|
||
FRHandler[fight_ready]
|
||
ZHHandler[zhao_huan]
|
||
FERHandler[clear_heros]
|
||
end
|
||
FightReady --> FRHandler
|
||
Zhaohuan --> ZHHandler
|
||
FightEnd --> FERHandler
|
||
```
|
||
|
||
**图表来源**
|
||
- [MissionHeroComp.ts](file://assets/script/game/map/MissionHeroComp.ts#L19-L23)
|
||
- [GameEvent.ts](file://assets/script/game/common/config/GameEvent.ts#L15-L25)
|
||
|
||
### 事件触发时机
|
||
|
||
| 事件名称 | 触发时机 | 处理内容 |
|
||
|---------|---------|---------|
|
||
| FightReady | 战斗开始前 | 初始化战斗英雄配置 |
|
||
| Zhaohuan | 英雄召唤时 | 动态添加新英雄 |
|
||
| FightEnd | 战斗结束后 | 清理战斗环境 |
|
||
|
||
**章节来源**
|
||
- [GameEvent.ts](file://assets/script/game/common/config/GameEvent.ts#L15-L25)
|
||
|
||
## 数据绑定关系
|
||
|
||
### SMC单例中的英雄数据
|
||
|
||
SingletonModuleComp通过vmdata属性系统实现与UI层的数据绑定:
|
||
|
||
```mermaid
|
||
erDiagram
|
||
SingletonModuleComp {
|
||
number fight_hero
|
||
any heros
|
||
any monsters
|
||
object vmdata
|
||
}
|
||
VMData {
|
||
boolean game_over
|
||
boolean game_pause
|
||
object mission_data
|
||
number gold
|
||
}
|
||
MissionData {
|
||
number mon_num
|
||
number hero_num
|
||
number wave_time_num
|
||
boolean in_fight
|
||
number fight_time
|
||
number level
|
||
number max_mission
|
||
number coin
|
||
}
|
||
SingletonModuleComp ||--|| VMData : "包含"
|
||
VMData ||--|| MissionData : "包含"
|
||
```
|
||
|
||
**图表来源**
|
||
- [SingletonModuleComp.ts](file://assets/script/game/common/SingletonModuleComp.ts#L40-L60)
|
||
|
||
### 数据流映射
|
||
|
||
| 数据源 | 目标组件 | 绑定方式 | 更新时机 |
|
||
|-------|---------|---------|---------|
|
||
| smc.fight_hero | MissionHeroCompComp | 直接访问 | 战斗准备时 |
|
||
| smc.heros | UI界面 | MVVM绑定 | 英雄解锁时 |
|
||
| smc.vmdata.mission_data.hero_num | 战斗计数器 | 自动更新 | 英雄加载时 |
|
||
| smc.vmdata.gold | 金币显示 | MVVM绑定 | 金币变化时 |
|
||
|
||
**章节来源**
|
||
- [SingletonModuleComp.ts](file://assets/script/game/common/SingletonModuleComp.ts#L40-L60)
|
||
|
||
## 时序图示例
|
||
|
||
### 完整英雄加载时序
|
||
|
||
```mermaid
|
||
sequenceDiagram
|
||
participant Player as "玩家"
|
||
participant UI as "UI界面"
|
||
participant SMC as "SMC单例"
|
||
participant MissionHero as "MissionHeroComp"
|
||
participant ECS as "ECS系统"
|
||
participant Hero as "Hero实体"
|
||
participant BattleMove as "BattleMove组件"
|
||
Note over Player,BattleMove : 战斗准备阶段
|
||
Player->>UI : 选择战斗英雄
|
||
UI->>SMC : updateFihgtHero(5001)
|
||
SMC->>SMC : 更新fight_hero配置
|
||
Player->>MissionHero : 触发FightReady事件
|
||
MissionHero->>SMC : 获取smc.fight_hero
|
||
SMC-->>MissionHero : 返回英雄UUID 5001
|
||
MissionHero->>MissionHero : 设置hero_num=0
|
||
Note over Player,BattleMove : 英雄加载阶段
|
||
MissionHero->>ECS : ecs.getEntity<Hero>(Hero)
|
||
ECS-->>MissionHero : 返回Hero实例
|
||
MissionHero->>Hero : load(v3(-240,100,0), 1, 5001)
|
||
Hero->>Hero : 初始化英雄属性
|
||
Hero->>Hero : 设置战斗位置
|
||
Hero->>BattleMove : 配置移动方向
|
||
BattleMove-->>Hero : 设置targetX=0
|
||
Hero->>SMC : 更新hero_num++
|
||
SMC-->>Player : 英雄出现在战场
|
||
Note over Player,BattleMove : 战斗进行阶段
|
||
Player->>MissionHero : 触发Zhaohuan事件
|
||
MissionHero->>ECS : 再次获取Hero实体
|
||
ECS-->>MissionHero : 返回新的Hero实例
|
||
MissionHero->>Hero : load(v3(0,100,0), 1, 新英雄UUID)
|
||
Hero-->>Player : 新英雄加入战斗
|
||
```
|
||
|
||
**图表来源**
|
||
- [MissionHeroComp.ts](file://assets/script/game/map/MissionHeroComp.ts#L32-L70)
|
||
- [Hero.ts](file://assets/script/game/hero/Hero.ts#L30-L80)
|
||
- [SingletonModuleComp.ts](file://assets/script/game/common/SingletonModuleComp.ts#L120-L140)
|
||
|
||
### 英雄召唤时序
|
||
|
||
```mermaid
|
||
sequenceDiagram
|
||
participant Player as "玩家"
|
||
participant UI as "UI界面"
|
||
participant MissionHero as "MissionHeroComp"
|
||
participant EventSys as "事件系统"
|
||
participant ECS as "ECS系统"
|
||
participant Hero as "Hero实体"
|
||
Player->>UI : 点击召唤按钮
|
||
UI->>EventSys : dispatchEvent(Zhaohuan, {uuid : 5002})
|
||
EventSys->>MissionHero : 触发zhao_huan事件
|
||
MissionHero->>MissionHero : addHero(5002, false)
|
||
MissionHero->>ECS : ecs.getEntity<Hero>(Hero)
|
||
ECS-->>MissionHero : 返回Hero实例
|
||
MissionHero->>Hero : load(v3(0,100,0), 1, 5002)
|
||
Hero->>Hero : 初始化新英雄属性
|
||
Hero->>Hero : 设置战斗位置
|
||
Hero-->>Player : 新英雄出现在战场
|
||
Note over Player,Hero : 英雄加入战斗
|
||
Hero->>Hero : 开始参与战斗
|
||
```
|
||
|
||
**图表来源**
|
||
- [MissionHeroComp.ts](file://assets/script/game/map/MissionHeroComp.ts#L50-L52)
|
||
- [Hero.ts](file://assets/script/game/hero/Hero.ts#L30-L60)
|
||
|
||
## 性能考虑
|
||
|
||
### ECS架构优势
|
||
|
||
1. **组件化设计**: Hero实体采用ECS架构,避免了传统继承层次的复杂性
|
||
2. **内存优化**: 通过组件池复用Hero实体,减少内存分配开销
|
||
3. **系统解耦**: 各组件职责单一,便于维护和扩展
|
||
|
||
### 事件处理优化
|
||
|
||
1. **事件监听**: 使用事件系统解耦组件间的直接依赖
|
||
2. **延迟处理**: 通过定时器控制英雄召唤间隔
|
||
3. **状态管理**: 通过SMC单例集中管理全局状态
|
||
|
||
### 渲染性能
|
||
|
||
1. **批量操作**: 批量处理英雄位置和属性更新
|
||
2. **组件缓存**: 缓存HeroViewComp等常用组件引用
|
||
3. **条件渲染**: 根据战斗状态动态启用/禁用组件
|
||
|
||
## 故障排除指南
|
||
|
||
### 常见问题及解决方案
|
||
|
||
| 问题类型 | 症状描述 | 可能原因 | 解决方案 |
|
||
|---------|---------|---------|---------|
|
||
| 英雄不出现 | 战斗开始后没有英雄 | fight_hero配置错误 | 检查smc.fight_hero设置 |
|
||
| 英雄位置错误 | 英雄出现在错误位置 | HeroPos配置问题 | 验证HeroPos数组配置 |
|
||
| 英雄属性异常 | 英雄属性显示错误 | HeroInfo配置缺失 | 检查HeroInfo中的英雄数据 |
|
||
| 事件不响应 | Zhaohuan事件无效 | 事件监听未注册 | 确认on方法调用 |
|
||
|
||
### 调试技巧
|
||
|
||
1. **日志输出**: 启用注释掉的日志语句进行调试
|
||
2. **断点调试**: 在关键方法设置断点观察变量状态
|
||
3. **状态检查**: 通过浏览器开发者工具检查SMC状态
|
||
|
||
**章节来源**
|
||
- [MissionHeroComp.ts](file://assets/script/game/map/MissionHeroComp.ts#L32-L70)
|
||
|
||
## 总结
|
||
|
||
MissionHeroCompComp类通过精心设计的ECS架构和事件驱动机制,实现了完整的英雄生命周期管理。该系统具有以下核心优势:
|
||
|
||
1. **模块化设计**: 清晰的职责分离和组件化架构
|
||
2. **事件驱动**: 基于事件系统的松耦合设计
|
||
3. **数据绑定**: 与UI层的无缝数据同步
|
||
4. **扩展性强**: 预留的扩展点支持未来功能增强
|
||
5. **性能优化**: 通过ECS架构实现高效的组件管理
|
||
|
||
该英雄管理系统为游戏战斗提供了稳定可靠的基础框架,支持动态英雄召唤、战斗状态管理和资源回收等功能,是整个战斗系统的重要组成部分。 |