gpg:: RealTimeRoomConfig:: Builder
#include <real_time_room_config_builder.h>
Builds one or more RealTimeRoomConfig objects.
Summary
Constructors and Destructors |
|
---|---|
Builder()
|
Public functions |
|
---|---|
AddAllPlayersToInvite(const std::vector< std::string > & player_ids)
|
Builder &
Adds multiple players to the list of players to invite to the room.
|
AddPlayerToInvite(const std::string & player_id)
|
Builder &
Adds a player to the list of players to invite to the room.
|
Create() const
|
Creates a
RealTimeRoomConfig object. |
PopulateFromPlayerSelectUIResponse(const RealTimeMultiplayerManager::PlayerSelectUIResponse & response)
|
Builder &
Populates values obtained by the
RealTimeMultiplayerManager::PlayerSelectUIResponse method. |
SetExclusiveBitMask(uint64_t exclusive_bit_mask)
|
Builder &
A bit mask indicating exclusive roles for players.
|
SetMaximumAutomatchingPlayers(uint32_t maximum_automatching_players)
|
Builder &
The maximum number of auto-matched players who can join the room.
|
SetMinimumAutomatchingPlayers(uint32_t minimum_automatching_players)
|
Builder &
The minimum number of auto-matched players who can join the room.
|
SetVariant(uint32_t variant)
|
Builder &
A developer-specific value used to indicate room type or mode.
|
Public functions
AddAllPlayersToInvite
Builder & AddAllPlayersToInvite( const std::vector< std::string > & player_ids )
Adds multiple players to the list of players to invite to the room.
By default, no players are added.
AddPlayerToInvite
Builder & AddPlayerToInvite( const std::string & player_id )
Adds a player to the list of players to invite to the room.
By default, no players are added to the room. The builder cannot create a room until players are added.
Builder
Builder()
PopulateFromPlayerSelectUIResponse
Builder & PopulateFromPlayerSelectUIResponse( const RealTimeMultiplayerManager::PlayerSelectUIResponse & response )
Populates values obtained by the RealTimeMultiplayerManager::PlayerSelectUIResponse
method.
Note that this does not populate the variant or the exclusive bit mask.
SetExclusiveBitMask
Builder & SetExclusiveBitMask( uint64_t exclusive_bit_mask )
A bit mask indicating exclusive roles for players.
(For example, one player as attacker, the other as defender.) Successful auto-matching requires that the logical product (AND) of the bit mask of any paired players equals 0. Defaults to 0.
SetMaximumAutomatchingPlayers
Builder & SetMaximumAutomatchingPlayers( uint32_t maximum_automatching_players )
The maximum number of auto-matched players who can join the room.
Left unspecified, defaults to a value equal to the minimum number of auto-matching players.
SetMinimumAutomatchingPlayers
Builder & SetMinimumAutomatchingPlayers( uint32_t minimum_automatching_players )
The minimum number of auto-matched players who can join the room.
Defaults to 0 when left unspecified. At least one auto-matching player or player id must be added.
SetVariant
Builder & SetVariant( uint32_t variant )
A developer-specific value used to indicate room type or mode.
Only players using the same variant can auto-match. Defaults to -1 when left unspecified.