| | |
| | | SkillAtkRateReduce = attrDict.get(ShareDefine.Def_Effect_SkillAtkRateReduce, 0) * (1 if not gsParamIpyData else gsParamIpyData.GetSkillAtkRateReduceC())
|
| | | Hit = attrDict.get(ShareDefine.Def_Effect_Hit, 0) * (1 if not gsParamIpyData else gsParamIpyData.GetHitC())
|
| | | Miss = attrDict.get(ShareDefine.Def_Effect_Miss, 0) * (1 if not gsParamIpyData else gsParamIpyData.GetMissC())
|
| | | SkillAddPerA = attrDict.get(ShareDefine.Def_Effect_SkillAddPer1, 0) * (1 if not gsParamIpyData else gsParamIpyData.GetSkillAddPer1C())
|
| | | SkillAddPerB = attrDict.get(ShareDefine.Def_Effect_SkillAddPer2, 0) * (1 if not gsParamIpyData else gsParamIpyData.GetSkillAddPer2C())
|
| | | SkillAddPerC = attrDict.get(ShareDefine.Def_Effect_SkillAddPer3, 0) * (1 if not gsParamIpyData else gsParamIpyData.GetSkillAddPer3C())
|
| | | SkillAddPerD = attrDict.get(ShareDefine.Def_Effect_SkillAddPer4, 0) * (1 if not gsParamIpyData else gsParamIpyData.GetSkillAddPer4C())
|
| | | SkillAddPerE = attrDict.get(ShareDefine.Def_Effect_SkillAddPer5, 0) * (1 if not gsParamIpyData else gsParamIpyData.GetSkillAddPer5C())
|
| | | SkillAddPerF = attrDict.get(ShareDefine.Def_Effect_SkillAddPer6, 0) * (1 if not gsParamIpyData else gsParamIpyData.GetSkillAddPer6C())
|
| | | SkillAddPerG = attrDict.get(ShareDefine.Def_Effect_SkillAddPer7, 0) * (1 if not gsParamIpyData else gsParamIpyData.GetSkillAddPer7C())
|
| | | SkillReducePerA = attrDict.get(ShareDefine.Def_Effect_SkillReducePer1, 0) * (1 if not gsParamIpyData else gsParamIpyData.GetSkillReducePer1C())
|
| | | SkillReducePerB = attrDict.get(ShareDefine.Def_Effect_SkillReducePer2, 0) * (1 if not gsParamIpyData else gsParamIpyData.GetSkillReducePer2C())
|
| | | SkillReducePerC = attrDict.get(ShareDefine.Def_Effect_SkillReducePer3, 0) * (1 if not gsParamIpyData else gsParamIpyData.GetSkillReducePer3C())
|
| | | SkillReducePerD = attrDict.get(ShareDefine.Def_Effect_SkillReducePer4, 0) * (1 if not gsParamIpyData else gsParamIpyData.GetSkillReducePer4C())
|
| | | SkillReducePerE = attrDict.get(ShareDefine.Def_Effect_SkillReducePer5, 0) * (1 if not gsParamIpyData else gsParamIpyData.GetSkillReducePer5C())
|
| | | SkillReducePerF = attrDict.get(ShareDefine.Def_Effect_SkillReducePer6, 0) * (1 if not gsParamIpyData else gsParamIpyData.GetSkillReducePer6C())
|
| | | SkillReducePerG = attrDict.get(ShareDefine.Def_Effect_SkillReducePer7, 0) * (1 if not gsParamIpyData else gsParamIpyData.GetSkillReducePer7C())
|
| | |
|
| | | # 攻速不默认乘,仅作为参数提供策划使用
|
| | | AtkSpeed = attrDict.get(ShareDefine.Def_Effect_AtkSpeed, 0)
|
| | |
| | | if GetIsDogzEquip(curItem):
|
| | | # 神兽装备用不同公式
|
| | | value = eval(FormulaControl.GetCompileFormula("EquipGSFormula3", IpyGameDataPY.GetFuncCfg("EquipGSFormula", 3)))
|
| | | elif GetIsZhuXianEquip(curItem):
|
| | | value = eval(FormulaControl.GetCompileFormula("EquipGSFormula4", IpyGameDataPY.GetFuncCfg("EquipGSFormula", 4)))
|
| | | else:
|
| | | value = eval(FormulaControl.GetCompileFormula("EquipGSFormula", IpyGameDataPY.GetFuncCfg("EquipGSFormula")))
|
| | | return value
|
| | |
|
| | | def GetZhuXianEquipTotalGS(curPlayer):
|
| | | ##诛仙装备总评分
|
| | | return 10000000
|
| | | equipScoreTotal = 0
|
| | | zhuXianEquipPack = curPlayer.GetItemManager().GetPack(ShareDefine.rptZhuXianEquip)
|
| | | for equipIndex in xrange(zhuXianEquipPack.GetCount()):
|
| | | curEquip = zhuXianEquipPack.GetAt(equipIndex) |
| | | if curEquip.IsEmpty():
|
| | | continue
|
| | | equipScoreTotal += GetEquipGearScore(curEquip)
|
| | | return equipScoreTotal
|
| | |
|
| | | #---------------------------------------------------------------------
|
| | | ## 通过效果ID,检查是否为指定物品
|
| | | # @param curPlayer 当前玩家
|
| | |
| | | return hasEnough, itemIndexList, findItemIsBind, needCnt
|
| | |
|
| | |
|
| | | def GetPackItemBindStateIndexInfo(curPlayer, itemID, needCount=0):
|
| | | def GetPackItemBindStateIndexInfo(curPlayer, itemID, needCount=0, packType=IPY_GameWorld.rptItem):
|
| | | ''' 获取背包消耗道具绑定及未绑定索引情况
|
| | | @param needCount: 所需个数, 默认绑定优先,当找到已经足够的个数后不再遍历,减少无用遍历
|
| | | @return: 可消耗物品列表[[绑定物品索引], [不绑定物品索引]], 绑定个数, 未绑定个数
|
| | |
| | | consumeItemIndexList = [[], []] # 可消耗物品列表[[绑定物品索引], [不绑定物品索引]]
|
| | | bindCnt, unBindCnt = 0, 0
|
| | |
|
| | | curPack = curPlayer.GetItemManager().GetPack(IPY_GameWorld.rptItem)
|
| | | curPack = curPlayer.GetItemManager().GetPack(packType)
|
| | | for i in range(0, curPack.GetCount()):
|
| | | curItem = curPack.GetAt(i)
|
| | | if not curItem:
|
| | |
| | | # @remarks 函数详细说明.
|
| | | def SwitchItem(curPlayer, curItem, switchItem, putInPackIndex):
|
| | | ##物品绑定字段判定 -> 装备绑定
|
| | | if putInPackIndex == IPY_GameWorld.rptEquip:
|
| | | if putInPackIndex in [IPY_GameWorld.rptEquip, ShareDefine.rptZhuXianEquip]:
|
| | | DoLogic_ItemBindType(curPlayer, switchItem, ChConfig.Def_BindType_DoEquipBind)
|
| | |
|
| | | # 装备技能书、坐骑装备绑定
|
| | | if putInPackIndex in [IPY_GameWorld.rptHorseEquip]:
|
| | | if putInPackIndex in [IPY_GameWorld.rptHorseEquip, ShareDefine.rptZhuXianEquip]:
|
| | | DoLogic_ItemBindType(curPlayer, curItem, ChConfig.Def_BindType_DoEquipBind)
|
| | |
|
| | | #交换装备
|
| | |
| | | return
|
| | |
|
| | | ##物品绑定字段判定 -> 装备绑定
|
| | | if putInPackIndex == IPY_GameWorld.rptEquip:
|
| | | if putInPackIndex in [IPY_GameWorld.rptEquip, ShareDefine.rptZhuXianEquip]:
|
| | | DoLogic_ItemBindType(curPlayer, switchItem, ChConfig.Def_BindType_DoEquipBind)
|
| | |
|
| | | # 装备技能书、坐骑装备绑定
|
| | | if putInPackIndex in [IPY_GameWorld.rptHorseEquip]:
|
| | | if putInPackIndex in [IPY_GameWorld.rptHorseEquip, ShareDefine.rptZhuXianEquip]:
|
| | | DoLogic_ItemBindType(curPlayer, emptyItem, ChConfig.Def_BindType_DoEquipBind)
|
| | |
|
| | | if switchItem.GetGameWorldItemType() == IPY_GameWorld.gwitRoleItem:
|
| | |
| | | ## 返回是否神兽装备
|
| | | return curItem.GetType() in ChConfig.Def_DogzEquiipType
|
| | |
|
| | | def GetIsZhuXianEquip(curItem):
|
| | | ## 返回是否诛仙装备
|
| | | return curItem.GetType() in ChConfig.Def_ZhuXianEquiipType
|
| | |
|
| | | ## 返回是否武器
|
| | | # @param curItem 当前物品
|
| | | # @return None
|