private void OnClientConnected(SocketerClient client, int sourceId, string hostAddress) { Debug.Log("Client connected to " + hostAddress); SocketEndpoint socketEndpoint = new SocketEndpoint(client, timeoutInterval, hostAddress, sourceId); clientConnection = socketEndpoint; socketEndpoint.QueueIncomingMessages(inputMessageQueue); newConnections.Enqueue(socketEndpoint); }
private void OnClientConnected(SocketerClient client, MessageEvent e) { Debug.Log("Client connected to " + e.SourceHost); SocketEndpoint socketEndpoint = new SocketEndpoint(client, timeoutInterval, e.SourceHost, e.SourceId); clientConnection = socketEndpoint; socketEndpoint.QueueIncomingMessages(inputMessageQueue); newConnections.Enqueue(socketEndpoint); }
private void OnServerConnected(SocketerClient client, int sourceId, string clientAddress) { Debug.Log("Server connected to " + clientAddress); SocketEndpoint socketEndpoint = new SocketEndpoint(client, timeoutInterval, clientAddress, sourceId); serverConnections[sourceId] = socketEndpoint; socketEndpoint.QueueIncomingMessages(inputMessageQueue); newConnections.Enqueue(socketEndpoint); }