private async void Form4_Load(object sender, EventArgs e) { TUpdate("Loading"); Tools.Enabled = false; Scriptbox.Enabled = false; Scriptlist.Enabled = false; try { foreach (string path in Directory.GetFiles("./Scripts")) { this.Scriptlist.Items.Add(Path.GetFileName(path)); } } catch (Exception) { Directory.CreateDirectory("./Scripts"); foreach (string path2 in Directory.GetFiles("./Scripts")) { this.Scriptlist.Items.Add(Path.GetFileName(path2)); } } try { a = Convert.ToBoolean(new Settings().SettingsConfig.Read("ScriptsFolder", "Configuration")); if (a == false) { this.Size = new Size(500, 300); } else { this.Size = new Size(658, 300); } } catch (Exception) { } toolStripMenuItem3.Text = "Scripts Folder = " + a.ToString(); if (File.Exists("Settings.AJax")) { string tm = new Settings().SettingsConfig.Read("Topmost", "Configuration"); TopMost = Convert.ToBoolean(tm); toolStripMenuItem4.Text = "Topmost = " + TopMost.ToString(); string wr = new Settings().SettingsConfig.Read("WordWrap", "Configuration"); Scriptbox.WordWrap = Convert.ToBoolean(wr); toolStripMenuItem2.Text = "WordWrap = " + Scriptbox.WordWrap.ToString(); Scriptbox.Text = File.ReadAllText(@"bin\\AJax.lua"); } else { toolStripMenuItem4.Text = "Topmost = True"; toolStripMenuItem2.Text = "WordWrap = False"; } if (File.Exists(@"bin\\AJax.lua")) { await Task.Delay(500); Scriptbox.Text = File.ReadAllText(@"bin\\AJax.lua"); } Synapse = SxLib.InitializeOffscreen(directory); Synapse.LoadEvent += Loader; Synapse.AttachEvent += Attacher; Synapse.Load(); }