class
#include <bn_link_state.h>
link_state Stores the state of a communication through the link cable.
Constructors, destructors, conversion operators
-
link_state(int current_player_id,
const vector<link_
player, 3>& other_players) - Constructor.
-
link_state(int current_player_id,
int player_count,
const vector<link_
player, 3>& other_players) - Constructor.
Public functions
- auto current_player_id() const -> int
- Returns the ID of this player.
- auto player_count() const -> int
- Returns the number of connected players (including this one).
-
auto other_players() const -> const ivector<link_
player>& - Returns the data provided by the other players.
Friends
-
auto operator==(const link_
state& a, const link_ state& b) -> bool defaulted - Default equal operator.
Function documentation
bn:: link_state:: link_state(int current_player_id,
const vector<link_ player, 3>& other_players)
Constructor.
Parameters | |
---|---|
current_player_id | ID of this player, in the range [0..3]. |
other_players | Data provided by the other players. |
bn:: link_state:: link_state(int current_player_id,
int player_count,
const vector<link_ player, 3>& other_players)
Constructor.
Parameters | |
---|---|
current_player_id | ID of this player, in the range [0..3]. |
player_count | Number of connected players (including this one). |
other_players | Data provided by the other players. |