code: function amf3encInteger(num) {
      var buf = new Buffer(1);
      buf.writeUInt8(0x4, 0);
      return Buffer.concat([buf, amf3encUI29(num & 0x3FFFFFFF)]); // This AND will auto convert the sign bit!
  }
docs: AMF3 Encode an integer
  @param num
  @returns {Buffer}