| | |
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # B9 13 进入组队副本失败原因 #tagGCEnterTeamFBFailReason
|
| | |
|
| | | class tagGCEnterTeamFBFailReason(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("MapID", c_int), # 请求进入的地图ID
|
| | | ("AskType", c_ubyte), # 请求类型: 0-匹配请求;1-进入请求
|
| | | ("Reason", c_ubyte), # 失败原因:2-次数不足;3-进入CD中;6-门票不足
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xB9
|
| | | self.SubCmd = 0x13
|
| | | 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 = 0xB9
|
| | | self.SubCmd = 0x13
|
| | | self.MapID = 0
|
| | | self.AskType = 0
|
| | | self.Reason = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagGCEnterTeamFBFailReason)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// B9 13 进入组队副本失败原因 //tagGCEnterTeamFBFailReason:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | MapID:%d,
|
| | | AskType:%d,
|
| | | Reason:%d
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.MapID,
|
| | | self.AskType,
|
| | | self.Reason
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagGCEnterTeamFBFailReason=tagGCEnterTeamFBFailReason()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagGCEnterTeamFBFailReason.Cmd,m_NAtagGCEnterTeamFBFailReason.SubCmd))] = m_NAtagGCEnterTeamFBFailReason
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # B9 01 收到邀请加入队伍信息 #tagGCInviteJoinTeamInfo
|
| | |
|
| | | class tagGCInviteJoinTeamInfo(Structure):
|
| | |
| | | _fields_ = [
|
| | | ("FuncID", c_ubyte), # 功能ID
|
| | | ("State", c_ubyte), # 是否开启
|
| | | ("AwardState", c_ubyte), # 是否已领奖励
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | |
| | | def Clear(self):
|
| | | self.FuncID = 0
|
| | | self.State = 0
|
| | | self.AwardState = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | |
| | | def OutputString(self):
|
| | | DumpString = '''//A3 02 功能开通状态 //tagMCFuncOpenStateList:
|
| | | FuncID:%d,
|
| | | State:%d
|
| | | State:%d,
|
| | | AwardState:%d
|
| | | '''\
|
| | | %(
|
| | | self.FuncID,
|
| | | self.State
|
| | | self.State,
|
| | | self.AwardState
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # A7 17 聊天气泡框状态 #tagMCChatBubbleBoxState
|
| | |
|
| | | class tagMCChatBubbleBoxState(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("BoxState", c_int), # 按二进制位存储代表是否已开启,暂支持31位,以后有需要再加
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xA7
|
| | | self.SubCmd = 0x17
|
| | | 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 = 0xA7
|
| | | self.SubCmd = 0x17
|
| | | self.BoxState = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagMCChatBubbleBoxState)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// A7 17 聊天气泡框状态 //tagMCChatBubbleBoxState:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | BoxState:%d
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.BoxState
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagMCChatBubbleBoxState=tagMCChatBubbleBoxState()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagMCChatBubbleBoxState.Cmd,m_NAtagMCChatBubbleBoxState.SubCmd))] = m_NAtagMCChatBubbleBoxState
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # A7 13 动态障碍物状态 #tagMCDynamicBarrierState
|
| | |
|
| | | class tagMCDynamicBarrier(Structure):
|
| | |
| | |
|
| | | m_NAtagMCGuideState=tagMCGuideState()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagMCGuideState.Head.Cmd,m_NAtagMCGuideState.Head.SubCmd))] = m_NAtagMCGuideState
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # A7 16 小助手设置 #tagMCLittleHelperSet
|
| | |
|
| | | class tagMCLittleHelperFuncSet(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("SetNum", c_ubyte), # 托管功能设置编号1~20,每个编号对应的托管功能前端自定义
|
| | | ("Value1", c_int), # 自定义值1,如果存储的是勾选信息, 按二进制位存储代表是否勾选,支持31位,每位代表的含义前端自定义
|
| | | ("Value2", c_int), # 自定义值2
|
| | | ("Value3", c_int), # 自定义值3
|
| | | ("Value4", c_int), # 自定义值4
|
| | | ("Value5", c_int), # 自定义值5
|
| | | ("Value6", c_int), # 自定义值6
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | 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.SetNum = 0
|
| | | self.Value1 = 0
|
| | | self.Value2 = 0
|
| | | self.Value3 = 0
|
| | | self.Value4 = 0
|
| | | self.Value5 = 0
|
| | | self.Value6 = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagMCLittleHelperFuncSet)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// A7 16 小助手设置 //tagMCLittleHelperSet:
|
| | | SetNum:%d,
|
| | | Value1:%d,
|
| | | Value2:%d,
|
| | | Value3:%d,
|
| | | Value4:%d,
|
| | | Value5:%d,
|
| | | Value6:%d
|
| | | '''\
|
| | | %(
|
| | | self.SetNum,
|
| | | self.Value1,
|
| | | self.Value2,
|
| | | self.Value3,
|
| | | self.Value4,
|
| | | self.Value5,
|
| | | self.Value6
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | class tagMCLittleHelperSet(Structure):
|
| | | Head = tagHead()
|
| | | FuncSetCount = 0 #(BYTE FuncSetCount)// 托管功能设置数,暂支持20个
|
| | | FuncSetList = list() #(vector<tagMCLittleHelperFuncSet> FuncSetList)// 托管功能设置列表
|
| | | data = None
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Head.Cmd = 0xA7
|
| | | self.Head.SubCmd = 0x16
|
| | | return
|
| | |
|
| | | def ReadData(self, _lpData, _pos=0, _Len=0):
|
| | | self.Clear()
|
| | | _pos = self.Head.ReadData(_lpData, _pos)
|
| | | self.FuncSetCount,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | for i in range(self.FuncSetCount):
|
| | | temFuncSetList = tagMCLittleHelperFuncSet()
|
| | | _pos = temFuncSetList.ReadData(_lpData, _pos)
|
| | | self.FuncSetList.append(temFuncSetList)
|
| | | return _pos
|
| | |
|
| | | def Clear(self):
|
| | | self.Head = tagHead()
|
| | | self.Head.Clear()
|
| | | self.Head.Cmd = 0xA7
|
| | | self.Head.SubCmd = 0x16
|
| | | self.FuncSetCount = 0
|
| | | self.FuncSetList = list()
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | length = 0
|
| | | length += self.Head.GetLength()
|
| | | length += 1
|
| | | for i in range(self.FuncSetCount):
|
| | | length += self.FuncSetList[i].GetLength()
|
| | |
|
| | | return length
|
| | |
|
| | | def GetBuffer(self):
|
| | | data = ''
|
| | | data = CommFunc.WriteString(data, self.Head.GetLength(), self.Head.GetBuffer())
|
| | | data = CommFunc.WriteBYTE(data, self.FuncSetCount)
|
| | | for i in range(self.FuncSetCount):
|
| | | data = CommFunc.WriteString(data, self.FuncSetList[i].GetLength(), self.FuncSetList[i].GetBuffer())
|
| | | return data
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''
|
| | | Head:%s,
|
| | | FuncSetCount:%d,
|
| | | FuncSetList:%s
|
| | | '''\
|
| | | %(
|
| | | self.Head.OutputString(),
|
| | | self.FuncSetCount,
|
| | | "..."
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagMCLittleHelperSet=tagMCLittleHelperSet()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagMCLittleHelperSet.Head.Cmd,m_NAtagMCLittleHelperSet.Head.SubCmd))] = m_NAtagMCLittleHelperSet
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | |
| | |
|
| | | m_NAtagMCVirtualItemDrop=tagMCVirtualItemDrop()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagMCVirtualItemDrop.Head.Cmd,m_NAtagMCVirtualItemDrop.Head.SubCmd))] = m_NAtagMCVirtualItemDrop
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # AA 1D 累计充值活动信息 #tagMCActTotalRechargeInfo
|
| | |
|
| | | class tagMCTotalRechargeAwardItem(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("ItemID", c_int), |
| | | ("ItemCount", c_ushort), |
| | | ("IsBind", c_ubyte), |
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | 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.ItemID = 0
|
| | | self.ItemCount = 0
|
| | | self.IsBind = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagMCTotalRechargeAwardItem)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// AA 1D 累计充值活动信息 //tagMCActTotalRechargeInfo:
|
| | | ItemID:%d,
|
| | | ItemCount:%d,
|
| | | IsBind:%d
|
| | | '''\
|
| | | %(
|
| | | self.ItemID,
|
| | | self.ItemCount,
|
| | | self.IsBind
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | class tagMCTotalRechargeAward(Structure):
|
| | | AwardIndex = 0 #(BYTE AwardIndex)// 奖励索引 0~31
|
| | | NeedGold = 0 #(DWORD NeedGold)// 所需仙玉数
|
| | | AwardItemCount = 0 #(BYTE AwardItemCount)// 奖励物品数
|
| | | AwardItem = list() #(vector<tagMCTotalRechargeAwardItem> AwardItem)// 奖励物品信息
|
| | | data = None
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | return
|
| | |
|
| | | def ReadData(self, _lpData, _pos=0, _Len=0):
|
| | | self.Clear()
|
| | | self.AwardIndex,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | self.NeedGold,_pos = CommFunc.ReadDWORD(_lpData, _pos)
|
| | | self.AwardItemCount,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | for i in range(self.AwardItemCount):
|
| | | temAwardItem = tagMCTotalRechargeAwardItem()
|
| | | _pos = temAwardItem.ReadData(_lpData, _pos)
|
| | | self.AwardItem.append(temAwardItem)
|
| | | return _pos
|
| | |
|
| | | def Clear(self):
|
| | | self.AwardIndex = 0
|
| | | self.NeedGold = 0
|
| | | self.AwardItemCount = 0
|
| | | self.AwardItem = list()
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | length = 0
|
| | | length += 1
|
| | | length += 4
|
| | | length += 1
|
| | | for i in range(self.AwardItemCount):
|
| | | length += self.AwardItem[i].GetLength()
|
| | |
|
| | | return length
|
| | |
|
| | | def GetBuffer(self):
|
| | | data = ''
|
| | | data = CommFunc.WriteBYTE(data, self.AwardIndex)
|
| | | data = CommFunc.WriteDWORD(data, self.NeedGold)
|
| | | data = CommFunc.WriteBYTE(data, self.AwardItemCount)
|
| | | for i in range(self.AwardItemCount):
|
| | | data = CommFunc.WriteString(data, self.AwardItem[i].GetLength(), self.AwardItem[i].GetBuffer())
|
| | | return data
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''
|
| | | AwardIndex:%d,
|
| | | NeedGold:%d,
|
| | | AwardItemCount:%d,
|
| | | AwardItem:%s
|
| | | '''\
|
| | | %(
|
| | | self.AwardIndex,
|
| | | self.NeedGold,
|
| | | self.AwardItemCount,
|
| | | "..."
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | class tagMCTotalRechargeAwardDay(Structure):
|
| | | AwardCount = 0 #(BYTE AwardCount)// 奖励档数
|
| | | AwardInfo = list() #(vector<tagMCTotalRechargeAward> AwardInfo)// 奖励档信息
|
| | | data = None
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | return
|
| | |
|
| | | def ReadData(self, _lpData, _pos=0, _Len=0):
|
| | | self.Clear()
|
| | | self.AwardCount,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | for i in range(self.AwardCount):
|
| | | temAwardInfo = tagMCTotalRechargeAward()
|
| | | _pos = temAwardInfo.ReadData(_lpData, _pos)
|
| | | self.AwardInfo.append(temAwardInfo)
|
| | | return _pos
|
| | |
|
| | | def Clear(self):
|
| | | self.AwardCount = 0
|
| | | self.AwardInfo = list()
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | length = 0
|
| | | length += 1
|
| | | for i in range(self.AwardCount):
|
| | | length += self.AwardInfo[i].GetLength()
|
| | |
|
| | | return length
|
| | |
|
| | | def GetBuffer(self):
|
| | | data = ''
|
| | | data = CommFunc.WriteBYTE(data, self.AwardCount)
|
| | | for i in range(self.AwardCount):
|
| | | data = CommFunc.WriteString(data, self.AwardInfo[i].GetLength(), self.AwardInfo[i].GetBuffer())
|
| | | return data
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''
|
| | | AwardCount:%d,
|
| | | AwardInfo:%s
|
| | | '''\
|
| | | %(
|
| | | self.AwardCount,
|
| | | "..."
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | class tagMCActTotalRechargeInfo(Structure):
|
| | | Head = tagHead()
|
| | | StartDate = "" #(char StartDate[10])// 开始日期 y-m-d
|
| | | EndtDate = "" #(char EndtDate[10])// 结束日期 y-m-d
|
| | | IsDayReset = 0 #(BYTE IsDayReset)//是否每天重置
|
| | | LimitLV = 0 #(WORD LimitLV)// 限制等级
|
| | | AwardDays = 0 #(BYTE AwardDays)
|
| | | AwardDayInfo = list() #(vector<tagMCTotalRechargeAwardDay> AwardDayInfo)//每天对应信息; 如果只有一天,但是活动有多天,则代表每天奖励都一样
|
| | | data = None
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Head.Cmd = 0xAA
|
| | | self.Head.SubCmd = 0x1D
|
| | | return
|
| | |
|
| | | def ReadData(self, _lpData, _pos=0, _Len=0):
|
| | | self.Clear()
|
| | | _pos = self.Head.ReadData(_lpData, _pos)
|
| | | self.StartDate,_pos = CommFunc.ReadString(_lpData, _pos,10)
|
| | | self.EndtDate,_pos = CommFunc.ReadString(_lpData, _pos,10)
|
| | | self.IsDayReset,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | self.LimitLV,_pos = CommFunc.ReadWORD(_lpData, _pos)
|
| | | self.AwardDays,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | for i in range(self.AwardDays):
|
| | | temAwardDayInfo = tagMCTotalRechargeAwardDay()
|
| | | _pos = temAwardDayInfo.ReadData(_lpData, _pos)
|
| | | self.AwardDayInfo.append(temAwardDayInfo)
|
| | | return _pos
|
| | |
|
| | | def Clear(self):
|
| | | self.Head = tagHead()
|
| | | self.Head.Clear()
|
| | | self.Head.Cmd = 0xAA
|
| | | self.Head.SubCmd = 0x1D
|
| | | self.StartDate = ""
|
| | | self.EndtDate = ""
|
| | | self.IsDayReset = 0
|
| | | self.LimitLV = 0
|
| | | self.AwardDays = 0
|
| | | self.AwardDayInfo = list()
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | length = 0
|
| | | length += self.Head.GetLength()
|
| | | length += 10
|
| | | length += 10
|
| | | length += 1
|
| | | length += 2
|
| | | length += 1
|
| | | for i in range(self.AwardDays):
|
| | | length += self.AwardDayInfo[i].GetLength()
|
| | |
|
| | | return length
|
| | |
|
| | | def GetBuffer(self):
|
| | | data = ''
|
| | | data = CommFunc.WriteString(data, self.Head.GetLength(), self.Head.GetBuffer())
|
| | | data = CommFunc.WriteString(data, 10, self.StartDate)
|
| | | data = CommFunc.WriteString(data, 10, self.EndtDate)
|
| | | data = CommFunc.WriteBYTE(data, self.IsDayReset)
|
| | | data = CommFunc.WriteWORD(data, self.LimitLV)
|
| | | data = CommFunc.WriteBYTE(data, self.AwardDays)
|
| | | for i in range(self.AwardDays):
|
| | | data = CommFunc.WriteString(data, self.AwardDayInfo[i].GetLength(), self.AwardDayInfo[i].GetBuffer())
|
| | | return data
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''
|
| | | Head:%s,
|
| | | StartDate:%s,
|
| | | EndtDate:%s,
|
| | | IsDayReset:%d,
|
| | | LimitLV:%d,
|
| | | AwardDays:%d,
|
| | | AwardDayInfo:%s
|
| | | '''\
|
| | | %(
|
| | | self.Head.OutputString(),
|
| | | self.StartDate,
|
| | | self.EndtDate,
|
| | | self.IsDayReset,
|
| | | self.LimitLV,
|
| | | self.AwardDays,
|
| | | "..."
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagMCActTotalRechargeInfo=tagMCActTotalRechargeInfo()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagMCActTotalRechargeInfo.Head.Cmd,m_NAtagMCActTotalRechargeInfo.Head.SubCmd))] = m_NAtagMCActTotalRechargeInfo
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | |
| | | # AA 16 通知超值礼包信息 #tagMCSuperGiftInfo
|
| | |
|
| | | class tagMCSuperGiftInfo(Structure):
|
| | | Head = tagHead()
|
| | | GiftID = 0 #(DWORD GiftID)//商品ID
|
| | | EndtDate = "" #(char EndtDate[10])// 结束日期 y-m-d
|
| | | data = None
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("StartTime", c_int), |
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Head.Cmd = 0xAA
|
| | | self.Head.SubCmd = 0x16
|
| | | self.Cmd = 0xAA
|
| | | self.SubCmd = 0x16
|
| | | return
|
| | |
|
| | | def ReadData(self, _lpData, _pos=0, _Len=0):
|
| | | def ReadData(self, stringData, _pos=0, _len=0):
|
| | | self.Clear()
|
| | | _pos = self.Head.ReadData(_lpData, _pos)
|
| | | self.GiftID,_pos = CommFunc.ReadDWORD(_lpData, _pos)
|
| | | self.EndtDate,_pos = CommFunc.ReadString(_lpData, _pos,10)
|
| | | return _pos
|
| | | memmove(addressof(self), stringData[_pos:], self.GetLength())
|
| | | return _pos + self.GetLength()
|
| | |
|
| | | def Clear(self):
|
| | | self.Head = tagHead()
|
| | | self.Head.Clear()
|
| | | self.Head.Cmd = 0xAA
|
| | | self.Head.SubCmd = 0x16
|
| | | self.GiftID = 0
|
| | | self.EndtDate = ""
|
| | | self.Cmd = 0xAA
|
| | | self.SubCmd = 0x16
|
| | | self.StartTime = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | length = 0
|
| | | length += self.Head.GetLength()
|
| | | length += 4
|
| | | length += 10
|
| | |
|
| | | return length
|
| | | return sizeof(tagMCSuperGiftInfo)
|
| | |
|
| | | def GetBuffer(self):
|
| | | data = ''
|
| | | data = CommFunc.WriteString(data, self.Head.GetLength(), self.Head.GetBuffer())
|
| | | data = CommFunc.WriteDWORD(data, self.GiftID)
|
| | | data = CommFunc.WriteString(data, 10, self.EndtDate)
|
| | | return data
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''
|
| | | Head:%s,
|
| | | GiftID:%d,
|
| | | EndtDate:%s
|
| | | DumpString = '''// AA 16 通知超值礼包信息 //tagMCSuperGiftInfo:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | StartTime:%d
|
| | | '''\
|
| | | %(
|
| | | self.Head.OutputString(),
|
| | | self.GiftID,
|
| | | self.EndtDate
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.StartTime
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagMCSuperGiftInfo=tagMCSuperGiftInfo()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagMCSuperGiftInfo.Head.Cmd,m_NAtagMCSuperGiftInfo.Head.SubCmd))] = m_NAtagMCSuperGiftInfo
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagMCSuperGiftInfo.Cmd,m_NAtagMCSuperGiftInfo.SubCmd))] = m_NAtagMCSuperGiftInfo
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | |
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # AA 1C 累计充值玩家活动信息 #tagMCTotalRechargePlayerInfo
|
| | |
|
| | | class tagMCTotalRechargePlayerInfo(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("GoldTotal", c_int), #本次活动已累计充值仙玉数
|
| | | ("AwardRecord", c_int), #奖励领奖记录,按奖励索引二进制位存储是否已领取
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xAA
|
| | | self.SubCmd = 0x1C
|
| | | 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 = 0xAA
|
| | | self.SubCmd = 0x1C
|
| | | self.GoldTotal = 0
|
| | | self.AwardRecord = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagMCTotalRechargePlayerInfo)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// AA 1C 累计充值玩家活动信息 //tagMCTotalRechargePlayerInfo:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | GoldTotal:%d,
|
| | | AwardRecord:%d
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.GoldTotal,
|
| | | self.AwardRecord
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagMCTotalRechargePlayerInfo=tagMCTotalRechargePlayerInfo()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagMCTotalRechargePlayerInfo.Cmd,m_NAtagMCTotalRechargePlayerInfo.SubCmd))] = m_NAtagMCTotalRechargePlayerInfo
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # AA 14 仙界盛典充值大礼 #tagMCXJSDRecharge
|
| | |
|
| | | class tagMCXJSDRecharge(Structure):
|