SFMLHelper: Simplify 64-bit packet reading function and remove 64-bit write function

Now that SFML's packet class can properly handle 64-bit values, we don't
need a helper function just to write values to the packets.
This commit is contained in:
Lioncash 2018-08-27 17:08:41 -04:00
parent 3130d388db
commit d10a0b440f
4 changed files with 15 additions and 20 deletions

View file

@ -26,13 +26,8 @@ u32 PacketReadU32(sf::Packet& packet)
u64 PacketReadU64(sf::Packet& packet)
{
u32 low, high;
packet >> low >> high;
return low | (static_cast<u64>(high) << 32);
}
void PacketWriteU64(sf::Packet& packet, const u64 value)
{
packet << static_cast<u32>(value) << static_cast<u32>(value >> 32);
sf::Uint64 value;
packet >> value;
return value;
}
} // namespace Common