xdh
2019-06-19 fe94844205ade47d1652ddd80ccfbfe0fac4a20f
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerControl.py
@@ -3790,9 +3790,9 @@
    #  @param expViewType 经验获得的渠道
    #  @param isSysHint 是否系统提示(默认是)
    #  @return 布尔值
    def AddExp(self, addExp, expViewType=ShareDefine.Def_ViewExpType_Mission, isSysHint=True):
    def AddExp(self, addExp, expViewType=ShareDefine.Def_ViewExpType_Mission, isSysHint=True, addSkillID=0):
        curPlayer = self.__Player
        finalAddExp, expNotifyType = self.__AddExp(curPlayer, addExp, expViewType, isSysHint)
        finalAddExp, expNotifyType = self.__AddExp(curPlayer, addExp, expViewType, isSysHint, addSkillID)
        
        # 通知客户端经验来源
        if finalAddExp:
@@ -3808,7 +3808,8 @@
            
        return finalAddExp
    
    def __AddExp(self, curPlayer, addExp, expViewType, isSysHint):
    # 参数 addSkillID 表示因什么技能杀死NPC获得经验
    def __AddExp(self, curPlayer, addExp, expViewType, isSysHint, addSkillID=0):
        if addExp == 0:
            # 不进入计算
            return addExp, expViewType
@@ -3837,6 +3838,11 @@
        if expViewType == ShareDefine.Def_ViewExpType_KillNPC:
            exp_rate = curPlayer.GetDictByKey(ChConfig.Def_PlayerKey_TotalExpRate)
            superRate = PassiveBuffEffMng.GetPassiveSkillValueByTriggerType(curPlayer, None, None, ChConfig.TriggerType_AddExpRate)
            if addSkillID == ChConfig.Def_SkillID_LXHY_AddExpRate:
                addSkill = GameWorld.GetGameData().GetSkillBySkillID(addSkillID)
                hasEffect = SkillCommon.GetSkillEffectByEffectID(addSkill, ChConfig.Def_Skill_Effect_AddExpRate)
                if hasEffect:
                    superRate += hasEffect.GetEffectValue(0)
            exp_rate += superRate
            if superRate:
                expViewType = ShareDefine.Def_ViewExpType_KillNPCSuper