to whoever at 4j made this code not adhere to any C standard: why

This commit is contained in:
Leah Anderson
2026-03-02 10:40:53 -07:00
parent f10f5845fd
commit daa04a789a
11 changed files with 59 additions and 59 deletions

View File

@@ -34,7 +34,7 @@ void ContainerSetSlotPacket::read(DataInputStream *dis) //throws IOException
{
// 4J Stu - TU-1 hotfix
// Fix for #13142 - Holding down the A button on the furnace ingredient slot causes the UI to display incorrect item counts
BYTE byteId = dis->readByte();
std::byte byteId = dis->readByte();
containerId = *(char *)&byteId;
slot = dis->readShort();
item = readItem(dis);
@@ -42,7 +42,7 @@ void ContainerSetSlotPacket::read(DataInputStream *dis) //throws IOException
void ContainerSetSlotPacket::write(DataOutputStream *dos) //throws IOException
{
dos->writeByte(containerId);
dos->writeByte((std::byte)containerId);
dos->writeShort(slot);
writeItem(item, dos);
}