Make header skips more obvious (#1074)

* Make header skips more obvious

seeing inStream.Read(LWOOBJID) is much less clear than a macro which very clearly skips the header.

* Formatting pass
This commit is contained in:
David Markowitz
2023-05-08 04:31:10 -07:00
committed by GitHub
parent 64a947e338
commit 7aad6e4bc2
7 changed files with 63 additions and 51 deletions

View File

@@ -46,9 +46,7 @@ void ClientPackets::HandleChatMessage(const SystemAddress& sysAddr, Packet* pack
return;
}
CINSTREAM;
uint64_t header;
inStream.Read(header);
CINSTREAM_SKIP_HEADER;
char chatChannel;
uint16_t unknown;
@@ -82,9 +80,7 @@ void ClientPackets::HandleClientPositionUpdate(const SystemAddress& sysAddr, Pac
return;
}
CINSTREAM;
uint64_t header;
inStream.Read(header);
CINSTREAM_SKIP_HEADER;
Entity* entity = EntityManager::Instance()->GetEntity(user->GetLastUsedChar()->GetObjectID());
if (!entity) return;