From 6aeee7efd261fc1f553a4f3a748402f6dbb3cd79 Mon Sep 17 00:00:00 2001
From: hxp <ale99527@vip.qq.com>
Date: 星期五, 27 二月 2026 16:07:54 +0800
Subject: [PATCH] 501 【武将】武将时装-服务端(武将时装激活、升级、穿戴、属性;武将战斗预览;)
---
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChPyNetPack.py | 120 ++++++++++++++++++++++++++++++++----------------------------
1 files changed, 64 insertions(+), 56 deletions(-)
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChPyNetPack.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChPyNetPack.py
index 64697d5..35da850 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChPyNetPack.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChPyNetPack.py
@@ -10307,6 +10307,70 @@
#------------------------------------------------------
+# B2 36 武将皮肤操作 #tagCSHeroSkinOP
+
+class tagCSHeroSkinOP(Structure):
+ _pack_ = 1
+ _fields_ = [
+ ("Cmd", c_ubyte),
+ ("SubCmd", c_ubyte),
+ ("HeroID", c_int), #武将ID
+ ("SkinID", c_int), #时装ID
+ ("OPType", c_ubyte), #操作 1-激活;2-佩戴;3-升星
+ ("ItemIndex", c_ushort), #武将物品所在武将背包位置索引,仅佩戴时有效
+ ]
+
+ def __init__(self):
+ self.Clear()
+ self.Cmd = 0xB2
+ self.SubCmd = 0x36
+ 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 = 0x36
+ self.HeroID = 0
+ self.SkinID = 0
+ self.OPType = 0
+ self.ItemIndex = 0
+ return
+
+ def GetLength(self):
+ return sizeof(tagCSHeroSkinOP)
+
+ def GetBuffer(self):
+ return string_at(addressof(self), self.GetLength())
+
+ def OutputString(self):
+ DumpString = '''// B2 36 武将皮肤操作 //tagCSHeroSkinOP:
+ Cmd:%s,
+ SubCmd:%s,
+ HeroID:%d,
+ SkinID:%d,
+ OPType:%d,
+ ItemIndex:%d
+ '''\
+ %(
+ self.Cmd,
+ self.SubCmd,
+ self.HeroID,
+ self.SkinID,
+ self.OPType,
+ self.ItemIndex
+ )
+ return DumpString
+
+
+m_NAtagCSHeroSkinOP=tagCSHeroSkinOP()
+ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCSHeroSkinOP.Cmd,m_NAtagCSHeroSkinOP.SubCmd))] = m_NAtagCSHeroSkinOP
+
+
+#------------------------------------------------------
# B2 31 武将升星 #tagCSHeroStarUP
class tagCSHeroStarUP(Structure):
@@ -10441,62 +10505,6 @@
m_NAtagCSHeroWash=tagCSHeroWash()
ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCSHeroWash.Head.Cmd,m_NAtagCSHeroWash.Head.SubCmd))] = m_NAtagCSHeroWash
-
-
-#------------------------------------------------------
-# B2 36 武将换肤 #tagCSHeroWearSkin
-
-class tagCSHeroWearSkin(Structure):
- _pack_ = 1
- _fields_ = [
- ("Cmd", c_ubyte),
- ("SubCmd", c_ubyte),
- ("ItemIndex", c_ushort), #武将物品所在武将背包位置索引
- ("SkinIndex", c_ubyte), #皮肤索引
- ]
-
- def __init__(self):
- self.Clear()
- self.Cmd = 0xB2
- self.SubCmd = 0x36
- 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 = 0x36
- self.ItemIndex = 0
- self.SkinIndex = 0
- return
-
- def GetLength(self):
- return sizeof(tagCSHeroWearSkin)
-
- def GetBuffer(self):
- return string_at(addressof(self), self.GetLength())
-
- def OutputString(self):
- DumpString = '''// B2 36 武将换肤 //tagCSHeroWearSkin:
- Cmd:%s,
- SubCmd:%s,
- ItemIndex:%d,
- SkinIndex:%d
- '''\
- %(
- self.Cmd,
- self.SubCmd,
- self.ItemIndex,
- self.SkinIndex
- )
- return DumpString
-
-
-m_NAtagCSHeroWearSkin=tagCSHeroWearSkin()
-ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCSHeroWearSkin.Cmd,m_NAtagCSHeroWearSkin.SubCmd))] = m_NAtagCSHeroWearSkin
#------------------------------------------------------
--
Gitblit v1.8.0