2026-03-08 11:22:00 +08:00
|
|
|
package effect
|
|
|
|
|
|
|
|
|
|
import (
|
|
|
|
|
element "blazing/common/data/Element"
|
|
|
|
|
"blazing/logic/service/fight/info"
|
|
|
|
|
"blazing/logic/service/fight/input"
|
|
|
|
|
"blazing/logic/service/fight/node"
|
|
|
|
|
)
|
|
|
|
|
|
2026-03-28 21:57:22 +08:00
|
|
|
// Effect 464: 遇到天敌时{0}%令对手烧伤
|
2026-03-08 11:22:00 +08:00
|
|
|
type Effect464 struct {
|
|
|
|
|
node.EffectNode
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
func (e *Effect464) OnSkill() bool {
|
|
|
|
|
t, _ := element.Calculator.GetOffensiveMultiplier(e.Ctx().Opp.CurrentPet.Type, e.Ctx().Our.CurrentPet.Type)
|
|
|
|
|
|
|
|
|
|
if t <= 1 {
|
|
|
|
|
return true
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
chance := e.Args()[0].IntPart()
|
|
|
|
|
success, _, _ := e.Input.Player.Roll(int(chance), 100)
|
|
|
|
|
if success {
|
|
|
|
|
burnEffect := e.Ctx().Our.InitEffect(input.EffectType.Status, int(info.PetStatus.Burned))
|
|
|
|
|
if burnEffect != nil {
|
|
|
|
|
e.Ctx().Opp.AddEffect(e.Ctx().Our, burnEffect)
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
return true
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
func init() {
|
|
|
|
|
input.InitEffect(input.EffectType.Skill, 464, &Effect464{})
|
|
|
|
|
|
|
|
|
|
}
|