Application翻译:^牛^魔王
- absoluteURL
- backgroundLoadingPriority
- CancelQuit
- CanStreamedLevelBeLoaded
- CaptureScreenshot
- dataPath
- ExternalCall
- ExternalEval
- GetStreamProgressForLevel
- internetReachability
- isEditor
- isLoadingLevel
- isPlaying
- isWebPlayer
- levelCount
- loadedLevelName
- loadedLevel
- LoadLevelAdditiveAsync
- LoadLevelAdditive
- LoadLevelAsync
- LoadLevel
- LogCallback
- OpenURL
- persistentDataPath
- platform
- Quit
- RegisterLogCallbackThreaded
- RegisterLogCallback
- runInBackground
- srcValue
- streamedBytes
- systemLanguage
- targetFrameRate
- temporaryCachePath
- unityVersion
- webSecurityEnabled
Application.loadedLevel 加载的关卡
static var loadedLevel : int
Description描述
The level index that was last loaded (Read Only).
最后加载的关卡索引(只读),关卡也就是一个独立的场景。
最后读取的场景代号(只读)
using UnityEngine;
using System.Collections;
public class example : MonoBehaviour {
public void Awake() {
print(Application.loadedLevel);
}
}
//打印当前场景的代号(索引号)
print (Application.loadedLevel);
最后修改:2010年12月15日 Wednesday 13:38