NetPlayProto: Remove now-unused MessageId type alias

Now that we have enum helpers for inserting values into packets and have
migrated all other enumerations over, there's no need to keep this alias
around any longer.
This commit is contained in:
Lioncash 2021-09-22 15:10:31 -04:00
parent a034f378a0
commit 80b4a4d7fd
2 changed files with 4 additions and 3 deletions

View File

@ -122,6 +122,8 @@ struct NetTraversalConfig
enum class MessageID : u8
{
ConnectionSuccessful = 0,
PlayerJoin = 0x10,
PlayerLeave = 0x11,
@ -225,7 +227,6 @@ struct WiimoteInput
u8 report_id;
std::vector<u8> data;
};
using MessageId = u8;
using PlayerId = u8;
using FrameNum = u32;
using PadIndex = s8;

View File

@ -431,9 +431,9 @@ ConnectionError NetPlayServer::OnConnect(ENetPeer* socket, sf::Packet& rpac)
spac << player.pid << player.name << player.revision;
SendToClients(spac);
// send new client success message with their id
// send new client success message with their ID
spac.clear();
spac << static_cast<MessageId>(0);
spac << MessageID::ConnectionSuccessful;
spac << player.pid;
Send(player.socket, spac);