コード例 #1
0
    /// <summary>
    /// Saving all XMLS
    ///
    /// if 'callEscapeKey' will call : Program.InputMain.EscapeKey();
    /// should be called always unless is a quicksave
    /// </summary>
    public static void SaveNow(bool callEscapeKey)
    {
        PlayerPrefs.Save();

        Directory.CreateDirectory(savePath);
        XMLSerie.SaveGame(savePath);

        //print("Resave Spawner and Buildings");
        Program.gameScene.controllerMain.TerraSpawnController.ReSaveData();
        BuildingPot.SaveLoad.Save();
        PersonPot.SaveLoad.Save();
        CamControl.CAMRTS.InputRts.SaveLastCamPos();

        savePath = "";

        if (callEscapeKey)
        {
            //so goes back to show the game
            Program.InputMain.EscapeKey();
        }
    }