EditorApplication
- applicationContentsPath
- applicationPath
- Beep
- CallbackFunction
- currentScene
- ExecuteMenuItem
- Exit
- HierarchyWindowItemCallback
- hierarchyWindowItemOnGUI
- isCompiling
- isPaused
- isPlayingOrWillChangePlaymode
- isPlaying
- LockReloadAssemblies
- modifierKeysChanged
- NewScene
- OpenProject
- OpenSceneAdditive
- OpenScene
- playmodeStateChanged
- ProjectWindowItemCallback
- projectWindowItemOnGUI
- RepaintHierarchyWindow
- RepaintProjectWindow
- SaveAssets
- SaveCurrentSceneIfUserWantsTo
- SaveScene
- Step
- timeSinceStartup
- UnlockReloadAssemblies
- update
EditorApplication.isCompiling 是否正编译
static var isCompiling : bool
Description描述
Is editor currently compiling scripts? (Read Only)
当前编辑器是否在编译脚本(只读)?
Editor Window that tells you if Unity is compiling scripts.
如果Unity正编译脚本,编辑器窗口告诉你。
// Dont let the user enter in play mode if the editor is compiling the assemblies
//当用户在编译程序时禁止用户进入播放状态
class FinishCompiling extends EditorWindow {
@MenuItem("Example/Dont Let Play until finish compiling")
static function Init() {
var window : FinishCompiling =
EditorWindow.GetWindowWithRect(FinishCompiling, Rect(0,0,165,40));
window.Show();
}
function OnGUI () {
EditorGUILayout.LabelField("Compiling:", EditorApplication.isCompiling?"YES" : "No");
}
function Update() {
if(EditorApplication.isCompiling) {
EditorApplication.isPlaying = false;
}
}
}
最后修改:2011年6月25日 Saturday 18:47