xdh
2019-05-17 e8b853ab499900513f5bdbb693d53815414e5d8a
6779 【后端】【2.0】BOSS之家多图合一 批
7个文件已修改
77 ■■■■ 已修改文件
ServerPython/CoreServerGroup/GameServer/Script/GameWorldLogic/GameWorldBoss.py 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBLogic.py 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBProcess/FBCommon.py 24 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBProcess/GameLogic_BossHome.py 14 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBProcess/GameLogic_HorsePetBoss.py 17 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Item/ChItem.py 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/NPC/NPCCommon.py 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ServerPython/CoreServerGroup/GameServer/Script/GameWorldLogic/GameWorldBoss.py
@@ -550,7 +550,7 @@
    # playerName, mapID, npcID, itemID, userData
    if len(msgList) != 8:
        return
    playerID, killerName, mapID, npcID, itemID, userData, weightValue, serverGroupID = msgList
    playerID, killerName, mapID, lineID, npcID, itemID, userData, weightValue, serverGroupID = msgList
    GameWorld.DebugLog("击杀Boss掉落好物品: mapID=%s,npcID=%s,killerName=%s,itemID=%s, userData=%s, weightValue=%s, serverGroupID=%s" 
                       % (mapID, npcID, killerName, itemID, userData, weightValue, serverGroupID))
    maxRecordCnt = IpyGameDataPY.GetFuncCfg('DropRecordNum')
@@ -596,9 +596,9 @@
                recordList.Delete(commonList[0][0])
        
    PlayerUniversalGameRec.MapServer_UniversalGameRec(None, recType, [mapID, npcID, itemID, playerID, weightValue],
                                                      [killerName, "", userData])
                                                      [killerName, lineID, userData])
    
    msgList = [killerName, playerID, mapID, npcID, itemID, userData]
    msgList = [killerName, playerID, mapID, lineID, npcID, itemID, userData]
    PlayerControl.WorldNotify(0, 'DropRecord' , msgList)
    return
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBLogic.py
@@ -525,9 +525,8 @@
    gameMap = GameWorld.GetMap()
    gameMapID = gameMap.GetMapID()
    
    #如果已经设置过副本功能线路属性,则进入时同步玩家,一般下线重登或者非第一个进入该副本的玩家(如队友)会收到该包
    if FBCommon.GetHadSetFBPropertyMark() and gameMap.GetMapFBType() != IPY_GameWorld.fbtSingle:
        PlayerControl.SetFBFuncLineID(curPlayer, FBCommon.GetFBPropertyMark())
    reqFuncLineID = curPlayer.NomalDictGetProperty(ChConfig.Def_Player_Dict_ReqFBFuncLine)
    PlayerControl.SetFBFuncLineID(curPlayer, reqFuncLineID)
        
    #成长NPC所需数据初始化
    InitFBNPCStrengthenData(curPlayer, gameMap)
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBProcess/FBCommon.py
@@ -446,18 +446,18 @@
#  @return
def SetFBPropertyMark(propertyMark, setPlayer=None):
    GameWorld.GetGameFB().SetGameFBDict(ChConfig.Map_FBDict_PropertyMark, propertyMark + 1) # 存储时+1才能判断是否存储过
    if setPlayer != None:
        PlayerControl.SetFBFuncLineID(setPlayer, propertyMark)
        GameWorld.DebugLog("SetFBPropertyMark 设置玩家副本功能线路ID: %s" % propertyMark, setPlayer.GetPlayerID())
        return
    playerManager = GameWorld.GetMapCopyPlayerManager()
    for index in xrange(playerManager.GetPlayerCount()):
        curPlayer = playerManager.GetPlayerByIndex(index)
        if not curPlayer.GetPlayerID():
            continue
        PlayerControl.SetFBFuncLineID(curPlayer, propertyMark)
        GameWorld.DebugLog("SetFBPropertyMark 广播玩家副本功能线路ID: %s" % propertyMark, curPlayer.GetPlayerID())
#    if setPlayer != None:
#        PlayerControl.SetFBFuncLineID(setPlayer, propertyMark)
#        GameWorld.DebugLog("SetFBPropertyMark 设置玩家副本功能线路ID: %s" % propertyMark, setPlayer.GetPlayerID())
#        return
#
#    playerManager = GameWorld.GetMapCopyPlayerManager()
#    for index in xrange(playerManager.GetPlayerCount()):
#        curPlayer = playerManager.GetPlayerByIndex(index)
#        if not curPlayer.GetPlayerID():
#            continue
#        PlayerControl.SetFBFuncLineID(curPlayer, propertyMark)
#        GameWorld.DebugLog("SetFBPropertyMark 广播玩家副本功能线路ID: %s" % propertyMark, curPlayer.GetPlayerID())
    return
## 是否已经扣除入场券/进入次数等
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBProcess/GameLogic_BossHome.py
@@ -75,7 +75,6 @@
def OnChangeMapAsk(ask, tick):
    return IPY_GameWorld.cmeAccept
## 进副本
#  @param curPlayer
#  @param tick
@@ -85,17 +84,14 @@
    if curPlayer.GetHP() == 0:
        PlayerControl.PlayerLeaveFB(curPlayer)
        return
    # 设置副本公共属性的单独处理,防止队员进入后被修改
    if not FBCommon.GetHadSetFBPropertyMark():
        lineID = curPlayer.NomalDictGetProperty(ChConfig.Def_Player_Dict_ReqFBFuncLine)
        FBCommon.SetFBPropertyMark(lineID)
    GameWorld.DebugLog("DoEnterFB...lineID=%s" % FBCommon.GetFBPropertyMark(), playerID)
    lineID = PlayerControl.GetFBFuncLineID(curPlayer)
    GameWorld.DebugLog("DoEnterFB...lineID=%s" % lineID, playerID)
    hadDelTicket = FBCommon.GetHadDelTicket(curPlayer)
    if not hadDelTicket:
        GameWorld.DebugLog('扣门票!')
        FBCommon.SetHadDelTicket(curPlayer)
        canEnterLine = PlayerVip.GetPrivilegeValue(curPlayer, ChConfig.VIPPrivilege_BossHome)
        lineID = FBCommon.GetFBPropertyMark()
        if lineID+1 > canEnterLine:
            costGold = __GetEnterCostMoney(lineID)
            costMoneyList = PlayerControl.HaveMoneyEx(curPlayer, ShareDefine.TYPE_Price_Gold_Paper_Money, costGold)
@@ -176,7 +172,7 @@
# @remarks 玩家主动离开副本.
def DoPlayerDead(curPlayer):
    FBCommon.Notify_FB_Over(curPlayer, {FBCommon.Over_isPass:0})
    lineID = FBCommon.GetFBPropertyMark()
    lineID = PlayerControl.GetFBFuncLineID(curPlayer)
    leaveTime = int(FBCommon.GetFBLineStepTime(ChConfig.Def_FBMapID_BossHome, lineID))
    curPlayer.Sync_TimeTick(IPY_GameWorld.tttLeaveMap, 0, leaveTime*1000, True)
    return
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBProcess/GameLogic_HorsePetBoss.py
@@ -105,7 +105,7 @@
    if not state:
        if GameWorld.GetGameFB().GetFBStep() == FB_Step_Fighting:
            GameWorld.GetGameFB().SetGameFBDict(FBDict_IsOver, tick)
            __DoLogicHorsePetBossOver(0, tick, 0, 0)
            __DoLogicHorsePetBossOver(0, tick)
    return
## 进副本
@@ -312,7 +312,7 @@
    return playerHurtList
def __DoLogicHorsePetBossOver(isPass, tick, dropPosX, dropPosY):
def __DoLogicHorsePetBossOver(isPass, tick):
    #结算
    FBCommon.SetFBStep(FB_Step_Over, tick)
    
@@ -327,8 +327,8 @@
    if not playerHurtList:
        GameWorld.Log(' __DoLogicHorsePetBossOver, 伤害榜上没有人!!lineID=%s'%lineID)
        return
    event = ["HorsePetBoss", False, {}]
    bossID = CurFBLineBOSSID(lineID)
    #event = ["HorsePetBoss", False, {}]
    batchPlayerIDList, batchAddItemList, batchParamList, batchDetailList = [], [], [], []
    playerManager = GameWorld.GetMapCopyPlayerManager()
    worldLV = GameWorld.GetGameWorld().GetGameWorldDictByKey(ShareDefine.Def_Notify_WorldKey_WorldAverageLv)
@@ -348,9 +348,8 @@
            if itemList:
                overDict[FBCommon.Over_itemInfo] = FBCommon.GetJsonItemList(itemList)
            if giveItemList:
                NPCCommon.DoVirtualItemDrop(player, giveItemList, dropPosX, dropPosY)
                ItemControler.GivePlayerItemOrMail(player, giveItemList, 'QCBOSS1', event)
                NPCCommon.DoGiveItemByVirtualDrop(player, giveItemList, bossID, mailTypeKey='QCBOSS1')
                #ItemControler.GivePlayerItemOrMail(player, giveItemList, 'QCBOSS1', event)
            player.Sync_TimeTick(IPY_GameWorld.tttLeaveMap, 0, leaveTick, True)
            FBCommon.NotifyFBOver(player, ChConfig.Def_FBMapID_HorsePetBoss, lineID, isPass, overDict)
        elif giveItemList:
@@ -420,13 +419,11 @@
    if curNPC.GetNPCID() != bossID:
        return
    dropPosX, dropPosY = curNPC.GetPosX(), curNPC.GetPosY()
    #结束 设置BOSS死亡
    FBCommon.NotifyCopyMapPlayerFBHelp(tick, DoFBHelp, 0)
    GameWorld.DebugLog('结束 设置BOSS死亡 lineID=%s' % lineID)
    
    __DoLogicHorsePetBossOver(1, tick, dropPosX, dropPosY)
    __DoLogicHorsePetBossOver(1, tick)
    GameWorld.GetGameFB().SetGameFBDict(FBDict_IsOver, tick)
    return
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Item/ChItem.py
@@ -268,7 +268,8 @@
        if dropItemNPCID:
            serverGroupID = PlayerControl.GetPlayerServerGroupID(curPlayer)
            mapID = GameWorld.GetGameWorld().GetMapID()
            NPCCommon.SendGameServerGoodItemRecord(mapID, dropItemNPCID, curPlayer.GetName(),
            lineID = 0 if GameWorld.GetMap().GetMapFBType() == IPY_GameWorld.fbtNull else PlayerControl.GetFBFuncLineID(curPlayer)
            NPCCommon.SendGameServerGoodItemRecord(mapID, lineID, dropItemNPCID, curPlayer.GetName(),
                                                   curPlayer.GetPlayerID(), curItemID, equipInfo, serverGroupID)
            
        # 不需要队伍提示
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/NPC/NPCCommon.py
@@ -622,7 +622,7 @@
    ## 给物品并且做假掉落表现,直接先堆叠给物品,再拆开做虚假掉落表现
    
    mapID = curPlayer.GetDictByKey(ChConfig.Def_PlayerKey_ClientCustomSceneMapID)
    #lineID = curPlayer.GetDictByKey(ChConfig.Def_PlayerKey_ClientCustomSceneLineID)
    lineID = curPlayer.GetDictByKey(ChConfig.Def_PlayerKey_ClientCustomSceneLineID)
    if not mapID:
        mapID = GameWorld.GetGameWorld().GetMapID()
        
@@ -651,7 +651,7 @@
            
        if npcID:
            serverGroupID = PlayerControl.GetPlayerServerGroupID(curPlayer)
            SendGameServerGoodItemRecord(mapID, npcID, curPlayer.GetName(), playerID, itemID, equipInfo, serverGroupID)
            SendGameServerGoodItemRecord(mapID, lineID, npcID, curPlayer.GetName(), playerID, itemID, equipInfo, serverGroupID)
            
        # 散开掉落
        if isDropDisperse:
@@ -6187,7 +6187,7 @@
    NetPackCommon.SendFakePack(curPlayer, npcInfoPack)
    return
def SendGameServerGoodItemRecord(mapID, npcID, playerName, playerID, itemID, equipInfo=[], serverGroupID=0):
def SendGameServerGoodItemRecord(mapID, lineID, npcID, playerName, playerID, itemID, equipInfo=[], serverGroupID=0):
    # @param equipInfo: [equipPlace, itemClassLV, itemColor, itemQuality, itemUserData]
#    GameWorld.DebugLog("检查物品是否发送GameServer: mapID=%s, npcID=%s, playerName=%s, itemID=%s" 
#                       % (mapID, npcID, playerName, itemID))
@@ -6218,7 +6218,7 @@
    if not needRecord:
        return
    
    dropEquipMsg = str([playerID, playerName, mapID, npcID, itemID, itemUserData, weightValue, serverGroupID])
    dropEquipMsg = str([playerID, playerName, mapID, lineID, npcID, itemID, itemUserData, weightValue, serverGroupID])
    GameWorld.GetPlayerManager().GameServer_QueryPlayerResult(0, 0, 0, 'BossDropGoodItem', dropEquipMsg, len(dropEquipMsg))
    GameWorld.DebugLog("发送GameServer记录拾取掉落好物品: %s" % dropEquipMsg, playerID)
    return