docs: 仿真器实体与事件映射 — 补充空基流程/Planner/状态机

This commit is contained in:
tian 2026-06-13 12:41:51 +08:00
parent 4e157834f7
commit 67223cd392

View File

@ -5,8 +5,8 @@
| 实体 | 类 | 生命周期 | 主要属性 |
|------|------|------|------|
| 无人机 | `DroneEntity` | 仿真全程 | Pos, Hp, Status, Route, ExposureTime |
| 发射平台 | `PlatformEntity` | 仿真全程 | Pos, PlatformType, AerosolType, MunitionCount, Cooldown |
| 飞行弹药 | `MunitionEntity` | 发射→到达释放高度 | Pos, LaunchMode, Target, HasArrived |
| 发射平台 | `PlatformEntity` | 仿真全程 | Pos, PlatformType, StateIdle/FlyingToTarget/ReadyToRelease, AerosolType, MunitionCount, Cooldown, CruiseSpeed, MuzzleVelocity, CurrentVelocity |
| 飞行弹药 | `MunitionEntity` | 发射→到达释放高度 | Pos, LaunchModeAirDrop/GroundArtillery, Target, HasArrived, 空基载机速度矢量 |
| 气溶胶云团 | `CloudEntity` | 弹药到达→消散 | Center, Radius, CoreDensity, IsDissipated |
| 管控区域 | `ControlZoneEntity` | 仿真全程 | Vertices, Min/MaxAltitude |
@ -35,33 +35,45 @@
## 数据流
```
FireSchedule (算法输出)
想定配置EquipmentDeployment + TargetConfig + RoutePlan + CombatScene
SimulationEngine.Initialize()
├─ BuildFireUnits() → List<FireUnit>
├─ BuildDroneGroups() → List<DroneGroup>
IDefensePlanner.Plan(fireUnits, threats, scene)
├─ 五步流水线 → FireSchedule发射计划
SimulationEngine.Tick()
├─ 时间到达 → PlatformEntity.Fire() → MunitionEntity 创建
│ │
│ ├─ OnMunitionLaunched ──→ Unity: 炮弹 3D 模型
│ │
│ └─ 飞行 → 到达释放高度
│ │
│ ├─ CloudEntity 创建
│ │
│ ├─ OnCloudGenerated ──→ Unity: 粒子系统
│ │
│ └─ 扩散 → 毁伤判定
│ │
│ ├─ DroneEntity.Hp -= dmg
│ │
│ └─ HP≤0 → OnDroneDestroyed ──→ Unity: 爆炸动画
├─ 【地基】时间到达 → PlatformEntity.Release() → MunitionEntity 创建
│ └─ OnMunitionLaunched ──→ Unity: 炮弹 3D 模型
├─ 【空基】时间到达 → PlatformEntity.CommandFlyTo() → 飞行中 → CanRelease
│ └─ Release() → MunitionEntity(AirDrop, 载机速度) → OnMunitionLaunched
│ └─ OnMunitionLaunched ──→ Unity: 空基投放
├─ MunitionEntity 飞行 → 到达释放高度
│ ├─ 地基抛物线弹道Kinematics.ParabolicPosition
│ └─ 空基:载机速度 + 重力Kinematics.AirDropPosition
│ │
│ ├─ CloudEntity 创建
│ ├─ OnCloudGenerated ──→ Unity: 粒子系统
│ └─ 扩散 → 毁伤判定
│ ├─ DroneEntity.Hp -= dmg
│ └─ HP≤0 → OnDroneDestroyed ──→ Unity: 爆炸动画
├─ DroneEntity.Update() → 到达终点
└─ OnDroneReachedTarget ──→ Unity: 抵达提示
│ └─ OnDroneReachedTarget ──→ Unity: 抵达提示
├─ ControlZone.ContainsPoint()
└─ OnZoneIntruded ──→ Unity: 红色警报
│ └─ OnZoneIntruded ──→ Unity: 红色警报
└─ All drones done
└─ OnSimulationEnded ──→ Unity: 结果面板 + 报告生成
└─ OnSimulationEnded ──→ Unity: 结果面板 + 报告生成
```