fix(task): 修复任务奖励与宠物

This commit is contained in:
2025-11-08 18:37:11 +08:00
parent c916440033
commit b864576ca9
11 changed files with 89 additions and 39 deletions

View File

@@ -5,7 +5,6 @@ import (
"blazing/logic/service/fight/input"
"blazing/logic/service/fight/node"
"github.com/brunoga/deep"
"github.com/shopspring/decimal"
)
@@ -28,9 +27,16 @@ func (e *Effect29) OnSkill(ctx input.Ctx) bool {
if !e.Hit() {
return true
}
eff := deep.MustCopy(ctx)
eff.DamageZone.Type = info.DamageType.Fixed
ctx.DamageZone.Damage = decimal.NewFromInt(int64(e.SideEffectArgs[0]))
eff := input.Ctx{
Input: e.Input,
SelectSkillAction: nil,
DamageZone: &info.DamageZone{
Type: info.DamageType.Fixed,
Damage: decimal.NewFromInt(int64(e.SideEffectArgs[0])),
},
}
ctx.Input.Damage(eff)
return true
}