diff --git a/server/matchserver/player/playermgr.go b/server/matchserver/player/playermgr.go index df66651f..18c4fb5a 100644 --- a/server/matchserver/player/playermgr.go +++ b/server/matchserver/player/playermgr.go @@ -92,6 +92,7 @@ func (this *playerMgr) CMLogin(hdr *f5.MsgHdr, msg *cs.CMLogin) { rspMsg.TeamUuid = proto.String(oldHum.GetTeam().GetTeamUuid()) oldHum.reBind(hdr.GetSocket(), msg.GetSessionId()) oldHum.SendMsg(&rspMsg) + GetHistoryMgr().PushLastBattleInfo(oldHum) return } } @@ -328,6 +329,7 @@ func (this *playerMgr) CMReconnect(hdr *f5.MsgHdr, msg *cs.CMReconnect) { } hum.reBind(hdr.GetSocket(), msg.GetSessionId()) GetWspListener().SendProxyMsg(hdr.Conn, hdr.SocketHandle, rspMsg) + GetHistoryMgr().PushLastBattleInfo(hum) } func (this *playerMgr) OnSocketClose(conn f5.WspCliConn) { diff --git a/server/matchserver/team/teammgr.go b/server/matchserver/team/teammgr.go index 1a7623ec..3d2c5936 100644 --- a/server/matchserver/team/teammgr.go +++ b/server/matchserver/team/teammgr.go @@ -6,6 +6,7 @@ import ( "cs" "main/common" "main/mt" + . "main/global" ) type teamMgr struct { @@ -66,7 +67,7 @@ func (this *teamMgr) GetTeamByUuid(teamUuid string) common.Team { } func (this *teamMgr) OnEnterNewUser(hum common.Player) { - + GetHistoryMgr().PushLastBattleInfo(hum) } func (this *teamMgr) removeTeam(teamUuid string) {