```
Some checks failed
ci/woodpecker/push/my-first-workflow Pipeline failed

fix(fight): 修复技能效果参数错误和伤害统计问题

- 修复effect_508中参数索引错误,将Args()[1]改为Args()[0]
- 修复effect_508中持续时间设置错误,统一设置为1
- 修复战斗伤害统计错误,将我方受伤统计改为对方受伤统计
```
This commit is contained in:
昔念
2026-03-10 09:33:27 +08:00
parent 939ef29800
commit 8992132d13
2 changed files with 4 additions and 4 deletions

View File

@@ -35,8 +35,8 @@ func (e *Effect508) DamageSubEx(t *info.DamageZone) bool {
return true return true
} }
if t.Damage.Cmp(e.Args()[1]) > 0 { if t.Damage.Cmp(e.Args()[0]) > 0 {
t.Damage = t.Damage.Sub(e.Args()[1]) t.Damage = t.Damage.Sub(e.Args()[0])
} else { } else {
t.Damage = alpacadecimal.Zero t.Damage = alpacadecimal.Zero
} }
@@ -45,6 +45,6 @@ func (e *Effect508) DamageSubEx(t *info.DamageZone) bool {
func (e *Effect508) SetArgs(t *input.Input, a ...int) { func (e *Effect508) SetArgs(t *input.Input, a ...int) {
e.EffectNode.SetArgs(t, a...) e.EffectNode.SetArgs(t, a...)
e.EffectNode.Duration(e.EffectNode.SideEffectArgs[0]) e.EffectNode.Duration(1)
} }

View File

@@ -166,7 +166,7 @@ func (our *Input) Damage(in *Input, sub *info.DamageZone) {
}) })
} }
if sub.Type == info.DamageType.Red { //红才会产生造成伤害 if sub.Type == info.DamageType.Red { //红才会产生造成伤害
our.AttackValue.LostHp += uint32(sub.Damage.IntPart()) //红伤落实 our.Opp.AttackValue.LostHp += uint32(sub.Damage.IntPart()) //红伤落实
} }