private void MainForm_Shown(object sender, EventArgs e) { GlobalUpdateCheck.Instance.BeginCheckedNotification(m_UpdateCheckNotification); if (0 < GlobalConfig.Instance.Settings.UpdateCheck) { this.menuAutoUpdateCheck.Checked = true; StartUpdateCheck(); } else if (0 == GlobalConfig.Instance.Settings.UpdateCheck) { this.stripEnableUpdateCheck.Visible = true; } // init AfxGoldSrc: m_AfxGoldSrc = new Afx.AfxGoldSrc(this); // start up public remoting system (if requested): if (Globals.EnableHlaeRemote) { m_HlaeRemoting = new hlae.remoting.HlaeRemoting(this); } // start-up CS:GO if requested (i.e. by command line) if (Globals.AutoStartCsgo) { LaunchCsgo.Launch(GlobalConfig.Instance.Settings.LauncherCsgo); } // start-up AfxHookGoldSrc if requested (i.e. by command line) if (Globals.AutoStartAfxHookGoldSrc) { CfgLauncher cfg = new CfgLauncher(); cfg.CopyFrom(GlobalConfig.Instance.Settings.Launcher); Afx.AfxGoldSrc.StartSettings settings = cfg.MakeStartSettings(); m_AfxGoldSrc.Start(settings); } // start-up CustomLoader if requested (i.e. by command line) if (Globals.AutoStartCustomLoader) { bool bOk = AfxCppCli.AfxHook.LauchAndHook(GlobalConfig.Instance.Settings.CustomLoader.ProgramPath, GlobalConfig.Instance.Settings.CustomLoader.CmdLine, GlobalConfig.Instance.Settings.CustomLoader.HookDllPath); if (!bOk) { MessageBox.Show("CustomLoader failed", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error); } } }
private void MainForm_Shown(object sender, EventArgs e) { GlobalUpdateCheck.Instance.BeginCheckedNotification(m_UpdateCheckNotification); if (0 < GlobalConfig.Instance.Settings.UpdateCheck) { this.menuAutoUpdateCheck.Checked = true; StartUpdateCheck(); } else if (0 == GlobalConfig.Instance.Settings.UpdateCheck) { this.stripEnableUpdateCheck.Visible = true; } // start up public remoting system (if requested): if (Globals.EnableHlaeRemote) { m_HlaeRemoting = new hlae.remoting.HlaeRemoting(this); } }
private void MainForm_Shown(object sender, EventArgs e) { GlobalUpdateCheck.Instance.BeginCheckedNotification(m_UpdateCheckNotification); if (0 < GlobalConfig.Instance.Settings.UpdateCheck) { this.menuAutoUpdateCheck.Checked = true; StartUpdateCheck(); } else if (0 == GlobalConfig.Instance.Settings.UpdateCheck) { this.stripEnableUpdateCheck.Visible = true; } // init AfxGoldSrc: m_AfxGoldSrc = new Afx.AfxGoldSrc(this); // start up public remoting system (if requested): if (Globals.EnableHlaeRemote) { m_HlaeRemoting = new hlae.remoting.HlaeRemoting(this); } // start-up AfxHookGoldSrc if requested (i.e. by command line) if (Globals.AutoStartAfxHookGoldSrc) { CfgLauncher cfg = new CfgLauncher(); cfg.CopyFrom(GlobalConfig.Instance.Settings.Launcher); Afx.AfxGoldSrc.StartSettings settings = cfg.MakeStartSettings(); m_AfxGoldSrc.Start(settings); } // start-up CustomLoader if requested (i.e. by command line) if (Globals.AutoStartCustomLoader) { bool bOk = AfxCppCli.AfxHook.LauchAndHook(GlobalConfig.Instance.Settings.CustomLoader.ProgramPath, GlobalConfig.Instance.Settings.CustomLoader.CmdLine, GlobalConfig.Instance.Settings.CustomLoader.HookDllPath); if (!bOk) MessageBox.Show("CustomLoader failed", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error); } }