| | |
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | #B3 07 语音聊天 #tagCGVoiceChat
|
| | |
|
| | | class tagCGVoiceChat(Structure):
|
| | | Head = tagHead()
|
| | | ChannelType = 0 #(BYTE ChannelType)// 1 世界 2 仙盟 3 私聊(好友) 4 队伍 -------查看封包tagCMVoiceChat 5 区域 |
| | | TargetNameLen = 0 #(BYTE TargetNameLen)
|
| | | TargetName = "" #(String TargetName)//size = TargetNameLen
|
| | | TargetID = 0 #(DWORD TargetID)// 默认发玩家ID,没有ID才发名称
|
| | | Len = 0 #(WORD Len)
|
| | | Content = list() #(vector<BYTE> Content)//size = Len
|
| | | data = None
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Head.Cmd = 0xB3
|
| | | self.Head.SubCmd = 0x07
|
| | | return
|
| | |
|
| | | def ReadData(self, _lpData, _pos=0, _Len=0):
|
| | | self.Clear()
|
| | | _pos = self.Head.ReadData(_lpData, _pos)
|
| | | self.ChannelType,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | self.TargetNameLen,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | self.TargetName,_pos = CommFunc.ReadString(_lpData, _pos,self.TargetNameLen)
|
| | | self.TargetID,_pos = CommFunc.ReadDWORD(_lpData, _pos)
|
| | | self.Len,_pos = CommFunc.ReadWORD(_lpData, _pos)
|
| | | for i in range(self.Len):
|
| | | value,_pos=CommFunc.ReadBYTE(_lpData,_pos)
|
| | | self.Content.append(value)
|
| | | return _pos
|
| | |
|
| | | def Clear(self):
|
| | | self.Head = tagHead()
|
| | | self.Head.Clear()
|
| | | self.Head.Cmd = 0xB3
|
| | | self.Head.SubCmd = 0x07
|
| | | self.ChannelType = 0
|
| | | self.TargetNameLen = 0
|
| | | self.TargetName = ""
|
| | | self.TargetID = 0
|
| | | self.Len = 0
|
| | | self.Content = list()
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | length = 0
|
| | | length += self.Head.GetLength()
|
| | | length += 1
|
| | | length += 1
|
| | | length += len(self.TargetName)
|
| | | length += 4
|
| | | length += 2
|
| | | length += 1 * self.Len
|
| | |
|
| | | return length
|
| | |
|
| | | def GetBuffer(self):
|
| | | data = ''
|
| | | data = CommFunc.WriteString(data, self.Head.GetLength(), self.Head.GetBuffer())
|
| | | data = CommFunc.WriteBYTE(data, self.ChannelType)
|
| | | data = CommFunc.WriteBYTE(data, self.TargetNameLen)
|
| | | data = CommFunc.WriteString(data, self.TargetNameLen, self.TargetName)
|
| | | data = CommFunc.WriteDWORD(data, self.TargetID)
|
| | | data = CommFunc.WriteWORD(data, self.Len)
|
| | | for i in range(self.Len):
|
| | | data = CommFunc.WriteBYTE(data, self.Content[i])
|
| | | return data
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''
|
| | | Head:%s,
|
| | | ChannelType:%d,
|
| | | TargetNameLen:%d,
|
| | | TargetName:%s,
|
| | | TargetID:%d,
|
| | | Len:%d,
|
| | | Content:%s
|
| | | '''\
|
| | | %(
|
| | | self.Head.OutputString(),
|
| | | self.ChannelType,
|
| | | self.TargetNameLen,
|
| | | self.TargetName,
|
| | | self.TargetID,
|
| | | self.Len,
|
| | | "..."
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCGVoiceChat=tagCGVoiceChat()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCGVoiceChat.Head.Cmd,m_NAtagCGVoiceChat.Head.SubCmd))] = m_NAtagCGVoiceChat
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | #B3 03 是否允许加入好友的回应#tagCGJoinFriendAnswer
|
| | |
|
| | | class tagCGJoinFriendAnswer(Structure):
|
| | |
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # A1 30 查看榜单 #tagCMViewBillboard
|
| | |
|
| | | class tagCMViewBillboard(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("Type", c_ubyte), #榜单类型
|
| | | ("GroupValue1", c_int), #分组值1
|
| | | ("GroupValue2", c_int), #分组值2,与分组值1组合归为同组榜单数据
|
| | | ("StartIndex", c_ushort), #查看的起始名次索引, 默认0
|
| | | ("ViewCnt", c_ubyte), #查看条数,默认20,单次最大不超过100
|
| | | ("ViewID", c_int), #附带查看指定ID所在名次前后数据,如玩家ID、家族ID等
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xA1
|
| | | self.SubCmd = 0x30
|
| | | return
|
| | |
|
| | | def ReadData(self, stringData, _pos=0, _len=0):
|
| | | self.Clear()
|
| | | memmove(addressof(self), stringData[_pos:], self.GetLength())
|
| | | return _pos + self.GetLength()
|
| | |
|
| | | def Clear(self):
|
| | | self.Cmd = 0xA1
|
| | | self.SubCmd = 0x30
|
| | | self.Type = 0
|
| | | self.GroupValue1 = 0
|
| | | self.GroupValue2 = 0
|
| | | self.StartIndex = 0
|
| | | self.ViewCnt = 0
|
| | | self.ViewID = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagCMViewBillboard)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// A1 30 查看榜单 //tagCMViewBillboard:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | Type:%d,
|
| | | GroupValue1:%d,
|
| | | GroupValue2:%d,
|
| | | StartIndex:%d,
|
| | | ViewCnt:%d,
|
| | | ViewID:%d
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.Type,
|
| | | self.GroupValue1,
|
| | | self.GroupValue2,
|
| | | self.StartIndex,
|
| | | self.ViewCnt,
|
| | | self.ViewID
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMViewBillboard=tagCMViewBillboard()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMViewBillboard.Cmd,m_NAtagCMViewBillboard.SubCmd))] = m_NAtagCMViewBillboard
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # A2 19 游戏建议收集 #tagCMAdviceSubmit
|
| | |
|
| | | class tagCMAdviceSubmit(Structure):
|
| | |
| | |
|
| | | m_NAtagCMOpenLongWarehouse=tagCMOpenLongWarehouse()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMOpenLongWarehouse.Cmd,m_NAtagCMOpenLongWarehouse.SubCmd))] = m_NAtagCMOpenLongWarehouse
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # A2 17 喇叭聊天 #tagCMPYSpeaker
|
| | |
|
| | | class tagCMPYSpeaker(Structure):
|
| | | Head = tagHead()
|
| | | SpeakerType = 0 #(BYTE SpeakerType)//1-本服;2-跨服
|
| | | IsUseGold = 0 #(BYTE IsUseGold)//是否使用钻石
|
| | | ItemIndex = 0 #(BYTE ItemIndex)//使用物品说话时, 物品Index
|
| | | TextLen = 0 #(WORD TextLen)//字符长度
|
| | | Text = "" #(String Text)//size = TextLen
|
| | | data = None
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Head.Cmd = 0xA2
|
| | | self.Head.SubCmd = 0x17
|
| | | return
|
| | |
|
| | | def ReadData(self, _lpData, _pos=0, _Len=0):
|
| | | self.Clear()
|
| | | _pos = self.Head.ReadData(_lpData, _pos)
|
| | | self.SpeakerType,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | self.IsUseGold,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | self.ItemIndex,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | self.TextLen,_pos = CommFunc.ReadWORD(_lpData, _pos)
|
| | | self.Text,_pos = CommFunc.ReadString(_lpData, _pos,self.TextLen)
|
| | | return _pos
|
| | |
|
| | | def Clear(self):
|
| | | self.Head = tagHead()
|
| | | self.Head.Clear()
|
| | | self.Head.Cmd = 0xA2
|
| | | self.Head.SubCmd = 0x17
|
| | | self.SpeakerType = 0
|
| | | self.IsUseGold = 0
|
| | | self.ItemIndex = 0
|
| | | self.TextLen = 0
|
| | | self.Text = ""
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | length = 0
|
| | | length += self.Head.GetLength()
|
| | | length += 1
|
| | | length += 1
|
| | | length += 1
|
| | | length += 2
|
| | | length += len(self.Text)
|
| | |
|
| | | return length
|
| | |
|
| | | def GetBuffer(self):
|
| | | data = ''
|
| | | data = CommFunc.WriteString(data, self.Head.GetLength(), self.Head.GetBuffer())
|
| | | data = CommFunc.WriteBYTE(data, self.SpeakerType)
|
| | | data = CommFunc.WriteBYTE(data, self.IsUseGold)
|
| | | data = CommFunc.WriteBYTE(data, self.ItemIndex)
|
| | | data = CommFunc.WriteWORD(data, self.TextLen)
|
| | | data = CommFunc.WriteString(data, self.TextLen, self.Text)
|
| | | return data
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''
|
| | | Head:%s,
|
| | | SpeakerType:%d,
|
| | | IsUseGold:%d,
|
| | | ItemIndex:%d,
|
| | | TextLen:%d,
|
| | | Text:%s
|
| | | '''\
|
| | | %(
|
| | | self.Head.OutputString(),
|
| | | self.SpeakerType,
|
| | | self.IsUseGold,
|
| | | self.ItemIndex,
|
| | | self.TextLen,
|
| | | self.Text
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMPYSpeaker=tagCMPYSpeaker()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMPYSpeaker.Head.Cmd,m_NAtagCMPYSpeaker.Head.SubCmd))] = m_NAtagCMPYSpeaker
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # A2 16 自定义玩家聊天 #tagCMPyTalk
|
| | |
|
| | | class tagCMPyTalk(Structure):
|
| | | Head = tagHead()
|
| | | TalkType = 0 #(BYTE TalkType)// 自定义聊天类型
|
| | | Len = 0 #(WORD Len)
|
| | | Content = "" #(String Content)//size = Len
|
| | | data = None
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Head.Cmd = 0xA2
|
| | | self.Head.SubCmd = 0x16
|
| | | return
|
| | |
|
| | | def ReadData(self, _lpData, _pos=0, _Len=0):
|
| | | self.Clear()
|
| | | _pos = self.Head.ReadData(_lpData, _pos)
|
| | | self.TalkType,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | self.Len,_pos = CommFunc.ReadWORD(_lpData, _pos)
|
| | | self.Content,_pos = CommFunc.ReadString(_lpData, _pos,self.Len)
|
| | | return _pos
|
| | |
|
| | | def Clear(self):
|
| | | self.Head = tagHead()
|
| | | self.Head.Clear()
|
| | | self.Head.Cmd = 0xA2
|
| | | self.Head.SubCmd = 0x16
|
| | | self.TalkType = 0
|
| | | self.Len = 0
|
| | | self.Content = ""
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | length = 0
|
| | | length += self.Head.GetLength()
|
| | | length += 1
|
| | | length += 2
|
| | | length += len(self.Content)
|
| | |
|
| | | return length
|
| | |
|
| | | def GetBuffer(self):
|
| | | data = ''
|
| | | data = CommFunc.WriteString(data, self.Head.GetLength(), self.Head.GetBuffer())
|
| | | data = CommFunc.WriteBYTE(data, self.TalkType)
|
| | | data = CommFunc.WriteWORD(data, self.Len)
|
| | | data = CommFunc.WriteString(data, self.Len, self.Content)
|
| | | return data
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''
|
| | | Head:%s,
|
| | | TalkType:%d,
|
| | | Len:%d,
|
| | | Content:%s
|
| | | '''\
|
| | | %(
|
| | | self.Head.OutputString(),
|
| | | self.TalkType,
|
| | | self.Len,
|
| | | self.Content
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMPyTalk=tagCMPyTalk()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMPyTalk.Head.Cmd,m_NAtagCMPyTalk.Head.SubCmd))] = m_NAtagCMPyTalk
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | |
| | |
|
| | | m_NAtagCMClientTaskCount=tagCMClientTaskCount()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMClientTaskCount.Cmd,m_NAtagCMClientTaskCount.SubCmd))] = m_NAtagCMClientTaskCount
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | #A2 26 语音聊天 #tagCMVoiceChat
|
| | |
|
| | | class tagCMVoiceChat(Structure):
|
| | | Head = tagHead()
|
| | | ChannelType = 0 #(BYTE ChannelType)// 5 区域 --- 查看封包tagCGVoiceChat 1 世界 2 仙盟 3 私聊(好友) 4 队伍
|
| | | TargetNameLen = 0 #(BYTE TargetNameLen)
|
| | | TargetName = "" #(String TargetName)//size = TargetNameLen
|
| | | TargetID = 0 #(DWORD TargetID)// 私聊默认发玩家ID,没有ID才发名称
|
| | | Len = 0 #(WORD Len)
|
| | | Content = list() #(vector<BYTE> Content)//size = Len
|
| | | data = None
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Head.Cmd = 0xA2
|
| | | self.Head.SubCmd = 0x26
|
| | | return
|
| | |
|
| | | def ReadData(self, _lpData, _pos=0, _Len=0):
|
| | | self.Clear()
|
| | | _pos = self.Head.ReadData(_lpData, _pos)
|
| | | self.ChannelType,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | self.TargetNameLen,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | self.TargetName,_pos = CommFunc.ReadString(_lpData, _pos,self.TargetNameLen)
|
| | | self.TargetID,_pos = CommFunc.ReadDWORD(_lpData, _pos)
|
| | | self.Len,_pos = CommFunc.ReadWORD(_lpData, _pos)
|
| | | for i in range(self.Len):
|
| | | value,_pos=CommFunc.ReadBYTE(_lpData,_pos)
|
| | | self.Content.append(value)
|
| | | return _pos
|
| | |
|
| | | def Clear(self):
|
| | | self.Head = tagHead()
|
| | | self.Head.Clear()
|
| | | self.Head.Cmd = 0xA2
|
| | | self.Head.SubCmd = 0x26
|
| | | self.ChannelType = 0
|
| | | self.TargetNameLen = 0
|
| | | self.TargetName = ""
|
| | | self.TargetID = 0
|
| | | self.Len = 0
|
| | | self.Content = list()
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | length = 0
|
| | | length += self.Head.GetLength()
|
| | | length += 1
|
| | | length += 1
|
| | | length += len(self.TargetName)
|
| | | length += 4
|
| | | length += 2
|
| | | length += 1 * self.Len
|
| | |
|
| | | return length
|
| | |
|
| | | def GetBuffer(self):
|
| | | data = ''
|
| | | data = CommFunc.WriteString(data, self.Head.GetLength(), self.Head.GetBuffer())
|
| | | data = CommFunc.WriteBYTE(data, self.ChannelType)
|
| | | data = CommFunc.WriteBYTE(data, self.TargetNameLen)
|
| | | data = CommFunc.WriteString(data, self.TargetNameLen, self.TargetName)
|
| | | data = CommFunc.WriteDWORD(data, self.TargetID)
|
| | | data = CommFunc.WriteWORD(data, self.Len)
|
| | | for i in range(self.Len):
|
| | | data = CommFunc.WriteBYTE(data, self.Content[i])
|
| | | return data
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''
|
| | | Head:%s,
|
| | | ChannelType:%d,
|
| | | TargetNameLen:%d,
|
| | | TargetName:%s,
|
| | | TargetID:%d,
|
| | | Len:%d,
|
| | | Content:%s
|
| | | '''\
|
| | | %(
|
| | | self.Head.OutputString(),
|
| | | self.ChannelType,
|
| | | self.TargetNameLen,
|
| | | self.TargetName,
|
| | | self.TargetID,
|
| | | self.Len,
|
| | | "..."
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMVoiceChat=tagCMVoiceChat()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMVoiceChat.Head.Cmd,m_NAtagCMVoiceChat.Head.SubCmd))] = m_NAtagCMVoiceChat
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | |
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # A5 37 请求邮件操作 #tagCMRequestMail
|
| | |
|
| | | class tagCMRequestMail(Structure):
|
| | | Head = tagHead()
|
| | | GUID = "" #(char GUID[36])//邮件GUID,可传空,默认针对个人邮件的批量处理,如批量领取、批量删除已领邮件等;全服邮件暂时限制只能单封邮件处理
|
| | | ReqType = 0 #(BYTE ReqType)//0-设置已读,1-领取邮件,2-删除邮件
|
| | | data = None
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Head.Cmd = 0xA5
|
| | | self.Head.SubCmd = 0x37
|
| | | return
|
| | |
|
| | | def ReadData(self, _lpData, _pos=0, _Len=0):
|
| | | self.Clear()
|
| | | _pos = self.Head.ReadData(_lpData, _pos)
|
| | | self.GUID,_pos = CommFunc.ReadString(_lpData, _pos,36)
|
| | | self.ReqType,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | return _pos
|
| | |
|
| | | def Clear(self):
|
| | | self.Head = tagHead()
|
| | | self.Head.Clear()
|
| | | self.Head.Cmd = 0xA5
|
| | | self.Head.SubCmd = 0x37
|
| | | self.GUID = ""
|
| | | self.ReqType = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | length = 0
|
| | | length += self.Head.GetLength()
|
| | | length += 36
|
| | | length += 1
|
| | |
|
| | | return length
|
| | |
|
| | | def GetBuffer(self):
|
| | | data = ''
|
| | | data = CommFunc.WriteString(data, self.Head.GetLength(), self.Head.GetBuffer())
|
| | | data = CommFunc.WriteString(data, 36, self.GUID)
|
| | | data = CommFunc.WriteBYTE(data, self.ReqType)
|
| | | return data
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''
|
| | | Head:%s,
|
| | | GUID:%s,
|
| | | ReqType:%d
|
| | | '''\
|
| | | %(
|
| | | self.Head.OutputString(),
|
| | | self.GUID,
|
| | | self.ReqType
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMRequestMail=tagCMRequestMail()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMRequestMail.Head.Cmd,m_NAtagCMRequestMail.Head.SubCmd))] = m_NAtagCMRequestMail
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # A5 68 请求寻宝 #tagCMRequestTreasure
|
| | |
|
| | | class tagCMRequestTreasure(Structure):
|
| | |
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # A6 23 修改家族公告 #tagCMChangeFamilyBroadcast
|
| | |
|
| | | class tagCMChangeFamilyBroadcast(Structure):
|
| | | Head = tagHead()
|
| | | Msg = "" #(char Msg[200])
|
| | | data = None
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Head.Cmd = 0xA6
|
| | | self.Head.SubCmd = 0x23
|
| | | return
|
| | |
|
| | | def ReadData(self, _lpData, _pos=0, _Len=0):
|
| | | self.Clear()
|
| | | _pos = self.Head.ReadData(_lpData, _pos)
|
| | | self.Msg,_pos = CommFunc.ReadString(_lpData, _pos,200)
|
| | | return _pos
|
| | |
|
| | | def Clear(self):
|
| | | self.Head = tagHead()
|
| | | self.Head.Clear()
|
| | | self.Head.Cmd = 0xA6
|
| | | self.Head.SubCmd = 0x23
|
| | | self.Msg = ""
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | length = 0
|
| | | length += self.Head.GetLength()
|
| | | length += 200
|
| | |
|
| | | return length
|
| | |
|
| | | def GetBuffer(self):
|
| | | data = ''
|
| | | data = CommFunc.WriteString(data, self.Head.GetLength(), self.Head.GetBuffer())
|
| | | data = CommFunc.WriteString(data, 200, self.Msg)
|
| | | return data
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''
|
| | | Head:%s,
|
| | | Msg:%s
|
| | | '''\
|
| | | %(
|
| | | self.Head.OutputString(),
|
| | | self.Msg
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMChangeFamilyBroadcast=tagCMChangeFamilyBroadcast()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMChangeFamilyBroadcast.Head.Cmd,m_NAtagCMChangeFamilyBroadcast.Head.SubCmd))] = m_NAtagCMChangeFamilyBroadcast
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # A6 24 修改家族徽章 #tagCMChangeFamilyEmblem
|
| | |
|
| | | class tagCMChangeFamilyEmblem(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("EmblemID", c_ubyte), # 更换的徽章ID
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xA6
|
| | | self.SubCmd = 0x24
|
| | | return
|
| | |
|
| | | def ReadData(self, stringData, _pos=0, _len=0):
|
| | | self.Clear()
|
| | | memmove(addressof(self), stringData[_pos:], self.GetLength())
|
| | | return _pos + self.GetLength()
|
| | |
|
| | | def Clear(self):
|
| | | self.Cmd = 0xA6
|
| | | self.SubCmd = 0x24
|
| | | self.EmblemID = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagCMChangeFamilyEmblem)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// A6 24 修改家族徽章 //tagCMChangeFamilyEmblem:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | EmblemID:%d
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.EmblemID
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMChangeFamilyEmblem=tagCMChangeFamilyEmblem()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMChangeFamilyEmblem.Cmd,m_NAtagCMChangeFamilyEmblem.SubCmd))] = m_NAtagCMChangeFamilyEmblem
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # A6 22 修改收人方式 #tagCMChangeFamilyJoin
|
| | |
|
| | | class tagCMChangeFamilyJoin(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("JoinReview", c_ubyte), #成员加入是否需要审核,默认0自动加入
|
| | | ("JoinLVMin", c_ushort), #限制最低可加入的玩家等级
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xA6
|
| | | self.SubCmd = 0x22
|
| | | return
|
| | |
|
| | | def ReadData(self, stringData, _pos=0, _len=0):
|
| | | self.Clear()
|
| | | memmove(addressof(self), stringData[_pos:], self.GetLength())
|
| | | return _pos + self.GetLength()
|
| | |
|
| | | def Clear(self):
|
| | | self.Cmd = 0xA6
|
| | | self.SubCmd = 0x22
|
| | | self.JoinReview = 0
|
| | | self.JoinLVMin = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagCMChangeFamilyJoin)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// A6 22 修改收人方式 //tagCMChangeFamilyJoin:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | JoinReview:%d,
|
| | | JoinLVMin:%d
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.JoinReview,
|
| | | self.JoinLVMin
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMChangeFamilyJoin=tagCMChangeFamilyJoin()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMChangeFamilyJoin.Cmd,m_NAtagCMChangeFamilyJoin.SubCmd))] = m_NAtagCMChangeFamilyJoin
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # A6 25 修改家族成员职位 #tagCMChangeFamilyMemLV
|
| | |
|
| | | class tagCMChangeFamilyMemLV(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("PlayerID", c_int), # 目标成员ID
|
| | | ("FmLV", c_ubyte), # 变更为xx职位
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xA6
|
| | | self.SubCmd = 0x25
|
| | | return
|
| | |
|
| | | def ReadData(self, stringData, _pos=0, _len=0):
|
| | | self.Clear()
|
| | | memmove(addressof(self), stringData[_pos:], self.GetLength())
|
| | | return _pos + self.GetLength()
|
| | |
|
| | | def Clear(self):
|
| | | self.Cmd = 0xA6
|
| | | self.SubCmd = 0x25
|
| | | self.PlayerID = 0
|
| | | self.FmLV = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagCMChangeFamilyMemLV)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// A6 25 修改家族成员职位 //tagCMChangeFamilyMemLV:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | PlayerID:%d,
|
| | | FmLV:%d
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.PlayerID,
|
| | | self.FmLV
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMChangeFamilyMemLV=tagCMChangeFamilyMemLV()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMChangeFamilyMemLV.Cmd,m_NAtagCMChangeFamilyMemLV.SubCmd))] = m_NAtagCMChangeFamilyMemLV
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # A6 15 传功操作 #tagCMChuangongOP
|
| | |
|
| | | class tagCMChuangongOP(Structure):
|
| | |
| | |
|
| | | m_NAtagCMRenameFamily=tagCMRenameFamily()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMRenameFamily.Head.Cmd,m_NAtagCMRenameFamily.Head.SubCmd))] = m_NAtagCMRenameFamily
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # A6 04 创建家族 #tagCMCreateFamily
|
| | |
|
| | | class tagCMCreateFamily(Structure):
|
| | | Head = tagHead()
|
| | | Name = "" #(char Name[33])
|
| | | EmblemID = 0 #(WORD EmblemID)//选择徽章ID,解锁仙盟等级为1级的均为可选ID
|
| | | data = None
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Head.Cmd = 0xA6
|
| | | self.Head.SubCmd = 0x04
|
| | | return
|
| | |
|
| | | def ReadData(self, _lpData, _pos=0, _Len=0):
|
| | | self.Clear()
|
| | | _pos = self.Head.ReadData(_lpData, _pos)
|
| | | self.Name,_pos = CommFunc.ReadString(_lpData, _pos,33)
|
| | | self.EmblemID,_pos = CommFunc.ReadWORD(_lpData, _pos)
|
| | | return _pos
|
| | |
|
| | | def Clear(self):
|
| | | self.Head = tagHead()
|
| | | self.Head.Clear()
|
| | | self.Head.Cmd = 0xA6
|
| | | self.Head.SubCmd = 0x04
|
| | | self.Name = ""
|
| | | self.EmblemID = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | length = 0
|
| | | length += self.Head.GetLength()
|
| | | length += 33
|
| | | length += 2
|
| | |
|
| | | return length
|
| | |
|
| | | def GetBuffer(self):
|
| | | data = ''
|
| | | data = CommFunc.WriteString(data, self.Head.GetLength(), self.Head.GetBuffer())
|
| | | data = CommFunc.WriteString(data, 33, self.Name)
|
| | | data = CommFunc.WriteWORD(data, self.EmblemID)
|
| | | return data
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''
|
| | | Head:%s,
|
| | | Name:%s,
|
| | | EmblemID:%d
|
| | | '''\
|
| | | %(
|
| | | self.Head.OutputString(),
|
| | | self.Name,
|
| | | self.EmblemID
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMCreateFamily=tagCMCreateFamily()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMCreateFamily.Head.Cmd,m_NAtagCMCreateFamily.Head.SubCmd))] = m_NAtagCMCreateFamily
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # A6 05 删除家族成员 #tagCMDeleteFamilyMember
|
| | |
|
| | | class tagCMDeleteFamilyMember(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("MemberID", c_int), |
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xA6
|
| | | self.SubCmd = 0x05
|
| | | return
|
| | |
|
| | | def ReadData(self, stringData, _pos=0, _len=0):
|
| | | self.Clear()
|
| | | memmove(addressof(self), stringData[_pos:], self.GetLength())
|
| | | return _pos + self.GetLength()
|
| | |
|
| | | def Clear(self):
|
| | | self.Cmd = 0xA6
|
| | | self.SubCmd = 0x05
|
| | | self.MemberID = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagCMDeleteFamilyMember)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// A6 05 删除家族成员 //tagCMDeleteFamilyMember:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | MemberID:%d
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.MemberID
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMDeleteFamilyMember=tagCMDeleteFamilyMember()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMDeleteFamilyMember.Cmd,m_NAtagCMDeleteFamilyMember.SubCmd))] = m_NAtagCMDeleteFamilyMember
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | |
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("MoneyType", c_ubyte), # 捐献货币类型
|
| | | ("DonateType", c_ubyte), # 捐献类型
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | |
| | | def Clear(self):
|
| | | self.Cmd = 0xA6
|
| | | self.SubCmd = 0x12
|
| | | self.MoneyType = 0
|
| | | self.DonateType = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | |
| | | DumpString = '''// A6 12 家族捐献货币 //tagCMFamilyMoneyDonate:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | MoneyType:%d
|
| | | DonateType:%d
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.MoneyType
|
| | | self.DonateType
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | #A6 02 申请加入家族#tagCGRequesJoinFamily
|
| | | # A6 26 请求家族成员列表 #tagCMGetFamilyInfo
|
| | |
|
| | | class tagCGRequesJoinFamily(Structure):
|
| | | class tagCMGetFamilyInfo(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("Type", c_ubyte), #申请类型
|
| | | ("AddFamilyID", c_int), #申请加入的家族
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xA6
|
| | | self.SubCmd = 0x26
|
| | | return
|
| | |
|
| | | def ReadData(self, stringData, _pos=0, _len=0):
|
| | | self.Clear()
|
| | | memmove(addressof(self), stringData[_pos:], self.GetLength())
|
| | | return _pos + self.GetLength()
|
| | |
|
| | | def Clear(self):
|
| | | self.Cmd = 0xA6
|
| | | self.SubCmd = 0x26
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagCMGetFamilyInfo)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// A6 26 请求家族成员列表 //tagCMGetFamilyInfo:
|
| | | Cmd:%s,
|
| | | SubCmd:%s
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMGetFamilyInfo=tagCMGetFamilyInfo()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMGetFamilyInfo.Cmd,m_NAtagCMGetFamilyInfo.SubCmd))] = m_NAtagCMGetFamilyInfo
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # A6 21 审核请求加入家族 #tagCMJoinFamilyReply
|
| | |
|
| | | class tagCMJoinFamilyReply(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("TagPlayerID", c_int), #被审核玩家ID 0则代表全部
|
| | | ("IsOK", c_ubyte), #是否同意其加入
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xA6
|
| | | self.SubCmd = 0x21
|
| | | return
|
| | |
|
| | | def ReadData(self, stringData, _pos=0, _len=0):
|
| | | self.Clear()
|
| | | memmove(addressof(self), stringData[_pos:], self.GetLength())
|
| | | return _pos + self.GetLength()
|
| | |
|
| | | def Clear(self):
|
| | | self.Cmd = 0xA6
|
| | | self.SubCmd = 0x21
|
| | | self.TagPlayerID = 0
|
| | | self.IsOK = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagCMJoinFamilyReply)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// A6 21 审核请求加入家族 //tagCMJoinFamilyReply:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | TagPlayerID:%d,
|
| | | IsOK:%d
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.TagPlayerID,
|
| | | self.IsOK
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMJoinFamilyReply=tagCMJoinFamilyReply()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMJoinFamilyReply.Cmd,m_NAtagCMJoinFamilyReply.SubCmd))] = m_NAtagCMJoinFamilyReply
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # A6 03 离开家族 #tagCMLeaveFamily
|
| | |
|
| | | class tagCMLeaveFamily(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xA6
|
| | | self.SubCmd = 0x03
|
| | | return
|
| | |
|
| | | def ReadData(self, stringData, _pos=0, _len=0):
|
| | | self.Clear()
|
| | | memmove(addressof(self), stringData[_pos:], self.GetLength())
|
| | | return _pos + self.GetLength()
|
| | |
|
| | | def Clear(self):
|
| | | self.Cmd = 0xA6
|
| | | self.SubCmd = 0x03
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagCMLeaveFamily)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// A6 03 离开家族 //tagCMLeaveFamily:
|
| | | Cmd:%s,
|
| | | SubCmd:%s
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMLeaveFamily=tagCMLeaveFamily()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMLeaveFamily.Cmd,m_NAtagCMLeaveFamily.SubCmd))] = m_NAtagCMLeaveFamily
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # A6 02 申请加入家族#tagCMRequesJoinFamily
|
| | |
|
| | | class tagCMRequesJoinFamily(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("Type", c_ubyte), #申请类型,0-申请;1-撤销
|
| | | ("TagFamilyID", c_int), #目标家族ID,申请时为0代表一键申请家族任意家族
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | |
| | | self.Cmd = 0xA6
|
| | | self.SubCmd = 0x02
|
| | | self.Type = 0
|
| | | self.AddFamilyID = 0
|
| | | self.TagFamilyID = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagCGRequesJoinFamily)
|
| | | return sizeof(tagCMRequesJoinFamily)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''//A6 02 申请加入家族//tagCGRequesJoinFamily:
|
| | | DumpString = '''// A6 02 申请加入家族//tagCMRequesJoinFamily:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | Type:%d,
|
| | | AddFamilyID:%d
|
| | | TagFamilyID:%d
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.Type,
|
| | | self.AddFamilyID
|
| | | self.TagFamilyID
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCGRequesJoinFamily=tagCGRequesJoinFamily()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCGRequesJoinFamily.Cmd,m_NAtagCGRequesJoinFamily.SubCmd))] = m_NAtagCGRequesJoinFamily
|
| | | m_NAtagCMRequesJoinFamily=tagCMRequesJoinFamily()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMRequesJoinFamily.Cmd,m_NAtagCMRequesJoinFamily.SubCmd))] = m_NAtagCMRequesJoinFamily
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | #A6 01 向玩家申请加入家族 #tagCGRequestJoinFamilyByPlayer
|
| | | # A6 01 向玩家申请加入家族 #tagCMRequestJoinFamilyByPlayer
|
| | |
|
| | | class tagCGRequestJoinFamilyByPlayer(Structure):
|
| | | class tagCMRequestJoinFamilyByPlayer(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("AddPlayerID", c_int), #申请加入的玩家ID
|
| | | ("TagPlayerID", c_int), #目标家族玩家ID
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | |
| | | def Clear(self):
|
| | | self.Cmd = 0xA6
|
| | | self.SubCmd = 0x01
|
| | | self.AddPlayerID = 0
|
| | | self.TagPlayerID = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagCGRequestJoinFamilyByPlayer)
|
| | | return sizeof(tagCMRequestJoinFamilyByPlayer)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''//A6 01 向玩家申请加入家族 //tagCGRequestJoinFamilyByPlayer:
|
| | | DumpString = '''// A6 01 向玩家申请加入家族 //tagCMRequestJoinFamilyByPlayer:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | AddPlayerID:%d
|
| | | TagPlayerID:%d
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.AddPlayerID
|
| | | self.TagPlayerID
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCGRequestJoinFamilyByPlayer=tagCGRequestJoinFamilyByPlayer()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCGRequestJoinFamilyByPlayer.Cmd,m_NAtagCGRequestJoinFamilyByPlayer.SubCmd))] = m_NAtagCGRequestJoinFamilyByPlayer
|
| | | m_NAtagCMRequestJoinFamilyByPlayer=tagCMRequestJoinFamilyByPlayer()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMRequestJoinFamilyByPlayer.Cmd,m_NAtagCMRequestJoinFamilyByPlayer.SubCmd))] = m_NAtagCMRequestJoinFamilyByPlayer
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | |
| | |
|
| | | m_NAtagCMFamilyTechLVUP=tagCMFamilyTechLVUP()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMFamilyTechLVUP.Cmd,m_NAtagCMFamilyTechLVUP.SubCmd))] = m_NAtagCMFamilyTechLVUP
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # A6 20 搜索家族列表 #tagCMViewFamilyPage
|
| | |
|
| | | class tagCMViewFamilyPage(Structure):
|
| | | Head = tagHead()
|
| | | MsgLen = 0 #(BYTE MsgLen)//模糊搜索家族,如果输入为空,则为不限制该条件
|
| | | Msg = "" #(String Msg)//size = MsgLen
|
| | | PageIndex = 0 #(BYTE PageIndex)//查询第X页索引,0~n
|
| | | ShowCount = 0 #(BYTE ShowCount)//每页数量,前端可自行指定,最大50
|
| | | data = None
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Head.Cmd = 0xA6
|
| | | self.Head.SubCmd = 0x20
|
| | | return
|
| | |
|
| | | def ReadData(self, _lpData, _pos=0, _Len=0):
|
| | | self.Clear()
|
| | | _pos = self.Head.ReadData(_lpData, _pos)
|
| | | self.MsgLen,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | self.Msg,_pos = CommFunc.ReadString(_lpData, _pos,self.MsgLen)
|
| | | self.PageIndex,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | self.ShowCount,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | return _pos
|
| | |
|
| | | def Clear(self):
|
| | | self.Head = tagHead()
|
| | | self.Head.Clear()
|
| | | self.Head.Cmd = 0xA6
|
| | | self.Head.SubCmd = 0x20
|
| | | self.MsgLen = 0
|
| | | self.Msg = ""
|
| | | self.PageIndex = 0
|
| | | self.ShowCount = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | length = 0
|
| | | length += self.Head.GetLength()
|
| | | length += 1
|
| | | length += len(self.Msg)
|
| | | length += 1
|
| | | length += 1
|
| | |
|
| | | return length
|
| | |
|
| | | def GetBuffer(self):
|
| | | data = ''
|
| | | data = CommFunc.WriteString(data, self.Head.GetLength(), self.Head.GetBuffer())
|
| | | data = CommFunc.WriteBYTE(data, self.MsgLen)
|
| | | data = CommFunc.WriteString(data, self.MsgLen, self.Msg)
|
| | | data = CommFunc.WriteBYTE(data, self.PageIndex)
|
| | | data = CommFunc.WriteBYTE(data, self.ShowCount)
|
| | | return data
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''
|
| | | Head:%s,
|
| | | MsgLen:%d,
|
| | | Msg:%s,
|
| | | PageIndex:%d,
|
| | | ShowCount:%d
|
| | | '''\
|
| | | %(
|
| | | self.Head.OutputString(),
|
| | | self.MsgLen,
|
| | | self.Msg,
|
| | | self.PageIndex,
|
| | | self.ShowCount
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMViewFamilyPage=tagCMViewFamilyPage()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMViewFamilyPage.Head.Cmd,m_NAtagCMViewFamilyPage.Head.SubCmd))] = m_NAtagCMViewFamilyPage
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | |
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | #B2 01 脱机挂状态 # tagCMLoginState
|
| | |
|
| | | class tagCMLoginState(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("State", c_ubyte), # 0正常登录,1脱机登录,2脱机登录死亡
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xB2
|
| | | self.SubCmd = 0x01
|
| | | return
|
| | |
|
| | | def ReadData(self, stringData, _pos=0, _len=0):
|
| | | self.Clear()
|
| | | memmove(addressof(self), stringData[_pos:], self.GetLength())
|
| | | return _pos + self.GetLength()
|
| | |
|
| | | def Clear(self):
|
| | | self.Cmd = 0xB2
|
| | | self.SubCmd = 0x01
|
| | | self.State = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagCMLoginState)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''//B2 01 脱机挂状态 // tagCMLoginState:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | State:%d
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.State
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMLoginState=tagCMLoginState()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMLoginState.Cmd,m_NAtagCMLoginState.SubCmd))] = m_NAtagCMLoginState
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | #B2 05 推送提醒设置 #tagCMPushNotificationsSetting
|
| | |
|
| | | class tagCMPushNotificationsSetting(Structure):
|
| | | Head = tagHead()
|
| | | OnoffBit = 0 #(DWORD OnoffBit)// 按位约定开关
|
| | | TimeLen = 0 #(BYTE TimeLen)
|
| | | TimeStr = "" #(String TimeStr)// 时间字符串 01:02-05:00
|
| | | data = None
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Head.Cmd = 0xB2
|
| | | self.Head.SubCmd = 0x05
|
| | | return
|
| | |
|
| | | def ReadData(self, _lpData, _pos=0, _Len=0):
|
| | | self.Clear()
|
| | | _pos = self.Head.ReadData(_lpData, _pos)
|
| | | self.OnoffBit,_pos = CommFunc.ReadDWORD(_lpData, _pos)
|
| | | self.TimeLen,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | self.TimeStr,_pos = CommFunc.ReadString(_lpData, _pos,self.TimeLen)
|
| | | return _pos
|
| | |
|
| | | def Clear(self):
|
| | | self.Head = tagHead()
|
| | | self.Head.Clear()
|
| | | self.Head.Cmd = 0xB2
|
| | | self.Head.SubCmd = 0x05
|
| | | self.OnoffBit = 0
|
| | | self.TimeLen = 0
|
| | | self.TimeStr = ""
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | length = 0
|
| | | length += self.Head.GetLength()
|
| | | length += 4
|
| | | length += 1
|
| | | length += len(self.TimeStr)
|
| | |
|
| | | return length
|
| | |
|
| | | def GetBuffer(self):
|
| | | data = ''
|
| | | data = CommFunc.WriteString(data, self.Head.GetLength(), self.Head.GetBuffer())
|
| | | data = CommFunc.WriteDWORD(data, self.OnoffBit)
|
| | | data = CommFunc.WriteBYTE(data, self.TimeLen)
|
| | | data = CommFunc.WriteString(data, self.TimeLen, self.TimeStr)
|
| | | return data
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''
|
| | | Head:%s,
|
| | | OnoffBit:%d,
|
| | | TimeLen:%d,
|
| | | TimeStr:%s
|
| | | '''\
|
| | | %(
|
| | | self.Head.OutputString(),
|
| | | self.OnoffBit,
|
| | | self.TimeLen,
|
| | | self.TimeStr
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMPushNotificationsSetting=tagCMPushNotificationsSetting()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMPushNotificationsSetting.Head.Cmd,m_NAtagCMPushNotificationsSetting.Head.SubCmd))] = m_NAtagCMPushNotificationsSetting
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | #B2 02 视野缩放 #tagCMSightZoom
|
| | |
|
| | | class tagCMSightZoom(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("Sight", c_ubyte), # 视野缩放,用于脱机挂不超过最大视野,空闲状态为0,被玩家攻击恢复视野
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xB2
|
| | | self.SubCmd = 0x02
|
| | | return
|
| | |
|
| | | def ReadData(self, stringData, _pos=0, _len=0):
|
| | | self.Clear()
|
| | | memmove(addressof(self), stringData[_pos:], self.GetLength())
|
| | | return _pos + self.GetLength()
|
| | |
|
| | | def Clear(self):
|
| | | self.Cmd = 0xB2
|
| | | self.SubCmd = 0x02
|
| | | self.Sight = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagCMSightZoom)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''//B2 02 视野缩放 //tagCMSightZoom:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | Sight:%d
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.Sight
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMSightZoom=tagCMSightZoom()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMSightZoom.Cmd,m_NAtagCMSightZoom.SubCmd))] = m_NAtagCMSightZoom
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | #B2 04 系统设置 #tagCMSystem
|
| | |
|
| | | class tagCMSystem(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("AutoEat", c_ubyte), # 自动吞噬
|
| | | ("AutoReborn", c_ubyte), #自动买活
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xB2
|
| | | self.SubCmd = 0x04
|
| | | return
|
| | |
|
| | | def ReadData(self, stringData, _pos=0, _len=0):
|
| | | self.Clear()
|
| | | memmove(addressof(self), stringData[_pos:], self.GetLength())
|
| | | return _pos + self.GetLength()
|
| | |
|
| | | def Clear(self):
|
| | | self.Cmd = 0xB2
|
| | | self.SubCmd = 0x04
|
| | | self.AutoEat = 0
|
| | | self.AutoReborn = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagCMSystem)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''//B2 04 系统设置 //tagCMSystem:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | AutoEat:%d,
|
| | | AutoReborn:%d
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.AutoEat,
|
| | | self.AutoReborn
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMSystem=tagCMSystem()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMSystem.Cmd,m_NAtagCMSystem.SubCmd))] = m_NAtagCMSystem
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | #B2 03 设置脱机挂NPC # tagCMTJGnpc
|
| | |
|
| | | class tagCMTJGnpc(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("NPCID", c_int), # 脱机挂点
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xB2
|
| | | self.SubCmd = 0x03
|
| | | return
|
| | |
|
| | | def ReadData(self, stringData, _pos=0, _len=0):
|
| | | self.Clear()
|
| | | memmove(addressof(self), stringData[_pos:], self.GetLength())
|
| | | return _pos + self.GetLength()
|
| | |
|
| | | def Clear(self):
|
| | | self.Cmd = 0xB2
|
| | | self.SubCmd = 0x03
|
| | | self.NPCID = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagCMTJGnpc)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''//B2 03 设置脱机挂NPC // tagCMTJGnpc:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | NPCID:%d
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.NPCID
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMTJGnpc=tagCMTJGnpc()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMTJGnpc.Cmd,m_NAtagCMTJGnpc.SubCmd))] = m_NAtagCMTJGnpc
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # B3 17 情戒解锁 #tagCMLoveRingUnlock
|
| | |
|
| | | class tagCMLoveRingUnlock(Structure):
|
| | |
| | |
|
| | | m_NAtagCMSendGifts=tagCMSendGifts()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMSendGifts.Cmd,m_NAtagCMSendGifts.SubCmd))] = m_NAtagCMSendGifts
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # B3 20 聊天 #tagCMTalk
|
| | |
|
| | | class tagCMPyTalk(Structure):
|
| | | Head = tagHead()
|
| | | ChannelType = 0 #(BYTE ChannelType)// 频道
|
| | | Len = 0 #(WORD Len)
|
| | | Content = "" #(String Content)//size = Len
|
| | | data = None
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Head.Cmd = 0xB3
|
| | | self.Head.SubCmd = 0x20
|
| | | return
|
| | |
|
| | | def ReadData(self, _lpData, _pos=0, _Len=0):
|
| | | self.Clear()
|
| | | _pos = self.Head.ReadData(_lpData, _pos)
|
| | | self.ChannelType,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | self.Len,_pos = CommFunc.ReadWORD(_lpData, _pos)
|
| | | self.Content,_pos = CommFunc.ReadString(_lpData, _pos,self.Len)
|
| | | return _pos
|
| | |
|
| | | def Clear(self):
|
| | | self.Head = tagHead()
|
| | | self.Head.Clear()
|
| | | self.Head.Cmd = 0xB3
|
| | | self.Head.SubCmd = 0x20
|
| | | self.ChannelType = 0
|
| | | self.Len = 0
|
| | | self.Content = ""
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | length = 0
|
| | | length += self.Head.GetLength()
|
| | | length += 1
|
| | | length += 2
|
| | | length += len(self.Content)
|
| | |
|
| | | return length
|
| | |
|
| | | def GetBuffer(self):
|
| | | data = ''
|
| | | data = CommFunc.WriteString(data, self.Head.GetLength(), self.Head.GetBuffer())
|
| | | data = CommFunc.WriteBYTE(data, self.ChannelType)
|
| | | data = CommFunc.WriteWORD(data, self.Len)
|
| | | data = CommFunc.WriteString(data, self.Len, self.Content)
|
| | | return data
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''
|
| | | Head:%s,
|
| | | ChannelType:%d,
|
| | | Len:%d,
|
| | | Content:%s
|
| | | '''\
|
| | | %(
|
| | | self.Head.OutputString(),
|
| | | self.ChannelType,
|
| | | self.Len,
|
| | | self.Content
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | |
| | |
|
| | | m_NAtagCMSuperAtk=tagCMSuperAtk()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMSuperAtk.Head.Cmd,m_NAtagCMSuperAtk.Head.SubCmd))] = m_NAtagCMSuperAtk
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | #B4 0A 脱机挂死亡 # tagCMTJGDead
|
| | |
|
| | | class tagCMTJGDead(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xB4
|
| | | self.SubCmd = 0x0A
|
| | | return
|
| | |
|
| | | def ReadData(self, stringData, _pos=0, _len=0):
|
| | | self.Clear()
|
| | | memmove(addressof(self), stringData[_pos:], self.GetLength())
|
| | | return _pos + self.GetLength()
|
| | |
|
| | | def Clear(self):
|
| | | self.Cmd = 0xB4
|
| | | self.SubCmd = 0x0A
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagCMTJGDead)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''//B4 0A 脱机挂死亡 // tagCMTJGDead:
|
| | | Cmd:%s,
|
| | | SubCmd:%s
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMTJGDead=tagCMTJGDead()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMTJGDead.Cmd,m_NAtagCMTJGDead.SubCmd))] = m_NAtagCMTJGDead
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|