public void SaveScore(string playerName) { ScoresTable.Add(new Player(playerName, Score)); var sr = new System.IO.StreamWriter(ScoresTablePath); ScoresTable.ForEach(player => sr.WriteLine(player)); sr.Close(); }
//Otworzenie Tabeli wyników private void scoreTableOpen(object sender, EventArgs e) { ScoresTable scores = new ScoresTable(); scores.ShowDialog(); }