| | |
| | | curLV = curPlayer.GetLV()
|
| | | if curLV < openLV:
|
| | | return 0
|
| | | # 初始点+升级点+境界点
|
| | | setFreePoint = IpyGameDataPY.GetFuncCfg("LVUPAddPoint", 2)
|
| | | |
| | | addPointDict = IpyGameDataPY.GetFuncEvalCfg("LVUPAddPoint", 1, {})
|
| | | initFreePoint = IpyGameDataPY.GetFuncCfg("LVUPAddPoint", 2)
|
| | | setFreePoint = initFreePoint
|
| | | for lv in xrange(openLV, curLV+1):
|
| | | setFreePoint += GameWorld.GetDictValueByRangeKey(addPointDict, lv, 0)
|
| | | for rangLVs, point in addPointDict.items():
|
| | | if curLV < rangLVs[0]:
|
| | | continue
|
| | | setFreePoint += point * (min(curLV, rangLVs[1]) - rangLVs[0] + 1)
|
| | | |
| | | #境界提升点数
|
| | | setFreePoint += curPlayer.GetOfficialRank() * IpyGameDataPY.GetFuncCfg("LVUPAddPoint", 3)
|
| | | return setFreePoint
|
| | |
|
| | | def DoAddPointOpen(curPlayer):
|
| | | '''加点功能开启 处理给自由属性点及老号处理 |
| | | 清除老服玩家未加点的点数(清零),以前加的加点属性不清除,属性不变,战力不减, 根据最新的加点开启等级和老服玩家的当前等级,相差的差值给予玩家对应的加点点数'''
|
| | | '''加点功能开启'''
|
| | | beforeFreePoint = curPlayer.GetFreePoint()
|
| | |
|
| | | setFreePoint = GetAllPointByLV(curPlayer)
|
| | |
| | | # @remarks 玩家升级 加点 2010-05-26 adaws修改 原来有加技能点 现将升级加技能提出
|
| | | def __DoLVUPAddPoint(self):
|
| | | curPlayer = self.__Player
|
| | | if not GameFuncComm.GetFuncCanUse(curPlayer, ShareDefine.GameFuncID_AddPoint):
|
| | | # 未开启前不可加点,因为DoAddPointOpen会一次性补齐,避免意外情况多加了点数
|
| | | return
|
| | |
|
| | | curFreePoint = curPlayer.GetFreePoint()
|
| | | addPoint = GetLvUp_AddPoint(curPlayer)
|
| | |
| | | pointFuncInfo[1](curPlayer, curPQLV)
|
| | | if not curPQLV:
|
| | | continue
|
| | | pqAttrID = ipyData.GetPointQualityAttrID()
|
| | | pqAttrValueList = ipyData.GetPointQualityAttrValueList()
|
| | | pqAttrIDDict = ipyData.GetPointQualityAttrIDDict()
|
| | | pqAttrID = pqAttrIDDict[curPlayer.GetJob()]
|
| | | pqAttrValueDict = ipyData.GetPointQualityAttrValueDict()
|
| | | pqAttrValueList = pqAttrValueDict[str(curPlayer.GetJob())]
|
| | | pqAttrValue = 0 if curPQLV > len(pqAttrValueList) else pqAttrValueList[curPQLV - 1]
|
| | | CalcAttrDict_Type(pqAttrID, pqAttrValue, lingGenQualityAttrList)
|
| | | #GameWorld.DebugLog(" 属性点(%s)品阶等级属性: curPQLV=%s,pqAttrID=%s,pqAttrValue=%s" % (pointAttrID, curPQLV, pqAttrID, pqAttrValue))
|