From 023b937d4985f5a2eef4f9a4ff851997744cefb4 Mon Sep 17 00:00:00 2001 From: 1 <1@72wo.cn> Date: Tue, 23 Sep 2025 21:01:30 +0000 Subject: [PATCH] =?UTF-8?q?refactor(fight/effect):=20=E6=96=B0=E5=A2=9EEff?= =?UTF-8?q?ectStatus.UseSkill=E6=96=B9=E6=B3=95=E5=B9=B6=E6=B8=85=E7=90=86?= =?UTF-8?q?AI=5Fplayer=E4=B8=AD=E6=97=A0=E7=94=A8=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- logic/service/fight/effect/effect_status.go | 6 +++++- logic/service/player/ai.go | 5 ++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/logic/service/fight/effect/effect_status.go b/logic/service/fight/effect/effect_status.go index 347a9bcd..fcb120f2 100644 --- a/logic/service/fight/effect/effect_status.go +++ b/logic/service/fight/effect/effect_status.go @@ -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{}) diff --git a/logic/service/player/ai.go b/logic/service/player/ai.go index 62a06b50..c6646f8b 100644 --- a/logic/service/player/ai.go +++ b/logic/service/player/ai.go @@ -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("战斗结束") }