public static string [] GetLevelsList() { string [] levelsFullPathes = STFileMng.GetFilesList(); string [] levelsArray = new string [levelsFullPathes.Length]; for (int i = 0; i < levelsFullPathes.Length; i++) { levelsArray[i] = Path.GetFileNameWithoutExtension(levelsFullPathes[i]); } return(levelsArray); }
public static void LoadLevel(string fileName) { sLevel = new STSerializedLevel(); //STSerializedLevel data; if (STFileMng.LoadData(fileName, sLevelSerializer, out sLevel)) { clearLevel(); _instance.NodesNet.LoadNet(sLevel.net); _instance.RootNode.LoadNodes(sLevel.rootNode); } else { } }
public static void DeleteLevel(string fileName) { STFileMng.DeleteData(fileName); }
public static bool SaveLevel(string fileName, bool shouldRewrite) { sLevel = STLevel.Instance().GetSerializedLevel(); return(STFileMng.SaveData(sLevel, sLevelSerializer, fileName, shouldRewrite)); }