From 589dc083a58425cadd8390ddd81854dcf054dd27 Mon Sep 17 00:00:00 2001 From: B3n30 Date: Sat, 8 Jul 2017 15:24:47 +0200 Subject: Network: Threads for Room and RoomMember --- src/network/room.h | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) (limited to 'src/network/room.h') diff --git a/src/network/room.h b/src/network/room.h index 70c64d5f1..0a6217c11 100644 --- a/src/network/room.h +++ b/src/network/room.h @@ -4,7 +4,6 @@ #pragma once -#include #include #include #include "common/common_types.h" @@ -19,6 +18,19 @@ struct RoomInformation { u32 member_slots; ///< Maximum number of members in this room }; +// The different types of messages that can be sent. The first byte of each packet defines the type +typedef uint8_t MessageID; +enum RoomMessageTypes { + IdJoinRequest = 1, + IdJoinSuccess, + IdRoomInformation, + IdSetGameName, + IdWifiPacket, + IdChatMessage, + IdNameCollision, + IdMacCollision +}; + /// This is what a server [person creating a server] would use. class Room final { public: -- cgit v1.2.3