docs: public byte[] toBuffer() {
          ByteBuffer buf=ByteBuffer.allocate(SIZE);
          buf.put(type);
          buf.putInt(x);
          buf.putInt(y);
          buf.putInt(val);
          return buf.array();
      }