Files
bl/logic/service/fight/effect/555.go
xinian 875ad668aa
Some checks failed
ci/woodpecker/push/my-first-workflow Pipeline failed
feat: 实现战斗效果逻辑和接口重构
2026-03-28 21:57:22 +08:00

41 lines
670 B
Go

package effect
import (
"blazing/logic/service/fight/input"
"blazing/logic/service/fight/node"
)
// Effect 555: 若打出致命一击则自身{0}回合内免疫异常状态
type Effect555 struct {
node.EffectNode
can bool
}
func (e *Effect555) SkillHit_ex() bool {
if e.Ctx().SkillEntity != nil && e.Ctx().SkillEntity.Crit != 0 {
e.can = true
}
return true
}
func (e *Effect555) EFFect_Befer(in *input.Input, effEffect input.Effect) bool {
if !e.can {
return true
}
if in != e.Ctx().Opp {
return true
}
if input.IS_Stat(effEffect) {
return false
}
return true
}
func init() {
input.InitEffect(input.EffectType.Skill, 555, &Effect555{})
}