Exemple #1
0
        public void Disconnect()
        {
            _logger.Debug($"{LogClientId}| Disconnecting from Server");

            _connectionMonitorTimer.Stop();

            _requestStop     = true;
            IsDataConnected  = false;
            IsAudioConnected = false;

            DcsPlayerRadioInfo.LastUpdate = 0;
            Clear();

            SrsDataClient?.RequestStop();
            _clientSyncThread?.Join();
            _clientSyncThread = null;

            SrsAudioClient?.RequestStop();
            _udpListenerThread?.Join();
            _udpListenerThread = null;

            _udpPingThread?.Join();
            _udpPingThread = null;

            DcsPlayerRadioInfo.Reset();
            PlayerCoalitionLocationMetadata.Reset();
        }
        public void Disconnect()
        {
            _logger.Debug($"{LogClientId}| Disconnecting from Server");

            IsDataConnected  = false;
            IsAudioConnected = false;

            SrsDataClient.DisconnectExternalAwacsMode();
            SrsDataClient.Disconnect();
            SrsAudioClient?.RequestStop();

            DcsPlayerRadioInfo.Reset();
            PlayerCoalitionLocationMetadata.Reset();
        }