From 1e3f8cd83080ab4f140f862b2b2a0e60282b521e Mon Sep 17 00:00:00 2001
From: xdh <xiefantasy@qq.com>
Date: 星期四, 30 八月 2018 20:11:31 +0800
Subject: [PATCH] fix:3106 【后端】新增守卫人皇参与奖励

---
 ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChPyNetSendPack.py |  760 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++--
 1 files changed, 732 insertions(+), 28 deletions(-)

diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChPyNetSendPack.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChPyNetSendPack.py
index c126dd8..fabb438 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChPyNetSendPack.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChPyNetSendPack.py
@@ -2667,6 +2667,114 @@
 
 
 #------------------------------------------------------
+# A9 04 通知神兽副本NPC刷新时间 #tagGCDogzNPCRefreshTime
+
+class  tagDogzTimeInfoObj(Structure):
+    _pack_ = 1
+    _fields_ = [
+                  ("NPCID", c_int),    # npcid
+                  ("RefreshSecond", c_int),    # 刷新倒计时, 秒
+                  ]
+
+    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.NPCID = 0
+        self.RefreshSecond = 0
+        return
+
+    def GetLength(self):
+        return sizeof(tagDogzTimeInfoObj)
+
+    def GetBuffer(self):
+        return string_at(addressof(self), self.GetLength())
+
+    def OutputString(self):
+        DumpString = '''// A9 04 通知神兽副本NPC刷新时间 //tagGCDogzNPCRefreshTime:
+                                NPCID:%d,
+                                RefreshSecond:%d
+                                '''\
+                                %(
+                                self.NPCID,
+                                self.RefreshSecond
+                                )
+        return DumpString
+
+
+class  tagGCDogzNPCRefreshTime(Structure):
+    Head = tagHead()
+    Cnt = 0    #(BYTE Cnt)//信息个数
+    InfoList = list()    #(vector<tagDogzTimeInfoObj> InfoList)//信息列表
+    data = None
+
+    def __init__(self):
+        self.Clear()
+        self.Head.Cmd = 0xA9
+        self.Head.SubCmd = 0x04
+        return
+
+    def ReadData(self, _lpData, _pos=0, _Len=0):
+        self.Clear()
+        _pos = self.Head.ReadData(_lpData, _pos)
+        self.Cnt,_pos = CommFunc.ReadBYTE(_lpData, _pos)
+        for i in range(self.Cnt):
+            temInfoList = tagDogzTimeInfoObj()
+            _pos = temInfoList.ReadData(_lpData, _pos)
+            self.InfoList.append(temInfoList)
+        return _pos
+
+    def Clear(self):
+        self.Head = tagHead()
+        self.Head.Clear()
+        self.Head.Cmd = 0xA9
+        self.Head.SubCmd = 0x04
+        self.Cnt = 0
+        self.InfoList = list()
+        return
+
+    def GetLength(self):
+        length = 0
+        length += self.Head.GetLength()
+        length += 1
+        for i in range(self.Cnt):
+            length += self.InfoList[i].GetLength()
+
+        return length
+
+    def GetBuffer(self):
+        data = ''
+        data = CommFunc.WriteString(data, self.Head.GetLength(), self.Head.GetBuffer())
+        data = CommFunc.WriteBYTE(data, self.Cnt)
+        for i in range(self.Cnt):
+            data = CommFunc.WriteString(data, self.InfoList[i].GetLength(), self.InfoList[i].GetBuffer())
+        return data
+
+    def OutputString(self):
+        DumpString = '''
+                                Head:%s,
+                                Cnt:%d,
+                                InfoList:%s
+                                '''\
+                                %(
+                                self.Head.OutputString(),
+                                self.Cnt,
+                                "..."
+                                )
+        return DumpString
+
+
+m_NAtagGCDogzNPCRefreshTime=tagGCDogzNPCRefreshTime()
+ChNetPackDict[eval("0x%02x%02x"%(m_NAtagGCDogzNPCRefreshTime.Head.Cmd,m_NAtagGCDogzNPCRefreshTime.Head.SubCmd))] = m_NAtagGCDogzNPCRefreshTime
+
+
+#------------------------------------------------------
 # A9 A9 通知好友互赠精力信息 #tagGCFriendSendEnergyInfo
 
 class  tagGCFriendSendEnergyInfo(Structure):
@@ -4126,6 +4234,162 @@
 
 m_NAtagUpdatePlayerNameResult=tagUpdatePlayerNameResult()
 ChNetPackDict[eval("0x%02x%02x"%(m_NAtagUpdatePlayerNameResult.Cmd,m_NAtagUpdatePlayerNameResult.SubCmd))] = m_NAtagUpdatePlayerNameResult
+
+
+#------------------------------------------------------
+# AC 10 仙盟抢Boss所有Boss伤血进度信息 #tagGCAllFamilyBossHurtInfoList
+
+class  tagGCFamilyBossHurtInfo(Structure):
+    NPCID = 0    #(DWORD NPCID)
+    CurHP = 0    #(DWORD CurHP)
+    CurHPEx = 0    #(DWORD CurHPEx)
+    MaxHP = 0    #(DWORD MaxHP)
+    MaxHPEx = 0    #(DWORD MaxHPEx)
+    FamilyID = 0    #(DWORD FamilyID)// 最大实时伤血仙盟
+    NameLen = 0    #(BYTE NameLen)
+    FamilyName = ""    #(String FamilyName)
+    data = None
+
+    def __init__(self):
+        self.Clear()
+        return
+
+    def ReadData(self, _lpData, _pos=0, _Len=0):
+        self.Clear()
+        self.NPCID,_pos = CommFunc.ReadDWORD(_lpData, _pos)
+        self.CurHP,_pos = CommFunc.ReadDWORD(_lpData, _pos)
+        self.CurHPEx,_pos = CommFunc.ReadDWORD(_lpData, _pos)
+        self.MaxHP,_pos = CommFunc.ReadDWORD(_lpData, _pos)
+        self.MaxHPEx,_pos = CommFunc.ReadDWORD(_lpData, _pos)
+        self.FamilyID,_pos = CommFunc.ReadDWORD(_lpData, _pos)
+        self.NameLen,_pos = CommFunc.ReadBYTE(_lpData, _pos)
+        self.FamilyName,_pos = CommFunc.ReadString(_lpData, _pos,self.NameLen)
+        return _pos
+
+    def Clear(self):
+        self.NPCID = 0
+        self.CurHP = 0
+        self.CurHPEx = 0
+        self.MaxHP = 0
+        self.MaxHPEx = 0
+        self.FamilyID = 0
+        self.NameLen = 0
+        self.FamilyName = ""
+        return
+
+    def GetLength(self):
+        length = 0
+        length += 4
+        length += 4
+        length += 4
+        length += 4
+        length += 4
+        length += 4
+        length += 1
+        length += len(self.FamilyName)
+
+        return length
+
+    def GetBuffer(self):
+        data = ''
+        data = CommFunc.WriteDWORD(data, self.NPCID)
+        data = CommFunc.WriteDWORD(data, self.CurHP)
+        data = CommFunc.WriteDWORD(data, self.CurHPEx)
+        data = CommFunc.WriteDWORD(data, self.MaxHP)
+        data = CommFunc.WriteDWORD(data, self.MaxHPEx)
+        data = CommFunc.WriteDWORD(data, self.FamilyID)
+        data = CommFunc.WriteBYTE(data, self.NameLen)
+        data = CommFunc.WriteString(data, self.NameLen, self.FamilyName)
+        return data
+
+    def OutputString(self):
+        DumpString = '''
+                                NPCID:%d,
+                                CurHP:%d,
+                                CurHPEx:%d,
+                                MaxHP:%d,
+                                MaxHPEx:%d,
+                                FamilyID:%d,
+                                NameLen:%d,
+                                FamilyName:%s
+                                '''\
+                                %(
+                                self.NPCID,
+                                self.CurHP,
+                                self.CurHPEx,
+                                self.MaxHP,
+                                self.MaxHPEx,
+                                self.FamilyID,
+                                self.NameLen,
+                                self.FamilyName
+                                )
+        return DumpString
+
+
+class  tagGCAllFamilyBossHurtInfoList(Structure):
+    Head = tagHead()
+    NPCCount = 0    #(BYTE NPCCount)// 个数
+    NPCHurtInfo = list()    #(vector<tagGCFamilyBossHurtInfo> NPCHurtInfo)// NPC伤血信息列表
+    data = None
+
+    def __init__(self):
+        self.Clear()
+        self.Head.Cmd = 0xAC
+        self.Head.SubCmd = 0x10
+        return
+
+    def ReadData(self, _lpData, _pos=0, _Len=0):
+        self.Clear()
+        _pos = self.Head.ReadData(_lpData, _pos)
+        self.NPCCount,_pos = CommFunc.ReadBYTE(_lpData, _pos)
+        for i in range(self.NPCCount):
+            temNPCHurtInfo = tagGCFamilyBossHurtInfo()
+            _pos = temNPCHurtInfo.ReadData(_lpData, _pos)
+            self.NPCHurtInfo.append(temNPCHurtInfo)
+        return _pos
+
+    def Clear(self):
+        self.Head = tagHead()
+        self.Head.Clear()
+        self.Head.Cmd = 0xAC
+        self.Head.SubCmd = 0x10
+        self.NPCCount = 0
+        self.NPCHurtInfo = list()
+        return
+
+    def GetLength(self):
+        length = 0
+        length += self.Head.GetLength()
+        length += 1
+        for i in range(self.NPCCount):
+            length += self.NPCHurtInfo[i].GetLength()
+
+        return length
+
+    def GetBuffer(self):
+        data = ''
+        data = CommFunc.WriteString(data, self.Head.GetLength(), self.Head.GetBuffer())
+        data = CommFunc.WriteBYTE(data, self.NPCCount)
+        for i in range(self.NPCCount):
+            data = CommFunc.WriteString(data, self.NPCHurtInfo[i].GetLength(), self.NPCHurtInfo[i].GetBuffer())
+        return data
+
+    def OutputString(self):
+        DumpString = '''
+                                Head:%s,
+                                NPCCount:%d,
+                                NPCHurtInfo:%s
+                                '''\
+                                %(
+                                self.Head.OutputString(),
+                                self.NPCCount,
+                                "..."
+                                )
+        return DumpString
+
+
+m_NAtagGCAllFamilyBossHurtInfoList=tagGCAllFamilyBossHurtInfoList()
+ChNetPackDict[eval("0x%02x%02x"%(m_NAtagGCAllFamilyBossHurtInfoList.Head.Cmd,m_NAtagGCAllFamilyBossHurtInfoList.Head.SubCmd))] = m_NAtagGCAllFamilyBossHurtInfoList
 
 
 #------------------------------------------------------
@@ -10662,6 +10926,114 @@
 
 
 #------------------------------------------------------
+# A3 C1 神兽助战状态刷新 #tagMCDogzHelpbattleState
+
+class  tagMCDogzHelpbattleState(Structure):
+    _pack_ = 1
+    _fields_ = [
+                  ("Cmd", c_ubyte),
+                  ("SubCmd", c_ubyte),
+                  ("DogzID", c_ubyte),    # 神兽ID
+                  ("BatteState", c_ubyte),    #是否已助战, 0否1是
+                  ]
+
+    def __init__(self):
+        self.Clear()
+        self.Cmd = 0xA3
+        self.SubCmd = 0xC1
+        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 = 0xC1
+        self.DogzID = 0
+        self.BatteState = 0
+        return
+
+    def GetLength(self):
+        return sizeof(tagMCDogzHelpbattleState)
+
+    def GetBuffer(self):
+        return string_at(addressof(self), self.GetLength())
+
+    def OutputString(self):
+        DumpString = '''// A3 C1 神兽助战状态刷新 //tagMCDogzHelpbattleState:
+                                Cmd:%s,
+                                SubCmd:%s,
+                                DogzID:%d,
+                                BatteState:%d
+                                '''\
+                                %(
+                                self.Cmd,
+                                self.SubCmd,
+                                self.DogzID,
+                                self.BatteState
+                                )
+        return DumpString
+
+
+m_NAtagMCDogzHelpbattleState=tagMCDogzHelpbattleState()
+ChNetPackDict[eval("0x%02x%02x"%(m_NAtagMCDogzHelpbattleState.Cmd,m_NAtagMCDogzHelpbattleState.SubCmd))] = m_NAtagMCDogzHelpbattleState
+
+
+#------------------------------------------------------
+# A3 C0 神兽信息 #tagMCDogzInfo
+
+class  tagMCDogzInfo(Structure):
+    _pack_ = 1
+    _fields_ = [
+                  ("Cmd", c_ubyte),
+                  ("SubCmd", c_ubyte),
+                  ("BuyHelpbattleCount", c_ubyte),    #额外购买的助战数
+                  ]
+
+    def __init__(self):
+        self.Clear()
+        self.Cmd = 0xA3
+        self.SubCmd = 0xC0
+        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 = 0xC0
+        self.BuyHelpbattleCount = 0
+        return
+
+    def GetLength(self):
+        return sizeof(tagMCDogzInfo)
+
+    def GetBuffer(self):
+        return string_at(addressof(self), self.GetLength())
+
+    def OutputString(self):
+        DumpString = '''// A3 C0 神兽信息 //tagMCDogzInfo:
+                                Cmd:%s,
+                                SubCmd:%s,
+                                BuyHelpbattleCount:%d
+                                '''\
+                                %(
+                                self.Cmd,
+                                self.SubCmd,
+                                self.BuyHelpbattleCount
+                                )
+        return DumpString
+
+
+m_NAtagMCDogzInfo=tagMCDogzInfo()
+ChNetPackDict[eval("0x%02x%02x"%(m_NAtagMCDogzInfo.Cmd,m_NAtagMCDogzInfo.SubCmd))] = m_NAtagMCDogzInfo
+
+
+#------------------------------------------------------
 # A3 1C 通知装备分解信息 #tagMCEquipDecomposeInfo
 
 class  tagMCEquipDecomposeInfo(Structure):
@@ -12629,6 +13001,7 @@
     _pack_ = 1
     _fields_ = [
                   ("PriID", c_int),    # 特权ID
+                  ("State", c_ubyte),    #激活状态
                   ("CurValue", c_int),    #当前总进度
                   ("GotValue", c_int),    #已领取进度
                   ("ItemAwardState", c_ubyte),    #物品奖励是否已领取
@@ -12645,6 +13018,7 @@
 
     def Clear(self):
         self.PriID = 0
+        self.State = 0
         self.CurValue = 0
         self.GotValue = 0
         self.ItemAwardState = 0
@@ -12659,12 +13033,14 @@
     def OutputString(self):
         DumpString = '''// A3 53 法宝特权数据 //tagMCMWPrivilegeDataInfo:
                                 PriID:%d,
+                                State:%d,
                                 CurValue:%d,
                                 GotValue:%d,
                                 ItemAwardState:%d
                                 '''\
                                 %(
                                 self.PriID,
+                                self.State,
                                 self.CurValue,
                                 self.GotValue,
                                 self.ItemAwardState
@@ -12744,16 +13120,12 @@
 class  tagMCNPCIDCollectionCnt(Structure):
     _pack_ = 1
     _fields_ = [
-                  ("Cmd", c_ubyte),
-                  ("SubCmd", c_ubyte),
                   ("NPCID", c_int),    #NPCID
                   ("CollectionCnt", c_ubyte),    #已采集次数
                   ]
 
     def __init__(self):
         self.Clear()
-        self.Cmd = 0xA3
-        self.SubCmd = 0x26
         return
 
     def ReadData(self, stringData, _pos=0, _len=0):
@@ -12762,8 +13134,6 @@
         return _pos + self.GetLength()
 
     def Clear(self):
-        self.Cmd = 0xA3
-        self.SubCmd = 0x26
         self.NPCID = 0
         self.CollectionCnt = 0
         return
@@ -12776,14 +13146,10 @@
 
     def OutputString(self):
         DumpString = '''// A3 26 NPCID已采集次数信息 //tagMCNPCIDCollectionCntInfo:
-                                Cmd:%s,
-                                SubCmd:%s,
                                 NPCID:%d,
                                 CollectionCnt:%d
                                 '''\
                                 %(
-                                self.Cmd,
-                                self.SubCmd,
                                 self.NPCID,
                                 self.CollectionCnt
                                 )
@@ -16139,6 +16505,183 @@
 
 
 #------------------------------------------------------
+# A7 15 通知仙盟抢Boss伤血信息 #tagMCFamilyBossHurtList
+
+class  tagMCFamilyBossHurt(Structure):
+    FamilyID = 0    #(DWORD FamilyID)// 所属仙盟ID
+    HurtID = 0    #(DWORD HurtID)// 伤血的ID, 根据伤血类型表示不同的ID, 如仙盟ID或玩家ID
+    NameLen = 0    #(BYTE NameLen)
+    HurtName = ""    #(String HurtName)
+    HurtValue = 0    #(DWORD HurtValue)// 累计伤血,求余1亿的值
+    HurtValueEx = 0    #(DWORD HurtValueEx)// 累计伤血,整除1亿的值
+    InitTick = 0    #(DWORD InitTick)// 伤血初始tick,用于排序,先按伤血倒序排,再按tick正序排
+    data = None
+
+    def __init__(self):
+        self.Clear()
+        return
+
+    def ReadData(self, _lpData, _pos=0, _Len=0):
+        self.Clear()
+        self.FamilyID,_pos = CommFunc.ReadDWORD(_lpData, _pos)
+        self.HurtID,_pos = CommFunc.ReadDWORD(_lpData, _pos)
+        self.NameLen,_pos = CommFunc.ReadBYTE(_lpData, _pos)
+        self.HurtName,_pos = CommFunc.ReadString(_lpData, _pos,self.NameLen)
+        self.HurtValue,_pos = CommFunc.ReadDWORD(_lpData, _pos)
+        self.HurtValueEx,_pos = CommFunc.ReadDWORD(_lpData, _pos)
+        self.InitTick,_pos = CommFunc.ReadDWORD(_lpData, _pos)
+        return _pos
+
+    def Clear(self):
+        self.FamilyID = 0
+        self.HurtID = 0
+        self.NameLen = 0
+        self.HurtName = ""
+        self.HurtValue = 0
+        self.HurtValueEx = 0
+        self.InitTick = 0
+        return
+
+    def GetLength(self):
+        length = 0
+        length += 4
+        length += 4
+        length += 1
+        length += len(self.HurtName)
+        length += 4
+        length += 4
+        length += 4
+
+        return length
+
+    def GetBuffer(self):
+        data = ''
+        data = CommFunc.WriteDWORD(data, self.FamilyID)
+        data = CommFunc.WriteDWORD(data, self.HurtID)
+        data = CommFunc.WriteBYTE(data, self.NameLen)
+        data = CommFunc.WriteString(data, self.NameLen, self.HurtName)
+        data = CommFunc.WriteDWORD(data, self.HurtValue)
+        data = CommFunc.WriteDWORD(data, self.HurtValueEx)
+        data = CommFunc.WriteDWORD(data, self.InitTick)
+        return data
+
+    def OutputString(self):
+        DumpString = '''
+                                FamilyID:%d,
+                                HurtID:%d,
+                                NameLen:%d,
+                                HurtName:%s,
+                                HurtValue:%d,
+                                HurtValueEx:%d,
+                                InitTick:%d
+                                '''\
+                                %(
+                                self.FamilyID,
+                                self.HurtID,
+                                self.NameLen,
+                                self.HurtName,
+                                self.HurtValue,
+                                self.HurtValueEx,
+                                self.InitTick
+                                )
+        return DumpString
+
+
+class  tagMCFamilyBossHurtList(Structure):
+    Head = tagHead()
+    ObjID = 0    #(DWORD ObjID)
+    NPCID = 0    #(DWORD NPCID)
+    HurtType = 0    #(BYTE HurtType)// 0-实时仙盟伤血,1-历史仙盟伤血,2-实时玩家伤血,3-历史玩家伤血
+    IsSort = 0    #(BYTE IsSort)// 是否排序过的,一般boss被击杀后会统一同步一次排序过的最终结果,其他情况下客户端自己排序
+    HurtCount = 0    #(WORD HurtCount)// 伤血个数
+    HurtList = list()    #(vector<tagMCFamilyBossHurt> HurtList)// 伤血列表
+    data = None
+
+    def __init__(self):
+        self.Clear()
+        self.Head.Cmd = 0xA7
+        self.Head.SubCmd = 0x15
+        return
+
+    def ReadData(self, _lpData, _pos=0, _Len=0):
+        self.Clear()
+        _pos = self.Head.ReadData(_lpData, _pos)
+        self.ObjID,_pos = CommFunc.ReadDWORD(_lpData, _pos)
+        self.NPCID,_pos = CommFunc.ReadDWORD(_lpData, _pos)
+        self.HurtType,_pos = CommFunc.ReadBYTE(_lpData, _pos)
+        self.IsSort,_pos = CommFunc.ReadBYTE(_lpData, _pos)
+        self.HurtCount,_pos = CommFunc.ReadWORD(_lpData, _pos)
+        for i in range(self.HurtCount):
+            temHurtList = tagMCFamilyBossHurt()
+            _pos = temHurtList.ReadData(_lpData, _pos)
+            self.HurtList.append(temHurtList)
+        return _pos
+
+    def Clear(self):
+        self.Head = tagHead()
+        self.Head.Clear()
+        self.Head.Cmd = 0xA7
+        self.Head.SubCmd = 0x15
+        self.ObjID = 0
+        self.NPCID = 0
+        self.HurtType = 0
+        self.IsSort = 0
+        self.HurtCount = 0
+        self.HurtList = list()
+        return
+
+    def GetLength(self):
+        length = 0
+        length += self.Head.GetLength()
+        length += 4
+        length += 4
+        length += 1
+        length += 1
+        length += 2
+        for i in range(self.HurtCount):
+            length += self.HurtList[i].GetLength()
+
+        return length
+
+    def GetBuffer(self):
+        data = ''
+        data = CommFunc.WriteString(data, self.Head.GetLength(), self.Head.GetBuffer())
+        data = CommFunc.WriteDWORD(data, self.ObjID)
+        data = CommFunc.WriteDWORD(data, self.NPCID)
+        data = CommFunc.WriteBYTE(data, self.HurtType)
+        data = CommFunc.WriteBYTE(data, self.IsSort)
+        data = CommFunc.WriteWORD(data, self.HurtCount)
+        for i in range(self.HurtCount):
+            data = CommFunc.WriteString(data, self.HurtList[i].GetLength(), self.HurtList[i].GetBuffer())
+        return data
+
+    def OutputString(self):
+        DumpString = '''
+                                Head:%s,
+                                ObjID:%d,
+                                NPCID:%d,
+                                HurtType:%d,
+                                IsSort:%d,
+                                HurtCount:%d,
+                                HurtList:%s
+                                '''\
+                                %(
+                                self.Head.OutputString(),
+                                self.ObjID,
+                                self.NPCID,
+                                self.HurtType,
+                                self.IsSort,
+                                self.HurtCount,
+                                "..."
+                                )
+        return DumpString
+
+
+m_NAtagMCFamilyBossHurtList=tagMCFamilyBossHurtList()
+ChNetPackDict[eval("0x%02x%02x"%(m_NAtagMCFamilyBossHurtList.Head.Cmd,m_NAtagMCFamilyBossHurtList.Head.SubCmd))] = m_NAtagMCFamilyBossHurtList
+
+
+#------------------------------------------------------
 # A7 03 通知进入副本时间 #tagMCFBEnterTickList
 
 class  tagMCFBEnterTick(Structure):
@@ -16314,6 +16857,121 @@
 
 
 #------------------------------------------------------
+# A7 14 通知查询的NPC数量 #tagMCNPCCntList
+
+class  tagMCNPCCntInfo(Structure):
+    _pack_ = 1
+    _fields_ = [
+                  ("NPCID", c_int),    
+                  ("Cnt", c_int),    
+                  ]
+
+    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.NPCID = 0
+        self.Cnt = 0
+        return
+
+    def GetLength(self):
+        return sizeof(tagMCNPCCntInfo)
+
+    def GetBuffer(self):
+        return string_at(addressof(self), self.GetLength())
+
+    def OutputString(self):
+        DumpString = '''// A7 14 通知查询的NPC数量 //tagMCNPCCntList:
+                                NPCID:%d,
+                                Cnt:%d
+                                '''\
+                                %(
+                                self.NPCID,
+                                self.Cnt
+                                )
+        return DumpString
+
+
+class  tagMCNPCCntList(Structure):
+    Head = tagHead()
+    MapID = 0    #(DWORD MapID)
+    NPCInfoCnt = 0    #(BYTE NPCInfoCnt)
+    NPCInfoList = list()    #(vector<tagMCNPCCntInfo> NPCInfoList)
+    data = None
+
+    def __init__(self):
+        self.Clear()
+        self.Head.Cmd = 0xA7
+        self.Head.SubCmd = 0x14
+        return
+
+    def ReadData(self, _lpData, _pos=0, _Len=0):
+        self.Clear()
+        _pos = self.Head.ReadData(_lpData, _pos)
+        self.MapID,_pos = CommFunc.ReadDWORD(_lpData, _pos)
+        self.NPCInfoCnt,_pos = CommFunc.ReadBYTE(_lpData, _pos)
+        for i in range(self.NPCInfoCnt):
+            temNPCInfoList = tagMCNPCCntInfo()
+            _pos = temNPCInfoList.ReadData(_lpData, _pos)
+            self.NPCInfoList.append(temNPCInfoList)
+        return _pos
+
+    def Clear(self):
+        self.Head = tagHead()
+        self.Head.Clear()
+        self.Head.Cmd = 0xA7
+        self.Head.SubCmd = 0x14
+        self.MapID = 0
+        self.NPCInfoCnt = 0
+        self.NPCInfoList = list()
+        return
+
+    def GetLength(self):
+        length = 0
+        length += self.Head.GetLength()
+        length += 4
+        length += 1
+        for i in range(self.NPCInfoCnt):
+            length += self.NPCInfoList[i].GetLength()
+
+        return length
+
+    def GetBuffer(self):
+        data = ''
+        data = CommFunc.WriteString(data, self.Head.GetLength(), self.Head.GetBuffer())
+        data = CommFunc.WriteDWORD(data, self.MapID)
+        data = CommFunc.WriteBYTE(data, self.NPCInfoCnt)
+        for i in range(self.NPCInfoCnt):
+            data = CommFunc.WriteString(data, self.NPCInfoList[i].GetLength(), self.NPCInfoList[i].GetBuffer())
+        return data
+
+    def OutputString(self):
+        DumpString = '''
+                                Head:%s,
+                                MapID:%d,
+                                NPCInfoCnt:%d,
+                                NPCInfoList:%s
+                                '''\
+                                %(
+                                self.Head.OutputString(),
+                                self.MapID,
+                                self.NPCInfoCnt,
+                                "..."
+                                )
+        return DumpString
+
+
+m_NAtagMCNPCCntList=tagMCNPCCntList()
+ChNetPackDict[eval("0x%02x%02x"%(m_NAtagMCNPCCntList.Head.Cmd,m_NAtagMCNPCCntList.Head.SubCmd))] = m_NAtagMCNPCCntList
+
+
+#------------------------------------------------------
 #A7 01 通知选中对象 # tagMCNotifySelectObj
 
 class  tagMCNotifySelectObj(Structure):
@@ -16379,8 +17037,6 @@
 class  tagMCNPCInfo(Structure):
     _pack_ = 1
     _fields_ = [
-                  ("Cmd", c_ubyte),
-                  ("SubCmd", c_ubyte),
                   ("ObjID", c_int),    
                   ("NPCID", c_int),    
                   ("NPCHP", c_int),    
@@ -16393,8 +17049,6 @@
 
     def __init__(self):
         self.Clear()
-        self.Cmd = 0xA7
-        self.SubCmd = 0x06
         return
 
     def ReadData(self, stringData, _pos=0, _len=0):
@@ -16403,8 +17057,6 @@
         return _pos + self.GetLength()
 
     def Clear(self):
-        self.Cmd = 0xA7
-        self.SubCmd = 0x06
         self.ObjID = 0
         self.NPCID = 0
         self.NPCHP = 0
@@ -16423,8 +17075,6 @@
 
     def OutputString(self):
         DumpString = '''// A7 06 通知查询的NPC信息 //tagMCNPCInfoList:
-                                Cmd:%s,
-                                SubCmd:%s,
                                 ObjID:%d,
                                 NPCID:%d,
                                 NPCHP:%d,
@@ -16435,8 +17085,6 @@
                                 RefreshSecond:%d
                                 '''\
                                 %(
-                                self.Cmd,
-                                self.SubCmd,
                                 self.ObjID,
                                 self.NPCID,
                                 self.NPCHP,
@@ -18740,6 +19388,7 @@
                   ("Cmd", c_ubyte),
                   ("SubCmd", c_ubyte),
                   ("FirstGoldRewardState", c_ubyte),    #首充奖励是否已领奖
+                  ("FirstGoldTry", c_ubyte),    #首充试用状态0-不可试用 1-可试用 2-已试用
                   ]
 
     def __init__(self):
@@ -18757,6 +19406,7 @@
         self.Cmd = 0xAA
         self.SubCmd = 0x02
         self.FirstGoldRewardState = 0
+        self.FirstGoldTry = 0
         return
 
     def GetLength(self):
@@ -18769,12 +19419,14 @@
         DumpString = '''// AA 02 首充信息 //tagMCFirstGoldInfo:
                                 Cmd:%s,
                                 SubCmd:%s,
-                                FirstGoldRewardState:%d
+                                FirstGoldRewardState:%d,
+                                FirstGoldTry:%d
                                 '''\
                                 %(
                                 self.Cmd,
                                 self.SubCmd,
-                                self.FirstGoldRewardState
+                                self.FirstGoldRewardState,
+                                self.FirstGoldTry
                                 )
         return DumpString
 
@@ -18792,7 +19444,6 @@
                   ("Cmd", c_ubyte),
                   ("SubCmd", c_ubyte),
                   ("FirstGoldRemainTime", c_int),    #首充提示剩余时间
-                  ("FirstGoldTry", c_ubyte),    #首充试用状态0-不可试用 1-可试用 2-已试用
                   ]
 
     def __init__(self):
@@ -18810,7 +19461,6 @@
         self.Cmd = 0xAA
         self.SubCmd = 0x08
         self.FirstGoldRemainTime = 0
-        self.FirstGoldTry = 0
         return
 
     def GetLength(self):
@@ -18823,14 +19473,12 @@
         DumpString = '''// AA 08 首充提示剩余时间 //tagMCFirstGoldTime:
                                 Cmd:%s,
                                 SubCmd:%s,
-                                FirstGoldRemainTime:%d,
-                                FirstGoldTry:%d
+                                FirstGoldRemainTime:%d
                                 '''\
                                 %(
                                 self.Cmd,
                                 self.SubCmd,
-                                self.FirstGoldRemainTime,
-                                self.FirstGoldTry
+                                self.FirstGoldRemainTime
                                 )
         return DumpString
 
@@ -19833,6 +20481,62 @@
 
 
 #------------------------------------------------------
+# AA 16 通知超值礼包信息 #tagMCSuperGiftInfo
+
+class  tagMCSuperGiftInfo(Structure):
+    _pack_ = 1
+    _fields_ = [
+                  ("Cmd", c_ubyte),
+                  ("SubCmd", c_ubyte),
+                  ("GiftID", c_int),    #商品ID
+                  ("RemainDay", c_ubyte),    #剩余天数
+                  ]
+
+    def __init__(self):
+        self.Clear()
+        self.Cmd = 0xAA
+        self.SubCmd = 0x16
+        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 = 0x16
+        self.GiftID = 0
+        self.RemainDay = 0
+        return
+
+    def GetLength(self):
+        return sizeof(tagMCSuperGiftInfo)
+
+    def GetBuffer(self):
+        return string_at(addressof(self), self.GetLength())
+
+    def OutputString(self):
+        DumpString = '''// AA 16 通知超值礼包信息 //tagMCSuperGiftInfo:
+                                Cmd:%s,
+                                SubCmd:%s,
+                                GiftID:%d,
+                                RemainDay:%d
+                                '''\
+                                %(
+                                self.Cmd,
+                                self.SubCmd,
+                                self.GiftID,
+                                self.RemainDay
+                                )
+        return DumpString
+
+
+m_NAtagMCSuperGiftInfo=tagMCSuperGiftInfo()
+ChNetPackDict[eval("0x%02x%02x"%(m_NAtagMCSuperGiftInfo.Cmd,m_NAtagMCSuperGiftInfo.SubCmd))] = m_NAtagMCSuperGiftInfo
+
+
+#------------------------------------------------------
 #AA 01 累计登陆天数信息 #tagMCTotalLoginDayCntInfo
 
 class  tagMCTotalLoginDayCntInfo(Structure):

--
Gitblit v1.8.0