コード例 #1
0
ファイル: GameLogicNetSwap.cs プロジェクト: lswzzz/BombMan
    IEnumerator SendStartInfo()
    {
        yield return(null);

        SendData data = new SendData();

        data.cmd = SendDataType.StartInfo;
        data.fd  = GameGlobalData.fd;
        udpSocket.Send(data);
    }
コード例 #2
0
 public void Send(byte[] buf, int off, int len)
 {
     // Debug.Print($"OurTransport::Send Data Length: {len}");
     // Debug.Print(BitConverter.ToString(buf, off, len));
     byte[] newBuf = new byte[len];
     Array.Copy(buf, off, newBuf, 0, newBuf.Length);
     buf = newBuf;
     UDPChannel.Send(buf, UDPChannel, _ep);
 }