Files
bl/logic/service/fight/boss/NewSeIdx_13.go
昔念 4751594ee8 ```
feat: 更新战斗系统模型结构和Redis消息处理

- 引入gredis依赖用于Redis消息处理
- 将战斗相关的枚举和结构体从info包迁移到model包
- 更新战斗结束原因、攻击值等类型的引用路径
- 添加新的zset工具包到工作区
- 修改Redis消息处理逻辑以正确解析gredis.Message类型
- 在战斗控制器中统一使用model包下的类型定义
2026-03-04 22:47:21 +08:00

29 lines
769 B
Go
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

package effect
import (
"blazing/logic/service/fight/input"
"blazing/modules/player/model"
)
// 13. n 回合逃跑;a1: n, a2: 不逃跑精灵ID, a3/a4: 不逃跑系精灵)
// TODO: 实现n 回合逃跑;a1: n, a2: 不逃跑精灵ID, a3/a4: 不逃跑系精灵)的核心逻辑
type NewSel13 struct {
NewSel0
}
func (e *NewSel13) HookAction() bool {
if e.ID().GetCatchTime() != e.Ctx().Our.CurrentPet.Info.CatchTime {
return true
}
r := e.Ctx().Our.FightC.GetOverInfo()
if r.Round == uint32(e.Args()[0].IntPart()) {
e.Ctx().Our.FightC.Over(e.Ctx().Our.Player, model.BattleOverReason.PlayerEscape)
return false //阻止技能释放
}
return true //阻止技能释放
}
func init() {
input.InitEffect(input.EffectType.NewSel, 13, &NewSel13{})
}