Rejecting Matches
For queues that require clients to accept or reject a match within a given time, clients will receive a ClientStatusResponse
message indicating a status of Matched
, instead of the usual ServerAssignmentResponse
message.
The message will also include the match
property containing:
id
- the match idexpiresInMillis
- how long the user has left to accept/reject from time of receiptaccepted
- how many players have acceptedrequired
- how many are required for the match to proceed
{
"msg_type": "ClientStatusResponse",
"msg": {
"status": "Matched",
"latencyMS": 123,
"match": {
"id": "<match-id>",
"expiresInMillis": 29822,
"accepted": 0,
"required": 6
}
}
}
Clients can accept the match by responding with a AcceptMatchRequest
message containing the match ID as the id
value.
{
"msg_type": "AcceptMatchRequest",
"msg": {
"id": "<match-id>"
}
}
The client status will become Accepted
and the client will continue to receive ClientStatusResponse
messages as other players accept the match, until either:
- All users have accepted, or
- One or more users have rejected, or
- The expiry time has passed.
If all users accept, the regular ServerAssignmentResponse
will be received by the client, and they’ll be able to join the specified server.
If another user rejects or times out, the client will be automatically re-queued - the client will receive a new ClientStatusResponse
with a Queued
status if this happens.
The user can explicitly reject a match by sending a RejectMatchRequest
:
{
"msg_type": "RejectMatchRequest",
"msg": {
"id": "<match-id>"
}
}
The client status will become Idle
- users that reject or time out are automatically dequeued, and need to manually re-queue.