用户工具

站点工具


侧边栏



Unity3D中文文档

script:unityengine:unityengine.scenemanagement:classes:scene:scene

Scene 场景

struct in UnityEngine.SceneManagement

Description 描述

Run-time data structure for *.unity file.

所有运行时的.unity文件的数据结构。

Variables 变量

buildIndexReturns the index of the scene in the Build Settings. Always returns -1 if the scene was loaded through an AssetBundle.
返回Build Settings中场景索引。如果场景已经通过资源包加载过则总是返回-1。
isDirtyReturns true if the scene is modifed.
如果场景被修改过则返回true。
isLoadedReturns true if the scene is loaded.
如果场景被加载则返回true。
nameReturns the name of the scene.
返回该场景的名称。
pathReturns the relative path of the scene. Like: “Assets/MyScenes/MyScene.unity”.
返回该场景的相对路径。就像“Assets/MyScenes/MyScene.unity”。
rootCountThe number of root transforms of this scene.
该场景的跟变换的数量。

Public Functions 公共函数

GetRootGameObjectsReturns all the root game objects in the scene.
返回该场景中所有的根物体。
IsValidTells if the scene is valid. A scene can be invalid if you eg. tried to open a scene that does not exists in that case the scene returnen from EditorSceneManager.OpenScene would be invalid.
告诉你该场景是否有效。一个场景可能是无效的。例如,尝试去打开一个场景时,该场景不存在,在这种情况下场景从EditorSceneManager.OpenScene返回可能是无效的。

Operators 运算符

operator !=Returns true if the Scenes are different.
如若场景不同返回true。
operator ==Returns true if the Scenes are equal.
如若场景一样则返回true。
script/unityengine/unityengine.scenemanagement/classes/scene/scene.txt · 最后更改: 2016/08/02 05:37 (外部编辑)