From c67a2d59e881e3d1df1a4142983e76e8fb5db24a Mon Sep 17 00:00:00 2001
From: hxp <ale99527@vip.qq.com>
Date: 星期五, 28 十二月 2018 21:26:28 +0800
Subject: [PATCH] 5424 【后端】【1.4】跨服竞技场开发(匹配规则优化,优先匹配同段位的,同段位不足两个人的支持按段位区间匹配)
---
ServerPython/CoreServerGroup/GameServer/Script/GameWorldLogic/GameWorldBoss.py | 26 +++++++++++++++-----------
1 files changed, 15 insertions(+), 11 deletions(-)
diff --git a/ServerPython/CoreServerGroup/GameServer/Script/GameWorldLogic/GameWorldBoss.py b/ServerPython/CoreServerGroup/GameServer/Script/GameWorldLogic/GameWorldBoss.py
index 848c439..c1fae3c 100644
--- a/ServerPython/CoreServerGroup/GameServer/Script/GameWorldLogic/GameWorldBoss.py
+++ b/ServerPython/CoreServerGroup/GameServer/Script/GameWorldLogic/GameWorldBoss.py
@@ -38,7 +38,6 @@
import PlayerUniversalGameRec
import PlayerCompensation
import IpyGameDataPY
-import MergePlayer
import PyGameDataStruct
import PyDataManager
import PlayerControl
@@ -306,6 +305,20 @@
#
# return
+#// A9 04 查询boss信息 #tagCGQueryBossInfo
+#
+#
+#struct tagCGQueryBossInfo
+#{
+# tagHead Head;
+# BYTE Count; //数量
+# DWORD BossIDList[Count]; //boosid
+#};
+def OnQueryBossInfo(index, clientData, tick):
+ curPlayer = GameWorld.GetPlayerManager().GetPlayerByIndex(index)
+ bossIDList = clientData.BossIDList
+ Sync_BossInfo(curPlayer, bossIDList)
+ return
## 同步boss相关信息
@@ -566,15 +579,6 @@
if lvLimit[0] <= findLV <= lvLimit[1]:
playerCntDict[bossid] = playerCntDict.get(bossid, 0) + 1
GameWorld.DebugLog(' boss等级信息对应本服在线人数 %s' % playerCntDict)
-
- # 此处需要统计累加当前在跨服服务器的玩家
- mergeServerOnlinePlayerDict = MergePlayer.GetMergeServerOnlinePlayerInfo()
- for playerInfo in mergeServerOnlinePlayerDict.values():
- findLV = playerInfo[MergePlayer.Def_MSOLPlayer_LV]
- for bossid, lvLimit in bossRebornDict.items():
- if lvLimit[0] <= findLV <= lvLimit[1]:
- playerCntDict[bossid] = playerCntDict.get(bossid, 0) + 1
- GameWorld.DebugLog(' boss等级信息对应本服及跨服在线人数 %s' % playerCntDict)
for bossid, curOnlineCnt in playerCntDict.items():
SetBossOnlineHeroCnt(bossid, curOnlineCnt)
@@ -1217,6 +1221,6 @@
if curMember.GetFamilyLV() == IPY_GameServer.fmlMember:
GameWorld.DebugLog("普通成员无法召集!", playerID)
return
- PlayerControl.FamilyNotify(curFamily.GetID(), "FairyGrabBossHelp", [npcID])
+ PlayerControl.FamilyNotify(curFamily.GetID(), "FairyGrabBossHelp", [curPlayer.GetName(), npcID])
return
--
Gitblit v1.8.0