Game Server Management #
Match Lifecycle and Match Capacity services manage assigning matches, managing the player session, and processing match end results.
Match Lifecycle #
The Match Lifecycle service accepts match requests from Matchmaking. It updates the player session to support several key features, This includes reconnecting to a match in the event of a crash or disconnect, and gatekeeper functionality such as preventing players from starting new parties or matches until their current one is complete.
This service is also responsible for processing match end events. This includes making parallel requests to all services that need to process match results, aggregating the respective results, and finally sending the match results notification to players.
Match Reconnect #
Pragma Engine provides a way to reconnect players who disconnected while in a match within the game loop. Once the player logs back, the engine sends a notification to the player’s client with the match details so they can reconnect if the match is still active. The client can use these connection details to reconnect to the match. This feature can be disabled via the SessionConfig.enableMatchReconnect
config value.
Match Reconnect only works in the Party service game flows. It does not work in the old Lobby-based game flows.
Match Capacity #
Match Capacity is responsible for processing match requests and coordinating with a game server management provider to allocate game servers.
This includes configuration to support maintaining a headroom of available capacity to keep servers ready ahead of time, configuring capacity limits, etc.
Pragma Engine supports several game server hosting solutions, providing first party support and integration across cloud providers and independent options.
Quick Guides #
Managing a match reconnect scenario #
Pragma Engine provides MatchReconnectV1
endpoint access within the Party service. This can be used to trigger resending the connection details to an active match.
Below are the steps for a sample scenario, along with the relevant calls for each stage in both Unity and Unreal.
The Matchmaking service forms a match once a party enters matchmaking.
unity unreal PragmaSession.Party.EnterMatchmakingV1
PragmaSession().Party().StartMatchmakingV1
A
MatchReady
notification with connection details is sent to every player within the match.unity unreal PragmaSession.Party.OnMatchReady
PragmaSession().Party().OnMatchReady
Account.Login
: A player loses their connection during the match and needs to reconnect.unity unreal PragmaSession.Account.Login
PragmaSession().Account().Login
A notification with match connection details is sent to the player’s client on login. The reconnect endpoint causes the
OnMatchReconnect
event, allowing the player to connect back to their game using the rebroadcasted match connection information.unity unreal PragmaSession.Party.OnMatchReconnect
PragmaSession().Party().OnMatchReconnect
The SDK offers rich support to determine whether a player can call MatchReconnectV1
.
- If the player’s client needs to request details again, it can manually invoke the
MatchReconnectV1
endpoint. (optional)unity unreal PragmaSession.Party.MatchReconnectV1
PragmaSession().Party().MatchReconnectV1