From c6e03f42ce7243feb8603a491b42eab642e2688d Mon Sep 17 00:00:00 2001 From: aozhiwei Date: Fri, 20 Sep 2024 14:33:44 +0800 Subject: [PATCH] 1 --- server/matchserver/history/historymgr.go | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/server/matchserver/history/historymgr.go b/server/matchserver/history/historymgr.go index 03a8cc09..65a68c6a 100644 --- a/server/matchserver/history/historymgr.go +++ b/server/matchserver/history/historymgr.go @@ -4,6 +4,7 @@ import ( "q5" "cs" "main/common" + "github.com/golang/protobuf/proto" ) type historyMgr struct { @@ -33,6 +34,14 @@ func (this *historyMgr) PushLastBattleInfo(hum common.Player) { } msg := new(cs.SMPushLastBattleInfo) q5.NewSlice(&msg.BattleList, 0, 10) + for key, val := range(u.mapAndModeHash) { + mapId := int32(key) + modeId := int32(key) + p := new(cs.MFLastBattleInfo) + p.MapId = proto.Int32(mapId) + p.ModeId = proto.Int32(modeId) + p.StartTime = proto.Int32(val) + } hum.SendMsg(msg) }