From 88effa2034b78c46426b2e7f7924a9493da9af4f Mon Sep 17 00:00:00 2001
From: xdh <xiefantasy@qq.com>
Date: 星期一, 03 十二月 2018 16:22:15 +0800
Subject: [PATCH] 5161 子 【1.3.100】修复在仙盟任务副本中退出仙盟还能继续任务的BUG

---
 ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBProcess/GameLogic_ClearDevil.py |   18 +++++++++++++++++-
 1 files changed, 17 insertions(+), 1 deletions(-)

diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBProcess/GameLogic_ClearDevil.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBProcess/GameLogic_ClearDevil.py
index b678f1d..49bb331 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBProcess/GameLogic_ClearDevil.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBProcess/GameLogic_ClearDevil.py
@@ -26,6 +26,7 @@
 import ShareDefine
 import EventReport
 import PlayerControl
+import QuestCommon
 
 
 #---副本配置对应key值---
@@ -57,6 +58,7 @@
 ) = range(5)
 
 FBPlayerDict_MissionID = 'FBPlayerDict_MissionID'   #副本任务ID
+FBPlayerDict_MissionType = 'FBPlayerDict_MissionType'   #副本任务类型
 FBPlayerDict_CostTime = 'FBPlayerDict_CostTime'   #副本耗时
 FBPlayerDict_TotalPoint = 'FBPlayerDict_TotalPoint'   # 获得的总积分
 FBPlayerDict_NPCRemainCnt = 'FBPlayerDict_NPCRemainCnt_%s'   # NPC剩余数量
@@ -140,8 +142,11 @@
     
     fbMissionID = curPlayer.NomalDictGetProperty(ChConfig.Def_Player_Dict_ReqFBMissionID)
     if fbMissionID:
+        fbMissionType = curPlayer.NomalDictGetProperty(ChConfig.Def_Player_Dict_ReqFBMissionType)
         gameFB.SetGameFBDict(FBPlayerDict_MissionID, fbMissionID)
+        gameFB.SetGameFBDict(FBPlayerDict_MissionType, fbMissionType)
         PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_Player_Dict_ReqFBMissionID, 0)
+        PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_Player_Dict_ReqFBMissionType, 0)
     
     fbStep = gameFB.GetFBStep()
     if fbStep < FB_Step_Prepare:
@@ -395,6 +400,16 @@
     
     return
 
+##玩家退出家族处理
+# @param curPlayer 玩家实例
+# @param tick 时间戳
+# @return 返回值无意义
+def OnLeaveFamily(curPlayer, tick):
+    gameFB = GameWorld.GetGameFB()
+    fbMissionType = gameFB.GetGameFBDictByKey(FBPlayerDict_MissionType)
+    if fbMissionType == QuestCommon.Def_Mission_Type_RunFamily:
+        gameFB.SetGameFBDict(FBPlayerDict_MissionType, 0)
+    return
 
 ## 任务专用,触发事件(副本内完成某任务)
 #  @param curPlayer:玩家实例
@@ -473,8 +488,9 @@
     costTime = tick - GameWorld.GetGameFB().GetFBStepTick()
     gameFB.SetGameFBDict(FBPlayerDict_CostTime, costTime)
     fbMissionID = gameFB.GetGameFBDictByKey(FBPlayerDict_MissionID)
+    fbMissionType = gameFB.GetGameFBDictByKey(FBPlayerDict_MissionType)
     # 通知结果 此处只通知失败,成功在完成任务时通知, 不是通过任务进的副本也通知
-    if not isPass or not fbMissionID:
+    if not isPass or not fbMissionID or not fbMissionType:
         __SendOverInfo(curPlayer, {FBCommon.Over_isPass:int(isPass), FBCommon.Over_exp:exp,FBCommon.Over_expPoint:expPoint, FBCommon.Over_costTime:costTime})
     
     # 进入离开阶段

--
Gitblit v1.8.0