JoinLobby
method in Coherence.Cloud.LobbiesService
Methods
public void JoinLobby(LobbyData lobby, Action<RequestResponse<LobbySession>> onRequestFinished, List<CloudAttribute> playerAttr = null, string password = null, LobbyReservations reservations = null)
Join the supplied Lobby.
Parameters
| Type | Name | Description |
|---|---|---|
| LobbyData | lobby | The lobby to join. |
| Action<RequestResponse<LobbySession>> | onRequestFinished | Callback that will be invoked when the request finished. |
| List<CloudAttribute> | playerAttr | Optional parameter to add player attributes to the joined Lobby. |
| string | password | Optional parameter to specify the Password to join a private Lobby. |
| LobbyReservations | reservations | Optional slots to reserve for the rest of your party, joining you and reserving them in a single step. Fails with Coherence.Runtime.ErrorCode.LobbyFull, without joining, if the lobby can't fit everyone. Fails with Coherence.Runtime.ErrorCode.LobbyReservationsNotAllowed if it would reserve more new slots than the lobby's MaxReservationsPerRequest. Players already in the lobby, or who already have a reservation, are skipped and don't count, so every member of the party can send the same reservations. |