void OnDestroy() { Inst = null; // 场景主界面 if (m_sceneWindow != null) { m_sceneWindow.CloseWindow(); } m_sceneWindow = null; // 事件关闭 SceneView.onSceneGUIDelegate -= OnSceneGUI; EditorSceneManager.sceneOpened -= OnSceneOpened; }
public static void OpenCubeWorldEditorWindow() { Inst = GetWindow <CubeWorldEditorWindow>(false, ""); Inst.titleContent.text = "Cube World Editor"; Inst.minSize = new Vector2(SettingManager.Inst.Setting.EditorWidth, 100); }