public static class AssetReferenceScanFinds what a Vixen-authored document points at.
No guide page documents this yet — the page shows what the code says about itself.
Remarks
Shared by every importer that reads the YAML dialect, because "what does this file depend on" has exactly one right answer and two importers deciding it separately is two answers. NativeFormatImporter carries a material through knowing nothing but this; SceneImporter compiles a scene and needs the same list for the same reason.
A walk of the node tree rather than a regular expression over the text, because a GUID inside a comment or a quoted description is not a reference and a text scan cannot tell the difference. It would produce a dependency that never changes and never breaks anything — which is exactly the kind of wrongness nobody finds.
Iterative rather than recursive. A scene is the deepest document the engine has and a deeply nested prefab hierarchy is an ordinary thing to author; a stack overflow inside an importer takes the whole process with it, which is the one failure the one-bad-asset-does-not-stop-the-build promise cannot catch.
Methods (1)
public static int Declare(YamlMapping root, ImportContext context)Declares every asset a document points at, and reports the ones that will not parse.
Used by (8)
- AnimationClipImporterVixen.Editor.Assets
- CompositorImporterVixen.Editor.Assets
- MaterialImporterVixen.Editor.Assets
- NativeFormatImporterVixen.Editor.Assets
- SceneImporterVixen.Editor.Assets
- ShapeYamlVixen.Editor.Assets
- TerrainAssetImporterVixen.Editor.Assets
- VfxImporterVixen.Editor.Assets