| | |
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # C1 06 跨服NPC对话 #tagCMCrossNPCTalk
|
| | |
|
| | | class tagCMCrossNPCTalk(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("ObjID", c_ushort), |
| | | ("NPCID", c_int), |
| | | ("PosX", c_ushort), |
| | | ("PosY", c_ushort), |
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xC1
|
| | | self.SubCmd = 0x06
|
| | | 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 = 0xC1
|
| | | self.SubCmd = 0x06
|
| | | self.ObjID = 0
|
| | | self.NPCID = 0
|
| | | self.PosX = 0
|
| | | self.PosY = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagCMCrossNPCTalk)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// C1 06 跨服NPC对话 //tagCMCrossNPCTalk:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | ObjID:%d,
|
| | | NPCID:%d,
|
| | | PosX:%d,
|
| | | PosY:%d
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.ObjID,
|
| | | self.NPCID,
|
| | | self.PosX,
|
| | | self.PosY
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMCrossNPCTalk=tagCMCrossNPCTalk()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMCrossNPCTalk.Cmd,m_NAtagCMCrossNPCTalk.SubCmd))] = m_NAtagCMCrossNPCTalk
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # C1 02 跨服PK购买次数 #tagCMCrossRealmPKBuy
|
| | |
|
| | | class tagCMCrossRealmPKBuy(Structure):
|