mirror of
https://github.com/yoimiya-kokomi/miao-plugin.git
synced 2025-02-01 16:05:53 +00:00
把扩散反应的伤害计算归到整体的计算中 (#239)
This commit is contained in:
parent
c6a70b3a6d
commit
c79ac0d2a5
@ -67,12 +67,14 @@ let DmgCalc = {
|
||||
|
||||
// 抗性区
|
||||
let kx = attr.kx
|
||||
if (talent === 'fy') {
|
||||
if (ele === 'swirl'/* || (ele === 'phy' && (attr.element === '雷' || attr.element === '冰'))*/) {
|
||||
kx = attr.fykx
|
||||
}
|
||||
kx = 10 - (kx || 0)
|
||||
let kNum = 0.9
|
||||
if (kx >= 0) {
|
||||
if (kx >= 75) {
|
||||
kNum = 1 / (1 + 3 * kx / 100)
|
||||
} else if (kx >= 0) {
|
||||
kNum = (100 - kx) / 100
|
||||
} else {
|
||||
kNum = 1 - kx / 200
|
||||
@ -86,8 +88,8 @@ let DmgCalc = {
|
||||
const isEle = ele !== false && ele !== 'phy'
|
||||
// 反应区
|
||||
let eleNum = isEle ? DmgMastery.getBasePct(ele, attr.element) : 1
|
||||
let eleBase = isEle ? 1 + attr[ele] / 100 + DmgMastery.getMultiple(ele, attr.mastery.base + attr.mastery.plus) : 1
|
||||
let dmgBase = (mode === 'basic') ? basicNum : atkNum * pctNum * (1 + multiNum)
|
||||
let eleBase = isEle ? 1 + attr[ele] / 100 + DmgMastery.getMultiple(ele, calc(attr.mastery)) : 1
|
||||
let dmgBase = (mode === 'basic') ? basicNum : atkNum * pctNum * (1 + multiNum) + plusNum
|
||||
let ret = {}
|
||||
|
||||
switch (ele) {
|
||||
@ -152,6 +154,10 @@ let DmgCalc = {
|
||||
dmgFn.basic = function (basicNum = 0, talent = false, ele = false) {
|
||||
return dmgFn(0, talent, ele, basicNum, 'basic')
|
||||
}
|
||||
|
||||
dmgFn.reaction = function(ele = false){
|
||||
return dmgFn(0, 'fy', ele, 0, 'basic')
|
||||
}
|
||||
|
||||
// 计算治疗
|
||||
dmgFn.heal = function (num) {
|
||||
|
@ -9,7 +9,7 @@ export const details = [{
|
||||
}
|
||||
}, {
|
||||
title: '扩散反应伤害',
|
||||
dmg: ({}, { swirl }) => swirl()
|
||||
dmg: ({}, { reaction }) => reaction('swirl')
|
||||
}]
|
||||
|
||||
export const mainAttr = 'atk,cpct,cdmg,mastery'
|
||||
@ -21,4 +21,4 @@ export const buffs = [{
|
||||
qPct: ({ attr, calc }) => Math.min(calc(attr.mastery) * 0.002, 400),
|
||||
_heal: ({ attr, calc }) => Math.min(calc(attr.mastery) * 3, 6000)
|
||||
}
|
||||
}, 'swirl']
|
||||
}]
|
||||
|
@ -9,7 +9,7 @@ export const details = [{
|
||||
dmg: ({ talent }, dmg) => dmg(talent.q['持续伤害'], 'q')
|
||||
}, {
|
||||
title: '扩散反应伤害',
|
||||
dmg: ({}, { swirl }) => swirl()
|
||||
dmg: ({}, { reaction }) => reaction('swirl')
|
||||
}]
|
||||
|
||||
export const mainAttr = 'atk,cpct,cdmg,mastery'
|
||||
@ -21,7 +21,9 @@ export const buffs = [{
|
||||
mastery: 200
|
||||
}
|
||||
}, {
|
||||
title: '元素精通:扩散伤害提高[swirl]%',
|
||||
title: '元素精通:扩散伤害提高[swirlPlus]%',
|
||||
sort: 2,
|
||||
mastery: 'swirl'
|
||||
data:{
|
||||
swirlPlus: ({calc, attr}) => 1600 * calc(attr.mastery) / (calc(attr.mastery) + 2000)
|
||||
}
|
||||
}]
|
||||
|
@ -19,10 +19,10 @@ export const details = [{
|
||||
}
|
||||
}, {
|
||||
title: '扩散反应伤害',
|
||||
dmg: ({}, { swirl }) => swirl()
|
||||
dmg: ({}, { reaction }) => reaction('swirl')
|
||||
}]
|
||||
|
||||
export const mainAttr = 'atk,cpct,cdmg'
|
||||
export const mainAttr = 'atk,cpct,cdmg,mastery'
|
||||
|
||||
export const buffs = [{
|
||||
title: '温迪2命:E降低12%风抗与物抗',
|
||||
@ -42,4 +42,4 @@ export const buffs = [{
|
||||
data: {
|
||||
kx: ({ params }) => params.q ? 20 : 0
|
||||
}
|
||||
}, 'swirl']
|
||||
}]
|
||||
|
@ -13,7 +13,7 @@ export const details = [{
|
||||
}
|
||||
}, {
|
||||
title: '扩散反应伤害',
|
||||
dmg: ({}, { swirl }) => swirl()
|
||||
dmg: ({}, { reaction }) => reaction('swirl')
|
||||
}]
|
||||
|
||||
export const mainAttr = 'atk,cpct,cdmg,mastery'
|
||||
@ -21,8 +21,8 @@ export const mainAttr = 'atk,cpct,cdmg,mastery'
|
||||
export const buffs = [{
|
||||
title: '砂糖被动:触发扩散反应时,队伍提升50精通'
|
||||
}, {
|
||||
title: '砂糖被动:释放QE命中敌人时,基于自身精通提升队伍[_mastery]精通',
|
||||
title: '砂糖被动:释放QE命中敌人时,基于自身精通提升队伍[mastery]精通',
|
||||
data: {
|
||||
_mastery: ({ attr, calc }) => calc(attr.mastery) * 0.2
|
||||
mastery: ({ attr, calc }) => calc(attr.mastery) * 0.2
|
||||
}
|
||||
}, 'swirl']
|
||||
}]
|
||||
|
Loading…
Reference in New Issue
Block a user