コード例 #1
0
        public ServerInstance()
        {
            m_launchedTime = DateTime.MinValue;

            m_serverThread   = null;
            m_serverInstance = this;

            string gameExePath = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "HELLION_Dedicated.exe");

            if (System.IO.File.Exists(gameExePath))
            {
                m_assembly      = Assembly.LoadFile(gameExePath);
                m_serverWrapper = new ServerWrapper(m_assembly);
            }
            else
            {
                Console.WriteLine($"HELLION_Dedicated.exe not detected at {gameExePath}.\r\n Press any key to close.");
            }

            //m_gameServerProperties = new GameServerProperties();
            //m_gameServerProperties.Load();

            m_gameServerIni = new GameServerIni();
            m_gameServerIni.Load();
        }
コード例 #2
0
        public Form1()
        {
            InitializeComponent();

            m_config         = new Config();
            m_config.Visible = false;

            m_gameServerIni = new GameServerIni();
            m_gameServerIni.LoadDefaults();
            m_gameServerIni.ServerPath = Properties.Settings.Default.HellionDedicatedPath;

            ServerConfig_PropertyGrid.ToolbarVisible = false;
            ServerConfig_PropertyGrid.SelectedObject = m_gameServerIni;

            if (Properties.Settings.Default.FirstRun && Properties.Settings.Default.HellionDedicatedPath == String.Empty)
            {
                m_config.ShowDialog();

                Properties.Settings.Default.FirstRun = false;
                //Properties.Settings.Default.Save();
            }
        }