- Add RoomStreamingManager to manage room loading and unloading based on player proximity. - Create StreamingBudgetConfigSO for memory and performance budgeting of the streaming system. - Introduce TransitionDirector to handle seamless and atmospheric fade transitions between rooms. - Develop WorldGraph to represent room connectivity and facilitate neighbor queries and distance calculations. - Implement RoomNode and RoomEdge classes to structure room data and connections.
30 lines
870 B
C#
30 lines
870 B
C#
namespace BaseGames.World
|
||
{
|
||
/// <summary>
|
||
/// 房间在流式加载系统中的生命周期状态。
|
||
/// </summary>
|
||
public enum RoomState
|
||
{
|
||
/// <summary>未加载,资产不在内存中。</summary>
|
||
Unloaded,
|
||
|
||
/// <summary>正在后台异步加载中。</summary>
|
||
Loading,
|
||
|
||
/// <summary>已加载并初始化,处于休眠状态:渲染器、AI、物理均已关闭,不消耗 CPU。</summary>
|
||
Dormant,
|
||
|
||
/// <summary>正在激活中(分帧启用 AI)。</summary>
|
||
Activating,
|
||
|
||
/// <summary>完全激活,玩家当前所在的房间。</summary>
|
||
Active,
|
||
|
||
/// <summary>玩家已离开,等待冷却计时后转为 Dormant 或 Unloaded。</summary>
|
||
Cooling,
|
||
|
||
/// <summary>正在后台异步卸载中。</summary>
|
||
Unloading,
|
||
}
|
||
}
|