public void Stop() { _taskScheduler.Remove(_pendingTask); _taskScheduler.Remove(_bannedPendingTask); _connectsFromIp.Clear(); _bannedTill.Clear(); }
public void Disconnect() { lock (_stateSync) { _connected = false; //stop ticking _taskScheduler.Remove(_socketTickTask); //_receiveTimer.Change(Timeout.Infinite, Timeout.Infinite); //Send(new DisconnectEvent()); _socket?.Close(); } }
public void Stop() { _taskScheduler.Remove(_clearTask); if (_closeTask != null) { _taskScheduler.Remove(_closeTask); } _rooms.Clear(); _groupToRoom.Clear(); lock (_roomQueueSync) { _roomsQueue.Clear(); } _roomToGroupId.Clear(); }
public void StopListening() { _isStopping = true; TaskScheduler.Remove(_socketTickTask); TaskScheduler.Dispose(); _reliableSocket.Close(); _protectionManager.Stop(); }
private void OnPingResponse(MessageBase message) { var response = message as PingResponse; //drop reset task _taskScheduler.Remove(_resetPingTask); if (response != null && response.Success && _pingRequestSentOn != null) { _rtt = (int)((DateTime.UtcNow - _pingRequestSentOn.Value).TotalMilliseconds); } else { _rtt = int.MaxValue; } if (response != null && !response.Success) { _logger?.Error($"OnPingResponse error: {response.Message}"); } _isPinging = false; }
public void Stop() { _queue.Clear(); _confirmationManager.Stop(); _taskScheduler.Remove(_getPlayersForForSyncTask); }
public void Stop() { _taskScheduler.Remove(_clearTask); }
public void Stop() { _taskScheduler.Remove(_actualizeTask); }
public void Stop() { _taskScheduler.Remove(_tickTask); }
public void Stop() { _taskScheduler.Remove(_getServerInfoTask); }
public void Stop() { _taskScheduler.Remove(_mainTask); }