Ejemplo n.º 1
0
        private void DS2Backup_Shown(object sender, EventArgs e)
        {
            backingUp = false;
            gameSave = new GameSave();
            backupSave = new BackupSave();

            GameSaveTextBox.Text = gameSave.Path;
            BackupSaveTextBox.Text = backupSave.Path;
        }
Ejemplo n.º 2
0
        public void backup(GameSave gameSave)
        {
            if (!System.IO.Directory.Exists(this.path + @"\Backups"))
            {
                System.IO.Directory.CreateDirectory(this.path + @"\Backups");
            }

            if(numBackupSaves == MAX_BACKUP_SAVES)
            {
                numBackupSaves = 1;
                latestSaveIndex = numBackupSaves;
            }
            else
            {
                latestSaveIndex = numBackupSaves++;
            }

            FileSysManip.copyFile("DS2SOFS0000.sl2", gameSave.Path, this.Path + @"\Backups" + @"\" + numBackupSaves);
        }