| | |
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # A9 01 获取Boss首杀奖励 #tagCGGetBossFirstKillAward
|
| | |
|
| | | class tagCGGetBossFirstKillAward(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("NPCID", c_int), |
| | | ("AwardType", c_ubyte), # 0-首杀红包奖励;1-个人首杀奖励
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xA9
|
| | | 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 = 0xA9
|
| | | self.SubCmd = 0x01
|
| | | self.NPCID = 0
|
| | | self.AwardType = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagCGGetBossFirstKillAward)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// A9 01 获取Boss首杀奖励 //tagCGGetBossFirstKillAward:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | NPCID:%d,
|
| | | AwardType:%d
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.NPCID,
|
| | | self.AwardType
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCGGetBossFirstKillAward=tagCGGetBossFirstKillAward()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCGGetBossFirstKillAward.Cmd,m_NAtagCGGetBossFirstKillAward.SubCmd))] = m_NAtagCGGetBossFirstKillAward
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # A9 04 查询boss信息 #tagCGQueryBossInfo
|
| | |
|
| | | class tagCGQueryBossInfo(Structure):
|