Exemple #1
0
    public SaveJson.SaveGame GetCurrentSave()
    {
        if ((saveIndex < 0) || (saveIndex > saveJson.saves.Length))
        {
            SaveJson.SaveGame save = new SaveJson.SaveGame();
            return(save);
        }


        return(saveJson.saves[saveIndex]);
    }
Exemple #2
0
    public void NewGame()
    {
        List <SaveJson.SaveGame> saves = new List <SaveJson.SaveGame>(gameManager.saveJson.saves);

        SaveJson.SaveGame save = new SaveJson.SaveGame();
        save.percentComplete = 0;
        save.respawPoint     = Commandments.Shrines.NEXUS;
        saves.Add(save);
        gameManager.saveJson.saves = saves.ToArray();
        saveIndex = gameManager.saveJson.saves.Length - 1;
        PrepareCurrentSave();
    }