summaryrefslogtreecommitdiffstats
path: root/src/network/room_member.h
diff options
context:
space:
mode:
authorB3n30 <benediktthomas@gmail.com>2017-07-09 15:06:02 +0200
committerB3n30 <benediktthomas@gmail.com>2017-07-16 21:29:57 +0200
commit859be35d54fda177a237e0c24bc1eaca76f1936d (patch)
tree87d277c722f269a1b8ca2186ec1e3ddbe8e4397a /src/network/room_member.h
parentNetwork: Enable sending and receiving chat messages (diff)
downloadyuzu-859be35d54fda177a237e0c24bc1eaca76f1936d.tar
yuzu-859be35d54fda177a237e0c24bc1eaca76f1936d.tar.gz
yuzu-859be35d54fda177a237e0c24bc1eaca76f1936d.tar.bz2
yuzu-859be35d54fda177a237e0c24bc1eaca76f1936d.tar.lz
yuzu-859be35d54fda177a237e0c24bc1eaca76f1936d.tar.xz
yuzu-859be35d54fda177a237e0c24bc1eaca76f1936d.tar.zst
yuzu-859be35d54fda177a237e0c24bc1eaca76f1936d.zip
Diffstat (limited to '')
-rw-r--r--src/network/room_member.h27
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 {
/// Information about the received WiFi packets.
/// Acts as our own 802.11 header.
struct WifiPacket {
- enum class PacketType { Beacon, Data, Management };
- PacketType type; ///< The type of 802.11 frame, Beacon / Data.
- std::vector<uint8_t> data; ///< Raw 802.11 frame data, starting at the management frame header
- /// for management frames.
+ enum class PacketType { Beacon, Data, Authentication, AssociationResponse };
+ PacketType type; ///< The type of 802.11 frame.
+ std::vector<u8> data; ///< Raw 802.11 frame data, starting at the management frame header
+ /// for management frames.
MacAddress transmitter_address; ///< Mac address of the transmitter.
MacAddress destination_address; ///< Mac address of the receiver.
- uint8_t channel; ///< WiFi channel where this frame was transmitted.
+ u8 channel; ///< WiFi channel where this frame was transmitted.
};
/// Represents a chat message.
@@ -70,6 +70,17 @@ public:
* Returns information about the members in the room we're currently connected to.
*/
const MemberList& GetMemberInformation() const;
+
+ /**
+ * Returns the nickname of the RoomMember.
+ */
+ const std::string& GetNickname() const;
+
+ /**
+ * Returns the MAC address of the RoomMember.
+ */
+ const MacAddress& GetMacAddress() const;
+
/**
* Returns information about the room we're currently connected to.
*/
@@ -100,6 +111,12 @@ public:
void SendChatMessage(const std::string& message);
/**
+ * Sends the current game name to the room.
+ * @param game_name The game name.
+ */
+ void SendGameName(const std::string& game_name);
+
+ /**
* Leaves the current room.
*/
void Leave();