Will match.presences contain the presence of the local player? I’ve seen code in the Nakama documentation that seems to indicate that match.presences contains the local player (https://heroiclabs.com/docs/gameplay-multiplayer-realtime/), but in practice match.presences seems to only return the non local presences.
@GTG101 The match.presences
contain the users who are already in the match. You should subscribe to the socket.ReceivedMatchPresence
action handler (or similar based on whatever SDK you use for Nakama) to receive the presences that join the match or leave after you’ve joined. You can see it covered in the docs here:
https://heroiclabs.com/docs/gameplay-multiplayer-realtime/#list-opponents
Use the match.Self
field which contains the presence for your own socket connection in the match.
Hope this helps.
1 Like
It does help, thanks.
1 Like