From c2f66e6ffcc1bfa9b919c92bfee8729158ac5426 Mon Sep 17 00:00:00 2001
From: hxp <ale99527@vip.qq.com>
Date: 星期三, 19 九月 2018 14:44:23 +0800
Subject: [PATCH] 3681 【后端】神兽基础战斗力
---
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerBossReborn.py | 27 +++++++++++++++++++--------
1 files changed, 19 insertions(+), 8 deletions(-)
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerBossReborn.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerBossReborn.py
index b73e56f..fb1100f 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerBossReborn.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerBossReborn.py
@@ -59,6 +59,7 @@
actBossRebornInfo = PyGameData.g_operationActionDict.get(ShareDefine.OperationActionName_BossReborn, {})
bossRebornID = actBossRebornInfo.get(ShareDefine.ActKey_ID, 0)
state = actBossRebornInfo.get(ShareDefine.ActKey_State, 0)
+ cfgID = actBossRebornInfo.get(ShareDefine.ActKey_CfgID, 0)
playerBossRebornID = curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_BossRebornID) # 玩家身上的活动ID
@@ -66,7 +67,11 @@
if bossRebornID == playerBossRebornID:
#GameWorld.DebugLog("BOSS复活活动ID不变,不处理!", curPlayer.GetPlayerID())
return
- templateID = actBossRebornInfo.get(ShareDefine.ActKey_TemplateID, 0)
+
+ templateID = 0
+ if cfgID:
+ actBossIpyData = IpyGameDataPY.GetIpyGameData("ActBossReborn", cfgID)
+ templateID = 0 if not actBossIpyData else actBossIpyData.GetTemplateID()
playerTemplateID = curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_BossRebornTemplateID)
GameWorld.DebugLog("BOSS复活重置! costRebateID=%s,playerCostRebateID=%s,state=%s,templateID=%s,playerTemplateID=%s"
@@ -120,7 +125,8 @@
state = actBossRebornInfo.get(ShareDefine.ActKey_State, 0)
if not state:
return
- ipyData = IpyGameDataPY.GetIpyGameData('BossReborn', actionID)
+ playerTemplateID = curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_BossRebornTemplateID)
+ ipyData = IpyGameDataPY.GetIpyGameData('BossReborn', playerTemplateID, actionID)
if not ipyData:
return
totalTimes = ipyData.GetTotalTimes()
@@ -168,7 +174,7 @@
def __GetAwardItem(curPlayer, ipyData, times=1):
awardDict = {}
- for itemID, itemCnt, isbind in ipyData.GetAward():
+ for itemID, itemCnt, isbind in ipyData.GetReward():
if not itemID or not itemCnt:
continue
awardDict[itemID] = awardDict.get(itemID, 0) + itemCnt * times
@@ -206,9 +212,13 @@
def SyncBossRebornInfo(curPlayer):
actBossRebornInfo = PyGameData.g_operationActionDict.get(ShareDefine.OperationActionName_BossReborn, {})
state = actBossRebornInfo.get(ShareDefine.ActKey_State, 0)
- if not state:
+ cfgID = actBossRebornInfo.get(ShareDefine.ActKey_CfgID, 0)
+ if not state or not cfgID:
return
- templateID = actBossRebornInfo.get(ShareDefine.ActKey_TemplateID, 0)
+ actBossIpyData = IpyGameDataPY.GetIpyGameData("ActBossReborn", cfgID)
+ if not actBossIpyData:
+ return
+ templateID = actBossIpyData.GetTemplateID()
if not templateID:
return
ipyDataList = IpyGameDataPY.GetIpyGameDataByCondition("BossReborn", {'TemplateID':templateID}, True)
@@ -216,9 +226,10 @@
return
actInfo = ChPyNetSendPack.tagMCBossRebornInfo()
actInfo.Clear()
- actInfo.StartDate = actBossRebornInfo.get(ShareDefine.ActKey_StartDate, "")
- actInfo.EndtDate = actBossRebornInfo.get(ShareDefine.ActKey_EndDate, "")
- actInfo.LimitLV = actBossRebornInfo.get(ShareDefine.ActKey_LVLimit, 0)
+ actInfo.StartDate = actBossIpyData.GetStartDate()
+ actInfo.EndtDate = actBossIpyData.GetEndDate()
+ actInfo.ResetType = actBossIpyData.GetResetType()
+ actInfo.LimitLV = actBossIpyData.GetLVLimit()
actInfo.TaskInfo = []
for ipyData in ipyDataList:
taskInfo = ChPyNetSendPack.tagMCBossRebornTaskInfo()
--
Gitblit v1.8.0