Save disconnect frame in the GameInformation

This information is useful to infer a winner in case the winstate is
unknown.
This commit is contained in:
Clément Bœsch
2020-07-26 21:56:37 +02:00
committed by abcdefg30
parent ca8870a5cf
commit 815bbc6ee8
4 changed files with 24 additions and 0 deletions

View File

@@ -39,7 +39,13 @@ namespace OpenRA.Network
{
var client = orderManager.LobbyInfo.ClientWithIndex(clientId);
if (client != null)
{
client.State = Session.ClientState.Disconnected;
var player = world?.FindPlayerByClient(client);
if (player != null)
world.OnPlayerDisconnected(player);
}
break;
}