fix: 修正Effect71效果计数逻辑
All checks were successful
ci/woodpecker/push/my-first-workflow Pipeline was successful

This commit is contained in:
xinian
2026-03-06 10:40:32 +08:00
committed by cnb
parent 17103cbc9a
commit 26d06c50af

View File

@@ -53,8 +53,10 @@ func (e *Effect71) SwitchIn(in *input.Input) bool {
if in != e.Ctx().Our {
return true
}
t := &Effect71_sub{}
t.Duration(1)
t := &Effect71_sub{
count:2,
}
t.Duration(-1)
tt := e.ID()
tt.SetEffectType(input.EffectType.Sub)
@@ -67,6 +69,7 @@ func (e *Effect71) SwitchIn(in *input.Input) bool {
type Effect71_sub struct {
node.EffectNode
count int
}
func (e *Effect71_sub) ActionStart(a, b *action.SelectSkillAction) bool {
@@ -78,6 +81,10 @@ func (e *Effect71_sub) ActionStart(a, b *action.SelectSkillAction) bool {
if e.Ctx().SkillEntity.Category() == info.Category.STATUS {
return true
}
if e.count <= 0 {
e.Alive(false)
}
e.count--
e.Ctx().SkillEntity.CritRate = 16
return true