Files
bl/logic/service/fight/effect/effect_116.go

43 lines
802 B
Go
Raw Normal View History

package effect
import (
"blazing/logic/service/fight/action"
"blazing/logic/service/fight/input"
"blazing/logic/service/fight/node"
"github.com/alpacahq/alpacadecimal"
)
/**
* n回合若自己先手则伤害的1/5回复体力
*/
func init() {
t := &Effect116{
EffectNode: node.EffectNode{},
}
2025-11-21 05:47:51 +00:00
input.InitEffect(input.EffectType.Skill, 116, t)
}
type Effect116 struct {
node.EffectNode
}
// 默认添加回合
func (e *Effect116) SetArgs(t *input.Input, a ...int) {
e.EffectNode.SetArgs(t, a...)
e.EffectNode.Duration(e.EffectNode.SideEffectArgs[0])
}
func (e *Effect116) SkillUseed() bool {
if e.Input.FightC.IsFirst(e.Input.Player) {
e.Ctx().Our.Heal(e.Ctx().Our, &action.SelectSkillAction{}, e.Ctx().Our.SumDamage.Div(alpacadecimal.NewFromInt(5)))
}
return true
}