using Discord.Interactions; using Discord; using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Xml.Serialization; using Orpticon.Wrappers; using SMSModLogOutputAnalyzer.Modules; namespace SMSModLogOutputAnalyzer.Data { public partial class Config { public static ITextChannel NotesLogChannel { get => (ITextChannel)Program.Client.GetChannel(Instance.notesLogChannel); set => Instance.notesLogChannel = value.Id; } [XmlAttribute] public ulong notesLogChannel { get; set; } public static void Load() { Instance = SerializerXML.DeserializeFromFileOrDefault("Config.xml"); } public static void Save() { try { SerializerXML.SerializeToFile(Instance, "Config.xml"); } catch (Exception e) { Console.WriteLine(e); } } public static Config Instance { get; set; } } }