remapComponentEntityRefs
此内容尚不支持你的语言。
remapComponentEntityRefs(
components,idMapping):void
Defined in: prefab/entityRef.ts:16
Remap entity-typed component fields from prefab-local ids to runtime ids.
The mapping is keyed by PrefabEntityId (string) → runtime entity (number),
matching what flatten built. A component field whose value is a string —
the authored prefab-local reference — gets resolved through the mapping;
a numeric value is treated as already a runtime id (or zero/INVALID) and
left alone, so partially-instantiated/mutated components round-trip.
Parameters
Section titled “Parameters”components
Section titled “components”idMapping
Section titled “idMapping”Map<string, number>
Returns
Section titled “Returns”void