Refactor Asset::GetReferences to support file path references
This commit is contained in:
@@ -179,10 +179,13 @@ public:
|
||||
/// For some asset types (e.g. scene or prefab) it may contain invalid asset ids due to not perfect gather method,
|
||||
/// which is optimized to perform scan very quickly. Before using those ids perform simple validation via Content cache API.
|
||||
/// The result collection contains only 1-level-deep references (only direct ones) and is invalid if asset is not loaded.
|
||||
/// Also the output data may have duplicated asset ids or even invalid ids (Guid::Empty).
|
||||
/// Also, the output data may have duplicated asset ids or even invalid ids (Guid::Empty).
|
||||
/// </remarks>
|
||||
/// <param name="output">The output collection of the asset ids referenced by this asset.</param>
|
||||
virtual void GetReferences(Array<Guid, HeapAllocation>& output) const;
|
||||
/// <param name="assets">The output collection of the asset ids referenced by this asset.</param>
|
||||
/// <param name="files">The output list of file paths referenced by this asset. Files might come from project Content folder (relative path is preserved in cooked game), or external location (copied into Content root folder of cooked game).</param>
|
||||
virtual void GetReferences(Array<Guid, HeapAllocation>& assets, Array<String, HeapAllocation>& files) const;
|
||||
// [Deprecated in v1.9]
|
||||
DEPRECATED virtual void GetReferences(Array<Guid, HeapAllocation>& output) const;
|
||||
|
||||
/// <summary>
|
||||
/// Gets the asset references. Supported only in Editor.
|
||||
@@ -191,7 +194,7 @@ public:
|
||||
/// For some asset types (e.g. scene or prefab) it may contain invalid asset ids due to not perfect gather method,
|
||||
/// which is optimized to perform scan very quickly. Before using those ids perform simple validation via Content cache API.
|
||||
/// The result collection contains only 1-level-deep references (only direct ones) and is invalid if asset is not loaded.
|
||||
/// Also the output data may have duplicated asset ids or even invalid ids (Guid::Empty).
|
||||
/// Also, the output data may have duplicated asset ids or even invalid ids (Guid::Empty).
|
||||
/// </remarks>
|
||||
/// <returns>The collection of the asset ids referenced by this asset.</returns>
|
||||
API_FUNCTION() Array<Guid, HeapAllocation> GetReferences() const;
|
||||
|
||||
Reference in New Issue
Block a user