From 3475d7857f59be1f61c2e928d425e9a7b2526fae Mon Sep 17 00:00:00 2001 From: hxp <ale99527@vip.qq.com> Date: 星期一, 22 四月 2019 11:29:56 +0800 Subject: [PATCH] 6459 【后端】【2.0】缥缈仙域开发单(跨服动态分配线路上线优化,踢出与当前线路分区或功能线路属性不一致的玩家,防止玩家跨服中重新上线后进入到不同功能线路的问题) --- ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBLogic.py | 17 +++++++++++++++++ 1 files changed, 17 insertions(+), 0 deletions(-) diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBLogic.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBLogic.py index 8706cdf..e2a5eeb 100644 --- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBLogic.py +++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBLogic.py @@ -18,6 +18,7 @@ import IPY_GameWorld import PlayerControl import GameWorldProcess +import CrossRealmPlayer import PlayerSuccess import ReadChConfig import ShareDefine @@ -484,6 +485,22 @@ def DoEnterFBLogic(curPlayer, tick): curPlayerID = curPlayer.GetID() + if GameWorld.IsCrossServer(): + mapID = GameWorld.GetMap().GetMapID() + mapID = FBCommon.GetRecordMapID(mapID) + if mapID in ChConfig.Def_CrossDynamicLineMap: + fbZoneID = FBCommon.GetCrossDynamicLineMapZoneID() + fbFuncLineID = FBCommon.GetCrossDynamicLineMapFuncLineID() + playerZoneID = curPlayer.NomalDictGetProperty(ChConfig.Def_Player_Dict_ReqCrossFBZoneID) + playerFuncLineID = curPlayer.NomalDictGetProperty(ChConfig.Def_Player_Dict_ReqCrossFBFuncLine) + if fbZoneID != playerZoneID or fbFuncLineID != playerFuncLineID: + GameWorld.ErrLog("DoEnterFB 玩家与当前副本线路所属分区或功能分线不同,踢出玩家!fbZoneID=%s,playerZoneID=%s,fbFuncLineID=%s,playerFuncLineID=%s" + % (fbZoneID, playerZoneID, fbFuncLineID, playerFuncLineID), curPlayerID) + CrossRealmPlayer.PlayerExitCrossServer(curPlayer) + return + GameWorld.Log("玩家进入跨服副本动态分配的线路: fbZoneID=%s,playerZoneID=%s,fbFuncLineID=%s,playerFuncLineID=%s" + % (fbZoneID, playerZoneID, fbFuncLineID, playerFuncLineID), curPlayerID) + # 自伸缩副本根据玩家进入开启,主动调用一次,避免间隔调用时机未触发导致逻辑错乱 GameWorldProcess.EnterOpenFB(tick) -- Gitblit v1.8.0