From 02e12388db2a357bdf2036d3cec4ce9e088c446d Mon Sep 17 00:00:00 2001 From: GuoWQ222 Date: Sun, 12 May 2024 10:38:35 +0800 Subject: [PATCH 1/2] Urgent:Spectator Message Block --- logic/Server/RpcServices.cs | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/logic/Server/RpcServices.cs b/logic/Server/RpcServices.cs index 5ada9445..f8f1f8ab 100755 --- a/logic/Server/RpcServices.cs +++ b/logic/Server/RpcServices.cs @@ -74,16 +74,17 @@ public override async Task AddPlayer(PlayerMsg request, IServerStreamWriter= 0; i--) + for (int i = info.ObjMessage.Count - 1; i >= 0; i--) { - if (currentGameInfo.ObjMessage[i].NewsMessage != null) + if (info.ObjMessage[i].NewsMessage != null) { - currentGameInfo.ObjMessage.RemoveAt(i); + info.ObjMessage.RemoveAt(i); } } - await responseStream.WriteAsync(currentGameInfo); + await responseStream.WriteAsync(info); GameServerLogging.logger.ConsoleLog("Send!", false); } } From 83e8a6addf2de4130477d5bfa636b2d245145810 Mon Sep 17 00:00:00 2001 From: GuoWQ222 Date: Sun, 12 May 2024 22:08:45 +0800 Subject: [PATCH 2/2] fix:Spectator Message Block --- logic/Server/RpcServices.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/logic/Server/RpcServices.cs b/logic/Server/RpcServices.cs index f8f1f8ab..5976e25b 100755 --- a/logic/Server/RpcServices.cs +++ b/logic/Server/RpcServices.cs @@ -74,9 +74,9 @@ public override async Task AddPlayer(PlayerMsg request, IServerStreamWriter= 0; i--) { if (info.ObjMessage[i].NewsMessage != null)