Esempio n. 1
0
    // Use this for initialization
    void Start()
    {
        singalFileStream = new FileStream("singal.txt", FileMode.Create, FileAccess.Write);
        string ip = useEc2 ? ec2_ip : local_ip;

        tcpNetComp = new NetComp(ip, tcpPort);
        kcpNetComp = new KcpNetComp(ip, kcpPort, 123);
        udpNetComp = new UdpNetComp(ip, udpPort);
        tcpNetComp.Start();
        udpNetComp.Start();
        kcpNetComp.Start();
        StartCoroutine(SendCo());
        StartCoroutine(SampleCo());
    }
Esempio n. 2
0
 // Use this for initialization
 void Start()
 {
     kcpNetComp = new KcpNetComp("127.0.0.1", 8080, 123);
     kcpNetComp.Start();
     StartCoroutine(SendCo());
 }