public static HashSet <string> GetPreviouslyPlayedServers() { HashSet <string> hashSet = new HashSet <string>(); string mpClientLocalPath = SaveSlotUtils.GetMpClientLocalPath(); if (!Directory.Exists(mpClientLocalPath)) { Directory.CreateDirectory(mpClientLocalPath); } foreach (string path in Directory.GetFiles(mpClientLocalPath)) { hashSet.Add(Path.GetFileName(path)); } return(hashSet); }
public static HashSet <string> GetPreviouslyPlayedServers() { HashSet <string> hashSet = new HashSet <string>(); string mpClientLocalPath = SaveSlotUtils.GetMpClientLocalPath(); if (!Directory.Exists(mpClientLocalPath)) { Directory.CreateDirectory(mpClientLocalPath); } string[] files = Directory.GetFiles(mpClientLocalPath); for (int i = 0; i < files.Length; i++) { string path = files[i]; hashSet.Add(Path.GetFileName(path)); } return(hashSet); }