@relu-interactives/spatial-ecs
@relu-interactives/spatial-ecs / index / SubtreeSnapshot
Type Alias: SubtreeSnapshot ​
ts
type SubtreeSnapshot = {
entities: number[];
components: {
component: string;
entries: {
entityId: number;
value: unknown;
}[];
}[];
};Defined in: prefab/snapshotIdUtils.ts:17
Snapshot-space entity-id walking/remapping.
This module is the single source of truth for WHERE entity ids live inside a serialized world snapshot:
ParentId.valueScriptComponent.entries[].dataEntityInput ({type:"entity", value}) and ComponentInput ({type:"component", value:{entityId, …}})ScriptObjectComponent.dataEntityInput/ComponentInput (same shapes)InstancedMeshComponent.instanceEntityIds[]InstanceSlotComponent.groupEntityId
Any new id-bearing component field must be added here — serialization, instantiation and the override differ all route through this walker.
Properties ​
| Property | Type | Defined in |
|---|---|---|
entities | number[] | prefab/snapshotIdUtils.ts:18 |
components | { component: string; entries: { entityId: number; value: unknown; }[]; }[] | prefab/snapshotIdUtils.ts:19 |

