Struct WeakObjectSceneReference
Weak reference to a scene. The Result field can be accessed after the scene has completed loading.
Namespace: Unity.Entities.Content
Assembly: Unity.Entities.dll
Syntax
[Serializable]
public struct WeakObjectSceneReference
Fields
Name | Description |
---|---|
Id | The reference Id. |
Properties
Name | Description |
---|---|
IsReferenceValid | Returns true if the reference has a valid id. In the editor, additional checks for the correct GenerationType and the existence of the referenced asset are performed. |
LoadingStatus | True if the object is either being loaded or already finished loading. |
SceneFileResult | The ContentSceneFile that was loaded. This can be used to manually integrate the loaded scene at the end of the frame. |
SceneResult | The loaded scene object. |
Methods
Name | Description |
---|---|
Equals(WeakObjectSceneReference) | |
GetHashCode() | Returns the hash code of this reference. |
LoadAsync(ContentSceneParameters) | Loads a scene. |
Release() | Releases the object. This will decrement the reference count of this object. When an objects reference count reaches 0, the archive file is released. The archive file is only unloaded when its reference count reaches zero, which will then release the archive it was loaded from. Archives will be unmounted when their reference count reaches 0. |
ToString() | String conversion override. |
Unload(ref Scene) | Unloads a scene. |