| | |
| | | #获取策划配置的表格
|
| | | GodWeapon4 = IpyGameDataPY.GetFuncCfg("GodWeapon4", 2)
|
| | | maxProDef = eval(FormulaControl.GetCompileFormula("GodWeapon4", GodWeapon4))
|
| | | maxProDef = min(maxProDef, ChConfig.Def_UpperLimit_DWord)
|
| | | |
| | | SetMaxProDef(curPlayer, int(maxProDef))
|
| | |
|
| | | afterMaxProDef = GetMaxProDef(curPlayer)
|
| | |
| | | return [attr15%1000, attr15/1000%1000, attr15/1000000]
|
| | | def SetFaceEquipIndex(curPlayer, value): return curPlayer.SetExAttr15(value)
|
| | |
|
| | | # 返回最大的灵根系
|
| | | def GetLingGenMaxIndex(curPlayer):
|
| | | return curPlayer.GetExAttr16()
|
| | |
|
| | | def SetLingGenMaxIndex(curPlayer):
|
| | | indexList = [
|
| | | ShareDefine.Def_Effect_Metal, # 金
|
| | | ShareDefine.Def_Effect_Wood, # ľ
|
| | | ShareDefine.Def_Effect_Water, # ˮ
|
| | | ShareDefine.Def_Effect_Fire, # 火
|
| | | ShareDefine.Def_Effect_Earth, # 土
|
| | | ]
|
| | | |
| | | |
| | | tempList = [curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_AddPointValue % attrID) for attrID in indexList]
|
| | | |
| | | curPlayer.SetExAttr16(indexList[tempList.index(max(tempList))])
|
| | | return
|
| | |
|
| | | # 境界难度等级
|
| | | def GetRealmDifficulty(curPlayer): return curPlayer.GetExAttr18()
|
| | |
| | | return
|
| | |
|
| | | #---最大防护值----
|
| | | def GetMaxProDef(curPlayer): return curPlayer.GetDictByKey(ChConfig.Def_PlayerKey_AttrMaxProDef)
|
| | | def GetMaxProDef(curPlayer): return curPlayer.GetExAttr16()
|
| | | def SetMaxProDef(curPlayer, value):
|
| | | curPlayer.SetDict(ChConfig.Def_PlayerKey_AttrMaxProDef, value)
|
| | | SendPropertyRefresh(curPlayer, ShareDefine.CDBPlayerRefresh_MaxProDef, value) # 周围玩家需要通知
|
| | | value = min(value, ChConfig.Def_UpperLimit_DWord)
|
| | | curPlayer.SetExAttr16(value)
|
| | | curPlayer.SendPropertyRefresh(ShareDefine.CDBPlayerRefresh_MaxProDef, value, 0, True) # 周围玩家需要通知
|
| | | return
|
| | |
|
| | | #---生命上限换算为防护值的百分比----
|
| | | def GetProDefHPPer(curPlayer): return curPlayer.GetDictByKey(ChConfig.Def_PlayerKey_AttrProDefHPPer)
|