Photon .NET Client API 4.1.4.8

Public Member Functions | Public Attributes | Static Public Attributes | Properties | List of all members
Photon.Realtime.TypedLobby Class Reference

Refers to a specific lobby on the server. More...

Inheritance diagram for Photon.Realtime.TypedLobby:
Photon.Realtime.TypedLobbyInfo

Public Member Functions

 TypedLobby (string name, LobbyType type)
 Sets Name and Type of the new instance. Make sure name is not empty or null, as that always points to the "default lobby" (TypedLobby.Default). More...
 
override string ToString ()
 

Public Attributes

string Name
 Name of the lobby. Default: null, pointing to the "default lobby". More...
 
LobbyType Type
 Type (and behaviour) of the lobby. More...
 

Static Public Attributes

static readonly TypedLobby Default = new TypedLobby()
 A reference to the default lobby which is the unique lobby that uses null as name and is of type LobbyType.Default. More...
 

Properties

bool IsDefault [get]
 Returns whether or not this instance points to the "default lobby" (TypedLobby.Default). More...
 

Detailed Description

Refers to a specific lobby on the server.

Name and Type combined are the unique identifier for a lobby.
The server will create lobbies "on demand", so no registration or setup is required.
An empty or null Name always points to the "default lobby" as special case.

Constructor & Destructor Documentation

◆ TypedLobby()

Photon.Realtime.TypedLobby.TypedLobby ( string  name,
LobbyType  type 
)
inline

Sets Name and Type of the new instance. Make sure name is not empty or null, as that always points to the "default lobby" (TypedLobby.Default).

Parameters
nameSome string to identify a lobby.
typeThe type of a lobby defines it's capabilities and behaviour.

Member Function Documentation

◆ ToString()

override string Photon.Realtime.TypedLobby.ToString ( )
inline

Member Data Documentation

◆ Default

readonly TypedLobby Photon.Realtime.TypedLobby.Default = new TypedLobby()
static

A reference to the default lobby which is the unique lobby that uses null as name and is of type LobbyType.Default.

There is only a single lobby with an empty name on the server. It is always of type LobbyType.Default.
On the other hand, this is a shortcut and reusable reference to the default lobby.
Do not change Name or Type.

◆ Name

string Photon.Realtime.TypedLobby.Name

Name of the lobby. Default: null, pointing to the "default lobby".

If Name is null or empty, a TypedLobby will point to the "default lobby". This ignores the Type value and always acts as LobbyType.Default.

◆ Type

LobbyType Photon.Realtime.TypedLobby.Type

Type (and behaviour) of the lobby.

An empty or null Name always points to the "default lobby" as special case.

Property Documentation

◆ IsDefault

bool Photon.Realtime.TypedLobby.IsDefault
get

Returns whether or not this instance points to the "default lobby" (TypedLobby.Default).

This comes up to checking if the Name is null or empty. LobbyType.Default is not the same thing as the "default lobby" (TypedLobby.Default).


The documentation for this class was generated from the following file: