From f08a5c4ef02f939cf3c5e762e42d98eb6debc403 Mon Sep 17 00:00:00 2001 From: 1 <1@72wo.cn> Date: Sun, 28 Sep 2025 09:31:08 +0000 Subject: [PATCH] =?UTF-8?q?refactor(fight/input):=20=E7=A7=BB=E9=99=A4Dama?= =?UTF-8?q?ge=5FPost=E7=9B=B8=E5=85=B3=E9=80=BB=E8=BE=91=EF=BC=8C=E6=B8=85?= =?UTF-8?q?=E7=90=86=E4=BC=A4=E5=AE=B3=E7=BB=93=E7=AE=97=E5=90=8E=E8=A7=A6?= =?UTF-8?q?=E5=8F=91=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- logic/service/fight/input/effecti.go | 2 +- logic/service/fight/input/fight.go | 11 +---------- logic/service/fight/input/input.go | 2 +- 3 files changed, 3 insertions(+), 12 deletions(-) diff --git a/logic/service/fight/input/effecti.go b/logic/service/fight/input/effecti.go index 598e3b12..cc4f1ae8 100644 --- a/logic/service/fight/input/effecti.go +++ b/logic/service/fight/input/effecti.go @@ -22,7 +22,7 @@ type Effect interface { Damage_SUB(ctx Ctx) bool // 受击触发 这时候就是点数减伤 Damage_Lock(ctx Ctx) bool //锁定伤害 - Damage_Post(ctx Ctx) bool // 伤害结算后触发(血量扣除后),克制等重写伤害 + //Damage_Post(ctx Ctx) bool // 伤害结算后触发(血量扣除后),克制等重写伤害 Damage_Shield(ctx Ctx) bool // 护盾值变化时触发 Damage_Use(ctx Ctx) bool // 伤害作用 Skill_SubPP(ctx Ctx) bool //技能PP减少节点 diff --git a/logic/service/fight/input/fight.go b/logic/service/fight/input/fight.go index 10984297..7c56eacc 100644 --- a/logic/service/fight/input/fight.go +++ b/logic/service/fight/input/fight.go @@ -90,22 +90,13 @@ func (u *Input) Damage(ctx Ctx) { return true }) } - ctx.Input.DamageZone.BeforePost = ctx.DamageZone.Damage - if ok { - ok = ctx.Input.Exec(func(t Effect) bool { - - t.Damage_Lock(ctx) - - return true - }) - } if ctx.DamageZone.Type == info.DamageType.Red { ctx.AttackValue.LostHp = uint32(ctx.DamageZone.Damage.IntPart()) //红伤落实 } if uint32(ctx.DamageZone.Damage.IntPart()) > u.CurrentPet.Info.Hp { - + u.CurrentPet.Info.Hp = 0 } else { u.CurrentPet.Info.Hp = u.CurrentPet.Info.Hp - ctx.AttackValue.LostHp diff --git a/logic/service/fight/input/input.go b/logic/service/fight/input/input.go index 19893d91..4c9b5451 100644 --- a/logic/service/fight/input/input.go +++ b/logic/service/fight/input/input.go @@ -26,7 +26,7 @@ type Input struct { BeforeDiv decimal.Decimal BeforeSUB decimal.Decimal BeforeLock decimal.Decimal //锁伤 先锁受击方,再锁攻击方 受击方免疫也是这么锁 免疫等于锁0 - BeforePost decimal.Decimal + //BeforePost decimal.Decimal //OldAttack int //攻击伤害被挡前伤害记录 } //伤害容器