From 0494d4903383737139445b11e525a9e2ca583801 Mon Sep 17 00:00:00 2001
From: xdh <xiefantasy@qq.com>
Date: 星期四, 21 二月 2019 16:47:35 +0800
Subject: [PATCH] 6268 【后端】【1.6.100】增加道具七日巡礼积分和节日巡礼积分支持

---
 ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Event/EventSrc/FunctionNPCCommon.py |   10 +++++++---
 1 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Event/EventSrc/FunctionNPCCommon.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Event/EventSrc/FunctionNPCCommon.py
index 8b756d8..2573564 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Event/EventSrc/FunctionNPCCommon.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Event/EventSrc/FunctionNPCCommon.py
@@ -260,16 +260,20 @@
     ResetShopItemBuyCount(curPlayer, [refreshType])
     return
 
-def ResetShopItemBuyCount(curPlayer, onEventTypeList=[]):
-    #@param onEventTypeList: 需要重置的类型列表,为空时重置所有类型
+def ResetShopItemBuyCount(curPlayer, resetTypeList):
+    #@param resetTypeList: 需要重置的类型列表
     #重置商店物品购买次数  1:周一0点刷新    2:周一5点刷新    3:每日0点刷新    4:每日5点刷新    5每月0点    6每月5点   7每3天5点  8每赛季
+    if not resetTypeList:
+        # 暂定必须指定类型列表,防止终身限购的误被重置
+        return
+    
     syncIndexList = []
     ipyDataMgr = IpyGameDataPY.IPY_Data()
     for i in xrange(ipyDataMgr.GetStoreCount()):
         shopItem = ipyDataMgr.GetStoreByIndex(i)
         if not shopItem.GetLimitCnt():
             continue
-        if onEventTypeList and shopItem.GetRefreshType() not in onEventTypeList:
+        if shopItem.GetRefreshType() not in resetTypeList:
             continue
         dayBuyCntKey = ChConfig.Def_PDict_ShopItemDayBuyCnt % shopItem.GetID()
         curDayBuyCnt = curPlayer.NomalDictGetProperty(dayBuyCntKey)

--
Gitblit v1.8.0