From 208eb0a5fe8c46a3e8490db184a93eaf57edac10 Mon Sep 17 00:00:00 2001
From: hxp <ale99527@vip.qq.com>
Date: 星期三, 28 十一月 2018 15:44:45 +0800
Subject: [PATCH] 4762 【后端】修复选择助战机器人阶段掉线重上时,刷新次数会重置的bug;

---
 ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBProcess/FBHelpBattle.py |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBProcess/FBHelpBattle.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBProcess/FBHelpBattle.py
index 7ef3fa7..d9487de 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBProcess/FBHelpBattle.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBProcess/FBHelpBattle.py
@@ -296,8 +296,8 @@
     costMoneyList = []
     calledPlayerIDDict = {} # 已经召唤的玩家ID字典 {playerID:[是否付费召唤, 职业], ...}
     
+    refreshCount = gameFB.GetPlayerGameFBDictByKey(playerID, ChConfig.FBPD_HelpBattleRefreshCount)
     if isClientRefresh:
-        refreshCount = gameFB.GetPlayerGameFBDictByKey(playerID, ChConfig.FBPD_HelpBattleRefreshCount)
         freeRefreshCount = IpyGameDataPY.GetFuncCfg("HelpBattleRefresh", 1)
         goldRefreshCount = IpyGameDataPY.GetFuncCfg("HelpBattleRefresh", 2)
         if refreshCount >= (freeRefreshCount + goldRefreshCount):
@@ -324,7 +324,8 @@
             
     # 非客户端刷新的视为重新开始,重置刷新次数 
     else:
-        gameFB.SetPlayerGameFBDict(playerID, ChConfig.FBPD_HelpBattleRefreshCount, 0)
+        if not refreshCount:
+            gameFB.SetPlayerGameFBDict(playerID, ChConfig.FBPD_HelpBattleRefreshCount, 0)
         gameFB.SetGameFBDict(ChConfig.FBPD_HelpBattleFBFightPower, ipyData.GetFightPowerMin())
         gameFB.SetGameFBDict(ChConfig.FBPD_HelpBattleFBBaseHurt, ipyData.GetRobotBaseHurt())
         GameWorld.DebugLog("设置副本战力=%s,保底伤害=%s" % (ipyData.GetFightPowerMin(), ipyData.GetRobotBaseHurt()))

--
Gitblit v1.8.0