コード例 #1
0
        public override void Unload()
        {
            UnityEditor.SceneManagement.EditorSceneManager.sceneOpening -= HandleUnitySceneOpening;

            m_Undo.UndoRedoBatchEnded -= HandleUndoEnded;

            m_ChangeManager.UnregisterChangeCallback(HandleChanges);

            foreach (var go in new HashSet <GameObject>(k_References.Values.Select(r => r.transform.root.gameObject)))
            {
                Object.DestroyImmediate(go);
            }
            k_References.Clear();
            k_ComponentCache.Clear();

            if (!ReloadingAssemblies)
            {
                UnityEditor.SceneManagement.EditorSceneManager.NewScene(NewSceneSetup.EmptyScene, NewSceneMode.Single);
            }
        }
コード例 #2
0
 public void Dispose()
 {
     m_ChangeManager.UnregisterChangeCallback(HandleChanges);
     AssetPostprocessorCallbacks.UnregisterAssetMovedHandlerForType <SceneAsset>(HandleMovedAsset);
 }
コード例 #3
0
 public override void Unload()
 {
     m_ChangeManager.UnregisterChangeCallback(HandleChanges);
     Flush();
     m_WorldManager = null;
 }
コード例 #4
0
 public override void Unload()
 {
     m_ChangeManager.UnregisterChangeCallback(HandleChanges);
     m_Undo.UndoRedoBatchStarted -= HandleUndoRedoStarted;
     m_Undo.UndoRedoBatchEnded   -= HandleUndoRedoEnded;
 }