var UnityLoader = UnityLoader || {
  Compression: {
    identity: {
      require: function () {
        return {};
      },
      decompress: function (data) {
        return data;
      },
    },
    gzip: {
      require: function require(e){var t={"inflate.js":function(e,t,i){"use strict";function n(e){if(!(this instanceof n))return new n(e);this.options=o.assign({chunkSize:16384,windowBits:0,to:""},e||{});var t=this.options;t.raw&&t.windowBits>=0&&t.windowBits<16&&(t.windowBits=-t.windowBits,0===t.windowBits&&(t.windowBits=-15)),!(t.windowBits>=0&&t.windowBits<16)||e&&e.windowBits||(t.windowBits+=32),t.windowBits>15&&t.windowBits<48&&0===(15&t.windowBits)&&(t.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new h,this.strm.avail_out=0;var i=s.inflateInit2(this.strm,t.windowBits);if(i!==f.Z_OK)throw new Error(d[i]);this.header=new u,s.inflateGetHeader(this.strm,this.header)}function a(e,t){var i=new n(t);if(i.push(e,!0),i.err)throw i.msg||d[i.err];return i.result}function r(e,t){return t=t||{},t.raw=!0,a(e,t)}var s=e("./zlib/inflate"),o=e("./utils/common"),l=e("./utils/strings"),f=e("./zlib/constants"),d=e("./zlib/messages"),h=e("./zlib/zstream"),u=e("./zlib/gzheader"),c=Object.prototype.toString;n.prototype.push=function(e,t){var i,n,a,r,d,h,u=this.strm,b=this.options.chunkSize,w=this.options.dictionary,m=!1;if(this.ended)return!1;n=t===~~t?t:t===!0?f.Z_FINISH:f.Z_NO_FLUSH,"string"==typeof e?u.input=l.binstring2buf(e):"[object ArrayBuffer]"===c.call(e)?u.input=new Uint8Array(e):u.input=e,u.next_in=0,u.avail_in=u.input.length;do{if(0===u.avail_out&&(u.output=new o.Buf8(b),u.next_out=0,u.avail_out=b),i=s.inflate(u,f.Z_NO_FLUSH),i===f.Z_NEED_DICT&&w&&(h="string"==typeof w?l.string2buf(w):"[object ArrayBuffer]"===c.call(w)?new Uint8Array(w):w,i=s.inflateSetDictionary(this.strm,h)),i===f.Z_BUF_ERROR&&m===!0&&(i=f.Z_OK,m=!1),i!==f.Z_STREAM_END&&i!==f.Z_OK)return this.onEnd(i),this.ended=!0,!1;u.next_out&&(0!==u.avail_out&&i!==f.Z_STREAM_END&&(0!==u.avail_in||n!==f.Z_FINISH&&n!==f.Z_SYNC_FLUSH)||("string"===this.options.to?(a=l.utf8border(u.output,u.next_out),r=u.next_out-a,d=l.buf2string(u.output,a),u.next_out=r,u.avail_out=b-r,r&&o.arraySet(u.output,u.output,a,r,0),this.onData(d)):this.onData(o.shrinkBuf(u.output,u.next_out)))),0===u.avail_in&&0===u.avail_out&&(m=!0)}while((u.avail_in>0||0===u.avail_out)&&i!==f.Z_STREAM_END);return i===f.Z_STREAM_END&&(n=f.Z_FINISH),n===f.Z_FINISH?(i=s.inflateEnd(this.strm),this.onEnd(i),this.ended=!0,i===f.Z_OK):n!==f.Z_SYNC_FLUSH||(this.onEnd(f.Z_OK),u.avail_out=0,!0)},n.prototype.onData=function(e){this.chunks.push(e)},n.prototype.onEnd=function(e){e===f.Z_OK&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=o.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg},i.Inflate=n,i.inflate=a,i.inflateRaw=r,i.ungzip=a},"utils/common.js":function(e,t,i){"use strict";var n="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Int32Array;i.assign=function(e){for(var t=Array.prototype.slice.call(arguments,1);t.length;){var i=t.shift();if(i){if("object"!=typeof i)throw new TypeError(i+"must be non-object");for(var n in i)i.hasOwnProperty(n)&&(e[n]=i[n])}}return e},i.shrinkBuf=function(e,t){return e.length===t?e:e.subarray?e.subarray(0,t):(e.length=t,e)};var a={arraySet:function(e,t,i,n,a){if(t.subarray&&e.subarray)return void e.set(t.subarray(i,i+n),a);for(var r=0;r<n;r++)e[a+r]=t[i+r]},flattenChunks:function(e){var t,i,n,a,r,s;for(n=0,t=0,i=e.length;t<i;t++)n+=e[t].length;for(s=new Uint8Array(n),a=0,t=0,i=e.length;t<i;t++)r=e[t],s.set(r,a),a+=r.length;return s}},r={arraySet:function(e,t,i,n,a){for(var r=0;r<n;r++)e[a+r]=t[i+r]},flattenChunks:function(e){return[].concat.apply([],e)}};i.setTyped=function(e){e?(i.Buf8=Uint8Array,i.Buf16=Uint16Array,i.Buf32=Int32Array,i.assign(i,a)):(i.Buf8=Array,i.Buf16=Array,i.Buf32=Array,i.assign(i,r))},i.setTyped(n)},"utils/strings.js":function(e,t,i){"use strict";function n(e,t){if(t<65537&&(e.subarray&&s||!e.subarray&&r))return String.fromCharCode.apply(null,a.shrinkBuf(e,t));for(var i="",n=0;n<t;n++)i+=String.fromCharCode(e[n]);return i}var a=e("./common"),r=!0,s=!0;try{String.fromCharCode.apply(null,[0])}catch(e){r=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch(e){s=!1}for(var o=new a.Buf8(256),l=0;l<256;l++)o[l]=l>=252?6:l>=248?5:l>=240?4:l>=224?3:l>=192?2:1;o[254]=o[254]=1,i.string2buf=function(e){var t,i,n,r,s,o=e.length,l=0;for(r=0;r<o;r++)i=e.charCodeAt(r),55296===(64512&i)&&r+1<o&&(n=e.charCodeAt(r+1),56320===(64512&n)&&(i=65536+(i-55296<<10)+(n-56320),r++)),l+=i<128?1:i<2048?2:i<65536?3:4;for(t=new a.Buf8(l),s=0,r=0;s<l;r++)i=e.charCodeAt(r),55296===(64512&i)&&r+1<o&&(n=e.charCodeAt(r+1),56320===(64512&n)&&(i=65536+(i-55296<<10)+(n-56320),r++)),i<128?t[s++]=i:i<2048?(t[s++]=192|i>>>6,t[s++]=128|63&i):i<65536?(t[s++]=224|i>>>12,t[s++]=128|i>>>6&63,t[s++]=128|63&i):(t[s++]=240|i>>>18,t[s++]=128|i>>>12&63,t[s++]=128|i>>>6&63,t[s++]=128|63&i);return t},i.buf2binstring=function(e){return n(e,e.length)},i.binstring2buf=function(e){for(var t=new a.Buf8(e.length),i=0,n=t.length;i<n;i++)t[i]=e.charCodeAt(i);return t},i.buf2string=function(e,t){var i,a,r,s,l=t||e.length,f=new Array(2*l);for(a=0,i=0;i<l;)if(r=e[i++],r<128)f[a++]=r;else if(s=o[r],s>4)f[a++]=65533,i+=s-1;else{for(r&=2===s?31:3===s?15:7;s>1&&i<l;)r=r<<6|63&e[i++],s--;s>1?f[a++]=65533:r<65536?f[a++]=r:(r-=65536,f[a++]=55296|r>>10&1023,f[a++]=56320|1023&r)}return n(f,a)},i.utf8border=function(e,t){var i;for(t=t||e.length,t>e.length&&(t=e.length),i=t-1;i>=0&&128===(192&e[i]);)i--;return i<0?t:0===i?t:i+o[e[i]]>t?i:t}},"zlib/inflate.js":function(e,t,i){"use strict";function n(e){return(e>>>24&255)+(e>>>8&65280)+((65280&e)<<8)+((255&e)<<24)}function a(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new _.Buf16(320),this.work=new _.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function r(e){var t;return e&&e.state?(t=e.state,e.total_in=e.total_out=t.total=0,e.msg="",t.wrap&&(e.adler=1&t.wrap),t.mode=U,t.last=0,t.havedict=0,t.dmax=32768,t.head=null,t.hold=0,t.bits=0,t.lencode=t.lendyn=new _.Buf32(we),t.distcode=t.distdyn=new _.Buf32(me),t.sane=1,t.back=-1,z):C}function s(e){var t;return e&&e.state?(t=e.state,t.wsize=0,t.whave=0,t.wnext=0,r(e)):C}function o(e,t){var i,n;return e&&e.state?(n=e.state,t<0?(i=0,t=-t):(i=(t>>4)+1,t<48&&(t&=15)),t&&(t<8||t>15)?C:(null!==n.window&&n.wbits!==t&&(n.window=null),n.wrap=i,n.wbits=t,s(e))):C}function l(e,t){var i,n;return e?(n=new a,e.state=n,n.window=null,i=o(e,t),i!==z&&(e.state=null),i):C}function f(e){return l(e,_e)}function d(e){if(ge){var t;for(m=new _.Buf32(512),k=new _.Buf32(32),t=0;t<144;)e.lens[t++]=8;for(;t<256;)e.lens[t++]=9;for(;t<280;)e.lens[t++]=7;for(;t<288;)e.lens[t++]=8;for(x(S,e.lens,0,288,m,0,e.work,{bits:9}),t=0;t<32;)e.lens[t++]=5;x(B,e.lens,0,32,k,0,e.work,{bits:5}),ge=!1}e.lencode=m,e.lenbits=9,e.distcode=k,e.distbits=5}function h(e,t,i,n){var a,r=e.state;return null===r.window&&(r.wsize=1<<r.wbits,r.wnext=0,r.whave=0,r.window=new _.Buf8(r.wsize)),n>=r.wsize?(_.arraySet(r.window,t,i-r.wsize,r.wsize,0),r.wnext=0,r.whave=r.wsize):(a=r.wsize-r.wnext,a>n&&(a=n),_.arraySet(r.window,t,i-n,a,r.wnext),n-=a,n?(_.arraySet(r.window,t,i-n,n,0),r.wnext=n,r.whave=r.wsize):(r.wnext+=a,r.wnext===r.wsize&&(r.wnext=0),r.whave<r.wsize&&(r.whave+=a))),0}function u(e,t){var i,a,r,s,o,l,f,u,c,b,w,m,k,we,me,ke,_e,ge,ve,pe,xe,ye,Se,Be,Ee=0,Ze=new _.Buf8(4),Ae=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!e||!e.state||!e.output||!e.input&&0!==e.avail_in)return C;i=e.state,i.mode===q&&(i.mode=W),o=e.next_out,r=e.output,f=e.avail_out,s=e.next_in,a=e.input,l=e.avail_in,u=i.hold,c=i.bits,b=l,w=f,ye=z;e:for(;;)switch(i.mode){case U:if(0===i.wrap){i.mode=W;break}for(;c<16;){if(0===l)break e;l--,u+=a[s++]<<c,c+=8}if(2&i.wrap&&35615===u){i.check=0,Ze[0]=255&u,Ze[1]=u>>>8&255,i.check=v(i.check,Ze,2,0),u=0,c=0,i.mode=j;break}if(i.flags=0,i.head&&(i.head.done=!1),!(1&i.wrap)||(((255&u)<<8)+(u>>8))%31){e.msg="incorrect header check",i.mode=ue;break}if((15&u)!==F){e.msg="unknown compression method",i.mode=ue;break}if(u>>>=4,c-=4,xe=(15&u)+8,0===i.wbits)i.wbits=xe;else if(xe>i.wbits){e.msg="invalid window size",i.mode=ue;break}i.dmax=1<<xe,e.adler=i.check=1,i.mode=512&u?G:q,u=0,c=0;break;case j:for(;c<16;){if(0===l)break e;l--,u+=a[s++]<<c,c+=8}if(i.flags=u,(255&i.flags)!==F){e.msg="unknown compression method",i.mode=ue;break}if(57344&i.flags){e.msg="unknown header flags set",i.mode=ue;break}i.head&&(i.head.text=u>>8&1),512&i.flags&&(Ze[0]=255&u,Ze[1]=u>>>8&255,i.check=v(i.check,Ze,2,0)),u=0,c=0,i.mode=D;case D:for(;c<32;){if(0===l)break e;l--,u+=a[s++]<<c,c+=8}i.head&&(i.head.time=u),512&i.flags&&(Ze[0]=255&u,Ze[1]=u>>>8&255,Ze[2]=u>>>16&255,Ze[3]=u>>>24&255,i.check=v(i.check,Ze,4,0)),u=0,c=0,i.mode=L;case L:for(;c<16;){if(0===l)break e;l--,u+=a[s++]<<c,c+=8}i.head&&(i.head.xflags=255&u,i.head.os=u>>8),512&i.flags&&(Ze[0]=255&u,Ze[1]=u>>>8&255,i.check=v(i.check,Ze,2,0)),u=0,c=0,i.mode=H;case H:if(1024&i.flags){for(;c<16;){if(0===l)break e;l--,u+=a[s++]<<c,c+=8}i.length=u,i.head&&(i.head.extra_len=u),512&i.flags&&(Ze[0]=255&u,Ze[1]=u>>>8&255,i.check=v(i.check,Ze,2,0)),u=0,c=0}else i.head&&(i.head.extra=null);i.mode=K;case K:if(1024&i.flags&&(m=i.length,m>l&&(m=l),m&&(i.head&&(xe=i.head.extra_len-i.length,i.head.extra||(i.head.extra=new Array(i.head.extra_len)),_.arraySet(i.head.extra,a,s,m,xe)),512&i.flags&&(i.check=v(i.check,a,m,s)),l-=m,s+=m,i.length-=m),i.length))break e;i.length=0,i.mode=M;case M:if(2048&i.flags){if(0===l)break e;m=0;do xe=a[s+m++],i.head&&xe&&i.length<65536&&(i.head.name+=String.fromCharCode(xe));while(xe&&m<l);if(512&i.flags&&(i.check=v(i.check,a,m,s)),l-=m,s+=m,xe)break e}else i.head&&(i.head.name=null);i.length=0,i.mode=P;case P:if(4096&i.flags){if(0===l)break e;m=0;do xe=a[s+m++],i.head&&xe&&i.length<65536&&(i.head.comment+=String.fromCharCode(xe));while(xe&&m<l);if(512&i.flags&&(i.check=v(i.check,a,m,s)),l-=m,s+=m,xe)break e}else i.head&&(i.head.comment=null);i.mode=Y;case Y:if(512&i.flags){for(;c<16;){if(0===l)break e;l--,u+=a[s++]<<c,c+=8}if(u!==(65535&i.check)){e.msg="header crc mismatch",i.mode=ue;break}u=0,c=0}i.head&&(i.head.hcrc=i.flags>>9&1,i.head.done=!0),e.adler=i.check=0,i.mode=q;break;case G:for(;c<32;){if(0===l)break e;l--,u+=a[s++]<<c,c+=8}e.adler=i.check=n(u),u=0,c=0,i.mode=X;case X:if(0===i.havedict)return e.next_out=o,e.avail_out=f,e.next_in=s,e.avail_in=l,i.hold=u,i.bits=c,N;e.adler=i.check=1,i.mode=q;case q:if(t===Z||t===A)break e;case W:if(i.last){u>>>=7&c,c-=7&c,i.mode=fe;break}for(;c<3;){if(0===l)break e;l--,u+=a[s++]<<c,c+=8}switch(i.last=1&u,u>>>=1,c-=1,3&u){case 0:i.mode=J;break;case 1:if(d(i),i.mode=ie,t===A){u>>>=2,c-=2;break e}break;case 2:i.mode=$;break;case 3:e.msg="invalid block type",i.mode=ue}u>>>=2,c-=2;break;case J:for(u>>>=7&c,c-=7&c;c<32;){if(0===l)break e;l--,u+=a[s++]<<c,c+=8}if((65535&u)!==(u>>>16^65535)){e.msg="invalid stored block lengths",i.mode=ue;break}if(i.length=65535&u,u=0,c=0,i.mode=Q,t===A)break e;case Q:i.mode=V;case V:if(m=i.length){if(m>l&&(m=l),m>f&&(m=f),0===m)break e;_.arraySet(r,a,s,m,o),l-=m,s+=m,f-=m,o+=m,i.length-=m;break}i.mode=q;break;case $:for(;c<14;){if(0===l)break e;l--,u+=a[s++]<<c,c+=8}if(i.nlen=(31&u)+257,u>>>=5,c-=5,i.ndist=(31&u)+1,u>>>=5,c-=5,i.ncode=(15&u)+4,u>>>=4,c-=4,i.nlen>286||i.ndist>30){e.msg="too many length or distance symbols",i.mode=ue;break}i.have=0,i.mode=ee;case ee:for(;i.have<i.ncode;){for(;c<3;){if(0===l)break e;l--,u+=a[s++]<<c,c+=8}i.lens[Ae[i.have++]]=7&u,u>>>=3,c-=3}for(;i.have<19;)i.lens[Ae[i.have++]]=0;if(i.lencode=i.lendyn,i.lenbits=7,Se={bits:i.lenbits},ye=x(y,i.lens,0,19,i.lencode,0,i.work,Se),i.lenbits=Se.bits,ye){e.msg="invalid code lengths set",i.mode=ue;break}i.have=0,i.mode=te;case te:for(;i.have<i.nlen+i.ndist;){for(;Ee=i.lencode[u&(1<<i.lenbits)-1],me=Ee>>>24,ke=Ee>>>16&255,_e=65535&Ee,!(me<=c);){if(0===l)break e;l--,u+=a[s++]<<c,c+=8}if(_e<16)u>>>=me,c-=me,i.lens[i.have++]=_e;else{if(16===_e){for(Be=me+2;c<Be;){if(0===l)break e;l--,u+=a[s++]<<c,c+=8}if(u>>>=me,c-=me,0===i.have){e.msg="invalid bit length repeat",i.mode=ue;break}xe=i.lens[i.have-1],m=3+(3&u),u>>>=2,c-=2}else if(17===_e){for(Be=me+3;c<Be;){if(0===l)break e;l--,u+=a[s++]<<c,c+=8}u>>>=me,c-=me,xe=0,m=3+(7&u),u>>>=3,c-=3}else{for(Be=me+7;c<Be;){if(0===l)break e;l--,u+=a[s++]<<c,c+=8}u>>>=me,c-=me,xe=0,m=11+(127&u),u>>>=7,c-=7}if(i.have+m>i.nlen+i.ndist){e.msg="invalid bit length repeat",i.mode=ue;break}for(;m--;)i.lens[i.have++]=xe}}if(i.mode===ue)break;if(0===i.lens[256]){e.msg="invalid code -- missing end-of-block",i.mode=ue;break}if(i.lenbits=9,Se={bits:i.lenbits},ye=x(S,i.lens,0,i.nlen,i.lencode,0,i.work,Se),i.lenbits=Se.bits,ye){e.msg="invalid literal/lengths set",i.mode=ue;break}if(i.distbits=6,i.distcode=i.distdyn,Se={bits:i.distbits},ye=x(B,i.lens,i.nlen,i.ndist,i.distcode,0,i.work,Se),i.distbits=Se.bits,ye){e.msg="invalid distances set",i.mode=ue;break}if(i.mode=ie,t===A)break e;case ie:i.mode=ne;case ne:if(l>=6&&f>=258){e.next_out=o,e.avail_out=f,e.next_in=s,e.avail_in=l,i.hold=u,i.bits=c,p(e,w),o=e.next_out,r=e.output,f=e.avail_out,s=e.next_in,a=e.input,l=e.avail_in,u=i.hold,c=i.bits,i.mode===q&&(i.back=-1);break}for(i.back=0;Ee=i.lencode[u&(1<<i.lenbits)-1],me=Ee>>>24,ke=Ee>>>16&255,_e=65535&Ee,!(me<=c);){if(0===l)break e;l--,u+=a[s++]<<c,c+=8}if(ke&&0===(240&ke)){for(ge=me,ve=ke,pe=_e;Ee=i.lencode[pe+((u&(1<<ge+ve)-1)>>ge)],me=Ee>>>24,ke=Ee>>>16&255,_e=65535&Ee,!(ge+me<=c);){if(0===l)break e;l--,u+=a[s++]<<c,c+=8}u>>>=ge,c-=ge,i.back+=ge}if(u>>>=me,c-=me,i.back+=me,i.length=_e,0===ke){i.mode=le;break}if(32&ke){i.back=-1,i.mode=q;break}if(64&ke){e.msg="invalid literal/length code",i.mode=ue;break}i.extra=15&ke,i.mode=ae;case ae:if(i.extra){for(Be=i.extra;c<Be;){if(0===l)break e;l--,u+=a[s++]<<c,c+=8}i.length+=u&(1<<i.extra)-1,u>>>=i.extra,c-=i.extra,i.back+=i.extra}i.was=i.length,i.mode=re;case re:for(;Ee=i.distcode[u&(1<<i.distbits)-1],me=Ee>>>24,ke=Ee>>>16&255,_e=65535&Ee,!(me<=c);){if(0===l)break e;l--,u+=a[s++]<<c,c+=8}if(0===(240&ke)){for(ge=me,ve=ke,pe=_e;Ee=i.distcode[pe+((u&(1<<ge+ve)-1)>>ge)],me=Ee>>>24,ke=Ee>>>16&255,_e=65535&Ee,!(ge+me<=c);){if(0===l)break e;l--,u+=a[s++]<<c,c+=8}u>>>=ge,c-=ge,i.back+=ge}if(u>>>=me,c-=me,i.back+=me,64&ke){e.msg="invalid distance code",i.mode=ue;break}i.offset=_e,i.extra=15&ke,i.mode=se;case se:if(i.extra){for(Be=i.extra;c<Be;){if(0===l)break e;l--,u+=a[s++]<<c,c+=8}i.offset+=u&(1<<i.extra)-1,u>>>=i.extra,c-=i.extra,i.back+=i.extra}if(i.offset>i.dmax){e.msg="invalid distance too far back",i.mode=ue;break}i.mode=oe;case oe:if(0===f)break e;if(m=w-f,i.offset>m){if(m=i.offset-m,m>i.whave&&i.sane){e.msg="invalid distance too far back",i.mode=ue;break}m>i.wnext?(m-=i.wnext,k=i.wsize-m):k=i.wnext-m,m>i.length&&(m=i.length),we=i.window}else we=r,k=o-i.offset,m=i.length;m>f&&(m=f),f-=m,i.length-=m;do r[o++]=we[k++];while(--m);0===i.length&&(i.mode=ne);break;case le:if(0===f)break e;r[o++]=i.length,f--,i.mode=ne;break;case fe:if(i.wrap){for(;c<32;){if(0===l)break e;l--,u|=a[s++]<<c,c+=8}if(w-=f,e.total_out+=w,i.total+=w,w&&(e.adler=i.check=i.flags?v(i.check,r,w,o-w):g(i.check,r,w,o-w)),w=f,(i.flags?u:n(u))!==i.check){e.msg="incorrect data check",i.mode=ue;break}u=0,c=0}i.mode=de;case de:if(i.wrap&&i.flags){for(;c<32;){if(0===l)break e;l--,u+=a[s++]<<c,c+=8}if(u!==(4294967295&i.total)){e.msg="incorrect length check",i.mode=ue;break}u=0,c=0}i.mode=he;case he:ye=R;break e;case ue:ye=O;break e;case ce:return I;case be:default:return C}return e.next_out=o,e.avail_out=f,e.next_in=s,e.avail_in=l,i.hold=u,i.bits=c,(i.wsize||w!==e.avail_out&&i.mode<ue&&(i.mode<fe||t!==E))&&h(e,e.output,e.next_out,w-e.avail_out)?(i.mode=ce,I):(b-=e.avail_in,w-=e.avail_out,e.total_in+=b,e.total_out+=w,i.total+=w,i.wrap&&w&&(e.adler=i.check=i.flags?v(i.check,r,w,e.next_out-w):g(i.check,r,w,e.next_out-w)),e.data_type=i.bits+(i.last?64:0)+(i.mode===q?128:0)+(i.mode===ie||i.mode===Q?256:0),(0===b&&0===w||t===E)&&ye===z&&(ye=T),ye)}function c(e){if(!e||!e.state)return C;var t=e.state;return t.window&&(t.window=null),e.state=null,z}function b(e,t){var i;return e&&e.state?(i=e.state,0===(2&i.wrap)?C:(i.head=t,t.done=!1,z)):C}function w(e,t){var i,n,a,r=t.length;return e&&e.state?(i=e.state,0!==i.wrap&&i.mode!==X?C:i.mode===X&&(n=1,n=g(n,t,r,0),n!==i.check)?O:(a=h(e,t,r,r))?(i.mode=ce,I):(i.havedict=1,z)):C}var m,k,_=e("../utils/common"),g=e("./adler32"),v=e("./crc32"),p=e("./inffast"),x=e("./inftrees"),y=0,S=1,B=2,E=4,Z=5,A=6,z=0,R=1,N=2,C=-2,O=-3,I=-4,T=-5,F=8,U=1,j=2,D=3,L=4,H=5,K=6,M=7,P=8,Y=9,G=10,X=11,q=12,W=13,J=14,Q=15,V=16,$=17,ee=18,te=19,ie=20,ne=21,ae=22,re=23,se=24,oe=25,le=26,fe=27,de=28,he=29,ue=30,ce=31,be=32,we=852,me=592,ke=15,_e=ke,ge=!0;i.inflateReset=s,i.inflateReset2=o,i.inflateResetKeep=r,i.inflateInit=f,i.inflateInit2=l,i.inflate=u,i.inflateEnd=c,i.inflateGetHeader=b,i.inflateSetDictionary=w,i.inflateInfo="pako inflate (from Nodeca project)"},"zlib/constants.js":function(e,t,i){"use strict";t.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},"zlib/messages.js":function(e,t,i){"use strict";t.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},"zlib/zstream.js":function(e,t,i){"use strict";function n(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}t.exports=n},"zlib/gzheader.js":function(e,t,i){"use strict";function n(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}t.exports=n},"zlib/adler32.js":function(e,t,i){"use strict";function n(e,t,i,n){for(var a=65535&e|0,r=e>>>16&65535|0,s=0;0!==i;){s=i>2e3?2e3:i,i-=s;do a=a+t[n++]|0,r=r+a|0;while(--s);a%=65521,r%=65521}return a|r<<16|0}t.exports=n},"zlib/crc32.js":function(e,t,i){"use strict";function n(){for(var e,t=[],i=0;i<256;i++){e=i;for(var n=0;n<8;n++)e=1&e?3988292384^e>>>1:e>>>1;t[i]=e}return t}function a(e,t,i,n){var a=r,s=n+i;e^=-1;for(var o=n;o<s;o++)e=e>>>8^a[255&(e^t[o])];return e^-1}var r=n();t.exports=a},"zlib/inffast.js":function(e,t,i){"use strict";var n=30,a=12;t.exports=function(e,t){var i,r,s,o,l,f,d,h,u,c,b,w,m,k,_,g,v,p,x,y,S,B,E,Z,A;i=e.state,r=e.next_in,Z=e.input,s=r+(e.avail_in-5),o=e.next_out,A=e.output,l=o-(t-e.avail_out),f=o+(e.avail_out-257),d=i.dmax,h=i.wsize,u=i.whave,c=i.wnext,b=i.window,w=i.hold,m=i.bits,k=i.lencode,_=i.distcode,g=(1<<i.lenbits)-1,v=(1<<i.distbits)-1;e:do{m<15&&(w+=Z[r++]<<m,m+=8,w+=Z[r++]<<m,m+=8),p=k[w&g];t:for(;;){if(x=p>>>24,w>>>=x,m-=x,x=p>>>16&255,0===x)A[o++]=65535&p;else{if(!(16&x)){if(0===(64&x)){p=k[(65535&p)+(w&(1<<x)-1)];continue t}if(32&x){i.mode=a;break e}e.msg="invalid literal/length code",i.mode=n;break e}y=65535&p,x&=15,x&&(m<x&&(w+=Z[r++]<<m,m+=8),y+=w&(1<<x)-1,w>>>=x,m-=x),m<15&&(w+=Z[r++]<<m,m+=8,w+=Z[r++]<<m,m+=8),p=_[w&v];i:for(;;){if(x=p>>>24,w>>>=x,m-=x,x=p>>>16&255,!(16&x)){if(0===(64&x)){p=_[(65535&p)+(w&(1<<x)-1)];continue i}e.msg="invalid distance code",i.mode=n;break e}if(S=65535&p,x&=15,m<x&&(w+=Z[r++]<<m,m+=8,m<x&&(w+=Z[r++]<<m,m+=8)),S+=w&(1<<x)-1,S>d){e.msg="invalid distance too far back",i.mode=n;break e}if(w>>>=x,m-=x,x=o-l,S>x){if(x=S-x,x>u&&i.sane){e.msg="invalid distance too far back",i.mode=n;break e}if(B=0,E=b,0===c){if(B+=h-x,x<y){y-=x;do A[o++]=b[B++];while(--x);B=o-S,E=A}}else if(c<x){if(B+=h+c-x,x-=c,x<y){y-=x;do A[o++]=b[B++];while(--x);if(B=0,c<y){x=c,y-=x;do A[o++]=b[B++];while(--x);B=o-S,E=A}}}else if(B+=c-x,x<y){y-=x;do A[o++]=b[B++];while(--x);B=o-S,E=A}for(;y>2;)A[o++]=E[B++],A[o++]=E[B++],A[o++]=E[B++],y-=3;y&&(A[o++]=E[B++],y>1&&(A[o++]=E[B++]))}else{B=o-S;do A[o++]=A[B++],A[o++]=A[B++],A[o++]=A[B++],y-=3;while(y>2);y&&(A[o++]=A[B++],y>1&&(A[o++]=A[B++]))}break}}break}}while(r<s&&o<f);y=m>>3,r-=y,m-=y<<3,w&=(1<<m)-1,e.next_in=r,e.next_out=o,e.avail_in=r<s?5+(s-r):5-(r-s),e.avail_out=o<f?257+(f-o):257-(o-f),i.hold=w,i.bits=m}},"zlib/inftrees.js":function(e,t,i){"use strict";var n=e("../utils/common"),a=15,r=852,s=592,o=0,l=1,f=2,d=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],h=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],u=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],c=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];t.exports=function(e,t,i,b,w,m,k,_){var g,v,p,x,y,S,B,E,Z,A=_.bits,z=0,R=0,N=0,C=0,O=0,I=0,T=0,F=0,U=0,j=0,D=null,L=0,H=new n.Buf16(a+1),K=new n.Buf16(a+1),M=null,P=0;for(z=0;z<=a;z++)H[z]=0;for(R=0;R<b;R++)H[t[i+R]]++;for(O=A,C=a;C>=1&&0===H[C];C--);if(O>C&&(O=C),0===C)return w[m++]=20971520,w[m++]=20971520,_.bits=1,0;for(N=1;N<C&&0===H[N];N++);for(O<N&&(O=N),F=1,z=1;z<=a;z++)if(F<<=1,F-=H[z],F<0)return-1;if(F>0&&(e===o||1!==C))return-1;for(K[1]=0,z=1;z<a;z++)K[z+1]=K[z]+H[z];for(R=0;R<b;R++)0!==t[i+R]&&(k[K[t[i+R]]++]=R);if(e===o?(D=M=k,S=19):e===l?(D=d,L-=257,M=h,P-=257,S=256):(D=u,M=c,S=-1),j=0,R=0,z=N,y=m,I=O,T=0,p=-1,U=1<<O,x=U-1,e===l&&U>r||e===f&&U>s)return 1;for(;;){B=z-T,k[R]<S?(E=0,Z=k[R]):k[R]>S?(E=M[P+k[R]],Z=D[L+k[R]]):(E=96,Z=0),g=1<<z-T,v=1<<I,N=v;do v-=g,w[y+(j>>T)+v]=B<<24|E<<16|Z|0;while(0!==v);for(g=1<<z-1;j&g;)g>>=1;if(0!==g?(j&=g-1,j+=g):j=0,R++,0===--H[z]){if(z===C)break;z=t[i+k[R]]}if(z>O&&(j&x)!==p){for(0===T&&(T=O),y+=N,I=z-T,F=1<<I;I+T<C&&(F-=H[I+T],!(F<=0));)I++,F<<=1;if(U+=1<<I,e===l&&U>r||e===f&&U>s)return 1;p=j&x,w[p]=O<<24|I<<16|y-m|0}}return 0!==j&&(w[y+j]=z-T<<24|64<<16|0),_.bits=O,0}}};for(var i in t)t[i].folder=i.substring(0,i.lastIndexOf("/")+1);var n=function(e){var i=[];return e=e.split("/").every(function(e){return".."==e?i.pop():"."==e||""==e||i.push(e)})?i.join("/"):null,e?t[e]||t[e+".js"]||t[e+"/index.js"]:null},a=function(e,t){return e?n(e.folder+"node_modules/"+t)||a(e.parent,t):null},r=function(e,t){var i=t.match(/^\//)?null:e?t.match(/^\.\.?\//)?n(e.folder+t):a(e,t):n(t);if(!i)throw"module not found: "+t;return i.exports||(i.parent=e,i(r.bind(null,i),i,i.exports={})),i.exports};return r(null,e)},
      decompress: function (data) {
        if (!this.exports)
          this.exports = this.require("inflate.js");
        try { return this.exports.inflate(data) } catch (e) {};
        
      },
      hasUnityMarker: function (data) {
        var commentOffset = 10, expectedComment = "UnityWeb Compressed Content (gzip)";
        if (commentOffset > data.length || data[0] != 0x1F || data[1] != 0x8B)
          return false;
        var flags = data[3];
        if (flags & 0x04) {
          if (commentOffset + 2 > data.length)
            return false;
          commentOffset += 2 + data[commentOffset] + (data[commentOffset + 1] << 8);
          if (commentOffset > data.length)
            return false;
        }
        if (flags & 0x08) {
          while (commentOffset < data.length && data[commentOffset])
            commentOffset++;
          if (commentOffset + 1 > data.length)
            return false;
          commentOffset++;
        }
        return (flags & 0x10) && String.fromCharCode.apply(null, data.subarray(commentOffset, commentOffset + expectedComment.length + 1)) == expectedComment + "\0";
        
      },
    },
    brotli: {
      require: function require(e){var n={"decompress.js":function(e,n,t){n.exports=e("./dec/decode").BrotliDecompressBuffer},"dec/bit_reader.js":function(e,n,t){function r(e){this.buf_=new Uint8Array(o),this.input_=e,this.reset()}const i=4096,o=8224,s=8191,a=new Uint32Array([0,1,3,7,15,31,63,127,255,511,1023,2047,4095,8191,16383,32767,65535,131071,262143,524287,1048575,2097151,4194303,8388607,16777215]);r.READ_SIZE=i,r.IBUF_MASK=s,r.prototype.reset=function(){this.buf_ptr_=0,this.val_=0,this.pos_=0,this.bit_pos_=0,this.bit_end_pos_=0,this.eos_=0,this.readMoreInput();for(var e=0;e<4;e++)this.val_|=this.buf_[this.pos_]<<8*e,++this.pos_;return this.bit_end_pos_>0},r.prototype.readMoreInput=function(){if(!(this.bit_end_pos_>256))if(this.eos_){if(this.bit_pos_>this.bit_end_pos_)throw new Error("Unexpected end of input "+this.bit_pos_+" "+this.bit_end_pos_)}else{var e=this.buf_ptr_,n=this.input_.read(this.buf_,e,i);if(n<0)throw new Error("Unexpected end of input");if(n<i){this.eos_=1;for(var t=0;t<32;t++)this.buf_[e+n+t]=0}if(0===e){for(var t=0;t<32;t++)this.buf_[8192+t]=this.buf_[t];this.buf_ptr_=i}else this.buf_ptr_=0;this.bit_end_pos_+=n<<3}},r.prototype.fillBitWindow=function(){for(;this.bit_pos_>=8;)this.val_>>>=8,this.val_|=this.buf_[this.pos_&s]<<24,++this.pos_,this.bit_pos_=this.bit_pos_-8>>>0,this.bit_end_pos_=this.bit_end_pos_-8>>>0},r.prototype.readBits=function(e){32-this.bit_pos_<e&&this.fillBitWindow();var n=this.val_>>>this.bit_pos_&a[e];return this.bit_pos_+=e,n},n.exports=r},"dec/context.js":function(e,n,t){t.lookup=new Uint8Array([0,0,0,0,0,0,0,0,0,4,4,0,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,8,12,16,12,12,20,12,16,24,28,12,12,32,12,36,12,44,44,44,44,44,44,44,44,44,44,32,32,24,40,28,12,12,48,52,52,52,48,52,52,52,48,52,52,52,52,52,48,52,52,52,52,52,48,52,52,52,52,52,24,12,28,12,12,12,56,60,60,60,56,60,60,60,56,60,60,60,60,60,56,60,60,60,60,60,56,60,60,60,60,60,24,12,28,12,0,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,1,1,1,1,1,1,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,7,0,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,56,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,6,6,6,6,7,7,7,7,8,8,8,8,9,9,9,9,10,10,10,10,11,11,11,11,12,12,12,12,13,13,13,13,14,14,14,14,15,15,15,15,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,22,22,22,22,23,23,23,23,24,24,24,24,25,25,25,25,26,26,26,26,27,27,27,27,28,28,28,28,29,29,29,29,30,30,30,30,31,31,31,31,32,32,32,32,33,33,33,33,34,34,34,34,35,35,35,35,36,36,36,36,37,37,37,37,38,38,38,38,39,39,39,39,40,40,40,40,41,41,41,41,42,42,42,42,43,43,43,43,44,44,44,44,45,45,45,45,46,46,46,46,47,47,47,47,48,48,48,48,49,49,49,49,50,50,50,50,51,51,51,51,52,52,52,52,53,53,53,53,54,54,54,54,55,55,55,55,56,56,56,56,57,57,57,57,58,58,58,58,59,59,59,59,60,60,60,60,61,61,61,61,62,62,62,62,63,63,63,63,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]),t.lookupOffsets=new Uint16Array([1024,1536,1280,1536,0,256,768,512])},"dec/decode.js":function(e,n,t){function r(e){var n;return 0===e.readBits(1)?16:(n=e.readBits(3),n>0?17+n:(n=e.readBits(3),n>0?8+n:17))}function i(e){if(e.readBits(1)){var n=e.readBits(3);return 0===n?1:e.readBits(n)+(1<<n)}return 0}function o(){this.meta_block_length=0,this.input_end=0,this.is_uncompressed=0,this.is_metadata=!1}function s(e){var n,t,r,i=new o;if(i.input_end=e.readBits(1),i.input_end&&e.readBits(1))return i;if(n=e.readBits(2)+4,7===n){if(i.is_metadata=!0,0!==e.readBits(1))throw new Error("Invalid reserved bit");if(t=e.readBits(2),0===t)return i;for(r=0;r<t;r++){var s=e.readBits(8);if(r+1===t&&t>1&&0===s)throw new Error("Invalid size byte");i.meta_block_length|=s<<8*r}}else for(r=0;r<n;++r){var a=e.readBits(4);if(r+1===n&&n>4&&0===a)throw new Error("Invalid size nibble");i.meta_block_length|=a<<4*r}return++i.meta_block_length,i.input_end||i.is_metadata||(i.is_uncompressed=e.readBits(1)),i}function a(e,n,t){var r;return t.fillBitWindow(),n+=t.val_>>>t.bit_pos_&K,r=e[n].bits-k,r>0&&(t.bit_pos_+=k,n+=e[n].value,n+=t.val_>>>t.bit_pos_&(1<<r)-1),t.bit_pos_+=e[n].bits,e[n].value}function f(e,n,t,r){for(var i=0,o=H,s=0,a=0,f=32768,w=[],d=0;d<32;d++)w.push(new N(0,0));for(q(w,0,5,e,G);i<n&&f>0;){var u,p=0;if(r.readMoreInput(),r.fillBitWindow(),p+=r.val_>>>r.bit_pos_&31,r.bit_pos_+=w[p].bits,u=255&w[p].value,u<M)s=0,t[i++]=u,0!==u&&(o=u,f-=32768>>u);else{var c,h,l=u-14,b=0;if(u===M&&(b=o),a!==b&&(s=0,a=b),c=s,s>0&&(s-=2,s<<=l),s+=r.readBits(l)+3,h=s-c,i+h>n)throw new Error("[ReadHuffmanCodeLengths] symbol + repeat_delta > num_symbols");for(var v=0;v<h;v++)t[i+v]=a;i+=h,0!==a&&(f-=h<<15-a)}}if(0!==f)throw new Error("[ReadHuffmanCodeLengths] space = "+f);for(;i<n;i++)t[i]=0}function w(e,n,t,r){var i,o=0,s=new Uint8Array(e);if(r.readMoreInput(),i=r.readBits(2),1===i){for(var a,w=e-1,d=0,u=new Int32Array(4),p=r.readBits(2)+1;w;)w>>=1,++d;for(a=0;a<p;++a)u[a]=r.readBits(d)%e,s[u[a]]=2;switch(s[u[0]]=1,p){case 1:break;case 3:if(u[0]===u[1]||u[0]===u[2]||u[1]===u[2])throw new Error("[ReadHuffmanCode] invalid symbols");break;case 2:if(u[0]===u[1])throw new Error("[ReadHuffmanCode] invalid symbols");s[u[1]]=1;break;case 4:if(u[0]===u[1]||u[0]===u[2]||u[0]===u[3]||u[1]===u[2]||u[1]===u[3]||u[2]===u[3])throw new Error("[ReadHuffmanCode] invalid symbols");r.readBits(1)?(s[u[2]]=3,s[u[3]]=3):s[u[0]]=2}}else{var a,c=new Uint8Array(G),h=32,l=0,b=[new N(2,0),new N(2,4),new N(2,3),new N(3,2),new N(2,0),new N(2,4),new N(2,3),new N(4,1),new N(2,0),new N(2,4),new N(2,3),new N(3,2),new N(2,0),new N(2,4),new N(2,3),new N(4,5)];for(a=i;a<G&&h>0;++a){var v,m=L[a],y=0;r.fillBitWindow(),y+=r.val_>>>r.bit_pos_&15,r.bit_pos_+=b[y].bits,v=b[y].value,c[m]=v,0!==v&&(h-=32>>v,++l)}if(1!==l&&0!==h)throw new Error("[ReadHuffmanCode] invalid num_codes or space");f(c,e,s,r)}if(o=q(n,t,k,s,e),0===o)throw new Error("[ReadHuffmanCode] BuildHuffmanTable failed: ");return o}function d(e,n,t){var r,i;return r=a(e,n,t),i=B.kBlockLengthPrefixCode[r].nbits,B.kBlockLengthPrefixCode[r].offset+t.readBits(i)}function u(e,n,t){var r;return e<J?(t+=T[e],t&=3,r=n[t]+z[e]):r=e-J+1,r}function p(e,n){for(var t=e[n],r=n;r;--r)e[r]=e[r-1];e[0]=t}function c(e,n){var t,r=new Uint8Array(256);for(t=0;t<256;++t)r[t]=t;for(t=0;t<n;++t){var i=e[t];e[t]=r[i],i&&p(r,i)}}function h(e,n){this.alphabet_size=e,this.num_htrees=n,this.codes=new Array(n+n*I[e+31>>>5]),this.htrees=new Uint32Array(n)}function l(e,n){var t,r,o,s={num_htrees:null,context_map:null},f=0;n.readMoreInput();var d=s.num_htrees=i(n)+1,u=s.context_map=new Uint8Array(e);if(d<=1)return s;for(t=n.readBits(1),t&&(f=n.readBits(4)+1),r=[],o=0;o<X;o++)r[o]=new N(0,0);for(w(d+f,r,0,n),o=0;o<e;){var p;if(n.readMoreInput(),p=a(r,0,n),0===p)u[o]=0,++o;else if(p<=f)for(var h=1+(1<<p)+n.readBits(p);--h;){if(o>=e)throw new Error("[DecodeContextMap] i >= context_map_size");u[o]=0,++o}else u[o]=p-f,++o}return n.readBits(1)&&c(u,e),s}function b(e,n,t,r,i,o,s){var f,w=2*t,d=t,u=a(n,t*X,s);f=0===u?i[w+(1&o[d])]:1===u?i[w+(o[d]-1&1)]+1:u-2,f>=e&&(f-=e),r[t]=f,i[w+(1&o[d])]=f,++o[d]}function v(e,n,t,r,i,o){var s,a=i+1,f=t&i,w=o.pos_&V.IBUF_MASK;if(n<8||o.bit_pos_+(n<<3)<o.bit_end_pos_)for(;n-- >0;)o.readMoreInput(),r[f++]=o.readBits(8),f===a&&(e.write(r,a),f=0);else{if(o.bit_end_pos_<32)throw new Error("[CopyUncompressedBlockToOutput] br.bit_end_pos_ < 32");for(;o.bit_pos_<32;)r[f]=o.val_>>>o.bit_pos_,o.bit_pos_+=8,++f,--n;if(s=o.bit_end_pos_-o.bit_pos_>>3,w+s>V.IBUF_MASK){for(var d=V.IBUF_MASK+1-w,u=0;u<d;u++)r[f+u]=o.buf_[w+u];s-=d,f+=d,n-=d,w=0}for(var u=0;u<s;u++)r[f+u]=o.buf_[w+u];if(f+=s,n-=s,f>=a){e.write(r,a),f-=a;for(var u=0;u<f;u++)r[u]=r[a+u]}for(;f+n>=a;){if(s=a-f,o.input_.read(r,f,s)<s)throw new Error("[CopyUncompressedBlockToOutput] not enough bytes");e.write(r,a),n-=s,f=0}if(o.input_.read(r,f,n)<n)throw new Error("[CopyUncompressedBlockToOutput] not enough bytes");o.reset()}}function m(e){var n=e.bit_pos_+7&-8,t=e.readBits(n-e.bit_pos_);return 0==t}function y(e){var n=new U(e),t=new V(n);r(t);var i=s(t);return i.meta_block_length}function W(e,n){var t=new U(e);null==n&&(n=y(e));var r=new Uint8Array(n),i=new E(r);return x(t,i),i.pos<i.buffer.length&&(i.buffer=i.buffer.subarray(0,i.pos)),i.buffer}function x(e,n){var t,o,f,p,c,y,W,x,U,E=0,q=0,H=0,M=0,k=[16,15,11,4],K=0,G=0,L=0,T=[new h(0,0),new h(0,0),new h(0,0)];const z=128+V.READ_SIZE;U=new V(e),H=r(U),o=(1<<H)-16,f=1<<H,p=f-1,c=new Uint8Array(f+z+O.maxDictionaryWordLength),y=f,W=[],x=[];for(var I=0;I<3240;I++)W[I]=new N(0,0),x[I]=new N(0,0);for(;!q;){var D,j,Q,C,S,_,$,ee,ne,te=0,re=[1<<28,1<<28,1<<28],ie=[0],oe=[1,1,1],se=[0,1,0,1,0,1],ae=[0],fe=null,we=null,de=null,ue=0,pe=null,ce=0,he=0,le=null,be=0,ve=0,me=0;for(t=0;t<3;++t)T[t].codes=null,T[t].htrees=null;U.readMoreInput();var ye=s(U);if(te=ye.meta_block_length,E+te>n.buffer.length){var We=new Uint8Array(E+te);We.set(n.buffer),n.buffer=We}if(q=ye.input_end,D=ye.is_uncompressed,ye.is_metadata)for(m(U);te>0;--te)U.readMoreInput(),U.readBits(8);else if(0!==te)if(D)U.bit_pos_=U.bit_pos_+7&-8,v(n,te,E,c,p,U),E+=te;else{for(t=0;t<3;++t)oe[t]=i(U)+1,oe[t]>=2&&(w(oe[t]+2,W,t*X,U),w(F,x,t*X,U),re[t]=d(x,t*X,U),ae[t]=1);for(U.readMoreInput(),j=U.readBits(2),Q=J+(U.readBits(4)<<j),C=(1<<j)-1,S=Q+(48<<j),we=new Uint8Array(oe[0]),t=0;t<oe[0];++t)U.readMoreInput(),we[t]=U.readBits(2)<<1;var xe=l(oe[0]<<Z,U);_=xe.num_htrees,fe=xe.context_map;var Ue=l(oe[2]<<P,U);for($=Ue.num_htrees,de=Ue.context_map,T[0]=new h(A,_),T[1]=new h(g,oe[1]),T[2]=new h(S,$),t=0;t<3;++t)T[t].decode(U);for(pe=0,le=0,ee=we[ie[0]],ve=Y.lookupOffsets[ee],me=Y.lookupOffsets[ee+1],ne=T[1].htrees[0];te>0;){var Ee,Ve,Oe,Ne,qe,Ye,Be,Re,He,Me,Ae;for(U.readMoreInput(),0===re[1]&&(b(oe[1],W,1,ie,se,ae,U),re[1]=d(x,X,U),ne=T[1].htrees[ie[1]]),--re[1],Ee=a(T[1].codes,ne,U),Ve=Ee>>6,Ve>=2?(Ve-=2,Be=-1):Be=0,Oe=B.kInsertRangeLut[Ve]+(Ee>>3&7),Ne=B.kCopyRangeLut[Ve]+(7&Ee),qe=B.kInsertLengthPrefixCode[Oe].offset+U.readBits(B.kInsertLengthPrefixCode[Oe].nbits),Ye=B.kCopyLengthPrefixCode[Ne].offset+U.readBits(B.kCopyLengthPrefixCode[Ne].nbits),G=c[E-1&p],L=c[E-2&p],Me=0;Me<qe;++Me)U.readMoreInput(),0===re[0]&&(b(oe[0],W,0,ie,se,ae,U),re[0]=d(x,0,U),ue=ie[0]<<Z,pe=ue,ee=we[ie[0]],ve=Y.lookupOffsets[ee],me=Y.lookupOffsets[ee+1]),He=Y.lookup[ve+G]|Y.lookup[me+L],ce=fe[pe+He],--re[0],L=G,G=a(T[0].codes,T[0].htrees[ce],U),c[E&p]=G,(E&p)===p&&n.write(c,f),++E;if(te-=qe,te<=0)break;if(Be<0){var He;if(U.readMoreInput(),0===re[2]&&(b(oe[2],W,2,ie,se,ae,U),re[2]=d(x,2160,U),he=ie[2]<<P,le=he),--re[2],He=255&(Ye>4?3:Ye-2),be=de[le+He],Be=a(T[2].codes,T[2].htrees[be],U),Be>=Q){var ge,Fe,Ze;Be-=Q,Fe=Be&C,Be>>=j,ge=(Be>>1)+1,Ze=(2+(1&Be)<<ge)-4,Be=Q+(Ze+U.readBits(ge)<<j)+Fe}}if(Re=u(Be,k,K),Re<0)throw new Error("[BrotliDecompress] invalid distance");if(M=E<o&&M!==o?E:o,Ae=E&p,Re>M){if(!(Ye>=O.minDictionaryWordLength&&Ye<=O.maxDictionaryWordLength))throw new Error("Invalid backward reference. pos: "+E+" distance: "+Re+" len: "+Ye+" bytes left: "+te);var Ze=O.offsetsByLength[Ye],Pe=Re-M-1,ke=O.sizeBitsByLength[Ye],Ke=(1<<ke)-1,Xe=Pe&Ke,Ge=Pe>>ke;if(Ze+=Xe*Ye,!(Ge<R.kNumTransforms))throw new Error("Invalid backward reference. pos: "+E+" distance: "+Re+" len: "+Ye+" bytes left: "+te);var Le=R.transformDictionaryWord(c,Ae,Ze,Ye,Ge);if(Ae+=Le,E+=Le,te-=Le,Ae>=y){n.write(c,f);for(var Je=0;Je<Ae-y;Je++)c[Je]=c[y+Je]}}else{if(Be>0&&(k[3&K]=Re,++K),Ye>te)throw new Error("Invalid backward reference. pos: "+E+" distance: "+Re+" len: "+Ye+" bytes left: "+te);for(Me=0;Me<Ye;++Me)c[E&p]=c[E-Re&p],(E&p)===p&&n.write(c,f),++E,--te}G=c[E-1&p],L=c[E-2&p]}E&=1073741823}}n.write(c,E&p)}var U=e("./streams").BrotliInput,E=e("./streams").BrotliOutput,V=e("./bit_reader"),O=e("./dictionary"),N=e("./huffman").HuffmanCode,q=e("./huffman").BrotliBuildHuffmanTable,Y=e("./context"),B=e("./prefix"),R=e("./transform");const H=8,M=16,A=256,g=704,F=26,Z=6,P=2,k=8,K=255,X=1080,G=18,L=new Uint8Array([1,2,3,4,0,5,17,6,16,7,8,9,10,11,12,13,14,15]),J=16,T=new Uint8Array([3,2,1,0,3,3,3,3,3,3,2,2,2,2,2,2]),z=new Int8Array([0,0,0,0,-1,1,-2,2,-3,3,-1,1,-2,2,-3,3]),I=new Uint16Array([256,402,436,468,500,534,566,598,630,662,694,726,758,790,822,854,886,920,952,984,1016,1048,1080]);h.prototype.decode=function(e){var n,t,r=0;for(n=0;n<this.num_htrees;++n)this.htrees[n]=r,t=w(this.alphabet_size,this.codes,r,e),r+=t},t.BrotliDecompressedSize=y,t.BrotliDecompressBuffer=W,t.BrotliDecompress=x,O.init()},"dec/dictionary.js":function(e,n,t){var r=e("./dictionary-browser");t.init=function(){t.dictionary=r.init()},t.offsetsByLength=new Uint32Array([0,0,0,0,0,4096,9216,21504,35840,44032,53248,63488,74752,87040,93696,100864,104704,106752,108928,113536,115968,118528,119872,121280,122016]),t.sizeBitsByLength=new Uint8Array([0,0,0,0,10,10,11,11,10,10,10,10,10,9,9,8,7,7,8,7,7,6,6,5,5]),t.minDictionaryWordLength=4,t.maxDictionaryWordLength=24},"dec/dictionary.bin.js":function(e,n,t){n.exports=" ";
},"dec/dictionary-browser.js":function(e,n,t){var r=e("base64-js");t.init=function(){var n=e("./decode").BrotliDecompressBuffer,t=r.toByteArray(e("./dictionary.bin.js"));return n(t)}},"dec/huffman.js":function(e,n,t){function r(e,n){this.bits=e,this.value=n}function i(e,n){for(var t=1<<n-1;e&t;)t>>=1;return(e&t-1)+t}function o(e,n,t,i,o){do i-=t,e[n+i]=new r(o.bits,o.value);while(i>0)}function s(e,n,t){for(var r=1<<n-t;n<a&&(r-=e[n],!(r<=0));)++n,r<<=1;return n-t}t.HuffmanCode=r;const a=15;t.BrotliBuildHuffmanTable=function(e,n,t,f,w){var d,u,p,c,h,l,b,v,m,y,W,x=n,U=new Int32Array(16),E=new Int32Array(16);for(W=new Int32Array(w),p=0;p<w;p++)U[f[p]]++;for(E[1]=0,u=1;u<a;u++)E[u+1]=E[u]+U[u];for(p=0;p<w;p++)0!==f[p]&&(W[E[f[p]]++]=p);if(v=t,m=1<<v,y=m,1===E[a]){for(c=0;c<y;++c)e[n+c]=new r(0,65535&W[0]);return y}for(c=0,p=0,u=1,h=2;u<=t;++u,h<<=1)for(;U[u]>0;--U[u])d=new r(255&u,65535&W[p++]),o(e,n+c,h,m,d),c=i(c,u);for(b=y-1,l=-1,u=t+1,h=2;u<=a;++u,h<<=1)for(;U[u]>0;--U[u])(c&b)!==l&&(n+=m,v=s(U,u,t),m=1<<v,y+=m,l=c&b,e[x+l]=new r(v+t&255,n-x-l&65535)),d=new r(u-t&255,65535&W[p++]),o(e,n+(c>>t),h,m,d),c=i(c,u);return y}},"dec/prefix.js":function(e,n,t){function r(e,n){this.offset=e,this.nbits=n}t.kBlockLengthPrefixCode=[new r(1,2),new r(5,2),new r(9,2),new r(13,2),new r(17,3),new r(25,3),new r(33,3),new r(41,3),new r(49,4),new r(65,4),new r(81,4),new r(97,4),new r(113,5),new r(145,5),new r(177,5),new r(209,5),new r(241,6),new r(305,6),new r(369,7),new r(497,8),new r(753,9),new r(1265,10),new r(2289,11),new r(4337,12),new r(8433,13),new r(16625,24)],t.kInsertLengthPrefixCode=[new r(0,0),new r(1,0),new r(2,0),new r(3,0),new r(4,0),new r(5,0),new r(6,1),new r(8,1),new r(10,2),new r(14,2),new r(18,3),new r(26,3),new r(34,4),new r(50,4),new r(66,5),new r(98,5),new r(130,6),new r(194,7),new r(322,8),new r(578,9),new r(1090,10),new r(2114,12),new r(6210,14),new r(22594,24)],t.kCopyLengthPrefixCode=[new r(2,0),new r(3,0),new r(4,0),new r(5,0),new r(6,0),new r(7,0),new r(8,0),new r(9,0),new r(10,1),new r(12,1),new r(14,2),new r(18,2),new r(22,3),new r(30,3),new r(38,4),new r(54,4),new r(70,5),new r(102,5),new r(134,6),new r(198,7),new r(326,8),new r(582,9),new r(1094,10),new r(2118,24)],t.kInsertRangeLut=[0,0,8,8,0,16,8,16,16],t.kCopyRangeLut=[0,8,0,8,16,0,16,8,16]},"dec/streams.js":function(e,n,t){function r(e){this.buffer=e,this.pos=0}function i(e){this.buffer=e,this.pos=0}r.prototype.read=function(e,n,t){this.pos+t>this.buffer.length&&(t=this.buffer.length-this.pos);for(var r=0;r<t;r++)e[n+r]=this.buffer[this.pos+r];return this.pos+=t,t},t.BrotliInput=r,i.prototype.write=function(e,n){if(this.pos+n>this.buffer.length)throw new Error("Output buffer is not large enough");return this.buffer.set(e.subarray(0,n),this.pos),this.pos+=n,n},t.BrotliOutput=i},"dec/transform.js":function(e,n,t){function r(e,n,t){this.prefix=new Uint8Array(e.length),this.transform=n,this.suffix=new Uint8Array(t.length);for(var r=0;r<e.length;r++)this.prefix[r]=e.charCodeAt(r);for(var r=0;r<t.length;r++)this.suffix[r]=t.charCodeAt(r)}function i(e,n){return e[n]<192?(e[n]>=97&&e[n]<=122&&(e[n]^=32),1):e[n]<224?(e[n+1]^=32,2):(e[n+2]^=5,3)}var o=e("./dictionary");const s=0,a=1,f=2,w=3,d=4,u=5,p=6,c=7,h=8,l=9,b=10,v=11,m=12,y=13,W=14,x=15,U=16,E=17,V=18,O=20;var N=[new r("",s,""),new r("",s," "),new r(" ",s," "),new r("",m,""),new r("",b," "),new r("",s," the "),new r(" ",s,""),new r("s ",s," "),new r("",s," of "),new r("",b,""),new r("",s," and "),new r("",y,""),new r("",a,""),new r(", ",s," "),new r("",s,", "),new r(" ",b," "),new r("",s," in "),new r("",s," to "),new r("e ",s," "),new r("",s,'"'),new r("",s,"."),new r("",s,'">'),new r("",s,"\n"),new r("",w,""),new r("",s,"]"),new r("",s," for "),new r("",W,""),new r("",f,""),new r("",s," a "),new r("",s," that "),new r(" ",b,""),new r("",s,". "),new r(".",s,""),new r(" ",s,", "),new r("",x,""),new r("",s," with "),new r("",s,"'"),new r("",s," from "),new r("",s," by "),new r("",U,""),new r("",E,""),new r(" the ",s,""),new r("",d,""),new r("",s,". The "),new r("",v,""),new r("",s," on "),new r("",s," as "),new r("",s," is "),new r("",c,""),new r("",a,"ing "),new r("",s,"\n\t"),new r("",s,":"),new r(" ",s,". "),new r("",s,"ed "),new r("",O,""),new r("",V,""),new r("",p,""),new r("",s,"("),new r("",b,", "),new r("",h,""),new r("",s," at "),new r("",s,"ly "),new r(" the ",s," of "),new r("",u,""),new r("",l,""),new r(" ",b,", "),new r("",b,'"'),new r(".",s,"("),new r("",v," "),new r("",b,'">'),new r("",s,'="'),new r(" ",s,"."),new r(".com/",s,""),new r(" the ",s," of the "),new r("",b,"'"),new r("",s,". This "),new r("",s,","),new r(".",s," "),new r("",b,"("),new r("",b,"."),new r("",s," not "),new r(" ",s,'="'),new r("",s,"er "),new r(" ",v," "),new r("",s,"al "),new r(" ",v,""),new r("",s,"='"),new r("",v,'"'),new r("",b,". "),new r(" ",s,"("),new r("",s,"ful "),new r(" ",b,". "),new r("",s,"ive "),new r("",s,"less "),new r("",v,"'"),new r("",s,"est "),new r(" ",b,"."),new r("",v,'">'),new r(" ",s,"='"),new r("",b,","),new r("",s,"ize "),new r("",v,"."),new r("\xc2\xa0",s,""),new r(" ",s,","),new r("",b,'="'),new r("",v,'="'),new r("",s,"ous "),new r("",v,", "),new r("",b,"='"),new r(" ",b,","),new r(" ",v,'="'),new r(" ",v,", "),new r("",v,","),new r("",v,"("),new r("",v,". "),new r(" ",v,"."),new r("",v,"='"),new r(" ",v,". "),new r(" ",b,'="'),new r(" ",v,"='"),new r(" ",b,"='")];t.kTransforms=N,t.kNumTransforms=N.length,t.transformDictionaryWord=function(e,n,t,r,s){var a,f=N[s].prefix,w=N[s].suffix,d=N[s].transform,u=d<m?0:d-11,p=0,c=n;u>r&&(u=r);for(var h=0;h<f.length;)e[n++]=f[h++];for(t+=u,r-=u,d<=l&&(r-=d),p=0;p<r;p++)e[n++]=o.dictionary[t+p];if(a=n-r,d===b)i(e,a);else if(d===v)for(;r>0;){var y=i(e,a);a+=y,r-=y}for(var W=0;W<w.length;)e[n++]=w[W++];return n-c}},"node_modules/base64-js/index.js":function(e,n,t){"use strict";function r(e){var n=e.length;if(n%4>0)throw new Error("Invalid string. Length must be a multiple of 4");return"="===e[n-2]?2:"="===e[n-1]?1:0}function i(e){return 3*e.length/4-r(e)}function o(e){var n,t,i,o,s,a,f=e.length;s=r(e),a=new u(3*f/4-s),i=s>0?f-4:f;var w=0;for(n=0,t=0;n<i;n+=4,t+=3)o=d[e.charCodeAt(n)]<<18|d[e.charCodeAt(n+1)]<<12|d[e.charCodeAt(n+2)]<<6|d[e.charCodeAt(n+3)],a[w++]=o>>16&255,a[w++]=o>>8&255,a[w++]=255&o;return 2===s?(o=d[e.charCodeAt(n)]<<2|d[e.charCodeAt(n+1)]>>4,a[w++]=255&o):1===s&&(o=d[e.charCodeAt(n)]<<10|d[e.charCodeAt(n+1)]<<4|d[e.charCodeAt(n+2)]>>2,a[w++]=o>>8&255,a[w++]=255&o),a}function s(e){return w[e>>18&63]+w[e>>12&63]+w[e>>6&63]+w[63&e]}function a(e,n,t){for(var r,i=[],o=n;o<t;o+=3)r=(e[o]<<16)+(e[o+1]<<8)+e[o+2],i.push(s(r));return i.join("")}function f(e){for(var n,t=e.length,r=t%3,i="",o=[],s=16383,f=0,d=t-r;f<d;f+=s)o.push(a(e,f,f+s>d?d:f+s));return 1===r?(n=e[t-1],i+=w[n>>2],i+=w[n<<4&63],i+="=="):2===r&&(n=(e[t-2]<<8)+e[t-1],i+=w[n>>10],i+=w[n>>4&63],i+=w[n<<2&63],i+="="),o.push(i),o.join("")}t.byteLength=i,t.toByteArray=o,t.fromByteArray=f;for(var w=[],d=[],u="undefined"!=typeof Uint8Array?Uint8Array:Array,p="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",c=0,h=p.length;c<h;++c)w[c]=p[c],d[p.charCodeAt(c)]=c;d["-".charCodeAt(0)]=62,d["_".charCodeAt(0)]=63}};for(var t in n)n[t].folder=t.substring(0,t.lastIndexOf("/")+1);var r=function(e){var t=[];return e=e.split("/").every(function(e){return".."==e?t.pop():"."==e||""==e||t.push(e)})?t.join("/"):null,e?n[e]||n[e+".js"]||n[e+"/index.js"]:null},i=function(e,n){return e?r(e.folder+"node_modules/"+n)||i(e.parent,n):null},o=function(e,n){var t=n.match(/^\//)?null:e?n.match(/^\.\.?\//)?r(e.folder+n):i(e,n):r(n);if(!t)throw"module not found: "+n;return t.exports||(t.parent=e,t(o.bind(null,t),t,t.exports={})),t.exports};return o(null,e)},
      decompress: function (data) {
        if (!this.exports)
          this.exports = this.require("decompress.js");
        try { return this.exports(data) } catch (e) {};
        
      },
      hasUnityMarker: function (data) {
        var expectedComment = "UnityWeb Compressed Content (brotli)";
        if (!data.length)
          return false;
        var WBITS_length = (data[0] & 0x01) ? (data[0] & 0x0E) ? 4 : 7 : 1,
            WBITS = data[0] & ((1 << WBITS_length) - 1),
            MSKIPBYTES = 1 + ((Math.log(expectedComment.length - 1) / Math.log(2)) >> 3);
            commentOffset = (WBITS_length + 1 + 2 + 1 + 2 + (MSKIPBYTES << 3) + 7) >> 3;
        if (WBITS == 0x11 || commentOffset > data.length)
          return false;
        var expectedCommentPrefix = WBITS + (((3 << 1) + (MSKIPBYTES << 4) + ((expectedComment.length - 1) << 6)) << WBITS_length);
        for (var i = 0; i < commentOffset; i++, expectedCommentPrefix >>>= 8) {
          if (data[i] != (expectedCommentPrefix & 0xFF))
            return false;
        }
        return String.fromCharCode.apply(null, data.subarray(commentOffset, commentOffset + expectedComment.length)) == expectedComment;
        
      },
    },
    decompress: function (compressed, callback) {
      var decompressor = this.gzip.hasUnityMarker(compressed) ? this.gzip : this.brotli.hasUnityMarker(compressed) ? this.brotli : this.identity;
      if (this.serverSetupWarningEnabled && decompressor != this.identity) {
        console.log("You can reduce your startup time if you configure your web server to host .unityweb files using " + (decompressor == this.gzip ? "gzip" : "brotli") + " compression.");
        this.serverSetupWarningEnabled = false;
      }
      if (typeof callback != "function")
        return decompressor.decompress(compressed);
      if (!decompressor.worker) {
        var workerUrl = URL.createObjectURL(new Blob(["this.require = ", decompressor.require.toString(), "; this.decompress = ", decompressor.decompress.toString(), "; this.onmessage = ", function (e) {
          var data = { id: e.data.id, decompressed: this.decompress(e.data.compressed) };
          postMessage(data, data.decompressed ? [data.decompressed.buffer] : []);
        }.toString(), "; postMessage({ ready: true });"], { type: "text/javascript" }));
        decompressor.worker = new Worker(workerUrl);
        decompressor.worker.onmessage = function (e) {
          if (e.data.ready) {
            URL.revokeObjectURL(workerUrl);
            return;
          }
          this.callbacks[e.data.id](e.data.decompressed);
          delete this.callbacks[e.data.id];
        };
        decompressor.worker.callbacks = {};
        decompressor.worker.nextCallbackId = 0;
      }
      var id = decompressor.worker.nextCallbackId++;
      decompressor.worker.callbacks[id] = callback;
      decompressor.worker.postMessage({id: id, compressed: compressed}, [compressed.buffer]);
    },
    serverSetupWarningEnabled: true,
  },  
  Cryptography: {
    crc32: function (code) {
      var module = UnityLoader.Cryptography.crc32.module;
      if (!module) {
        var buffer = new ArrayBuffer(0x1000000);
        var asm = (function (global, env, buffer) {
          "use asm"
          var HEAPU8 = new global.Uint8Array(buffer);
          var HEAPU32 = new global.Uint32Array(buffer);
          function process(data, length) {
            data = data | 0;
            length = length | 0;
            var crc = 0;
            for (crc = HEAPU32[0x400 >> 2] | 0; length; data = (data + 1) | 0, length = (length - 1) | 0)
              crc = HEAPU32[(((crc & 0xFF) ^ HEAPU8[data]) << 2) >> 2] ^ (crc >>> 8) ^ 0xFF000000;
            HEAPU32[0x400 >> 2] = crc;
          }
          return {process: process};
        })({Uint8Array: Uint8Array, Uint32Array: Uint32Array}, null, buffer);
        
        module = UnityLoader.Cryptography.crc32.module = {
          buffer: buffer,
          HEAPU8: new Uint8Array(buffer),
          HEAPU32: new Uint32Array(buffer),
          process: asm.process,
          crc32: 0x400,
          data: 0x404,
        };
        for (var i = 0; i < 0x100; i++) {
          var a = i ^ 0xFF;
          for (var j = 0; j < 8; j++)
            a = (a >>> 1) ^ ((a & 1) ? 0xEDB88320 : 0);
          module.HEAPU32[i] = a;
        }
      }
      
      module.HEAPU32[module.crc32 >> 2] = 0;
      for (var offset = 0; offset < code.length;) {
        var length = Math.min(module.HEAPU8.length - module.data, code.length - offset);
        module.HEAPU8.set(code.subarray(offset, offset + length), module.data);
        crc = module.process(module.data, length);
        offset += length;
      }
      var crc32 = module.HEAPU32[module.crc32 >> 2];
      return new Uint8Array([crc32 >> 24, crc32 >> 16, crc32 >> 8, crc32]);

    },
    md5: function (code) {
      var module = UnityLoader.Cryptography.md5.module;
      if (!module) {
        var buffer = new ArrayBuffer(0x1000000);
        var asm = (function (global, env, buffer) {
          "use asm"
          var HEAPU32 = new global.Uint32Array(buffer);
          function process(data, blockCount) {
            data = data | 0;
            blockCount = blockCount | 0;
            var h0 = 0, h1 = 0, h2 = 0, h3 = 0, d0 = 0, d1 = 0, d2 = 0, d3 = 0, d4 = 0, i = 0, t = 0, s = 0;
            h0 = HEAPU32[0x80] | 0, h1 = HEAPU32[0x81] | 0, h2 = HEAPU32[0x82] | 0, h3 = HEAPU32[0x83] | 0;
            for (; blockCount; data = (data + 64) | 0, blockCount = (blockCount - 1) | 0) {
              d0 = h0; d1 = h1; d2 = h2; d3 = h3;
              for (i = 0; (i | 0) < 512; i = (i + 8) | 0) {
                s = (HEAPU32[i >> 2] | 0);
                h0 = (h0 + (HEAPU32[(i + 4) >> 2] | 0) + (HEAPU32[(data + (s >>> 14)) >> 2] | 0) + (
                  (i | 0) < 128 ? h3 ^ (h1 & (h2 ^ h3)) :
                  (i | 0) < 256 ? h2 ^ (h3 & (h1 ^ h2)) :
                  (i | 0) < 384 ? h1 ^ h2 ^ h3:
                  (h2 ^ (h1 | ~h3))
                )) | 0;
                t = (((h0 << (s & 31)) | (h0 >>> (32 - (s & 31)))) + h1) | 0; h0 = h3; h3 = h2; h2 = h1; h1 = t;
              }
              h0 = (h0 + d0) | 0; h1 = (h1 + d1) | 0; h2 = (h2 + d2) | 0; h3 = (h3 + d3) | 0;
            }
            HEAPU32[0x80] = h0; HEAPU32[0x81] = h1; HEAPU32[0x82] = h2; HEAPU32[0x83] = h3;
          }
          return {process: process};
        })({Uint32Array:Uint32Array}, null, buffer);

        module = UnityLoader.Cryptography.md5.module = {
          buffer: buffer,
          HEAPU8: new Uint8Array(buffer),
          HEAPU32: new Uint32Array(buffer),
          process: asm.process,
          md5: 0x200,
          data: 0x240,
        };
        
        module.HEAPU32.set(new Uint32Array([
          0x00000007, 0xD76AA478, 0x0001000C, 0xE8C7B756, 0x00020011, 0x242070DB, 0x00030016, 0xC1BDCEEE,
          0x00040007, 0xF57C0FAF, 0x0005000C, 0x4787C62A, 0x00060011, 0xA8304613, 0x00070016, 0xFD469501,
          0x00080007, 0x698098D8, 0x0009000C, 0x8B44F7AF, 0x000A0011, 0xFFFF5BB1, 0x000B0016, 0x895CD7BE,
          0x000C0007, 0x6B901122, 0x000D000C, 0xFD987193, 0x000E0011, 0xA679438E, 0x000F0016, 0x49B40821,
          0x00010005, 0xF61E2562, 0x00060009, 0xC040B340, 0x000B000E, 0x265E5A51, 0x00000014, 0xE9B6C7AA,
          0x00050005, 0xD62F105D, 0x000A0009, 0x02441453, 0x000F000E, 0xD8A1E681, 0x00040014, 0xE7D3FBC8,
          0x00090005, 0x21E1CDE6, 0x000E0009, 0xC33707D6, 0x0003000E, 0xF4D50D87, 0x00080014, 0x455A14ED,
          0x000D0005, 0xA9E3E905, 0x00020009, 0xFCEFA3F8, 0x0007000E, 0x676F02D9, 0x000C0014, 0x8D2A4C8A,
          0x00050004, 0xFFFA3942, 0x0008000B, 0x8771F681, 0x000B0010, 0x6D9D6122, 0x000E0017, 0xFDE5380C,
          0x00010004, 0xA4BEEA44, 0x0004000B, 0x4BDECFA9, 0x00070010, 0xF6BB4B60, 0x000A0017, 0xBEBFBC70,
          0x000D0004, 0x289B7EC6, 0x0000000B, 0xEAA127FA, 0x00030010, 0xD4EF3085, 0x00060017, 0x04881D05,
          0x00090004, 0xD9D4D039, 0x000C000B, 0xE6DB99E5, 0x000F0010, 0x1FA27CF8, 0x00020017, 0xC4AC5665,
          0x00000006, 0xF4292244, 0x0007000A, 0x432AFF97, 0x000E000F, 0xAB9423A7, 0x00050015, 0xFC93A039,
          0x000C0006, 0x655B59C3, 0x0003000A, 0x8F0CCC92, 0x000A000F, 0xFFEFF47D, 0x00010015, 0x85845DD1,
          0x00080006, 0x6FA87E4F, 0x000F000A, 0xFE2CE6E0, 0x0006000F, 0xA3014314, 0x000D0015, 0x4E0811A1,
          0x00040006, 0xF7537E82, 0x000B000A, 0xBD3AF235, 0x0002000F, 0x2AD7D2BB, 0x00090015, 0xEB86D391,
        ]));
      }
      
      module.HEAPU32.set(new Uint32Array([0x67452301, 0xEFCDAB89, 0x98BADCFE, 0x10325476]), module.md5 >> 2);
      for (var offset = 0; offset < code.length;) {
        var length = Math.min(module.HEAPU8.length - module.data, code.length - offset) & ~63;
        module.HEAPU8.set(code.subarray(offset, offset + length), module.data);
        offset += length;
        module.process(module.data, length >> 6);
        if (code.length - offset < 64) {
          length = code.length - offset;
          module.HEAPU8.set(code.subarray(code.length - length, code.length), module.data);
          offset += length;
          module.HEAPU8[module.data + length++] = 0x80;
          if (length > 56) {
            for (var i = length; i < 64; i++)
              module.HEAPU8[module.data + i] = 0;
            module.process(module.data, 1);
            length = 0;
          }
          for (var i = length; i < 64; i++)
            module.HEAPU8[module.data + i] = 0;
          for (var value = code.length, add = 0, i = 56; i < 64; i++, add = (value & 0xE0) >> 5, value /= 0x100)
            module.HEAPU8[module.data + i] = ((value & 0x1F) << 3) + add;
          module.process(module.data, 1);
        }
      }
      return new Uint8Array(module.HEAPU8.subarray(module.md5, module.md5 + 16));

    },
    sha1: function (code) {
      var module = UnityLoader.Cryptography.sha1.module;
      if (!module) {
        var buffer = new ArrayBuffer(0x1000000);
        var asm = (function (global, env, buffer) {
          "use asm"
          var HEAPU32 = new global.Uint32Array(buffer);
          function process(data, blockCount) {
            data = data | 0;
            blockCount = blockCount | 0;
            var h0 = 0, h1 = 0, h2 = 0, h3 = 0, h4 = 0, d0 = 0, d1 = 0, d2 = 0, d3 = 0, d4 = 0, t = 0, i = 0;
            h0 = HEAPU32[80] | 0, h1 = HEAPU32[81] | 0, h2 = HEAPU32[82] | 0, h3 = HEAPU32[83] | 0, h4 = HEAPU32[84] | 0;
            for (; blockCount; data = (data + 64) | 0, blockCount = (blockCount - 1) | 0) {
              d0 = h0; d1 = h1; d2 = h2; d3 = h3; d4 = h4;            
              for (i = 0; (i | 0) < 320; i = (i + 4) | 0, h4 = h3, h3 = h2, h2 = (h1 << 30) | (h1 >>> 2), h1 = h0, h0 = t) {
                if ((i | 0) < 64) {
                  t = (HEAPU32[(data + i) >> 2] | 0);
                  t = ((t << 24) & 0xFF000000) | ((t << 8) & 0xFF0000) | ((t >>> 8) & 0xFF00) | ((t >>> 24) & 0xFF);
                } else {
                  t = HEAPU32[(i - 12) >> 2] ^ HEAPU32[(i - 32) >> 2] ^ HEAPU32[(i - 56) >> 2] ^ HEAPU32[(i - 64) >> 2];
                  t = (t << 1) | (t >>> 31);
                }
                HEAPU32[i >> 2] = t;
                t = (t + (((h0 << 5) | (h0 >>> 27)) + h4) + (
                  (i | 0) < 80 ? ((((h1 & h2) | (~h1 & h3)) | 0) + 0x5A827999) | 0 :
                  (i | 0) < 160 ? ((h1 ^ h2 ^ h3) + 0x6ED9EBA1) | 0 :
                  (i | 0) < 240 ? (((h1 & h2) | (h1 & h3) | (h2 & h3)) + 0x8F1BBCDC) | 0 :
                  ((h1 ^ h2 ^ h3) + 0xCA62C1D6) | 0
                )) | 0;
              }            
              h0 = (h0 + d0) | 0; h1 = (h1 + d1) | 0; h2 = (h2 + d2) | 0; h3 = (h3 + d3) | 0; h4 = (h4 + d4) | 0;
            }
            HEAPU32[80] = h0; HEAPU32[81] = h1; HEAPU32[82] = h2; HEAPU32[83] = h3; HEAPU32[84] = h4;
          }
          return {process: process};
        })({Uint32Array:Uint32Array}, null, buffer);
        
        module = UnityLoader.Cryptography.sha1.module = {
          buffer: buffer,
          HEAPU8: new Uint8Array(buffer),
          HEAPU32: new Uint32Array(buffer),
          process: asm.process,
          sha1: 0x140,
          data: 0x180,
        };
      }
      
      module.HEAPU32.set(new Uint32Array([0x67452301, 0xEFCDAB89, 0x98BADCFE, 0x10325476, 0xC3D2E1F0]), module.sha1 >> 2);
      for (var offset = 0; offset < code.length;) {
        var length = Math.min(module.HEAPU8.length - module.data, code.length - offset) & ~63;
        module.HEAPU8.set(code.subarray(offset, offset + length), module.data);
        offset += length;
        module.process(module.data, length >> 6);
        if (code.length - offset < 64) {
          length = code.length - offset;
          module.HEAPU8.set(code.subarray(code.length - length, code.length), module.data);
          offset += length;
          module.HEAPU8[module.data + length++] = 0x80;
          if (length > 56) {
            for (var i = length; i < 64; i++)
              module.HEAPU8[module.data + i] = 0;
            module.process(module.data, 1);
            length = 0;
          }
          for (var i = length; i < 64; i++)
            module.HEAPU8[module.data + i] = 0;
          for (var value = code.length, add = 0, i = 63; i >=56; i--, add = (value & 0xE0) >> 5, value /= 0x100)
            module.HEAPU8[module.data + i] = ((value & 0x1F) << 3) + add;
          module.process(module.data, 1);
        }
      }
      var sha1 = new Uint8Array(20);
      for (var i = 0; i < sha1.length; i++)
        sha1[i] = module.HEAPU8[module.sha1 + (i & ~3) + 3 - (i & 3)];    
      return sha1;

    },
  
  },
  Error: {
    // stacktrace example:
    //
    // [Chrome]
    // Error
    //    at Array.eWg (blob:http%3A//localhost%3A8080/7dd54af3-48c5-47e1-893f-5f1ef09ab62b:10:238896)
    //    at Object.P7h [as dynCall_iiii] (blob:http%3A//localhost%3A8080/7dd54af3-48c5-47e1-893f-5f1ef09ab62b:28:33689)
    //    at invoke_iiii (blob:http%3A//localhost%3A8080/972f149f-a28e-4ee9-a1c7-45e8c4b0998b:1:334638)
    //    at DJd (blob:http%3A//localhost%3A8080/7dd54af3-48c5-47e1-893f-5f1ef09ab62b:15:260807)
    //    at Object.dynCall (blob:http%3A//localhost%3A8080/972f149f-a28e-4ee9-a1c7-45e8c4b0998b:1:7492)
    //    at browserIterationFunc (blob:http%3A//localhost%3A8080/972f149f-a28e-4ee9-a1c7-45e8c4b0998b:1:207518)
    //    at Object.runIter (blob:http%3A//localhost%3A8080/972f149f-a28e-4ee9-a1c7-45e8c4b0998b:1:189915)
    //
    // [Chrome WebAssembly]
    //    at  (<WASM>[24622]+70)
    //    at  (<WASM>[24000]+73)
    //
    // [Firefox]
    // eWg@blob:http://localhost:8080/0e677969-e11c-e24b-bb23-4f3afdbd5a3a:10:1
    // P7h@blob:http://localhost:8080/0e677969-e11c-e24b-bb23-4f3afdbd5a3a:28:1
    // invoke_iiii@blob:http://localhost:8080/67513e21-4cf2-de4e-a571-c6ee67cc2a72:1:334616
    // DJd@blob:http://localhost:8080/0e677969-e11c-e24b-bb23-4f3afdbd5a3a:15:1
    // Runtime.dynCall@blob:http://localhost:8080/67513e21-4cf2-de4e-a571-c6ee67cc2a72:1:7469
    // _emscripten_set_main_loop/browserIterationFunc@blob:http://localhost:8080/67513e21-4cf2-de4e-a571-c6ee67cc2a72:1:207510
    // Browser.mainLoop.runIter@blob:http://localhost:8080/67513e21-4cf2-de4e-a571-c6ee67cc2a72:1:189915
    //
    // [Firefox WebAssembly]
    // wasm-function[24622]@blob:null/2e0a79af-37a7-ac43-9534-4ac66e23fea4:8059611:1
    // wasm-function[24000]@blob:null/2e0a79af-37a7-ac43-9534-4ac66e23fea4:7932153:1
    //
    // [Safari]
    // eWg@blob:http://localhost:8080/6efe7f5a-b930-45c3-9175-296366f9d9f4:10:238896
    // P7h@blob:http://localhost:8080/6efe7f5a-b930-45c3-9175-296366f9d9f4:28:33689
    // invoke_iiii@blob:http://localhost:8080/597cffca-fc52-4586-9da7-f9c8e591738b:1:334638
    // DJd@blob:http://localhost:8080/6efe7f5a-b930-45c3-9175-296366f9d9f4:15:260809
    // dynCall@blob:http://localhost:8080/597cffca-fc52-4586-9da7-f9c8e591738b:1:7496
    // browserIterationFunc@blob:http://localhost:8080/597cffca-fc52-4586-9da7-f9c8e591738b:1:207525
    // runIter@blob:http://localhost:8080/597cffca-fc52-4586-9da7-f9c8e591738b:1:189919

    init: (function () {
      Error.stackTraceLimit = 50;
      window.addEventListener("error", function (e) {
        var Module = UnityLoader.Error.getModule(e);
        if (!Module)
          return UnityLoader.Error.handler(e);
        var debugSymbolsUrl = Module.useWasm ? Module.wasmSymbolsUrl : Module.asmSymbolsUrl;
        if (!debugSymbolsUrl)
          return UnityLoader.Error.handler(e, Module);
        var xhr = new XMLHttpRequest();
        xhr.open("GET", Module.resolveBuildUrl(debugSymbolsUrl));
        xhr.responseType = "arraybuffer";
        xhr.onload = function () {
          UnityLoader.loadCode(UnityLoader.Compression.decompress(new Uint8Array(xhr.response)), function (id) {
            Module.demangleSymbol = UnityLoader[id]();
            UnityLoader.Error.handler(e, Module);
          });
        };        
        xhr.send();
      });
      return true;
    })(),
    stackTraceFormat: navigator.userAgent.indexOf("Chrome") != -1 ? "(\\s+at\\s+)(([\\w\\d_\\.]*?)([\\w\\d_$]+)(/[\\w\\d_\\./]+|))(\\s+\\[.*\\]|)\\s*\\((blob:.*)\\)" : 
                                                                    "(\\s*)(([\\w\\d_\\.]*?)([\\w\\d_$]+)(/[\\w\\d_\\./]+|))(\\s+\\[.*\\]|)\\s*@(blob:.*)",
    stackTraceFormatWasm: navigator.userAgent.indexOf("Chrome") != -1 ? "((\\s+at\\s*)\\s\\(<WASM>\\[(\\d+)\\]\\+\\d+\\))()" : 
                                                                        "((\\s*)wasm-function\\[(\\d+)\\])@(blob:.*)",
    blobParseRegExp: new RegExp("^(blob:.*)(:\\d+:\\d+)$"),
    getModule: function (e) {
      var traceMatch = e.message.match(new RegExp(this.stackTraceFormat, "g"));
      for (var trace in traceMatch) {
        var traceParse = traceMatch[trace].match(new RegExp("^" + this.stackTraceFormat + "$"));
        var blobParse = traceParse[7].match(this.blobParseRegExp);
        if (blobParse && UnityLoader.Blobs[blobParse[1]] && UnityLoader.Blobs[blobParse[1]].Module)
          return UnityLoader.Blobs[blobParse[1]].Module;
      }
    },
    demangle: function (e, Module) {
      var message = e.message;
      if (!Module)
        return message;
      message = message.replace(new RegExp(this.stackTraceFormat, "g"), function (trace) {
        var errParse = trace.match(new RegExp("^" + this.stackTraceFormat + "$"));
        var blobParse = errParse[7].match(this.blobParseRegExp);
        var functionName = Module.demangleSymbol ? Module.demangleSymbol(errParse[4]) : errParse[4];
        var url = blobParse && UnityLoader.Blobs[blobParse[1]] && UnityLoader.Blobs[blobParse[1]].url ? UnityLoader.Blobs[blobParse[1]].url : "blob";
        return errParse[1] + functionName + (errParse[2] != functionName ? " ["+ errParse[2] + "]" : "") +
          " (" + (blobParse ? url.substr(url.lastIndexOf("/") + 1) + blobParse[2] : errParse[7]) + ")";
      }.bind(this));
      if (Module.useWasm) {
        message = message.replace(new RegExp(this.stackTraceFormatWasm, "g"), function (trace) {
          var errParse = trace.match(new RegExp("^" + this.stackTraceFormatWasm + "$"));
          var functionName = Module.demangleSymbol ? Module.demangleSymbol(errParse[3]) : errParse[3];
          var blobParse = errParse[4].match(this.blobParseRegExp);
          var url = blobParse && UnityLoader.Blobs[blobParse[1]] && UnityLoader.Blobs[blobParse[1]].url ? UnityLoader.Blobs[blobParse[1]].url : "blob";
          return (functionName == errParse[3] ? errParse[1] : errParse[2] + functionName + " [wasm:"+ errParse[3] + "]") +
                 (errParse[4] ? " (" + (blobParse ? url.substr(url.lastIndexOf("/") + 1) + blobParse[2] : errParse[4]) + ")" : "");
        }.bind(this));
      }
      return message;
    },
    handler: function (e, Module) {
      var message = Module ? this.demangle(e, Module) : e.message;
      if (Module && Module.errorhandler && Module.errorhandler(message, e.filename, e.lineno))
        return;
      console.log("Invoking error handler due to\n" + message);
      if (typeof dump == "function")
        dump("Invoking error handler due to\n" + message);
      // Firefox has a bug where it's IndexedDB implementation will throw UnknownErrors, which are harmless, and should not be shown.
      if (message.indexOf("UnknownError") != -1)
        return;
      // Ignore error when application terminated with return code 0
      if (message.indexOf("Program terminated with exit(0)") != -1)
        return;
      if (this.didShowErrorMessage)
        return;
      var message = "An error occurred running the Unity content on this page. See your browser JavaScript console for more info. The error was:\n" + message;
      if (message.indexOf("DISABLE_EXCEPTION_CATCHING") != -1) {
        message = "An exception has occurred, but exception handling has been disabled in this build. If you are the developer of this content, enable exceptions in your project WebGL player settings to be able to catch the exception or see the stack trace.";
      } else if (message.indexOf("Cannot enlarge memory arrays") != -1) {
        message = "Out of memory. If you are the developer of this content, try allocating more memory to your WebGL build in the WebGL player settings.";
      } else if (message.indexOf("Invalid array buffer length") != -1  || message.indexOf("Invalid typed array length") != -1 || message.indexOf("out of memory") != -1 || message.indexOf("could not allocate memory") != -1) {
          message = "The browser could not allocate enough memory for the WebGL content. If you are the developer of this content, try allocating less memory to your WebGL build in the WebGL player settings.";
      }
      alert(message);
      this.didShowErrorMessage = true;
      
    },
    popup: function (gameInstance, message, callbacks) {
      callbacks = callbacks || [{text: "OK"}];
      var popup = document.createElement("div");
      popup.style.cssText = "position: absolute; top: 50%; left: 50%; -webkit-transform: translate(-50%, -50%); transform: translate(-50%, -50%); text-align: center; border: 1px solid black; padding: 5px; background: #E8E8E8";
      var messageElement = document.createElement("span");
      messageElement.textContent  = message;      
      popup.appendChild(messageElement);
      popup.appendChild(document.createElement("br"));
      for (var i = 0; i < callbacks.length; i++) {
        var button = document.createElement("button");
        if (callbacks[i].text)
          button.textContent = callbacks[i].text;
        if (callbacks[i].callback)
          button.onclick = callbacks[i].callback;
        button.style.margin = "5px";
        button.addEventListener("click", function () { gameInstance.container.removeChild(popup); })
        popup.appendChild(button);
      }
      gameInstance.container.appendChild(popup);
      
    },
    
  },
  Job: {
    schedule: function (Module, id, dependencies, callback, parameters) {
      parameters = parameters || {};
      var job = Module.Jobs[id];
      if (!job)
        job = Module.Jobs[id] = {dependencies: {}, dependants: {}};
      if (job.callback)
        throw "[UnityLoader.Job.schedule] job '" + id + "' has been already scheduled";
      if (typeof callback != "function")
        throw "[UnityLoader.Job.schedule] job '" + id + "' has invalid callback";
      if (typeof parameters != "object")
        throw "[UnityLoader.Job.schedule] job '" + id + "' has invalid parameters";
      job.callback = function (x,y) { job.starttime = performance.now(); callback(x,y) };
      job.parameters = parameters;
      job.complete = function (result) {
        job.endtime = performance.now();
        job.result = {value: result};
        for (var dependant in job.dependants) {
          var dependantJob = Module.Jobs[dependant];
          dependantJob.dependencies[id] = job.dependants[dependant] = false;
          var pending = typeof dependantJob.callback != "function";
          for (var dependency in dependantJob.dependencies)
            pending = pending || dependantJob.dependencies[dependency];
          if (!pending) {
            if (dependantJob.executed)
              throw "[UnityLoader.Job.schedule] job '" + id + "' has already been executed";
            dependantJob.executed = true;
            setTimeout(dependantJob.callback.bind(null, Module, dependantJob), 0);
          }
        }
      }
      var pending = false;
      dependencies.forEach(function (dependency) {
        var dependencyJob = Module.Jobs[dependency];
        if (!dependencyJob)
          dependencyJob = Module.Jobs[dependency] = {dependencies: {}, dependants: {}};
        if (job.dependencies[dependency] = dependencyJob.dependants[id] = !dependencyJob.result)
          pending = true;
      });
      if (!pending) {
        job.executed = true;
        setTimeout(job.callback.bind(null, Module, job), 0);
      }

    },
    result: function (Module, id) {
      var job = Module.Jobs[id];
      if (!job)
        throw "[UnityLoader.Job.result] job '" + id + "' does not exist";
      if (typeof job.result != "object")
        throw "[UnityLoader.Job.result] job '" + id + "' has invalid result";
      return job.result.value;

    },

  },
  Progress: {
    Styles: {
      Dark: {
        progressLogoUrl: "data:image/png;base64,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",
        progressEmptyUrl: "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAI0AAAASCAYAAABmbl0zAAAACXBIWXMAAAsSAAALEgHS3X78AAAATUlEQVRo3u3aIQ4AIAwEQUr4/5cPiyMVBDOj0M2mCKgkGdAwjYCudZzLOLiITYPrCdEgGkSDaEA0iAbRIBpEA6JBNHx1vnL7V4NNwxsbCNMGI3YImu0AAAAASUVORK5CYII=",
        progressFullUrl: "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAI0AAAASCAYAAABmbl0zAAAACXBIWXMAAAsSAAALEgHS3X78AAAAO0lEQVRo3u3SQREAAAjDMMC/56EB3omEXjtJCg5GAkyDaTANpsE0YBpMg2kwDaYB02AaTINpMA2Yhr8FO18EIBpZMeQAAAAASUVORK5CYII=",
      },
      Light: {
        progressLogoUrl: "data:image/png;base64,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",
        progressEmptyUrl: "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAI0AAAASCAYAAABmbl0zAAAACXBIWXMAAAsSAAALEgHS3X78AAAAUUlEQVRo3u3aMQ4AEAxAUcRJzGb3v1mt3cQglvcmc/NTA3XMFQUuNCPgVk/nahwchE2D6wnRIBpEg2hANIgG0SAaRAOiQTR8lV+5/avBpuGNDcz6A6oq1CgNAAAAAElFTkSuQmCC",
        progressFullUrl: "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAI0AAAASCAYAAABmbl0zAAAACXBIWXMAAAsSAAALEgHS3X78AAAAQElEQVRo3u3SMREAMAgAsVIpnTvj3xlogDmR8PfxftaBgSsBpsE0mAbTYBowDabBNJgG04BpMA2mwTSYBkzDXgP/hgGnr4PpeAAAAABJRU5ErkJggg==",
      },
    },
    handler: function (gameInstance, progress) {
      if (!gameInstance.Module)
        return;
      var style = UnityLoader.Progress.Styles[gameInstance.Module.splashScreenStyle];
      var progressLogoUrl = gameInstance.Module.progressLogoUrl ? gameInstance.Module.resolveBuildUrl(gameInstance.Module.progressLogoUrl) : style.progressLogoUrl;
      var progressEmptyUrl = gameInstance.Module.progressEmptyUrl ? gameInstance.Module.resolveBuildUrl(gameInstance.Module.progressEmptyUrl) : style.progressEmptyUrl;
      var progressFullUrl = gameInstance.Module.progressFullUrl ? gameInstance.Module.resolveBuildUrl(gameInstance.Module.progressFullUrl) : style.progressFullUrl;      
      var commonStyle = "position: absolute; left: 50%; top: 50%; -webkit-transform: translate(-50%, -50%); transform: translate(-50%, -50%);";
      if (!gameInstance.logo) {
        gameInstance.logo = document.createElement("div");
        gameInstance.logo.style.cssText = commonStyle + "background: url('" + progressLogoUrl + "') no-repeat center / contain; width: 154px; height: 130px;";
        gameInstance.container.appendChild(gameInstance.logo);
      }
      if (!gameInstance.progress) {        
        gameInstance.progress = document.createElement("div");
        gameInstance.progress.style.cssText = commonStyle + " height: 18px; width: 141px; margin-top: 90px;";
        gameInstance.progress.empty = document.createElement("div");
        gameInstance.progress.empty.style.cssText = "background: url('" + progressEmptyUrl + "') no-repeat right / cover; float: right; width: 100%; height: 100%; display: inline-block;";
        gameInstance.progress.appendChild(gameInstance.progress.empty);
        gameInstance.progress.full = document.createElement("div");
        gameInstance.progress.full.style.cssText = "background: url('" + progressFullUrl + "') no-repeat left / cover; float: left; width: 0%; height: 100%; display: inline-block;";
        gameInstance.progress.appendChild(gameInstance.progress.full);
        gameInstance.container.appendChild(gameInstance.progress);
      }
      gameInstance.progress.full.style.width = (100 * progress) + "%";
      gameInstance.progress.empty.style.width = (100 * (1 - progress)) + "%";
      if (progress == 1)
        gameInstance.logo.style.display = gameInstance.progress.style.display = "none";

    },
    update: function (Module, id, e) {
      var progress = Module.buildDownloadProgress[id];
      if (!progress)
        progress = Module.buildDownloadProgress[id] = {
          started: false,
          finished: false,
          lengthComputable: false,
          total: 0,
          loaded: 0,
        };
      if (typeof e == "object" && (e.type == "progress" || e.type == "load")) {
        if (!progress.started) {
          progress.started = true;
          progress.lengthComputable = e.lengthComputable;
          progress.total = e.total;
        }
        progress.loaded = e.loaded;
        if (e.type == "load")
          progress.finished = true;
      }
      var loaded = 0, total = 0, started = 0, computable = 0, unfinishedNonComputable = 0;
      for (var id in Module.buildDownloadProgress) {
        var progress = Module.buildDownloadProgress[id];
        if (!progress.started)
          return 0;
        started++;
        if (progress.lengthComputable) {
          loaded += progress.loaded;
          total += progress.total;
          computable++;
        } else if (!progress.finished) {
          unfinishedNonComputable++;
        }
      }
      var totalProgress = started ? (started - unfinishedNonComputable - (total ? computable * (total - loaded) / total : 0)) / started : 0;
      Module.gameInstance.onProgress(Module.gameInstance, 0.9 * totalProgress);

    },

  },
  // The Unity WebGL generated content depends on SystemInfo, therefore it should not be changed. If any modification is necessary, do it at your own risk.
  SystemInfo: (function() {
    var unknown = "-";
    var nVer = navigator.appVersion;
    var nAgt = navigator.userAgent;
    var browser = navigator.appName;
    var version = navigator.appVersion;
    var majorVersion = parseInt(navigator.appVersion, 10);
    var nameOffset, verOffset, ix;
    if ((verOffset = nAgt.indexOf("Opera")) != -1) {
      browser = "Opera";
      version = nAgt.substring(verOffset + 6);
      if ((verOffset = nAgt.indexOf("Version")) != -1) {
        version = nAgt.substring(verOffset + 8);
      }
    } else if ((verOffset = nAgt.indexOf("MSIE")) != -1) {
      browser = "Microsoft Internet Explorer";
      version = nAgt.substring(verOffset + 5);
    } else if ((verOffset = nAgt.indexOf("Edge")) != -1) {
      browser = "Edge";
      version = nAgt.substring(verOffset + 5);
    } else if ((verOffset = nAgt.indexOf("Chrome")) != -1) {
      browser = "Chrome";
      version = nAgt.substring(verOffset + 7);
    } else if ((verOffset = nAgt.indexOf("Safari")) != -1) {
      browser = "Safari";
      version = nAgt.substring(verOffset + 7);
      if ((verOffset = nAgt.indexOf("Version")) != -1) {
        version = nAgt.substring(verOffset + 8);
      }
    } else if ((verOffset = nAgt.indexOf("Firefox")) != -1) {
      browser = "Firefox";
      version = nAgt.substring(verOffset + 8);
    } else if (nAgt.indexOf("Trident/") != -1) {
      browser = "Microsoft Internet Explorer";
      version = nAgt.substring(nAgt.indexOf("rv:") + 3);
    } else if ((nameOffset = nAgt.lastIndexOf(" ") + 1) < (verOffset = nAgt.lastIndexOf("/"))) {
      browser = nAgt.substring(nameOffset, verOffset);
      version = nAgt.substring(verOffset + 1);
      if (browser.toLowerCase() == browser.toUpperCase()) {
        browser = navigator.appName;
      }
    }
    if ((ix = version.indexOf(";")) != -1)
      version = version.substring(0, ix);
    if ((ix = version.indexOf(" ")) != -1)
      version = version.substring(0, ix);
    if ((ix = version.indexOf(")")) != -1)
      version = version.substring(0, ix);
    majorVersion = parseInt("" + version, 10);
    if (isNaN(majorVersion)) {
      version = "" + parseFloat(navigator.appVersion);
      majorVersion = parseInt(navigator.appVersion, 10);
    }
    else version = "" + parseFloat(version);
    var mobile = /Mobile|mini|Fennec|Android|iP(ad|od|hone)/.test(nVer);
    var os = unknown;
    var clientStrings = [
      {s: "Windows 3.11", r: /Win16/},
      {s: "Windows 95", r: /(Windows 95|Win95|Windows_95)/},
      {s: "Windows ME", r: /(Win 9x 4.90|Windows ME)/},
      {s: "Windows 98", r: /(Windows 98|Win98)/},
      {s: "Windows CE", r: /Windows CE/},
      {s: "Windows 2000", r: /(Windows NT 5.0|Windows 2000)/},
      {s: "Windows XP", r: /(Windows NT 5.1|Windows XP)/},
      {s: "Windows Server 2003", r: /Windows NT 5.2/},
      {s: "Windows Vista", r: /Windows NT 6.0/},
      {s: "Windows 7", r: /(Windows 7|Windows NT 6.1)/},
      {s: "Windows 8.1", r: /(Windows 8.1|Windows NT 6.3)/},
      {s: "Windows 8", r: /(Windows 8|Windows NT 6.2)/},
      {s: "Windows 10", r: /(Windows 10|Windows NT 10.0)/},
      {s: "Windows NT 4.0", r: /(Windows NT 4.0|WinNT4.0|WinNT|Windows NT)/},
      {s: "Windows ME", r: /Windows ME/},
      {s: "Android", r: /Android/},
      {s: "Open BSD", r: /OpenBSD/},
      {s: "Sun OS", r: /SunOS/},
      {s: "Linux", r: /(Linux|X11)/},
      {s: "iOS", r: /(iPhone|iPad|iPod)/},
      {s: "Mac OS X", r: /Mac OS X/},
      {s: "Mac OS", r: /(MacPPC|MacIntel|Mac_PowerPC|Macintosh)/},
      {s: "QNX", r: /QNX/},
      {s: "UNIX", r: /UNIX/}, 
      {s: "BeOS", r: /BeOS/},
      {s: "OS/2", r: /OS\/2/},
      {s: "Search Bot", r: /(nuhk|Googlebot|Yammybot|Openbot|Slurp|MSNBot|Ask Jeeves\/Teoma|ia_archiver)/}
    ];
    for (var id in clientStrings) {
      var cs = clientStrings[id];
      if (cs.r.test(nAgt)) {
        os = cs.s;
        break;
      }
    }

    var osVersion = unknown;
    if (/Windows/.test(os)) {
      osVersion = /Windows (.*)/.exec(os)[1];
      os = "Windows";
    }
    switch (os) {
    case "Mac OS X":
      osVersion = /Mac OS X (10[\.\_\d]+)/.exec(nAgt)[1];
      break;
    case "Android":
      osVersion = /Android ([\.\_\d]+)/.exec(nAgt)[1];
      break;
    case "iOS":
      osVersion = /OS (\d+)_(\d+)_?(\d+)?/.exec(nVer);
      osVersion = osVersion[1] + "." + osVersion[2] + "." + (osVersion[3] | 0);
      break;
    }
    return {
      width: screen.width ? screen.width : 0,
      height: screen.height ? screen.height : 0,
      browser: browser,
      browserVersion: version,
      mobile: mobile,
      os: os,
      osVersion: osVersion,
      gpu: (function() {
        var canvas = document.createElement("canvas");
        var gl = canvas.getContext("experimental-webgl");
        if(gl) {
          var renderedInfo = gl.getExtension("WEBGL_debug_renderer_info");
          if(renderedInfo) {
            return gl.getParameter(renderedInfo.UNMASKED_RENDERER_WEBGL);
          }
        }
        return unknown;
      })(),
      language: window.navigator.userLanguage || window.navigator.language,
      hasWebGL: (function() {
        if (!window.WebGLRenderingContext) {
          return 0;
        }
        var canvas = document.createElement("canvas");
        var gl = canvas.getContext("webgl2");
        if (!gl) {
          gl = canvas.getContext("experimental-webgl2");
          if (!gl) {
            gl = canvas.getContext("webgl");
            if (!gl) {
              gl = canvas.getContext("experimental-webgl");
              if (!gl) {
                return 0;
              }
            }
            return 1;
          }
          return 2;
        }
        return 2;
      })(),
      hasCursorLock: (function() {
        var e = document.createElement("canvas");
        if (e["requestPointerLock"] || e["mozRequestPointerLock"] || e["webkitRequestPointerLock"] || e["msRequestPointerLock"]) return 1; else return 0;
      })(),
      hasFullscreen: (function() {
        var e = document.createElement("canvas");
        if (e["requestFullScreen"] || e["mozRequestFullScreen"] || e["msRequestFullscreen"] || e["webkitRequestFullScreen"]) {
          if (browser.indexOf("Safari") == -1 || version >= 10.1) return 1;
        }
        return 0;
      })(),
      hasThreads: typeof SharedArrayBuffer !== 'undefined',
      hasWasm: typeof WebAssembly == "object" && typeof WebAssembly.validate == "function" && typeof WebAssembly.compile == "function",
    };

  })(),
  compatibilityCheck: function (gameInstance, onsuccess, onerror) {
    if (!UnityLoader.SystemInfo.hasWebGL) {
      gameInstance.popup("Your browser does not support WebGL",
        [{text: "OK", callback: onerror}]);
    } else if (UnityLoader.SystemInfo.mobile) {
      gameInstance.popup("Please note that Unity WebGL is not currently supported on mobiles. Press OK if you wish to continue anyway.",
        [{text: "OK", callback: onsuccess}]);
    } else if (["Edge", "Firefox", "Chrome", "Safari"].indexOf(UnityLoader.SystemInfo.browser) == -1) {
      gameInstance.popup("Please note that your browser is not currently supported for this Unity WebGL content. Press OK if you wish to continue anyway.",
        [{text: "OK", callback: onsuccess}]);
    } else {
      onsuccess();
    }
    
  },
  Blobs: {},
  loadCode: function (code, onload, info) {
    var functionId = [].slice.call(UnityLoader.Cryptography.md5(code)).map(function(x) { return ("0" + x.toString(16)).substr(-2); }).join("");
    var script = document.createElement("script");
    var blobUrl = URL.createObjectURL(new Blob(["UnityLoader[\"" + functionId + "\"]=", code], { type: "text/javascript" }));
    UnityLoader.Blobs[blobUrl] = info;
    script.src = blobUrl;
    script.onload = function () {
      URL.revokeObjectURL(blobUrl);
      onload(functionId);
    }
    document.body.appendChild(script);

  },
  setupIndexedDBJob: function (Module, job) {
    function setupIndexedDB(idb) {
      if (setupIndexedDB.called)
        return;
      setupIndexedDB.called = true;
      Module.indexedDB = idb;
      job.complete();
    }
    try {
      var idb = window.indexedDB || window.mozIndexedDB || window.webkitIndexedDB || window.msIndexedDB;
      var testRequest = idb.open("/idbfs-test");
      testRequest.onerror = function(e) { e.preventDefault(); setupIndexedDB(); }
      testRequest.onsuccess = function() { testRequest.result.close(); setupIndexedDB(idb); }
      setTimeout(setupIndexedDB, 1000);
    } catch (e) {
      setupIndexedDB();
    }
    
  },
  initWasmCache: function (Module, urlId) {
    if (!Module.cacheControl || ["must-revalidate", "immutable"].indexOf(Module.cacheControl[urlId] || Module.cacheControl["default"]) == -1)
      return;
    Module.wasmCache = {
      update: function () {
        var wasm = this;
        if (wasm.cache && wasm.download && wasm.request) {
          if (wasm.cache.module && wasm.cache.md5 == wasm.download.md5) {
            wasm.request.wasmInstantiate(wasm.cache.module).then(function (result) {
              console.log("[Unity Cache] WebAssembly module '" + wasm.cache.url + "' successfully loaded from the indexedDB cache");
              wasm.request.callback(result);
            });
          } else {
            wasm.request.wasmInstantiate(wasm.download.binary).then(function (result) {
              wasm.cache.module = result.module;
              wasm.cache.md5 = wasm.download.md5;
              UnityLoader.UnityCache.WebAssembly.put(wasm.cache, function () {
                console.log("[Unity Cache] WebAssembly module '" + wasm.cache.url + "' successfully stored in the indexedDB cache");
              }, function (error) {
                console.log("[Unity Cache] WebAssembly module '" + wasm.cache.url + "' not stored in the indexedDB cache due to the error: " + error);
              });
              wasm.request.callback(result.instance);
            });
          }
        }
      },
    };
    UnityLoader.UnityCache.WebAssembly.get(Module.resolveBuildUrl(Module[urlId]), function (result) { Module.wasmCache.cache = result; Module.wasmCache.update(); });
    
  },
  processWasmCodeJob: function (Module, job) {
    Module.wasmBinary = UnityLoader.Job.result(Module, "downloadWasmCode").data;
    if (Module.wasmCache) {
      Module.wasmCache.download = {
        binary: Module.wasmBinary,
        md5: [].slice.call(UnityLoader.Cryptography.md5(Module.wasmBinary)).map(function(x) { return ("0" + x.toString(16)).substr(-2); }).join(""),
      };
      Module.wasmCache.update();
    }
    job.complete();
    
  },
  processWasmFrameworkJob: function (Module, job) {
    var code = UnityLoader.Job.result(Module, "downloadWasmFramework").data;
    UnityLoader.loadCode(code, function (id) {
      var blob = new Blob([code], { type: "application/javascript" });
      Module["mainScriptUrlOrBlob"] = blob;
      UnityLoader[id](Module);
      job.complete();
    }, {Module: Module, url: Module["wasmFrameworkUrl"]});
    
  },
  processAsmCodeJob: function (Module, job) {
    var asm = UnityLoader.Job.result(Module, "downloadAsmCode").data;
    UnityLoader.loadCode(!Math.fround ? UnityLoader.Utils.optimizeMathFround(asm) : asm, function (id) {
      Module.asm = UnityLoader[id];
      job.complete();
    }, {Module: Module, url: Module["asmCodeUrl"]});
    
  },
  processAsmFrameworkJob: function (Module, job) {
    var code = UnityLoader.Job.result(Module, "downloadAsmFramework").data;
    UnityLoader.loadCode(code, function (id) {
      var blob = new Blob([code], { type: "application/javascript" });
      Module["mainScriptUrlOrBlob"] = blob;
      UnityLoader[id](Module);
      job.complete();
    }, {Module: Module, url: Module["asmFrameworkUrl"]});
    
  },
  processMemoryInitializerJob: function (Module, job) {
    Module["memoryInitializerRequest"].status = 200;
    Module["memoryInitializerRequest"].response = UnityLoader.Job.result(Module, "downloadMemoryInitializer").data;
    if (Module["memoryInitializerRequest"].callback)
      Module["memoryInitializerRequest"].callback();
    job.complete();
    
  },
  processDataJob: function (Module, job) {
    var data = UnityLoader.Job.result(Module, "downloadData").data;
    var view = new DataView(data.buffer, data.byteOffset, data.byteLength);
    var pos = 0;
    var prefix = "UnityWebData1.0\0";
    if (!String.fromCharCode.apply(null, data.subarray(pos, pos + prefix.length)) == prefix)
      throw "unknown data format";
    pos += prefix.length;
    var headerSize = view.getUint32(pos, true); pos += 4;
    while (pos < headerSize) {
      var offset = view.getUint32(pos, true); pos += 4;
      var size = view.getUint32(pos, true); pos += 4;
      var pathLength = view.getUint32(pos, true); pos += 4;
      var path = String.fromCharCode.apply(null, data.subarray(pos, pos + pathLength)); pos += pathLength;
      for (var folder = 0, folderNext = path.indexOf("/", folder) + 1 ; folderNext > 0; folder = folderNext, folderNext = path.indexOf("/", folder) + 1)
        Module["FS_createPath"](path.substring(0, folder), path.substring(folder, folderNext - 1), true, true);
      Module["FS_createDataFile"](path, null, data.subarray(offset, offset + size), true, true, true);
    }
    Module["removeRunDependency"]("processDataJob");
    job.complete();

  },
  downloadJob: function (Module, job) {
    var xhr = job.parameters.objParameters ? new UnityLoader.UnityCache.XMLHttpRequest(job.parameters.objParameters) : new XMLHttpRequest();
    xhr.open("GET", job.parameters.url);
    xhr.responseType = "arraybuffer";
    //xhr.onload = function () { UnityLoader.Compression.decompress(new Uint8Array(xhr.response), function (decompressed) { job.complete(decompressed) }) };
    xhr.onload = function () { UnityLoader.Compression.decompress(new Uint8Array(xhr.response), function (decompressed) { var result = {data: decompressed, cached: xhr.xhr.cached}; job.complete(result); }) };
    if (job.parameters.onprogress)
      xhr.addEventListener("progress", job.parameters.onprogress);
    if (job.parameters.onload)
      xhr.addEventListener("load", job.parameters.onload);
    xhr.send();
    
  },
  scheduleBuildDownloadJob: function (Module, jobId, urlId) {
    UnityLoader.Progress.update(Module, jobId);
    UnityLoader.Job.schedule(Module, jobId, [], UnityLoader.downloadJob, {
      url: Module.resolveBuildUrl(Module[urlId]),
      onprogress: function(e) { UnityLoader.Progress.update(Module, jobId, e); },
      onload: function(e) { UnityLoader.Progress.update(Module, jobId, e); },
      objParameters: Module.companyName && Module.productName && Module.cacheControl && (Module.cacheControl[urlId] || Module.cacheControl["default"]) ? {
        companyName: Module.companyName,
        productName: Module.productName,
        cacheControl: Module.cacheControl[urlId] || Module.cacheControl["default"],
      } : null,
    });
    
  },
  loadModule: function (Module) {
    Module.useWasm = Module["wasmCodeUrl"] && UnityLoader.SystemInfo.hasWasm;
    
    if (Module.useWasm) {
      // UnityLoader.initWasmCache(Module, "wasmCodeUrl");
      UnityLoader.scheduleBuildDownloadJob(Module, "downloadWasmCode", "wasmCodeUrl");
      UnityLoader.Job.schedule(Module, "processWasmCode", ["downloadWasmCode"], UnityLoader.processWasmCodeJob);
      if (Module["wasmMemoryUrl"])
      {
        UnityLoader.scheduleBuildDownloadJob(Module, "downloadMemoryInitializer", "wasmMemoryUrl");
        UnityLoader.Job.schedule(Module, "processMemoryInitializer", ["downloadMemoryInitializer"], UnityLoader.processMemoryInitializerJob);
        Module["memoryInitializerRequest"] = { addEventListener: function (type, callback) { Module["memoryInitializerRequest"].callback = callback; } }        
      }
      UnityLoader.scheduleBuildDownloadJob(Module, "downloadWasmFramework", "wasmFrameworkUrl");
      UnityLoader.Job.schedule(Module, "processWasmFramework", ["downloadWasmFramework", "processWasmCode", "setupIndexedDB"], UnityLoader.processWasmFrameworkJob);

    } else if (Module["asmCodeUrl"]) {
      UnityLoader.scheduleBuildDownloadJob(Module, "downloadAsmCode", "asmCodeUrl");
      UnityLoader.Job.schedule(Module, "processAsmCode", ["downloadAsmCode"], UnityLoader.processAsmCodeJob);
      UnityLoader.scheduleBuildDownloadJob(Module, "downloadMemoryInitializer", "asmMemoryUrl");
      UnityLoader.Job.schedule(Module, "processMemoryInitializer", ["downloadMemoryInitializer"], UnityLoader.processMemoryInitializerJob);
      Module["memoryInitializerRequest"] = { addEventListener: function (type, callback) { Module["memoryInitializerRequest"].callback = callback; } }
      if (Module.asmLibraryUrl)
        Module.dynamicLibraries = [Module.asmLibraryUrl].map(Module.resolveBuildUrl);
      UnityLoader.scheduleBuildDownloadJob(Module, "downloadAsmFramework", "asmFrameworkUrl");
      UnityLoader.Job.schedule(Module, "processAsmFramework", ["downloadAsmFramework", "processAsmCode", "setupIndexedDB"], UnityLoader.processAsmFrameworkJob);

    } else {
      throw "WebAssembly support is not detected in this browser.";
    }

    UnityLoader.scheduleBuildDownloadJob(Module, "downloadData", "dataUrl");
    UnityLoader.Job.schedule(Module, "setupIndexedDB", [], UnityLoader.setupIndexedDBJob);
        
    Module["preRun"].push(function () {
      Module["addRunDependency"]("processDataJob");
      UnityLoader.Job.schedule(Module, "processData", ["downloadData"], UnityLoader.processDataJob);
    });
    
  },
  instantiate: function (container, url, parameters) {
    function instantiate(container, gameInstance) {
      if (typeof container == "string" && !(container = document.getElementById(container)))
        return false;

      container.innerHTML = "";
      container.style.border = container.style.margin = container.style.padding = 0;
      if (getComputedStyle(container).getPropertyValue("position") == "static")
        container.style.position = "relative";
      container.style.width = gameInstance.width || container.style.width;
      container.style.height = gameInstance.height || container.style.height;
      gameInstance.container = container;

      var Module = gameInstance.Module;
      Module.canvas = document.createElement("canvas");
      Module.canvas.style.width = "100%";
      Module.canvas.style.height = "100%";
      Module.canvas.addEventListener("contextmenu", function (e) { e.preventDefault() }),
      Module.canvas.id = "#canvas";
      container.appendChild(Module.canvas);

      gameInstance.compatibilityCheck(gameInstance, function () {
        var xhr = new XMLHttpRequest();
        xhr.open("GET", gameInstance.url, true);
        xhr.responseType = "text";
        xhr.onerror = function() {
          Module.print("Could not download " + gameInstance.url);
          if (document.URL.indexOf("file:") == 0) {
            alert ("It seems your browser does not support running Unity WebGL content from file:// urls. Please upload it to an http server, or try a different browser.");
          }   
        }
        xhr.onload = function () {
          var parameters = JSON.parse(xhr.responseText);
          for (var parameter in parameters) {
            if (typeof Module[parameter] == "undefined")
              Module[parameter] = parameters[parameter];
          }

          var graphicsApiMatch = false;
          for(var i = 0; i < Module.graphicsAPI.length; i++) {
            var api = Module.graphicsAPI[i];
            if (api == "WebGL 2.0" && UnityLoader.SystemInfo.hasWebGL == 2) {
                graphicsApiMatch = true;
            }
            else if (api == "WebGL 1.0" && UnityLoader.SystemInfo.hasWebGL >= 1) {
                graphicsApiMatch = true;
            }
            else
              Module.print("Warning: Unsupported graphics API " + api);
          }
          if (!graphicsApiMatch) {
            gameInstance.popup("Your browser does not support any of the required graphics API for this content: " + Module.graphicsAPI, [{text: "OK"}]);
            return;
          }

          container.style.background = Module.backgroundUrl ? "center/cover url('" + Module.resolveBuildUrl(Module.backgroundUrl) + "')" :
            Module.backgroundColor ? " " + Module.backgroundColor : "";

          // show loading screen as soon as possible
          gameInstance.onProgress(gameInstance, 0.0);

          UnityLoader.loadModule(Module);
        }
        xhr.send();
      }, function () {
        Module.printErr("Instantiation of the '" + url + "' terminated due to the failed compatibility check.");
      });
      
      return true;
    }
    
    function resolveURL(url) {
      resolveURL.link = resolveURL.link || document.createElement("a");
      resolveURL.link.href = url;
      return resolveURL.link.href;
    }

    var gameInstance = {
      url: url,
      onProgress: UnityLoader.Progress.handler,
      compatibilityCheck: UnityLoader.compatibilityCheck,
      Module: {
        graphicsAPI: ["WebGL 2.0", "WebGL 1.0"],
        onAbort: function(what){
          if (what !== undefined) {
            this.print(what);
            this.printErr(what);
            what = JSON.stringify(what);
          } else {
            what = '';
          }
          throw 'abort(' + what + ') at ' + this.stackTrace();
        },
        preRun: [],
        postRun: [],
        print: function (message) { console.log(message); },
        printErr: function (message) { console.error(message); },
        Jobs: {},
        buildDownloadProgress: {},
        resolveBuildUrl: function (buildUrl) { return buildUrl.match(/(http|https|ftp|file):\/\//) ? buildUrl : url.substring(0, url.lastIndexOf("/") + 1) + buildUrl; },
        streamingAssetsUrl: function () { return resolveURL(this.resolveBuildUrl("../StreamingAssets")) },
        pthreadMainPrefixURL: "Build/",
        wasmRequest: function (wasmInstantiate, callback) {
          if (this.wasmCache && !UnityLoader.SystemInfo.hasThreads) {
            this.wasmCache.request = {
              wasmInstantiate: wasmInstantiate,
              callback: callback,
            };
            this.wasmCache.update();
          } else {
            wasmInstantiate(this.wasmBinary).then(function (result) { callback(result.instance); });
          }
        },
      },
      SetFullscreen: function() {
        if (gameInstance.Module.SetFullscreen)
          return gameInstance.Module.SetFullscreen.apply(gameInstance.Module, arguments);
      },
      SendMessage: function() {
        if (gameInstance.Module.SendMessage)
          return gameInstance.Module.SendMessage.apply(gameInstance.Module, arguments);
      },
    };

    gameInstance.Module.gameInstance = gameInstance;
    gameInstance.popup = function (message, callbacks) { return UnityLoader.Error.popup(gameInstance, message, callbacks); };
    gameInstance.Module.postRun.push(function() {
      gameInstance.onProgress(gameInstance, 1);
    });

    for (var parameter in parameters) {
      if (parameter == "Module") {
        for (var moduleParameter in parameters[parameter])
          gameInstance.Module[moduleParameter] = parameters[parameter][moduleParameter];
      } else {
        gameInstance[parameter] = parameters[parameter];
      }
    }

    if (!instantiate(container, gameInstance))
      document.addEventListener("DOMContentLoaded", function () { instantiate(container, gameInstance) });
    
    return gameInstance;

  },
  Utils: {
    assert: function (condition, text) {
      if (!condition)
        abort("Assertion failed: " + text);
      
    },
    optimizeMathFround: function (code, embeddedAsm) {
      console.log("optimizing out Math.fround calls");

      var State = {
        LOOKING_FOR_MODULE: 0,
        SCANNING_MODULE_VARIABLES: 1,
        SCANNING_MODULE_FUNCTIONS: 2,
      };
      var stateSwitchMarker = [
        "EMSCRIPTEN_START_ASM",
        "EMSCRIPTEN_START_FUNCS",
        "EMSCRIPTEN_END_FUNCS",
      ];
      var froundPrefix = "var";
      var froundMarker = "global.Math.fround;";
      
      var position = 0;
      var state = embeddedAsm ? State.LOOKING_FOR_MODULE : State.SCANNING_MODULE_VARIABLES;
      var froundLast = 0;
      var froundLength = 0;
          
      for(; state <= State.SCANNING_MODULE_FUNCTIONS && position < code.length; position++) {
        if (code[position] == 0x2F && code[position + 1] == 0x2F && code[position + 2] == 0x20 &&
            String.fromCharCode.apply(null, code.subarray(position + 3, position + 3 + stateSwitchMarker[state].length)) === stateSwitchMarker[state]) {
          // if code at position starts with "// " + stateSwitchMarker[state]
          state++;
        } else if (state == State.SCANNING_MODULE_VARIABLES && !froundLength && code[position] == 0x3D &&
            String.fromCharCode.apply(null, code.subarray(position + 1, position + 1 + froundMarker.length)) === froundMarker) {
          // if we are at the module variable section and Math_fround name has not yet been found and code at position starts with "=" + froundMarker
          froundLast = position - 1;
          while(code[froundLast - froundLength] != 0x20)
            froundLength++; // scan back until the first space character (it is always present as at least it is a part of the previously found "// ")
          if (!froundLength || String.fromCharCode.apply(null, code.subarray(froundLast - froundLength - froundPrefix.length, froundLast - froundLength)) !== froundPrefix)
            froundLast = froundLength = 0;
        } else if (froundLength && code[position] == 0x28) {
          // if Math_fround name has been found and code at position starts with "("
          var nameLength = 0;
          while (nameLength < froundLength && code[position - 1 - nameLength] == code[froundLast - nameLength])
            nameLength++;
          if (nameLength == froundLength) {
            var c = code[position - 1 - nameLength];
            if (c < 0x24 || (0x24 < c && c < 0x30) || (0x39 < c && c < 0x41) || (0x5A < c && c < 0x5F) || (0x5F < c && c < 0x61) || 0x7A < c) {
              // if the matched Math_fround name is not a suffix of another identifier, i.e. it's preceding character does not match [$0-9A-Z_a-z]
              for(;nameLength; nameLength--)
                code[position - nameLength] = 0x20; // fill the Math_fround name with spaces (replacement works faster than shifting back the rest of the code)
            }
          }
        }            
      }
      return code;

    },

  },
  UnityCache: function () {
    var UnityCacheDatabase = { name: "UnityCache", version: 2 };
    var XMLHttpRequestStore = { name: "XMLHttpRequest", version: 1 };
    var WebAssemblyStore = { name: "WebAssembly", version: 1 };
    
    function log(message) {
      console.log("[UnityCache] " + message);
    }
    
    function resolveURL(url) {
      resolveURL.link = resolveURL.link || document.createElement("a");
      resolveURL.link.href = url;
      return resolveURL.link.href;
    }
    
    function isCrossOriginURL(url) {
      var originMatch = window.location.href.match(/^[a-z]+:\/\/[^\/]+/);
      return !originMatch || url.lastIndexOf(originMatch[0], 0);
    }

    function UnityCache() {
      var cache = this;
      cache.queue = [];

      function initDatabase(database) {
        if (typeof cache.database != "undefined")
          return;
        cache.database = database;
        if (!cache.database)
          log("indexedDB database could not be opened");
        while (cache.queue.length) {
          var queued = cache.queue.shift();
          if (cache.database) {
            cache.execute.apply(cache, queued);
          } else if (typeof queued.onerror == "function") {
            queued.onerror(new Error("operation cancelled"));
          }
        }
      }
      
      try {
        var indexedDB = window.indexedDB || window.mozIndexedDB || window.webkitIndexedDB || window.msIndexedDB;
        function upgradeDatabase() {
          var openRequest = indexedDB.open(UnityCacheDatabase.name, UnityCacheDatabase.version);
          openRequest.onupgradeneeded = function (e) {
            var database = e.target.result;
            if (!database.objectStoreNames.contains(WebAssemblyStore.name))
              database.createObjectStore(WebAssemblyStore.name);
          };
          openRequest.onsuccess = function (e) { initDatabase(e.target.result); };
          openRequest.onerror = function () { initDatabase(null); };
        }
        var openRequest = indexedDB.open(UnityCacheDatabase.name);
        openRequest.onupgradeneeded = function (e) {
          var objectStore = e.target.result.createObjectStore(XMLHttpRequestStore.name, { keyPath: "url" });
          ["version", "company", "product", "updated", "revalidated", "accessed"].forEach(function (index) { objectStore.createIndex(index, index); });
        };
        openRequest.onsuccess = function (e) {
          var database = e.target.result;
          if (database.version < UnityCacheDatabase.version) {
            database.close();
            upgradeDatabase();
          } else {
            initDatabase(database);
          }
        };
        openRequest.onerror = function () { initDatabase(null); };
        setTimeout(openRequest.onerror, 1000);
      } catch (e) {
        initDatabase(null);
      }
    };
    
    UnityCache.prototype.execute = function (store, operation, parameters, onsuccess, onerror) {
      if (this.database) {
        try {
          var target = this.database.transaction([store], ["put", "delete", "clear"].indexOf(operation) != -1 ? "readwrite" : "readonly").objectStore(store);
          if (operation == "openKeyCursor") {
            target = target.index(parameters[0]);
            parameters = parameters.slice(1);
          }
          var request = target[operation].apply(target, parameters);
          if (typeof onsuccess == "function")
            request.onsuccess = function (e) { onsuccess(e.target.result); };
          request.onerror = onerror;
        } catch (e) {
          if (typeof onerror == "function")
            onerror(e);
        }
      } else if (typeof this.database == "undefined") {
        this.queue.push(arguments);
      } else if (typeof onerror == "function") {
        onerror(new Error("indexedDB access denied"));
      }
    };
    
    var unityCache = new UnityCache();
    
    function createXMLHttpRequestResult(url, company, product, timestamp, xhr) {
      var result = { url: url, version: XMLHttpRequestStore.version, company: company, product: product, updated: timestamp, revalidated: timestamp, accessed: timestamp, responseHeaders: {}, xhr: {} };
      if (xhr) {
        ["Last-Modified", "ETag"].forEach(function (header) { result.responseHeaders[header] = xhr.getResponseHeader(header); });
        ["responseURL", "status", "statusText", "response"].forEach(function (property) { result.xhr[property] = xhr[property]; });
      }
      return result;
    }

    function CachedXMLHttpRequest(objParameters) {
      this.cache = { enabled: false };
      if (objParameters) {
        this.cache.control = objParameters.cacheControl;
        this.cache.company = objParameters.companyName;
        this.cache.product = objParameters.productName;
      }
      this.xhr = new XMLHttpRequest(objParameters);
      this.xhr.cached = false;
      this.xhr.addEventListener("load", function () {
        var xhr = this.xhr, cache = this.cache;
        if (!cache.enabled || cache.revalidated)
          return;
        if (xhr.status == 304) {
          cache.result.revalidated = cache.result.accessed;
          cache.revalidated = true;
          unityCache.execute(XMLHttpRequestStore.name, "put", [cache.result]);
          this.xhr.cached = true;
          log("'" + cache.result.url + "' successfully revalidated and served from the indexedDB cache");
        } else if (xhr.status == 200) {
          cache.result = createXMLHttpRequestResult(cache.result.url, cache.company, cache.product, cache.result.accessed, xhr);
          cache.revalidated = true;
          unityCache.execute(XMLHttpRequestStore.name, "put", [cache.result], function (result) {
            log("'" + cache.result.url + "' successfully downloaded and stored in the indexedDB cache");
          }, function (error) {
            log("'" + cache.result.url + "' successfully downloaded but not stored in the indexedDB cache due to the error: " + error);
          });
        } else {
          log("'" + cache.result.url + "' request failed with status: " + xhr.status + " " + xhr.statusText);
        }
      }.bind(this));
    };
    
    CachedXMLHttpRequest.prototype.send = function (data) {
      var xhr = this.xhr, cache = this.cache;
      var sendArguments = arguments;
      cache.enabled = cache.enabled && xhr.responseType == "arraybuffer" && !data;
      if (!cache.enabled)
        return xhr.send.apply(xhr, sendArguments);
      unityCache.execute(XMLHttpRequestStore.name, "get", [cache.result.url], function (result) {
        if (!result || result.version != XMLHttpRequestStore.version) {
          xhr.send.apply(xhr, sendArguments);
          return;
        }
        cache.result = result;
        cache.result.accessed = Date.now();
        if (cache.control == "immutable") {
          cache.revalidated = true;
          unityCache.execute(XMLHttpRequestStore.name, "put", [cache.result]);
          xhr.dispatchEvent(new Event('load'));
          xhr.cached = true;
          log("'" + cache.result.url + "' served from the indexedDB cache without revalidation");
        } else if (isCrossOriginURL(cache.result.url) && (cache.result.responseHeaders["Last-Modified"] || cache.result.responseHeaders["ETag"])) {
          var headXHR = new XMLHttpRequest();
          headXHR.open("HEAD", cache.result.url);
          headXHR.onload = function () {
            cache.revalidated = ["Last-Modified", "ETag"].every(function (header) {
              return !cache.result.responseHeaders[header] || cache.result.responseHeaders[header] == headXHR.getResponseHeader(header);
            });
            if (cache.revalidated) {
              cache.result.revalidated = cache.result.accessed;
              unityCache.execute(XMLHttpRequestStore.name, "put", [cache.result]);
              xhr.dispatchEvent(new Event('load'));
              xhr.cached = true;
              log("'" + cache.result.url + "' successfully revalidated and served from the indexedDB cache");
            } else {
              xhr.send.apply(xhr, sendArguments);
            }
          }
          headXHR.send();
        } else {
          if (cache.result.responseHeaders["Last-Modified"]) {
            xhr.setRequestHeader("If-Modified-Since", cache.result.responseHeaders["Last-Modified"]);
            xhr.setRequestHeader("Cache-Control", "no-cache");
          } else if (cache.result.responseHeaders["ETag"]) {
            xhr.setRequestHeader("If-None-Match", cache.result.responseHeaders["ETag"]);
            xhr.setRequestHeader("Cache-Control", "no-cache");
          }
          xhr.send.apply(xhr, sendArguments);
        }
      }, function (error) {
        xhr.send.apply(xhr, sendArguments);
      });
    };
    
    CachedXMLHttpRequest.prototype.open = function (method, url, async, user, password) {
      this.cache.result = createXMLHttpRequestResult(resolveURL(url), this.cache.company, this.cache.product, Date.now());
      this.cache.enabled = ["must-revalidate", "immutable"].indexOf(this.cache.control) != -1 && method == "GET" && this.cache.result.url.match("^https?:\/\/")
        && (typeof async == "undefined" || async) && typeof user == "undefined" && typeof password == "undefined";
      this.cache.revalidated = false;
      return this.xhr.open.apply(this.xhr, arguments);
    };
    
    CachedXMLHttpRequest.prototype.setRequestHeader = function (header, value) {
      this.cache.enabled = false;
      return this.xhr.setRequestHeader.apply(this.xhr, arguments);
    };
    
    var xhr = new XMLHttpRequest();
    for (var property in xhr) {
      if (!CachedXMLHttpRequest.prototype.hasOwnProperty(property)) {
        (function (property) {
          Object.defineProperty(CachedXMLHttpRequest.prototype, property, typeof xhr[property] == "function" ? {
            value: function () { return this.xhr[property].apply(this.xhr, arguments); },
          } : {
            get: function () { return this.cache.revalidated && this.cache.result.xhr.hasOwnProperty(property) ? this.cache.result.xhr[property] : this.xhr[property]; },
            set: function (value) { this.xhr[property] = value; },
          });
        })(property);
      }
    }
    
    return {
      XMLHttpRequest: CachedXMLHttpRequest,
      WebAssembly: {
        get: function (url, callback) {
          var base = { url: resolveURL(url), version: WebAssemblyStore.version, module: null, md5: null };
          unityCache.execute(WebAssemblyStore.name, "get", [base.url], function (result) {
            callback(result && result.version == WebAssemblyStore.version ? result : base);
          }, function () {
            callback(base);
          });
        },
        put: function (result, onsuccess, onerror) {
          unityCache.execute(WebAssemblyStore.name, "put", [result, result.url], onsuccess, onerror);
        },
      },
    };
  } (),

};
