int slot = buffer.readUnsignedShort();
byte button = buffer.readByte();
int transaction = buffer.readUnsignedShort();
byte mode = buffer.readByte();
ItemStack item = VanillaByteBufUtils.readItemStack(buffer);
return new WindowClickMessage(id, slot, button, transaction, mode, item);
}