From ce9190555eb8ba098d25632fdea39ae198cad599 Mon Sep 17 00:00:00 2001
From: hxp <ale99527@vip.qq.com>
Date: 星期四, 12 三月 2020 23:50:35 +0800
Subject: [PATCH] 8401 【后端】BOSS复活修改(增加活跃修炼完成事件16;宝箱支持动态开出玩家当前解锁的最大境界装备)
---
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Item/UseItem/Item_Chests.py | 6 ++++++
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Item/ChEquip.py | 37 +++++++++++++++++++++++++++++++++++++
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerActivity.py | 3 +++
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChConfig.py | 3 ++-
4 files changed, 48 insertions(+), 1 deletions(-)
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChConfig.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChConfig.py
index 224bf86..2da3418 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChConfig.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChConfig.py
@@ -5326,7 +5326,8 @@
Def_BRAct_RuneTreasure, #符印寻宝 13
Def_BRAct_FairyDomain, #缥缈仙域 14
Def_BRAct_FamilyBoss, #仙盟BOSS 15
-) = range(1, 15+1)
+Def_BRAct_ActivityPlace, #活跃放置 16
+) = range(1, 16+1)
#全民来嗨活动定义(仙界盛典)
PeoplePartyActIDList = (
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Item/ChEquip.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Item/ChEquip.py
index 777be72..3b459b6 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Item/ChEquip.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Item/ChEquip.py
@@ -1394,6 +1394,43 @@
curPlayer.SetEquipShowSwitch(updEquipShowSwitch)
return
+def GetPlayerMaxEquipClassLV(curPlayer):
+ ## 获取玩家当前解锁的装备阶
+ key = "RealmEquipClassLVMap"
+ RealmEquipClassLVMap = IpyGameDataPY.GetConfigEx(key)
+ if not RealmEquipClassLVMap:
+ RealmEquipClassLVMap = {}
+ infoDict = {}
+ ipyDataMgr = IpyGameDataPY.IPY_Data()
+ for index in xrange(ipyDataMgr.GetEquipControlCount()):
+ ipyData = ipyDataMgr.GetEquipControlByIndex(index)
+ infoDict[ipyData.GetNeedRealmLV()] = ipyData.GetClassLV()
+ needReamlLVList = infoDict.keys()
+ needReamlLVList.sort() # 升序排
+ for i, realmLV in enumerate(needReamlLVList):
+ classLV = infoDict[realmLV]
+ if i == len(needReamlLVList) - 1:
+ RealmEquipClassLVMap[realmLV] = classLV
+ if i == 0:
+ continue
+ else:
+ preRealmLV = needReamlLVList[i - 1]
+ preClassLV = infoDict[preRealmLV]
+ for pRealmLV in range(preRealmLV, realmLV):
+ RealmEquipClassLVMap[pRealmLV] = preClassLV
+ GameWorld.DebugLog("加载境界对应开放最大装备阶设置: %s" % RealmEquipClassLVMap)
+ IpyGameDataPY.SetConfigEx(key, RealmEquipClassLVMap)
+
+ playerRealmLV = curPlayer.GetOfficialRank()
+ if playerRealmLV in RealmEquipClassLVMap:
+ return RealmEquipClassLVMap[playerRealmLV]
+
+ maxRealmLV = max(RealmEquipClassLVMap)
+ if playerRealmLV >= maxRealmLV:
+ return RealmEquipClassLVMap[maxRealmLV]
+
+ return 0
+
#获取当前是第几套装备外观
def GetEquipFacadeClassLV(curPlayer):return curPlayer.GetEquipShowSwitch()%1000/10
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Item/UseItem/Item_Chests.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Item/UseItem/Item_Chests.py
index cefa863..27a7a75 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Item/UseItem/Item_Chests.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Item/UseItem/Item_Chests.py
@@ -25,6 +25,7 @@
import PlayerRune
import NPCCommon
import ChConfig
+import ChEquip
import ChItem
import random
@@ -351,6 +352,11 @@
if not placeList:
GameWorld.ErrLog("部位集合key不存在!chestsItemID=%s,placeKey=%s" % (chestsItemID, placeKey))
continue
+ # 未指定,默认取当前解锁的最大境界装备阶
+ if classLV == 0:
+ classLV = ChEquip.GetPlayerMaxEquipClassLV(curPlayer)
+ GameWorld.DebugLog(" 未指定装备阶,默认取玩家当前解锁的最大阶: classLV=%s" % classLV)
+
randEquipIDList = NPCCommon.__GetEquipIDList(chestsItemID, classLV, color, isSuit, placeList, itemJobList, findType="ChestsItem")
if not randEquipIDList:
continue
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerActivity.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerActivity.py
index e077b0d..c994ea8 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerActivity.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerActivity.py
@@ -35,6 +35,7 @@
import datetime
import time
import FormulaControl
+import PlayerBossReborn
#关联类型
(
@@ -899,6 +900,8 @@
EventShell.EventRespons_ActivityPlace(curPlayer, "cangetreward")
Sync_ActivityPlaceInfo(curPlayer)
+
+ PlayerBossReborn.AddBossRebornActionCnt(curPlayer, ChConfig.Def_BRAct_ActivityPlace, endCount)
return
def GetActivityPlaceReward(curPlayer):
--
Gitblit v1.8.0