From 1cf37b4b51fc287ca3e443afb72604ec88f72cc4 Mon Sep 17 00:00:00 2001
From: hch <305670599@qq.com>
Date: 星期三, 09 七月 2025 19:33:55 +0800
Subject: [PATCH] 0312 玩家物品支持DWORD数量
---
PySysDB/生成IpyGameDataPY/IpyGameDataPYCreater.py | 14 ++++++++------
1 files changed, 8 insertions(+), 6 deletions(-)
diff --git "a/PySysDB/\347\224\237\346\210\220IpyGameDataPY/IpyGameDataPYCreater.py" "b/PySysDB/\347\224\237\346\210\220IpyGameDataPY/IpyGameDataPYCreater.py"
index 673f776..939cbb7 100644
--- "a/PySysDB/\347\224\237\346\210\220IpyGameDataPY/IpyGameDataPYCreater.py"
+++ "b/PySysDB/\347\224\237\346\210\220IpyGameDataPY/IpyGameDataPYCreater.py"
@@ -57,7 +57,7 @@
StructFileName = sys.argv[1]
if StructFileName == "PySysDBPY.h":
IpyGameDataPYFile = CodeProjectPath + "\\ZoneServerGroup\\map1_8G\\MapServer\\MapServerData\\Script\\"
- LoadStructPath = "ChConfig.GetDBPath()"
+ LoadStructPath = "ChConfig.GetServerConfigPath()"
elif StructFileName == "PySysDBG.h":
IpyGameDataPYFile = CodeProjectPath + "\\CoreServerGroup\\GameServer\\Script\\"
LoadStructPath = "ChConfig.GetAppPath()"
@@ -94,12 +94,14 @@
continue
if "struct" in line:
- tagIndex = line.index("tag")
+ line = line.strip()
if "{" in line:
- tableName = line[tagIndex + 3:line.index("{")]
+ tableName = line[6:line.index("{")]
else:
- tableName = line[tagIndex + 3:]
- tableName = tableName.replace(" ", "") # 表名英文名
+ tableName = line[6:]
+ tableName = tableName.replace("\t", "").replace(" ", "") # 表名英文名
+ if tableName.startswith("tag"):
+ tableName = tableName[3:]
continue
noteInfo = " #" # 字段注释说明
@@ -115,7 +117,7 @@
if not fieldType:
if "struct" not in line and "{" not in line and "}" not in line:
print "### 类型定义错误表 ###"
- print "struct tag%s" % tableName
+ print "struct %s" % tableName
print line
raise
continue
--
Gitblit v1.8.0