public override void initFiles() { base.initFiles(); Folder storageFolder = this.comp.files.root.searchForFolder("IRC"); if (storageFolder == null) { storageFolder = new Folder("IRC"); this.comp.files.root.folders.Add(storageFolder); } this.System = new IRCSystem(storageFolder); for (int index = 0; index < this.StartingMessages.Count; ++index) { this.System.AddLog(this.StartingMessages[index].Key, this.StartingMessages[index].Value, (string)null); } string str = this.name + "\nRequireAuth: " + (this.RequiresLogin ? "true" : "false") + "\n" + Utils.convertColorToParseableString(this.ThemeColor) + "\n"; foreach (KeyValuePair <string, Color> userColor in this.UserColors) { str = str + userColor.Key + "#%#" + Utils.convertColorToParseableString(userColor.Value) + "\n"; } storageFolder.files.Add(new FileEntry(str.Trim(), "users.cfg")); Folder sourceFolder = storageFolder.searchForFolder("runtime"); if (sourceFolder == null) { sourceFolder = new Folder("runtime"); storageFolder.folders.Add(sourceFolder); } this.DelayedActions = new DelayableActionSystem(sourceFolder, (object)this.os); }
public override void loadInit() { base.loadInit(); Folder storageFolder = this.comp.files.root.searchForFolder("IRC"); this.System = new IRCSystem(storageFolder); this.DelayedActions = new DelayableActionSystem(storageFolder.searchForFolder("runtime"), (object)this.os); this.ReloadUserColors(); }