跳转到内容

validateOverrides

此内容尚不支持你的语言。

validateOverrides(prefab, options?): ValidateResult

Defined in: prefab/validate.ts:54

Find overrides pointing at entities or components that no longer exist.

The check is structural (no flatten). For nested-prefab site validation pass a loader via options.loadPrefab; without it, nested overrides are skipped (treated as “cannot verify”).

Used by the editor on scene open + on Apply-to-Source to warn the user before stale overrides silently disappear.

PrefabData

readonly PrefabOverride[]

Overrides applied at instance site, e.g. prefab:overrides metadata.

(path) => PrefabData | null

ValidateResult