| | |
| | | DWORD MapID; //场景地图ID
|
| | | };
|
| | |
|
| | | //副本助战表
|
| | |
|
| | | struct tagFBHelpBattle
|
| | | {
|
| | | DWORD _DataMapID; //数据地图ID
|
| | | BYTE _LineID; //功能线路ID
|
| | | DWORD FightPowerMin; //助战最低战力,也是副本战力
|
| | | DWORD FightPowerMax; //助战最高战力,0为不限制
|
| | | WORD LVLimit; //助战等级限制, 0为不限制
|
| | | list DayFreeHelpCount; //每日免费助战次数,[每日免费助战次数, 是否所有层通用]
|
| | | };
|
| | |
|
| | | //地图表
|
| | |
|
| | | struct tagChinMap
|
| | |
| | | eval RewardInfo; //奖励信息
|
| | | };
|
| | |
|
| | | //副本助战表
|
| | |
|
| | | struct tagFBHelpBattle
|
| | | {
|
| | | DWORD _DataMapID; //数据地图ID
|
| | | BYTE _LineID; //功能线路ID
|
| | | DWORD RobotFightPower; //助战NPC战力
|
| | | WORD RobotLV; //助战NPC等级
|
| | | dict RobotSkillsDict; //助战NPC技能, {"职业":[技能列表], ...}
|
| | | };
|
| | |
|
| | | //副本刷怪标识点表
|
| | |
|
| | | struct tagNPCCustomRefresh
|
| | |
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # B1 06 助战召唤 #tagCMHelpBattleCall
|
| | |
|
| | | class tagCMHelpBattleCall(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("IsOneKeyCall", c_ubyte), # 是否一键召唤
|
| | | ("PlayerID", c_int), # 召唤的玩家ID,大于1小于100代表机器人
|
| | | ("IsGoldCall", c_ubyte), # 是否仙玉召唤
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xB1
|
| | | 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 = 0xB1
|
| | | self.SubCmd = 0x06
|
| | | self.IsOneKeyCall = 0
|
| | | self.PlayerID = 0
|
| | | self.IsGoldCall = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagCMHelpBattleCall)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// B1 06 助战召唤 //tagCMHelpBattleCall:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | IsOneKeyCall:%d,
|
| | | PlayerID:%d,
|
| | | IsGoldCall:%d
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.IsOneKeyCall,
|
| | | self.PlayerID,
|
| | | self.IsGoldCall
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMHelpBattleCall=tagCMHelpBattleCall()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMHelpBattleCall.Cmd,m_NAtagCMHelpBattleCall.SubCmd))] = m_NAtagCMHelpBattleCall
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # B1 05 助战登记 #tagCMHelpBattleCheckIn
|
| | |
|
| | | class tagCMHelpBattleCheckIn(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xB1
|
| | | self.SubCmd = 0x05
|
| | | 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 = 0xB1
|
| | | self.SubCmd = 0x05
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagCMHelpBattleCheckIn)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// B1 05 助战登记 //tagCMHelpBattleCheckIn:
|
| | | Cmd:%s,
|
| | | SubCmd:%s
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMHelpBattleCheckIn=tagCMHelpBattleCheckIn()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMHelpBattleCheckIn.Cmd,m_NAtagCMHelpBattleCheckIn.SubCmd))] = m_NAtagCMHelpBattleCheckIn
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # B1 07 助战刷新 #tagCMHelpBattleRefresh
|
| | |
|
| | | class tagCMHelpBattleRefresh(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xB1
|
| | | self.SubCmd = 0x07
|
| | | 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 = 0xB1
|
| | | self.SubCmd = 0x07
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagCMHelpBattleRefresh)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// B1 07 助战刷新 //tagCMHelpBattleRefresh:
|
| | | Cmd:%s,
|
| | | SubCmd:%s
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMHelpBattleRefresh=tagCMHelpBattleRefresh()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMHelpBattleRefresh.Cmd,m_NAtagCMHelpBattleRefresh.SubCmd))] = m_NAtagCMHelpBattleRefresh
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # B1 02 领取多倍副本奖励 #tagCMGetMultiFBPrize
|
| | |
|
| | | class tagCMGetMultiFBPrize(Structure):
|
| | |
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # B2 06 助战召唤结果 #tagMCHelpBattleCallResult
|
| | |
|
| | | class tagMCHelpBattleCallResult(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("ObjID", c_int), # 助战实例ID
|
| | | ("PlayerID", c_int), # 助战镜像ID,大于1小于100代表机器人,如果是机器人前端按顺序自己记录对应实例ID代表已召唤
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xB2
|
| | | 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 = 0xB2
|
| | | self.SubCmd = 0x06
|
| | | self.ObjID = 0
|
| | | self.PlayerID = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagMCHelpBattleCallResult)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// B2 06 助战召唤结果 //tagMCHelpBattleCallResult:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | ObjID:%d,
|
| | | PlayerID:%d
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.ObjID,
|
| | | self.PlayerID
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagMCHelpBattleCallResult=tagMCHelpBattleCallResult()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagMCHelpBattleCallResult.Cmd,m_NAtagMCHelpBattleCallResult.SubCmd))] = m_NAtagMCHelpBattleCallResult
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # B2 05 助战登记结果 #tagMCHelpBattleCheckInResult
|
| | |
|
| | | class tagMCHelpBattleCheckInResult(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("IsOK", c_ubyte), #是否成功
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xB2
|
| | | self.SubCmd = 0x05
|
| | | 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 = 0x05
|
| | | self.IsOK = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagMCHelpBattleCheckInResult)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// B2 05 助战登记结果 //tagMCHelpBattleCheckInResult:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | IsOK:%d
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.IsOK
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagMCHelpBattleCheckInResult=tagMCHelpBattleCheckInResult()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagMCHelpBattleCheckInResult.Cmd,m_NAtagMCHelpBattleCheckInResult.SubCmd))] = m_NAtagMCHelpBattleCheckInResult
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # B2 07 助战机器人列表 #tagMCHelpBattleList
|
| | |
|
| | | class tagMCHelpBattlePlayer(Structure):
|
| | | ObjID = 0 #(DWORD ObjID)// 实例ID, 0代表未召唤
|
| | | PlayerID = 0 #(DWORD PlayerID)// 助战镜像ID, 大于1小于100代表机器人,如果是机器人,没有以下信息,相关信息自己读配置
|
| | | NameLen = 0 #(BYTE NameLen)
|
| | | Name = "" #(String Name)// 玩家名,size = NameLen
|
| | | LV = 0 #(WORD LV)// 玩家等级
|
| | | Job = 0 #(BYTE Job)// 玩家职业, 如果是机器人,则职业有值,服务端控制
|
| | | RealmLV = 0 #(WORD RealmLV)// 玩家境界等级
|
| | | FightPower = 0 #(DWORD FightPower)// 玩家战力
|
| | | IsNeedGold = 0 #(BYTE IsNeedGold)// 是否需要仙玉召唤
|
| | | data = None
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | return
|
| | |
|
| | | def ReadData(self, _lpData, _pos=0, _Len=0):
|
| | | self.Clear()
|
| | | self.ObjID,_pos = CommFunc.ReadDWORD(_lpData, _pos)
|
| | | self.PlayerID,_pos = CommFunc.ReadDWORD(_lpData, _pos)
|
| | | self.NameLen,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | self.Name,_pos = CommFunc.ReadString(_lpData, _pos,self.NameLen)
|
| | | self.LV,_pos = CommFunc.ReadWORD(_lpData, _pos)
|
| | | self.Job,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | self.RealmLV,_pos = CommFunc.ReadWORD(_lpData, _pos)
|
| | | self.FightPower,_pos = CommFunc.ReadDWORD(_lpData, _pos)
|
| | | self.IsNeedGold,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | return _pos
|
| | |
|
| | | def Clear(self):
|
| | | self.ObjID = 0
|
| | | self.PlayerID = 0
|
| | | self.NameLen = 0
|
| | | self.Name = ""
|
| | | self.LV = 0
|
| | | self.Job = 0
|
| | | self.RealmLV = 0
|
| | | self.FightPower = 0
|
| | | self.IsNeedGold = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | length = 0
|
| | | length += 4
|
| | | length += 4
|
| | | length += 1
|
| | | length += len(self.Name)
|
| | | length += 2
|
| | | length += 1
|
| | | length += 2
|
| | | length += 4
|
| | | length += 1
|
| | |
|
| | | return length
|
| | |
|
| | | def GetBuffer(self):
|
| | | data = ''
|
| | | data = CommFunc.WriteDWORD(data, self.ObjID)
|
| | | data = CommFunc.WriteDWORD(data, self.PlayerID)
|
| | | data = CommFunc.WriteBYTE(data, self.NameLen)
|
| | | data = CommFunc.WriteString(data, self.NameLen, self.Name)
|
| | | data = CommFunc.WriteWORD(data, self.LV)
|
| | | data = CommFunc.WriteBYTE(data, self.Job)
|
| | | data = CommFunc.WriteWORD(data, self.RealmLV)
|
| | | data = CommFunc.WriteDWORD(data, self.FightPower)
|
| | | data = CommFunc.WriteBYTE(data, self.IsNeedGold)
|
| | | return data
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''
|
| | | ObjID:%d,
|
| | | PlayerID:%d,
|
| | | NameLen:%d,
|
| | | Name:%s,
|
| | | LV:%d,
|
| | | Job:%d,
|
| | | RealmLV:%d,
|
| | | FightPower:%d,
|
| | | IsNeedGold:%d
|
| | | '''\
|
| | | %(
|
| | | self.ObjID,
|
| | | self.PlayerID,
|
| | | self.NameLen,
|
| | | self.Name,
|
| | | self.LV,
|
| | | self.Job,
|
| | | self.RealmLV,
|
| | | self.FightPower,
|
| | | self.IsNeedGold
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | class tagMCHelpBattleList(Structure):
|
| | | Head = tagHead()
|
| | | RefreshCount = 0 #(BYTE RefreshCount)// 已刷新次数
|
| | | HelpCount = 0 #(BYTE HelpCount)// 助战个数
|
| | | HelpPlayerList = list() #(vector<tagMCHelpBattlePlayer> HelpPlayerList)// 助战镜像信息
|
| | | data = None
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Head.Cmd = 0xB2
|
| | | self.Head.SubCmd = 0x07
|
| | | return
|
| | |
|
| | | def ReadData(self, _lpData, _pos=0, _Len=0):
|
| | | self.Clear()
|
| | | _pos = self.Head.ReadData(_lpData, _pos)
|
| | | self.RefreshCount,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | self.HelpCount,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | for i in range(self.HelpCount):
|
| | | temHelpPlayerList = tagMCHelpBattlePlayer()
|
| | | _pos = temHelpPlayerList.ReadData(_lpData, _pos)
|
| | | self.HelpPlayerList.append(temHelpPlayerList)
|
| | | return _pos
|
| | |
|
| | | def Clear(self):
|
| | | self.Head = tagHead()
|
| | | self.Head.Clear()
|
| | | self.Head.Cmd = 0xB2
|
| | | self.Head.SubCmd = 0x07
|
| | | self.RefreshCount = 0
|
| | | self.HelpCount = 0
|
| | | self.HelpPlayerList = list()
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | length = 0
|
| | | length += self.Head.GetLength()
|
| | | length += 1
|
| | | length += 1
|
| | | for i in range(self.HelpCount):
|
| | | length += self.HelpPlayerList[i].GetLength()
|
| | |
|
| | | return length
|
| | |
|
| | | def GetBuffer(self):
|
| | | data = ''
|
| | | data = CommFunc.WriteString(data, self.Head.GetLength(), self.Head.GetBuffer())
|
| | | data = CommFunc.WriteBYTE(data, self.RefreshCount)
|
| | | data = CommFunc.WriteBYTE(data, self.HelpCount)
|
| | | for i in range(self.HelpCount):
|
| | | data = CommFunc.WriteString(data, self.HelpPlayerList[i].GetLength(), self.HelpPlayerList[i].GetBuffer())
|
| | | return data
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''
|
| | | Head:%s,
|
| | | RefreshCount:%d,
|
| | | HelpCount:%d,
|
| | | HelpPlayerList:%s
|
| | | '''\
|
| | | %(
|
| | | self.Head.OutputString(),
|
| | | self.RefreshCount,
|
| | | self.HelpCount,
|
| | | "..."
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagMCHelpBattleList=tagMCHelpBattleList()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagMCHelpBattleList.Head.Cmd,m_NAtagMCHelpBattleList.Head.SubCmd))] = m_NAtagMCHelpBattleList
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # B2 04 冰晶矿脉信息通知 #tagMCIceLodeInfo
|
| | |
|
| | | class tagMCIceLodeInfo(Structure):
|
| | |
| | | ("DWORD", "MapID", 0),
|
| | | ),
|
| | |
|
| | | "FBHelpBattle":(
|
| | | ("DWORD", "DataMapID", 1),
|
| | | ("BYTE", "LineID", 1),
|
| | | ("DWORD", "FightPowerMin", 0),
|
| | | ("DWORD", "FightPowerMax", 0),
|
| | | ("WORD", "LVLimit", 0),
|
| | | ("list", "DayFreeHelpCount", 0),
|
| | | ),
|
| | |
|
| | | "ChinMap":(
|
| | | ("DWORD", "MapID", 1),
|
| | | ("char", "MapName", 0),
|
| | |
| | | def GetDataMapID(self): return self.DataMapID # 数据地图ID
|
| | | def GetLineID(self): return self.LineID # 功能线路ID
|
| | | def GetMapID(self): return self.MapID # 场景地图ID |
| | | |
| | | # 副本助战表 |
| | | class IPY_FBHelpBattle(): |
| | | |
| | | def __init__(self): |
| | | self.DataMapID = 0
|
| | | self.LineID = 0
|
| | | self.FightPowerMin = 0
|
| | | self.FightPowerMax = 0
|
| | | self.LVLimit = 0
|
| | | self.DayFreeHelpCount = [] |
| | | return |
| | | |
| | | def GetDataMapID(self): return self.DataMapID # 数据地图ID
|
| | | def GetLineID(self): return self.LineID # 功能线路ID
|
| | | def GetFightPowerMin(self): return self.FightPowerMin # 助战最低战力,也是副本战力
|
| | | def GetFightPowerMax(self): return self.FightPowerMax # 助战最高战力,0为不限制
|
| | | def GetLVLimit(self): return self.LVLimit # 助战等级限制, 0为不限制
|
| | | def GetDayFreeHelpCount(self): return self.DayFreeHelpCount # 每日免费助战次数,[每日免费助战次数, 是否所有层通用] |
| | | |
| | | # 地图表 |
| | | class IPY_ChinMap(): |
| | |
| | | self.ipyFBStateTimeCustomLen = len(self.ipyFBStateTimeCustomCache)
|
| | | self.ipyFBLineCache = self.__LoadFileData("FBLine", IPY_FBLine)
|
| | | self.ipyFBLineLen = len(self.ipyFBLineCache)
|
| | | self.ipyFBHelpBattleCache = self.__LoadFileData("FBHelpBattle", IPY_FBHelpBattle)
|
| | | self.ipyFBHelpBattleLen = len(self.ipyFBHelpBattleCache)
|
| | | self.ipyChinMapCache = self.__LoadFileData("ChinMap", IPY_ChinMap)
|
| | | self.ipyChinMapLen = len(self.ipyChinMapCache)
|
| | | self.ipyBOSSInfoCache = self.__LoadFileData("BOSSInfo", IPY_BOSSInfo)
|
| | |
| | | def GetFBStateTimeCustomByIndex(self, index): return self.ipyFBStateTimeCustomCache[index]
|
| | | def GetFBLineCount(self): return self.ipyFBLineLen
|
| | | def GetFBLineByIndex(self, index): return self.ipyFBLineCache[index]
|
| | | def GetFBHelpBattleCount(self): return self.ipyFBHelpBattleLen
|
| | | def GetFBHelpBattleByIndex(self, index): return self.ipyFBHelpBattleCache[index]
|
| | | def GetChinMapCount(self): return self.ipyChinMapLen
|
| | | def GetChinMapByIndex(self, index): return self.ipyChinMapCache[index]
|
| | | def GetBOSSInfoCount(self): return self.ipyBOSSInfoLen
|
| | |
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # B1 06 助战召唤 #tagCMHelpBattleCall
|
| | |
|
| | | class tagCMHelpBattleCall(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("IsOneKeyCall", c_ubyte), # 是否一键召唤
|
| | | ("PlayerID", c_int), # 召唤的玩家ID,大于1小于100代表机器人
|
| | | ("IsGoldCall", c_ubyte), # 是否仙玉召唤
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xB1
|
| | | 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 = 0xB1
|
| | | self.SubCmd = 0x06
|
| | | self.IsOneKeyCall = 0
|
| | | self.PlayerID = 0
|
| | | self.IsGoldCall = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagCMHelpBattleCall)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// B1 06 助战召唤 //tagCMHelpBattleCall:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | IsOneKeyCall:%d,
|
| | | PlayerID:%d,
|
| | | IsGoldCall:%d
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.IsOneKeyCall,
|
| | | self.PlayerID,
|
| | | self.IsGoldCall
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMHelpBattleCall=tagCMHelpBattleCall()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMHelpBattleCall.Cmd,m_NAtagCMHelpBattleCall.SubCmd))] = m_NAtagCMHelpBattleCall
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # B1 05 助战登记 #tagCMHelpBattleCheckIn
|
| | |
|
| | | class tagCMHelpBattleCheckIn(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xB1
|
| | | self.SubCmd = 0x05
|
| | | 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 = 0xB1
|
| | | self.SubCmd = 0x05
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagCMHelpBattleCheckIn)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// B1 05 助战登记 //tagCMHelpBattleCheckIn:
|
| | | Cmd:%s,
|
| | | SubCmd:%s
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMHelpBattleCheckIn=tagCMHelpBattleCheckIn()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMHelpBattleCheckIn.Cmd,m_NAtagCMHelpBattleCheckIn.SubCmd))] = m_NAtagCMHelpBattleCheckIn
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # B1 07 助战刷新 #tagCMHelpBattleRefresh
|
| | |
|
| | | class tagCMHelpBattleRefresh(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xB1
|
| | | self.SubCmd = 0x07
|
| | | 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 = 0xB1
|
| | | self.SubCmd = 0x07
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagCMHelpBattleRefresh)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// B1 07 助战刷新 //tagCMHelpBattleRefresh:
|
| | | Cmd:%s,
|
| | | SubCmd:%s
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagCMHelpBattleRefresh=tagCMHelpBattleRefresh()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagCMHelpBattleRefresh.Cmd,m_NAtagCMHelpBattleRefresh.SubCmd))] = m_NAtagCMHelpBattleRefresh
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # B1 02 领取多倍副本奖励 #tagCMGetMultiFBPrize
|
| | |
|
| | | class tagCMGetMultiFBPrize(Structure):
|
| | |
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # B2 06 助战召唤结果 #tagMCHelpBattleCallResult
|
| | |
|
| | | class tagMCHelpBattleCallResult(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("ObjID", c_int), # 助战实例ID
|
| | | ("PlayerID", c_int), # 助战镜像ID,大于1小于100代表机器人,如果是机器人前端按顺序自己记录对应实例ID代表已召唤
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xB2
|
| | | 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 = 0xB2
|
| | | self.SubCmd = 0x06
|
| | | self.ObjID = 0
|
| | | self.PlayerID = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagMCHelpBattleCallResult)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// B2 06 助战召唤结果 //tagMCHelpBattleCallResult:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | ObjID:%d,
|
| | | PlayerID:%d
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.ObjID,
|
| | | self.PlayerID
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagMCHelpBattleCallResult=tagMCHelpBattleCallResult()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagMCHelpBattleCallResult.Cmd,m_NAtagMCHelpBattleCallResult.SubCmd))] = m_NAtagMCHelpBattleCallResult
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # B2 05 助战登记结果 #tagMCHelpBattleCheckInResult
|
| | |
|
| | | class tagMCHelpBattleCheckInResult(Structure):
|
| | | _pack_ = 1
|
| | | _fields_ = [
|
| | | ("Cmd", c_ubyte),
|
| | | ("SubCmd", c_ubyte),
|
| | | ("IsOK", c_ubyte), #是否成功
|
| | | ]
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Cmd = 0xB2
|
| | | self.SubCmd = 0x05
|
| | | 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 = 0x05
|
| | | self.IsOK = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | return sizeof(tagMCHelpBattleCheckInResult)
|
| | |
|
| | | def GetBuffer(self):
|
| | | return string_at(addressof(self), self.GetLength())
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''// B2 05 助战登记结果 //tagMCHelpBattleCheckInResult:
|
| | | Cmd:%s,
|
| | | SubCmd:%s,
|
| | | IsOK:%d
|
| | | '''\
|
| | | %(
|
| | | self.Cmd,
|
| | | self.SubCmd,
|
| | | self.IsOK
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagMCHelpBattleCheckInResult=tagMCHelpBattleCheckInResult()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagMCHelpBattleCheckInResult.Cmd,m_NAtagMCHelpBattleCheckInResult.SubCmd))] = m_NAtagMCHelpBattleCheckInResult
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # B2 07 助战机器人列表 #tagMCHelpBattleList
|
| | |
|
| | | class tagMCHelpBattlePlayer(Structure):
|
| | | ObjID = 0 #(DWORD ObjID)// 实例ID, 0代表未召唤
|
| | | PlayerID = 0 #(DWORD PlayerID)// 助战镜像ID, 大于1小于100代表机器人,如果是机器人,没有以下信息,相关信息自己读配置
|
| | | NameLen = 0 #(BYTE NameLen)
|
| | | Name = "" #(String Name)// 玩家名,size = NameLen
|
| | | LV = 0 #(WORD LV)// 玩家等级
|
| | | Job = 0 #(BYTE Job)// 玩家职业, 如果是机器人,则职业有值,服务端控制
|
| | | RealmLV = 0 #(WORD RealmLV)// 玩家境界等级
|
| | | FightPower = 0 #(DWORD FightPower)// 玩家战力
|
| | | IsNeedGold = 0 #(BYTE IsNeedGold)// 是否需要仙玉召唤
|
| | | data = None
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | return
|
| | |
|
| | | def ReadData(self, _lpData, _pos=0, _Len=0):
|
| | | self.Clear()
|
| | | self.ObjID,_pos = CommFunc.ReadDWORD(_lpData, _pos)
|
| | | self.PlayerID,_pos = CommFunc.ReadDWORD(_lpData, _pos)
|
| | | self.NameLen,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | self.Name,_pos = CommFunc.ReadString(_lpData, _pos,self.NameLen)
|
| | | self.LV,_pos = CommFunc.ReadWORD(_lpData, _pos)
|
| | | self.Job,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | self.RealmLV,_pos = CommFunc.ReadWORD(_lpData, _pos)
|
| | | self.FightPower,_pos = CommFunc.ReadDWORD(_lpData, _pos)
|
| | | self.IsNeedGold,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | return _pos
|
| | |
|
| | | def Clear(self):
|
| | | self.ObjID = 0
|
| | | self.PlayerID = 0
|
| | | self.NameLen = 0
|
| | | self.Name = ""
|
| | | self.LV = 0
|
| | | self.Job = 0
|
| | | self.RealmLV = 0
|
| | | self.FightPower = 0
|
| | | self.IsNeedGold = 0
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | length = 0
|
| | | length += 4
|
| | | length += 4
|
| | | length += 1
|
| | | length += len(self.Name)
|
| | | length += 2
|
| | | length += 1
|
| | | length += 2
|
| | | length += 4
|
| | | length += 1
|
| | |
|
| | | return length
|
| | |
|
| | | def GetBuffer(self):
|
| | | data = ''
|
| | | data = CommFunc.WriteDWORD(data, self.ObjID)
|
| | | data = CommFunc.WriteDWORD(data, self.PlayerID)
|
| | | data = CommFunc.WriteBYTE(data, self.NameLen)
|
| | | data = CommFunc.WriteString(data, self.NameLen, self.Name)
|
| | | data = CommFunc.WriteWORD(data, self.LV)
|
| | | data = CommFunc.WriteBYTE(data, self.Job)
|
| | | data = CommFunc.WriteWORD(data, self.RealmLV)
|
| | | data = CommFunc.WriteDWORD(data, self.FightPower)
|
| | | data = CommFunc.WriteBYTE(data, self.IsNeedGold)
|
| | | return data
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''
|
| | | ObjID:%d,
|
| | | PlayerID:%d,
|
| | | NameLen:%d,
|
| | | Name:%s,
|
| | | LV:%d,
|
| | | Job:%d,
|
| | | RealmLV:%d,
|
| | | FightPower:%d,
|
| | | IsNeedGold:%d
|
| | | '''\
|
| | | %(
|
| | | self.ObjID,
|
| | | self.PlayerID,
|
| | | self.NameLen,
|
| | | self.Name,
|
| | | self.LV,
|
| | | self.Job,
|
| | | self.RealmLV,
|
| | | self.FightPower,
|
| | | self.IsNeedGold
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | class tagMCHelpBattleList(Structure):
|
| | | Head = tagHead()
|
| | | RefreshCount = 0 #(BYTE RefreshCount)// 已刷新次数
|
| | | HelpCount = 0 #(BYTE HelpCount)// 助战个数
|
| | | HelpPlayerList = list() #(vector<tagMCHelpBattlePlayer> HelpPlayerList)// 助战镜像信息
|
| | | data = None
|
| | |
|
| | | def __init__(self):
|
| | | self.Clear()
|
| | | self.Head.Cmd = 0xB2
|
| | | self.Head.SubCmd = 0x07
|
| | | return
|
| | |
|
| | | def ReadData(self, _lpData, _pos=0, _Len=0):
|
| | | self.Clear()
|
| | | _pos = self.Head.ReadData(_lpData, _pos)
|
| | | self.RefreshCount,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | self.HelpCount,_pos = CommFunc.ReadBYTE(_lpData, _pos)
|
| | | for i in range(self.HelpCount):
|
| | | temHelpPlayerList = tagMCHelpBattlePlayer()
|
| | | _pos = temHelpPlayerList.ReadData(_lpData, _pos)
|
| | | self.HelpPlayerList.append(temHelpPlayerList)
|
| | | return _pos
|
| | |
|
| | | def Clear(self):
|
| | | self.Head = tagHead()
|
| | | self.Head.Clear()
|
| | | self.Head.Cmd = 0xB2
|
| | | self.Head.SubCmd = 0x07
|
| | | self.RefreshCount = 0
|
| | | self.HelpCount = 0
|
| | | self.HelpPlayerList = list()
|
| | | return
|
| | |
|
| | | def GetLength(self):
|
| | | length = 0
|
| | | length += self.Head.GetLength()
|
| | | length += 1
|
| | | length += 1
|
| | | for i in range(self.HelpCount):
|
| | | length += self.HelpPlayerList[i].GetLength()
|
| | |
|
| | | return length
|
| | |
|
| | | def GetBuffer(self):
|
| | | data = ''
|
| | | data = CommFunc.WriteString(data, self.Head.GetLength(), self.Head.GetBuffer())
|
| | | data = CommFunc.WriteBYTE(data, self.RefreshCount)
|
| | | data = CommFunc.WriteBYTE(data, self.HelpCount)
|
| | | for i in range(self.HelpCount):
|
| | | data = CommFunc.WriteString(data, self.HelpPlayerList[i].GetLength(), self.HelpPlayerList[i].GetBuffer())
|
| | | return data
|
| | |
|
| | | def OutputString(self):
|
| | | DumpString = '''
|
| | | Head:%s,
|
| | | RefreshCount:%d,
|
| | | HelpCount:%d,
|
| | | HelpPlayerList:%s
|
| | | '''\
|
| | | %(
|
| | | self.Head.OutputString(),
|
| | | self.RefreshCount,
|
| | | self.HelpCount,
|
| | | "..."
|
| | | )
|
| | | return DumpString
|
| | |
|
| | |
|
| | | m_NAtagMCHelpBattleList=tagMCHelpBattleList()
|
| | | ChNetPackDict[eval("0x%02x%02x"%(m_NAtagMCHelpBattleList.Head.Cmd,m_NAtagMCHelpBattleList.Head.SubCmd))] = m_NAtagMCHelpBattleList
|
| | |
|
| | |
|
| | | #------------------------------------------------------
|
| | | # B2 04 冰晶矿脉信息通知 #tagMCIceLodeInfo
|
| | |
|
| | | class tagMCIceLodeInfo(Structure):
|
| | |
| | | ("eval", "RewardInfo", 0),
|
| | | ),
|
| | |
|
| | | "FBHelpBattle":(
|
| | | ("DWORD", "DataMapID", 1),
|
| | | ("BYTE", "LineID", 1),
|
| | | ("DWORD", "RobotFightPower", 0),
|
| | | ("WORD", "RobotLV", 0),
|
| | | ("dict", "RobotSkillsDict", 0),
|
| | | ),
|
| | |
|
| | | "NPCCustomRefresh":(
|
| | | ("DWORD", "ID", 1),
|
| | | ("list", "RefreshMarkInfo", 0),
|
| | |
| | | def GetGradeInfo(self): return self.GradeInfo # 评级规则
|
| | | def GetRewardInfo(self): return self.RewardInfo # 奖励信息 |
| | | |
| | | # 副本助战表 |
| | | class IPY_FBHelpBattle(): |
| | | |
| | | def __init__(self): |
| | | self.DataMapID = 0
|
| | | self.LineID = 0
|
| | | self.RobotFightPower = 0
|
| | | self.RobotLV = 0
|
| | | self.RobotSkillsDict = {} |
| | | return |
| | | |
| | | def GetDataMapID(self): return self.DataMapID # 数据地图ID
|
| | | def GetLineID(self): return self.LineID # 功能线路ID
|
| | | def GetRobotFightPower(self): return self.RobotFightPower # 助战NPC战力
|
| | | def GetRobotLV(self): return self.RobotLV # 助战NPC等级
|
| | | def GetRobotSkillsDict(self): return self.RobotSkillsDict # 助战NPC技能, {"职业":[技能列表], ...} |
| | | |
| | | # 副本刷怪标识点表 |
| | | class IPY_NPCCustomRefresh(): |
| | | |
| | |
| | | self.ipyFBFuncLen = len(self.ipyFBFuncCache)
|
| | | self.ipyFBLineCache = self.__LoadFileData("FBLine", IPY_FBLine)
|
| | | self.ipyFBLineLen = len(self.ipyFBLineCache)
|
| | | self.ipyFBHelpBattleCache = self.__LoadFileData("FBHelpBattle", IPY_FBHelpBattle)
|
| | | self.ipyFBHelpBattleLen = len(self.ipyFBHelpBattleCache)
|
| | | self.ipyNPCCustomRefreshCache = self.__LoadFileData("NPCCustomRefresh", IPY_NPCCustomRefresh)
|
| | | self.ipyNPCCustomRefreshLen = len(self.ipyNPCCustomRefreshCache)
|
| | | self.ipyDailyActionCache = self.__LoadFileData("DailyAction", IPY_DailyAction)
|
| | |
| | | def GetFBFuncByIndex(self, index): return self.ipyFBFuncCache[index]
|
| | | def GetFBLineCount(self): return self.ipyFBLineLen
|
| | | def GetFBLineByIndex(self, index): return self.ipyFBLineCache[index]
|
| | | def GetFBHelpBattleCount(self): return self.ipyFBHelpBattleLen
|
| | | def GetFBHelpBattleByIndex(self, index): return self.ipyFBHelpBattleCache[index]
|
| | | def GetNPCCustomRefreshCount(self): return self.ipyNPCCustomRefreshLen
|
| | | def GetNPCCustomRefreshByIndex(self, index): return self.ipyNPCCustomRefreshCache[index]
|
| | | def GetDailyActionCount(self): return self.ipyDailyActionLen
|