| | |
| | | GameWorld.Log("仙匣秘境发送GameServer: %s, %s" % (msgType, dataMsg), playerID)
|
| | | return
|
| | |
|
| | | def AddPlayerLotteryScore(curPlayer, actNum, addScore):
|
| | | def AddPlayerLotteryScore(curPlayer, actNum, addScore, isRelationCrossAct):
|
| | | if addScore <= 0:
|
| | | return 0
|
| | | lotteryScore = curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_XianXiaMJScore % actNum)
|
| | | updLotteryScore = lotteryScore + addScore
|
| | | PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_PDict_XianXiaMJScore % actNum, updLotteryScore)
|
| | | PlayerBillboard.UpdatePlayerBillboard(curPlayer, ShareDefine.Def_BT_XianXiaMJScore, updLotteryScore, autoSort=True)
|
| | | SendToGameServer_XianXiaMJ(curPlayer, "AddLotteryScore", [addScore, updLotteryScore])
|
| | | SendToGameServer_XianXiaMJ(curPlayer, "AddLotteryScore", [addScore, updLotteryScore, isRelationCrossAct])
|
| | | return updLotteryScore
|
| | |
|
| | | def GetLayerSetByList(layerNum, setList):
|
| | |
| | | GameWorld.DebugLog(" 刷新完成! layerNum=%s,playCount=%s" % (layerNum, playCount))
|
| | | PlayerActTask.UpdActTaskValue(curPlayer, ChConfig.ActTaskType_XianXiaMJLayer, layerNum)
|
| | | if layerNum > 1:
|
| | | AddPlayerLotteryScore(curPlayer, actNum, ipyData.GetLayerAddScore())
|
| | | AddPlayerLotteryScore(curPlayer, actNum, ipyData.GetLayerAddScore(), ipyData.GetIsRelationCrossAct())
|
| | | return True
|
| | |
|
| | | #// AA 17 仙匣秘境活动抽奖 #tagCMActXianXiaMJLottery
|
| | |
| | | if not actInfo.get(ShareDefine.ActKey_State):
|
| | | GameWorld.DebugLog(" 非活动中!")
|
| | | return
|
| | | |
| | | playerID = curPlayer.GetPlayerID()
|
| | | crossActInfo = CrossRealmPlayer.GetPlayerCrossActInfo(curPlayer, ShareDefine.CrossActName_XianXiaMJ)
|
| | | if crossActInfo.get(ShareDefine.ActKey_State, 0):
|
| | | if crossActInfo.get(ShareDefine.ActKey_StateJoin) != ShareDefine.ActStateJoin_Start:
|
| | | GameWorld.Log("跨服仙匣秘境非参与活动中: actNum=%s" % actNum, playerID)
|
| | | return
|
| | | else:
|
| | | if actInfo.get(ShareDefine.ActKey_StateJoin) != ShareDefine.ActStateJoin_Start:
|
| | | GameWorld.Log("仙匣秘境非参与活动中: actNum=%s" % actNum, playerID)
|
| | | return
|
| | |
|
| | | playerID = curPlayer.GetPlayerID()
|
| | | cfgID = actInfo.get(ShareDefine.ActKey_CfgID)
|
| | | ipyData = IpyGameDataPY.GetIpyGameData("ActXianXiaMJ", cfgID)
|
| | | if not ipyData:
|
| | | return
|
| | |
|
| | | if ipyData.GetIsRelationCrossAct():
|
| | | crossActInfo = CrossRealmPlayer.GetPlayerCrossActInfo(curPlayer, ShareDefine.CrossActName_XianXiaMJ)
|
| | | if crossActInfo.get(ShareDefine.ActKey_State, 0):
|
| | | if crossActInfo.get(ShareDefine.ActKey_StateJoin) != ShareDefine.ActStateJoin_Start:
|
| | | GameWorld.Log("跨服仙匣秘境非参与活动中: actNum=%s" % actNum, playerID)
|
| | | return
|
| | | else:
|
| | | if actInfo.get(ShareDefine.ActKey_StateJoin) != ShareDefine.ActStateJoin_Start:
|
| | | GameWorld.Log("仙匣秘境非参与活动中: actNum=%s" % actNum, playerID)
|
| | | return
|
| | | |
| | | templateID = ipyData.GetTemplateID()
|
| | | if not templateID:
|
| | | return
|
| | |
| | | PlayerControl.WorldNotify(0, "XianXiaMJ%s" % actNum, [curPlayer.GetPlayerName(), itemID, itemCount])
|
| | |
|
| | | # 积分
|
| | | lotteryScore = AddPlayerLotteryScore(curPlayer, actNum, ipyData.GetLotteryAddScore())
|
| | | lotteryScore = AddPlayerLotteryScore(curPlayer, actNum, ipyData.GetLotteryAddScore(), ipyData.GetIsRelationCrossAct())
|
| | |
|
| | | # 通知抽奖结果
|
| | | clientPack = ChPyNetSendPack.tagMCActXianXiaMJAwardItemResult()
|