From 953010961dcae20f32cf41c55c029d7c76b1fee8 Mon Sep 17 00:00:00 2001
From: hxp <ale99527@vip.qq.com>
Date: 星期四, 12 八月 2021 11:41:59 +0800
Subject: [PATCH] 8585 【BT3】【主干】竞技场(机器人最大等级公式改为参数改为世界等级; 匹配机器人等级优化为按机器人的最低等级减10到机器人最低等级区间随机)
---
ServerPython/CoreServerGroup/GameServer/Script/GameWorldLogic/GameWorldArena.py | 36 +++++++++---------------------------
1 files changed, 9 insertions(+), 27 deletions(-)
diff --git a/ServerPython/CoreServerGroup/GameServer/Script/GameWorldLogic/GameWorldArena.py b/ServerPython/CoreServerGroup/GameServer/Script/GameWorldLogic/GameWorldArena.py
index a8b5747..a623f65 100644
--- a/ServerPython/CoreServerGroup/GameServer/Script/GameWorldLogic/GameWorldArena.py
+++ b/ServerPython/CoreServerGroup/GameServer/Script/GameWorldLogic/GameWorldArena.py
@@ -270,6 +270,7 @@
# 删除对战记录
GameWorld.GetUniversalRecMgr().Delete(Def_RecType_ArenaBattleRecord)
PyGameData.g_arenaPlayerBattleRecDict = {}
+ PyGameData.g_arenaPlayerMatchDict = {}
# 更新新赛季信息
if openServerDay <= customMaxServerDay and OSSeasonState == 0:
@@ -374,30 +375,11 @@
def __GetRobotLVRange():
## 获取赛季机器人等级范围
worldLV = max(1, PlayerDBGSEvent.GetDBGSTrig_ByKey(ShareDefine.Def_Notify_WorldKey_WorldAverageLv))
- ipyDataMgr = IpyGameDataPY.IPY_Data()
- maxCnt = ipyDataMgr.GetWorldLVCount()
- worldLVTime = 0
- if worldLV <= maxCnt:
- worldLVIpyData = ipyDataMgr.GetWorldLVByIndex(worldLV - 1)
- worldLVTime = worldLVIpyData.GetOpenServerSecond()
-
minLV, maxLV = IpyGameDataPY.GetFuncEvalCfg("ArenaRobot", 2) # 机器人最小、最大等级
-
- robotMaxLV = minLV
- maxWorldLVTime = eval(IpyGameDataPY.GetFuncCfg("ArenaRobot", 3))
- for i in xrange(worldLV - 1, maxCnt):
- ipyData = ipyDataMgr.GetWorldLVByIndex(i)
- if i == maxCnt - 1:
- robotMaxLV = ipyData.GetWorldLV()
- else:
- nextIpyData = IpyGameDataPY.IPY_Data().GetWorldLVByIndex(i + 1)
- if ipyData.GetOpenServerSecond() <= maxWorldLVTime < nextIpyData.GetOpenServerSecond():
- robotMaxLV = ipyData.GetWorldLV()
- break
-
+ robotMaxLV = eval(IpyGameDataPY.GetFuncCfg("ArenaRobot", 3))
robotMaxLV = max(minLV, min(maxLV, robotMaxLV))
- GameWorld.Log(" 机器人等级范围: worldLV=%s,worldLVTime=%s,maxWorldLVTime=%s,minLV=%s,robotMaxLV=%s"
- % (worldLV, worldLVTime, maxWorldLVTime, minLV, robotMaxLV))
+ GameWorld.Log(" 机器人等级范围: worldLV=%s,minLV=%s,maxLV=%s,robotMaxLV=%s"
+ % (worldLV, minLV, maxLV, robotMaxLV))
return minLV, robotMaxLV
def __RandRobotScoreList(robotMaxCount):
@@ -675,12 +657,12 @@
# 随机机器人备用信息
openJobList = IpyGameDataPY.GetFuncEvalCfg("OpenJob", 1)
- randRobotLVScorePerInfo = IpyGameDataPY.GetFuncEvalCfg("ArenaMatch", 3)
- randRobotLVPerRange, randRobotScorePerRange = randRobotLVScorePerInfo
- minLV, maxLV = IpyGameDataPY.GetFuncEvalCfg("ArenaRobot", 2) # 机器人最小、最大等级
- randMinLV = min(minLV, int(playerLV * randRobotLVPerRange[0] / 100.0))
- randMaxLV = min(maxLV, int(playerLV * randRobotLVPerRange[1] / 100.0))
+ minLV, _ = IpyGameDataPY.GetFuncEvalCfg("ArenaRobot", 2) # 机器人最小、最大等级
+ randMinLV, randMaxLV = minLV - 10, minLV
+ #randMinLV = min(minLV, int(playerLV * randRobotLVPerRange[0] / 100.0))
+ #randMaxLV = min(maxLV, int(playerLV * randRobotLVPerRange[1] / 100.0))
+ randRobotScorePerRange = IpyGameDataPY.GetFuncEvalCfg("ArenaMatch", 3)
randMinScore = int(playerScore * randRobotScorePerRange[0] / 100.0)
randMaxScore = int(playerScore * randRobotScorePerRange[1] / 100.0)
--
Gitblit v1.8.0