public static void CompileShapes() { var shapes = DataLoader.YamlLoad <List <SpellShape> >(Directories.SHAPES_YAML); if (shapes == null) { return; } foreach (var shape in shapes) { shape.Flags = shape.Flags.Distinct().ToList(); } var distinctShapes = GetDistinctShapes(shapes).OrderBy(s => s.Id).ToList(); if (!DataLoader.YamlSave(Directories.SHAPES_YAML, distinctShapes)) { return; } var compiledData = new Dictionary <uint, SpellShape>(); foreach (var shape in distinctShapes) { compiledData[shape.Id] = shape; } if (!DataLoader.ProtoSave(Directories.SHAPES, compiledData)) { return; } Logger.ZekkenMessage("Compiled {0} spell shapes.", distinctShapes.Count); }
public static void MenderDataToYaml() { DataLoader.YamlSave(Directories.MENDERS_YAML, Database.Menders); }