示例#1
0
    public MFQTcpClient(RemoteManger r)
    {
        retryCount   = 0;
        remoteManger = r;
        tcpClient    = new TcpClient();

        tcpClient.SendBufferSize    = BUFFERLENGTH;
        tcpClient.ReceiveBufferSize = BUFFERLENGTH;

        StartConnection();
    }
示例#2
0
    public MFQTcpClient(RemoteManger r)
    {
        remoteManger = r;
        tcpClient    = new TcpClient();

        tcpClient.SendBufferSize    = BUFFERLENGTH;
        tcpClient.ReceiveBufferSize = BUFFERLENGTH;

        try
        {
            tcpClient.BeginConnect(SERVERNAME, PORT, connectCallback, null);
        }
        catch (Exception e)
        {
            Debug.LogError(e.Message);
            GlobalDebug.Addline(e.Message);
        }
    }