From 2cf5365a5e409b38bba122f9bd1b0a6bd217c1c0 Mon Sep 17 00:00:00 2001
From: hxp <ale99527@vip.qq.com>
Date: 星期四, 03 七月 2025 17:57:30 +0800
Subject: [PATCH] 16 卡牌服务端(删除无用的GY_Query_Offline_xxx命令)
---
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/DB/StructData/DBMail.py | 19 +++++++++++++++++++
1 files changed, 19 insertions(+), 0 deletions(-)
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/DB/StructData/DBMail.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/DB/StructData/DBMail.py
index 561d085..f86f89c 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/DB/StructData/DBMail.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/DB/StructData/DBMail.py
@@ -254,13 +254,32 @@
itemObj = MailItem()
return itemObj
+ def GetMailItemList(self, guid):
+ if guid not in self.__mailItemDict:
+ return []
+ itemList = []
+ for mailItem in self.__mailItemDict[guid]:
+ itemID = mailItem.GetItemID()
+ itemCount = mailItem.GetCount()
+ isBind = mailItem.GetIsBind()
+ userData = mailItem.GetUserData()
+ itemInfo = [itemID, itemCount, isBind]
+ if userData:
+ itemInfo.append(userData)
+ itemList.append(itemInfo)
+ return itemList
+
def AddServerMail(self, guid, title, text, itemList, limitDays=7, mailType=0):
'''添加个人邮件
@param guid: 指定的邮件guid,为空时自动生成新guid
@param itemList: 元素支持字典{k:v, ...} 或列表 [itemID, itemCount, 可选是否拍品, 物品UserData]
'''
+ mailObj = None
if not guid:
guid = GameWorld.GetGUID()
+ if guid in self.__serverMailDict:
+ # 已经存在的guid不允许重复插入全服邮件,防止多领取,后台发送全服邮件时如果重复推送到某个服务器就可能存在重复情况
+ return mailObj
dbData = DBStruct.tagDBMailServer()
dbData.GUID = guid
dbData.Type = mailType
--
Gitblit v1.8.0