跳到主要内容
版本:2.3.x

Class SceneHandle

Assembly: YooAsset.dll
Declaration
public class SceneHandle : HandleBase, IEnumerator, IDisposable

Properties

SceneName

场景名称

Declaration
public string SceneName { get; }

SceneObject

场景对象

Declaration
public Scene SceneObject { get; }

Methods

ActivateScene()

激活场景(当同时存在多个场景时用于切换激活场景)

Declaration
public bool ActivateScene()
Returns

System.Boolean

UnSuspend()

解除场景加载挂起操作

Declaration
public bool UnSuspend()
Returns

System.Boolean

UnloadAsync()

异步卸载场景对象 注意:场景卸载成功后,会自动释放该handle的引用计数!

Declaration
public UnloadSceneOperation UnloadAsync()
Returns

YooAsset.UnloadSceneOperation

Events

Completed

完成委托

Declaration
public event Action<SceneHandle> Completed
Event Type

System.Action<YooAsset.SceneHandle>

Implements

  • System.Collections.IEnumerator
  • System.IDisposable