public static void SaveAsBMFont(string filename, File.Font f) { BMFontWriter writer = new BMFontWriter(); writer.sw = new StreamWriter(filename); writer.WriteInfoTag(f); writer.WriteCommon(f); writer.WritePage(filename, f); writer.WriteChars(f); writer.sw.Flush(); writer.sw.Close(); }
public static void SaveAsBMFont(string filename, File.Font f) { BMFontWriter writer = new BMFontWriter(); writer.sw = new StreamWriter(filename); writer.WriteInfoTag(f); writer.WriteCommon(f); writer.WritePage(filename, f); writer.WriteChars(f); writer.sw.Flush(); writer.sw.Close(); }
static void DoFileWrite(string path, File.Font f) { CodeTask.RunOneThing(path, f); if (Context.saveAllPngs) { string filename = Path.ChangeExtension(Path.Combine(path, f.Name), ".fnt"); // we just have one BMFontWriter.SaveAsBMFont(filename, f); // f.Frame.Image.Save(filename); } }