@relu-interactives/spatial-ecs
@relu-interactives/spatial-ecs / components / PrefabNode
Class: PrefabNode ​
Defined in: components/PrefabNode.ts:17
Stable identity for an entity that originated from a prefab asset.
Every entity serialized into a .prefab file carries a PrefabNode with a uuid nodeId. Hydrating the prefab (editor instantiate or runtime spawn) restores the component, so each instance entity can be matched back to its prefab-file counterpart regardless of live entity ids. The per-property override system diffs and merges in nodeId-space.
Node ids are unique within one prefab subtree — two instances of the same prefab intentionally share nodeIds.
Extends ​
Constructors ​
Constructor ​
ts
new PrefabNode(nodeId): PrefabNode;Defined in: components/PrefabNode.ts:21
Parameters ​
| Parameter | Type |
|---|---|
nodeId | string |
Returns ​
PrefabNode
Overrides ​
Properties ​
| Property | Type | Description | Defined in |
|---|---|---|---|
nodeId | string | Stable uuid identifying this entity within its prefab definition. | components/PrefabNode.ts:19 |

