| | |
| | | # @param mergeMapInfo 该提示所属的跨服活动地图信息, 主要用于不同子服对应所跨的活动地图ID
|
| | | # @return 无返回值
|
| | | def WorldNotify(country, msgMark, msgParamList=[], lineID=0, mergeMinOSD=-1, mergeMaxOSD=-1, mergeMapInfo=[]):
|
| | | # 如果是跨服服务器,则广播子服
|
| | | if GameWorld.IsCrossServer():
|
| | | sendMsg = str([country, msgMark, msgParamList, lineID, mergeMinOSD, mergeMaxOSD, mergeMapInfo])
|
| | | GameWorld.GetPlayerManager().GameServer_QueryPlayerResult(0, 0, 0, 'MergeWorldNotify',
|
| | | sendMsg, len(sendMsg))
|
| | | FBNotify(msgMark, msgParamList) # 跨服中的全服广播只在地图中做广播即可,防止不同跨服分区的地图会相互看到广播,体验不好
|
| | | else:
|
| | | GameWorld.GetPlayerManager().BroadcastCountry_NotifyCode(country, 0, msgMark,
|
| | | __GetNotifyCodeList(msgParamList), lineID)
|
| | | GameWorld.GetPlayerManager().BroadcastCountry_NotifyCode(country, 0, msgMark, __GetNotifyCodeList(msgParamList), lineID)
|
| | | return
|
| | |
|
| | | def GetCrossWorldNotifyInfo(country, msgMark, msgParamList=[]):
|
| | | return {"Type":ShareDefine.CrossNotify_World, "Params":[country, msgMark, msgParamList]}
|
| | |
|
| | | def GetCrossFamilyNotifyInfo(familyID, msgMark, msgParamList=[]):
|
| | | return {"Type":ShareDefine.CrossNotify_Family, "Params":[familyID, msgMark, msgParamList]}
|
| | |
|
| | | def CrossNotify(serverGroupIDList, crossNotifyList):
|
| | | ''' 跨服广播信息提示,支持同步多条,同时也建议多条一起同步
|
| | | @param serverGroupIDList: 需要同步到的目标服务器组ID列表
|
| | | @param crossNotifyList: 信息提示列表,通过 GetCrossWorldNotifyInfo GetCrossFamilyNotifyInfo 函数获得返回值添加到列表
|
| | | '''
|
| | | sendMsg = str([serverGroupIDList, crossNotifyList])
|
| | | GameWorld.GetPlayerManager().GameServer_QueryPlayerResult(0, 0, 0, "CrossNotify", sendMsg, len(sendMsg))
|
| | | return
|
| | |
|
| | | #---------------------------------------------------------------------
|