From 7d7cc0d1745babe9674ba762f2d99bd9a603297d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=98=94=E5=BF=B5?= <12574910+72wo@users.noreply.github.com> Date: Sat, 7 Feb 2026 20:50:02 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=A1=94=E7=A6=BB=E5=BC=80bu?= =?UTF-8?q?g?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- logic/controller/fight_塔.go | 2 +- logic/controller/user_task.go | 2 +- logic/service/player/player.go | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/logic/controller/fight_塔.go b/logic/controller/fight_塔.go index 02951fcd..8a137a3b 100644 --- a/logic/controller/fight_塔.go +++ b/logic/controller/fight_塔.go @@ -101,7 +101,7 @@ func (h Controller) FreshLeaveFightLevel(data *fight.FRESH_LEAVE_FIGHT_LEVEL, c out := info.NewOutInfo() copier.CopyWithOption(out, c.GetInfo(), copier.Option{DeepCopy: true}) - c.SendPackCmd(2001, out) + //c.SendPackCmd(2001, out) return result, 0 } diff --git a/logic/controller/user_task.go b/logic/controller/user_task.go index fb20a1e0..cc55df26 100644 --- a/logic/controller/user_task.go +++ b/logic/controller/user_task.go @@ -21,7 +21,7 @@ func (h Controller) AcceptTask(data *task.AcceptTaskInboundInfo, c *player.Playe } taskinfo := service.NewTaskService().IsAcceptable(data.TaskId) if taskinfo == nil { - return nil, errorcode.ErrorCodes.ErrSystemError + return nil, errorcode.ErrorCodes.ErrCannotAcceptDailyTasks } if taskinfo.ParentTaskId != 0 && c.Info.GetTask(int(taskinfo.ParentTaskId)) != model.Completed { return nil, errorcode.ErrorCodes.ErrInsufficientTasksForReward diff --git a/logic/service/player/player.go b/logic/service/player/player.go index 76cd083b..eeba4ba5 100644 --- a/logic/service/player/player.go +++ b/logic/service/player/player.go @@ -253,7 +253,7 @@ func (player1 *Player) Kick(isquit bool) { // --- 新增超时机制核心代码 --- // 设定超时时间(可根据业务需求调整,这里以3秒为例) - const kickTimeout = 5 * time.Second + const kickTimeout = 3 * time.Second select { case <-CloseChan: // 正常流程:连接关闭回调已执行,CloseChan 被关闭