public void Load(string file) { if (!IsLoaded) { Generators.Clear(); var listItems = JsonConvert.DeserializeObject <List <GeneratorJsonData> >(Resources.Load <TextAsset>(file).text); listItems.ForEach(item => Generators.Add(item.id, new GeneratorData(item, GeneratorType.Normal))); IsLoaded = true; } }
public void ClearGenerators() { Generators.Clear(); generatorList.Clear(); }
public void Clear() { Generators.Clear(); }