From 2c7e84a1640472409d81aff4aa991441b810212d Mon Sep 17 00:00:00 2001
From: hxp <ale99527@vip.qq.com>
Date: 星期一, 22 七月 2024 18:43:24 +0800
Subject: [PATCH] 10223 【越南】【砍树】【主干】【港台】秘境寻宝(修复每X次必出配0时寻宝报错;)

---
 ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerTreasure.py |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerTreasure.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerTreasure.py
index 9f0472a..c17c965 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerTreasure.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerTreasure.py
@@ -207,7 +207,7 @@
                 gridNumRateList = beSureCountDict[updTreasureCount]
                 gridNum = GameWorld.GetResultByRandomList(gridNumRateList)
                 GameWorld.DebugLog("到达次数必出,updTreasureCount=%s,gridNumRateList=%s,gridNum=%s" % (updTreasureCount, gridNumRateList, gridNum), playerID)
-            elif updTreasureCount % ensureCount == 0 and ensureRateList:
+            elif ensureCount and updTreasureCount % ensureCount == 0 and ensureRateList:
                 gridNumRateList = ensureRateList
                 gridNum = GameWorld.GetResultByRandomList(gridNumRateList)
                 GameWorld.DebugLog("满次数保底出,updTreasureCount=%s,gridNumRateList=%s,gridNum=%s" % (updTreasureCount, gridNumRateList, gridNum), playerID)
@@ -231,7 +231,7 @@
                 
         # 3. 次数保底
         ensureGridNumList = []
-        if updTreasureCount / ensureCount > curTreasureCount / ensureCount and ensureRateList:
+        if ensureCount and updTreasureCount / ensureCount > curTreasureCount / ensureCount and ensureRateList:
             for gridInfo in ensureRateList:
                 ensureGridNumList.append(gridInfo[1])
             gridNum = GameWorld.GetResultByRandomList(ensureRateList)

--
Gitblit v1.8.0