Class JoinByCodeRequest
The body of a Join Lobby request using lobby code.
Inherited Members
Namespace: Unity.Services.Lobbies.Models
Assembly: Unity.Services.Lobbies.dll
Syntax
[Preserve]
[DataContract(Name = "JoinByCodeRequest")]
public class JoinByCodeRequest
Constructors
JoinByCodeRequest(string, Player, string)
The body of a Join Lobby request using lobby code.
Declaration
[Preserve]
public JoinByCodeRequest(string lobbyCode, Player player = null, string password = null)
Parameters
Type | Name | Description |
---|---|---|
string | lobbyCode | The lobby code of the lobby to join. Mutually exclusive with |
Player | player | player param |
string | password | The password to the target lobby. If target lobby HasPassword is true, this password must match or the request is denied. |
Properties
LobbyCode
The lobby code of the lobby to join. Mutually exclusive with id
. This is used to join a private lobby where the lobby code was shared to other users manually.
Declaration
[Preserve]
[DataMember(Name = "lobbyCode", IsRequired = true, EmitDefaultValue = true)]
public string LobbyCode { get; }
Property Value
Type | Description |
---|---|
string |
Password
The password to the target lobby. If target lobby HasPassword is true, this password must match or the request is denied.
Declaration
[Preserve]
[DataMember(Name = "password", EmitDefaultValue = false)]
public string Password { get; }
Property Value
Type | Description |
---|---|
string |
Player
Parameter player of JoinByCodeRequest
Declaration
[Preserve]
[DataMember(Name = "player", EmitDefaultValue = false)]
public Player Player { get; }
Property Value
Type | Description |
---|---|
Player |