From e4a5fbde4c804262a7cfd17d89d427b4ff36accb Mon Sep 17 00:00:00 2001
From: hxp <ale99527@vip.qq.com>
Date: 星期四, 09 十月 2025 19:41:26 +0800
Subject: [PATCH] 225 【付费内容】功能基金-服务端
---
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/DB/DBStruct.py | 257 +++++++++++++++++++++++++++++++++++++++++++++++++++
1 files changed, 256 insertions(+), 1 deletions(-)
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/DB/DBStruct.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/DB/DBStruct.py
index b6b8e0c..771998a 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/DB/DBStruct.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/DB/DBStruct.py
@@ -1126,6 +1126,7 @@
('RealmLV', ctypes.c_ubyte),
('Face', ctypes.c_int),
('FacePic', ctypes.c_int),
+ ('ModelMark', ctypes.c_ulong),
('FamilyID', ctypes.c_ulong),
('FamilyName', ctypes.c_char * 33),
('FamilyEmblemID', ctypes.c_ushort),
@@ -1152,6 +1153,7 @@
self.RealmLV = 0
self.Face = 0
self.FacePic = 0
+ self.ModelMark = 0
self.FamilyID = 0
self.FamilyName = ''
self.FamilyEmblemID = 0
@@ -1177,6 +1179,7 @@
self.RealmLV, pos = CommFunc.ReadBYTE(buf, pos)
self.Face, pos = CommFunc.ReadDWORD(buf, pos)
self.FacePic, pos = CommFunc.ReadDWORD(buf, pos)
+ self.ModelMark, pos = CommFunc.ReadDWORD(buf, pos)
self.FamilyID, pos = CommFunc.ReadDWORD(buf, pos)
self.FamilyName, pos = CommFunc.ReadString(buf, pos, 33)
self.FamilyEmblemID, pos = CommFunc.ReadWORD(buf, pos)
@@ -1200,6 +1203,7 @@
buf = CommFunc.WriteBYTE(buf, self.RealmLV)
buf = CommFunc.WriteDWORD(buf, self.Face)
buf = CommFunc.WriteDWORD(buf, self.FacePic)
+ buf = CommFunc.WriteDWORD(buf, self.ModelMark)
buf = CommFunc.WriteDWORD(buf, self.FamilyID)
buf = CommFunc.WriteString(buf, sizeof(ctypes.c_char) * 33, self.FamilyName)
buf = CommFunc.WriteWORD(buf, self.FamilyEmblemID)
@@ -1223,6 +1227,7 @@
length += sizeof(ctypes.c_int)
length += sizeof(ctypes.c_int)
length += sizeof(ctypes.c_ulong)
+ length += sizeof(ctypes.c_ulong)
length += sizeof(ctypes.c_char) * 33
length += sizeof(ctypes.c_ushort)
length += sizeof(ctypes.c_ulong)
@@ -1244,6 +1249,7 @@
RealmLV = %s,
Face = %s,
FacePic = %s,
+ ModelMark = %s,
FamilyID = %s,
FamilyName = %s,
FamilyEmblemID = %s,
@@ -1264,6 +1270,7 @@
self.RealmLV,
self.Face,
self.FacePic,
+ self.ModelMark,
self.FamilyID,
self.FamilyName,
self.FamilyEmblemID,
@@ -2029,11 +2036,259 @@
return output
+# 功能队伍表 #tagDBFuncTeam
+class tagDBFuncTeam(Structure):
+ _pack_ = 1
+ _fields_ = [
+ ('TeamID', ctypes.c_ulong),
+ ('TeamName', ctypes.c_char * 33),
+ ('ZoneID', ctypes.c_ubyte),
+ ('FuncMapID', ctypes.c_ulong),
+ ('FuncMapEx', ctypes.c_ulong),
+ ('CreateTime', ctypes.c_ulong),
+ ('CaptainID', ctypes.c_ulong),
+ ('MinLV', ctypes.c_ushort),
+ ('MinFightPower', ctypes.c_ulong),
+ ('MinFightPowerEx', ctypes.c_ulong),
+ ('ServerOnly', ctypes.c_ubyte),
+ ('NeedCheck', ctypes.c_ubyte),
+ ('ApplyIDLen', ctypes.c_ushort),
+ ('ApplyIDList', ctypes.c_char_p),
+ ('Value1', ctypes.c_ulong),
+ ('Value2', ctypes.c_ulong),
+ ('Value3', ctypes.c_ulong),
+ ('Value4', ctypes.c_ulong),
+ ('Value5', ctypes.c_ulong),
+ ('ADOResult', ctypes.c_ulong),
+ ]
+
+ def __init__(self):
+ Structure.__init__(self)
+ self.clear()
+
+ def clear(self):
+ self.TeamID = 0
+ self.TeamName = ''
+ self.ZoneID = 0
+ self.FuncMapID = 0
+ self.FuncMapEx = 0
+ self.CreateTime = 0
+ self.CaptainID = 0
+ self.MinLV = 0
+ self.MinFightPower = 0
+ self.MinFightPowerEx = 0
+ self.ServerOnly = 0
+ self.NeedCheck = 0
+ self.ApplyIDLen = 0
+ self.ApplyIDList = ''
+ self.Value1 = 0
+ self.Value2 = 0
+ self.Value3 = 0
+ self.Value4 = 0
+ self.Value5 = 0
+
+ def readData(self, buf, pos = 0, length = 0):
+ if not pos <= length:
+ return -1
+ if len(buf) < pos + self.getLength():
+ return -1
+ self.clear()
+ self.TeamID, pos = CommFunc.ReadDWORD(buf, pos)
+ self.TeamName, pos = CommFunc.ReadString(buf, pos, 33)
+ self.ZoneID, pos = CommFunc.ReadBYTE(buf, pos)
+ self.FuncMapID, pos = CommFunc.ReadDWORD(buf, pos)
+ self.FuncMapEx, pos = CommFunc.ReadDWORD(buf, pos)
+ self.CreateTime, pos = CommFunc.ReadDWORD(buf, pos)
+ self.CaptainID, pos = CommFunc.ReadDWORD(buf, pos)
+ self.MinLV, pos = CommFunc.ReadWORD(buf, pos)
+ self.MinFightPower, pos = CommFunc.ReadDWORD(buf, pos)
+ self.MinFightPowerEx, pos = CommFunc.ReadDWORD(buf, pos)
+ self.ServerOnly, pos = CommFunc.ReadBYTE(buf, pos)
+ self.NeedCheck, pos = CommFunc.ReadBYTE(buf, pos)
+ self.ApplyIDLen, pos = CommFunc.ReadWORD(buf, pos)
+ tmp, pos = CommFunc.ReadString(buf, pos, self.ApplyIDLen)
+ self.ApplyIDList = ctypes.c_char_p(tmp)
+ self.Value1, pos = CommFunc.ReadDWORD(buf, pos)
+ self.Value2, pos = CommFunc.ReadDWORD(buf, pos)
+ self.Value3, pos = CommFunc.ReadDWORD(buf, pos)
+ self.Value4, pos = CommFunc.ReadDWORD(buf, pos)
+ self.Value5, pos = CommFunc.ReadDWORD(buf, pos)
+ return self.getLength()
+
+ def getBuffer(self):
+ buf = ''
+ buf = CommFunc.WriteDWORD(buf, self.TeamID)
+ buf = CommFunc.WriteString(buf, sizeof(ctypes.c_char) * 33, self.TeamName)
+ buf = CommFunc.WriteBYTE(buf, self.ZoneID)
+ buf = CommFunc.WriteDWORD(buf, self.FuncMapID)
+ buf = CommFunc.WriteDWORD(buf, self.FuncMapEx)
+ buf = CommFunc.WriteDWORD(buf, self.CreateTime)
+ buf = CommFunc.WriteDWORD(buf, self.CaptainID)
+ buf = CommFunc.WriteWORD(buf, self.MinLV)
+ buf = CommFunc.WriteDWORD(buf, self.MinFightPower)
+ buf = CommFunc.WriteDWORD(buf, self.MinFightPowerEx)
+ buf = CommFunc.WriteBYTE(buf, self.ServerOnly)
+ buf = CommFunc.WriteBYTE(buf, self.NeedCheck)
+ buf = CommFunc.WriteWORD(buf, self.ApplyIDLen)
+ buf = CommFunc.WriteString(buf, self.ApplyIDLen, self.ApplyIDList)
+ buf = CommFunc.WriteDWORD(buf, self.Value1)
+ buf = CommFunc.WriteDWORD(buf, self.Value2)
+ buf = CommFunc.WriteDWORD(buf, self.Value3)
+ buf = CommFunc.WriteDWORD(buf, self.Value4)
+ buf = CommFunc.WriteDWORD(buf, self.Value5)
+ return buf
+
+ def getLength(self):
+ length = 0
+ length += sizeof(ctypes.c_ulong)
+ length += sizeof(ctypes.c_char) * 33
+ length += sizeof(ctypes.c_ubyte)
+ length += sizeof(ctypes.c_ulong)
+ length += sizeof(ctypes.c_ulong)
+ length += sizeof(ctypes.c_ulong)
+ length += sizeof(ctypes.c_ulong)
+ length += sizeof(ctypes.c_ushort)
+ length += sizeof(ctypes.c_ulong)
+ length += sizeof(ctypes.c_ulong)
+ length += sizeof(ctypes.c_ubyte)
+ length += sizeof(ctypes.c_ubyte)
+ length += sizeof(ctypes.c_ushort)
+ length += self.ApplyIDLen
+ length += sizeof(ctypes.c_ulong)
+ length += sizeof(ctypes.c_ulong)
+ length += sizeof(ctypes.c_ulong)
+ length += sizeof(ctypes.c_ulong)
+ length += sizeof(ctypes.c_ulong)
+ return length
+
+ def outputString(self):
+ output = '''// 功能队伍表 #tagDBFuncTeam:
+ TeamID = %s,
+ TeamName = %s,
+ ZoneID = %s,
+ FuncMapID = %s,
+ FuncMapEx = %s,
+ CreateTime = %s,
+ CaptainID = %s,
+ MinLV = %s,
+ MinFightPower = %s,
+ MinFightPowerEx = %s,
+ ServerOnly = %s,
+ NeedCheck = %s,
+ ApplyIDLen = %s,
+ ApplyIDList = %s,
+ Value1 = %s,
+ Value2 = %s,
+ Value3 = %s,
+ Value4 = %s,
+ Value5 = %s,
+ ADOResult = %s,
+ '''%(
+ self.TeamID,
+ self.TeamName,
+ self.ZoneID,
+ self.FuncMapID,
+ self.FuncMapEx,
+ self.CreateTime,
+ self.CaptainID,
+ self.MinLV,
+ self.MinFightPower,
+ self.MinFightPowerEx,
+ self.ServerOnly,
+ self.NeedCheck,
+ self.ApplyIDLen,
+ self.ApplyIDList,
+ self.Value1,
+ self.Value2,
+ self.Value3,
+ self.Value4,
+ self.Value5,
+ self.ADOResult,
+ )
+ return output
+
+ #Char数组类型Set接口,使用该接口对此类型数据赋值,防止赋值的数据过长报错
+ def SetTeamName(self,Str):
+ if len(Str)<=33:
+ self.TeamName = Str
+ else:
+ self.TeamName = Str[:33]
+
+
+# 功能队伍成员表 #tagDBFuncTeamMem
+class tagDBFuncTeamMem(Structure):
+ _pack_ = 1
+ _fields_ = [
+ ('TeamID', ctypes.c_ulong),
+ ('PlayerID', ctypes.c_ulong),
+ ('Value1', ctypes.c_ulong),
+ ('Value2', ctypes.c_ulong),
+ ('Value3', ctypes.c_ulong),
+ ('Value4', ctypes.c_ulong),
+ ('Value5', ctypes.c_ulong),
+ ('ADOResult', ctypes.c_ulong),
+ ]
+
+ def __init__(self):
+ Structure.__init__(self)
+ self.clear()
+
+
+ def clear(self):
+ memset(addressof(self), 0, self.getLength())
+
+ def readData(self, buf, pos = 0, length = 0):
+ if not pos <= length:
+ return -1
+ if len(buf) < pos + self.getLength():
+ return -1
+ self.clear()
+ self.TeamID, pos = CommFunc.ReadDWORD(buf, pos)
+ self.PlayerID, pos = CommFunc.ReadDWORD(buf, pos)
+ self.Value1, pos = CommFunc.ReadDWORD(buf, pos)
+ self.Value2, pos = CommFunc.ReadDWORD(buf, pos)
+ self.Value3, pos = CommFunc.ReadDWORD(buf, pos)
+ self.Value4, pos = CommFunc.ReadDWORD(buf, pos)
+ self.Value5, pos = CommFunc.ReadDWORD(buf, pos)
+ return self.getLength()
+
+
+ def getBuffer(self):
+ buf = create_string_buffer(self.getLength())
+ memmove(addressof(buf), addressof(self), self.getLength())
+ return string_at(addressof(buf), self.getLength())
+
+ def getLength(self):
+ return sizeof(tagDBFuncTeamMem)
+
+ def outputString(self):
+ output = '''// 功能队伍成员表 #tagDBFuncTeamMem:
+ TeamID = %s,
+ PlayerID = %s,
+ Value1 = %s,
+ Value2 = %s,
+ Value3 = %s,
+ Value4 = %s,
+ Value5 = %s,
+ ADOResult = %s,
+ '''%(
+ self.TeamID,
+ self.PlayerID,
+ self.Value1,
+ self.Value2,
+ self.Value3,
+ self.Value4,
+ self.Value5,
+ self.ADOResult,
+ )
+ return output
+
+
#服务器世界数据表版本号
GAMEWORLD_DATA_VERSION_NO = ctypes.c_ulong (\
sizeof(tagDBEventTrig) + sizeof(tagDBFamily) + sizeof(tagDBFamilyMem) + sizeof(tagDBFamilyAction) +
sizeof(tagDBPlayerViewCache) + sizeof(tagDBMailPersonal) + sizeof(tagDBMailServer) + sizeof(tagDBMailItem) +
- sizeof(tagDBMailPlayerRec) + sizeof(tagDBBillboard) + sizeof(tagDBGameRec)
+ sizeof(tagDBMailPlayerRec) + sizeof(tagDBBillboard) + sizeof(tagDBGameRec) + sizeof(tagDBFuncTeam) + sizeof(tagDBFuncTeamMem)
).value
\ No newline at end of file
--
Gitblit v1.8.0