fix(fight): 修复空变更提交问题

This commit is contained in:
1
2025-11-10 04:17:27 +00:00
parent b157d6bc40
commit 3b84572455
2 changed files with 2 additions and 2 deletions

View File

@@ -25,11 +25,10 @@ func (p *Player) SendNoteReadyToFightInfo(b info.NoteReadyToFightInfo) {
p.SendPack(t1.Pack(&b)) //准备包由各自发,因为协议不一样
}
func (p *Player) SendFightEndInfo(b info.FightOverInfo) {
p.FightC = nil
t1 := NewTomeeHeader(2506, p.Info.UserID)
p.SendPack(t1.Pack(&b))
p.FightC = nil
}

View File

@@ -331,6 +331,7 @@ func (p *Player) Save() {
}()
p.FightC.Over(p, info.BattleOverReason.PlayerOffline) //玩家逃跑,但是不能锁线程
}()
<-p.FightC.GetOverChan() //等待结束
}
p.Info.TimeToday = p.Info.TimeToday + uint32(time.Now().Unix()) - uint32(p.Onlinetime) //保存电池时间