I'm researching how to implement reconnecting to a game in progress (e.g. your computer crashed and you want to get back into your match).
Currently, my live title does this via legacy matchmaking by
1. Store current game ID in player data as a "currentgame" field. When a game finishes, this field is cleared by a dedicated lobby server.
2. When the client logs on, it checks if it has a non-null "currentgame." If so, it will fetch server data (indirectly) from a call to PlayFabClientAPI.GetCurrentGames() and connect to the server (i.e. 'reconnect to game in progress').
In game servers 2.0, matchmaking no longer flows through my dedicated lobby server, but instead is communicated between clients and PlayFab.
If I store the matchId in the currentgame field, I can reconnect to a match in progress by calling GetMatch() and connecting to the server in the serverDetails.
However, I don't know how to handle the case where the match already finished by the time my client tries to reconnect to it.
The direct solution that comes to mind is if there was an API call to tell if a matchId was finished (the server that handled this matchId already shut down).
Does such an API call exist?
Alternatively, a naive solution is that the client will always try to connect to the "current game" server, then it will just consider a timeout (failing to connect to the server) as a sign that the match finished. This feels messy to me and potentially buggy given that a timeout could happen for other reasons.