refactor(fight/effect): 新增EffectStatus.UseSkill方法并清理AI_player中无用代码

This commit is contained in:
1
2025-09-23 21:01:30 +00:00
parent 1ec9d46b23
commit 023b937d49
2 changed files with 7 additions and 4 deletions

View File

@@ -12,12 +12,16 @@ type EffectStatus struct {
status info.EnumBattleStatus
}
func (e *EffectStatus) UseSkill(opp *input.Input) bool {
return false
}
func init() {
//麻痹,疲惫,害怕,石化,都是无法行动
tt := func(t info.EnumBattleStatus, f *EffectStatus) {
f.status=t
f.status = t
input.InitStatusEffect(int(t), f)
}
tt(info.BattleStatus.Paralysis, &EffectStatus{})

View File

@@ -21,8 +21,7 @@ func (f *AI_player) SendPack(b []byte) error {
func (f *AI_player) SendReadyToFightInfo(gg info.FightStartOutboundInfo) {
fmt.Println(gg)
// f.FightC.UseSkill(f, f.fightinfo.OpponentPetList[0].SkillList[0].ID) //使用1#技能,实际上要按照四个技能权重去使用
//这时候给个出招
}
func (f *AI_player) SendNoteReadyToFightInfo(fs info.NoteReadyToFightInfo) {
@@ -30,7 +29,7 @@ func (f *AI_player) SendNoteReadyToFightInfo(fs info.NoteReadyToFightInfo) {
}
func (f *AI_player) SendFightEndInfo(_ info.FightOverInfo) {
f.FightC = nil
//fmt.Println("战斗结束")
}