fix: 修正Effect71效果计数逻辑
All checks were successful
ci/woodpecker/push/my-first-workflow Pipeline was successful
All checks were successful
ci/woodpecker/push/my-first-workflow Pipeline was successful
This commit is contained in:
@@ -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
|
||||
|
||||
Reference in New Issue
Block a user