Find the real-time matchmaking queue size

Hello!
I’m trying to give the user that has a matchmaking ticket, a feedback that they are in the queue. The goal is to show the player the amount of people that also have received a ticket.

I haven’t found a direct interface from Nakama giving this info to users.

I have two ways in mind for doing it manually. I wanted to ask others opinions too;

  1. Create a public group. Add people with matchmaking ticket to that group and remove them when they cancel or find a match. The size of that group is thing we’re looking for.

  2. Increment a storage object value when Nakama detects a MatchmakerAdd. Remove when MatchmakerRemove happens or a match is found.

Are there better ways? Or is there a direct way to do this that I couldn’t find?

Thank you

Hi amuuu,

What do plan to achieve by providing that information to the user? A sense of progress or how busy that game mode is?

Best,
Flávio

Thank you.

The user knows the matches need 10 players for example. We want to show them that roughly what percentage of those 10 needed players are matched with them. So that if they have been waiting for too long and only 2-3 players are matched, they cancel if they want. But if they are 8-9 players matched, they can keep waiting.

The matchmaking can have a variable length of time to finish, thus the counter and/or progress concept won’t allow you to accurately determine that it will finish any time soon.

Another approach you can take is to provide the average waiting time (or other metric like percentiles) during the last X time units (hours,weeks,etc) for the matchmaking.

1 Like

That’s a nice idea. What would be a good way to implement it? Like counting the ticks from when a match ticket is created until when that player has a match found for them?

Hi amuuu,

Counting the number of tickets, forces you to then have a predefined time per ticket that you will multiple by, in order to provide a user friendly metric.

Using the MatchmakerTicket to find out when it started and the MatchmakerMatched to know when it ended, will give you the duration of the process to speculate on future matchmakings.

Best,
Flávio

1 Like