hxp
2025-10-20 6a6ba3ddbe0f03cf9c268c8afae393ef53a15816
232 【付费内容】历练秘笈-服务端(手动升级)
3个文件已修改
35 ■■■■ 已修改文件
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChConfig.py 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/ChPlayer.py 3 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerLLMJ.py 30 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChConfig.py
@@ -4929,7 +4929,7 @@
(
Def_RewardType_Activity,  # 活跃度奖励 0
Def_RewardType_DailyTask,  # 每日任务奖励 1
Def_RewardType_ChampionFamilyDailyReward,  # 仙盟联赛冠军仙盟每日俸禄奖励 2
Def_RewardType_LLMJLVUp,  # 历练秘笈升级 2
Def_RewardType_XMZZWinCnt,  # 仙魔之争胜利场数奖励 3
Def_RewardType_FamilyDayAward,  # 仙盟每日福利奖励 4
Def_RewardType_LVAward,  # 玩家等级奖励5
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/ChPlayer.py
@@ -3276,6 +3276,9 @@
    # 广告奖励
    elif rewardType == ChConfig.Def_RewardType_ADAward:
        OnGetADAward(curPlayer, dataEx)
    # 历练秘笈升级
    elif rewardType == ChConfig.Def_RewardType_LLMJLVUp:
        PlayerLLMJ.OnLLMJLVUp(curPlayer)
    # 每日免费直购礼包
    elif rewardType == ChConfig.Def_RewardType_DayFreeGoldGift:
        PlayerDailyGiftbag.OnGetDailyFreeGiftbag(curPlayer)
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerLLMJ.py
@@ -62,20 +62,34 @@
    mjLV, zhanchui = GetMJLVInfo(curPlayer)
    if not mjLV:
        return
    nextIpyData = IpyGameDataPY.GetIpyGameDataNotLog("LLMJ", mjLV + 1)
    if not nextIpyData:
        #GameWorld.DebugLog("历练秘笈已满级不再累加战锤: mjLV=%s" % (mjLV))
    maxIpyData = IpyGameDataPY.IPY_Data().GetLLMJByIndex(-1) # 最多累加到最后一级
    if not maxIpyData:
        return
    updZhanchui = zhanchui + addCnt
    maxZhanchui = maxIpyData.GetCostWarhammer()
    if zhanchui >= maxZhanchui:
        #GameWorld.DebugLog("历练秘笈累加战锤已达上限: mjLV=%s,zhanchui=%s >= %s" % (mjLV, zhanchui, maxZhanchui))
        return
    updZhanchui = min(zhanchui + addCnt, maxZhanchui)
    GameWorld.DebugLog("累加历练秘笈战锤: mjLV=%s,addCnt=%s,updZhanchui=%s,maxZhanchui=%s" % (mjLV, addCnt, updZhanchui, maxZhanchui))
    SetMJLVInfo(curPlayer, mjLV, updZhanchui)
    SyncLLMJInfo(curPlayer)
    return
def OnLLMJLVUp(curPlayer):
    ## 秘笈升级
    mjLV, zhanchui = GetMJLVInfo(curPlayer)
    if not mjLV:
        return
    nextIpyData = IpyGameDataPY.GetIpyGameData("LLMJ", mjLV + 1)
    if not nextIpyData:
        return
    nextZhanchui = nextIpyData.GetCostWarhammer()
    GameWorld.DebugLog("累加历练秘笈战锤: mjLV=%s,addCnt=%s,updZhanchui=%s,nextZhanchui=%s" % (mjLV, addCnt, updZhanchui, nextZhanchui))
    while nextIpyData and updZhanchui >= nextZhanchui:
    while nextIpyData and zhanchui >= nextZhanchui:
        mjLV += 1 # 升级
        nextIpyData = IpyGameDataPY.GetIpyGameDataNotLog("LLMJ", mjLV + 1)
        nextZhanchui = nextIpyData.GetCostWarhammer() if nextIpyData else 0
        GameWorld.DebugLog("历练秘笈升级: %s,nextZhanchui=%s" % (mjLV, nextZhanchui))
    SetMJLVInfo(curPlayer, mjLV, updZhanchui)
    SetMJLVInfo(curPlayer, mjLV, zhanchui)
    SyncLLMJInfo(curPlayer)
    return