示例#1
0
 public void CleanCurScene()
 {
     if (curScene != null)
     {
         curScene.Dispose();
         curScene = null;
     }
 }
示例#2
0
    public void ChangeScene(string sceneName)
    {
        CleanCurScene();

        Resources.UnloadUnusedAssets();

        if (OnSceneEnter != null)
        {
            OnSceneEnter.Invoke();
        }

        curScene = new SceneIns(sceneName);
    }