示例#1
0
 public NetData(int correlationid, NetProtocal.Respone cmd, byte[] data, int len)
 {
     m_correlationid = correlationid;
     m_serverRespone = cmd;
     m_data          = new byte[len];
     Array.Copy(data, m_data, len);
 }
示例#2
0
    /// <summary>
    /// 接收到一个消息
    /// </summary>
    /// <param name="ms"></param>
    public void OnReceivedMessage(object ms)
    {
        if (null == ms)
        {
            Debug.Log("ms===nullnullnullnullnullnullnullnull");
            return;
        }

        NetProtocal.Respone sid = (NetProtocal.Respone)ProtoNetSerialize.readId;
        Debug.Log("sid=========" + sid + GetTimeStamp());
        NetDataMgr.Instance.Mrgs[sid].data = ms;

        msgList.Add(NetDataMgr.Instance.Mrgs[sid]);
    }