From 92126566b642cdb2be53291c8e8e64c7a623782e Mon Sep 17 00:00:00 2001
From: hxp <ale99527@vip.qq.com>
Date: 星期二, 22 一月 2019 20:38:34 +0800
Subject: [PATCH] 5931 【后端】【1.5.100】诛仙装备开发(学习神技广播)
---
ServerPython/CoreServerGroup/GameServer/Script/ChPyNetPack.py | 220 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 files changed, 220 insertions(+), 0 deletions(-)
diff --git a/ServerPython/CoreServerGroup/GameServer/Script/ChPyNetPack.py b/ServerPython/CoreServerGroup/GameServer/Script/ChPyNetPack.py
index b6f4ae5..1df956a 100644
--- a/ServerPython/CoreServerGroup/GameServer/Script/ChPyNetPack.py
+++ b/ServerPython/CoreServerGroup/GameServer/Script/ChPyNetPack.py
@@ -3259,6 +3259,54 @@
#------------------------------------------------------
+# A1 08 刷新主服角色信息 #tagCMRefreshMainServerRole
+
+class tagCMRefreshMainServerRole(Structure):
+ _pack_ = 1
+ _fields_ = [
+ ("Cmd", c_ubyte),
+ ("SubCmd", c_ubyte),
+ ]
+
+ def __init__(self):
+ self.Clear()
+ self.Cmd = 0xA1
+ self.SubCmd = 0x08
+ 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 = 0x08
+ return
+
+ def GetLength(self):
+ return sizeof(tagCMRefreshMainServerRole)
+
+ def GetBuffer(self):
+ return string_at(addressof(self), self.GetLength())
+
+ def OutputString(self):
+ DumpString = '''// A1 08 刷新主服角色信息 //tagCMRefreshMainServerRole:
+ Cmd:%s,
+ SubCmd:%s
+ '''\
+ %(
+ self.Cmd,
+ self.SubCmd
+ )
+ return DumpString
+
+
+m_NAtagCMRefreshMainServerRole=tagCMRefreshMainServerRole()
+ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMRefreshMainServerRole.Cmd,m_NAtagCMRefreshMainServerRole.SubCmd))] = m_NAtagCMRefreshMainServerRole
+
+
+#------------------------------------------------------
#A1 03 设置是否成年 #tagCMAdult
class tagCMAdult(Structure):
@@ -6041,6 +6089,62 @@
#------------------------------------------------------
+# A3 30 装备诛仙装备 #tagCMEquipZhuXianItem
+
+class tagCMEquipZhuXianItem(Structure):
+ _pack_ = 1
+ _fields_ = [
+ ("Cmd", c_ubyte),
+ ("SubCmd", c_ubyte),
+ ("EquipIndex", c_ubyte), #装备在诛仙装备背包中的索引
+ ("ItemIndex", c_ubyte), #装备在诛仙物品背包中的索引
+ ]
+
+ def __init__(self):
+ self.Clear()
+ self.Cmd = 0xA3
+ 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 = 0xA3
+ self.SubCmd = 0x30
+ self.EquipIndex = 0
+ self.ItemIndex = 0
+ return
+
+ def GetLength(self):
+ return sizeof(tagCMEquipZhuXianItem)
+
+ def GetBuffer(self):
+ return string_at(addressof(self), self.GetLength())
+
+ def OutputString(self):
+ DumpString = '''// A3 30 装备诛仙装备 //tagCMEquipZhuXianItem:
+ Cmd:%s,
+ SubCmd:%s,
+ EquipIndex:%d,
+ ItemIndex:%d
+ '''\
+ %(
+ self.Cmd,
+ self.SubCmd,
+ self.EquipIndex,
+ self.ItemIndex
+ )
+ return DumpString
+
+
+m_NAtagCMEquipZhuXianItem=tagCMEquipZhuXianItem()
+ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMEquipZhuXianItem.Cmd,m_NAtagCMEquipZhuXianItem.SubCmd))] = m_NAtagCMEquipZhuXianItem
+
+
+#------------------------------------------------------
# A3 12 守护拾取物品 #tagCMGuardPickupItem
class tagCMGuardPickupItem(Structure):
@@ -6798,6 +6902,58 @@
m_NAtagCMTrialExchange=tagCMTrialExchange()
ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMTrialExchange.Cmd,m_NAtagCMTrialExchange.SubCmd))] = m_NAtagCMTrialExchange
+
+
+#------------------------------------------------------
+# A3 31 卸下诛仙装备 #tagCMUnEquipZhuXianItem
+
+class tagCMUnEquipZhuXianItem(Structure):
+ _pack_ = 1
+ _fields_ = [
+ ("Cmd", c_ubyte),
+ ("SubCmd", c_ubyte),
+ ("EquipIndex", c_ubyte), #装备在诛仙装备背包中的索引
+ ]
+
+ def __init__(self):
+ self.Clear()
+ self.Cmd = 0xA3
+ self.SubCmd = 0x31
+ 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 = 0xA3
+ self.SubCmd = 0x31
+ self.EquipIndex = 0
+ return
+
+ def GetLength(self):
+ return sizeof(tagCMUnEquipZhuXianItem)
+
+ def GetBuffer(self):
+ return string_at(addressof(self), self.GetLength())
+
+ def OutputString(self):
+ DumpString = '''// A3 31 卸下诛仙装备 //tagCMUnEquipZhuXianItem:
+ Cmd:%s,
+ SubCmd:%s,
+ EquipIndex:%d
+ '''\
+ %(
+ self.Cmd,
+ self.SubCmd,
+ self.EquipIndex
+ )
+ return DumpString
+
+
+m_NAtagCMUnEquipZhuXianItem=tagCMUnEquipZhuXianItem()
+ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMUnEquipZhuXianItem.Cmd,m_NAtagCMUnEquipZhuXianItem.SubCmd))] = m_NAtagCMUnEquipZhuXianItem
#------------------------------------------------------
@@ -15322,6 +15478,70 @@
#------------------------------------------------------
+# C1 06 跨服NPC对话 #tagCMCrossNPCTalk
+
+class tagCMCrossNPCTalk(Structure):
+ _pack_ = 1
+ _fields_ = [
+ ("Cmd", c_ubyte),
+ ("SubCmd", c_ubyte),
+ ("ObjID", c_int),
+ ("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):
--
Gitblit v1.8.0