fix: talent key

This commit is contained in:
Aluxes 2023-11-18 02:58:57 +08:00
parent f03997fe9e
commit 9d63ec13fc
2 changed files with 4 additions and 3 deletions

View File

@ -48,8 +48,9 @@ export default class ProfileDmg extends Base {
let { isSr, isGs } = this
lodash.forEach((isSr ? 'a,a2,e,e2,q,q2,t' : 'a,e,q').split(','), (key) => {
let level = lodash.isNumber(talentData[key]) ? talentData[key] : (talentData[key]?.level || 1)
if (key === 'a2' || key === 'e2') {
let tmpKey = key === 'a2' ? 'a' : 'e'
let keyRet = /^(a|e|q)2$/.exec(key)
if (keyRet) {
let tmpKey = keyRet[1]
level = lodash.isNumber(talentData[tmpKey]) ? talentData[tmpKey] : (talentData[tmpKey]?.level || 1)
}
let map = {}

View File

@ -21,7 +21,7 @@ export const defDmgIdx = 3
export const mainAttr = 'atk,cpct,cdmg'
export const buffs = [{
title: '天赋-勇气对当前生命百分比小于等于50%的敌人目标造成的伤害提高[dmg]%',
title: '行迹-勇气对当前生命百分比小于等于50%的敌人目标造成的伤害提高[dmg]%',
trees: 2,
data: {
dmg: 15