【家园功能1.1.8】

1、装备强化增加战力修改
back_recharge
duhui 2021-12-31 13:39:41 +08:00
parent b1c4e0ba35
commit a56918a674
1 changed files with 11 additions and 7 deletions

View File

@ -2781,13 +2781,17 @@ public class HeroLogic {
int[][] property = sEquipConfig.getProperty();
Map<Integer, Long> propertyValueByIdMap = new HashMap<>();
for (int[] prop : property) {
int buff = 0;
// 家园装备强化属性
int strongeId = Optional.ofNullable(intensifyMap.get(sEquipConfig.getPosition())).orElse(0);
buff += Optional.ofNullable(strengthenMap.get(strongeId)).map(SEquipStrengthen::getRate).orElse(0);
long value = prop[1];
SPropertyConfig config = SPropertyConfig.getsPropertyConfigByPID(prop[0]);
// 家园装备强化属性,只增加基础属性
if (config != null && config.getStyle() == 1){
double buff = 0;
int strongId = Optional.ofNullable(intensifyMap.get(sEquipConfig.getPosition())).orElse(0);
buff += Optional.ofNullable(strengthenMap.get(strongId)).map(SEquipStrengthen::getRate).orElse(0);
// 突破
buff += Optional.ofNullable(rankUpMap.get(homeRankUp)).map(v -> v.getRate()[sEquipConfig.getPosition() - 1]).orElse(0);
long value = prop[1] + (long) prop[1] / 100 *buff;
value = value + (long) Math.ceil(buff/100*value);
}
propertyValueByIdMap.put(prop[0], value);
}
combinedAttribute(propertyValueByIdMap, heroAllAttribute);