Skip to content

Matchmaking

Andrew Bates edited this page Aug 3, 2024 · 2 revisions

Matchmaking

Sequence

3


group matchmaking
GameClient->Pipeline: LobbyFindSession
activate Pipeline
Pipeline-->*MatchmakingSession:<<create>>
activate GameClient
Pipeline->GameClient:LobbyPingRequest
deactivate Pipeline
GameClient->GameServer:ping
activate GameServer
GameServer-->GameClient:pong
deactivate GameServer
GameClient-->Pipeline:PingResults
deactivate GameClient
Pipeline->Pipeline:Stores results to LatencyHistory

MatchmakingSession-->partyHandler:Join Party

MatchmakingSession-->*Member:<<role>>
loop [4 min timeout]

Member->>matchHandler:tries to join leader's lobby (if space)
activate matchHandler
matchHandler--xMember:reject lobby full
deactivate matchHandler
Member->>matchHandler:tries to join leader's lobby
activate matchHandler
matchHandler-->>Member:accept
deactivate matchHandler
Member->matchHandler:Join
end
Member->GameClient:LobbySessionSuccess
destroysilent Member
MatchmakingSession-->*Leader:
group leader
Leader->Leader:Wait 15 seconds
Leader->Leader:"Synchronize" Matchmaking (one cancel == all cancel)
Leader->partyHandler:Kick party members who are not matchmaking



activate Leader
Leader-->matchmaker:File Party Ticket in Matchmaker

Leader->matchHandler:Look for backfills on regular interval
activate matchHandler
matchHandler-->Leader:
destroysilent Leader
deactivate matchHandler
end

matchmaker->matchmaker:MatchMade, builds match

matchmaker->GameClient:LobbySessionSuccess (connection info) to whole party at once

GameClient->GameServer:ping
activate GameServer
GameServer->GameClient:pong
deactivate GameServer

GameServer->Pipeline:New Entrant
activate Pipeline
Pipeline-->GameServer:Accept Entrant
deactivate Pipeline
GameClient->Pipeline:LobbySessionsRequest
Pipeline->GameClient:LobbySessionsSuccess (entrant ID)


Clone this wiki locally