diff options
| author | 2017-07-09 15:06:02 +0200 | |
|---|---|---|
| committer | 2017-07-16 21:29:57 +0200 | |
| commit | 859be35d54fda177a237e0c24bc1eaca76f1936d (patch) | |
| tree | 87d277c722f269a1b8ca2186ec1e3ddbe8e4397a /src/network/room_member.h | |
| parent | Network: Enable sending and receiving chat messages (diff) | |
| download | yuzu-859be35d54fda177a237e0c24bc1eaca76f1936d.tar.gz yuzu-859be35d54fda177a237e0c24bc1eaca76f1936d.tar.xz yuzu-859be35d54fda177a237e0c24bc1eaca76f1936d.zip | |
Network: Send the game title
Diffstat (limited to 'src/network/room_member.h')
| -rw-r--r-- | src/network/room_member.h | 27 |
1 files changed, 22 insertions, 5 deletions
diff --git a/src/network/room_member.h b/src/network/room_member.h index 693aa4e7f..d874cc5e4 100644 --- a/src/network/room_member.h +++ b/src/network/room_member.h | |||
| @@ -15,13 +15,13 @@ namespace Network { | |||
| 15 | /// Information about the received WiFi packets. | 15 | /// Information about the received WiFi packets. |
| 16 | /// Acts as our own 802.11 header. | 16 | /// Acts as our own 802.11 header. |
| 17 | struct WifiPacket { | 17 | struct WifiPacket { |
| 18 | enum class PacketType { Beacon, Data, Management }; | 18 | enum class PacketType { Beacon, Data, Authentication, AssociationResponse }; |
| 19 | PacketType type; ///< The type of 802.11 frame, Beacon / Data. | 19 | PacketType type; ///< The type of 802.11 frame. |
| 20 | std::vector<uint8_t> data; ///< Raw 802.11 frame data, starting at the management frame header | 20 | std::vector<u8> data; ///< Raw 802.11 frame data, starting at the management frame header |
| 21 | /// for management frames. | 21 | /// for management frames. |
| 22 | MacAddress transmitter_address; ///< Mac address of the transmitter. | 22 | MacAddress transmitter_address; ///< Mac address of the transmitter. |
| 23 | MacAddress destination_address; ///< Mac address of the receiver. | 23 | MacAddress destination_address; ///< Mac address of the receiver. |
| 24 | uint8_t channel; ///< WiFi channel where this frame was transmitted. | 24 | u8 channel; ///< WiFi channel where this frame was transmitted. |
| 25 | }; | 25 | }; |
| 26 | 26 | ||
| 27 | /// Represents a chat message. | 27 | /// Represents a chat message. |
| @@ -70,6 +70,17 @@ public: | |||
| 70 | * Returns information about the members in the room we're currently connected to. | 70 | * Returns information about the members in the room we're currently connected to. |
| 71 | */ | 71 | */ |
| 72 | const MemberList& GetMemberInformation() const; | 72 | const MemberList& GetMemberInformation() const; |
| 73 | |||
| 74 | /** | ||
| 75 | * Returns the nickname of the RoomMember. | ||
| 76 | */ | ||
| 77 | const std::string& GetNickname() const; | ||
| 78 | |||
| 79 | /** | ||
| 80 | * Returns the MAC address of the RoomMember. | ||
| 81 | */ | ||
| 82 | const MacAddress& GetMacAddress() const; | ||
| 83 | |||
| 73 | /** | 84 | /** |
| 74 | * Returns information about the room we're currently connected to. | 85 | * Returns information about the room we're currently connected to. |
| 75 | */ | 86 | */ |
| @@ -100,6 +111,12 @@ public: | |||
| 100 | void SendChatMessage(const std::string& message); | 111 | void SendChatMessage(const std::string& message); |
| 101 | 112 | ||
| 102 | /** | 113 | /** |
| 114 | * Sends the current game name to the room. | ||
| 115 | * @param game_name The game name. | ||
| 116 | */ | ||
| 117 | void SendGameName(const std::string& game_name); | ||
| 118 | |||
| 119 | /** | ||
| 103 | * Leaves the current room. | 120 | * Leaves the current room. |
| 104 | */ | 121 | */ |
| 105 | void Leave(); | 122 | void Leave(); |