Пример #1
0
        private void GameLoaded(string gameName, EventArgs e)
        {
            if (_game != null)
            {
                EventArgs ev = new EventArgs();
                GameClosed(_game.Name, ev);
            }
            if (_game == null)
            {
                _game = _plugins[gameName];

                Invoke(new Action(() => { Status.Text = _game.DisplayName; }));
                Invoke(new Action(() => { labelStatus.Text = _game.DisplayName; }));

                if (_game.ConnectionType == ConnectionType.BOTH || _game.ConnectionType == ConnectionType.MANUAL)
                {
                    Invoke(new Action(() => { buttonStop.Enabled = true; }));
                }
                else
                {
                    Invoke(new Action(() => { buttonStop.Enabled = false; }));
                }

                if (imageListPlugins.Images.ContainsKey(_game.Name))
                {
                    Invoke(new Action(() => { pictureConnected.Image = imageListPlugins.Images[_game.Name]; }));
                }
                _telemetryData.Reset();
                _telemetryData.Game        = gameName;
                _telemetryData.Description = _plugins[gameName].DisplayName;
                _gameReaderThread          = new Thread(() => GameReaderThread());
                _gameReaderThread.Start();
            }
        }
Пример #2
0
 public void Reset()
 {
     _telemetryData.Reset();
     _timingData.Reset();
 }