| | |
| | | def GetCurWeekMissionMoney(curFamily): return curFamily.GetExtra2()
|
| | | def SetCurWeekMissionMoney(curFamily, value): return curFamily.SetExtra2(min(value, ChConfig.Def_UpperLimit_DWord))
|
| | |
|
| | | # 仙盟上次处理的合服天
|
| | | def GetFamilyMixServerDay(curFamily): return curFamily.GetExtra1()
|
| | | def SetFamilyMixServerDay(curFamily, value): return curFamily.SetExtra1(value)
|
| | | ## ------------------ 成员 ----------------------
|
| | | def GetMemberFightPower(curMember): return curMember.GetExattr3()
|
| | | def SetMemberFightPower(curMember, fightPower): return curMember.SetExattr3(fightPower)
|
| | |
| | | curFamily.SetLV(1)
|
| | | curFamily.SetAcceptJoin(ShareDefine.FamilyAcceptJoin_Agree) #设置收人方式为直接通过申请
|
| | | PyDataManager.GetFamilyStoreItemManager().DelFamilyStoreItemAll(curFamily.GetID())
|
| | | |
| | | #新创建的仙盟默认设置已处理过合服
|
| | | SetFamilyMixServerDay(curFamily, PlayerDBGSEvent.GetDBGSTrig_ByKey(PlayerDBGSEvent.Def_LastMixServerDay))
|
| | |
|
| | | #-设置家族成员属性
|
| | | DoPlayerJionFamily(curFamily, curPlayer, IPY_GameServer.fmlLeader)
|
| | |
| | | PlayerRefresh(curPlayer, tick)
|
| | |
|
| | | GameWorldFamilyWar.OnPlayerLogin(curFamily, curPlayer)
|
| | | |
| | | # 盟主上线处理
|
| | | if curMember.GetFamilyLV() == IPY_GameServer.fmlLeader:
|
| | | OnFamilyLeaderLogin(curPlayer, curFamily)
|
| | | return
|
| | |
|
| | | def OnFamilyLeaderLogin(curPlayer, curFamily):
|
| | | ## 盟主登录处理
|
| | | __DoFamilyMixServerLogicOnLeaderLogin(curPlayer, curFamily)
|
| | | return
|
| | |
|
| | | def __DoFamilyMixServerLogicOnLeaderLogin(curPlayer, curFamily):
|
| | | ## 合服仙盟盟主登录处理
|
| | | |
| | | isMixServer = PlayerDBGSEvent.GetDBGSTrig_ByKey(PlayerDBGSEvent.Def_IsMixServer)
|
| | | if not isMixServer:
|
| | | return
|
| | | lastMixServerDay = PlayerDBGSEvent.GetDBGSTrig_ByKey(PlayerDBGSEvent.Def_LastMixServerDay)
|
| | | familyID = curFamily.GetID()
|
| | | familyMixServerDay = GetFamilyMixServerDay(curFamily)
|
| | | if familyMixServerDay == lastMixServerDay:
|
| | | GameWorld.DebugLog("已经处理过仙盟盟主合服登录逻辑! lastMixServerDay=%s" % (lastMixServerDay), familyID)
|
| | | return
|
| | | SetFamilyMixServerDay(curFamily, lastMixServerDay)
|
| | | GameWorld.Log("处理合服仙盟盟主登录! lastMixServerDay=%s" % (lastMixServerDay), familyID)
|
| | | |
| | | mailItemList = IpyGameDataPY.GetFuncEvalCfg("MixServerMail", 4)
|
| | | playerID = curPlayer.GetPlayerID()
|
| | | detailDict = {}
|
| | | GameWorld.Log(" 发送合服盟主专属补偿邮件! familyID=%s,mailItemList=%s" % (familyID, mailItemList), playerID)
|
| | | PlayerCompensation.SendMailByKey("MixServer2", [playerID], mailItemList, detail=detailDict)
|
| | | return
|
| | | #---------------------------------------------------------------------
|
| | | ## 玩家下线家族刷新逻辑
|