ReadScenes() public static method

Reads in the current list of scenes registered in the custom TextScene buildsettings.
public static ReadScenes ( ) : List
return List
Esempio n. 1
0
    public TextSceneBuilder(string buildPath, BuildTarget buildTarget, List <string> sceneList)
    {
        if (sceneList == null)
        {
            sceneList = TextScene.ReadScenes();
        }

        if (sceneList.Count == 0)
        {
            EditorUtility.DisplayDialog("No scenes", "No scenes have been added to the build settings. Please add some, and try to build again.", "OK");
            return;
        }

        this.sceneQueue  = new Queue <string>(sceneList);
        this.sceneToLoad = TextSceneMonitor.Instance.GetCurrentScene();
        this.buildPath   = buildPath;
        this.buildTarget = buildTarget;

        if (EditorApplication.SaveCurrentSceneIfUserWantsTo())
        {
            TextSceneMonitor.Instance.SaveIfTempIsNewer();
        }
        else
        {
            Debug.Log("Cancelled build");
            return;
        }

        BuildNext();
    }
Esempio n. 2
0
    void LoadSettings()
    {
        scenes = TextScene.ReadScenes();

        loadedBuildSettingsTime = TextScene.BuildSettingsDate();
    }