public void Connect(ITCPSocket socket) { var client = new Client(socket, idCounter); socketToClientMap.Add(socket, client); idCounter++; }
public void Connect() { var url = isLocal ? localURL : remoteURL; connection = new TCPSocket(url); connection.OnMessageReceive += ReciveMessage; connection.Connect(); }
public Client(ITCPSocket socket, int id) { Socket = socket; Id = id; }
public override void MyOnDestroy() { connection = null; }