using MoonTools.ECS;
using System.Numerics;
namespace Nerfed.Runtime.Scene.Streaming;
///
/// Marks an entity as a streaming observer (e.g. the player camera) that causes chunks
/// to be loaded around it.
///
public struct ChunkObserverComponent
{
public float ViewRadius;
}
///
/// Tags an entity as belonging to a specific chunk, allowing it to be unloaded when the chunk is out of range.
///
public struct ChunkMemberComponent
{
// A 64-bit spatial hash combining the X, Y, and Z coordinates.
public long ChunkId;
}
///
/// Added to entities that belong to a chunk that has been unloaded.
/// A dedicated system will process and destroy these slowly over multiple frames.
///
public struct ChunkUnloadPendingTag { }