Exemplo n.º 1
0
        public MainForm(string[] args, GameManager gameManager)
        {
            if (ApplicationUtil.OnlyOneInstance())
            {
                this.Close();
                return;
            }

            this.gameManager  = gameManager;
            MainForm.Instance = this;

            InitializeComponent();

            this.SetupBaseForm(this.panel_formContent);

            // control that shows over the entire application while the game is running
            overlay         = new GameRunningOverlay();
            overlay.OnStop += Overlay_OnStop;

            this.titleBarControl.Text = $"SplitScreenMe RC{Globals.Version}";

            controls = new Dictionary <string, GameControl>();

            // Selects the list of games, so the buttons look equal
            list_games.Select();
            list_games.AutoScroll = false;

            // check for arguments
            //SplitScreenEngineUtil.HandleArguments(args);

            // update register if needed
            //SplitScreenEngineUtil.HandleRegisterUpdates();
        }