From d8783081eac62409055afa990b6c5750cf5f6117 Mon Sep 17 00:00:00 2001 From: mengyxu Date: Wed, 21 May 2025 09:08:09 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B5=81=E8=A1=80=E4=BC=A4=E5=AE=B3=E4=B8=8D?= =?UTF-8?q?=E5=86=8D=E6=98=AF=E7=9C=9F=E5=AE=9E=E4=BC=A4=E5=AE=B3,?= =?UTF-8?q?=E5=8F=97=E6=8A=A4=E7=94=B2=E5=87=8F=E4=BC=A4=E5=BD=B1=E5=93=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/config/skill/buff.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/config/skill/buff.ts b/src/config/skill/buff.ts index fa04392..9baf5bc 100644 --- a/src/config/skill/buff.ts +++ b/src/config/skill/buff.ts @@ -1,4 +1,4 @@ -import { BattleRole, callDmgPercent, callDmgReduc, replace } from '@/tool'; +import { BattleRole, callDmgPercent, callDmgReduc, callReducPercent, replace } from '@/tool'; import i18n from '../i18n'; const { t } = i18n; @@ -196,7 +196,8 @@ export class LiuXue extends AttackBuff { return replace(t('skill.liuxue.0'), [this.percent]); } takeEffect(owner: BattleRole): void { - const dmg = Math.ceil(owner.attr.curHp * (this.percent / 100) * this.layer); + const reducPercent = callReducPercent(owner.attr.def + owner.extraAttr.def, owner.attr.lv); //目标防御提供的减伤比例 + const dmg = Math.ceil(owner.attr.curHp * (this.percent / 100) * this.layer * (1 - reducPercent)); owner.addHp(-1 * dmg); owner.debuffLog(replace(t('skill.liuxue.1'), [this.layer, t(owner.type), dmg])); }