Initial upload: Source and Game Build
28
GameQuiz-InputKeyBoard/appmanifest.json
Normal file
@@ -0,0 +1,28 @@
|
||||
{
|
||||
"name": "GameQuiz-InputKeyBoard",
|
||||
"short_name": "GameQuiz-InputKeyBoard",
|
||||
"start_url": "index.html",
|
||||
"display": "fullscreen",
|
||||
"orientation": "any",
|
||||
"icons": [{
|
||||
"src": "icon-16.png",
|
||||
"sizes": "16x16",
|
||||
"type": "image/png"
|
||||
}, {
|
||||
"src": "icon-32.png",
|
||||
"sizes": "32x32",
|
||||
"type": "image/png"
|
||||
}, {
|
||||
"src": "icon-128.png",
|
||||
"sizes": "128x128",
|
||||
"type": "image/png"
|
||||
}, {
|
||||
"src": "icon-256.png",
|
||||
"sizes": "144x144",
|
||||
"type": "image/png"
|
||||
}, {
|
||||
"src": "icon-256.png",
|
||||
"sizes": "256x256",
|
||||
"type": "image/png"
|
||||
}]
|
||||
}
|
||||
BIN
GameQuiz-InputKeyBoard/bg.mp4
Normal file
485
GameQuiz-InputKeyBoard/c2runtime.js
Normal file
@@ -0,0 +1,485 @@
|
||||
// Generated by Construct 2, the HTML5 game and app creator :: https://www.construct.net
|
||||
'use strict';var aa,ca,da,ea,ga,ia,ka,la,A,ma,na,oa,pa,qa,sa,ta,ua,va,wa,xa,Aa,Ba,Ca,N,Da,Ea,Fa,Ga,Ha,Q,Ia,Ja,La,Ma,Na,Oa,Pa,Ra,Sa,Ta,Ua,Va,Wa,Xa,$a,ab,bb,cb,db,eb,fb,gb,hb,ib,jb,kb,nb,ob,pb,qb,rb,sb,tb,ub,vb,wb,xb,yb,zb,Ab,Bb,Cb,Db,Ib,Jb,Kb,Lb,Mb,Nb,Ob,Pb,Qb,Rb,Sb,Tb,Ub,Vb,Wb,Xb,Yb,Zb,$b,ac,bc,cc,dc,ec,fc,gc,hc,ic,jc,kc={};"function"!==typeof Object.getPrototypeOf&&(Object.getPrototypeOf="object"===typeof"test".__proto__?function(f){return f.__proto__}:function(f){return f.constructor.prototype});
|
||||
(function(){function f(a,e,c,d){this.set(a,e,c,d)}function q(){this.Wb=this.Vb=this.Yb=this.Xb=this.hc=this.gc=this.Ib=this.Hb=0}function r(a,e,c,d){a<e?c<d?(n=a<c?a:c,L=e>d?e:d):(n=a<d?a:d,L=e>c?e:c):c<d?(n=e<c?e:c,L=a>d?a:d):(n=e<d?e:d,L=a>c?a:c)}function t(){this.items=this.$d=null;this.oi=0;ha&&(this.$d=new Set);this.Ah=[];this.Ye=!0}function b(a){W[E++]=a}function p(){this.Z=this.ol=this.y=this.am=0}function k(a){this.nh=[];this.ep=this.gp=this.hp=this.fp=0;this.Yi(a)}function d(a,e){this.hm=
|
||||
a;this.gm=e;this.cells={}}function h(a,e){this.hm=a;this.gm=e;this.cells={}}function c(a,e,c){var d;return x.length?(d=x.pop(),d.Nm=a,d.x=e,d.y=c,d):new ca(a,e,c)}function a(a,e,c){this.Nm=a;this.x=e;this.y=c;this.Cb=new da}function e(a,e,c){var d;return y.length?(d=y.pop(),d.Nm=a,d.x=e,d.y=c,d):new ea(a,e,c)}function l(a,e,c){this.Nm=a;this.x=e;this.y=c;this.Cb=[];this.Sg=!0;this.Xd=new da;this.Dh=!1}function g(a,e){return a.Jd-e.Jd}ga=function(a){window.console&&window.console.log&&window.console.log(a)};
|
||||
ia=function(a){window.console&&window.console.error&&window.console.error(a)};aa=function(a){return a};ka=function(a){return"undefined"===typeof a};la=function(a){return"number"===typeof a};A=function(a){return"string"===typeof a};ma=function(a){return 0<a&&0===(a-1&a)};na=function(a){--a;for(var e=1;32>e;e<<=1)a=a|a>>e;return a+1};oa=function(a){return 0>a?-a:a};pa=function(a,e){return a>e?a:e};qa=function(a,e){return a<e?a:e};sa=Math.PI;ta=function(a){return 0<=a?a|0:(a|0)-1};ua=function(a){var e=
|
||||
a|0;return e===a?e:e+1};va=function(a,e,c,d,g,v,b,h){var l,m,u,n;a<c?(m=a,l=c):(m=c,l=a);g<b?(n=g,u=b):(n=b,u=g);if(l<n||m>u)return!1;e<d?(m=e,l=d):(m=d,l=e);v<h?(n=v,u=h):(n=h,u=v);if(l<n||m>u)return!1;l=g-a+b-c;m=v-e+h-d;a=c-a;e=d-e;g=b-g;v=h-v;h=oa(e*g-v*a);return oa(g*m-v*l)>h?!1:oa(a*m-e*l)<=h};f.prototype.set=function(a,e,c,d){this.left=a;this.top=e;this.right=c;this.bottom=d};f.prototype.Kh=function(a){this.left=a.left;this.top=a.top;this.right=a.right;this.bottom=a.bottom};f.prototype.width=
|
||||
function(){return this.right-this.left};f.prototype.height=function(){return this.bottom-this.top};f.prototype.offset=function(a,e){this.left+=a;this.top+=e;this.right+=a;this.bottom+=e;return this};f.prototype.normalize=function(){var a=0;this.left>this.right&&(a=this.left,this.left=this.right,this.right=a);this.top>this.bottom&&(a=this.top,this.top=this.bottom,this.bottom=a)};f.prototype.ad=function(a,e){return a>=this.left&&a<=this.right&&e>=this.top&&e<=this.bottom};f.prototype.Ph=function(a){return this.left===
|
||||
a.left&&this.top===a.top&&this.right===a.right&&this.bottom===a.bottom};wa=f;q.prototype.jl=function(a){this.Hb=a.left;this.Ib=a.top;this.gc=a.right;this.hc=a.top;this.Xb=a.right;this.Yb=a.bottom;this.Vb=a.left;this.Wb=a.bottom};q.prototype.Kr=function(a,e){if(0===e)this.jl(a);else{var c=Math.sin(e),d=Math.cos(e),g=a.left*c,v=a.top*c,b=a.right*c,c=a.bottom*c,h=a.left*d,l=a.top*d,m=a.right*d,d=a.bottom*d;this.Hb=h-v;this.Ib=l+g;this.gc=m-v;this.hc=l+b;this.Xb=m-c;this.Yb=d+b;this.Vb=h-c;this.Wb=d+
|
||||
g}};q.prototype.offset=function(a,e){this.Hb+=a;this.Ib+=e;this.gc+=a;this.hc+=e;this.Xb+=a;this.Yb+=e;this.Vb+=a;this.Wb+=e;return this};var n=0,L=0;q.prototype.jp=function(a){r(this.Hb,this.gc,this.Xb,this.Vb);a.left=n;a.right=L;r(this.Ib,this.hc,this.Yb,this.Wb);a.top=n;a.bottom=L};q.prototype.ad=function(a,e){var c=this.Hb,d=this.Ib,g=this.gc-c,v=this.hc-d,b=this.Xb-c,h=this.Yb-d,l=a-c,m=e-d,u=g*g+v*v,n=g*b+v*h,v=g*l+v*m,w=b*b+h*h,k=b*l+h*m,f=1/(u*w-n*n),g=(w*v-n*k)*f,u=(u*k-n*v)*f;if(0<=g&&0<
|
||||
u&&1>g+u)return!0;g=this.Vb-c;v=this.Wb-d;u=g*g+v*v;n=g*b+v*h;v=g*l+v*m;f=1/(u*w-n*n);g=(w*v-n*k)*f;u=(u*k-n*v)*f;return 0<=g&&0<u&&1>g+u};xa=q;Aa=function(a,e){for(var c in e)e.hasOwnProperty(c)&&(a[c]=e[c]);return a};Ba=function(a,e){var c,d;e=ta(e);if(!(0>e||e>=a.length)){c=e;for(d=a.length-1;c<d;c++)a[c]=a[c+1];Ca(a,d)}};Ca=function(a,e){a.length=e};N=function(a){Ca(a,0)};Da=function(a,e){N(a);var c,d;c=0;for(d=e.length;c<d;++c)a[c]=e[c]};Ea=function(a,e){a.push.apply(a,e)};Fa=function(a,e){var c,
|
||||
d;c=0;for(d=a.length;c<d;++c)if(a[c]===e)return c;return-1};Ga=function(a,e){var c=Fa(a,e);-1!==c&&Ba(a,c)};Ha=function(a,e,c){return a<e?e:a>c?c:a};Q=function(a){return a/(180/sa)};Ia=function(a){return 180/sa*a};Ja=function(a){a%=360;0>a&&(a+=360);return a};La=function(a){a%=2*sa;0>a&&(a+=2*sa);return a};Ma=function(a){return Ja(Ia(a))};Na=function(a){return La(Q(a))};Oa=function(a,e,c,d){return Math.atan2(d-e,c-a)};Pa=function(a,e){if(a===e)return 0;var c=Math.sin(a),d=Math.cos(a),g=Math.sin(e),
|
||||
v=Math.cos(e),c=c*g+d*v;return 1<=c?0:-1>=c?sa:Math.acos(c)};Ra=function(a,e,c){var d=Math.sin(a),g=Math.cos(a),v=Math.sin(e),b=Math.cos(e);return Math.acos(d*v+g*b)>c?0<g*v-d*b?La(a+c):La(a-c):La(e)};Sa=function(a,e){var c=Math.sin(a),d=Math.cos(a),g=Math.sin(e),v=Math.cos(e);return 0>=d*g-c*v};Ta=function(a,e,c,d,g,v){if(0===c)return v?a:e;var b=Math.sin(c);c=Math.cos(c);a-=d;e-=g;var h=a*b;a=a*c-e*b;e=e*c+h;return v?a+d:e+g};Ua=function(a,e,c,d){a=c-a;e=d-e;return Math.sqrt(a*a+e*e)};Va=function(a,
|
||||
e){return!a!==!e};Wa=function(a){for(var e in a)if(a.hasOwnProperty(e))return!0;return!1};Xa=function(a){for(var e in a)a.hasOwnProperty(e)&&delete a[e]};var w=+new Date;$a=function(){if("undefined"!==typeof window.performance){var a=window.performance;if("undefined"!==typeof a.now)return a.now();if("undefined"!==typeof a.webkitNow)return a.webkitNow();if("undefined"!==typeof a.mozNow)return a.mozNow();if("undefined"!==typeof a.msNow)return a.msNow()}return Date.now()-w};var m=!1,u=m=!1,fa=!1;"undefined"!==
|
||||
typeof window&&(m=/chrome/i.test(navigator.userAgent)||/chromium/i.test(navigator.userAgent),m=!m&&/safari/i.test(navigator.userAgent),u=/(iphone|ipod|ipad)/i.test(navigator.userAgent),fa=window.c2ejecta);var ha=!m&&!fa&&!u&&"undefined"!==typeof Set&&"undefined"!==typeof Set.prototype.forEach;t.prototype.contains=function(a){return this.ve()?!1:ha?this.$d.has(a):this.items&&this.items.hasOwnProperty(a)};t.prototype.add=function(a){if(ha)this.$d.has(a)||(this.$d.add(a),this.Ye=!1);else{var e=a.toString(),
|
||||
c=this.items;c?c.hasOwnProperty(e)||(c[e]=a,this.oi++,this.Ye=!1):(this.items={},this.items[e]=a,this.oi=1,this.Ye=!1)}};t.prototype.remove=function(a){if(!this.ve())if(ha)this.$d.has(a)&&(this.$d["delete"](a),this.Ye=!1);else if(this.items){a=a.toString();var e=this.items;e.hasOwnProperty(a)&&(delete e[a],this.oi--,this.Ye=!1)}};t.prototype.clear=function(){this.ve()||(ha?this.$d.clear():(this.items=null,this.oi=0),N(this.Ah),this.Ye=!0)};t.prototype.ve=function(){return 0===this.count()};t.prototype.count=
|
||||
function(){return ha?this.$d.size:this.oi};var W=null,E=0;t.prototype.Xx=function(){if(!this.Ye){if(ha)N(this.Ah),W=this.Ah,E=0,this.$d.forEach(b),W=null,E=0;else{var a=this.Ah;N(a);var e,c=0,d=this.items;if(d)for(e in d)d.hasOwnProperty(e)&&(a[c++]=d[e])}this.Ye=!0}};t.prototype.Bf=function(){this.Xx();return this.Ah};da=t;new da;ab=function(a,e){ha?bb(a,e.$d):cb(a,e.Bf())};bb=function(a,e){var c,d,g,v;d=c=0;for(g=a.length;c<g;++c)v=a[c],e.has(v)||(a[d++]=v);Ca(a,d)};cb=function(a,e){var c,d,g,v;
|
||||
d=c=0;for(g=a.length;c<g;++c)v=a[c],-1===Fa(e,v)&&(a[d++]=v);Ca(a,d)};p.prototype.add=function(a){this.y=a-this.am;this.ol=this.Z+this.y;this.am=this.ol-this.Z-this.y;this.Z=this.ol};p.prototype.reset=function(){this.Z=this.ol=this.y=this.am=0};db=p;eb=function(a){return a.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")};k.prototype.Yi=function(a){this.pr=a;this.Wk=a.length/2;this.nh.length=a.length;this.cm=this.dm=-1;this.mp=0};k.prototype.Dw=function(){return!this.pr.length};k.prototype.Ha=function(){for(var a=
|
||||
this.nh,e=a[0],c=e,d=a[1],g=d,v,b,h=1,l=this.Wk;h<l;++h)b=2*h,v=a[b],b=a[b+1],v<e&&(e=v),v>c&&(c=v),b<d&&(d=b),b>g&&(g=b);this.fp=e;this.gp=c;this.hp=d;this.ep=g};k.prototype.jl=function(a,e,c){this.nh.length=8;this.Wk=4;var d=this.nh;d[0]=a.left-e;d[1]=a.top-c;d[2]=a.right-e;d[3]=a.top-c;d[4]=a.right-e;d[5]=a.bottom-c;d[6]=a.left-e;d[7]=a.bottom-c;this.dm=a.right-a.left;this.cm=a.bottom-a.top;this.Ha()};k.prototype.gu=function(a,e,c){if(this.dm!==a||this.cm!==e||this.mp!==c){this.dm=a;this.cm=e;
|
||||
this.mp=c;var d,g,v,b,h,l=0,m=1,u=this.pr,n=this.nh;0!==c&&(l=Math.sin(c),m=Math.cos(c));c=0;for(v=this.Wk;c<v;c++)d=2*c,g=d+1,b=u[d]*a,h=u[g]*e,n[d]=b*m-h*l,n[g]=h*m+b*l;this.Ha()}};k.prototype.ad=function(a,e){var c=this.nh;if(a===c[0]&&e===c[1])return!0;var d,g,v,b=this.Wk,h=this.fp-110,l=this.hp-101,m=this.gp+131,u=this.ep+120,n,w,k=0,f=0;for(d=0;d<b;d++)g=2*d,v=(d+1)%b*2,n=c[g],g=c[g+1],w=c[v],v=c[v+1],va(h,l,a,e,n,g,w,v)&&k++,va(m,u,a,e,n,g,w,v)&&f++;return 1===k%2||1===f%2};fb=k;d.prototype.jf=
|
||||
function(a,e,d){var g;g=this.cells[a];return g?(g=g[e])?g:d?(g=c(this,a,e),this.cells[a][e]=g):null:d?(g=c(this,a,e),this.cells[a]={},this.cells[a][e]=g):null};d.prototype.pc=function(a){return ta(a/this.hm)};d.prototype.qc=function(a){return ta(a/this.gm)};d.prototype.update=function(a,e,c){var d,g,v,b,h;if(e)for(d=e.left,g=e.right;d<=g;++d)for(v=e.top,b=e.bottom;v<=b;++v)if(!c||!c.ad(d,v))if(h=this.jf(d,v,!1))h.remove(a),h.ve()&&(h.Cb.clear(),1E3>x.length&&x.push(h),this.cells[d][v]=null);if(c)for(d=
|
||||
c.left,g=c.right;d<=g;++d)for(v=c.top,b=c.bottom;v<=b;++v)e&&e.ad(d,v)||this.jf(d,v,!0).Sm(a)};d.prototype.rr=function(a,e){var c,d,g,v,b,h;c=this.pc(a.left);g=this.qc(a.top);d=this.pc(a.right);for(b=this.qc(a.bottom);c<=d;++c)for(v=g;v<=b;++v)(h=this.jf(c,v,!1))&&h.dump(e)};gb=d;h.prototype.jf=function(a,c,d){var g;g=this.cells[a];return g?(g=g[c])?g:d?(g=e(this,a,c),this.cells[a][c]=g):null:d?(g=e(this,a,c),this.cells[a]={},this.cells[a][c]=g):null};h.prototype.pc=function(a){return ta(a/this.hm)};
|
||||
h.prototype.qc=function(a){return ta(a/this.gm)};h.prototype.update=function(a,e,c){var d,g,v,b,h;if(e)for(d=e.left,g=e.right;d<=g;++d)for(v=e.top,b=e.bottom;v<=b;++v)if(!c||!c.ad(d,v))if(h=this.jf(d,v,!1))h.remove(a),h.ve()&&(h.reset(),1E3>y.length&&y.push(h),this.cells[d][v]=null);if(c)for(d=c.left,g=c.right;d<=g;++d)for(v=c.top,b=c.bottom;v<=b;++v)e&&e.ad(d,v)||this.jf(d,v,!0).Sm(a)};h.prototype.rr=function(a,e,c,d,g){var v,b;a=this.pc(a);e=this.qc(e);c=this.pc(c);for(v=this.qc(d);a<=c;++a)for(d=
|
||||
e;d<=v;++d)(b=this.jf(a,d,!1))&&b.dump(g)};h.prototype.Kw=function(a){var e,c,d,g,v;e=a.left;d=a.top;c=a.right;for(g=a.bottom;e<=c;++e)for(a=d;a<=g;++a)if(v=this.jf(e,a,!1))v.Sg=!1};hb=h;var x=[];a.prototype.ve=function(){return this.Cb.ve()};a.prototype.Sm=function(a){this.Cb.add(a)};a.prototype.remove=function(a){this.Cb.remove(a)};a.prototype.dump=function(a){Ea(a,this.Cb.Bf())};ca=a;var y=[];l.prototype.ve=function(){if(!this.Cb.length)return!0;if(this.Cb.length>this.Xd.count())return!1;this.ym();
|
||||
return!0};l.prototype.Sm=function(a){this.Xd.contains(a)?(this.Xd.remove(a),this.Xd.ve()&&(this.Dh=!1)):this.Cb.length?(this.Cb[this.Cb.length-1].Rd()>a.Rd()&&(this.Sg=!1),this.Cb.push(a)):(this.Cb.push(a),this.Sg=!0)};l.prototype.remove=function(a){this.Xd.add(a);this.Dh=!0;30<=this.Xd.count()&&this.ym()};l.prototype.ym=function(){this.Dh&&(this.Xd.count()===this.Cb.length?this.reset():(ab(this.Cb,this.Xd),this.Xd.clear(),this.Dh=!1))};l.prototype.Vu=function(){this.Sg||(this.Cb.sort(g),this.Sg=
|
||||
!0)};l.prototype.reset=function(){N(this.Cb);this.Sg=!0;this.Xd.clear();this.Dh=!1};l.prototype.dump=function(a){this.ym();this.Vu();this.Cb.length&&a.push(this.Cb)};ea=l;var F="lighter xor copy destination-over source-in destination-in source-out destination-out source-atop destination-atop".split(" ");ib=function(a){return 0>=a||11<=a?"source-over":F[a-1]};jb=function(a,e,c){if(c)switch(a.fc=c.ONE,a.$b=c.ONE_MINUS_SRC_ALPHA,e){case 1:a.fc=c.ONE;a.$b=c.ONE;break;case 3:a.fc=c.ONE;a.$b=c.ZERO;break;
|
||||
case 4:a.fc=c.ONE_MINUS_DST_ALPHA;a.$b=c.ONE;break;case 5:a.fc=c.DST_ALPHA;a.$b=c.ZERO;break;case 6:a.fc=c.ZERO;a.$b=c.SRC_ALPHA;break;case 7:a.fc=c.ONE_MINUS_DST_ALPHA;a.$b=c.ZERO;break;case 8:a.fc=c.ZERO;a.$b=c.ONE_MINUS_SRC_ALPHA;break;case 9:a.fc=c.DST_ALPHA;a.$b=c.ONE_MINUS_SRC_ALPHA;break;case 10:a.fc=c.ONE_MINUS_DST_ALPHA,a.$b=c.SRC_ALPHA}};kb=function(a){return Math.round(1E6*a)/1E6};nb=function(a,e){return"string"!==typeof a||"string"!==typeof e||a.length!==e.length?!1:a===e?!0:a.toLowerCase()===
|
||||
e.toLowerCase()};ob=function(a){a=a.target;return!a||a===document||a===window||document&&document.body&&a===document.body||nb(a.tagName,"canvas")?!0:!1}})();var lc="undefined"!==typeof Float32Array?Float32Array:Array;function mc(f){var q=new lc(3);f&&(q[0]=f[0],q[1]=f[1],q[2]=f[2]);return q}
|
||||
function nc(f){var q=new lc(16);f&&(q[0]=f[0],q[1]=f[1],q[2]=f[2],q[3]=f[3],q[4]=f[4],q[5]=f[5],q[6]=f[6],q[7]=f[7],q[8]=f[8],q[9]=f[9],q[10]=f[10],q[11]=f[11],q[12]=f[12],q[13]=f[13],q[14]=f[14],q[15]=f[15]);return q}function oc(f,q){q[0]=f[0];q[1]=f[1];q[2]=f[2];q[3]=f[3];q[4]=f[4];q[5]=f[5];q[6]=f[6];q[7]=f[7];q[8]=f[8];q[9]=f[9];q[10]=f[10];q[11]=f[11];q[12]=f[12];q[13]=f[13];q[14]=f[14];q[15]=f[15]}
|
||||
function pc(f,q){var r=q[0],t=q[1];q=q[2];f[0]*=r;f[1]*=r;f[2]*=r;f[3]*=r;f[4]*=t;f[5]*=t;f[6]*=t;f[7]*=t;f[8]*=q;f[9]*=q;f[10]*=q;f[11]*=q}
|
||||
function qc(f,q,r,t){t||(t=nc());var b,p,k,d,h,c,a,e,l=f[0],g=f[1];f=f[2];p=r[0];k=r[1];b=r[2];r=q[1];c=q[2];l===q[0]&&g===r&&f===c?(f=t,f[0]=1,f[1]=0,f[2]=0,f[3]=0,f[4]=0,f[5]=1,f[6]=0,f[7]=0,f[8]=0,f[9]=0,f[10]=1,f[11]=0,f[12]=0,f[13]=0,f[14]=0,f[15]=1):(r=l-q[0],c=g-q[1],a=f-q[2],e=1/Math.sqrt(r*r+c*c+a*a),r*=e,c*=e,a*=e,q=k*a-b*c,b=b*r-p*a,p=p*c-k*r,(e=Math.sqrt(q*q+b*b+p*p))?(e=1/e,q*=e,b*=e,p*=e):p=b=q=0,k=c*p-a*b,d=a*q-r*p,h=r*b-c*q,(e=Math.sqrt(k*k+d*d+h*h))?(e=1/e,k*=e,d*=e,h*=e):h=d=k=0,
|
||||
t[0]=q,t[1]=k,t[2]=r,t[3]=0,t[4]=b,t[5]=d,t[6]=c,t[7]=0,t[8]=p,t[9]=h,t[10]=a,t[11]=0,t[12]=-(q*l+b*g+p*f),t[13]=-(k*l+d*g+h*f),t[14]=-(r*l+c*g+a*f),t[15]=1)}
|
||||
(function(){function f(d,b,c){this.we=/msie/i.test(navigator.userAgent)||/trident/i.test(navigator.userAgent);this.height=this.width=0;this.Pa=!!c;this.ik=this.fi=!1;this.pm=0;this.Il=1;this.yo=1E3;this.ey=(this.yo-this.Il)/32768;this.em=mc([0,0,100]);this.qq=mc([0,0,0]);this.gs=mc([0,1,0]);this.lj=mc([1,1,1]);this.vp=!0;this.Dk=nc();this.Sc=nc();this.gn=nc();this.om=nc();this.G=d;this.version=0===this.G.getParameter(this.G.VERSION).indexOf("WebGL 2")?2:1;this.Qp()}function q(d,b,c){this.G=d;this.Zi=
|
||||
b;this.name=c;this.fd=d.getAttribLocation(b,"aPos");this.tf=d.getAttribLocation(b,"aTex");this.oq=d.getUniformLocation(b,"matP");this.yk=d.getUniformLocation(b,"matMV");this.Zg=d.getUniformLocation(b,"opacity");this.mn=d.getUniformLocation(b,"colorFill");this.pq=d.getUniformLocation(b,"samplerFront");this.yi=d.getUniformLocation(b,"samplerBack");this.eg=d.getUniformLocation(b,"destStart");this.dg=d.getUniformLocation(b,"destEnd");this.Bi=d.getUniformLocation(b,"seconds");this.pn=d.getUniformLocation(b,
|
||||
"pixelWidth");this.nn=d.getUniformLocation(b,"pixelHeight");this.xi=d.getUniformLocation(b,"layerScale");this.wi=d.getUniformLocation(b,"layerAngle");this.Ci=d.getUniformLocation(b,"viewOrigin");this.Ai=d.getUniformLocation(b,"scrollPos");this.mw=!!(this.pn||this.nn||this.Bi||this.yi||this.eg||this.dg||this.xi||this.wi||this.Ci||this.Ai);this.yq=this.zq=-999;this.Ck=1;this.uq=this.tq=0;this.wq=this.sq=this.rq=1;this.Cq=this.Bq=this.Aq=this.Eq=this.Dq=this.vq=0;this.dn=[];this.xq=nc();this.Zg&&d.uniform1f(this.Zg,
|
||||
1);this.mn&&d.uniform4f(this.mn,1,1,1,1);this.pq&&d.uniform1i(this.pq,0);this.yi&&d.uniform1i(this.yi,1);this.eg&&d.uniform2f(this.eg,0,0);this.dg&&d.uniform2f(this.dg,1,1);this.xi&&d.uniform1f(this.xi,1);this.wi&&d.uniform1f(this.wi,0);this.Ci&&d.uniform2f(this.Ci,0,0);this.Ai&&d.uniform2f(this.Ai,0,0);this.Bi&&d.uniform1f(this.Bi,0);this.Rf=!1}function r(d,b){return d[0]===b[0]&&d[1]===b[1]&&d[2]===b[2]&&d[3]===b[3]&&d[4]===b[4]&&d[5]===b[5]&&d[6]===b[6]&&d[7]===b[7]&&d[8]===b[8]&&d[9]===b[9]&&
|
||||
d[10]===b[10]&&d[11]===b[11]&&d[12]===b[12]&&d[13]===b[13]&&d[14]===b[14]&&d[15]===b[15]}function t(d,b){this.type=d;this.C=b;this.G=b.G;this.Sd=this.nc=this.cr=0;this.ca=this.od=null;this.Lr=[]}var b=nc();f.prototype.Qp=function(){var d=this.G,b;this.fq=1;this.Yf=this.qf=null;this.Hj=1;d.clearColor(0,0,0,0);d.clear(d.COLOR_BUFFER_BIT);d.enable(d.BLEND);d.blendFunc(d.ONE,d.ONE_MINUS_SRC_ALPHA);d.disable(d.CULL_FACE);d.disable(d.STENCIL_TEST);d.disable(d.DITHER);this.Pa?(d.enable(d.DEPTH_TEST),d.depthFunc(d.LEQUAL)):
|
||||
d.disable(d.DEPTH_TEST);this.hq=d.ONE;this.cq=d.ONE_MINUS_SRC_ALPHA;this.Cl=new Float32Array(8E3*(this.Pa?3:2));this.ql=new Float32Array(16E3);this.mr=new Float32Array(32E3);this.In=d.createBuffer();d.bindBuffer(d.ARRAY_BUFFER,this.In);d.bufferData(d.ARRAY_BUFFER,this.mr.byteLength,d.DYNAMIC_DRAW);this.jj=Array(4);this.dj=Array(4);for(b=0;4>b;b++)this.jj[b]=d.createBuffer(),d.bindBuffer(d.ARRAY_BUFFER,this.jj[b]),d.bufferData(d.ARRAY_BUFFER,this.Cl.byteLength,d.DYNAMIC_DRAW),this.dj[b]=d.createBuffer(),
|
||||
d.bindBuffer(d.ARRAY_BUFFER,this.dj[b]),d.bufferData(d.ARRAY_BUFFER,this.ql.byteLength,d.DYNAMIC_DRAW);this.ne=0;this.qw=d.createBuffer();d.bindBuffer(d.ELEMENT_ARRAY_BUFFER,this.qw);for(var c=new Uint16Array(12E3),a=b=0;12E3>b;)c[b++]=a,c[b++]=a+1,c[b++]=a+2,c[b++]=a,c[b++]=a+2,c[b++]=a+3,a+=4;d.bufferData(d.ELEMENT_ARRAY_BUFFER,c,d.STATIC_DRAW);this.Jn=this.uh=this.Ne=0;this.bb=[];b=this.Pa?"attribute highp vec3 aPos;\nattribute mediump vec2 aTex;\nvarying mediump vec2 vTex;\nuniform highp mat4 matP;\nuniform highp mat4 matMV;\nvoid main(void) {\n\tgl_Position = matP * matMV * vec4(aPos.x, aPos.y, aPos.z, 1.0);\n\tvTex = aTex;\n}":
|
||||
"attribute highp vec2 aPos;\nattribute mediump vec2 aTex;\nvarying mediump vec2 vTex;\nuniform highp mat4 matP;\nuniform highp mat4 matMV;\nvoid main(void) {\n\tgl_Position = matP * matMV * vec4(aPos.x, aPos.y, 0.0, 1.0);\n\tvTex = aTex;\n}";c=this.Lh({src:"varying mediump vec2 vTex;\nuniform lowp float opacity;\nuniform lowp sampler2D samplerFront;\nvoid main(void) {\n\tgl_FragColor = texture2D(samplerFront, vTex);\n\tgl_FragColor *= opacity;\n}"},b,"<default>");this.bb.push(c);c=this.Lh({src:"uniform mediump sampler2D samplerFront;\nvarying lowp float opacity;\nvoid main(void) {\n\tgl_FragColor = texture2D(samplerFront, gl_PointCoord);\n\tgl_FragColor *= opacity;\n}"},
|
||||
"attribute vec4 aPos;\nvarying float opacity;\nuniform mat4 matP;\nuniform mat4 matMV;\nvoid main(void) {\n\tgl_Position = matP * matMV * vec4(aPos.x, aPos.y, 0.0, 1.0);\n\tgl_PointSize = aPos.z;\n\topacity = aPos.w;\n}","<point>");this.bb.push(c);c=this.Lh({src:"varying mediump vec2 vTex;\nuniform lowp sampler2D samplerFront;\nvoid main(void) {\n\tif (texture2D(samplerFront, vTex).a < 1.0)\n\t\tdiscard;\n}"},b,"<earlyz>");this.bb.push(c);c=this.Lh({src:"uniform lowp vec4 colorFill;\nvoid main(void) {\n\tgl_FragColor = colorFill;\n}"},
|
||||
b,"<fill>");this.bb.push(c);for(var e in rc)rc.hasOwnProperty(e)&&this.bb.push(this.Lh(rc[e],b,e));d.activeTexture(d.TEXTURE0);d.bindTexture(d.TEXTURE_2D,null);this.We=[];this.me=0;this.ac=!1;this.sp=this.ri=-1;this.Gg=null;this.wm=d.createFramebuffer();this.Mj=this.$k=null;this.dp=!1;this.Pa&&(this.Mj=d.createRenderbuffer());this.yf=mc([0,0,0]);this.Fq=d.getParameter(d.ALIASED_POINT_SIZE_RANGE)[1];2048<this.Fq&&(this.Fq=2048);this.zc(0)};q.prototype.so=function(d){r(this.xq,d)||(oc(d,this.xq),this.G.uniformMatrix4fv(this.yk,
|
||||
!1,d))};f.prototype.Lh=function(d,b,c){var a=this.G,e=a.createShader(a.FRAGMENT_SHADER);a.shaderSource(e,d.src);a.compileShader(e);if(!a.getShaderParameter(e,a.COMPILE_STATUS))throw d=a.getShaderInfoLog(e),a.deleteShader(e),Error("error compiling fragment shader: "+d);var l=a.createShader(a.VERTEX_SHADER);a.shaderSource(l,b);a.compileShader(l);if(!a.getShaderParameter(l,a.COMPILE_STATUS))throw d=a.getShaderInfoLog(l),a.deleteShader(e),a.deleteShader(l),Error("error compiling vertex shader: "+d);b=
|
||||
a.createProgram();a.attachShader(b,e);a.attachShader(b,l);a.linkProgram(b);if(!a.getProgramParameter(b,a.LINK_STATUS))throw d=a.getProgramInfoLog(b),a.deleteShader(e),a.deleteShader(l),a.deleteProgram(b),Error("error linking shader program: "+d);a.useProgram(b);a.deleteShader(e);a.deleteShader(l);e=new q(a,b,c);e.Qj=d.Qj||0;e.Rj=d.Rj||0;e.nm=!!d.nm;e.jd=!!d.jd;e.Xl=!!d.Xl;e.aa=d.aa||[];d=0;for(l=e.aa.length;d<l;d++)e.aa[d][1]=a.getUniformLocation(b,e.aa[d][0]),e.dn.push(0),a.uniform1f(e.aa[d][1],
|
||||
0);return e};f.prototype.Lm=function(d){var b,c;b=0;for(c=this.bb.length;b<c;b++)if(this.bb[b].name===d)return b;return-1};f.prototype.or=function(d,b,c){var a=this.Sc,e=this.Dk,l=[0,0,0,0,0,0,0,0];l[0]=a[0]*d+a[4]*b+a[12];l[1]=a[1]*d+a[5]*b+a[13];l[2]=a[2]*d+a[6]*b+a[14];l[3]=a[3]*d+a[7]*b+a[15];l[4]=e[0]*l[0]+e[4]*l[1]+e[8]*l[2]+e[12]*l[3];l[5]=e[1]*l[0]+e[5]*l[1]+e[9]*l[2]+e[13]*l[3];l[6]=e[2]*l[0]+e[6]*l[1]+e[10]*l[2]+e[14]*l[3];l[7]=-l[2];0!==l[7]&&(l[7]=1/l[7],l[4]*=l[7],l[5]*=l[7],l[6]*=l[7],
|
||||
c[0]=(.5*l[4]+.5)*this.width,c[1]=(.5*l[5]+.5)*this.height)};f.prototype.qg=function(d,b,c){if(this.width!==d||this.height!==b||c){this.gf();c=this.G;this.width=d;this.height=b;c.viewport(0,0,d,b);qc(this.em,this.qq,this.gs,this.Sc);if(this.Pa){var a=-d/2;d=d/2;var e=b/2;b=-b/2;var l=this.Il,g=this.yo,n=this.Dk;n||(n=nc());var k=d-a,w=b-e,m=g-l;n[0]=2/k;n[1]=0;n[2]=0;n[3]=0;n[4]=0;n[5]=2/w;n[6]=0;n[7]=0;n[8]=0;n[9]=0;n[10]=-2/m;n[11]=0;n[12]=-(a+d)/k;n[13]=-(b+e)/w;n[14]=-(g+l)/m;n[15]=1;this.lj[0]=
|
||||
1;this.lj[1]=1}else b=d/b,a=this.Il,d=this.yo,n=this.Dk,g=a*Math.tan(45*Math.PI/360),b*=g,e=-b,l=-g,n||(n=nc()),k=b-e,w=g-l,m=d-a,n[0]=2*a/k,n[1]=0,n[2]=0,n[3]=0,n[4]=0,n[5]=2*a/w,n[6]=0,n[7]=0,n[8]=(b+e)/k,n[9]=(g+l)/w,n[10]=-(d+a)/m,n[11]=-1,n[12]=0,n[13]=0,n[14]=-(d*a*2)/m,n[15]=0,a=[0,0],d=[0,0],this.or(0,0,a),this.or(1,1,d),this.lj[0]=1/(d[0]-a[0]),this.lj[1]=-1/(d[1]-a[1]);a=0;for(d=this.bb.length;a<d;a++)e=this.bb[a],e.Rf=!1,e.oq&&(c.useProgram(e.Zi),c.uniformMatrix4fv(e.oq,!1,this.Dk));c.useProgram(this.bb[this.ri].Zi);
|
||||
c.bindTexture(c.TEXTURE_2D,null);c.activeTexture(c.TEXTURE1);c.bindTexture(c.TEXTURE_2D,null);c.activeTexture(c.TEXTURE0);this.Yf=this.qf=null;this.Mj&&(c.bindFramebuffer(c.FRAMEBUFFER,this.wm),c.bindRenderbuffer(c.RENDERBUFFER,this.Mj),c.renderbufferStorage(c.RENDERBUFFER,c.DEPTH_COMPONENT16,this.width,this.height),this.dp||(c.framebufferRenderbuffer(c.FRAMEBUFFER,c.DEPTH_ATTACHMENT,c.RENDERBUFFER,this.Mj),this.dp=!0),c.bindRenderbuffer(c.RENDERBUFFER,null),c.bindFramebuffer(c.FRAMEBUFFER,null),
|
||||
this.$k=null)}};f.prototype.kd=function(){qc(this.em,this.qq,this.gs,this.Sc);pc(this.Sc,this.lj)};f.prototype.translate=function(d,b){if(0!==d||0!==b){this.yf[0]=d;this.yf[1]=b;this.yf[2]=0;var c=this.Sc,a=this.yf,e=a[0],l=a[1],a=a[2];c[12]=c[0]*e+c[4]*l+c[8]*a+c[12];c[13]=c[1]*e+c[5]*l+c[9]*a+c[13];c[14]=c[2]*e+c[6]*l+c[10]*a+c[14];c[15]=c[3]*e+c[7]*l+c[11]*a+c[15]}};f.prototype.scale=function(d,b){if(1!==d||1!==b)this.yf[0]=d,this.yf[1]=b,this.yf[2]=1,pc(this.Sc,this.yf)};f.prototype.cl=function(d){if(0!==
|
||||
d){var b=this.Sc,c,a=Math.sin(d);d=Math.cos(d);var e=b[0],l=b[1],g=b[2],n=b[3],k=b[4],w=b[5],m=b[6],u=b[7];c?b!==c&&(c[8]=b[8],c[9]=b[9],c[10]=b[10],c[11]=b[11],c[12]=b[12],c[13]=b[13],c[14]=b[14],c[15]=b[15]):c=b;c[0]=e*d+k*a;c[1]=l*d+w*a;c[2]=g*d+m*a;c[3]=n*d+u*a;c[4]=e*-a+k*d;c[5]=l*-a+w*d;c[6]=g*-a+m*d;c[7]=n*-a+u*d}};f.prototype.Xc=function(){if(!r(this.gn,this.Sc)){var d=this.Jc();d.type=5;d.ca?oc(this.Sc,d.ca):d.ca=nc(this.Sc);oc(this.Sc,this.gn);this.ac=!1}};f.prototype.hl=function(d){this.Pa&&
|
||||
(32760<d&&(d=32760),this.pm=this.em[2]-this.Il-d*this.ey)};t.prototype.Du=function(){var d=this.G,b=this.C;0!==this.nc?(d.depthMask(!0),d.colorMask(!1,!1,!1,!1),d.disable(d.BLEND),d.bindFramebuffer(d.FRAMEBUFFER,b.wm),d.framebufferTexture2D(d.FRAMEBUFFER,d.COLOR_ATTACHMENT0,d.TEXTURE_2D,null,0),d.clear(d.DEPTH_BUFFER_BIT),d.bindFramebuffer(d.FRAMEBUFFER,null),b.ik=!0):(d.depthMask(!1),d.colorMask(!0,!0,!0,!0),d.enable(d.BLEND),b.ik=!1)};t.prototype.Hu=function(){this.G.bindTexture(this.G.TEXTURE_2D,
|
||||
this.od)};t.prototype.Iu=function(){var d=this.G;d.activeTexture(d.TEXTURE1);d.bindTexture(d.TEXTURE_2D,this.od);d.activeTexture(d.TEXTURE0)};t.prototype.Eu=function(){var d=this.cr,b=this.C;b.Hj=d;b=b.Gg;b.Zg&&b.Ck!==d&&(b.Ck=d,this.G.uniform1f(b.Zg,d))};t.prototype.yu=function(){this.G.drawElements(this.G.TRIANGLES,this.Sd,this.G.UNSIGNED_SHORT,this.nc)};t.prototype.Au=function(){this.G.blendFunc(this.nc,this.Sd)};t.prototype.Ku=function(){var d,b,c,a=this.C.bb,e=this.C.sp;d=0;for(b=a.length;d<
|
||||
b;d++)c=a[d],d===e&&c.yk?(c.so(this.ca),c.Rf=!0):c.Rf=!1;oc(this.ca,this.C.om)};t.prototype.zu=function(){var d=this.G,b=this.C;this.od?(b.Yf===this.od&&(d.activeTexture(d.TEXTURE1),d.bindTexture(d.TEXTURE_2D,null),b.Yf=null,d.activeTexture(d.TEXTURE0)),d.bindFramebuffer(d.FRAMEBUFFER,b.wm),b.ik||d.framebufferTexture2D(d.FRAMEBUFFER,d.COLOR_ATTACHMENT0,d.TEXTURE_2D,this.od,0)):(b.Pa||d.framebufferTexture2D(d.FRAMEBUFFER,d.COLOR_ATTACHMENT0,d.TEXTURE_2D,null,0),d.bindFramebuffer(d.FRAMEBUFFER,null))};
|
||||
t.prototype.uu=function(){var d=this.G,b=this.nc;0===b?(d.clearColor(this.ca[0],this.ca[1],this.ca[2],this.ca[3]),d.clear(d.COLOR_BUFFER_BIT)):1===b?(d.enable(d.SCISSOR_TEST),d.scissor(this.ca[0],this.ca[1],this.ca[2],this.ca[3]),d.clearColor(0,0,0,0),d.clear(d.COLOR_BUFFER_BIT),d.disable(d.SCISSOR_TEST)):d.clear(d.DEPTH_BUFFER_BIT)};t.prototype.Cu=function(){var d=this.G;0!==this.nc?d.enable(d.DEPTH_TEST):d.disable(d.DEPTH_TEST)};t.prototype.xu=function(){var d=this.G,b=this.C;b.Pa&&d.disable(d.DEPTH_TEST);
|
||||
var c=b.bb[1];d.useProgram(c.Zi);!c.Rf&&c.yk&&(c.so(b.om),c.Rf=!0);d.enableVertexAttribArray(c.fd);d.bindBuffer(d.ARRAY_BUFFER,b.In);d.vertexAttribPointer(c.fd,4,d.FLOAT,!1,0,0);d.drawArrays(d.POINTS,this.nc/4,this.Sd);c=b.Gg;d.useProgram(c.Zi);0<=c.fd&&(d.enableVertexAttribArray(c.fd),d.bindBuffer(d.ARRAY_BUFFER,b.jj[b.ne]),d.vertexAttribPointer(c.fd,b.Pa?3:2,d.FLOAT,!1,0,0));0<=c.tf&&(d.enableVertexAttribArray(c.tf),d.bindBuffer(d.ARRAY_BUFFER,b.dj[b.ne]),d.vertexAttribPointer(c.tf,2,d.FLOAT,!1,
|
||||
0,0));b.Pa&&d.enable(d.DEPTH_TEST)};t.prototype.Fu=function(){var d=this.G,b=this.C,c=b.bb[this.nc];b.sp=this.nc;b.Gg=c;d.useProgram(c.Zi);!c.Rf&&c.yk&&(c.so(b.om),c.Rf=!0);c.Zg&&c.Ck!==b.Hj&&(c.Ck=b.Hj,d.uniform1f(c.Zg,b.Hj));0<=c.fd&&(d.enableVertexAttribArray(c.fd),d.bindBuffer(d.ARRAY_BUFFER,b.jj[b.ne]),d.vertexAttribPointer(c.fd,b.Pa?3:2,d.FLOAT,!1,0,0));0<=c.tf&&(d.enableVertexAttribArray(c.tf),d.bindBuffer(d.ARRAY_BUFFER,b.dj[b.ne]),d.vertexAttribPointer(c.tf,2,d.FLOAT,!1,0,0))};t.prototype.Bu=
|
||||
function(){var d=this.ca;this.G.uniform4f(this.C.Gg.mn,d[0],d[1],d[2],d[3])};t.prototype.Gu=function(){var d,b,c=this.C.Gg,a=this.G;d=this.ca;c.yi&&this.C.Yf!==this.od&&(a.activeTexture(a.TEXTURE1),a.bindTexture(a.TEXTURE_2D,this.od),this.C.Yf=this.od,a.activeTexture(a.TEXTURE0));var e=d[0];c.pn&&e!==c.zq&&(c.zq=e,a.uniform1f(c.pn,e));e=d[1];c.nn&&e!==c.yq&&(c.yq=e,a.uniform1f(c.nn,e));e=d[2];b=d[3];!c.eg||e===c.tq&&b===c.uq||(c.tq=e,c.uq=b,a.uniform2f(c.eg,e,b));e=d[4];b=d[5];!c.dg||e===c.rq&&b===
|
||||
c.sq||(c.rq=e,c.sq=b,a.uniform2f(c.dg,e,b));e=d[6];c.xi&&e!==c.wq&&(c.wq=e,a.uniform1f(c.xi,e));e=d[7];c.wi&&e!==c.vq&&(c.vq=e,a.uniform1f(c.wi,e));e=d[8];b=d[9];!c.Ci||e===c.Dq&&b===c.Eq||(c.Dq=e,c.Eq=b,a.uniform2f(c.Ci,e,b));e=d[10];b=d[11];!c.Ai||e===c.Aq&&b===c.Bq||(c.Aq=e,c.Bq=b,a.uniform2f(c.Ai,e,b));e=d[12];c.Bi&&e!==c.Cq&&(c.Cq=e,a.uniform1f(c.Bi,e));if(c.aa.length)for(d=0,b=c.aa.length;d<b;d++)e=this.Lr[d],e!==c.dn[d]&&(c.dn[d]=e,a.uniform1f(c.aa[d][1],e))};f.prototype.Jc=function(){this.me===
|
||||
this.We.length&&this.We.push(new t(0,this));return this.We[this.me++]};f.prototype.gf=function(){if(0!==this.me&&!this.G.isContextLost()){var d=this.G;0<this.Jn&&(d.bindBuffer(d.ARRAY_BUFFER,this.In),d.bufferSubData(d.ARRAY_BUFFER,0,this.mr.subarray(0,this.Jn)),b&&0<=b.fd&&"<point>"===b.name&&d.vertexAttribPointer(b.fd,4,d.FLOAT,!1,0,0));if(0<this.Ne){var b=this.Gg;d.bindBuffer(d.ARRAY_BUFFER,this.jj[this.ne]);d.bufferSubData(d.ARRAY_BUFFER,0,this.Cl.subarray(0,this.Ne));b&&0<=b.fd&&"<point>"!==b.name&&
|
||||
d.vertexAttribPointer(b.fd,this.Pa?3:2,d.FLOAT,!1,0,0);d.bindBuffer(d.ARRAY_BUFFER,this.dj[this.ne]);d.bufferSubData(d.ARRAY_BUFFER,0,this.ql.subarray(0,this.uh));b&&0<=b.tf&&"<point>"!==b.name&&d.vertexAttribPointer(b.tf,2,d.FLOAT,!1,0,0)}for(var c,d=0,b=this.me;d<b;d++)switch(c=this.We[d],c.type){case 1:c.yu();break;case 2:c.Hu();break;case 3:c.Eu();break;case 4:c.Au();break;case 5:c.Ku();break;case 6:c.zu();break;case 7:c.uu();break;case 8:c.xu();break;case 9:c.Fu();break;case 10:c.Gu();break;
|
||||
case 11:c.Iu();break;case 12:c.Bu();break;case 13:c.Cu();break;case 14:c.Du()}this.Jn=this.uh=this.Ne=this.me=0;this.ik=this.ac=!1;this.ne++;4<=this.ne&&(this.ne=0)}};f.prototype.pg=function(d){if(d!==this.fq&&!this.fi){var b=this.Jc();b.type=3;this.fq=b.cr=d;this.ac=!1}};f.prototype.Kc=function(d){if(d!==this.qf){var b=this.Jc();b.type=2;this.qf=b.od=d;this.ac=!1}};f.prototype.wf=function(d,b){if((d!==this.hq||b!==this.cq)&&!this.fi){var c=this.Jc();c.type=4;c.nc=d;c.Sd=b;this.hq=d;this.cq=b;this.ac=
|
||||
!1}};f.prototype.Dr=function(){this.wf(this.G.ONE,this.G.ONE_MINUS_SRC_ALPHA)};f.prototype.Ti=function(d,b,c,a,e,l,g,n){15992<=this.Ne&&this.gf();var k=this.Ne,w=this.uh,m=this.Cl,u=this.ql,f=this.pm;if(this.ac)this.We[this.me-1].Sd+=6;else{var q=this.Jc();q.type=1;q.nc=this.Pa?k:k/2*3;q.Sd=6;this.ac=!0}this.Pa?(m[k++]=d,m[k++]=b,m[k++]=f,m[k++]=c,m[k++]=a,m[k++]=f,m[k++]=e,m[k++]=l,m[k++]=f,m[k++]=g,m[k++]=n,m[k++]=f):(m[k++]=d,m[k++]=b,m[k++]=c,m[k++]=a,m[k++]=e,m[k++]=l,m[k++]=g,m[k++]=n);u[w++]=
|
||||
0;u[w++]=0;u[w++]=1;u[w++]=0;u[w++]=1;u[w++]=1;u[w++]=0;u[w++]=1;this.Ne=k;this.uh=w};f.prototype.Fe=function(d,b,c,a,e,l,g,n,k){15992<=this.Ne&&this.gf();var w=this.Ne,m=this.uh,u=this.Cl,f=this.ql,q=this.pm;if(this.ac)this.We[this.me-1].Sd+=6;else{var p=this.Jc();p.type=1;p.nc=this.Pa?w:w/2*3;p.Sd=6;this.ac=!0}var p=k.left,t=k.top,r=k.right;k=k.bottom;this.Pa?(u[w++]=d,u[w++]=b,u[w++]=q,u[w++]=c,u[w++]=a,u[w++]=q,u[w++]=e,u[w++]=l,u[w++]=q,u[w++]=g,u[w++]=n,u[w++]=q):(u[w++]=d,u[w++]=b,u[w++]=c,
|
||||
u[w++]=a,u[w++]=e,u[w++]=l,u[w++]=g,u[w++]=n);f[m++]=p;f[m++]=t;f[m++]=r;f[m++]=t;f[m++]=r;f[m++]=k;f[m++]=p;f[m++]=k;this.Ne=w;this.uh=m};f.prototype.zc=function(d){if(this.ri!==d){if(!this.bb[d]){if(0===this.ri)return;d=0}var b=this.Jc();b.type=9;this.ri=b.nc=d;this.ac=!1}};f.prototype.Qi=function(d){d=this.bb[d];return!(!d.eg&&!d.dg)};f.prototype.Mn=function(d){d=this.bb[d];return!!(d.eg||d.dg||d.nm)};f.prototype.Ln=function(d){return this.bb[d].jd};f.prototype.lx=function(d){d=this.bb[d];return 0!==
|
||||
d.Qj||0!==d.Rj};f.prototype.Tv=function(d){return this.bb[d].Qj};f.prototype.Uv=function(d){return this.bb[d].Rj};f.prototype.Vv=function(d,b){return this.bb[d].aa[b][2]};f.prototype.Vk=function(d){return this.bb[d].Xl};f.prototype.rh=function(d,b,c,a,e,l,g,n,k,w,m,u,f,q,p){var t=this.bb[this.ri],r,y;if(t.mw||p.length){r=this.Jc();r.type=10;r.ca?oc(this.Sc,r.ca):r.ca=nc();y=r.ca;y[0]=b;y[1]=c;y[2]=a;y[3]=e;y[4]=l;y[5]=g;y[6]=n;y[7]=k;y[8]=w;y[9]=m;y[10]=u;y[11]=f;y[12]=q;t.yi?r.od=d:r.od=null;if(p.length)for(c=
|
||||
r.Lr,c.length=p.length,d=0,b=p.length;d<b;d++)c[d]=p[d];this.ac=!1}};f.prototype.clear=function(d,b,c,a){var e=this.Jc();e.type=7;e.nc=0;e.ca||(e.ca=nc());e.ca[0]=d;e.ca[1]=b;e.ca[2]=c;e.ca[3]=a;this.ac=!1};f.prototype.clearRect=function(d,b,c,a){if(!(0>c||0>a)){var e=this.Jc();e.type=7;e.nc=1;e.ca||(e.ca=nc());e.ca[0]=d;e.ca[1]=b;e.ca[2]=c;e.ca[3]=a;this.ac=!1}};f.prototype.Gr=function(d){if(this.Pa&&(d=!!d,this.fi!==d)){var b=this.Jc();b.type=14;b.nc=d?1:0;this.ac=!1;this.fi=d;this.$k=null;this.fi?
|
||||
this.zc(2):this.zc(0)}};f.prototype.Fr=function(d){if(this.Pa){var b=this.Jc();b.type=13;b.nc=d?1:0;this.ac=!1}};f.prototype.Dp=function(){oc(this.gn,b);this.kd();this.Xc();var d=this.width/2,k=this.height/2;this.Ti(-d,k,d,k,d,-k,-d,-k);oc(b,this.Sc);this.Xc()};f.prototype.Er=function(d,b,c){this.zc(3);var a=this.Jc();a.type=12;a.ca||(a.ca=nc());a.ca[0]=d;a.ca[1]=b;a.ca[2]=c;a.ca[3]=1;this.ac=!1};f.prototype.Kx=function(){this.zc(0)};f.prototype.wx=function(){this.zc(2)};f.prototype.kx=function(){this.gf();
|
||||
this.G.flush()};var p=[],k={};f.prototype.ku=function(){N(p);k={}};f.prototype.vi=function(d,b,c){var a;a=!1;b=!!b;var e=d.src+","+a+","+b+(a?",undefined":""),l=null;if("undefined"!==typeof d.src&&k.hasOwnProperty(e))return l=k[e],l.yj++,l;this.gf();var g=this.G,n=ma(d.width)&&ma(d.height),l=g.createTexture();g.bindTexture(g.TEXTURE_2D,l);g.pixelStorei(g.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!0);var f=g.RGBA,w=g.RGBA,m=g.UNSIGNED_BYTE;if(c&&!this.we)switch(c){case 1:w=f=g.RGB;break;case 2:m=g.UNSIGNED_SHORT_4_4_4_4;
|
||||
break;case 3:m=g.UNSIGNED_SHORT_5_5_5_1;break;case 4:w=f=g.RGB,m=g.UNSIGNED_SHORT_5_6_5}if(1===this.version&&!n&&a){c=document.createElement("canvas");c.width=na(d.width);c.height=na(d.height);var u=c.getContext("2d");"undefined"!==typeof u.imageSmoothingEnabled?u.imageSmoothingEnabled=b:(u.webkitImageSmoothingEnabled=b,u.mozImageSmoothingEnabled=b,u.msImageSmoothingEnabled=b);u.drawImage(d,0,0,d.width,d.height,0,0,c.width,c.height);g.texImage2D(g.TEXTURE_2D,0,f,w,m,c)}else g.texImage2D(g.TEXTURE_2D,
|
||||
0,f,w,m,d);a?(g.texParameteri(g.TEXTURE_2D,g.TEXTURE_WRAP_S,g.REPEAT),g.texParameteri(g.TEXTURE_2D,g.TEXTURE_WRAP_T,g.REPEAT)):(g.texParameteri(g.TEXTURE_2D,g.TEXTURE_WRAP_S,g.CLAMP_TO_EDGE),g.texParameteri(g.TEXTURE_2D,g.TEXTURE_WRAP_T,g.CLAMP_TO_EDGE));b?(g.texParameteri(g.TEXTURE_2D,g.TEXTURE_MAG_FILTER,g.LINEAR),(n||2<=this.version)&&this.vp?(g.texParameteri(g.TEXTURE_2D,g.TEXTURE_MIN_FILTER,g.LINEAR_MIPMAP_LINEAR),g.generateMipmap(g.TEXTURE_2D)):g.texParameteri(g.TEXTURE_2D,g.TEXTURE_MIN_FILTER,
|
||||
g.LINEAR)):(g.texParameteri(g.TEXTURE_2D,g.TEXTURE_MAG_FILTER,g.NEAREST),g.texParameteri(g.TEXTURE_2D,g.TEXTURE_MIN_FILTER,g.NEAREST));g.bindTexture(g.TEXTURE_2D,null);this.qf=null;l.Gf=d.width;l.Ff=d.height;l.yj=1;l.lp=e;p.push(l);return k[e]=l};f.prototype.Mc=function(b,k,c,a){this.gf();var e=this.G;this.we&&(a=!1);var l=e.createTexture();e.bindTexture(e.TEXTURE_2D,l);e.texImage2D(e.TEXTURE_2D,0,e.RGBA,b,k,0,e.RGBA,a?e.UNSIGNED_SHORT_4_4_4_4:e.UNSIGNED_BYTE,null);e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_S,
|
||||
e.CLAMP_TO_EDGE);e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_T,e.CLAMP_TO_EDGE);e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MAG_FILTER,c?e.LINEAR:e.NEAREST);e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,c?e.LINEAR:e.NEAREST);e.bindTexture(e.TEXTURE_2D,null);this.qf=null;l.Gf=b;l.Ff=k;p.push(l);return l};f.prototype.by=function(b,k,c){this.gf();var a=this.G;this.we&&(c=!1);a.bindTexture(a.TEXTURE_2D,k);a.pixelStorei(a.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!0);try{a.texImage2D(a.TEXTURE_2D,0,a.RGBA,a.RGBA,
|
||||
c?a.UNSIGNED_SHORT_4_4_4_4:a.UNSIGNED_BYTE,b)}catch(e){console&&console.error&&console.error("Error updating WebGL texture: ",e)}a.bindTexture(a.TEXTURE_2D,null);this.qf=null};f.prototype.deleteTexture=function(b){b&&("undefined"!==typeof b.yj&&1<b.yj?b.yj--:(this.gf(),b===this.qf&&(this.G.bindTexture(this.G.TEXTURE_2D,null),this.qf=null),b===this.Yf&&(this.G.activeTexture(this.G.TEXTURE1),this.G.bindTexture(this.G.TEXTURE_2D,null),this.G.activeTexture(this.G.TEXTURE0),this.Yf=null),Ga(p,b),"undefined"!==
|
||||
typeof b.lp&&delete k[b.lp],this.G.deleteTexture(b)))};f.prototype.ld=function(b){if(b!==this.$k){var k=this.Jc();k.type=6;this.$k=k.od=b;this.ac=!1}};pb=f})();
|
||||
(function(){function f(a){if(a&&(a.getContext||a.dc)&&!a.c2runtime){a.c2runtime=this;var e=this;this.Qc=(this.jk=/crosswalk/i.test(navigator.userAgent)||/xwalk/i.test(navigator.userAgent)||!("undefined"===typeof window.c2isCrosswalk||!window.c2isCrosswalk))||"undefined"!==typeof window.device&&("undefined"!==typeof window.device.cordova||"undefined"!==typeof window.device.phonegap)||"undefined"!==typeof window.c2iscordova&&window.c2iscordova;this.cc=!!a.dc;this.Vp="undefined"!==typeof window.AppMobi||
|
||||
this.cc;this.ed=!!window.c2cocoonjs;this.Bd=!!window.c2ejecta;this.ed&&(CocoonJS.App.onSuspended.addEventListener(function(){e.setSuspended(!0)}),CocoonJS.App.onActivated.addEventListener(function(){e.setSuspended(!1)}));this.Bd&&(document.addEventListener("pagehide",function(){e.setSuspended(!0)}),document.addEventListener("pageshow",function(){e.setSuspended(!1)}),document.addEventListener("resize",function(){e.setSize(window.innerWidth,window.innerHeight)}));this.Ca=this.cc||this.ed||this.Bd;this.hi=
|
||||
/edge\//i.test(navigator.userAgent);this.we=(/msie/i.test(navigator.userAgent)||/trident/i.test(navigator.userAgent)||/iemobile/i.test(navigator.userAgent))&&!this.hi;this.Xp=/tizen/i.test(navigator.userAgent);this.ei=/android/i.test(navigator.userAgent)&&!this.Xp&&!this.we&&!this.hi;this.aq=(/iphone/i.test(navigator.userAgent)||/ipod/i.test(navigator.userAgent))&&!this.we&&!this.hi;this.Fw=/ipad/i.test(navigator.userAgent);this.Ug=this.aq||this.Fw||this.Bd;this.Vm=(/chrome/i.test(navigator.userAgent)||
|
||||
/chromium/i.test(navigator.userAgent))&&!this.we&&!this.hi;this.Up=/amazonwebappplatform/i.test(navigator.userAgent);this.vw=/firefox/i.test(navigator.userAgent);this.zw=/safari/i.test(navigator.userAgent)&&!this.Vm&&!this.we&&!this.hi;this.Aw=/windows/i.test(navigator.userAgent);this.Ym="undefined"!==typeof window.c2nodewebkit||"undefined"!==typeof window.c2nwjs||/nodewebkit/i.test(navigator.userAgent)||/nwjs/i.test(navigator.userAgent);this.Zp=!("undefined"===typeof window.c2isWindows8||!window.c2isWindows8);
|
||||
this.Cw=!("undefined"===typeof window.c2isWindows8Capable||!window.c2isWindows8Capable);this.ji=!("undefined"===typeof window.c2isWindowsPhone8||!window.c2isWindowsPhone8);this.an=!("undefined"===typeof window.c2isWindowsPhone81||!window.c2isWindowsPhone81);this.mk=!!window.cr_windows10;this.Yp=this.Zp||this.Cw||this.an||this.mk;this.uw=!("undefined"===typeof window.c2isBlackberry10||!window.c2isBlackberry10);this.hk=this.ei&&!this.Vm&&!this.jk&&!this.vw&&!this.Up&&!this.Ca;this.devicePixelRatio=
|
||||
1;this.nf=this.Qc||this.jk||this.Vp||this.ed||this.ei||this.Ug||this.ji||this.an||this.uw||this.Xp||this.Bd;this.nf||(this.nf=/(blackberry|bb10|playbook|palm|symbian|nokia|windows\s+ce|phone|mobile|tablet|kindle|silk)/i.test(navigator.userAgent));this.lk=!!(this.Ug&&this.Qc&&window.webkit);"undefined"===typeof cr_is_preview||this.Ym||"?nw"!==window.location.search&&!/nodewebkit/i.test(navigator.userAgent)&&!/nwjs/i.test(navigator.userAgent)||(this.Ym=!0);this.canvas=a;this.zj=document.getElementById("c2canvasdiv");
|
||||
this.C=this.G=null;this.Mm="(unavailable)";this.Pa=!1;this.Lf=0;this.Za=null;this.Xj=!1;this.Uq=this.Vq=0;this.canvas.oncontextmenu=function(a){a.preventDefault&&a.preventDefault();return!1};this.canvas.onselectstart=function(a){a.preventDefault&&a.preventDefault();return!1};this.canvas.ontouchstart=function(a){a.preventDefault&&a.preventDefault();return!1};this.cc&&(window.c2runtime=this);this.Ym&&(window.ondragover=function(a){a.preventDefault();return!1},window.ondrop=function(a){a.preventDefault();
|
||||
return!1},window.nwgui&&window.nwgui.App.clearCache&&window.nwgui.App.clearCache());this.hk&&"undefined"!==typeof jQuery&&jQuery("canvas").parents("*").css("overflow","visible");this.width=a.width;this.height=a.height;this.M=this.width;this.L=this.height;this.Gj=this.width;this.Nh=this.height;this.Xg=window.innerWidth;this.Wg=window.innerHeight;this.Y=!0;this.ii=!1;Date.now||(Date.now=function(){return+new Date});this.plugins=[];this.types={};this.D=[];this.Ya=[];this.kn={};this.Dd=[];this.vm={};
|
||||
this.re=[];this.wg=[];this.xl=[];this.Vl=[];this.Yt=[];this.If={};this.Xm=this.lf=!1;this.Cd=0;this.Wm=this.$m=!1;this.Nd=[];this.gi=!1;this.uk=this.Wn="";this.wb=null;this.xe="";this.bj=this.Or=!1;this.Wj=[];this.Kf=this.Jf=0;this.Iq=30;this.mm=this.Di=0;this.vh=1;this.Nb=new db;this.Oe=new db;this.Gk=this.$j=this.Rh=this.ee=this.$f=this.Am=this.pk=0;this.Hh=null;this.Nj=[];this.um=[];this.Pj=-1;this.qn=[[]];this.lo=this.zk=0;this.Yk(null);this.sn=[];this.Bk=-1;this.Th=this.Pq=this.Gi=0;this.cj=
|
||||
[];this.io=this.On=-1;this.ni=!0;this.xk=0;this.kk=!1;this.Nx=0;this.Cg=null;this.ec=this.Mp=!1;this.Tq=new da;this.yn=new da;this.zn=new da;this.ur=[];new fb([]);new fb([]);this.Ue=[];this.ek={};this.bf={};this.Te={};this.Bh={};this.ip={};this.nq=this.tk=this.kb=this.tb=this.mq=this.sk=this.Da=null;this.zh=this.bn=!1;this.Bm=[null,null];this.Mg=0;this.xm="";this.Ae={};this.$i=this.rf=null;this.Qr="";this.Fk=[];this.vx()}}function q(a,e){return 128>=e?a[3]:256>=e?a[2]:512>=e?a[1]:a[0]}function r(){try{return!!window.indexedDB}catch(a){return!1}}
|
||||
function t(a){a.target.result.createObjectStore("saves",{keyPath:"slot"})}function b(a,e,c,b){try{var d=indexedDB.open("_C2SaveStates");d.onupgradeneeded=t;d.onerror=b;d.onsuccess=function(d){d=d.target.result;d.onerror=b;d.transaction(["saves"],"readwrite").objectStore("saves").put({slot:a,data:e}).onsuccess=c}}catch(g){b(g)}}function p(a,e,c){try{var b=indexedDB.open("_C2SaveStates");b.onupgradeneeded=t;b.onerror=c;b.onsuccess=function(b){b=b.target.result;b.onerror=c;var d=b.transaction(["saves"]).objectStore("saves").get(a);
|
||||
d.onsuccess=function(){d.result?e(d.result.data):e(null)}}}catch(d){c(d)}}function k(){ga("Reloading for continuous preview");window.c2cocoonjs?CocoonJS.App.reload():-1<window.location.search.indexOf("continuous")?window.location.reload(!0):window.location=window.location+"?continuous"}function d(a){var e,c={};for(e in a)!a.hasOwnProperty(e)||a[e]instanceof da||a[e]&&"undefined"!==typeof a[e].Dz||"spriteCreatedDestroyCallback"!==e&&(c[e]=a[e]);return c}var h=window.requestAnimationFrame||window.mozRequestAnimationFrame||
|
||||
window.webkitRequestAnimationFrame||window.msRequestAnimationFrame||window.oRequestAnimationFrame;f.prototype.vx=function(){var a=this;if(this.lk)this.Dv(function(e){a.ti(JSON.parse(e))},function(){alert("Error fetching data.js")});else{var e;this.ji?e=new ActiveXObject("Microsoft.XMLHTTP"):e=new XMLHttpRequest;var c="data.js";if(this.Zp||this.ji||this.an||this.mk)c="data.json";e.open("GET",c,!0);var b=!1;if(!this.Ca&&"response"in e&&"responseType"in e)try{e.responseType="json",b="json"===e.responseType}catch(d){b=
|
||||
!1}if(!b&&"responseType"in e)try{e.responseType="text"}catch(g){}if("overrideMimeType"in e)try{e.overrideMimeType("application/json; charset=utf-8")}catch(l){}this.ji?e.onreadystatechange=function(){4===e.readyState&&a.ti(JSON.parse(e.responseText))}:(e.onload=function(){if(b)a.ti(e.response);else if(a.Bd){var c=e.responseText,c=c.substr(c.indexOf("{"));a.ti(JSON.parse(c))}else a.ti(JSON.parse(e.responseText))},e.onerror=function(a){ia("Error requesting "+c+":");ia(a)});e.send()}};f.prototype.rw=
|
||||
function(){var a=this,e,c,b,d,g,l,m,u,n;this.Xf=(!this.Ca||this.Bd||this.Qc)&&this.Zx&&!this.hk;0===this.rc&&this.Ug&&(this.Xf=!1);this.devicePixelRatio=this.Xf?window.devicePixelRatio||window.webkitDevicePixelRatio||window.mozDevicePixelRatio||window.msDevicePixelRatio||1:1;"object"===typeof window.StatusBar&&window.StatusBar.hide();this.Tb();0<this.rc&&this.setSize(window.innerWidth,window.innerHeight,!0);this.canvas.addEventListener("webglcontextlost",function(e){e.preventDefault();a.Ow();ga("[Construct 2] WebGL context lost");
|
||||
window.cr_setSuspended(!0)},!1);this.canvas.addEventListener("webglcontextrestored",function(){a.C.Qp();a.C.qg(a.C.width,a.C.height,!0);a.tb=null;a.kb=null;a.Bm[0]=null;a.Bm[1]=null;a.Pw();a.Y=!0;ga("[Construct 2] WebGL context restored");window.cr_setSuspended(!1)},!1);try{this.Tu&&(this.ed||this.Bd||!this.Ca)&&(e={alpha:!0,depth:!1,antialias:!1,powerPreference:"high-performance",failIfMajorPerformanceCaveat:!0},this.ei||(this.G=this.canvas.getContext("webgl2",e)),this.G||(this.G=this.canvas.getContext("webgl",
|
||||
e)||this.canvas.getContext("experimental-webgl",e)))}catch(k){}if(this.G){if(e=this.G.getExtension("WEBGL_debug_renderer_info"))this.Mm=this.G.getParameter(e.UNMASKED_RENDERER_WEBGL)+" ["+this.G.getParameter(e.UNMASKED_VENDOR_WEBGL)+"]";this.Pa&&(this.Mm+=" [front-to-back enabled]");this.Ca||(this.Pb=document.createElement("canvas"),jQuery(this.Pb).appendTo(this.canvas.parentNode),this.Pb.oncontextmenu=function(){return!1},this.Pb.onselectstart=function(){return!1},this.Pb.width=Math.round(this.Gj*
|
||||
this.devicePixelRatio),this.Pb.height=Math.round(this.Nh*this.devicePixelRatio),jQuery(this.Pb).css({width:this.Gj+"px",height:this.Nh+"px"}),this.nr(),this.Gn=this.Pb.getContext("2d"));this.C=new pb(this.G,this.nf,this.Pa);this.C.qg(this.canvas.width,this.canvas.height);this.C.vp=0!==this.Lu;this.Za=null;e=0;for(c=this.D.length;e<c;e++)for(g=this.D[e],b=0,d=g.T.length;b<d;b++)m=g.T[b],m.nb=this.C.Lm(m.id),m.jd=this.C.Ln(m.nb),this.zh=this.zh||this.C.Qi(m.nb);e=0;for(c=this.Dd.length;e<c;e++){u=this.Dd[e];
|
||||
b=0;for(d=u.T.length;b<d;b++)m=u.T[b],m.nb=this.C.Lm(m.id),m.jd=this.C.Ln(m.nb);u.Id();b=0;for(d=u.X.length;b<d;b++){n=u.X[b];g=0;for(l=n.T.length;g<l;g++)m=n.T[g],m.nb=this.C.Lm(m.id),m.jd=this.C.Ln(m.nb),this.zh=this.zh||this.C.Qi(m.nb);n.Id()}}}else{if(0<this.rc&&this.cc){this.canvas=null;document.oncontextmenu=function(){return!1};document.onselectstart=function(){return!1};this.Za=AppMobi.canvas.getContext("2d");try{this.Za.samplingMode=this.Ra?"smooth":"sharp",this.Za.globalScale=1,this.Za.HTML5CompatibilityMode=
|
||||
!0,this.Za.imageSmoothingEnabled=this.Ra}catch(w){}0!==this.width&&0!==this.height&&(this.Za.width=this.width,this.Za.height=this.height)}this.Za||(this.ed?(e={antialias:!!this.Ra,alpha:!0},this.Za=this.canvas.getContext("2d",e)):(e={alpha:!0},this.Za=this.canvas.getContext("2d",e)),this.gl(this.Za,this.Ra));this.Gn=this.Pb=null}this.Xr=function(e){a.Sa(!1,e)};window==window.top||this.Ca||this.Yp||this.ji||(document.addEventListener("mousedown",function(){window.focus()},!0),document.addEventListener("touchstart",
|
||||
function(){window.focus()},!0));"undefined"!==typeof cr_is_preview&&(this.ed&&console.log("[Construct 2] In preview-over-wifi via CocoonJS mode"),-1<window.location.search.indexOf("continuous")&&(ga("Reloading for continuous preview"),this.uk="__c2_continuouspreview",this.bj=!0),this.$w&&!this.nf&&(jQuery(window).focus(function(){a.setSuspended(!1)}),jQuery(window).blur(function(){var e=window.parent;e&&e.document.hasFocus()||a.setSuspended(!0)})));window.addEventListener("blur",function(){a.jh()});
|
||||
this.Ca||(e=function(a){if(ob(a)&&document.activeElement&&document.activeElement!==document.getElementsByTagName("body")[0]&&document.activeElement.blur)try{document.activeElement.blur()}catch(e){}},"undefined"!==typeof PointerEvent?document.addEventListener("pointerdown",e):window.navigator.msPointerEnabled?document.addEventListener("MSPointerDown",e):document.addEventListener("touchstart",e),document.addEventListener("mousedown",e));0===this.rc&&this.Xf&&1<this.devicePixelRatio&&this.setSize(this.Xa,
|
||||
this.Wa,!0);this.bs();this.jw();this.go();this.Ta={}};f.prototype.setSize=function(a,e,c){var b=0,d=0,g=0,l=0,l=0;if(this.Xg!==a||this.Wg!==e||c){this.Xg=a;this.Wg=e;var m=this.rc;if((g=(document.mozFullScreen||document.webkitIsFullScreen||!!document.msFullscreenElement||document.fullScreen||this.kk)&&!this.Qc)||0!==this.rc||c)g&&(m=this.Mg),c=this.devicePixelRatio,4<=m?(5===m&&1!==c&&(a+=1,e+=1),g=this.Xa/this.Wa,a/e>g?(g*=e,5===m?(l=g*c/this.Xa,1<l?l=Math.floor(l):1>l&&(l=1/Math.ceil(1/l)),g=this.Xa*
|
||||
l/c,l=this.Wa*l/c,b=(a-g)/2,d=(e-l)/2,a=g,e=l):(b=(a-g)/2,a=g)):(l=a/g,5===m?(l=l*c/this.Wa,1<l?l=Math.floor(l):1>l&&(l=1/Math.ceil(1/l)),g=this.Xa*l/c,l=this.Wa*l/c,b=(a-g)/2,d=(e-l)/2,a=g):d=(e-l)/2,e=l)):g&&0===m&&(b=Math.floor((a-this.Xa)/2),d=Math.floor((e-this.Wa)/2),a=this.Xa,e=this.Wa),2>m&&(this.Fh=c),this.Gj=Math.round(a),this.Nh=Math.round(e),this.width=Math.round(a*c),this.height=Math.round(e*c),this.Y=!0,this.ns?(this.M=this.width,this.L=this.height,this.Nc=!0):this.width<this.Xa&&this.height<
|
||||
this.Wa||1===m?(this.M=this.width,this.L=this.height,this.Nc=!0):(this.M=this.Xa,this.L=this.Wa,this.Nc=!1,2===m?(g=this.Xa/this.Wa,m=this.Xg/this.Wg,m<g?this.M=this.L*m:m>g&&(this.L=this.M/m)):3===m&&(g=this.Xa/this.Wa,m=this.Xg/this.Wg,m>g?this.M=this.L*m:m<g&&(this.L=this.M/m))),this.zj&&!this.Ca&&(jQuery(this.zj).css({width:Math.round(a)+"px",height:Math.round(e)+"px","margin-left":Math.floor(b)+"px","margin-top":Math.floor(d)+"px"}),"undefined"!==typeof cr_is_preview&&jQuery("#borderwrap").css({width:Math.round(a)+
|
||||
"px",height:Math.round(e)+"px"})),this.canvas&&(this.canvas.width=Math.round(a*c),this.canvas.height=Math.round(e*c),this.Bd?(this.canvas.style.left=Math.floor(b)+"px",this.canvas.style.top=Math.floor(d)+"px",this.canvas.style.width=Math.round(a)+"px",this.canvas.style.height=Math.round(e)+"px"):this.Xf&&!this.Ca&&(this.canvas.style.width=Math.round(a)+"px",this.canvas.style.height=Math.round(e)+"px")),this.Pb&&(this.Pb.width=Math.round(a*c),this.Pb.height=Math.round(e*c),this.Pb.style.width=this.Gj+
|
||||
"px",this.Pb.style.height=this.Nh+"px"),this.C&&this.C.qg(Math.round(a*c),Math.round(e*c)),this.cc&&this.Za&&(this.Za.width=Math.round(a),this.Za.height=Math.round(e)),this.Za&&this.gl(this.Za,this.Ra),this.bs(),this.aq&&!this.Qc&&window.scrollTo(0,0)}};f.prototype.bs=function(){if(this.cu&&0!==this.Fn){var a="portrait";2===this.Fn&&(a="landscape");try{screen.orientation&&screen.orientation.lock?screen.orientation.lock(a).catch(function(){}):screen.lockOrientation?screen.lockOrientation(a):screen.webkitLockOrientation?
|
||||
screen.webkitLockOrientation(a):screen.mozLockOrientation?screen.mozLockOrientation(a):screen.msLockOrientation&&screen.msLockOrientation(a)}catch(e){console&&console.warn&&console.warn("Failed to lock orientation: ",e)}}};f.prototype.Ow=function(){this.C.ku();this.bn=!0;var a,e,c;a=0;for(e=this.D.length;a<e;a++)c=this.D[a],c.Ik&&c.Ik()};f.prototype.Pw=function(){this.bn=!1;var a,e,c;a=0;for(e=this.D.length;a<e;a++)c=this.D[a],c.Cn&&c.Cn()};f.prototype.nr=function(){if(!this.Ca){var a=(document.mozFullScreen||
|
||||
document.webkitIsFullScreen||document.fullScreen||document.msFullscreenElement||this.kk)&&!this.Qc?jQuery(this.canvas).offset():jQuery(this.canvas).position();a.position="absolute";jQuery(this.Pb).css(a)}};var c=window.cancelAnimationFrame||window.mozCancelAnimationFrame||window.webkitCancelAnimationFrame||window.msCancelAnimationFrame||window.oCancelAnimationFrame;f.prototype.setSuspended=function(a){var e;if(a&&!this.ii)for(ga("[Construct 2] Suspending"),this.ii=!0,-1!==this.On&&c&&c(this.On),-1!==
|
||||
this.io&&clearTimeout(this.io),a=0,e=this.cj.length;a<e;a++)this.cj[a](!0);else if(!a&&this.ii){ga("[Construct 2] Resuming");this.ii=!1;this.pk=$a();this.$f=$a();a=this.Di=this.$j=0;for(e=this.cj.length;a<e;a++)this.cj[a](!1);this.Sa(!1)}};f.prototype.Wo=function(a){this.cj.push(a)};f.prototype.Re=function(a){return this.Fk[a]};f.prototype.ti=function(a){a&&a.project||ia("Project model unavailable");a=a.project;this.name=a[0];this.Cp=a[1];this.rc=a[12];this.Xa=a[10];this.Wa=a[11];this.jr=this.Xa/
|
||||
2;this.kr=this.Wa/2;this.Ca&&!this.Bd&&(4<=a[12]||0===a[12])&&(ga("[Construct 2] Letterbox scale fullscreen modes are not supported on this platform - falling back to 'Scale outer'"),this.rc=3);this.uo=a[18];this.sf=a[19];if(0===this.sf){var e=new Image;e.crossOrigin="anonymous";this.Xn(e,"loading-logo.png");this.rf={Ak:e}}else if(4===this.sf){e=new Image;e.src="";var c=new Image;c.src="";var b=new Image;b.src="";var d=new Image;d.src="";var g=new Image;g.src="";var l=new Image;l.src="";var m=new Image;
|
||||
m.src="";var u=new Image;u.src="";var n=new Image;n.src="";var k=new Image;k.src="";var w=new Image;w.src="";var f=new Image;f.src="";this.rf={Ak:[e,c,b,d],hx:[g,l,m,u],dy:[n,k,w,f]}}this.Gi=a[21];this.Fk=sc();this.be=new X(this);e=0;for(c=a[2].length;e<c;e++)m=a[2][e],b=this.Re(m[0]),qb(m,b.prototype),u=new b(this),u.kl=m[1],u.pf=m[2],u.Jz=m[5],u.Kq=m[9],u.N&&u.N(),this.plugins.push(u);this.Fk=sc();e=0;for(c=a[3].length;e<c;e++){m=a[3][e];g=this.Re(m[1]);u=null;b=0;for(d=this.plugins.length;b<d;b++)if(this.plugins[b]instanceof
|
||||
g){u=this.plugins[b];break}n=new u.la(u);n.name=m[0];n.V=m[2];n.Tm=m[3].slice(0);n.ay=m[3].length;n.du=m[4];n.Hv=m[5];n.fa=m[11];n.V?(n.Ek=[],n.se=this.Th++,n.Ua=null):(n.Ek=null,n.se=-1,n.Ua=[]);n.Uj=null;n.Kg=null;n.wp=null;n.jc=!1;n.Dc=null;m[6]?(n.fo=m[6][0],n.Vr=m[6][1],n.ho=m[6][2]):(n.fo=null,n.Vr=0,n.ho=0);m[7]?n.Cc=m[7]:n.Cc=null;n.index=e;n.e=[];n.Kj=[];n.Je=[new rb(n)];n.Od=0;n.bd=null;n.pu=0;n.sh=!0;n.zl=sb;n.Fm=tb;n.Rv=ub;n.qa=vb;n.Si=wb;n.Xk=xb;n.mg=yb;n.bk=zb;n.Cm=Ab;n.Em=Bb;n.Ve=Cb;
|
||||
n.Hm=Db;n.op=new gb(this.Xa,this.Wa);n.$o=!0;n.bp=!1;n.Ta={};n.toString=Ib;n.Ya=[];b=0;for(d=m[8].length;b<d;b++){k=m[8][b];w=this.Re(k[1]);f=null;g=0;for(l=this.Ya.length;g<l;g++)if(this.Ya[g]instanceof w){f=this.Ya[g];break}f||(f=new w(this),f.Mq=[],f.wn=new da,f.N&&f.N(),this.Ya.push(f));-1===f.Mq.indexOf(n)&&f.Mq.push(n);g=new f.la(f,n);g.name=k[0];g.fa=k[2];g.N();n.Ya.push(g)}n.global=m[9];n.Zm=m[10];n.T=[];b=0;for(d=m[12].length;b<d;b++)n.T.push({id:m[12][b][0],name:m[12][b][1],nb:-1,jd:!1,
|
||||
B:!0,index:b});n.Xz=m[13];this.uo&&!n.V&&!n.Zm&&u.pf||n.N();n.name&&(this.types[n.name]=n);this.D.push(n);u.kl&&(b=new u.da(n),b.uid=this.Gi++,b.qr=this.Pq++,b.Tf=0,b.Zh=Jb,b.toString=Kb,b.q=m[14],b.N(),n.e.push(b),this.Ae[b.uid.toString()]=b)}e=0;for(c=a[4].length;e<c;e++)for(g=a[4][e],l=this.D[g[0]],b=1,d=g.length;b<d;b++)m=this.D[g[b]],m.Ua.push(l),l.Ek.push(m);e=0;for(c=a[28].length;e<c;e++){g=a[28][e];l=[];b=0;for(d=g.length;b<d;b++)l.push(this.D[g[b]]);b=0;for(d=l.length;b<d;b++)l[b].jc=!0,
|
||||
l[b].Dc=l}if(0<this.Th)for(e=0,c=this.D.length;e<c;e++)if(m=this.D[e],!m.V&&m.Ua.length){m.Uj=Array(this.Th);m.Kg=Array(this.Th);m.wp=Array(this.Th);n=[];b=f=w=k=0;for(d=m.Ua.length;b<d;b++)for(u=m.Ua[b],m.Uj[u.se]=k,k+=u.ay,m.Kg[u.se]=w,w+=u.du,m.wp[u.se]=f,f+=u.Hv,g=0,l=u.T.length;g<l;g++)n.push(Aa({},u.T[g]));m.T=n.concat(m.T);b=0;for(d=m.T.length;b<d;b++)m.T[b].index=b}e=0;for(c=a[5].length;e<c;e++)m=a[5][e],b=new Lb(this,m),this.kn[b.name]=b,this.Dd.push(b);e=0;for(c=a[6].length;e<c;e++)m=a[6][e],
|
||||
b=new Mb(this,m),this.vm[b.name]=b,this.re.push(b);e=0;for(c=this.re.length;e<c;e++)this.re[e].cb();e=0;for(c=this.re.length;e<c;e++)this.re[e].ro();e=0;for(c=this.xl.length;e<c;e++)this.xl[e].cb();N(this.xl);this.au=a[7];this.xm=a[8];this.Ed=a[9];this.Fh=1;this.Tu=a[13];this.Ra=a[14];this.np=a[15];this.Zx=a[17];this.Fn=a[20];this.cu=0<this.Fn;this.$w=a[22];this.Nc=this.ns=a[23];this.Lu=a[24];this.ix=a[25];this.Pa=a[27]&&!this.we;this.ll=Date.now();N(this.Fk);this.rw()};var a=!1,e=0,l=[];f.prototype.ox=
|
||||
function(a,c){function b(){e--;d.Gq()}var d=this;a.addEventListener("load",b);a.addEventListener("error",b);l.push([a,c]);this.Gq()};f.prototype.Gq=function(){for(var a;l.length&&100>e;)e++,a=l.shift(),this.Xn(a[0],a[1])};f.prototype.cy=function(e,c){e.cocoonLazyLoad=!0;e.onerror=function(c){a=e.kp=!0;console&&console.error&&console.error("Error loading image '"+e.src+"': ",c)};this.Bd?e.src=c:e.src||("undefined"!==typeof XAPKReader?XAPKReader.get(c,function(a){e.src=a},function(b){a=e.kp=!0;console&&
|
||||
console.error&&console.error("Error extracting image '"+c+"' from expansion file: ",b)}):(e.crossOrigin="anonymous",this.ox(e,c)));this.wg.push(e)};f.prototype.Fv=function(a){var e,c;e=0;for(c=this.wg.length;e<c;e++)if(this.wg[e].mu===a)return this.wg[e];return null};var g=0,n=!1;f.prototype.jw=function(){this.Cg&&(g=this.Cg.Ix(this.au))};f.prototype.cp=function(){var a=g,e=0,c=0,b=!0,d,m,c=0;for(d=this.wg.length;c<d;c++){m=this.wg[c];var l=m.lu;if(!l||0>=l)l=5E4;a+=l;m.src&&(m.complete||m.loaded)&&
|
||||
!m.kp?e+=l:b=!1}b&&this.ix&&this.Cg&&(n||(this.Cg.Ox(),n=!0),c=this.Cg.Sv(),e+=c,c<g&&(b=!1));this.Fd=0==a?1:e/a;return b};var L=!1;f.prototype.go=function(){if(this.Za||this.C){var e=this.Za||this.Gn;this.Pb&&this.nr();var c=window.innerWidth,b=window.innerHeight;this.Xg===c&&this.Wg===b||this.setSize(c,b);this.Fd=0;this.lq=-1;var d=this;if(this.cp()&&(4!==this.sf||L))this.kw();else{b=Date.now()-this.ll;if(e){var g=this.width,m=this.height,c=this.devicePixelRatio;if(3>this.sf&&(this.ed||500<=b&&
|
||||
this.lq!=this.Fd)){e.clearRect(0,0,g,m);var b=g/2,m=m/2,g=0===this.sf&&this.rf.Ak.complete,l=40*c,n=0,u=80*c,k;if(g){var w=this.rf.Ak,u=w.width*c;k=w.height*c;l=u/2;n=k/2;e.drawImage(w,ta(b-l),ta(m-n),u,k)}1>=this.sf?(b=ta(b-l)+.5,m=ta(m+(n+(g?12*c:0)))+.5,e.fillStyle=a?"red":"DodgerBlue",e.fillRect(b,m,Math.floor(u*this.Fd),6*c),e.strokeStyle="black",e.strokeRect(b,m,u,6*c),e.strokeStyle="white",e.strokeRect(b-1*c,m-1*c,u+2*c,8*c)):2===this.sf&&(e.font=this.Bd?"12pt ArialMT":"12pt Arial",e.fillStyle=
|
||||
a?"#f00":"#999",e.Wz="middle",c=Math.round(100*this.Fd)+"%",g=e.measureText?e.measureText(c):null,e.fillText(c,b-(g?g.width:0)/2,m));this.lq=this.Fd}else if(4===this.sf){this.Qu(e);h?h(function(){d.go()}):setTimeout(function(){d.go()},16);return}}setTimeout(function(){d.go()},this.ed?10:100)}}};var w=-1,m="undefined"===typeof cr_is_preview?200:0,u=!0,fa=!1,ha=0,W=0,E="undefined"===typeof cr_is_preview?3E3:0,x=null,y=null,F=0;f.prototype.Qu=function(e){if(!L){for(var c=Math.ceil(this.width),b=Math.ceil(this.height),
|
||||
d=this.rf.Ak,g=this.rf.hx,l=this.rf.dy,n=0;4>n;++n)if(!d[n].complete||!g[n].complete||!l[n].complete)return;0===F&&(w=Date.now());var n=Date.now(),k=!1,f=e,h,p;u||fa?(e.clearRect(0,0,c,b),x&&x.width===c&&x.height===b||(x=document.createElement("canvas"),x.width=c,x.height=b,y=x.getContext("2d")),f=y,k=!0,u&&1===F&&(w=Date.now())):e.globalAlpha=1;f.fillStyle="#333333";f.fillRect(0,0,c,b);256<this.Nh?(h=Ha(.22*b,105,.6*c),p=.25*h,f.drawImage(q(g,h),.5*c-h/2,.2*b-p/2,h,p),p=h=Math.min(.395*b,.95*c),
|
||||
f.drawImage(q(d,h),.5*c-h/2,.485*b-p/2,h,p),h=Ha(.22*b,105,.6*c),p=.25*h,f.drawImage(q(l,h),.5*c-h/2,.868*b-p/2,h,p),f.fillStyle="#3C3C3C",h=c,p=Math.max(.005*b,2),f.fillRect(0,.8*b-p/2,h,p),f.fillStyle=a?"red":"#E0FF65",h=c*this.Fd,f.fillRect(.5*c-h/2,.8*b-p/2,h,p)):(p=h=.55*b,f.drawImage(q(d,h),.5*c-h/2,.45*b-p/2,h,p),f.fillStyle="#3C3C3C",h=c,p=Math.max(.005*b,2),f.fillRect(0,.85*b-p/2,h,p),f.fillStyle=a?"red":"#E0FF65",h=c*this.Fd,f.fillRect(.5*c-h/2,.85*b-p/2,h,p));k&&(u?e.globalAlpha=0===F?
|
||||
0:Math.min((n-w)/300,1):fa&&(e.globalAlpha=Math.max(1-(n-W)/300,0)),e.drawImage(x,0,0,c,b));u&&300<=n-w&&2<=F&&(u=!1,ha=n);!u&&n-ha>=E&&!fa&&1<=this.Fd&&(fa=!0,W=n);if(fa&&n-W>=300+m||"undefined"!==typeof cr_is_preview&&1<=this.Fd&&500>Date.now()-w)L=!0,fa=u=!1,this.rf=y=x=null;++F}};f.prototype.kw=function(){this.Pb&&(this.canvas.parentNode.removeChild(this.Pb),this.Pb=this.Gn=null);this.ll=Date.now();this.$f=$a();var a,e,c;if(this.uo)for(a=0,e=this.D.length;a<e;a++)c=this.D[a],c.V||c.Zm||!c.Ga.pf||
|
||||
c.N();else this.ni=!1;a=0;for(e=this.Dd.length;a<e;a++)this.Dd[a].nu();2<=this.rc&&(a=this.Xa/this.Wa,e=this.width/this.height,this.Fh=2!==this.rc&&e>a||2===this.rc&&e<a?this.height/this.Wa:this.width/this.Xa);this.Cp?this.kn[this.Cp].co():this.Dd[0].co();this.uo||(this.xk=1,this.trigger(X.prototype.g.Fo,null),window.C2_RegisterSW&&window.C2_RegisterSW());navigator.splashscreen&&navigator.splashscreen.hide&&navigator.splashscreen.hide();a=0;for(e=this.D.length;a<e;a++)c=this.D[a],c.Wq&&c.Wq();document.hidden||
|
||||
document.webkitHidden||document.mozHidden||document.msHidden?window.cr_setSuspended(!0):this.Sa(!1);this.cc&&AppMobi.webview.execute("onGameReady();")};f.prototype.Sa=function(a,e,c){if(this.Da){var b=$a();if(c||!this.ii||a){a||(h?this.On=h(this.Xr):this.io=setTimeout(this.Xr,this.nf?1:16));e=e||b;var d=this.rc;((c=(document.mozFullScreen||document.webkitIsFullScreen||document.fullScreen||!!document.msFullscreenElement)&&!this.Qc)||this.kk)&&0<this.Mg&&(d=this.Mg);if(0<d){var d=window.innerWidth,
|
||||
g=window.innerHeight;this.Xg===d&&this.Wg===g||this.setSize(d,g)}this.Ca||(c?this.Xj||(this.Xj=!0):this.Xj?(this.Xj=!1,0===this.rc&&this.setSize(Math.round(this.Vq/this.devicePixelRatio),Math.round(this.Uq/this.devicePixelRatio),!0)):(this.Vq=this.width,this.Uq=this.height));this.ni&&(c=this.cp(),this.xk=this.Fd,c&&(this.ni=!1,this.Fd=1,this.trigger(X.prototype.g.Fo,null),window.C2_RegisterSW&&window.C2_RegisterSW()));this.Jw(e);!this.Y&&!this.ed||this.bn||this.bj||a||(this.Y=!1,this.C?this.Ec():
|
||||
this.zd(),this.$i&&(this.canvas&&this.canvas.toDataURL&&(this.Qr=this.canvas.toDataURL(this.$i[0],this.$i[1]),window.cr_onSnapshot&&window.cr_onSnapshot(this.Qr),this.trigger(X.prototype.g.Ps,null)),this.$i=null));this.Iz||(this.ee++,this.Rh++,this.$j++);this.Di+=$a()-b}}};f.prototype.Jw=function(a){var e,c,b,d,g,m,l,n;1E3<=a-this.$f&&(this.$f+=1E3,1E3<=a-this.$f&&(this.$f=a),this.Am=this.$j,this.$j=0,this.mm=this.Di,this.Di=0);e=0;0!==this.pk&&(e=a-this.pk,0>e&&(e=0),this.Kf=e/=1E3,.5<this.Kf?this.Kf=
|
||||
0:this.Kf>1/this.Iq&&(this.Kf=1/this.Iq));this.pk=a;this.Jf=this.Kf*this.vh;this.Nb.add(this.Jf);this.Oe.add(e);a=(document.mozFullScreen||document.webkitIsFullScreen||document.fullScreen||!!document.msFullscreenElement||this.kk)&&!this.Qc;2<=this.rc||a&&0<this.Mg?(e=this.Xa/this.Wa,c=this.width/this.height,b=this.rc,a&&0<this.Mg&&(b=this.Mg),this.Fh=2!==b&&c>e||2===b&&c<e?this.height/this.Wa:this.width/this.Xa,this.Da&&(this.Da.Br(this.Da.scrollX),this.Da.Cr(this.Da.scrollY))):this.Fh=this.Xf?this.devicePixelRatio:
|
||||
1;this.Tb();this.Cd++;this.be.zx();this.Cd--;this.Tb();this.Cd++;c=this.Tq.Bf();a=0;for(e=c.length;a<e;a++)c[a].Rz();a=0;for(e=this.D.length;a<e;a++)if(m=this.D[a],!m.V&&(m.Ya.length||m.Ua.length))for(c=0,b=m.e.length;c<b;c++)for(l=m.e[c],d=0,g=l.S.length;d<g;d++)l.S[d].Sa();a=0;for(e=this.D.length;a<e;a++)if(m=this.D[a],!m.V&&(m.Ya.length||m.Ua.length))for(c=0,b=m.e.length;c<b;c++)for(l=m.e[c],d=0,g=l.S.length;d<g;d++)n=l.S[d],n.gx&&n.gx();c=this.yn.Bf();a=0;for(e=c.length;a<e;a++)c[a].Sa();this.Cd--;
|
||||
this.lw();for(a=0;this.Hh&&10>a++;)this.up(this.Hh);a=0;for(e=this.re.length;a<e;a++)this.re[a].Pm=!1;this.Da.Nf&&this.Da.Nf.mb();N(this.ur);this.Cd++;a=0;for(e=this.D.length;a<e;a++)if(m=this.D[a],!m.V&&(m.Ya.length||m.Ua.length))for(c=0,b=m.e.length;c<b;c++)for(l=m.e[c],d=0,g=l.S.length;d<g;d++)n=l.S[d],n.ej&&n.ej();c=this.zn.Bf();a=0;for(e=c.length;a<e;a++)c[a].ej();this.Cd--};f.prototype.jh=function(){var a,e,c,b,d,g,m,l,n;a=0;for(e=this.D.length;a<e;a++)if(m=this.D[a],!m.V)for(c=0,b=m.e.length;c<
|
||||
b;c++)if(l=m.e[c],l.jh&&l.jh(),l.S)for(d=0,g=l.S.length;d<g;d++)n=l.S[d],n.jh&&n.jh()};f.prototype.up=function(a){var e=this.Da;this.Da.Px();var c,b,d;if(this.C)for(c=0,b=this.D.length;c<b;c++)d=this.D[c],d.V||!d.po||d.global&&0!==d.e.length||-1!==a.di.indexOf(d)||d.po();e==a&&N(this.be.Ac);N(this.ur);this.yr(!0);a.co();this.yr(!1);this.Y=!0;this.Tb()};f.prototype.yr=function(a){var e,c,b,d,g,m,l,n,u;e=0;for(c=this.Ya.length;e<c;e++)b=this.Ya[e],a?b.Hi&&b.Hi():b.Ki&&b.Ki();e=0;for(c=this.D.length;e<
|
||||
c;e++)if(b=this.D[e],b.global||b.Ga.kl)for(d=0,g=b.e.length;d<g;d++)if(m=b.e[d],a?m.Hi&&m.Hi():m.Ki&&m.Ki(),m.S)for(l=0,n=m.S.length;l<n;l++)u=m.S[l],a?u.Hi&&u.Hi():u.Ki&&u.Ki()};f.prototype.tl=function(a){this.yn.add(a)};f.prototype.Rx=function(a){this.zn.add(a)};f.prototype.Pf=function(a){return a&&-1!==a.Fi?this.Kf*a.Fi:this.Jf};f.prototype.zd=function(){this.Da.zd(this.Za);this.cc&&this.Za.present()};f.prototype.Ec=function(){this.Pa&&(this.Lf=1,this.Da.Hg(this.C));this.Da.Ec(this.C);this.C.kx()};
|
||||
f.prototype.Uo=function(a){a&&this.Nj.push(a)};f.prototype.ux=function(a){Ga(this.Nj,a)};f.prototype.Xh=function(a){a=a.toString();return this.Ae.hasOwnProperty(a)?this.Ae[a]:null};var G=[];f.prototype.ie=function(a){var e,c;e=a.type.name;var b=null;if(this.If.hasOwnProperty(e)){if(b=this.If[e],b.contains(a))return}else b=G.length?G.pop():new da,this.If[e]=b;b.add(a);this.lf=!0;if(a.jc)for(e=0,c=a.siblings.length;e<c;e++)this.ie(a.siblings[e]);this.Xm&&b.Ah.push(a);this.Wm||(this.Cd++,this.trigger(Object.getPrototypeOf(a.type.Ga).g.Ss,
|
||||
a),this.Cd--)};f.prototype.Tb=function(){if(this.lf){var a,e,c,b,d,g;this.Xm=!0;c=0;for(d=this.Nd.length;c<d;++c)for(a=this.Nd[c],e=a.type,e.e.push(a),b=0,g=e.Ua.length;b<g;++b)e.Ua[b].e.push(a),e.Ua[b].sh=!0;N(this.Nd);this.Js();Xa(this.If);this.lf=this.Xm=!1}};f.prototype.Js=function(){for(var a in this.If)this.If.hasOwnProperty(a)&&this.ts(this.If[a])};f.prototype.ts=function(a){var e=a.Bf(),c=e[0].type,b,d,g,m,l,n;ab(c.e,a);c.sh=!0;0===c.e.length&&(c.bp=!1);b=0;for(d=c.Ua.length;b<d;++b)n=c.Ua[b],
|
||||
ab(n.e,a),n.sh=!0;b=0;for(d=this.be.Ac.length;b<d;++b)if(l=this.be.Ac[b],l.mc.hasOwnProperty(c.index)&&ab(l.mc[c.index].ue,a),!c.V)for(g=0,m=c.Ua.length;g<m;++g)n=c.Ua[g],l.mc.hasOwnProperty(n.index)&&ab(l.mc[n.index].ue,a);if(l=e[0].k){if(l.Yc)for(g=l.e,b=0,d=g.length;b<d;++b)m=g[b],a.contains(m)&&(m.Ha(),l.Rb.update(m,m.xc,null),m.xc.set(0,0,-1,-1));ab(l.e,a);l.Xi(0)}for(b=0;b<e.length;++b)this.ss(e[b],c);a.clear();G.push(a);this.Y=!0};f.prototype.ss=function(a,e){var c,b,d;c=0;for(b=this.Nj.length;c<
|
||||
b;++c)this.Nj[c](a);a.cf&&e.op.update(a,a.cf,null);(c=a.k)&&c.ph(a,!0);if(a.S)for(c=0,b=a.S.length;c<b;++c)d=a.S[c],d.lg&&d.lg(),d.behavior.wn.remove(a);this.Tq.remove(a);this.yn.remove(a);this.zn.remove(a);a.lg&&a.lg();this.Ae.hasOwnProperty(a.uid.toString())&&delete this.Ae[a.uid.toString()];this.Gk--;100>e.Kj.length&&e.Kj.push(a)};f.prototype.rp=function(a,e,c,b){if(a.V){var d=ta(Math.random()*a.Ek.length);return this.rp(a.Ek[d],e,c,b)}return a.bd?this.df(a.bd,e,!1,c,b,!1):null};var K=[];f.prototype.df=
|
||||
function(a,e,c,b,d,g){var m,l,n,u;if(!a)return null;var k=this.D[a[1]],w=k.Ga.pf;if(this.ni&&w&&!k.Zm||w&&!this.C&&11===a[0][11])return null;var f=e;w||(e=null);var h;k.Kj.length?(h=k.Kj.pop(),h.Eb=!0,k.Ga.da.call(h,k)):(h=new k.Ga.da(k),h.Eb=!1);!c||g||this.Ae.hasOwnProperty(a[2].toString())?h.uid=this.Gi++:h.uid=a[2];this.Ae[h.uid.toString()]=h;h.qr=this.Pq++;h.Tf=k.e.length;m=0;for(l=this.Nd.length;m<l;++m)this.Nd[m].type===k&&h.Tf++;h.Zh=Jb;h.toString=Kb;n=a[3];if(h.Eb)Xa(h.Ta);else{h.Ta={};if("undefined"!==
|
||||
typeof cr_is_preview)for(h.Tp=[],h.Tp.length=n.length,m=0,l=n.length;m<l;m++)h.Tp[m]=n[m][1];h.sb=[];h.sb.length=n.length}m=0;for(l=n.length;m<l;m++)h.sb[m]=n[m][0];if(w){var p=a[0];h.x=ka(b)?p[0]:b;h.y=ka(d)?p[1]:d;h.z=p[2];h.width=p[3];h.height=p[4];h.depth=p[5];h.j=p[6];h.opacity=p[7];h.tc=p[8];h.uc=p[9];h.Ub=p[10];m=p[11];!this.C&&k.T.length&&(h.Ub=m);h.Jh=ib(h.Ub);this.G&&jb(h,h.Ub,this.G);if(h.Eb){m=0;for(l=p[12].length;m<l;m++)for(n=0,u=p[12][m].length;n<u;n++)h.$a[m][n]=p[12][m][n];h.xa.set(0,
|
||||
0,0,0);h.cf.set(0,0,-1,-1);h.xc.set(0,0,-1,-1);h.Xe.jl(h.xa);N(h.$l)}else{h.$a=p[12].slice(0);m=0;for(l=h.$a.length;m<l;m++)h.$a[m]=p[12][m].slice(0);h.wa=[];h.Se=[];h.Se.length=k.T.length;h.xa=new wa(0,0,0,0);h.cf=new wa(0,0,-1,-1);h.xc=new wa(0,0,-1,-1);h.Xe=new xa;h.$l=[];h.ta=Nb;h.Cz=Ob;h.ad=Pb;h.Ha=Qb;h.Yx=Rb;h.Yz=Sb;h.Rd=Tb}h.Yr=!1;h.Ux=0;h.Tx=0;h.Sx=null;14===p.length&&(h.Yr=!0,h.Ux=p[13][0],h.Tx=p[13][1],h.Sx=p[13][2]);m=0;for(l=k.T.length;m<l;m++)h.Se[m]=!0;h.He=!0;h.Id=Ub;h.Id();h.ks=!!h.wa.length;
|
||||
h.Zl=!0;h.fm=!0;k.$o=!0;h.visible=!0;h.Fi=-1;h.k=e;h.Jd=e.e.length;h.Lf=0;"undefined"===typeof h.Md&&(h.Md=null);this.Y=h.Ih=!0}var q;N(K);m=0;for(l=k.Ua.length;m<l;m++)K.push.apply(K,k.Ua[m].Ya);K.push.apply(K,k.Ya);if(h.Eb)for(m=0,l=K.length;m<l;m++){var L=K[m];q=h.S[m];q.Eb=!0;L.behavior.da.call(q,L,h);p=a[4][m];n=0;for(u=p.length;n<u;n++)q.q[n]=p[n];q.N();L.behavior.wn.add(h)}else for(h.S=[],m=0,l=K.length;m<l;m++)L=K[m],q=new L.behavior.da(L,h),q.Eb=!1,q.q=a[4][m].slice(0),q.N(),h.S.push(q),
|
||||
L.behavior.wn.add(h);p=a[5];if(h.Eb)for(m=0,l=p.length;m<l;m++)h.q[m]=p[m];else h.q=p.slice(0);this.Nd.push(h);this.lf=!0;e&&(e.Eh(h,!0),1!==e.Be||1!==e.Ce)&&(k.bp=!0);this.Gk++;if(k.jc){if(h.jc=!0,h.Eb?N(h.siblings):h.siblings=[],!c&&!g){m=0;for(l=k.Dc.length;m<l;m++)if(k.Dc[m]!==k){if(!k.Dc[m].bd)return null;h.siblings.push(this.df(k.Dc[m].bd,f,!1,w?h.x:b,w?h.y:d,!0))}m=0;for(l=h.siblings.length;m<l;m++)for(h.siblings[m].siblings.push(h),n=0;n<l;n++)m!==n&&h.siblings[m].siblings.push(h.siblings[n])}}else h.jc=
|
||||
!1,h.siblings=null;h.N();m=0;for(l=h.S.length;m<l;m++)h.S[m].dx&&h.S[m].dx();return h};f.prototype.Im=function(a){var e,c;e=0;for(c=this.Da.X.length;e<c;e++){var b=this.Da.X[e];if(nb(b.name,a))return b}return null};f.prototype.Wh=function(a){a=ta(a);0>a&&(a=0);a>=this.Da.X.length&&(a=this.Da.X.length-1);return this.Da.X[a]};f.prototype.km=function(a){var e,c;e=0;for(c=a.length;e<c;e++)a[e].qa().Aa=!0};f.prototype.Si=function(a){var e,c;e=0;for(c=a.length;e<c;e++)a[e].Si()};f.prototype.Xk=function(a){var e,
|
||||
c;e=0;for(c=a.length;e<c;e++)a[e].Xk()};f.prototype.mg=function(a){var e,c;e=0;for(c=a.length;e<c;e++)a[e].mg()};f.prototype.pl=function(a,e,c){var b=a.qa(),d,g,m,l,n=this.Mb().Kb.gd,u,k,h;if(b.Aa)for(b.Aa=!1,N(b.e),d=0,l=a.e.length;d<l;d++)m=a.e[d],m.Ha(),u=m.k.ic(e,c,!0),k=m.k.ic(e,c,!1),m.ad(u,k)?b.e.push(m):n&&b.ga.push(m);else{g=0;h=n?b.ga:b.e;d=0;for(l=h.length;d<l;d++)m=h[d],m.Ha(),u=m.k.ic(e,c,!0),k=m.k.ic(e,c,!1),m.ad(u,k)&&(n?b.e.push(m):(b.e[g]=b.e[d],g++));h.length=g}a.Ve();return b.Om()};
|
||||
new xa;new wa(0,0,0,0);f.prototype.ds=function(a,e){if(!e)return!1;var c,b,d,g,m;c=0;for(b=a.Ya.length;c<b;c++)if(a.Ya[c].behavior instanceof e)return!0;if(!a.V)for(c=0,b=a.Ua.length;c<b;c++)for(m=a.Ua[c],d=0,g=m.Ya.length;d<g;d++)if(m.Ya[d].behavior instanceof e)return!0;return!1};f.prototype.no=function(a){return this.ds(a,kc.Ky)};f.prototype.oo=function(a){return this.ds(a,kc.My)};var R=-1;f.prototype.trigger=function(a,e,c){if(!this.Da)return!1;var b=this.Da.Nf;if(!b)return!1;var d=!1,g,m,l;R++;
|
||||
var n=b.qm;m=0;for(l=n.length;m<l;++m)g=this.$r(a,e,n[m],c),d=d||g;g=this.$r(a,e,b,c);R--;return d||g};f.prototype.$r=function(a,e,c,b){var d=!1,g,m,l,n;if(e)for(l=this.ko(a,e,e.type.name,c,b),d=d||l,n=e.type.Ua,g=0,m=n.length;g<m;++g)l=this.ko(a,e,n[g].name,c,b),d=d||l;else l=this.ko(a,e,"system",c,b),d=d||l;return d};f.prototype.ko=function(a,e,c,b,d){var g,m=!1,l=!1,l="undefined"!==typeof d,n=(l?b.yp:b.as)[c];if(!n)return m;var u=null;b=0;for(g=n.length;b<g;++b)if(n[b].method==a){u=n[b].Qh;break}if(!u)return m;
|
||||
var k;l?k=u[d]:k=u;if(!k)return null;b=0;for(g=k.length;b<g;b++)a=k[b][0],d=k[b][1],l=this.Cv(e,c,a,d),m=m||l;return m};f.prototype.Cv=function(a,e,c,b){var d,g,m=!1;this.lo++;var l=this.Mb().Kb;l&&this.Si(l.xf);var n=1<this.lo;this.Si(c.xf);n&&this.mx();var u=this.Yk(c);u.Kb=c;a&&(d=this.types[e].qa(),d.Aa=!1,N(d.e),d.e[0]=a,this.types[e].Ve());a=!0;if(c.parent){e=u.Ur;for(d=c.parent;d;)e.push(d),d=d.parent;e.reverse();d=0;for(g=e.length;d<g;d++)if(!e[d].Bx()){a=!1;break}}a&&(this.Rh++,c.gd?c.Ax(b):
|
||||
c.mb(),m=m||u.Zf);this.Sk();n&&this.bx();this.mg(c.xf);l&&this.mg(l.xf);this.lf&&0===this.Cd&&0===R&&!this.$m&&this.Tb();this.lo--;return m};f.prototype.Lv=function(){var a=this.Mb();return a.Kb.pb[a.ob]};f.prototype.mx=function(){this.zk++;this.zk>=this.qn.length&&this.qn.push([])};f.prototype.bx=function(){this.zk--};f.prototype.Gp=function(){return this.qn[this.zk]};f.prototype.Yk=function(a){this.Pj++;this.Pj>=this.um.length&&this.um.push(new Vb);var e=this.Mb();e.reset(a);return e};f.prototype.Sk=
|
||||
function(){this.Pj--};f.prototype.Mb=function(){return this.um[this.Pj]};f.prototype.nx=function(){this.Bk++;this.Bk>=this.sn.length&&this.sn.push(aa({name:void 0,index:0,Gb:!1}));var a=this.Mv();a.name=void 0;a.index=0;a.Gb=!1;return a};f.prototype.cx=function(){this.Bk--};f.prototype.Mv=function(){return this.sn[this.Bk]};f.prototype.Hp=function(a,e){for(var c,b,d,g,m,l;e;){c=0;for(b=e.nd.length;c<b;c++)if(l=e.nd[c],l instanceof Wb&&nb(a,l.name))return l;e=e.parent}c=0;for(b=this.re.length;c<b;c++)for(m=
|
||||
this.re[c],d=0,g=m.hf.length;d<g;d++)if(l=m.hf[d],l instanceof Wb&&nb(a,l.name))return l;return null};f.prototype.Ip=function(a){var e,c;e=0;for(c=this.Dd.length;e<c;e++)if(this.Dd[e].fa===a)return this.Dd[e];return null};f.prototype.dk=function(a){var e,c;e=0;for(c=this.D.length;e<c;e++)if(this.D[e].fa===a)return this.D[e];return null};f.prototype.Nv=function(a){var e,c;e=0;for(c=this.Ue.length;e<c;e++)if(this.Ue[e].fa===a)return this.Ue[e];return null};f.prototype.ru=function(a,e){this.$i=[a,e];
|
||||
this.Y=!0};f.prototype.lw=function(){var a=this,e=this.Wn,c=this.xe,d=this.uk,g=!1;this.Or&&(g=!0,e="__c2_continuouspreview",this.Or=!1);if(e.length){this.Tb();c=this.Fx();if(r()&&!this.ed)b(e,c,function(){ga("Saved state to IndexedDB storage ("+c.length+" bytes)");a.xe=c;a.trigger(X.prototype.g.Kl,null);c=a.xe="";g&&k()},function(b){try{localStorage.setItem("__c2save_"+e,c),ga("Saved state to WebStorage ("+c.length+" bytes)"),a.xe=c,a.trigger(X.prototype.g.Kl,null),c=a.xe="",g&&k()}catch(d){ga("Failed to save game state: "+
|
||||
b+"; "+d),a.trigger(X.prototype.g.Jo,null)}});else try{localStorage.setItem("__c2save_"+e,c),ga("Saved state to WebStorage ("+c.length+" bytes)"),a.xe=c,this.trigger(X.prototype.g.Kl,null),c=a.xe="",g&&k()}catch(m){ga("Error saving to WebStorage: "+m),a.trigger(X.prototype.g.Jo,null)}this.uk=this.Wn="";this.wb=null}if(d.length){if(r()&&!this.ed)p(d,function(e){e?(a.wb=e,ga("Loaded state from IndexedDB storage ("+a.wb.length+" bytes)")):(a.wb=localStorage.getItem("__c2save_"+d)||"",ga("Loaded state from WebStorage ("+
|
||||
a.wb.length+" bytes)"));a.bj=!1;a.wb||(a.wb=null,a.trigger(X.prototype.g.rj,null))},function(){a.wb=localStorage.getItem("__c2save_"+d)||"";ga("Loaded state from WebStorage ("+a.wb.length+" bytes)");a.bj=!1;a.wb||(a.wb=null,a.trigger(X.prototype.g.rj,null))});else{try{this.wb=localStorage.getItem("__c2save_"+d)||"",ga("Loaded state from WebStorage ("+this.wb.length+" bytes)")}catch(l){this.wb=null}this.bj=!1;a.wb||(a.wb=null,a.trigger(X.prototype.g.rj,null))}this.Wn=this.uk=""}null!==this.wb&&(this.Tb(),
|
||||
this.Hw(this.wb)?(this.xe=this.wb,this.trigger(X.prototype.g.ft,null),this.xe=""):a.trigger(X.prototype.g.rj,null),this.wb=null)};f.prototype.Fx=function(){var a,e,c,b,g,m,l,n={c2save:!0,version:1,rt:{time:this.Nb.Z,walltime:this.Oe.Z,timescale:this.vh,tickcount:this.ee,execcount:this.Rh,next_uid:this.Gi,running_layout:this.Da.fa,start_time_offset:Date.now()-this.ll},types:{},layouts:{},events:{groups:{},cnds:{},acts:{},vars:{}}};a=0;for(e=this.D.length;a<e;a++)if(g=this.D[a],!g.V&&!this.no(g)){m=
|
||||
{instances:[]};Wa(g.Ta)&&(m.ex=d(g.Ta));c=0;for(b=g.e.length;c<b;c++)m.instances.push(this.Vn(g.e[c]));n.types[g.fa.toString()]=m}a=0;for(e=this.Dd.length;a<e;a++)c=this.Dd[a],n.layouts[c.fa.toString()]=c.eb();b=n.events.groups;a=0;for(e=this.Ue.length;a<e;a++)c=this.Ue[a],b[c.fa.toString()]=this.ek[c.ai].$h;e=n.events.cnds;for(l in this.bf)this.bf.hasOwnProperty(l)&&(a=this.bf[l],Wa(a.Ta)&&(e[l]={ex:d(a.Ta)}));e=n.events.acts;for(l in this.Te)this.Te.hasOwnProperty(l)&&(a=this.Te[l],Wa(a.Ta)&&(e[l]=
|
||||
{ex:d(a.Ta)}));e=n.events.vars;for(l in this.Bh)this.Bh.hasOwnProperty(l)&&(a=this.Bh[l],a.nk||a.parent&&!a.mi||(e[l]=a.data));n.system=this.be.eb();return JSON.stringify(n)};f.prototype.tr=function(){var a,e,c,b,d,g;this.Ae={};a=0;for(e=this.D.length;a<e;a++)if(c=this.D[a],!c.V)for(b=0,d=c.e.length;b<d;b++)g=c.e[b],this.Ae[g.uid.toString()]=g};f.prototype.Hw=function(a){var e;try{e=JSON.parse(a)}catch(c){return!1}if(!e.c2save||1<e.version)return!1;this.gi=!0;a=e.rt;this.Nb.reset();this.Nb.Z=a.time;
|
||||
this.Oe.reset();this.Oe.Z=a.walltime||0;this.vh=a.timescale;this.ee=a.tickcount;this.Rh=a.execcount;this.ll=Date.now()-a.start_time_offset;var b=a.running_layout;if(b!==this.Da.fa)if(b=this.Ip(b))this.up(b);else return;var d,g,m,l,n,u,k;u=e.types;for(g in u)if(u.hasOwnProperty(g)&&(l=this.dk(parseInt(g,10)))&&!l.V&&!this.no(l)){u[g].ex?l.Ta=u[g].ex:Xa(l.Ta);n=l.e;m=u[g].instances;b=0;for(d=qa(n.length,m.length);b<d;b++)this.vk(n[b],m[b]);b=m.length;for(d=n.length;b<d;b++)this.ie(n[b]);b=n.length;
|
||||
for(d=m.length;b<d;b++){n=null;if(l.Ga.pf&&(n=this.Da.ck(m[b].w.l),!n))continue;n=this.df(l.bd,n,!1,0,0,!0);this.vk(n,m[b])}l.sh=!0}this.Tb();this.tr();d=e.layouts;for(g in d)d.hasOwnProperty(g)&&(b=this.Ip(parseInt(g,10)))&&b.ub(d[g]);d=e.events.groups;for(g in d)d.hasOwnProperty(g)&&(b=this.Nv(parseInt(g,10)))&&this.ek[b.ai]&&this.ek[b.ai].Hr(d[g]);b=e.events.cnds;for(g in this.bf)this.bf.hasOwnProperty(g)&&(b.hasOwnProperty(g)?this.bf[g].Ta=b[g].ex:this.bf[g].Ta={});b=e.events.acts;for(g in this.Te)this.Te.hasOwnProperty(g)&&
|
||||
(b.hasOwnProperty(g)?this.Te[g].Ta=b[g].ex:this.Te[g].Ta={});b=e.events.vars;for(g in b)b.hasOwnProperty(g)&&this.Bh.hasOwnProperty(g)&&(this.Bh[g].data=b[g]);this.Gi=a.next_uid;this.gi=!1;b=0;for(d=this.Wj.length;b<d;++b)n=this.Wj[b],this.trigger(Object.getPrototypeOf(n.type.Ga).g.oj,n);N(this.Wj);this.be.ub(e.system);b=0;for(d=this.D.length;b<d;b++)if(l=this.D[b],!l.V&&!this.no(l))for(e=0,g=l.e.length;e<g;e++){n=l.e[e];if(l.jc)for(u=n.Zh(),N(n.siblings),a=0,m=l.Dc.length;a<m;a++)k=l.Dc[a],l!==k&&
|
||||
n.siblings.push(k.e[u]);n.je&&n.je();if(n.S)for(a=0,m=n.S.length;a<m;a++)u=n.S[a],u.je&&u.je()}return this.Y=!0};f.prototype.Vn=function(a,e){var c,b,g,m,l;m=a.type;g=m.Ga;var n={};e?n.c2=!0:n.uid=a.uid;Wa(a.Ta)&&(n.ex=d(a.Ta));if(a.sb&&a.sb.length)for(n.ivs={},c=0,b=a.sb.length;c<b;c++)n.ivs[a.type.Tm[c].toString()]=a.sb[c];if(g.pf){g={x:a.x,y:a.y,w:a.width,h:a.height,l:a.k.fa,zi:a.Rd()};0!==a.j&&(g.a=a.j);1!==a.opacity&&(g.o=a.opacity);.5!==a.tc&&(g.hX=a.tc);.5!==a.uc&&(g.hY=a.uc);0!==a.Ub&&(g.bm=
|
||||
a.Ub);a.visible||(g.v=a.visible);a.Ih||(g.ce=a.Ih);-1!==a.Fi&&(g.mts=a.Fi);if(m.T.length)for(g.fx=[],c=0,b=m.T.length;c<b;c++)l=m.T[c],g.fx.push({name:l.name,active:a.Se[l.index],params:a.$a[l.index]});n.w=g}if(a.S&&a.S.length)for(n.behs={},c=0,b=a.S.length;c<b;c++)m=a.S[c],m.eb&&(n.behs[m.type.fa.toString()]=m.eb());a.eb&&(n.data=a.eb());return n};f.prototype.Pv=function(a,e){var c,b;c=0;for(b=a.Tm.length;c<b;c++)if(a.Tm[c]===e)return c;return-1};f.prototype.Kv=function(a,e){var c,b;c=0;for(b=a.S.length;c<
|
||||
b;c++)if(a.S[c].type.fa===e)return c;return-1};f.prototype.vk=function(a,e,c){var b,d,g,m,l;l=a.type;var n=l.Ga;if(c){if(!e.c2)return}else a.uid=e.uid;e.ex?a.Ta=e.ex:Xa(a.Ta);if(d=e.ivs)for(b in d)d.hasOwnProperty(b)&&(g=this.Pv(l,parseInt(b,10)),0>g||g>=a.sb.length||(m=d[b],null===m&&(m=NaN),a.sb[g]=m));if(n.pf){g=e.w;a.k.fa!==g.l&&(d=a.k,a.k=this.Da.ck(g.l),a.k?(d.ph(a,!0),a.k.Eh(a,!0),a.ta(),a.k.Xi(0)):(a.k=d,c||this.ie(a)));a.x=g.x;a.y=g.y;a.width=g.w;a.height=g.h;a.Jd=g.zi;a.j=g.hasOwnProperty("a")?
|
||||
g.a:0;a.opacity=g.hasOwnProperty("o")?g.o:1;a.tc=g.hasOwnProperty("hX")?g.hX:.5;a.uc=g.hasOwnProperty("hY")?g.hY:.5;a.visible=g.hasOwnProperty("v")?g.v:!0;a.Ih=g.hasOwnProperty("ce")?g.ce:!0;a.Fi=g.hasOwnProperty("mts")?g.mts:-1;a.Ub=g.hasOwnProperty("bm")?g.bm:0;a.Jh=ib(a.Ub);this.G&&jb(a,a.Ub,this.G);a.ta();if(g.hasOwnProperty("fx"))for(c=0,d=g.fx.length;c<d;c++)m=l.Em(g.fx[c].name),0>m||(a.Se[m]=g.fx[c].active,a.$a[m]=g.fx[c].params);a.Id()}if(l=e.behs)for(b in l)l.hasOwnProperty(b)&&(c=this.Kv(a,
|
||||
parseInt(b,10)),0>c||a.S[c].ub(l[b]));e.data&&a.ub(e.data)};f.prototype.zp=function(a,e,c){window.resolveLocalFileSystemURL(cordova.file.applicationDirectory+"www/"+a,function(a){a.file(e,c)},c)};f.prototype.Dv=function(a,e){this.zp("data.js",function(c){var b=new FileReader;b.onload=function(e){a(e.target.result)};b.onerror=e;b.readAsText(c)},e)};var T=[],M=0;f.prototype.tn=function(){if(T.length&&!(8<=M)){M++;var a=T.shift();this.wu(a.filename,a.Qx,a.Wu)}};f.prototype.Ap=function(a,e,c){var b=this;
|
||||
T.push({filename:a,Qx:function(a){M--;b.tn();e(a)},Wu:function(a){M--;b.tn();c(a)}});this.tn()};f.prototype.wu=function(a,e,c){this.zp(a,function(a){var c=new FileReader;c.onload=function(a){e(a.target.result)};c.readAsArrayBuffer(a)},c)};f.prototype.Ev=function(a,e,c){var b="",d=a.toLowerCase(),g=d.substr(d.length-4),d=d.substr(d.length-5);".mp4"===g?b="video/mp4":".webm"===d?b="video/webm":".m4a"===g?b="audio/mp4":".mp3"===g&&(b="audio/mpeg");this.Ap(a,function(a){a=URL.createObjectURL(new Blob([a],
|
||||
{type:b}));e(a)},c)};f.prototype.sw=function(a){return/^(?:[a-z]+:)?\/\//.test(a)||"data:"===a.substr(0,5)||"blob:"===a.substr(0,5)};f.prototype.Xn=function(a,e){this.lk&&!this.sw(e)?this.Ev(e,function(e){a.src=e},function(a){alert("Failed to load image: "+a)}):a.src=e};f.prototype.gl=function(a,e){"undefined"!==typeof a.imageSmoothingEnabled?a.imageSmoothingEnabled=e:(a.webkitImageSmoothingEnabled=e,a.mozImageSmoothingEnabled=e,a.msImageSmoothingEnabled=e)};Xb=function(a){return new f(document.getElementById(a))};
|
||||
Yb=function(a,e){return new f({dc:!0,width:a,height:e})};window.cr_createRuntime=Xb;window.cr_createDCRuntime=Yb;window.createCocoonJSRuntime=function(){window.c2cocoonjs=!0;var a=document.createElement("screencanvas")||document.createElement("canvas");a.Gh=!0;document.body.appendChild(a);a=new f(a);window.c2runtime=a;window.addEventListener("orientationchange",function(){window.c2runtime.setSize(window.innerWidth,window.innerHeight)});window.c2runtime.setSize(window.innerWidth,window.innerHeight);
|
||||
return a};window.createEjectaRuntime=function(){var a=new f(document.getElementById("canvas"));window.c2runtime=a;window.c2runtime.setSize(window.innerWidth,window.innerHeight);return a}})();window.cr_getC2Runtime=function(){var f=document.getElementById("c2canvas");return f?f.c2runtime:window.c2runtime?window.c2runtime:null};window.cr_getSnapshot=function(f,q){var r=window.cr_getC2Runtime();r&&r.ru(f,q)};
|
||||
window.cr_sizeCanvas=function(f,q){if(0!==f&&0!==q){var r=window.cr_getC2Runtime();r&&r.setSize(f,q)}};window.cr_setSuspended=function(f){var q=window.cr_getC2Runtime();q&&q.setSuspended(f)};
|
||||
(function(){function f(a,e){this.b=a;this.Nf=null;this.scrollX=this.b.Xa/2;this.scrollY=this.b.Wa/2;this.scale=1;this.j=0;this.Lg=!0;this.name=e[0];this.Yw=e[1];this.Xw=e[2];this.width=e[1];this.height=e[2];this.es=e[3];this.Mr=e[4];this.fa=e[5];var c=e[6],b,d;this.X=[];this.di=[];b=0;for(d=c.length;b<d;b++){var k=new Zb(this,c[b]);k.Rq=b;this.X.push(k)}c=e[7];this.mf=[];b=0;for(d=c.length;b<d;b++){var k=c[b],h=this.b.D[k[1]];h.bd||(h.bd=k);this.mf.push(k);-1===this.di.indexOf(h)&&this.di.push(h)}this.T=
|
||||
[];this.wa=[];this.He=!0;this.$a=[];b=0;for(d=e[8].length;b<d;b++)this.T.push({id:e[8][b][0],name:e[8][b][1],nb:-1,jd:!1,B:!0,index:b}),this.$a.push(e[8][b][2].slice(0));this.Id();this.oh=new wa(0,0,1,1);this.Pn=new wa(0,0,1,1);this.uf={}}function q(a,e){return a.Jd-e.Jd}function r(a,e){this.Bb=a;this.b=a.b;this.e=[];this.scale=1;this.j=0;this.qe=!1;this.Le=new wa(0,0,0,0);this.Zr=new xa;this.Ia=this.Fa=this.Ja=this.Ea=0;this.xg=!1;this.Pe=-1;this.lm=0;this.name=e[0];this.index=e[1];this.fa=e[2];
|
||||
this.visible=e[3];this.ud=e[4];this.Hd=e[5];this.Be=e[6];this.Ce=e[7];this.opacity=e[8];this.Zj=e[9];this.Yc=e[10];this.Qe=e[11];this.Ub=e[12];this.Su=e[13];this.Jh="source-over";this.$b=this.fc=0;this.Rb=null;this.ye=t();this.Gd=!0;this.Yg=new wa(0,0,-1,-1);this.Jb=new wa(0,0,-1,-1);this.Yc&&(this.Rb=new hb(this.b.Xa,this.b.Wa));this.Zd=!1;var c=e[14],b,d;this.Sr=[];this.Pc=[];this.Mh=[];b=0;for(d=c.length;b<d;b++){var k=c[b],h=this.b.D[k[1]];h.bd||(h.bd=k,h.pu=this.index);this.Pc.push(k);-1===this.Bb.di.indexOf(h)&&
|
||||
this.Bb.di.push(h)}Da(this.Sr,this.Pc);this.T=[];this.wa=[];this.He=!0;this.$a=[];b=0;for(d=e[15].length;b<d;b++)this.T.push({id:e[15][b][0],name:e[15][b][1],nb:-1,jd:!1,B:!0,index:b}),this.$a.push(e[15][b][2].slice(0));this.Id();this.oh=new wa(0,0,1,1);this.Pn=new wa(0,0,1,1)}function t(){return d.length?d.pop():[]}function b(a){N(a);d.push(a)}f.prototype.Ex=function(a){var e=a.type.fa.toString();this.uf.hasOwnProperty(e)||(this.uf[e]=[]);this.uf[e].push(this.b.Vn(a))};f.prototype.Np=function(){var a=
|
||||
this.X[0];return!a.Hd&&1===a.opacity&&!a.Zj&&a.visible};f.prototype.Id=function(){N(this.wa);this.He=!0;var a,e,c;a=0;for(e=this.T.length;a<e;a++)c=this.T[a],c.B&&(this.wa.push(c),c.jd||(this.He=!1))};f.prototype.Dm=function(a){var e,c,b;e=0;for(c=this.T.length;e<c;e++)if(b=this.T[e],b.name===a)return b;return null};var p=[],k=!0;f.prototype.co=function(){this.Mr&&(this.Nf=this.b.vm[this.Mr],this.Nf.ro());this.b.Da=this;this.width=this.Yw;this.height=this.Xw;this.scrollX=this.b.Xa/2;this.scrollY=
|
||||
this.b.Wa/2;var a,e,c,b,d,h,w;a=0;for(c=this.b.D.length;a<c;a++)if(e=this.b.D[a],!e.V)for(d=e.e,e=0,b=d.length;e<b;e++)if(h=d[e],h.k){var m=h.k.Rq;m>=this.X.length&&(m=this.X.length-1);h.k=this.X[m];-1===h.k.e.indexOf(h)&&h.k.e.push(h);h.k.xg=!0}if(!k)for(a=0,c=this.X.length;a<c;++a)this.X[a].e.sort(q);N(p);this.eu();a=0;for(c=this.X.length;a<c;a++)h=this.X[a],h.ou(),h.Bl();d=!1;if(!this.Lg){for(w in this.uf)if(this.uf.hasOwnProperty(w)&&(e=this.b.dk(parseInt(w,10)))&&!e.V&&this.b.oo(e)){b=this.uf[w];
|
||||
a=0;for(c=b.length;a<c;a++){h=null;if(e.Ga.pf&&(h=this.ck(b[a].w.l),!h))continue;h=this.b.df(e.bd,h,!1,0,0,!0);this.b.vk(h,b[a]);d=!0;p.push(h)}N(b)}a=0;for(c=this.X.length;a<c;a++)this.X[a].e.sort(q),this.X[a].xg=!0}d&&(this.b.Tb(),this.b.tr());for(a=0;a<p.length;a++)if(h=p[a],h.type.jc)for(c=h.Zh(),e=0,b=h.type.Dc.length;e<b;e++)w=h.type.Dc[e],h.type!==w&&(w.e.length>c?h.siblings.push(w.e[c]):w.bd&&(d=this.b.df(w.bd,h.k,!0,h.x,h.y,!0),this.b.Tb(),w.zl(),h.siblings.push(d),p.push(d)));a=0;for(c=
|
||||
this.mf.length;a<c;a++)h=this.mf[a],e=this.b.D[h[1]],e.jc||this.b.df(this.mf[a],null,!0);this.b.Hh=null;this.b.Tb();if(this.b.Za&&!this.b.Ca)for(a=0,c=this.b.D.length;a<c;a++)w=this.b.D[a],!w.V&&w.e.length&&w.Kn&&w.Kn(this.b.Za);if(this.b.gi)Da(this.b.Wj,p);else for(a=0,c=p.length;a<c;a++)h=p[a],this.b.trigger(Object.getPrototypeOf(h.type.Ga).g.oj,h);N(p);this.b.gi||this.b.trigger(X.prototype.g.Eo,null);this.Lg=!1};f.prototype.nu=function(){var a,e,c,b,d;e=a=0;for(c=this.mf.length;a<c;a++)b=this.mf[a],
|
||||
d=this.b.D[b[1]],d.global?d.jc||this.b.df(b,null,!0):(this.mf[e]=b,e++);Ca(this.mf,e)};f.prototype.Px=function(){this.b.gi||this.b.trigger(X.prototype.g.et,null);this.b.Wm=!0;N(this.b.be.Ac);var a,e,c,b,d,h;if(!this.Lg)for(a=0,e=this.X.length;a<e;a++)for(this.X[a].to(),d=this.X[a].e,c=0,b=d.length;c<b;c++)h=d[c],h.type.global||this.b.oo(h.type)&&this.Ex(h);a=0;for(e=this.X.length;a<e;a++){d=this.X[a].e;c=0;for(b=d.length;c<b;c++)h=d[c],h.type.global||this.b.ie(h);this.b.Tb();N(d);this.X[a].xg=!0}a=
|
||||
0;for(e=this.b.D.length;a<e;a++)if(d=this.b.D[a],!(d.global||d.Ga.pf||d.Ga.kl||d.V)){c=0;for(b=d.e.length;c<b;c++)this.b.ie(d.e[c]);this.b.Tb()}k=!1;this.b.Wm=!1};new wa(0,0,0,0);f.prototype.zd=function(a){var e,c=a,b=!1,d=!this.b.Nc;d&&(this.b.tk||(this.b.tk=document.createElement("canvas"),e=this.b.tk,e.width=this.b.M,e.height=this.b.L,this.b.nq=e.getContext("2d"),b=!0),e=this.b.tk,c=this.b.nq,e.width!==this.b.M&&(e.width=this.b.M,b=!0),e.height!==this.b.L&&(e.height=this.b.L,b=!0),b&&this.b.gl(c,
|
||||
this.b.Ra));c.globalAlpha=1;c.globalCompositeOperation="source-over";this.b.np&&!this.Np()&&c.clearRect(0,0,this.b.M,this.b.L);var h,k,b=0;for(h=this.X.length;b<h;b++)k=this.X[b],k.visible&&0<k.opacity&&11!==k.Ub&&(k.e.length||!k.Hd)?k.zd(c):k.Bl();d&&a.drawImage(e,0,0,this.b.width,this.b.height)};f.prototype.Hg=function(a){a.Gr(!0);this.b.kb||(this.b.kb=a.Mc(this.b.M,this.b.L,this.b.Ra));if(this.b.kb.Gf!==this.b.M||this.b.kb.Ff!==this.b.L)a.deleteTexture(this.b.kb),this.b.kb=a.Mc(this.b.M,this.b.L,
|
||||
this.b.Ra);a.ld(this.b.kb);this.b.Nc||a.qg(this.b.M,this.b.L);var e,c;for(e=this.X.length-1;0<=e;--e)c=this.X[e],c.visible&&1===c.opacity&&c.He&&0===c.Ub&&(c.e.length||!c.Hd)?c.Hg(a):c.Bl();a.Gr(!1)};f.prototype.Ec=function(a){var e=0<this.wa.length||this.b.zh||!this.b.Nc||this.b.Pa;if(e){this.b.kb||(this.b.kb=a.Mc(this.b.M,this.b.L,this.b.Ra));if(this.b.kb.Gf!==this.b.M||this.b.kb.Ff!==this.b.L)a.deleteTexture(this.b.kb),this.b.kb=a.Mc(this.b.M,this.b.L,this.b.Ra);a.ld(this.b.kb);this.b.Nc||a.qg(this.b.M,
|
||||
this.b.L)}else this.b.kb&&(a.ld(null),a.deleteTexture(this.b.kb),this.b.kb=null);this.b.np&&!this.Np()&&a.clear(0,0,0,0);var c,b,d;c=0;for(b=this.X.length;c<b;c++)d=this.X[c],d.visible&&0<d.opacity&&(d.e.length||!d.Hd)?d.Ec(a):d.Bl();e&&(0===this.wa.length||1===this.wa.length&&this.b.Nc?(1===this.wa.length?(e=this.wa[0].index,a.zc(this.wa[0].nb),a.rh(null,1/this.b.M,1/this.b.L,0,0,1,1,this.scale,this.j,0,0,this.b.M/2,this.b.L/2,this.b.Nb.Z,this.$a[e]),a.Vk(this.wa[0].nb)&&(this.b.Y=!0)):a.zc(0),this.b.Nc||
|
||||
a.qg(this.b.width,this.b.height),a.ld(null),a.Fr(!1),a.pg(1),a.Kc(this.b.kb),a.Dr(),a.kd(),a.Xc(),e=this.b.width/2,c=this.b.height/2,a.Ti(-e,c,e,c,e,-c,-e,-c),a.Kc(null),a.Fr(!0)):this.Qn(a,null,null,null))};f.prototype.Yh=function(){return 0<this.wa.length||this.b.zh||!this.b.Nc||this.b.Pa?this.b.kb:null};f.prototype.Jp=function(){var a=this.X[0].sc(),e,c,b;e=1;for(c=this.X.length;e<c;e++)b=this.X[e],(0!==b.Be||0!==b.Ce)&&b.sc()<a&&(a=b.sc());return a};f.prototype.Br=function(a){if(!this.es){var e=
|
||||
1/this.Jp()*this.b.M/2;a>this.width-e&&(a=this.width-e);a<e&&(a=e)}this.scrollX!==a&&(this.scrollX=a,this.b.Y=!0)};f.prototype.Cr=function(a){if(!this.es){var e=1/this.Jp()*this.b.L/2;a>this.height-e&&(a=this.height-e);a<e&&(a=e)}this.scrollY!==a&&(this.scrollY=a,this.b.Y=!0)};f.prototype.eu=function(){this.Br(this.scrollX);this.Cr(this.scrollY)};f.prototype.Qn=function(a,e,c,b){var d=c?c.wa:e?e.wa:this.wa,k=1,h=0,m=0,u=0,f=this.b.M,p=this.b.L;c?(k=c.k.sc(),h=c.k.rb(),m=c.k.Ea,u=c.k.Fa,f=c.k.Ja,p=
|
||||
c.k.Ia):e&&(k=e.sc(),h=e.rb(),m=e.Ea,u=e.Fa,f=e.Ja,p=e.Ia);var q=this.b.Bm,t,r,y,F,G=0,K=1,R,T,M=this.b.M,v=this.b.L,C=M/2,S=v/2,I=e?e.oh:this.oh,D=e?e.Pn:this.Pn,H=0,z=0,J=0,B=0,O=M,ja=M,P=v,ba=v,U=y=0;F=c?c.k.rb():0;if(c){t=0;for(r=d.length;t<r;t++)y+=a.Tv(d[t].nb),U+=a.Uv(d[t].nb);B=c.xa;H=e.Va(B.left,B.top,!0,!0);J=e.Va(B.left,B.top,!1,!0);O=e.Va(B.right,B.bottom,!0,!0);P=e.Va(B.right,B.bottom,!1,!0);0!==F&&(t=e.Va(B.right,B.top,!0,!0),r=e.Va(B.right,B.top,!1,!0),z=e.Va(B.left,B.bottom,!0,!0),
|
||||
B=e.Va(B.left,B.bottom,!1,!0),F=Math.min(H,O,t,z),O=Math.max(H,O,t,z),H=F,F=Math.min(J,P,r,B),P=Math.max(J,P,r,B),J=F);H-=y;J-=U;O+=y;P+=U;D.left=H/M;D.top=1-J/v;D.right=O/M;D.bottom=1-P/v;z=H=ta(H);B=J=ta(J);ja=O=ua(O);ba=P=ua(P);z-=y;B-=U;ja+=y;ba+=U;0>H&&(H=0);0>J&&(J=0);O>M&&(O=M);P>v&&(P=v);0>z&&(z=0);0>B&&(B=0);ja>M&&(ja=M);ba>v&&(ba=v);I.left=H/M;I.top=1-J/v;I.right=O/M;I.bottom=1-P/v}else I.left=D.left=0,I.top=D.top=0,I.right=D.right=1,I.bottom=D.bottom=1;U=c&&(a.Qi(d[0].nb)||0!==y||0!==U||
|
||||
1!==c.opacity||c.type.Ga.Kq)||e&&!c&&1!==e.opacity;a.Dr();if(U){q[G]||(q[G]=a.Mc(M,v,this.b.Ra));if(q[G].Gf!==M||q[G].Ff!==v)a.deleteTexture(q[G]),q[G]=a.Mc(M,v,this.b.Ra);a.zc(0);a.ld(q[G]);T=ba-B;a.clearRect(z,v-B-T,ja-z,T);c?c.Ec(a):(a.Kc(this.b.tb),a.pg(e.opacity),a.kd(),a.translate(-C,-S),a.Xc(),a.Fe(H,P,O,P,O,J,H,J,I));D.left=D.top=0;D.right=D.bottom=1;c&&(F=I.top,I.top=I.bottom,I.bottom=F);G=1;K=0}a.pg(1);y=d.length-1;var ya=a.Mn(d[y].nb)||!e&&!c&&!this.b.Nc;t=F=0;for(r=d.length;t<r;t++){q[G]||
|
||||
(q[G]=a.Mc(M,v,this.b.Ra));if(q[G].Gf!==M||q[G].Ff!==v)a.deleteTexture(q[G]),q[G]=a.Mc(M,v,this.b.Ra);a.zc(d[t].nb);F=d[t].index;a.Vk(d[t].nb)&&(this.b.Y=!0);0!=t||U?(a.rh(b,1/M,1/v,D.left,D.top,D.right,D.bottom,k,h,m,u,(m+f)/2,(u+p)/2,this.b.Nb.Z,c?c.$a[F]:e?e.$a[F]:this.$a[F]),a.Kc(null),t!==y||ya?(a.ld(q[G]),T=ba-B,R=v-B-T,a.clearRect(z,R,ja-z,T)):(c?a.wf(c.fc,c.$b):e&&a.wf(e.fc,e.$b),a.ld(b)),a.Kc(q[K]),a.kd(),a.translate(-C,-S),a.Xc(),a.Fe(H,P,O,P,O,J,H,J,I),t!==y||ya||a.Kc(null)):(a.ld(q[G]),
|
||||
T=ba-B,R=v-B-T,a.clearRect(z,R,ja-z,T),c?(c.hb&&c.hb.ua?(R=c.hb.ua,K=1/R.width,R=1/R.height):(K=1/c.width,R=1/c.height),a.rh(b,K,R,D.left,D.top,D.right,D.bottom,k,h,m,u,(m+f)/2,(u+p)/2,this.b.Nb.Z,c.$a[F]),c.Ec(a)):(a.rh(b,1/M,1/v,0,0,1,1,k,h,m,u,(m+f)/2,(u+p)/2,this.b.Nb.Z,e?e.$a[F]:this.$a[F]),a.Kc(e?this.b.tb:this.b.kb),a.kd(),a.translate(-C,-S),a.Xc(),a.Fe(H,P,O,P,O,J,H,J,I)),D.left=D.top=0,D.right=D.bottom=1,c&&!ya&&(F=P,P=J,J=F));G=0===G?1:0;K=0===G?1:0}ya&&(a.zc(0),c?a.wf(c.fc,c.$b):e?a.wf(e.fc,
|
||||
e.$b):this.b.Nc||(a.qg(this.b.width,this.b.height),C=this.b.width/2,S=this.b.height/2,J=H=0,O=this.b.width,P=this.b.height),a.ld(b),a.Kc(q[K]),a.kd(),a.translate(-C,-S),a.Xc(),c&&1===d.length&&!U?a.Fe(H,J,O,J,O,P,H,P,I):a.Fe(H,P,O,P,O,J,H,J,I),a.Kc(null))};f.prototype.ck=function(a){var e,c;e=0;for(c=this.X.length;e<c;e++)if(this.X[e].fa===a)return this.X[e];return null};f.prototype.eb=function(){var a,e,c,b={sx:this.scrollX,sy:this.scrollY,s:this.scale,a:this.j,w:this.width,h:this.height,fv:this.Lg,
|
||||
persist:this.uf,fx:[],layers:{}};a=0;for(e=this.T.length;a<e;a++)c=this.T[a],b.fx.push({name:c.name,active:c.B,params:this.$a[c.index]});a=0;for(e=this.X.length;a<e;a++)c=this.X[a],b.layers[c.fa.toString()]=c.eb();return b};f.prototype.ub=function(a){var e,c,b,d;this.scrollX=a.sx;this.scrollY=a.sy;this.scale=a.s;this.j=a.a;this.width=a.w;this.height=a.h;this.uf=a.persist;"undefined"!==typeof a.fv&&(this.Lg=a.fv);var k=a.fx;e=0;for(c=k.length;e<c;e++)if(b=this.Dm(k[e].name))b.B=k[e].active,this.$a[b.index]=
|
||||
k[e].params;this.Id();e=a.layers;for(d in e)e.hasOwnProperty(d)&&(a=this.ck(parseInt(d,10)))&&a.ub(e[d])};Lb=f;r.prototype.Id=function(){N(this.wa);this.He=!0;var a,e,c;a=0;for(e=this.T.length;a<e;a++)c=this.T[a],c.B&&(this.wa.push(c),c.jd||(this.He=!1))};r.prototype.Dm=function(a){var e,c,b;e=0;for(c=this.T.length;e<c;e++)if(b=this.T[e],b.name===a)return b;return null};r.prototype.ou=function(){var a,e,c,b,d,k;e=a=0;for(c=this.Pc.length;a<c;a++){b=this.Pc[a];d=this.b.D[b[1]];k=this.b.oo(d);d=!0;
|
||||
if(!k||this.Bb.Lg){b=this.b.df(b,this,!0);if(!b)continue;p.push(b);b.type.global&&(d=!1,this.Mh.push(b.uid))}d&&(this.Pc[e]=this.Pc[a],e++)}this.Pc.length=e;this.b.Tb();!this.b.C&&this.T.length&&(this.Ub=this.Su);this.Jh=ib(this.Ub);this.b.G&&jb(this,this.Ub,this.b.G);this.Gd=!0};r.prototype.ph=function(a,e){var c=Fa(this.e,a);0>c||(e&&this.Yc&&a.xc&&a.xc.right>=a.xc.left&&(a.Ha(),this.Rb.update(a,a.xc,null),a.xc.set(0,0,-1,-1)),c===this.e.length-1?this.e.pop():(Ba(this.e,c),this.Xi(c)),this.Gd=!0)};
|
||||
r.prototype.Eh=function(a,c){a.Jd=this.e.length;this.e.push(a);c&&this.Yc&&a.xc&&a.ta();this.Gd=!0};r.prototype.jx=function(a){this.e.unshift(a);this.Xi(0)};r.prototype.Nw=function(a,c,b){var d=a.Rd();c=c.Rd();Ba(this.e,d);d<c&&c--;b&&c++;c===this.e.length?this.e.push(a):this.e.splice(c,0,a);this.Xi(d<c?d:c)};r.prototype.Xi=function(a){-1===this.Pe?this.Pe=a:a<this.Pe&&(this.Pe=a);this.Gd=this.xg=!0};r.prototype.to=function(){if(this.xg){-1===this.Pe&&(this.Pe=0);var a,c,b;if(this.Yc)for(a=this.Pe,
|
||||
c=this.e.length;a<c;++a)b=this.e[a],b.Jd=a,this.Rb.Kw(b.xc);else for(a=this.Pe,c=this.e.length;a<c;++a)this.e[a].Jd=a;this.xg=!1;this.Pe=-1}};r.prototype.sc=function(a){return this.Qv()*(this.b.Nc||a?this.b.Fh:1)};r.prototype.Qv=function(){return(this.scale*this.Bb.scale-1)*this.Qe+1};r.prototype.rb=function(){return this.qe?0:La(this.Bb.j+this.j)};var d=[],h=[],c=[];r.prototype.Km=function(){this.to();this.Rb.rr(this.Ea,this.Fa,this.Ja,this.Ia,c);if(!c.length)return t();if(1===c.length){var a=t();
|
||||
Da(a,c[0]);N(c);return a}for(var e=!0;1<c.length;){for(var a=c,d=void 0,g=void 0,n=void 0,k=void 0,f=void 0,d=0,g=a.length;d<g-1;d+=2){var n=a[d],k=a[d+1],f=t(),m=n,u=k,p=f,q=0,r=0,E=0,x=m.length,y=u.length,F=void 0,G=void 0;for(p.length=x+y;q<x&&r<y;++E)F=m[q],G=u[r],F.Jd<G.Jd?(p[E]=F,++q):(p[E]=G,++r);for(;q<x;++q,++E)p[E]=m[q];for(;r<y;++r,++E)p[E]=u[r];e||(b(n),b(k));h.push(f)}1===g%2&&(e?(n=t(),Da(n,a[g-1]),h.push(n)):h.push(a[g-1]));Da(a,h);N(h);e=!1}a=c[0];N(c);return a};r.prototype.zd=function(a){this.Zd=
|
||||
this.Zj||1!==this.opacity||0!==this.Ub;var c=this.b.canvas,d=a,g=!1;this.Zd&&(this.b.sk||(this.b.sk=document.createElement("canvas"),c=this.b.sk,c.width=this.b.M,c.height=this.b.L,this.b.mq=c.getContext("2d"),g=!0),c=this.b.sk,d=this.b.mq,c.width!==this.b.M&&(c.width=this.b.M,g=!0),c.height!==this.b.L&&(c.height=this.b.L,g=!0),g&&this.b.gl(d,this.b.Ra),this.Hd&&d.clearRect(0,0,this.b.M,this.b.L));d.globalAlpha=1;d.globalCompositeOperation="source-over";this.Hd||(d.fillStyle="rgb("+this.ud[0]+","+
|
||||
this.ud[1]+","+this.ud[2]+")",d.fillRect(0,0,this.b.M,this.b.L));d.save();this.qe=!0;var g=this.ic(0,0,!0,!0),n=this.ic(0,0,!1,!0);this.qe=!1;this.b.Ed&&(g=Math.round(g),n=Math.round(n));this.bl(g,n,d);var k=this.sc();d.scale(k,k);d.translate(-g,-n);this.Yc?(this.Jb.left=this.Rb.pc(this.Ea),this.Jb.top=this.Rb.qc(this.Fa),this.Jb.right=this.Rb.pc(this.Ja),this.Jb.bottom=this.Rb.qc(this.Ia),this.Gd||!this.Jb.Ph(this.Yg)?(b(this.ye),g=this.Km(),this.Gd=!1,this.Yg.Kh(this.Jb)):g=this.ye):g=this.e;for(var h,
|
||||
m=null,n=0,k=g.length;n<k;++n)h=g[n],h!==m&&(this.Mu(h,d),m=h);this.Yc&&(this.ye=g);d.restore();this.Zd&&(a.globalCompositeOperation=this.Jh,a.globalAlpha=this.opacity,a.drawImage(c,0,0))};r.prototype.Mu=function(a,c){if(a.visible&&0!==a.width&&0!==a.height){a.Ha();var b=a.xa;b.right<this.Ea||b.bottom<this.Fa||b.left>this.Ja||b.top>this.Ia||(c.globalCompositeOperation=a.Jh,a.zd(c))}};r.prototype.Bl=function(){this.qe=!0;var a=this.ic(0,0,!0,!0),c=this.ic(0,0,!1,!0);this.qe=!1;this.b.Ed&&(a=Math.round(a),
|
||||
c=Math.round(c));this.bl(a,c,null)};r.prototype.bl=function(a,c,b){var d=this.sc();this.Ea=a;this.Fa=c;this.Ja=a+1/d*this.b.M;this.Ia=c+1/d*this.b.L;this.Ea>this.Ja&&(a=this.Ea,this.Ea=this.Ja,this.Ja=a);this.Fa>this.Ia&&(a=this.Fa,this.Fa=this.Ia,this.Ia=a);a=this.rb();0!==a&&(b&&(b.translate(this.b.M/2,this.b.L/2),b.rotate(-a),b.translate(this.b.M/-2,this.b.L/-2)),this.Le.set(this.Ea,this.Fa,this.Ja,this.Ia),this.Le.offset((this.Ea+this.Ja)/-2,(this.Fa+this.Ia)/-2),this.Zr.Kr(this.Le,a),this.Zr.jp(this.Le),
|
||||
this.Le.offset((this.Ea+this.Ja)/2,(this.Fa+this.Ia)/2),this.Ea=this.Le.left,this.Fa=this.Le.top,this.Ja=this.Le.right,this.Ia=this.Le.bottom)};r.prototype.Hg=function(a){if(this.Zd=this.Zj){this.b.tb||(this.b.tb=a.Mc(this.b.M,this.b.L,this.b.Ra));if(this.b.tb.Gf!==this.b.M||this.b.tb.Ff!==this.b.L)a.deleteTexture(this.b.tb),this.b.tb=a.Mc(this.b.M,this.b.L,this.b.Ra);a.ld(this.b.tb)}this.qe=!0;var c=this.ic(0,0,!0,!0),d=this.ic(0,0,!1,!0);this.qe=!1;this.b.Ed&&(c=Math.round(c),d=Math.round(d));this.bl(c,
|
||||
d,null);c=this.sc();a.kd();a.scale(c,c);a.cl(-this.rb());a.translate((this.Ea+this.Ja)/-2,(this.Fa+this.Ia)/-2);a.Xc();this.Yc?(this.Jb.left=this.Rb.pc(this.Ea),this.Jb.top=this.Rb.qc(this.Fa),this.Jb.right=this.Rb.pc(this.Ja),this.Jb.bottom=this.Rb.qc(this.Ia),this.Gd||!this.Jb.Ph(this.Yg)?(b(this.ye),c=this.Km(),this.Gd=!1,this.Yg.Kh(this.Jb)):c=this.ye):c=this.e;for(var g,n=null,d=c.length-1;0<=d;--d)g=c[d],g!==n&&(this.Ou(c[d],a),n=g);this.Yc&&(this.ye=c);this.Hd||(this.lm=this.b.Lf++,a.hl(this.lm),
|
||||
a.Er(1,1,1),a.Dp(),a.wx())};r.prototype.Ec=function(a){var c=0,d=0;if(this.Zd=this.Zj||1!==this.opacity||0<this.wa.length||0!==this.Ub){this.b.tb||(this.b.tb=a.Mc(this.b.M,this.b.L,this.b.Ra));if(this.b.tb.Gf!==this.b.M||this.b.tb.Ff!==this.b.L)a.deleteTexture(this.b.tb),this.b.tb=a.Mc(this.b.M,this.b.L,this.b.Ra);a.ld(this.b.tb);this.Hd&&a.clear(0,0,0,0)}this.Hd||(this.b.Pa?(a.hl(this.lm),a.Er(this.ud[0]/255,this.ud[1]/255,this.ud[2]/255),a.Dp(),a.Kx()):a.clear(this.ud[0]/255,this.ud[1]/255,this.ud[2]/
|
||||
255,1));this.qe=!0;var g=this.ic(0,0,!0,!0),c=this.ic(0,0,!1,!0);this.qe=!1;this.b.Ed&&(g=Math.round(g),c=Math.round(c));this.bl(g,c,null);g=this.sc();a.kd();a.scale(g,g);a.cl(-this.rb());a.translate((this.Ea+this.Ja)/-2,(this.Fa+this.Ia)/-2);a.Xc();this.Yc?(this.Jb.left=this.Rb.pc(this.Ea),this.Jb.top=this.Rb.qc(this.Fa),this.Jb.right=this.Rb.pc(this.Ja),this.Jb.bottom=this.Rb.qc(this.Ia),this.Gd||!this.Jb.Ph(this.Yg)?(b(this.ye),c=this.Km(),this.Gd=!1,this.Yg.Kh(this.Jb)):c=this.ye):c=this.e;var n,
|
||||
k,h=null,d=0;for(n=c.length;d<n;++d)k=c[d],k!==h&&(this.Nu(c[d],a),h=k);this.Yc&&(this.ye=c);this.Zd&&(c=this.wa.length?this.wa[0].nb:0,d=this.wa.length?this.wa[0].index:0,0===this.wa.length||1===this.wa.length&&!a.Mn(c)&&1===this.opacity?(1===this.wa.length?(a.zc(c),a.rh(this.Bb.Yh(),1/this.b.M,1/this.b.L,0,0,1,1,g,this.rb(),this.Ea,this.Fa,(this.Ea+this.Ja)/2,(this.Fa+this.Ia)/2,this.b.Nb.Z,this.$a[d]),a.Vk(c)&&(this.b.Y=!0)):a.zc(0),a.ld(this.Bb.Yh()),a.pg(this.opacity),a.Kc(this.b.tb),a.wf(this.fc,
|
||||
this.$b),a.kd(),a.Xc(),g=this.b.M/2,c=this.b.L/2,a.Ti(-g,c,g,c,g,-c,-g,-c),a.Kc(null)):this.Bb.Qn(a,this,null,this.Bb.Yh()))};r.prototype.Nu=function(a,c){if(a.visible&&0!==a.width&&0!==a.height){a.Ha();var b=a.xa;b.right<this.Ea||b.bottom<this.Fa||b.left>this.Ja||b.top>this.Ia||(c.hl(a.Lf),a.ks?this.Pu(a,c):(c.zc(0),c.wf(a.fc,a.$b),a.Ec(c)))}};r.prototype.Ou=function(a,c){if(a.visible&&0!==a.width&&0!==a.height){a.Ha();var b=a.xa;b.right<this.Ea||b.bottom<this.Fa||b.left>this.Ja||b.top>this.Ia||
|
||||
(a.Lf=this.b.Lf++,0===a.Ub&&1===a.opacity&&a.He&&a.Hg&&(c.hl(a.Lf),a.Hg(c)))}};r.prototype.Pu=function(a,c){var b=a.wa[0].nb,d=a.wa[0].index,n=this.sc();if(1!==a.wa.length||c.Mn(b)||c.lx(b)||(a.j||a.k.rb())&&c.Qi(b)||1!==a.opacity||a.type.Ga.Kq)this.Bb.Qn(c,this,a,this.Zd?this.b.tb:this.Bb.Yh()),c.kd(),c.scale(n,n),c.cl(-this.rb()),c.translate((this.Ea+this.Ja)/-2,(this.Fa+this.Ia)/-2),c.Xc();else{c.zc(b);c.wf(a.fc,a.$b);c.Vk(b)&&(this.b.Y=!0);var k=0,h=0,m=0,u=0;c.Qi(b)&&(u=a.xa,k=this.Va(u.left,
|
||||
u.top,!0,!0),h=this.Va(u.left,u.top,!1,!0),m=this.Va(u.right,u.bottom,!0,!0),u=this.Va(u.right,u.bottom,!1,!0),k=k/windowWidth,h=1-h/windowHeight,m=m/windowWidth,u=1-u/windowHeight);var f;a.hb&&a.hb.ua?(f=a.hb.ua,b=1/f.width,f=1/f.height):(b=1/a.width,f=1/a.height);c.rh(this.Zd?this.b.tb:this.Bb.Yh(),b,f,k,h,m,u,n,this.rb(),this.Ea,this.Fa,(this.Ea+this.Ja)/2,(this.Fa+this.Ia)/2,this.b.Nb.Z,a.$a[d]);a.Ec(c)}};r.prototype.ic=function(a,c,b,d){var n=this.b.devicePixelRatio;this.b.Xf&&(a*=n,c*=n);var n=
|
||||
this.b.jr,k=this.b.kr,n=(this.Bb.scrollX-n)*this.Be+n,k=(this.Bb.scrollY-k)*this.Ce+k,h=n,m=k,u=1/this.sc(!d);d?(h-=this.b.M*u/2,m-=this.b.L*u/2):(h-=this.b.width*u/2,m-=this.b.height*u/2);h+=a*u;m+=c*u;c=this.rb();0!==c&&(h-=n,m-=k,a=Math.cos(c),c=Math.sin(c),d=h*a-m*c,m=m*a+h*c,h=d+n,m+=k);return b?h:m};r.prototype.Va=function(a,c,b,d){var n=this.b.jr,k=this.b.kr,h=(this.Bb.scrollX-n)*this.Be+n,m=(this.Bb.scrollY-k)*this.Ce+k,k=h,n=m,u=this.rb();if(0!==u){a-=h;c-=m;var f=Math.cos(-u),u=Math.sin(-u),
|
||||
p=a*f-c*u;c=c*f+a*u;a=p+h;c+=m}h=1/this.sc(!d);d?(k-=this.b.M*h/2,n-=this.b.L*h/2):(k-=this.b.width*h/2,n-=this.b.height*h/2);k=(a-k)/h;n=(c-n)/h;a=this.b.devicePixelRatio;this.b.Xf&&!d&&(k/=a,n/=a);return b?k:n};r.prototype.eb=function(){var a,c,b,d={s:this.scale,a:this.j,vl:this.Ea,vt:this.Fa,vr:this.Ja,vb:this.Ia,v:this.visible,bc:this.ud,t:this.Hd,px:this.Be,py:this.Ce,o:this.opacity,zr:this.Qe,fx:[],cg:this.Mh,instances:[]};a=0;for(c=this.T.length;a<c;a++)b=this.T[a],d.fx.push({name:b.name,active:b.B,
|
||||
params:this.$a[b.index]});return d};r.prototype.ub=function(a){var c,b,d;this.scale=a.s;this.j=a.a;this.Ea=a.vl;this.Fa=a.vt;this.Ja=a.vr;this.Ia=a.vb;this.visible=a.v;this.ud=a.bc;this.Hd=a.t;this.Be=a.px;this.Ce=a.py;this.opacity=a.o;this.Qe=a.zr;this.Mh=a.cg||[];Da(this.Pc,this.Sr);var n=new da;c=0;for(d=this.Mh.length;c<d;++c)n.add(this.Mh[c]);b=c=0;for(d=this.Pc.length;c<d;++c)n.contains(this.Pc[c][2])||(this.Pc[b]=this.Pc[c],++b);Ca(this.Pc,b);b=a.fx;c=0;for(d=b.length;c<d;c++)if(a=this.Dm(b[c].name))a.B=
|
||||
b[c].active,this.$a[a.index]=b[c].params;this.Id();this.e.sort(q);this.xg=!0};Zb=r})();
|
||||
(function(){function f(a,c){var b,e=a.length;switch(e){case 0:return!0;case 1:return a[0]===c[0];case 2:return a[0]===c[0]&&a[1]===c[1];default:for(b=0;b<e;b++)if(a[b]!==c[b])return!1;return!0}}function q(a,c){return a.index-c.index}function r(a){var c,b,e,d;2===a.length?a[0].index>a[1].index&&(c=a[0],a[0]=a[1],a[1]=c):2<a.length&&a.sort(q);a.length>=n.length&&(n.length=a.length+1);n[a.length]||(n[a.length]=[]);d=n[a.length];c=0;for(b=d.length;c<b;c++)if(e=d[c],f(a,e))return e;d.push(a);return a}
|
||||
function t(a,c){this.b=a;this.as={};this.yp={};this.Pm=!1;this.Pp=new da;this.qm=[];this.Wl=[];this.name=c[0];var b=c[1];this.hf=[];var e,d;e=0;for(d=b.length;e<d;e++)this.Rp(b[e],null,this.hf)}function b(a){this.type=a;this.e=[];this.ga=[];this.Aa=!0}function p(a,c,b){this.sheet=a;this.parent=c;this.b=a.b;this.Ka=[];this.xf=[];this.Op=this.ul=this.jo=this.gk=this.group=this.bo=!1;this.pb=[];this.sd=[];this.nd=[];this.ai="";this.$h=this.gk=this.group=!1;this.Ej=null;b[1]&&(this.ai=b[1][1].toLowerCase(),
|
||||
this.group=!0,this.gk=!!b[1][0],this.Ej=[],this.$h=this.gk,this.b.Ue.push(this),this.b.ek[this.ai]=this);this.gd=b[2];this.fa=b[4];this.group||(this.b.ip[this.fa.toString()]=this);var e=b[5];a=0;for(c=e.length;a<c;a++){var d=new $b(this,e[a]);d.index=a;this.pb.push(d);this.Vo(d.type)}e=b[6];a=0;for(c=e.length;a<c;a++)d=new ac(this,e[a]),d.index=a,this.sd.push(d);if(8===b.length)for(b=b[7],a=0,c=b.length;a<c;a++)this.sheet.Rp(b[a],this,this.nd);this.ok=!1;this.pb.length&&(this.ok=null==this.pb[0].type&&
|
||||
this.pb[0].Lb==X.prototype.g.zo)}function k(a,c){var b,e,d;if(a&&(-1===c.indexOf(a)&&c.push(a),a.jc))for(b=0,e=a.Dc.length;b<e;b++)d=a.Dc[b],a!==d&&-1===c.indexOf(d)&&c.push(d)}function d(a,c){this.Lc=a;this.sheet=a.sheet;this.b=a.b;this.aa=[];this.ab=[];this.Ta={};this.index=-1;this.Ch=!1;this.Lb=this.b.Re(c[1]);this.trigger=0<c[3];this.xp=2===c[3];this.Ud=c[4];this.Um=c[5];this.Gw=c[6];this.fa=c[7];this.b.bf[this.fa.toString()]=this;-1===c[0]?(this.type=null,this.mb=this.Un,this.Ef=null,this.vd=
|
||||
-1):(this.type=this.b.D[c[0]],this.mb=this.Gw?this.Cx:this.Tn,c[2]?(this.Ef=this.type.bk(c[2]),this.vd=this.type.Cm(c[2])):(this.Ef=null,this.vd=-1),this.Lc.parent&&this.Lc.parent.il());this.xp&&(this.mb=this.Dx);if(10===c.length){var b,e,d=c[9];b=0;for(e=d.length;b<e;b++){var g=new bc(this,d[b]);this.aa.push(g)}this.ab.length=d.length}}function h(a,c){this.Lc=a;this.sheet=a.sheet;this.b=a.b;this.aa=[];this.ab=[];this.Ta={};this.index=-1;this.Ch=!1;this.Lb=this.b.Re(c[1]);-1===c[0]?(this.type=null,
|
||||
this.mb=this.Un,this.Ef=null,this.vd=-1):(this.type=this.b.D[c[0]],this.mb=this.Tn,c[2]?(this.Ef=this.type.bk(c[2]),this.vd=this.type.Cm(c[2])):(this.Ef=null,this.vd=-1));this.fa=c[3];this.b.Te[this.fa.toString()]=this;if(6===c.length){var b,e,d=c[5];b=0;for(e=d.length;b<e;b++){var g=new bc(this,d[b]);this.aa.push(g)}this.ab.length=d.length}}function c(){w++;L.length===w&&L.push(new cc);return L[w]}function a(a,c){this.hd=a;this.Lc=a.Lc;this.sheet=a.sheet;this.b=a.b;this.type=c[0];this.Pd=null;this.Ie=
|
||||
0;this.get=null;this.qp=0;this.Bb=null;this.key=0;this.object=null;this.index=0;this.hj=this.tg=this.hj=this.tg=this.Bp=this.Of=this.ij=null;this.qd=!1;var b,e,d;switch(c[0]){case 0:case 7:this.Pd=new dc(this,c[1]);this.Ie=0;this.get=this.$v;break;case 1:this.Pd=new dc(this,c[1]);this.Ie=0;this.get=this.aw;break;case 5:this.Pd=new dc(this,c[1]);this.Ie=0;this.get=this.fw;break;case 3:case 8:this.qp=c[1];this.get=this.Yv;break;case 6:this.Bb=this.b.kn[c[1]];this.get=this.gw;break;case 9:this.key=c[1];
|
||||
this.get=this.ew;break;case 4:this.object=this.b.D[c[1]];this.get=this.hw;this.Lc.Vo(this.object);this.hd instanceof ac?this.Lc.il():this.Lc.parent&&this.Lc.parent.il();break;case 10:this.index=c[1];a.type&&a.type.V?(this.get=this.bw,this.qd=!0):this.get=this.dw;break;case 11:this.ij=c[1];this.Of=null;this.get=this.Zv;break;case 2:case 12:this.Bp=c[1];this.get=this.Xv;break;case 13:for(this.get=this.iw,this.tg=[],this.hj=[],b=1,e=c.length;b<e;b++)d=new bc(this.hd,c[b]),this.tg.push(d),this.hj.push(0)}}
|
||||
function e(a,c,b){this.sheet=a;this.parent=c;this.b=a.b;this.Ka=[];this.name=b[1];this.u=b[3];this.mi=!!b[4];this.nk=!!b[5];this.fa=b[6];this.b.Bh[this.fa.toString()]=this;this.data=this.u;this.parent?(this.fg=this.mi||this.nk?-1:this.b.Nx++,this.b.Yt.push(this)):(this.fg=-1,this.b.Vl.push(this))}function l(a,c,b){this.sheet=a;this.parent=c;this.b=a.b;this.Ka=[];this.ci=null;this.pw=b[1];this.B=!0}function g(){this.Ur=[];this.reset(null)}var n=[];t.prototype.toString=function(){return this.name};
|
||||
t.prototype.Rp=function(a,c,b){switch(a[0]){case 0:a=new ec(this,c,a);if(a.gd)for(b.push(a),b=0,c=a.pb.length;b<c;b++)a.pb[b].trigger&&this.Sp(a,b);else a.$p()?this.Sp(a,0):b.push(a);break;case 1:a=new Wb(this,c,a);b.push(a);break;case 2:a=new fc(this,c,a),b.push(a)}};t.prototype.cb=function(){var a,c;a=0;for(c=this.hf.length;a<c;a++)this.hf[a].cb(a<c-1&&this.hf[a+1].ok)};t.prototype.ro=function(){N(this.qm);N(this.Wl);this.To(this);N(this.Wl)};t.prototype.To=function(a){var c,b,e,d,g=a.qm,n=a.Wl,
|
||||
k=this.Pp.Bf();c=0;for(b=k.length;c<b;++c)e=k[c],d=e.ci,!e.B||a===d||-1<n.indexOf(d)||(n.push(d),d.To(a),g.push(d))};t.prototype.mb=function(a){this.b.Uz||(this.Pm=!0,a||(this.b.$m=!0));var c,b;c=0;for(b=this.hf.length;c<b;c++){var e=this.hf[c];e.mb();this.b.km(e.Ka);this.b.lf&&this.b.Tb()}a||(this.b.$m=!1)};t.prototype.Sp=function(a,c){a.gd||this.b.xl.push(a);var b,e,d=a.pb[c],g;d.type?g=d.type.name:g="system";var n=(b=d.xp)?this.yp:this.as;n[g]||(n[g]=[]);g=n[g];n=d.Lb;if(b){if(d.aa.length&&(d=
|
||||
d.aa[0],1===d.type&&2===d.Pd.type)){d=d.Pd.value.toLowerCase();b=0;for(e=g.length;b<e;b++)if(g[b].method==n){b=g[b].Qh;b[d]?b[d].push([a,c]):b[d]=[[a,c]];return}b={};b[d]=[[a,c]];g.push({method:n,Qh:b})}}else{b=0;for(e=g.length;b<e;b++)if(g[b].method==n){g[b].Qh.push([a,c]);return}tc&&n===tc.prototype.g.Ag?g.unshift({method:n,Qh:[[a,c]]}):g.push({method:n,Qh:[[a,c]]})}};Mb=t;b.prototype.Om=function(){return this.Aa?this.type.e.length:this.e.length};b.prototype.dd=function(){return this.Aa?this.type.e:
|
||||
this.e};b.prototype.Oi=function(a){a&&(a.b.Mb().Kb.gd?(this.Aa&&(N(this.e),Da(this.ga,a.type.e),this.Aa=!1),a=this.ga.indexOf(a),-1!==a&&(this.e.push(this.ga[a]),this.ga.splice(a,1))):(this.Aa=!1,N(this.e),this.e[0]=a))};rb=b;window._c2hh_="0764F5122709682D4499715308638A3CE8A82A1F";p.prototype.cb=function(a){var c,b=this.parent;if(this.group)for(this.ul=!0;b;){if(!b.group){this.ul=!1;break}b=b.parent}this.jo=!this.$p()&&(!this.parent||this.parent.group&&this.parent.ul);this.Op=!!a;this.xf=this.Ka.slice(0);
|
||||
for(b=this.parent;b;){a=0;for(c=b.Ka.length;a<c;a++)this.Xt(b.Ka[a]);b=b.parent}this.Ka=r(this.Ka);this.xf=r(this.xf);a=0;for(c=this.pb.length;a<c;a++)this.pb[a].cb();a=0;for(c=this.sd.length;a<c;a++)this.sd[a].cb();a=0;for(c=this.nd.length;a<c;a++)this.nd[a].cb(a<c-1&&this.nd[a+1].ok)};p.prototype.Hr=function(a){if(this.$h!==!!a){this.$h=!!a;var c;a=0;for(c=this.Ej.length;a<c;++a)this.Ej[a].hs();0<c&&this.b.Da.Nf&&this.b.Da.Nf.ro()}};p.prototype.Vo=function(a){k(a,this.Ka)};p.prototype.Xt=function(a){k(a,
|
||||
this.xf)};p.prototype.il=function(){this.bo=!0;this.parent&&this.parent.il()};p.prototype.$p=function(){return this.pb.length?this.pb[0].trigger:!1};p.prototype.mb=function(){var a,c,b=!1,e=this.b,d=this.b.Mb();d.Kb=this;var g=this.pb;this.ok||(d.tm=!1);if(this.gd){0===g.length&&(b=!0);d.ob=0;for(a=g.length;d.ob<a;d.ob++)c=g[d.ob],c.trigger||(c=c.mb())&&(b=!0);(d.Zf=b)&&this.dl()}else{d.ob=0;for(a=g.length;d.ob<a;d.ob++)if(c=g[d.ob].mb(),!c){d.Zf=!1;this.jo&&e.lf&&e.Tb();return}d.Zf=!0;this.dl()}this.Uu(d)};
|
||||
p.prototype.Uu=function(a){a.Zf&&this.Op&&(a.tm=!0);this.jo&&this.b.lf&&this.b.Tb()};p.prototype.Ax=function(a){this.b.Mb().Kb=this;this.pb[a].mb()&&(this.dl(),this.b.Mb().Zf=!0)};p.prototype.dl=function(){var a=this.b.Mb(),c;a.Bc=0;for(c=this.sd.length;a.Bc<c;a.Bc++)if(this.sd[a.Bc].mb())return;this.Ar()};p.prototype.yx=function(){var a=this.b.Mb(),c;for(c=this.sd.length;a.Bc<c;a.Bc++)if(this.sd[a.Bc].mb())return;this.Ar()};p.prototype.Ar=function(){if(this.nd.length){var a,c,b,e,d=this.nd.length-
|
||||
1;this.b.Yk(this);if(this.bo)for(a=0,c=this.nd.length;a<c;a++)b=this.nd[a],(e=!this.ul||!this.group&&a<d)&&this.b.Xk(b.Ka),b.mb(),e?this.b.mg(b.Ka):this.b.km(b.Ka);else for(a=0,c=this.nd.length;a<c;a++)this.nd[a].mb();this.b.Sk()}};p.prototype.Bx=function(){var a=this.b.Mb();a.Kb=this;var c=!1,b;a.ob=0;for(b=this.pb.length;a.ob<b;a.ob++)if(this.pb[a.ob].mb())c=!0;else if(!this.gd)return!1;return this.gd?c:!0};p.prototype.xr=function(){this.b.Rh++;var a=this.b.Mb().ob,c=this.b.Yk(this);if(!this.gd)for(c.ob=
|
||||
a+1,a=this.pb.length;c.ob<a;c.ob++)if(!this.pb[c.ob].mb()){this.b.Sk();return}this.dl();this.b.Sk()};p.prototype.ww=function(a){var c=a.index;if(0===c)return!0;for(--c;0<=c;--c)if(this.pb[c].type===a.type)return!1;return!0};ec=p;d.prototype.cb=function(){var a,c,b;a=0;for(c=this.aa.length;a<c;a++)b=this.aa[a],b.cb(),b.qd&&(this.Ch=!0)};d.prototype.Dx=function(){return!0};d.prototype.Un=function(){var a,c;a=0;for(c=this.aa.length;a<c;a++)this.ab[a]=this.aa[a].get();return Va(this.Lb.apply(this.b.be,
|
||||
this.ab),this.Um)};d.prototype.Cx=function(){var a,c;a=0;for(c=this.aa.length;a<c;a++)this.ab[a]=this.aa[a].get();a=this.Lb.apply(this.Ef?this.Ef:this.type,this.ab);this.type.Ve();return a};d.prototype.Tn=function(){var a,c,b,e,d,g,n,k,h=this.type,l=h.qa(),f=this.Lc.gd&&!this.trigger;c=0;var w=h.jc,p=h.V,q=h.se,t=this.vd,r=-1<t,L=this.Ch,I=this.aa,D=this.ab,H=this.Um,z=this.Lb,J;if(L)for(c=0,d=I.length;c<d;++c)g=I[c],g.qd||(D[c]=g.get(0));else for(c=0,d=I.length;c<d;++c)D[c]=I[c].get(0);if(l.Aa){N(l.e);
|
||||
N(l.ga);J=h.e;a=0;for(e=J.length;a<e;++a){k=J[a];if(L)for(c=0,d=I.length;c<d;++c)g=I[c],g.qd&&(D[c]=g.get(a));r?(c=0,p&&(c=k.type.Kg[q]),c=z.apply(k.S[t+c],D)):c=z.apply(k,D);(n=Va(c,H))?l.e.push(k):f&&l.ga.push(k)}h.finish&&h.finish(!0);l.Aa=!1;h.Ve();return l.Om()}b=0;J=(n=f&&!this.Lc.ww(this))?l.ga:l.e;var B=!1;a=0;for(e=J.length;a<e;++a){k=J[a];if(L)for(c=0,d=I.length;c<d;++c)g=I[c],g.qd&&(D[c]=g.get(a));r?(c=0,p&&(c=k.type.Kg[q]),c=z.apply(k.S[t+c],D)):c=z.apply(k,D);if(Va(c,H))if(B=!0,n){if(l.e.push(k),
|
||||
w)for(c=0,d=k.siblings.length;c<d;c++)g=k.siblings[c],g.type.qa().e.push(g)}else{J[b]=k;if(w)for(c=0,d=k.siblings.length;c<d;c++)g=k.siblings[c],g.type.qa().e[b]=g;b++}else if(n){J[b]=k;if(w)for(c=0,d=k.siblings.length;c<d;c++)g=k.siblings[c],g.type.qa().ga[b]=g;b++}else if(f&&(l.ga.push(k),w))for(c=0,d=k.siblings.length;c<d;c++)g=k.siblings[c],g.type.qa().ga.push(g)}Ca(J,b);if(w)for(p=h.Dc,a=0,e=p.length;a<e;a++)k=p[a].qa(),n?Ca(k.ga,b):Ca(k.e,b);b=B;if(n&&!B)for(a=0,e=l.e.length;a<e;a++){k=l.e[a];
|
||||
if(L)for(c=0,d=I.length;c<d;c++)g=I[c],g.qd&&(D[c]=g.get(a));c=r?z.apply(k.S[t],D):z.apply(k,D);if(Va(c,H)){B=!0;break}}h.finish&&h.finish(b||f);return f?B:l.Om()};$b=d;h.prototype.cb=function(){var a,c,b;a=0;for(c=this.aa.length;a<c;a++)b=this.aa[a],b.cb(),b.qd&&(this.Ch=!0)};h.prototype.Un=function(){var a=this.b,c,b,e=this.aa,d=this.ab;c=0;for(b=e.length;c<b;++c)d[c]=e[c].get();return this.Lb.apply(a.be,d)};h.prototype.Tn=function(){var a=this.type,c=this.vd,b=a.se,e=this.Ch,d=this.aa,g=this.ab,
|
||||
n=this.Lb,k=a.qa().dd(),a=a.V,h=-1<c,l,f,w,p,q,t;if(e)for(f=0,p=d.length;f<p;++f)q=d[f],q.qd||(g[f]=q.get(0));else for(f=0,p=d.length;f<p;++f)g[f]=d[f].get(0);l=0;for(w=k.length;l<w;++l){t=k[l];if(e)for(f=0,p=d.length;f<p;++f)q=d[f],q.qd&&(g[f]=q.get(l));h?(f=0,a&&(f=t.type.Kg[b]),n.apply(t.S[c+f],g)):n.apply(t,g)}return!1};ac=h;var L=[],w=-1;a.prototype.cb=function(){var a,c;if(11===this.type)this.Of=this.b.Hp(this.ij,this.Lc.parent);else if(13===this.type)for(a=0,c=this.tg.length;a<c;a++)this.tg[a].cb();
|
||||
this.Pd&&this.Pd.cb()};a.prototype.Mw=function(a){this.qd||!a||a.Ga.kl||(this.qd=!0)};a.prototype.Jr=function(){this.qd=!0};a.prototype.$v=function(a){this.Ie=a||0;a=c();this.Pd.get(a);w--;return a.data};a.prototype.aw=function(a){this.Ie=a||0;a=c();this.Pd.get(a);w--;return A(a.data)?a.data:""};a.prototype.hw=function(){return this.object};a.prototype.Yv=function(){return this.qp};a.prototype.fw=function(a){this.Ie=a||0;a=c();this.Pd.get(a);w--;return a.zb()?this.b.Wh(a.data):this.b.Im(a.data)};
|
||||
a.prototype.gw=function(){return this.Bb};a.prototype.ew=function(){return this.key};a.prototype.dw=function(){return this.index};a.prototype.bw=function(a){a=a||0;var c=this.hd.type,b=null,b=c.qa(),e=b.dd();if(e.length)b=e[a%e.length].type;else if(b.ga.length)b=b.ga[a%b.ga.length].type;else if(c.e.length)b=c.e[a%c.e.length].type;else return 0;return this.index+b.Uj[c.se]};a.prototype.Zv=function(){return this.Of};a.prototype.Xv=function(){return this.Bp};a.prototype.iw=function(){var a,c;a=0;for(c=
|
||||
this.tg.length;a<c;a++)this.hj[a]=this.tg[a].get();return this.hj};bc=a;e.prototype.cb=function(){this.Ka=r(this.Ka)};e.prototype.Lx=function(a){var c=this.b.Gp();this.parent&&!this.mi&&c?(this.fg>=c.length&&(c.length=this.fg+1),c[this.fg]=a):this.data=a};e.prototype.Wv=function(){var a=this.b.Gp();return!this.parent||this.mi||!a||this.nk?this.data:this.fg>=a.length||"undefined"===typeof a[this.fg]?this.u:a[this.fg]};e.prototype.mb=function(){!this.parent||this.mi||this.nk||this.Lx(this.u)};Wb=e;
|
||||
l.prototype.toString=function(){return"include:"+this.ci.toString()};l.prototype.cb=function(){this.ci=this.b.vm[this.pw];this.sheet.Pp.add(this);this.Ka=r(this.Ka);for(var a=this.parent;a;)a.group&&a.Ej.push(this),a=a.parent;this.hs()};l.prototype.mb=function(){this.parent&&this.b.Si(this.b.D);this.ci.Pm||this.ci.mb(!0);this.parent&&this.b.mg(this.b.D)};l.prototype.hs=function(){for(var a=this.parent;a;){if(a.group&&!a.$h){this.B=!1;return}a=a.parent}this.B=!0};fc=l;g.prototype.reset=function(a){this.Kb=
|
||||
a;this.Bc=this.ob=0;N(this.Ur);this.tm=this.Zf=!1};g.prototype.yw=function(){return this.Kb.bo?!0:this.ob<this.Kb.pb.length-1?!!this.Kb.Ka.length:!1};Vb=g})();
|
||||
(function(){function f(b,d){this.hd=b;this.b=b.b;this.type=d[0];this.get=[this.pv,this.kv,this.yv,this.Bv,this.Xu,this.zv,this.tv,this.gv,this.sv,this.xv,this.Yu,this.wv,this.hv,this.uv,this.qv,this.rv,this.lv,this.nv,this.dv,this.Av,this.vv,this.ov,this.cv,this.jv][this.type];var h=null;this.ze=this.aa=this.ab=this.Lb=this.sl=this.second=this.first=this.value=null;this.vd=-1;this.Ad=null;this.ls=-1;this.Of=this.ij=null;this.qh=!1;switch(this.type){case 0:case 1:case 2:this.value=d[1];break;case 3:this.first=
|
||||
new dc(b,d[1]);break;case 18:this.first=new dc(b,d[1]);this.second=new dc(b,d[2]);this.sl=new dc(b,d[3]);break;case 19:this.Lb=this.b.Re(d[1]);this.Lb!==X.prototype.Ma.random&&this.Lb!==X.prototype.Ma.ju||this.hd.Jr();this.ab=[];this.aa=[];3===d.length?(h=d[2],this.ab.length=h.length+1):this.ab.length=1;break;case 20:this.ze=this.b.D[d[1]];this.vd=-1;this.Lb=this.b.Re(d[2]);this.qh=d[3];uc&&this.Lb===uc.prototype.Ma.rs&&this.hd.Jr();d[4]?this.Ad=new dc(b,d[4]):this.Ad=null;this.ab=[];this.aa=[];6===
|
||||
d.length?(h=d[5],this.ab.length=h.length+1):this.ab.length=1;break;case 21:this.ze=this.b.D[d[1]];this.qh=d[2];d[3]?this.Ad=new dc(b,d[3]):this.Ad=null;this.ls=d[4];break;case 22:this.ze=this.b.D[d[1]];this.ze.bk(d[2]);this.vd=this.ze.Cm(d[2]);this.Lb=this.b.Re(d[3]);this.qh=d[4];d[5]?this.Ad=new dc(b,d[5]):this.Ad=null;this.ab=[];this.aa=[];7===d.length?(h=d[6],this.ab.length=h.length+1):this.ab.length=1;break;case 23:this.ij=d[1],this.Of=null}this.hd.Mw(this.ze);4<=this.type&&17>=this.type&&(this.first=
|
||||
new dc(b,d[1]),this.second=new dc(b,d[2]));if(h){var c,a;c=0;for(a=h.length;c<a;c++)this.aa.push(new dc(b,h[c]))}}function q(){++p;b.length===p&&b.push(new cc);return b[p]}function r(b,d,h){var c,a;c=0;for(a=b.length;c<a;++c)b[c].get(h),d[c+1]=h.data}function t(b,d){this.type=b||gc.zg;this.data=d||0;this.ig=null;this.type==gc.zg&&(this.data=Math.floor(this.data))}f.prototype.cb=function(){23===this.type&&(this.Of=this.hd.b.Hp(this.ij,this.hd.Lc.parent));this.first&&this.first.cb();this.second&&this.second.cb();
|
||||
this.sl&&this.sl.cb();this.Ad&&this.Ad.cb();if(this.aa){var b,d;b=0;for(d=this.aa.length;b<d;b++)this.aa[b].cb()}};var b=[],p=-1;f.prototype.Av=function(b){var d=this.aa,h=this.ab;h[0]=b;b=q();r(d,h,b);--p;this.Lb.apply(this.b.be,h)};f.prototype.vv=function(b){var d=this.ze,h=this.ab,c=this.aa,a=this.Ad,e=this.Lb,l=this.hd.Ie,g=d.qa(),n=g.dd();if(!n.length)if(g.ga.length)n=g.ga;else{this.qh?b.Fb(""):b.Na(0);return}h[0]=b;b.ig=d;b=q();r(c,h,b);a&&(a.get(b),b.zb()&&(l=b.data,n=d.e));--p;d=n.length;
|
||||
if(l>=d||l<=-d)l%=d;0>l&&(l+=d);e.apply(n[l],h)};f.prototype.cv=function(b){var d=this.ze,h=this.ab,c=this.aa,a=this.Ad,e=this.vd,l=this.Lb,g=this.hd.Ie,n=d.qa(),f=n.dd();if(!f.length)if(n.ga.length)f=n.ga;else{this.qh?b.Fb(""):b.Na(0);return}h[0]=b;b.ig=d;b=q();r(c,h,b);a&&(a.get(b),b.zb()&&(g=b.data,f=d.e));--p;c=f.length;if(g>=c||g<=-c)g%=c;0>g&&(g+=c);g=f[g];f=0;d.V&&(f=g.type.Kg[d.se]);l.apply(g.S[e+f],h)};f.prototype.ov=function(b){var d=this.Ad,h=this.ze,c=this.ls,a=this.hd.Ie,e=h.qa(),l=e.dd();
|
||||
if(!l.length)if(e.ga.length)l=e.ga;else{this.qh?b.Fb(""):b.Na(0);return}if(d){e=q();d.get(e);if(e.zb()){a=e.data;l=h.e;0!==l.length&&(a%=l.length,0>a&&(a+=l.length));a=h.Hm(a);h=a.sb[c];A(h)?b.Fb(h):b.H(h);--p;return}--p}d=l.length;if(a>=d||a<=-d)a%=d;0>a&&(a+=d);a=l[a];l=0;h.V&&(l=a.type.Uj[h.se]);h=a.sb[c+l];A(h)?b.Fb(h):b.H(h)};f.prototype.pv=function(b){b.type=gc.zg;b.data=this.value};f.prototype.kv=function(b){b.type=gc.yg;b.data=this.value};f.prototype.yv=function(b){b.type=gc.String;b.data=
|
||||
this.value};f.prototype.Bv=function(b){this.first.get(b);b.zb()&&(b.data=-b.data)};f.prototype.Xu=function(b){this.first.get(b);var d=q();this.second.get(d);b.zb()&&d.zb()&&(b.data+=d.data,d.Qg()&&b.$g());--p};f.prototype.zv=function(b){this.first.get(b);var d=q();this.second.get(d);b.zb()&&d.zb()&&(b.data-=d.data,d.Qg()&&b.$g());--p};f.prototype.tv=function(b){this.first.get(b);var d=q();this.second.get(d);b.zb()&&d.zb()&&(b.data*=d.data,d.Qg()&&b.$g());--p};f.prototype.gv=function(b){this.first.get(b);
|
||||
var d=q();this.second.get(d);b.zb()&&d.zb()&&(b.data/=d.data,b.$g());--p};f.prototype.sv=function(b){this.first.get(b);var d=q();this.second.get(d);b.zb()&&d.zb()&&(b.data%=d.data,d.Qg()&&b.$g());--p};f.prototype.xv=function(b){this.first.get(b);var d=q();this.second.get(d);b.zb()&&d.zb()&&(b.data=Math.pow(b.data,d.data),d.Qg()&&b.$g());--p};f.prototype.Yu=function(b){this.first.get(b);var d=q();this.second.get(d);d.Tg()||b.Tg()?this.$u(b,d):this.Zu(b,d);--p};f.prototype.$u=function(b,d){b.Tg()&&
|
||||
d.Tg()?this.bv(b,d):this.av(b,d)};f.prototype.bv=function(b,d){b.data+=d.data};f.prototype.av=function(b,d){b.Tg()?b.data+=(Math.round(1E10*d.data)/1E10).toString():b.Fb(b.data.toString()+d.data)};f.prototype.Zu=function(b,d){b.Na(b.data&&d.data?1:0)};f.prototype.wv=function(b){this.first.get(b);var d=q();this.second.get(d);b.zb()&&d.zb()&&(b.data||d.data?b.Na(1):b.Na(0));--p};f.prototype.dv=function(b){this.first.get(b);b.data?this.second.get(b):this.sl.get(b)};f.prototype.hv=function(b){this.first.get(b);
|
||||
var d=q();this.second.get(d);b.Na(b.data===d.data?1:0);--p};f.prototype.uv=function(b){this.first.get(b);var d=q();this.second.get(d);b.Na(b.data!==d.data?1:0);--p};f.prototype.qv=function(b){this.first.get(b);var d=q();this.second.get(d);b.Na(b.data<d.data?1:0);--p};f.prototype.rv=function(b){this.first.get(b);var d=q();this.second.get(d);b.Na(b.data<=d.data?1:0);--p};f.prototype.lv=function(b){this.first.get(b);var d=q();this.second.get(d);b.Na(b.data>d.data?1:0);--p};f.prototype.nv=function(b){this.first.get(b);
|
||||
var d=q();this.second.get(d);b.Na(b.data>=d.data?1:0);--p};f.prototype.jv=function(b){var d=this.Of.Wv();la(d)?b.H(d):b.Fb(d)};dc=f;t.prototype.Qg=function(){return this.type===gc.yg};t.prototype.zb=function(){return this.type===gc.zg||this.type===gc.yg};t.prototype.Tg=function(){return this.type===gc.String};t.prototype.$g=function(){this.Qg()||(this.Tg()&&(this.data=parseFloat(this.data)),this.type=gc.yg)};t.prototype.Na=function(b){this.type=gc.zg;this.data=Math.floor(b)};t.prototype.H=function(b){this.type=
|
||||
gc.yg;this.data=b};t.prototype.Fb=function(b){this.type=gc.String;this.data=b};t.prototype.rg=function(b){la(b)?(this.type=gc.yg,this.data=b):A(b)?(this.type=gc.String,this.data=b.toString()):(this.type=gc.zg,this.data=0)};cc=t;gc={zg:0,yg:1,String:2}})();function X(f){this.b=f;this.Ac=[]}
|
||||
X.prototype.eb=function(){var f={},q,r,t,b,p,k,d,h;f.waits=[];var c=f.waits,a;q=0;for(r=this.Ac.length;q<r;q++){k=this.Ac[q];a={t:k.time,st:k.Pr,s:k.ao,ev:k.Ig.fa,sm:[],sols:{}};k.Ig.sd[k.Bc]&&(a.act=k.Ig.sd[k.Bc].fa);t=0;for(b=k.Ka.length;t<b;t++)a.sm.push(k.Ka[t].fa);for(p in k.mc)if(k.mc.hasOwnProperty(p)){d=this.b.D[parseInt(p,10)];h={sa:k.mc[p].el,insts:[]};t=0;for(b=k.mc[p].ue.length;t<b;t++)h.insts.push(k.mc[p].ue[t].uid);a.sols[d.fa.toString()]=h}c.push(a)}return f};
|
||||
X.prototype.ub=function(f){f=f.waits;var q,r,t,b,p,k,d,h,c,a,e;N(this.Ac);q=0;for(r=f.length;q<r;q++)if(k=f[q],h=this.b.ip[k.ev.toString()]){c=-1;t=0;for(b=h.sd.length;t<b;t++)if(h.sd[t].fa===k.act){c=t;break}if(-1!==c){d={mc:{},Ka:[],rm:!1};d.time=k.t;d.Pr=k.st||"";d.ao=!!k.s;d.Ig=h;d.Bc=c;t=0;for(b=k.sm.length;t<b;t++)(h=this.b.dk(k.sm[t]))&&d.Ka.push(h);for(p in k.sols)if(k.sols.hasOwnProperty(p)&&(h=this.b.dk(parseInt(p,10)))){c=k.sols[p];a={el:c.sa,ue:[]};t=0;for(b=c.insts.length;t<b;t++)(e=
|
||||
this.b.Xh(c.insts[t]))&&a.ue.push(e);d.mc[h.index.toString()]=a}this.Ac.push(d)}}};
|
||||
(function(){function f(){}function q(){}function r(){}var t=X.prototype;f.prototype.Eo=function(){return!0};f.prototype.et=function(){return!0};f.prototype.us=function(b,c,a){return hc(b,c,a)};var b=[],p=-1;f.prototype.Cs=function(d){var c=d.qa();p++;b.length===p&&b.push([]);var a=b[p];Da(a,c.dd());var e=this.b.Mb(),l=e.Kb,g=e.yw(),e=this.b.nx(),n,f,k,m,u,q,t=d.jc;if(g)for(g=0,n=a.length;g<n&&!e.Gb;g++){this.b.Xk(l.Ka);m=a[g];c=d.qa();c.Aa=!1;N(c.e);c.e[0]=m;if(t)for(f=0,k=m.siblings.length;f<k;f++)u=
|
||||
m.siblings[f],q=u.type.qa(),q.Aa=!1,N(q.e),q.e[0]=u;e.index=g;l.xr();this.b.mg(l.Ka)}else for(c.Aa=!1,N(c.e),g=0,n=a.length;g<n&&!e.Gb;g++){m=a[g];c.e[0]=m;if(t)for(f=0,k=m.siblings.length;f<k;f++)u=m.siblings[f],q=u.type.qa(),q.Aa=!1,N(q.e),q.e[0]=u;e.index=g;l.xr()}N(a);this.b.cx();p--;return!1};f.prototype.zo=function(){var b=this.b.Mb();return b.tm?!1:!b.Zf};f.prototype.Fo=function(){return!0};f.prototype.Ps=function(){return!0};f.prototype.Kl=function(){return!0};f.prototype.Jo=function(){return!0};
|
||||
f.prototype.ft=function(){return!0};f.prototype.rj=function(){return!0};f.prototype.os=function(b,c,a){return Pa(Q(b),Q(a))<=Q(c)};f.prototype.Hs=function(b,c){return Sa(Q(b),Q(c))};f.prototype.Gs=function(b,c,a){b=Na(b);c=Na(c);a=Na(a);return Sa(a,c)?Sa(b,c)&&!Sa(b,a):!(!Sa(b,c)&&Sa(b,a))};t.g=new f;q.prototype.ws=function(b,c,a,e){if(c&&b&&(c=this.b.rp(b,c,a,e))){this.b.Cd++;var d;this.b.trigger(Object.getPrototypeOf(b.Ga).g.oj,c);if(c.jc)for(a=0,e=c.siblings.length;a<e;a++)d=c.siblings[a],this.b.trigger(Object.getPrototypeOf(d.type.Ga).g.oj,
|
||||
d);this.b.Cd--;b=b.qa();b.Aa=!1;N(b.e);b.e[0]=c;if(c.jc)for(a=0,e=c.siblings.length;a<e;a++)d=c.siblings[a],b=d.type.qa(),b.Aa=!1,N(b.e),b.e[0]=d}};var k=[],d=[];q.prototype.St=function(b){if(!(0>b)){var c,a,e,l=this.b.Mb(),g;k.length?g=k.pop():g={mc:{},Ka:[]};g.rm=!1;g.time=this.b.Nb.Z+b;g.Pr="";g.ao=!1;g.Ig=l.Kb;g.Bc=l.Bc+1;b=0;for(c=this.b.D.length;b<c;b++)e=this.b.D[b],a=e.qa(),a.Aa&&-1===l.Kb.Ka.indexOf(e)||(g.Ka.push(e),e=void 0,d.length?e=d.pop():e={ue:[]},e.el=!1,e.el=a.Aa,Da(e.ue,a.e),g.mc[b.toString()]=
|
||||
e);this.Ac.push(g);return!0}};q.prototype.zt=function(){var b,c,a;b=0;for(c=this.b.Vl.length;b<c;b++)a=this.b.Vl[b],a.data=a.u};q.prototype.Bt=function(){if(!this.b.ni&&!this.b.Hh&&this.b.Da){this.b.Hh=this.b.Da;var b,c,a;b=0;for(c=this.b.Ue.length;b<c;b++)a=this.b.Ue[b],a.Hr(a.gk)}};t.J=new q;r.prototype["int"]=function(b,c){A(c)?(b.Na(parseInt(c,10)),isNaN(b.data)&&(b.data=0)):b.Na(c)};r.prototype["float"]=function(b,c){A(c)?(b.H(parseFloat(c)),isNaN(b.data)&&(b.data=0)):b.H(c)};r.prototype.random=
|
||||
function(b,c,a){void 0===a?b.H(Math.random()*c):b.H(Math.random()*(a-c)+c)};r.prototype.sqrt=function(b,c){b.H(Math.sqrt(c))};r.prototype.abs=function(b,c){b.H(Math.abs(c))};r.prototype.round=function(b,c){b.Na(Math.round(c))};r.prototype.floor=function(b,c){b.Na(Math.floor(c))};r.prototype.ceil=function(b,c){b.Na(Math.ceil(c))};r.prototype.sin=function(b,c){b.H(Math.sin(Q(c)))};r.prototype.cos=function(b,c){b.H(Math.cos(Q(c)))};r.prototype.tan=function(b,c){b.H(Math.tan(Q(c)))};r.prototype.asin=
|
||||
function(b,c){b.H(Ia(Math.asin(c)))};r.prototype.acos=function(b,c){b.H(Ia(Math.acos(c)))};r.prototype.atan=function(b,c){b.H(Ia(Math.atan(c)))};r.prototype.exp=function(b,c){b.H(Math.exp(c))};r.prototype.log10=function(b,c){b.H(Math.log(c)/Math.LN10)};r.prototype.max=function(b){var c=arguments[1];"number"!==typeof c&&(c=0);var a,e,d;a=2;for(e=arguments.length;a<e;a++)d=arguments[a],"number"===typeof d&&c<d&&(c=d);b.H(c)};r.prototype.min=function(b){var c=arguments[1];"number"!==typeof c&&(c=0);
|
||||
var a,e,d;a=2;for(e=arguments.length;a<e;a++)d=arguments[a],"number"===typeof d&&c>d&&(c=d);b.H(c)};r.prototype.Jf=function(b){b.H(this.b.Jf)};r.prototype.vh=function(b){b.H(this.b.vh)};r.prototype.time=function(b){b.H(this.b.Nb.Z)};r.prototype.ee=function(b){b.Na(this.b.ee)};r.prototype.Gk=function(b){b.Na(this.b.Gk)};r.prototype.Am=function(b){b.Na(this.b.Am)};r.prototype.j=function(b,c,a,e,d){b.H(Ia(Oa(c,a,e,d)))};r.prototype.left=function(b,c,a){b.Fb(A(c)?c.substr(0,a):"")};r.prototype.right=
|
||||
function(b,c,a){b.Fb(A(c)?c.substr(c.length-a):"")};r.prototype.replace=function(b,c,a,e){A(c)&&A(a)&&A(e)?b.Fb(c.replace(new RegExp(eb(a),"gi"),e)):b.Fb(A(c)?c:"")};r.prototype.trim=function(b,c){b.Fb(A(c)?c.trim():"")};r.prototype.ju=function(b){var c=ta(Math.random()*(arguments.length-1));b.rg(arguments[c+1])};r.prototype.mm=function(b){b.H(this.b.mm/1E3)};r.prototype.xk=function(b){b.H(this.b.xk)};t.Ma=new r;t.zx=function(){var b,c,a,e,l,g,n=this.b.Mb();b=0;for(a=this.Ac.length;b<a;b++){e=this.Ac[b];
|
||||
if(-1===e.time){if(!e.ao)continue}else if(e.time>this.b.Nb.Z)continue;n.Kb=e.Ig;n.Bc=e.Bc;n.ob=0;for(c in e.mc)e.mc.hasOwnProperty(c)&&(l=this.b.D[parseInt(c,10)].qa(),g=e.mc[c],l.Aa=g.el,Da(l.e,g.ue),l=g,N(l.ue),d.push(l));e.Ig.yx();this.b.km(e.Ka);e.rm=!0}c=b=0;for(a=this.Ac.length;b<a;b++)e=this.Ac[b],this.Ac[c]=e,e.rm?(Xa(e.mc),N(e.Ka),k.push(e)):c++;Ca(this.Ac,c)}})();
|
||||
(function(){qb=function(f,r){var t=f[1],b=f[3],p=f[4],k=f[5],d=f[6],h=f[7],c=f[8];r.g||(r.g={});r.J||(r.J={});r.Ma||(r.Ma={});var a=r.g,e=r.J,l=r.Ma;b&&(a.ry=function(a,b){return hc(this.x,a,b)},a.ty=function(a,b){return hc(this.y,a,b)},a.By=function(){var a=this.k;this.Ha();var b=this.xa;return!(b.right<a.Ea||b.bottom<a.Fa||b.left>a.Ja||b.top>a.Ia)},a.Cy=function(){this.Ha();var a=this.xa,b=this.b.Da;return 0>a.right||0>a.bottom||a.left>b.width||a.top>b.height},a.Oy=function(a,b,c){var e=this.qa(),
|
||||
d=e.dd();if(!d.length)return!1;var l=d[0],f=l,h=Ua(l.x,l.y,b,c),k,p,q;k=1;for(p=d.length;k<p;k++)if(l=d[k],q=Ua(l.x,l.y,b,c),0===a&&q<h||1===a&&q>h)h=q,f=l;e.Oi(f);return!0},e.rz=function(a){this.x!==a&&(this.x=a,this.ta())},e.sz=function(a){this.y!==a&&(this.y=a,this.ta())},e.iz=function(a,b){if(this.x!==a||this.y!==b)this.x=a,this.y=b,this.ta()},e.jz=function(a,b){var c=a.Rv(this);if(c){var e;c.Gm?(e=c.Gm(b,!0),c=c.Gm(b,!1)):(e=c.x,c=c.y);if(this.x!==e||this.y!==c)this.x=e,this.y=c,this.ta()}},
|
||||
e.Gy=function(a){0!==a&&(this.x+=Math.cos(this.j)*a,this.y+=Math.sin(this.j)*a,this.ta())},e.Fy=function(a,b){0!==b&&(this.x+=Math.cos(Q(a))*b,this.y+=Math.sin(Q(a))*b,this.ta())},l.No=function(a){a.H(this.x)},l.Oo=function(a){a.H(this.y)},l.Jf=function(a){a.H(this.b.Pf(this))});p&&(a.qy=function(a,b){return hc(this.width,a,b)},a.my=function(a,b){return hc(this.height,a,b)},e.Mt=function(a){this.width!==a&&(this.width=a,this.ta())},e.cz=function(a){this.height!==a&&(this.height=a,this.ta())},e.kz=
|
||||
function(a,b){if(this.width!==a||this.height!==b)this.width=a,this.height=b,this.ta()},l.zz=function(a){a.H(this.width)},l.wy=function(a){a.H(this.height)},l.iy=function(a){this.Ha();a.H(this.xa.left)},l.ky=function(a){this.Ha();a.H(this.xa.top)},l.jy=function(a){this.Ha();a.H(this.xa.right)},l.hy=function(a){this.Ha();a.H(this.xa.bottom)});k&&(a.os=function(a,b){return Pa(this.j,Q(b))<=Q(a)},a.Hs=function(a){return Sa(this.j,Q(a))},a.Gs=function(a,b){var c=Na(a),e=Na(b),d=La(this.j);return Sa(e,
|
||||
c)?Sa(d,c)&&!Sa(d,e):!(!Sa(d,c)&&Sa(d,e))},e.Zy=function(a){a=Q(Ja(a));isNaN(a)||this.j===a||(this.j=a,this.ta())},e.Vy=function(a){0===a||isNaN(a)||(this.j+=Q(a),this.j=La(this.j),this.ta())},e.Wy=function(a){0===a||isNaN(a)||(this.j-=Q(a),this.j=La(this.j),this.ta())},e.Xy=function(a,b){var c=Ra(this.j,Q(b),Q(a));isNaN(c)||this.j===c||(this.j=c,this.ta())},e.Yy=function(a,b,c){a=Ra(this.j,Math.atan2(c-this.y,b-this.x),Q(a));isNaN(a)||this.j===a||(this.j=a,this.ta())},e.oz=function(a,b){var c=Math.atan2(b-
|
||||
this.y,a-this.x);isNaN(c)||this.j===c||(this.j=c,this.ta())},l.gy=function(a){a.H(Ma(this.j))});t||(a.vs=function(a,b,c){return hc(this.sb[a],b,c)},a.zy=function(a){return this.sb[a]},a.Py=function(a,b){var c=this.qa(),e=c.dd();if(!e.length)return!1;var d=e[0],l=d,f=d.sb[b],h,k,p;h=1;for(k=e.length;h<k;h++)if(d=e[h],p=d.sb[b],0===a&&p<f||1===a&&p>f)f=p,l=d;c.Oi(l);return!0},a.Ny=function(a){var b,c,e,d,l;if(this.b.Lv().Um){l=this.qa();if(l.Aa)for(l.Aa=!1,N(l.e),N(l.ga),e=this.e,b=0,c=e.length;b<c;b++)d=
|
||||
e[b],d.uid===a?l.ga.push(d):l.e.push(d);else{e=b=0;for(c=l.e.length;b<c;b++)d=l.e[b],l.e[e]=d,d.uid===a?l.ga.push(d):e++;Ca(l.e,e)}this.Ve();return!!l.e.length}d=this.b.Xh(a);if(!d)return!1;l=this.qa();if(!l.Aa&&-1===l.e.indexOf(d))return!1;if(this.V)for(a=d.type.Ua,b=0,c=a.length;b<c;b++){if(a[b]===this)return l.Oi(d),this.Ve(),!0}else if(d.type===this)return l.Oi(d),this.Ve(),!0;return!1},a.oj=function(){return!0},a.Ss=function(){return!0},e.Jt=function(a,b){var c=this.sb;la(c[a])?c[a]=la(b)?b:
|
||||
parseFloat(b):A(c[a])&&(c[a]=A(b)?b:b.toString())},e.fy=function(a,b){var c=this.sb;la(c[a])?c[a]=la(b)?c[a]+b:c[a]+parseFloat(b):A(c[a])&&(c[a]=A(b)?c[a]+b:c[a]+b.toString())},e.vz=function(a,b){var c=this.sb;la(c[a])&&(c[a]=la(b)?c[a]-b:c[a]-parseFloat(b))},e.Et=function(a,b){this.sb[a]=b?1:0},e.xz=function(a){this.sb[a]=1-this.sb[a]},e.xs=function(){this.b.ie(this)},e.Ks||(e.Ks=function(a){var b,c;try{b=JSON.parse(a)}catch(e){return}this.b.vk(this,b,!0);this.je&&this.je();if(this.S)for(a=0,b=this.S.length;a<
|
||||
b;++a)c=this.S[a],c.je&&c.je()}),l.vy=function(a){var b=a.ig.e.length,c,e,d;c=0;for(e=this.b.Nd.length;c<e;c++)d=this.b.Nd[c],a.ig.V?0<=d.type.Ua.indexOf(a.ig)&&b++:d.type===a.ig&&b++;a.Na(b)},l.Ry=function(a){a.Na(a.ig.qa().dd().length)},l.yz=function(a){a.Na(this.uid)},l.xy=function(a){a.Na(this.Zh())},l.qs||(l.qs=function(a){a.Fb(JSON.stringify(this.b.Vn(this,!0)))}));d&&(a.Is=function(){return this.visible},e.tj=function(a){!a!==!this.visible&&(this.visible=!!a,this.b.Y=!0)},a.ny=function(a,b){return hc(kb(100*
|
||||
this.opacity),a,b)},e.fz=function(a){a=a/100;0>a?a=0:1<a&&(a=1);a!==this.opacity&&(this.opacity=a,this.b.Y=!0)},l.Opacity=function(a){a.H(kb(100*this.opacity))});h&&(a.Ay=function(a){return a?this.k===a:!1},a.Qy=function(a){var b=this.qa(),c=b.dd();if(!c.length)return!1;var e=c[0],d=e,l,f;l=1;for(f=c.length;l<f;l++)if(e=c[l],0===a){if(e.k.index>d.k.index||e.k.index===d.k.index&&e.Rd()>d.Rd())d=e}else if(e.k.index<d.k.index||e.k.index===d.k.index&&e.Rd()<d.Rd())d=e;b.Oi(d);return!0},e.Jy=function(){var a=
|
||||
this.k,b=a.e;b.length&&b[b.length-1]===this||(a.ph(this,!1),a.Eh(this,!1),this.b.Y=!0)},e.Hy=function(){var a=this.k,b=a.e;b.length&&b[0]===this||(a.ph(this,!1),a.jx(this),this.b.Y=!0)},e.Iy=function(a){a&&a!=this.k&&(this.k.ph(this,!0),this.k=a,a.Eh(this,!0),this.b.Y=!0)},e.Bz=function(a,b){var c=0===a;if(b){var e=b.Fm(this);e&&e.uid!==this.uid&&(this.k.index!==e.k.index&&(this.k.ph(this,!0),this.k=e.k,e.k.Eh(this,!0)),this.k.Nw(this,e,c),this.b.Y=!0)}},l.Ey=function(a){a.Na(this.k.Rq)},l.Dy=function(a){a.Fb(this.k.name)},
|
||||
l.Az=function(a){a.Na(this.Rd())});c&&(e.az=function(a,b){if(this.b.C){var c=this.type.Em(b);if(!(0>c)){var e=1===a;this.Se[c]!==e&&(this.Se[c]=e,this.Id(),this.b.Y=!0)}}},e.bz=function(a,b,c){if(this.b.C){var e=this.type.Em(a);0>e||(a=this.type.T[e],e=this.$a[e],b=Math.floor(b),0>b||b>=e.length||(1===this.b.C.Vv(a.nb,b)&&(c/=100),e[b]!==c&&(e[b]=c,a.B&&(this.b.Y=!0))))}})};Nb=function(){this.fm=this.Zl=!0;this.type.$o=!0;this.b.Y=!0;var f,r,t=this.$l;f=0;for(r=t.length;f<r;++f)t[f](this);this.k.Yc&&
|
||||
this.Ha()};Ob=function(f){f&&this.$l.push(f)};Qb=function(){if(this.Zl){var f=this.xa,r=this.Xe;f.set(this.x,this.y,this.x+this.width,this.y+this.height);f.offset(-this.tc*this.width,-this.uc*this.height);this.j?(f.offset(-this.x,-this.y),r.Kr(f,this.j),r.offset(this.x,this.y),r.jp(f)):r.jl(f);f.normalize();this.Zl=!1;this.Yx()}};var f=new wa(0,0,0,0);Rb=function(){if(this.k.Yc){var q=this.k.Rb,r=this.xa;f.set(q.pc(r.left),q.qc(r.top),q.pc(r.right),q.qc(r.bottom));this.xc.Ph(f)||(this.xc.right<this.xc.left?
|
||||
q.update(this,null,f):q.update(this,this.xc,f),this.xc.Kh(f),this.k.Gd=!0)}};Sb=function(){if(this.fm&&this.Ih){this.Ha();var q=this.type.op,r=this.xa;f.set(q.pc(r.left),q.qc(r.top),q.pc(r.right),q.qc(r.bottom));this.cf.Ph(f)||(this.cf.right<this.cf.left?q.update(this,null,f):q.update(this,this.cf,f),this.cf.Kh(f),this.fm=!1)}};Pb=function(f,r){return this.xa.ad(f,r)&&this.Xe.ad(f,r)?this.Yr?this.Vz(f,r):this.Md&&!this.Md.Dw()?(this.Md.gu(this.width,this.height,this.j),this.Md.ad(f-this.x,r-this.y)):
|
||||
!0:!1};Jb=function(){this.type.zl();return this.Tf};Tb=function(){this.k.to();return this.Jd};Ub=function(){N(this.wa);var f,r,t,b=!0;f=0;for(r=this.Se.length;f<r;f++)this.Se[f]&&(t=this.type.T[f],this.wa.push(t),t.jd||(b=!1));this.ks=!!this.wa.length;this.He=b};Kb=function(){return"Inst"+this.qr};tb=function(f){if(f&&f.jc&&f.type!=this){var r,t,b;r=0;for(t=f.siblings.length;r<t;r++)if(b=f.siblings[r],b.type==this)return b}f=this.qa().dd();return f.length?f[0]:null};ub=function(f){var r=this.qa().dd();
|
||||
return r.length?r[f.Zh()%r.length]:null};sb=function(){if(this.sh&&!this.V){var f,r;f=0;for(r=this.e.length;f<r;f++)this.e[f].Tf=f;var t=f,b=this.b.Nd;f=0;for(r=b.length;f<r;++f)b[f].type===this&&(b[f].Tf=t++);this.sh=!1}};Db=function(f){if(f<this.e.length)return this.e[f];f-=this.e.length;var r=this.b.Nd,t,b;t=0;for(b=r.length;t<b;++t)if(r[t].type===this){if(0===f)return r[t];--f}return null};vb=function(){return this.Je[this.Od]};wb=function(){this.Od++;this.Od===this.Je.length?this.Je.push(new rb(this)):
|
||||
(this.Je[this.Od].Aa=!0,N(this.Je[this.Od].ga))};xb=function(){this.Od++;this.Od===this.Je.length&&this.Je.push(new rb(this));var f=this.Je[this.Od],r=this.Je[this.Od-1];r.Aa?f.Aa=!0:(f.Aa=!1,Da(f.e,r.e));N(f.ga)};yb=function(){this.Od--};zb=function(f){var r,t,b,p,k,d=0;if(!this.V)for(r=0,t=this.Ua.length;r<t;r++)for(k=this.Ua[r],b=0,p=k.Ya.length;b<p;b++){if(f===k.Ya[b].name)return this.Ta.lastBehIndex=d,k.Ya[b];d++}r=0;for(t=this.Ya.length;r<t;r++){if(f===this.Ya[r].name)return this.Ta.lastBehIndex=
|
||||
d,this.Ya[r];d++}return null};Ab=function(f){return this.bk(f)?this.Ta.lastBehIndex:-1};Bb=function(f){var r,t;r=0;for(t=this.T.length;r<t;r++)if(this.T[r].name===f)return r;return-1};Cb=function(){if(this.jc&&!this.V){var f,r,t,b,p,k,d;this.zl();k=this.qa();var h=k.Aa,c=(f=this.b.Mb())&&f.Kb&&f.Kb.gd;f=0;for(r=this.Dc.length;f<r;f++)if(p=this.Dc[f],p!==this&&(p.zl(),d=p.qa(),d.Aa=h,!h)){N(d.e);t=0;for(b=k.e.length;t<b;++t)d.e[t]=p.Hm(k.e[t].Tf);if(c)for(N(d.ga),t=0,b=k.ga.length;t<b;++t)d.ga[t]=
|
||||
p.Hm(k.ga[t].Tf)}}};Ib=function(){return"Type"+this.fa};hc=function(f,r,t){if("undefined"===typeof f||"undefined"===typeof t)return!1;switch(r){case 0:return f===t;case 1:return f!==t;case 2:return f<t;case 3:return f<=t;case 4:return f>t;case 5:return f>=t;default:return!1}}})();
|
||||
var rc={inverse:{src:"varying mediump vec2 vTex;\nuniform lowp sampler2D samplerFront;\nuniform lowp float intensity;\nvoid main(void)\n{\nlowp vec4 front = texture2D(samplerFront, vTex);\nlowp vec3 inverse = vec3(front.a - front.rgb);\ngl_FragColor = vec4(mix(front.rgb, inverse, intensity), front.a);\n}",Qj:0,Rj:0,nm:!1,jd:!0,Xl:!1,aa:[["intensity",0,1]]}};function vc(f){this.b=f}
|
||||
(function(){function f(a){-1===lb.indexOf(a)&&lb.push(a)}function q(a){var b=a.n,c;try{c=b.play()}catch(e){f(a);return}c?c.catch(function(){f(a)}):Fc&&!C.ec&&f(a)}function r(){var a,b,c,e;Gc||Eb||!z||(t(),"running"===z.state&&(Gc=!0));var d=lb.slice(0);N(lb);if(!ba)for(a=0,b=d.length;a<b;++a)c=d[a],c.Gb||c.Fc||(e=c.n.play())&&e.catch(function(){f(c)})}function t(){"suspended"===z.state&&z.resume&&z.resume();if(z.createBuffer){var a=z.createBuffer(1,220,22050),b=z.createBufferSource();b.buffer=a;b.connect(z.destination);
|
||||
h(b)}}function b(a){0>a&&(a=0);1<a&&(a=1);return Math.log(a)/Math.log(10)*20}function p(a){a=a.toLowerCase();return V.hasOwnProperty(a)&&V[a].length?V[a][0].Oc():z.destination}function k(){return z.createGain?z.createGain():z.createGainNode()}function d(a){return z.createDelay?z.createDelay(a):z.createDelayNode(a)}function h(a,b){a.start?a.start(b||0):a.noteOn(b||0)}function c(a,b,c,e){a.start?a.start(e||0,b):a.noteGrainOn(e||0,b,c-b)}function a(a){try{a.stop?a.stop(0):a.noteOff(0)}catch(b){}}function e(a,
|
||||
b,c,e,d,g){this.type="filter";this.Qb=[a,b,c,e,d,g];this.ka=k();this.R=k();this.R.gain.value=g;this.P=k();this.P.gain.value=1-g;this.ib=z.createBiquadFilter();this.ib.type="number"===typeof this.ib.type?a:Mc[a];this.ib.frequency.value=b;this.ib.detune&&(this.ib.detune.value=c);this.ib.Q.value=e;this.ib.gain.value=d;this.ka.connect(this.ib);this.ka.connect(this.P);this.ib.connect(this.R)}function l(a,b,c){this.type="delay";this.Qb=[a,b,c];this.ka=k();this.R=k();this.R.gain.value=c;this.P=k();this.P.gain.value=
|
||||
1-c;this.Ei=k();this.cd=d(a);this.cd.delayTime.value=a;this.Lj=k();this.Lj.gain.value=b;this.ka.connect(this.Ei);this.ka.connect(this.P);this.Ei.connect(this.R);this.Ei.connect(this.cd);this.cd.connect(this.Lj);this.Lj.connect(this.Ei)}function g(a,b,c,e){this.type="convolve";this.Qb=[b,c,e];this.ka=k();this.R=k();this.R.gain.value=c;this.P=k();this.P.gain.value=1-c;this.Hf=z.createConvolver();a&&(this.Hf.normalize=b,this.Hf.buffer=a);this.ka.connect(this.Hf);this.ka.connect(this.P);this.Hf.connect(this.R)}
|
||||
function n(a,b,c,e,g){this.type="flanger";this.Qb=[a,b,c,e,g];this.ka=k();this.P=k();this.P.gain.value=1-g/2;this.R=k();this.R.gain.value=g/2;this.Vj=k();this.Vj.gain.value=e;this.cd=d(a+b);this.cd.delayTime.value=a;this.Db=z.createOscillator();this.Db.frequency.value=c;this.Ic=k();this.Ic.gain.value=b;this.ka.connect(this.cd);this.ka.connect(this.P);this.cd.connect(this.R);this.cd.connect(this.Vj);this.Vj.connect(this.cd);this.Db.connect(this.Ic);this.Ic.connect(this.cd.delayTime);h(this.Db)}function L(a,
|
||||
b,c,e,d,g){this.type="phaser";this.Qb=[a,b,c,e,d,g];this.ka=k();this.P=k();this.P.gain.value=1-g/2;this.R=k();this.R.gain.value=g/2;this.ib=z.createBiquadFilter();this.ib.type="number"===typeof this.ib.type?7:"allpass";this.ib.frequency.value=a;this.ib.detune&&(this.ib.detune.value=b);this.ib.Q.value=c;this.Db=z.createOscillator();this.Db.frequency.value=d;this.Ic=k();this.Ic.gain.value=e;this.ka.connect(this.ib);this.ka.connect(this.P);this.ib.connect(this.R);this.Db.connect(this.Ic);this.Ic.connect(this.ib.frequency);
|
||||
h(this.Db)}function w(a){this.type="gain";this.Qb=[a];this.ra=k();this.ra.gain.value=a}function m(a,b){this.type="tremolo";this.Qb=[a,b];this.ra=k();this.ra.gain.value=1-b/2;this.Db=z.createOscillator();this.Db.frequency.value=a;this.Ic=k();this.Ic.gain.value=b/2;this.Db.connect(this.Ic);this.Ic.connect(this.ra.gain);h(this.Db)}function u(a,b){this.type="ringmod";this.Qb=[a,b];this.ka=k();this.R=k();this.R.gain.value=b;this.P=k();this.P.gain.value=1-b;this.Vi=k();this.Vi.gain.value=0;this.Db=z.createOscillator();
|
||||
this.Db.frequency.value=a;this.Db.connect(this.Vi.gain);h(this.Db);this.ka.connect(this.Vi);this.ka.connect(this.P);this.Vi.connect(this.R)}function fa(a,b,c,e,d){this.type="distortion";this.Qb=[a,b,c,e,d];this.ka=k();this.Uk=k();this.Tk=k();this.Gx(c,Math.pow(10,e/20));this.R=k();this.R.gain.value=d;this.P=k();this.P.gain.value=1-d;this.Dl=z.createWaveShaper();this.Ij=new Float32Array(65536);this.Iv(a,b);this.Dl.Ij=this.Ij;this.ka.connect(this.Uk);this.ka.connect(this.P);this.Uk.connect(this.Dl);
|
||||
this.Dl.connect(this.Tk);this.Tk.connect(this.R)}function ha(a,b,c,e,d){this.type="compressor";this.Qb=[a,b,c,e,d];this.ra=z.createDynamicsCompressor();try{this.ra.threshold.value=a,this.ra.knee.value=b,this.ra.ratio.value=c,this.ra.attack.value=e,this.ra.release.value=d}catch(g){}}function W(a,b){this.type="analyser";this.Qb=[a,b];this.ra=z.createAnalyser();this.ra.fftSize=a;this.ra.smoothingTimeConstant=b;this.Gv=new Float32Array(this.ra.frequencyBinCount);this.Nr=new Uint8Array(a);this.Ni=0}function E(){this.za=
|
||||
null;this.wk=0}function x(a,b){this.src=a;this.ea=H;this.Td=b;this.wj=!1;var c=this;this.ah=this.kh=null;this.mh=[];this.fl=0;this.wo=this.Tj=this.Tr=this.Ok=!1;1===H&&b&&!mb&&(this.ea=0,this.kh=k());this.le=this.na=null;var e;switch(this.ea){case 0:this.na=new Audio;this.na.crossOrigin="anonymous";this.na.addEventListener("canplaythrough",function(){c.wo=!0});1===H&&z.createMediaElementSource&&!/wiiu/i.test(navigator.userAgent)&&(this.Tr=!0,this.na.addEventListener("canplay",function(){!c.ah&&c.na&&
|
||||
(c.ah=z.createMediaElementSource(c.na),c.ah.connect(c.kh))}));this.na.autoplay=!1;this.na.Qz="auto";this.na.src=a;break;case 1:C.lk?C.Ap(a,function(a){c.le=a;c.tp()},function(){c.Tj=!0}):(e=new XMLHttpRequest,e.open("GET",a,!0),e.responseType="arraybuffer",e.onload=function(){c.le=e.response;c.tp()},e.onerror=function(){c.Tj=!0},e.send());break;case 2:this.na=!0;break;case 3:this.na=!0}}function y(a,b){var c=this;this.tag=b;this.Gb=this.Qd=!0;this.src=a.src;this.buffer=a;this.ea=H;this.Td=a.Td;this.playbackRate=
|
||||
1;this.Og=!0;this.Fc=this.Tc=!1;this.yc=0;this.li=this.Rg=this.Ud=!1;this.volume=1;this.En=function(a){if(!c.Fc&&!c.Tc){var b=this;b||(b=a.target);b===c.vj&&(c.Og=!0,c.Gb=!0,I=c.tag,C.trigger(vc.prototype.g.pj,S))}};this.vj=null;this.Pg=1===P&&!this.Td||2===P;this.dh=1;this.startTime=this.Pg?C.Nb.Z:C.Oe.Z;this.lb=this.qb=null;this.Wd=!1;this.Ob=null;this.gr=this.fr=this.er=this.dr=this.ir=this.hr=0;this.n=null;var e=!1;1!==this.ea||0!==this.buffer.ea||this.buffer.Tr||(this.ea=0);switch(this.ea){case 0:this.Td?
|
||||
(this.n=a.na,e=!a.wj,a.wj=!0):(this.n=new Audio,this.n.crossOrigin="anonymous",this.n.autoplay=!1,this.n.src=a.na.src,e=!0);e&&this.n.addEventListener("ended",function(){I=c.tag;c.Gb=!0;C.trigger(vc.prototype.g.pj,S)});break;case 1:this.qb=k();this.qb.connect(p(b));1===this.buffer.ea?a.na&&(this.n=z.createBufferSource(),this.n.buffer=a.na,this.n.connect(this.qb)):(this.n=this.buffer.na,this.buffer.kh.connect(this.qb),this.buffer.wj||(this.buffer.wj=!0,this.buffer.na.addEventListener("ended",function(){I=
|
||||
c.tag;c.Gb=!0;C.trigger(vc.prototype.g.pj,S)})));break;case 2:this.n=new window.Media(D+this.src,null,null,function(a){a===window.Media.MEDIA_STOPPED&&(c.Og=!0,c.Gb=!0,I=c.tag,C.trigger(vc.prototype.g.pj,S))});break;case 3:this.n=!0}}function F(a,b){var c=a.Wf()?1:0,e=b.Wf()?1:0;return c===e?0:c<e?1:-1}function G(a,b){N(za);if(a.length){var c,e,d;c=0;for(e=B.length;c<e;c++)d=B[c],nb(a,d.tag)&&za.push(d);b&&za.sort(F)}else O&&!O.Sf()&&(N(za),za[0]=O)}function K(a,b){V.hasOwnProperty(a)?V[a].push(b):
|
||||
V[a]=[b];var c,e,d,g,f=z.destination;if(V.hasOwnProperty(a)&&(d=V[a],d.length))for(f=d[0].Oc(),c=0,e=d.length;c<e;c++)g=d[c],c+1===e?g.$c(z.destination):g.$c(d[c+1].Oc());G(a);c=0;for(e=za.length;c<e;c++)za[c].qx(f);Ka&&Fb===a&&(Ka.disconnect(),Ka.connect(f))}function R(){}function T(){}function M(){}var v=vc.prototype;v.la=function(a){this.Ga=a;this.b=a.b};v.la.prototype.N=function(){};var C=null,S=null,I="",D="",H=0,z=null,J=[],B=[],O=null,ja=!1,P=0,ba=!1,U=1,ya=0,Qa=0,Eb=!1,Gb=1,Hb=1,Hc=10,Ic=
|
||||
1E4,Jc=1,Ka=null,Fb="",Fc=!1,lb=[],mb=!1,Gc=!1;document.addEventListener("pointerup",r,!0);document.addEventListener("touchend",r,!0);document.addEventListener("click",r,!0);document.addEventListener("keydown",r,!0);document.addEventListener("gamepadconnected",r,!0);var V={},Mc="lowpass highpass bandpass lowshelf highshelf peaking notch allpass".split(" ");e.prototype.$c=function(a){this.R.disconnect();this.R.connect(a);this.P.disconnect();this.P.connect(a)};e.prototype.remove=function(){this.ka.disconnect();
|
||||
this.ib.disconnect();this.R.disconnect();this.P.disconnect()};e.prototype.Oc=function(){return this.ka};l.prototype.$c=function(a){this.R.disconnect();this.R.connect(a);this.P.disconnect();this.P.connect(a)};l.prototype.remove=function(){this.ka.disconnect();this.Ei.disconnect();this.cd.disconnect();this.Lj.disconnect();this.R.disconnect();this.P.disconnect()};l.prototype.Oc=function(){return this.ka};g.prototype.$c=function(a){this.R.disconnect();this.R.connect(a);this.P.disconnect();this.P.connect(a)};
|
||||
g.prototype.remove=function(){this.ka.disconnect();this.Hf.disconnect();this.R.disconnect();this.P.disconnect()};g.prototype.Oc=function(){return this.ka};n.prototype.$c=function(a){this.P.disconnect();this.P.connect(a);this.R.disconnect();this.R.connect(a)};n.prototype.remove=function(){this.ka.disconnect();this.cd.disconnect();this.Db.disconnect();this.Ic.disconnect();this.P.disconnect();this.R.disconnect();this.Vj.disconnect()};n.prototype.Oc=function(){return this.ka};L.prototype.$c=function(a){this.P.disconnect();
|
||||
this.P.connect(a);this.R.disconnect();this.R.connect(a)};L.prototype.remove=function(){this.ka.disconnect();this.ib.disconnect();this.Db.disconnect();this.Ic.disconnect();this.P.disconnect();this.R.disconnect()};L.prototype.Oc=function(){return this.ka};w.prototype.$c=function(a){this.ra.disconnect();this.ra.connect(a)};w.prototype.remove=function(){this.ra.disconnect()};w.prototype.Oc=function(){return this.ra};m.prototype.$c=function(a){this.ra.disconnect();this.ra.connect(a)};m.prototype.remove=
|
||||
function(){this.Db.disconnect();this.Ic.disconnect();this.ra.disconnect()};m.prototype.Oc=function(){return this.ra};u.prototype.$c=function(a){this.R.disconnect();this.R.connect(a);this.P.disconnect();this.P.connect(a)};u.prototype.remove=function(){this.Db.disconnect();this.Vi.disconnect();this.ka.disconnect();this.R.disconnect();this.P.disconnect()};u.prototype.Oc=function(){return this.ka};fa.prototype.Gx=function(a,b){.01>a&&(a=.01);this.Uk.gain.value=a;this.Tk.gain.value=Math.pow(1/a,.6)*b};
|
||||
fa.prototype.shape=function(a,b,c){var e=1.05*c*b-b;c=0>a?-1:1;a=0>a?-a:a;b=a<b?a:b+e*(1-Math.exp(-(1/e)*(a-b)));return b*c};fa.prototype.Iv=function(a,b){for(var c=Math.pow(10,a/20),e=Math.pow(10,b/20),d=0,g=0;32768>g;++g)d=g/32768,d=this.shape(d,c,e),this.Ij[32768+g]=d,this.Ij[32768-g-1]=-d};fa.prototype.$c=function(a){this.R.disconnect();this.R.connect(a);this.P.disconnect();this.P.connect(a)};fa.prototype.remove=function(){this.ka.disconnect();this.Uk.disconnect();this.Dl.disconnect();this.Tk.disconnect();
|
||||
this.R.disconnect();this.P.disconnect()};fa.prototype.Oc=function(){return this.ka};ha.prototype.$c=function(a){this.ra.disconnect();this.ra.connect(a)};ha.prototype.remove=function(){this.ra.disconnect()};ha.prototype.Oc=function(){return this.ra};W.prototype.Sa=function(){this.ra.getFloatFrequencyData(this.Gv);this.ra.getByteTimeDomainData(this.Nr);for(var a=this.ra.fftSize,c=0,e=this.Ni=0,d=0;c<a;c++)d=(this.Nr[c]-128)/128,0>d&&(d=-d),this.Ni<d&&(this.Ni=d),e+=d*d;this.Ni=b(this.Ni);b(Math.sqrt(e/
|
||||
a))};W.prototype.$c=function(a){this.ra.disconnect();this.ra.connect(a)};W.prototype.remove=function(){this.ra.disconnect()};W.prototype.Oc=function(){return this.ra};E.prototype.Wi=function(a){this.za=a};E.prototype.fk=function(){return!!this.za};E.prototype.Sa=function(){};x.prototype.rx=function(){var a,b,c,e;c=a=0;for(b=B.length;a<b;++a)e=B[a],B[c]=e,e.buffer===this?e.stop():++c;B.length=c;this.ah&&(this.ah.disconnect(),this.ah=null);this.kh&&(this.kh.disconnect(),this.kh=null);this.le=this.na=
|
||||
null};x.prototype.tp=function(){if(!this.na&&this.le){var a=this;if(z.decodeAudioData)z.decodeAudioData(this.le,function(b){a.na=b;a.le=null;var c,e,d;if(ka(a.Qk)||ba)ka(a.Fj)||(c=a.Fj.Hf,c.normalize=a.Qq,c.buffer=b);else if(a.mh.length){c=0;for(e=a.mh.length;c<e;c++){b=a.mh[c];d=new y(a,b.Wr);d.Zn(!0);if("undefined"!==typeof b.Sq&&(b.za=C.Xh(b.Sq),!b.za))continue;if(b.za){var g=Ta(b.za.x,b.za.y,-b.za.k.rb(),ya,Qa,!0),f=Ta(b.za.x,b.za.y,-b.za.k.rb(),ya,Qa,!1);d.Yn(g,f,Ia(b.za.j-b.za.k.rb()),b.Qm,
|
||||
b.xn,b.An);d.Wi(b.za)}else d.Yn(b.x,b.y,b.Tt,b.Qm,b.xn,b.An);d.play(a.rn,a.vo,a.fl);a.Ok&&d.pause();B.push(d)}N(a.mh)}else d=new y(a,a.Qk||""),d.play(a.rn,a.vo,a.fl),a.Ok&&d.pause(),B.push(d)},function(){a.Tj=!0});else if(this.na=z.createBuffer(this.le,!1),this.le=null,ka(this.Qk)||ba)ka(this.Fj)||(b=this.Fj.Hf,b.normalize=this.Qq,b.buffer=this.na);else{var b=new y(this,this.Qk);b.play(this.rn,this.vo,this.fl);this.Ok&&b.pause();B.push(b)}}};x.prototype.Wp=function(){switch(this.ea){case 0:var a=
|
||||
4<=this.na.readyState;a&&(this.wo=!0);return a||this.wo;case 1:return!!this.le||!!this.na;case 2:return!0;case 3:return!0}return!1};x.prototype.xw=function(){switch(this.ea){case 0:return this.Wp();case 1:return!!this.na;case 2:return!0;case 3:return!0}return!1};x.prototype.ow=function(){switch(this.ea){case 0:return!!this.na.error;case 1:return this.Tj}return!1};y.prototype.Sf=function(){switch(this.ea){case 0:return this.n.ended;case 1:return 1===this.buffer.ea?!this.Qd&&!this.Gb&&this.n.loop||
|
||||
this.Fc?!1:this.Og:this.n.ended;case 2:return this.Og;case 3:!0}return!0};y.prototype.hu=function(){return this.Qd||this.Gb?!0:this.Sf()};y.prototype.Zn=function(a){1===H&&(!this.Wd&&a?this.qb&&(this.lb||(this.lb=z.createPanner(),this.lb.panningModel="number"===typeof this.lb.panningModel?Gb:["equalpower","HRTF","soundfield"][Gb],this.lb.distanceModel="number"===typeof this.lb.distanceModel?Hb:["linear","inverse","exponential"][Hb],this.lb.refDistance=Hc,this.lb.maxDistance=Ic,this.lb.rolloffFactor=
|
||||
Jc),this.qb.disconnect(),this.qb.connect(this.lb),this.lb.connect(p(this.tag)),this.Wd=!0):this.Wd&&!a&&this.qb&&(this.lb.disconnect(),this.qb.disconnect(),this.qb.connect(p(this.tag)),this.Wd=!1))};y.prototype.Yn=function(a,b,c,e,d,g){this.Wd&&1===H&&(this.lb.setPosition(a,b,0),this.lb.setOrientation(Math.cos(Q(c)),Math.sin(Q(c)),0),this.lb.coneInnerAngle=e,this.lb.coneOuterAngle=d,this.lb.coneOuterGain=g,this.hr=a,this.ir=b,this.dr=c,this.er=e,this.fr=d,this.gr=g)};y.prototype.Wi=function(a){this.Wd&&
|
||||
1===H&&(this.Ob||(this.Ob=new E),this.Ob.Wi(a))};y.prototype.Sa=function(a){if(this.Wd&&1===H&&this.Ob&&this.Ob.fk()&&this.Wf()){this.Ob.Sa(a);a=this.Ob.za;var b=Ta(a.x,a.y,-a.k.rb(),ya,Qa,!0),c=Ta(a.x,a.y,-a.k.rb(),ya,Qa,!1);this.lb.setPosition(b,c,0);b=0;"undefined"!==typeof this.Ob.za.j&&(b=a.j-a.k.rb(),this.lb.setOrientation(Math.cos(b),Math.sin(b),0))}};y.prototype.play=function(a,b,e,d){var g=this.n;this.Ud=a;this.volume=b;e=e||0;d=d||0;switch(this.ea){case 0:1!==g.playbackRate&&(g.playbackRate=
|
||||
1);g.volume!==b*U&&(g.volume=b*U);g.loop!==a&&(g.loop=a);g.muted&&(g.muted=!1);if(g.currentTime!==e)try{g.currentTime=e}catch(f){}q(this);break;case 1:this.muted=!1;this.dh=1;if(1===this.buffer.ea)this.qb.gain.value=b*U,this.Qd||(this.n=z.createBufferSource(),this.n.buffer=this.buffer.na,this.n.connect(this.qb)),this.n.onended=this.En,this.vj=this.n,this.n.loop=a,this.Og=!1,0===e?h(this.n,d):c(this.n,e,this.kf(),d);else{1!==g.playbackRate&&(g.playbackRate=1);g.loop!==a&&(g.loop=a);g.volume=b*U;if(g.currentTime!==
|
||||
e)try{g.currentTime=e}catch(l){}q(this)}break;case 2:(!this.Qd&&this.Gb||0!==e)&&g.seekTo(e);g.play();this.Og=!1;break;case 3:C.cc?AppMobi.context.playSound(this.src,a):AppMobi.player.playSound(this.src,a)}this.playbackRate=1;this.startTime=(this.Pg?C.Nb.Z:C.Oe.Z)-e;this.Fc=this.Gb=this.Qd=!1};y.prototype.stop=function(){switch(this.ea){case 0:this.n.paused||this.n.pause();break;case 1:1===this.buffer.ea?a(this.n):this.n.paused||this.n.pause();break;case 2:this.n.stop();break;case 3:C.cc&&AppMobi.context.stopSound(this.src)}this.Gb=
|
||||
!0;this.Fc=!1};y.prototype.pause=function(){if(!(this.Qd||this.Gb||this.Sf()||this.Fc)){switch(this.ea){case 0:this.n.paused||this.n.pause();break;case 1:1===this.buffer.ea?(this.yc=this.Jm(!0),this.Ud&&(this.yc=this.yc%this.kf()),this.Fc=!0,a(this.n)):this.n.paused||this.n.pause();break;case 2:this.n.pause();break;case 3:C.cc&&AppMobi.context.stopSound(this.src)}this.Fc=!0}};y.prototype.xx=function(){if(!(this.Qd||this.Gb||this.Sf())&&this.Fc){switch(this.ea){case 0:q(this);break;case 1:1===this.buffer.ea?
|
||||
(this.n=z.createBufferSource(),this.n.buffer=this.buffer.na,this.n.connect(this.qb),this.n.onended=this.En,this.vj=this.n,this.n.loop=this.Ud,this.qb.gain.value=U*this.volume*this.dh,this.Al(),this.startTime=(this.Pg?C.Nb.Z:C.Oe.Z)-this.yc/(this.playbackRate||.001),c(this.n,this.yc,this.kf())):q(this);break;case 2:this.n.play();break;case 3:C.cc&&AppMobi.context.resumeSound(this.src)}this.Fc=!1}};y.prototype.seek=function(a){if(!(this.Qd||this.Gb||this.Sf()))switch(this.ea){case 0:try{this.n.currentTime=
|
||||
a}catch(b){}break;case 1:if(1===this.buffer.ea)this.Fc?this.yc=a:(this.pause(),this.yc=a,this.xx());else try{this.n.currentTime=a}catch(c){}break;case 3:C.cc&&AppMobi.context.seekSound(this.src,a)}};y.prototype.qx=function(a){1===this.ea&&(this.Wd?(this.lb.disconnect(),this.lb.connect(a)):(this.qb.disconnect(),this.qb.connect(a)))};y.prototype.kf=function(){var a=0;switch(this.ea){case 0:"undefined"!==typeof this.n.duration&&(a=this.n.duration);break;case 1:a=this.buffer.na.duration;break;case 2:a=
|
||||
this.n.getDuration();break;case 3:C.cc&&(a=AppMobi.context.getDurationSound(this.src))}return a};y.prototype.Jm=function(a){var b=this.kf(),c=0;switch(this.ea){case 0:"undefined"!==typeof this.n.currentTime&&(c=this.n.currentTime);break;case 1:if(1===this.buffer.ea){if(this.Fc)return this.yc;c=(this.Pg?C.Nb.Z:C.Oe.Z)-this.startTime}else"undefined"!==typeof this.n.currentTime&&(c=this.n.currentTime);break;case 3:C.cc&&(c=AppMobi.context.getPlaybackTimeSound(this.src))}a&&(c*=this.playbackRate);!this.Ud&&
|
||||
c>b&&(c=b);return c};y.prototype.Wf=function(){return!this.Fc&&!this.Qd&&!this.Gb&&!this.Sf()};y.prototype.Mx=function(){return!this.Qd&&!this.Gb&&!this.Sf()};y.prototype.Wx=function(){var a=this.volume*U;isFinite(a)||(a=0);switch(this.ea){case 0:"undefined"!==typeof this.n.volume&&this.n.volume!==a&&(this.n.volume=a);break;case 1:1===this.buffer.ea?this.qb.gain.value=a*this.dh:"undefined"!==typeof this.n.volume&&this.n.volume!==a&&(this.n.volume=a)}};y.prototype.Oj=function(a){switch(this.ea){case 0:this.n.muted!==
|
||||
!!a&&(this.n.muted=!!a);break;case 1:1===this.buffer.ea?(this.dh=a?0:1,this.qb.gain.value=U*this.volume*this.dh):this.n.muted!==!!a&&(this.n.muted=!!a)}};y.prototype.Hx=function(){this.Rg=!0;this.Oj(this.Rg||this.li)};y.prototype.Ir=function(a){this.li=!!a;this.Oj(this.Rg||this.li)};y.prototype.Al=function(){var a=this.playbackRate;this.Pg&&(a*=C.vh);switch(this.ea){case 0:this.n.playbackRate!==a&&(this.n.playbackRate=a);break;case 1:1===this.buffer.ea?this.n.playbackRate.value!==a&&(this.n.playbackRate.value=
|
||||
a):this.n.playbackRate!==a&&(this.n.playbackRate=a)}};y.prototype.Jx=function(b){switch(this.ea){case 0:b?this.Wf()?(this.Tc=!0,this.n.pause()):this.Tc=!1:this.Tc&&(this.n.play(),this.Tc=!1);break;case 1:b?this.Wf()?(this.Tc=!0,1===this.buffer.ea?(this.yc=this.Jm(!0),this.Ud&&(this.yc=this.yc%this.kf()),a(this.n)):this.n.pause()):this.Tc=!1:this.Tc&&(1===this.buffer.ea?(this.n=z.createBufferSource(),this.n.buffer=this.buffer.na,this.n.connect(this.qb),this.n.onended=this.En,this.vj=this.n,this.n.loop=
|
||||
this.Ud,this.qb.gain.value=U*this.volume*this.dh,this.Al(),this.startTime=(this.Pg?C.Nb.Z:C.Oe.Z)-this.yc/(this.playbackRate||.001),c(this.n,this.yc,this.kf())):this.n.play(),this.Tc=!1);break;case 2:b?this.Wf()?(this.n.pause(),this.Tc=!0):this.Tc=!1:this.Tc&&(this.Tc=!1,this.n.play())}};v.da=function(a){this.type=a;C=this.b=a.b;S=this;this.Gc=null;this.si=-600;this.b.lk&&(mb=!0);!(this.b.Ug||this.b.ei&&(this.b.Vm||this.b.hk))||this.b.jk||this.b.Ca||this.b.Up||mb||(Fc=!0);z=null;"undefined"!==typeof AudioContext?
|
||||
(H=1,z=new AudioContext):"undefined"!==typeof webkitAudioContext&&(H=1,z=new webkitAudioContext);this.b.Ug&&z&&(z.close&&z.close(),"undefined"!==typeof AudioContext?z=new AudioContext:"undefined"!==typeof webkitAudioContext&&(z=new webkitAudioContext));1!==H&&(this.b.Qc&&"undefined"!==typeof window.Media?H=2:this.b.Vp&&(H=3));2===H&&(D=location.href,a=D.lastIndexOf("/"),-1<a&&(D=D.substr(0,a+1)),D=D.replace("file://",""));if(this.b.zw&&this.b.Aw&&"undefined"===typeof Audio)alert("It looks like you're using Safari for Windows without Quicktime. Audio cannot be played until Quicktime is installed."),
|
||||
this.b.ie(this);else{if(this.b.cc)ja=this.b.ei;else try{ja=!!(new Audio).canPlayType('audio/ogg; codecs="vorbis"')&&!this.b.mk}catch(b){ja=!1}this.b.tl(this)}};var ra=v.da.prototype;ra.N=function(){this.b.Cg=this;P=this.q[0];this.Ge=this.q[1];this.ax=0!==this.q[2];this.Oq=0;Gb=this.q[3];Hb=this.q[4];this.si=-this.q[5];Hc=this.q[6];Ic=this.q[7];Jc=this.q[8];this.Gc=new E;var a=this.b.M||this.b.width,b=this.b.L||this.b.height;1===H&&(z.listener.setPosition(a/2,b/2,this.si),z.listener.setOrientation(0,
|
||||
0,1,0,-1,0),window.c2OnAudioMicStream=function(a,b){Ka&&Ka.disconnect();Fb=b.toLowerCase();Ka=z.createMediaStreamSource(a);Ka.connect(p(Fb))});this.b.Wo(function(a){S.Ww(a)});var c=this;this.b.Uo(function(a){c.Bn(a)})};ra.Bn=function(a){var b,c,e;b=0;for(c=B.length;b<c;b++)e=B[b],e.Ob&&e.Ob.za===a&&(e.Ob.za=null,e.Wd&&e.Wf()&&e.Ud&&e.stop());this.Gc.za===a&&(this.Gc.za=null)};ra.eb=function(){var a={silent:ba,masterVolume:U,listenerZ:this.si,listenerUid:this.Gc.fk()?this.Gc.za.uid:-1,playing:[],effects:{}},
|
||||
b=a.playing,c,e,d,g,f,l;c=0;for(e=B.length;c<e;c++)d=B[c],!d.Mx()||3===this.Ge||d.Td&&1===this.Ge||!d.Td&&2===this.Ge||(g=d.Jm(),d.Ud&&(g=g%d.kf()),g={tag:d.tag,buffersrc:d.buffer.src,is_music:d.Td,playbackTime:g,volume:d.volume,looping:d.Ud,muted:d.Rg,playbackRate:d.playbackRate,paused:d.Fc,resume_position:d.yc},d.Wd&&(g.pan={},l=g.pan,d.Ob&&d.Ob.fk()?l.objUid=d.Ob.za.uid:(l.x=d.hr,l.y=d.ir,l.a=d.dr),l.ia=d.er,l.oa=d.fr,l.og=d.gr),b.push(g));b=a.effects;for(f in V)if(V.hasOwnProperty(f)){d=[];c=
|
||||
0;for(e=V[f].length;c<e;c++)d.push({type:V[f][c].type,params:V[f][c].Qb});b[f]=d}return a};var Ya=[];ra.ub=function(a){var b=a.silent;U=a.masterVolume;this.si=a.listenerZ;this.Gc.Wi(null);var c=a.listenerUid;-1!==c&&(this.Gc.wk=c,Ya.push(this.Gc));var c=a.playing,d,f,h,k,p,t,q,r,v,x,y;if(3!==this.Ge)for(d=0,f=B.length;d<f;d++)v=B[d],v.Td&&1===this.Ge||(v.Td||2!==this.Ge)&&v.stop();for(p in V)if(V.hasOwnProperty(p))for(d=0,f=V[p].length;d<f;d++)V[p][d].remove();Xa(V);for(p in a.effects)if(a.effects.hasOwnProperty(p))for(t=
|
||||
a.effects[p],d=0,f=t.length;d<f;d++)switch(h=t[d].type,x=t[d].params,h){case "filter":K(p,new e(x[0],x[1],x[2],x[3],x[4],x[5]));break;case "delay":K(p,new l(x[0],x[1],x[2]));break;case "convolve":h=x[2];v=this.ak(h,!1);v.na?h=new g(v.na,x[0],x[1],h):(h=new g(null,x[0],x[1],h),v.Qq=x[0],v.Fj=h);K(p,h);break;case "flanger":K(p,new n(x[0],x[1],x[2],x[3],x[4]));break;case "phaser":K(p,new L(x[0],x[1],x[2],x[3],x[4],x[5]));break;case "gain":K(p,new w(x[0]));break;case "tremolo":K(p,new m(x[0],x[1]));break;
|
||||
case "ringmod":K(p,new u(x[0],x[1]));break;case "distortion":K(p,new fa(x[0],x[1],x[2],x[3],x[4]));break;case "compressor":K(p,new ha(x[0],x[1],x[2],x[3],x[4]));break;case "analyser":K(p,new W(x[0],x[1]))}d=0;for(f=c.length;d<f;d++)3===this.Ge||(a=c[d],h=a.buffersrc,k=a.is_music,p=a.tag,t=a.playbackTime,q=a.looping,r=a.volume,y=(x=a.pan)&&x.hasOwnProperty("objUid")?x.objUid:-1,k&&1===this.Ge)||!k&&2===this.Ge||((v=this.Fp(h,p,k,q,r))?(v.yc=a.resume_position,v.Zn(!!x),v.play(q,r,t),v.Al(),v.Wx(),v.Oj(v.Rg||
|
||||
v.li),a.paused&&v.pause(),a.muted&&v.Hx(),v.Oj(v.Rg||v.li),x&&(-1!==y?(v.Ob=v.Ob||new E,v.Ob.wk=y,Ya.push(v.Ob)):v.Yn(x.x,x.y,x.a,x.ia,x.oa,x.og))):(v=this.ak(h,k),v.fl=t,v.Ok=a.paused,x&&(-1!==y?v.mh.push({Sq:y,Qm:x.ia,xn:x.oa,An:x.og,Wr:p}):v.mh.push({x:x.x,y:x.y,Tt:x.a,Qm:x.ia,xn:x.oa,An:x.og,Wr:p}))));if(b&&!ba){d=0;for(f=B.length;d<f;d++)B[d].Ir(!0);ba=!0}else if(!b&&ba){d=0;for(f=B.length;d<f;d++)B[d].Ir(!1);ba=!1}};ra.je=function(){var a,b,c,e;a=0;for(b=Ya.length;a<b;a++)c=Ya[a],e=this.b.Xh(c.wk),
|
||||
c.Wi(e),c.wk=-1,e&&(ya=e.x,Qa=e.y);N(Ya)};ra.Ww=function(a){if(!this.ax){!a&&z&&z.resume&&(z.resume(),Eb=!1);var b,c;b=0;for(c=B.length;b<c;b++)B[b].Jx(a);a&&z&&z.suspend&&(z.suspend(),Eb=!0)}};ra.Sa=function(){var a=this.b.Jf,b,c,e;b=0;for(c=B.length;b<c;b++)e=B[b],e.Sa(a),0!==P&&e.Al();var d,g;for(d in V)if(V.hasOwnProperty(d))for(e=V[d],b=0,c=e.length;b<c;b++)g=e[b],g.Sa&&g.Sa();1===H&&this.Gc.fk()&&(this.Gc.Sa(a),ya=this.Gc.za.x,Qa=this.Gc.za.y,z.listener.setPosition(this.Gc.za.x,this.Gc.za.y,
|
||||
this.si))};var Za=[];ra.Ix=function(a){var b,c,e,d,g,f=0;b=0;for(c=a.length;b<c;++b)if(e=a[b],d=e[0],e=2*e[1],(g=4<d.length&&".ogg"===d.substr(d.length-4))&&ja||!g&&!ja)Za.push({filename:d,size:e,za:null}),f+=e;return f};ra.Ox=function(){var a,b,c,e;a=0;for(b=Za.length;a<b;++a)c=Za[a],e=this.b.xm+c.filename,c.za=this.ak(e,!1)};ra.Sv=function(){var a=0,b,c,e;b=0;for(c=Za.length;b<c;++b)e=Za[b],e.za.xw()||e.za.ow()||this.b.Ca||this.b.hk?a+=e.size:e.za.Wp()&&(a+=Math.floor(e.size/2));return a};ra.tx=
|
||||
function(){var a,b,c,e;c=a=0;for(b=J.length;a<b;++a)e=J[a],J[c]=e,e.Td?e.rx():++c;J.length=c};ra.ak=function(a,b){var c,e,d,g=null;c=0;for(e=J.length;c<e;c++)if(d=J[c],d.src===a){g=d;break}g||(mb&&b&&this.tx(),g=new x(a,b),J.push(g));return g};ra.Fp=function(a,b,c,e,d){var g,f,l;g=0;for(f=B.length;g<f;g++)if(l=B[g],l.src===a&&(l.hu()||c))return l.tag=b,l;a=this.ak(a,c);if(!a.na)return"<preload>"!==b&&(a.Qk=b,a.rn=e,a.vo=d),null;l=new y(a,b);B.push(l);return l};var za=[];R.prototype.pj=function(a){return nb(I,
|
||||
a)};v.g=new R;T.prototype.Play=function(a,b,c,e){!ba&&(c=Math.pow(10,c/20),isFinite(c)||(c=0),0>c&&(c=0),1<c&&(c=1),O=this.Fp(this.b.xm+a[0]+(ja?".ogg":".m4a"),e,a[1],0!==b,c))&&(O.Zn(!1),O.play(0!==b,c,0,this.Oq),this.Oq=0)};T.prototype.Ql=function(a){G(a);var b;a=0;for(b=za.length;a<b;a++)za[a].stop()};T.prototype.Qt=function(){var a,b;a=0;for(b=B.length;a<b;a++)B[a].stop()};v.J=new T;M.prototype.ys=function(a,b){G(b,!0);za.length?a.H(za[0].kf()):a.H(0)};v.Ma=new M})();function Y(f){this.b=f}
|
||||
(function(){function f(){k&&d&&window.OfflineClientInfo&&window.OfflineClientInfo.SetMessageCallback(function(b){h.Vw(b)})}function q(){}function r(){}function t(){}var b=Y.prototype;b.la=function(b){this.Ga=b;this.b=b.b};var p=b.la.prototype;p.N=function(){};var k=!1,d=!1;document.addEventListener("DOMContentLoaded",function(){if(window.C2_RegisterSW&&navigator.serviceWorker){var b=document.createElement("script");b.onload=function(){k=!0;f()};b.src="offlineClient.js";document.head.appendChild(b)}});
|
||||
var h=null;p.Wq=function(){d=!0;f()};b.da=function(b){this.type=b;this.b=b.b};p=b.da.prototype;p.N=function(){var b=this;window.addEventListener("resize",function(){b.b.trigger(Y.prototype.g.mt,b)});h=this;"undefined"!==typeof navigator.onLine&&(window.addEventListener("online",function(){b.b.trigger(Y.prototype.g.it,b)}),window.addEventListener("offline",function(){b.b.trigger(Y.prototype.g.gt,b)}));this.b.cc||(document.addEventListener("appMobi.device.update.available",function(){b.b.trigger(Y.prototype.g.Ml,
|
||||
b)}),document.addEventListener("backbutton",function(){b.b.trigger(Y.prototype.g.nj,b)}),document.addEventListener("menubutton",function(){b.b.trigger(Y.prototype.g.Go,b)}),document.addEventListener("searchbutton",function(){b.b.trigger(Y.prototype.g.nt,b)}),document.addEventListener("tizenhwkey",function(a){var e;switch(a.keyName){case "back":e=b.b.trigger(Y.prototype.g.nj,b);!e&&window.tizen&&window.tizen.application.getCurrentApplication().exit();break;case "menu":(e=b.b.trigger(Y.prototype.g.Go,
|
||||
b))||a.preventDefault()}}));this.b.mk&&"undefined"!==typeof Windows?Windows.UI.Core.SystemNavigationManager.getForCurrentView().addEventListener("backrequested",function(a){b.b.trigger(Y.prototype.g.nj,b)&&(a.handled=!0)}):this.b.Yp&&WinJS.Application&&(WinJS.Application.onbackclick=function(){return!!b.b.trigger(Y.prototype.g.nj,b)});this.b.Wo(function(a){a?b.b.trigger(Y.prototype.g.jt,b):b.b.trigger(Y.prototype.g.kt,b)})};p.Vw=function(b){b=b.data.type;"downloading-update"===b?this.b.trigger(Y.prototype.g.xt,
|
||||
this):"update-ready"===b||"update-pending"===b?this.b.trigger(Y.prototype.g.Ml,this):"offline-ready"===b&&this.b.trigger(Y.prototype.g.ht,this)};q.prototype.it=function(){return!0};q.prototype.gt=function(){return!0};q.prototype.Ml=function(){return!0};q.prototype.kt=function(){return!0};q.prototype.jt=function(){return!0};q.prototype.mt=function(){return!0};q.prototype.nj=function(){return!0};q.prototype.Go=function(){return!0};q.prototype.nt=function(){return!0};q.prototype.xt=function(){return!0};
|
||||
q.prototype.Ml=function(){return!0};q.prototype.ht=function(){return!0};b.g=new q;r.prototype.As=function(b){try{eval&&eval(b)}catch(a){console&&console.error&&console.error("Error executing Javascript: ",a)}};b.J=new r;t.prototype.zs=function(b,a){if(eval){var e=0;try{e=eval(a)}catch(d){console&&console.error&&console.error("Error executing Javascript: ",d)}"number"===typeof e?b.rg(e):"string"===typeof e?b.rg(e):"boolean"===typeof e?b.rg(e?1:0):b.rg(0)}else b.rg(0)};b.Ma=new t})();
|
||||
function uc(f){this.b=f}
|
||||
(function(){function f(){this.name="";this.Ui=0;this.Qb=[]}function q(){d++;d===k.length&&k.push(new f);return k[d]}function r(){}function t(){}function b(){}var p=uc.prototype;p.la=function(b){this.Ga=b;this.b=b.b};p.la.prototype.N=function(){};p.da=function(b){this.type=b;this.b=b.b};var k=[],d=-1;p.da.prototype.N=function(){var b=this;window.c2_callFunction=function(c,a){var e,f,g,n=q();n.name=c.toLowerCase();n.Ui=0;if(a)for(n.Qb.length=a.length,e=0,f=a.length;e<f;++e)g=a[e],n.Qb[e]="number"===
|
||||
typeof g||"string"===typeof g?g:"boolean"===typeof g?g?1:0:0;else N(n.Qb);b.b.trigger(uc.prototype.g.qj,b,n.name);d--;return n.Ui}};r.prototype.qj=function(b){var c=0>d?null:k[d];return c?nb(b,c.name):!1};p.g=new r;t.prototype.CallFunction=function(b,c){var a=q();a.name=b.toLowerCase();a.Ui=0;Da(a.Qb,c);this.b.trigger(uc.prototype.g.qj,this,a.name);d--};p.J=new t;b.prototype.rs=function(b,c){var a=q();a.name=c.toLowerCase();a.Ui=0;N(a.Qb);var e,f;e=2;for(f=arguments.length;e<f;e++)a.Qb.push(arguments[e]);
|
||||
this.b.trigger(uc.prototype.g.qj,this,a.name);d--;b.rg(a.Ui)};p.Ma=new b})();function wc(f){this.b=f}
|
||||
(function(){function f(){}var q=wc.prototype;q.la=function(b){this.Ga=b;this.b=b.b};q.la.prototype.N=function(){};q.da=function(b){this.type=b;this.b=b.b;this.pi=Array(256);this.gj=Array(256);this.Me=0};var r=q.da.prototype;r.N=function(){var b=this;this.b.Ca||(jQuery(document).keydown(function(f){b.Qw(f)}),jQuery(document).keyup(function(f){b.Rw(f)}))};var t=[32,33,34,35,36,37,38,39,40,44];r.Qw=function(b){var f=!1;window!=window.top&&-1<t.indexOf(b.which)&&(b.preventDefault(),f=!0,b.stopPropagation());
|
||||
if(this.pi[b.which])this.gj[b.which]&&!f&&b.preventDefault();else{this.pi[b.which]=!0;this.Me=b.which;this.b.ec=!0;this.b.trigger(wc.prototype.g.Os,this);var k=this.b.trigger(wc.prototype.g.Bo,this),d=this.b.trigger(wc.prototype.g.dt,this);this.b.ec=!1;if(k||d)this.gj[b.which]=!0,f||b.preventDefault()}};r.Rw=function(b){this.pi[b.which]=!1;this.Me=b.which;this.b.ec=!0;this.b.trigger(wc.prototype.g.Ao,this);var f=this.b.trigger(wc.prototype.g.Do,this),k=this.b.trigger(wc.prototype.g.Co,this);this.b.ec=
|
||||
!1;if(f||k||this.gj[b.which])this.gj[b.which]=!0,b.preventDefault()};r.jh=function(){var b;for(b=0;256>b;++b)if(this.pi[b]){this.pi[b]=!1;this.Me=b;this.b.trigger(wc.prototype.g.Ao,this);var f=this.b.trigger(wc.prototype.g.Do,this),k=this.b.trigger(wc.prototype.g.Co,this);if(f||k)this.gj[b]=!0}};r.eb=function(){return{triggerKey:this.Me}};r.ub=function(b){this.Me=b.triggerKey};f.prototype.Bo=function(b){return b===this.Me};f.prototype.Os=function(){return!0};f.prototype.Ao=function(){return!0};f.prototype.Do=
|
||||
function(b){return b===this.Me};f.prototype.dt=function(b){return b===this.Me};f.prototype.Co=function(b){return b===this.Me};q.g=new f;q.J=new function(){};q.Ma=new function(){}})();function tc(f){this.b=f}
|
||||
(function(){function f(){if(0===this.Jj.length){var b=document.createElement("canvas");b.width=this.width;b.height=this.height;var a=b.getContext("2d");this.sg?a.drawImage(this.ua,this.jg,this.kg,this.width,this.height,0,0,this.width,this.height):a.drawImage(this.ua,0,0,this.width,this.height);this.Jj=b.toDataURL("image/png")}return this.Jj}function q(){}function r(){}var t=tc.prototype;t.la=function(b){this.Ga=b;this.b=b.b};var b=t.la.prototype;b.N=function(){if(!this.V){var b,a,e,d,g,n,k,h,m;this.td=
|
||||
[];this.bi=!1;b=0;for(a=this.Cc.length;b<a;b++){g=this.Cc[b];k={};k.name=g[0];k.speed=g[1];k.loop=g[2];k.Rn=g[3];k.Sn=g[4];k.lr=g[5];k.fa=g[6];k.frames=[];e=0;for(d=g[7].length;e<d;e++)n=g[7][e],h={},h.fo=n[0],h.Vr=n[1],h.jg=n[2],h.kg=n[3],h.width=n[4],h.height=n[5],h.duration=n[6],h.tc=n[7],h.uc=n[8],h.Rm=n[9],h.Rk=n[10],h.Hn=n[11],h.sg=0!==h.width,h.Jj="",h.Hz=f,console.log(n),m={left:0,top:0,right:1,bottom:1},h.$n=m,h.La=null,(m=this.b.Fv(n[0]))?h.ua=m:(h.ua=new Image,h.ua.mu=n[0],h.ua.lu=n[1],
|
||||
h.ua.fu=null,this.b.cy(h.ua,n[0])),k.frames.push(h),this.td.push(h);this.Cc[b]=k}}};b.qo=function(){var b,a,e;b=0;for(a=this.e.length;b<a;b++)e=this.e[b],e.Eg=e.hb.La};b.Ik=function(){if(!this.V){var b,a,e;b=0;for(a=this.td.length;b<a;++b)e=this.td[b],e.ua.fu=null,e.La=null;this.bi=!1;this.qo()}};b.Cn=function(){if(!this.V&&this.e.length){var b,a,e;b=0;for(a=this.td.length;b<a;++b)e=this.td[b],e.La=this.b.C.vi(e.ua,this.b.Ra,e.Hn);this.qo()}};b.Iw=function(){if(!this.V&&!this.bi&&this.b.C){var b,
|
||||
a,e;b=0;for(a=this.td.length;b<a;++b)e=this.td[b],e.La=this.b.C.vi(e.ua,this.b.Ra,e.Hn);this.bi=!0}};b.po=function(){if(!this.V&&!this.e.length&&this.bi){var b,a,e;b=0;for(a=this.td.length;b<a;++b)e=this.td[b],this.b.C.deleteTexture(e.La),e.La=null;this.bi=!1}};var p=[];b.Kn=function(b){var a,e,d;N(p);a=0;for(e=this.td.length;a<e;++a)d=this.td[a].ua,-1===p.indexOf(d)&&(b.drawImage(d,0,0),p.push(d))};t.da=function(b){this.type=b;this.b=b.b;b=this.type.Cc[0].frames[0].Rk;this.Eb?this.Md.Yi(b):this.Md=
|
||||
new fb(b)};var k=t.da.prototype;k.N=function(){this.visible=0===this.q[0];this.Ih=0!==this.q[3];this.Qa=this.Ep(this.q[1])||this.type.Cc[0];this.K=this.q[2];0>this.K&&(this.K=0);this.K>=this.Qa.frames.length&&(this.K=this.Qa.frames.length-1);var b=this.Qa.frames[this.K];this.Md.Yi(b.Rk);this.tc=b.tc;this.uc=b.uc;this.Fg=this.Qa.speed;this.ef=this.Qa.Sn;1===this.type.Cc.length&&1===this.type.Cc[0].frames.length||0===this.Fg||this.b.tl(this);this.Eb?this.Ld.reset():this.Ld=new db;this.te=this.Ld.Z;
|
||||
this.Df=!0;this.ke=0;this.Cf=!0;this.jm=this.Zo="";this.iu=0;this.im=-1;this.type.Iw();var a,e,d,g,f,h,k,b=0;for(a=this.type.Cc.length;b<a;b++)for(g=this.type.Cc[b],e=0,d=g.frames.length;e<d;e++)f=g.frames[e],0===f.width&&(f.width=f.ua.width,f.height=f.ua.height),f.sg&&(k=f.ua,h=f.$n,h.left=f.jg/k.width,h.top=f.kg/k.height,h.right=(f.jg+f.width)/k.width,h.bottom=(f.kg+f.height)/k.height,0===f.jg&&0===f.kg&&f.width===k.width&&f.height===k.height&&(f.sg=!1));this.hb=this.Qa.frames[this.K];this.Eg=this.hb.La};
|
||||
k.eb=function(){var b={a:this.Qa.fa,f:this.K,cas:this.Fg,fs:this.te,ar:this.ke,at:this.Ld.Z,rt:this.ef};this.Df||(b.ap=this.Df);this.Cf||(b.af=this.Cf);return b};k.ub=function(b){var a=this.Jv(b.a);a&&(this.Qa=a);this.K=b.f;0>this.K&&(this.K=0);this.K>=this.Qa.frames.length&&(this.K=this.Qa.frames.length-1);this.Fg=b.cas;this.te=b.fs;this.ke=b.ar;this.Ld.reset();this.Ld.Z=b.at;this.Df=b.hasOwnProperty("ap")?b.ap:!0;this.Cf=b.hasOwnProperty("af")?b.af:!0;b.hasOwnProperty("rt")?this.ef=b.rt:this.ef=
|
||||
this.Qa.Sn;this.hb=this.Qa.frames[this.K];this.Eg=this.hb.La;this.Md.Yi(this.hb.Rk);this.tc=this.hb.tc;this.uc=this.hb.uc};k.Yl=function(b){this.K=b?0:this.Qa.frames.length-1;this.Df=!1;this.Zo=this.Qa.name;this.b.trigger(tc.prototype.g.Ns,this);this.b.trigger(tc.prototype.g.Ms,this);this.ke=0};k.Gh=function(){return this.Ld.Z};k.Sa=function(){this.Ld.add(this.b.Pf(this));this.jm.length&&this.su();0<=this.im&&this.tu();var b=this.Ld.Z,a=this.Qa,e=a.frames[this.K],d=e.duration/this.Fg;this.Df&&b>=
|
||||
this.te+d&&(this.Cf?this.K++:this.K--,this.te+=d,this.K>=a.frames.length&&(a.lr?(this.Cf=!1,this.K=a.frames.length-2):a.loop?this.K=this.ef:(this.ke++,this.ke>=a.Rn?this.Yl(!1):this.K=this.ef)),0>this.K&&(a.lr?(this.K=1,this.Cf=!0,a.loop||(this.ke++,this.ke>=a.Rn&&this.Yl(!0))):a.loop?this.K=this.ef:(this.ke++,this.ke>=a.Rn?this.Yl(!0):this.K=this.ef)),0>this.K?this.K=0:this.K>=a.frames.length&&(this.K=a.frames.length-1),b>this.te+a.frames[this.K].duration/this.Fg&&(this.te=b),b=a.frames[this.K],
|
||||
this.Ag(e,b),this.b.Y=!0)};k.Ep=function(b){var a,e,d;a=0;for(e=this.type.Cc.length;a<e;a++)if(d=this.type.Cc[a],nb(d.name,b))return d;return null};k.Jv=function(b){var a,e,d;a=0;for(e=this.type.Cc.length;a<e;a++)if(d=this.type.Cc[a],d.fa===b)return d;return null};k.su=function(){var b=this.Qa.frames[this.K],a=this.Ep(this.jm);this.jm="";!a||nb(a.name,this.Qa.name)&&this.Df||(this.Qa=a,this.Fg=a.speed,this.ef=a.Sn,0>this.K&&(this.K=0),this.K>=this.Qa.frames.length&&(this.K=this.Qa.frames.length-1),
|
||||
1===this.iu&&(this.K=0),this.Df=!0,this.te=this.Ld.Z,this.Cf=!0,this.Ag(b,this.Qa.frames[this.K]),this.b.Y=!0)};k.tu=function(){var b=this.Qa.frames[this.K],a=this.K;this.K=ta(this.im);0>this.K&&(this.K=0);this.K>=this.Qa.frames.length&&(this.K=this.Qa.frames.length-1);a!==this.K&&(this.Ag(b,this.Qa.frames[this.K]),this.te=this.Ld.Z,this.b.Y=!0);this.im=-1};k.Ag=function(b,a){var e=b.width,d=b.height,g=a.width,f=a.height;e!=g&&(this.width*=g/e);d!=f&&(this.height*=f/d);this.tc=a.tc;this.uc=a.uc;this.Md.Yi(a.Rk);
|
||||
this.ta();this.hb=a;this.Eg=a.La;e=0;for(d=this.S.length;e<d;e++)g=this.S[e],g.Zq&&g.Zq(b,a);this.b.trigger(tc.prototype.g.Ag,this)};k.zd=function(b){b.globalAlpha=this.opacity;var a=this.hb,e=a.sg,d=a.ua,g=this.x,f=this.y,h=this.width,k=this.height;if(0===this.j&&0<=h&&0<=k)g-=this.tc*h,f-=this.uc*k,this.b.Ed&&(g=Math.round(g),f=Math.round(f)),e?b.drawImage(d,a.jg,a.kg,a.width,a.height,g,f,h,k):b.drawImage(d,g,f,h,k);else{this.b.Ed&&(g=Math.round(g),f=Math.round(f));b.save();var m=0<h?1:-1,p=0<k?
|
||||
1:-1;b.translate(g,f);1===m&&1===p||b.scale(m,p);b.rotate(this.j*m*p);g=0-this.tc*oa(h);f=0-this.uc*oa(k);e?b.drawImage(d,a.jg,a.kg,a.width,a.height,g,f,oa(h),oa(k)):b.drawImage(d,g,f,oa(h),oa(k));b.restore()}};k.Hg=function(b){this.Ec(b)};k.Ec=function(b){b.Kc(this.Eg);b.pg(this.opacity);var a=this.hb,e=this.Xe;if(this.b.Ed){var d=Math.round(this.x)-this.x,g=Math.round(this.y)-this.y;a.sg?b.Fe(e.Hb+d,e.Ib+g,e.gc+d,e.hc+g,e.Xb+d,e.Yb+g,e.Vb+d,e.Wb+g,a.$n):b.Ti(e.Hb+d,e.Ib+g,e.gc+d,e.hc+g,e.Xb+d,e.Yb+
|
||||
g,e.Vb+d,e.Wb+g)}else a.sg?b.Fe(e.Hb,e.Ib,e.gc,e.hc,e.Xb,e.Yb,e.Vb,e.Wb,a.$n):b.Ti(e.Hb,e.Ib,e.gc,e.hc,e.Xb,e.Yb,e.Vb,e.Wb)};k.Ov=function(b){var a=this.hb,e,d;e=0;for(d=a.Rm.length;e<d;e++)if(nb(b,a.Rm[e][0]))return e;return-1};k.Gm=function(b,a){var e=this.hb,d=e.Rm,g;A(b)?g=this.Ov(b):g=b-1;g=ta(g);if(0>g||g>=d.length)return a?this.x:this.y;var f=(d[g][1]-e.tc)*this.width,d=d[g][2],d=(d-e.uc)*this.height,e=Math.cos(this.j);g=Math.sin(this.j);var h=f*e-d*g,d=d*e+f*g,f=h+this.x,d=d+this.y;return a?
|
||||
f:d};var d=new da,h=!1;new wa(0,0,0,0);b.finish=function(b){if(h){if(b){var a=this.b.Mb().Kb.gd;b=null.qa();var e=d.Bf(),f,g;if(b.Aa){b.Aa=!1;N(b.e);f=0;for(g=e.length;f<g;++f)b.e[f]=e[f];if(a)for(N(b.ga),f=0,g=null.e.length;f<g;++f)e=null.e[f],d.contains(e)||b.ga.push(e)}else if(a)for(a=b.e.length,f=0,g=e.length;f<g;++f)b.e[a+f]=e[f],Ga(b.ga,e[f]);else Da(b.e,e);null.Ve()}d.clear();h=!1}};q.prototype.Ms=function(b){return nb(this.Zo,b)};q.prototype.Ns=function(){return!0};q.prototype.Ag=function(){return!0};
|
||||
q.prototype.ut=function(){return!0};t.g=new q;r.prototype.Ls=function(b,a,d){var f=new Image,g=this,h=this.hb;f.onload=function(){h.ua.src===f.src?g.b.C&&g.hb===h&&(g.Eg=h.La):(h.ua=f,h.jg=0,h.kg=0,h.width=f.width,h.height=f.height,h.sg=!1,h.Jj="",h.Hn=0,g.b.C&&(h.La&&g.b.C.deleteTexture(h.La),h.La=g.b.C.vi(f,g.b.Ra),g.hb===h&&(g.Eg=h.La),g.type.qo()));0===a&&(g.width=f.width,g.height=f.height,g.ta());g.b.Y=!0;g.b.trigger(tc.prototype.g.ut,g)};"data:"!==b.substr(0,5)&&0===d&&(f.crossOrigin="anonymous");
|
||||
this.b.Xn(f,b)};t.J=new r;t.Ma=new function(){}})();function xc(f){this.b=f}
|
||||
(function(){function f(a,b){return a.length?a.pop():new b}function q(a,b,c){if(c){var e;c=0;for(e=b.length;c<e;c++)a.length<d&&a.push(b[c]);b.length=0}else for(e in b)Object.prototype.hasOwnProperty.call(b,e)&&(a.length<d&&a.push(b[e]),delete b[e])}function r(a,b,c){var d=a.kc;c=c.replace(/\s\s*$/,"");b>=d.length&&d.push(f(h,Object));b=d[b];b.text=c;b.width=a.un(c);a.Ke=pa(a.Ke,b.width)}function t(){}function b(){}var p=xc.prototype;p.N=function(){};p.la=function(a){this.Ga=a;this.b=a.b};var k=p.la.prototype;
|
||||
k.N=function(){this.V||(this.ua=new Image,this.ua.idtkLoadDisposed=!0,this.ua.src=this.fo,this.b.wg.push(this.ua),this.La=null)};k.Ik=function(){this.V||(this.La=null)};k.Cn=function(){if(!this.V&&this.e.length){this.La||(this.La=this.b.C.vi(this.ua,this.b.Ra,this.ho));var a,b;a=0;for(b=this.e.length;a<b;a++)this.e[a].La=this.La}};k.po=function(){this.V||this.e.length||!this.La||(this.b.C.deleteTexture(this.La),this.La=null)};k.Kn=function(a){a.drawImage(this.ua,0,0)};p.da=function(a){this.type=a;
|
||||
this.b=a.b};k=p.da.prototype;k.lg=function(){q(h,this.kc,!0);q(c,this.Cj,!1);q(a,this.Dj,!1);Xa(this.wd)};k.N=function(){this.ua=this.type.ua;this.Bj=this.q[0];this.Ze=this.q[1];this.characterSet=this.q[2];this.text=this.q[3];this.$e=this.q[4];this.visible=0===this.q[5];this.Qf=this.q[6]/2;this.ug=this.q[7]/2;this.mj=0===this.q[9];this.Dg=this.q[10];this.lineHeight=this.q[11];this.de=this.Ke=0;this.Aj=this.q[12];this.Rr=this.q[13];this.Eb?(this.kc.length=0,Xa(this.Cj),Xa(this.Dj),Xa(this.wd)):(this.kc=
|
||||
[],this.Cj={},this.Dj={},this.wd={});try{if(this.Aj)if(-1!==this.Aj.indexOf('""c2array""'))for(var a=jQuery.parseJSON(this.Aj.replace(/""/g,'"')),b=a.size[1],c=0;c<b;c++)for(var d=a.data[1][c][0],e=a.data[0][c][0],f=0;f<d.length;f++)this.wd[d.charAt(f)]=e;else for(a=jQuery.parseJSON(this.Aj),b=a.length,c=0;c<b;c++)for(d=a[c][1],e=a[c][0],f=0;f<d.length;f++)this.wd[d.charAt(f)]=e;-1!==this.Rr&&(this.wd[" "]=this.Rr)}catch(h){window.console&&window.console.log&&window.console.log("SpriteFont+ Failure: "+
|
||||
h)}this.Uc=!0;this.bg=this.width;this.b.C&&(this.type.La||(this.type.La=this.b.C.vi(this.type.ua,this.b.Ra,this.type.ho)),this.La=this.type.La);this.Nt()};k.eb=function(){var a={t:this.text,csc:this.$e,csp:this.Dg,lh:this.lineHeight,tw:this.Ke,th:this.de,lrt:this.ag,cw:{}},b;for(b in this.wd)a.cw[b]=this.wd[b];return a};k.ub=function(a){this.text=a.t;this.$e=a.csc;this.Dg=a.csp;this.lineHeight=a.lh;this.Ke=a.tw;this.de=a.th;this.ag=a.lrt;for(var b in a.cw)this.wd[b]=a.cw[b];this.Uc=!0;this.bg=this.width};
|
||||
var d=1E3,h=[],c=[],a=[];k.Nt=function(){for(var b=this.ua,d=b.width,e=b.height,b=this.Bj,h=this.Ze,k=b/d,l=h/e,p=this.characterSet,d=Math.floor(d/b),e=Math.floor(e/h),t=0;t<p.length&&!(t>=d*e);t++){var q=t%d,r=Math.floor(t/d),x=p.charAt(t);if(this.b.C){var y=this.Dj,F=q*k,G=r*l,q=(q+1)*k,r=(r+1)*l;void 0===y[x]&&(y[x]=f(a,wa));y[x].left=F;y[x].top=G;y[x].right=q;y[x].bottom=r}else y=this.Cj,q=q*b,r=r*h,F=b,G=h,void 0===y[x]&&(y[x]=f(c,Object)),y[x].x=q,y[x].y=r,y[x].ms=F,y[x].Lp=G}};var e=[];p.Rl=
|
||||
function(a){e.length=0;for(var b="",c,d=0;d<a.length;)if(c=a.charAt(d),"\n"===c)b.length&&(e.push(b),b=""),e.push("\n"),++d;else if(" "===c||"\t"===c||"-"===c){do b+=a.charAt(d),d++;while(d<a.length&&(" "===a.charAt(d)||"\t"===a.charAt(d)));e.push(b);b=""}else d<a.length&&(b+=c,d++);b.length&&e.push(b)};p.Sl=function(a){var b=a.text,c=a.kc;if(b&&b.length){var d=a.width;if(2>=d)q(h,c,!0);else{var e=a.$e,k=a.Dg;if(b.length*(a.Bj*e+k)-k<=d&&-1===b.indexOf("\n")&&(k=a.un(b),k<=d)){q(h,c,!0);c.push(f(h,
|
||||
Object));c[0].text=b;c[0].width=k;a.Ke=k;a.de=a.Ze*e+a.lineHeight;return}this.Tl(a);a.de=c.length*(a.Ze*e+a.lineHeight)}}else q(h,c,!0)};p.Tl=function(a){var b=a.mj,c=a.text,f=a.kc,k=a.width;b&&(this.Rl(c),c=e);var l="",p,t,q,E=0,x=!1;for(q=0;q<c.length;q++)"\n"===c[q]?(!0===x?x=!1:(r(a,E,l),E++),l=""):(x=!1,p=l,l+=c[q],t=a.un(l.replace(/\s\s*$/,"")),t>k&&(""===p?(r(a,E,l),l="",x=!0):(r(a,E,p),l=c[q]),E++,b||" "!==l||(l="")));l.replace(/\s\s*$/,"").length&&(r(a,E,l),E++);for(q=E;q<f.length;q++)h.length<
|
||||
d&&h.push(f[q]);f.length=E};k.un=function(a){for(var b=this.Dg,c=a.length,d=0,e=0;e<c;e++)d+=this.Vh(a.charAt(e))*this.$e+b;return d-(0<d?b:0)};k.Vh=function(a){var b=this.wd;return void 0!==b[a]?b[a]:this.Bj};k.sr=function(){if(this.Uc||this.width!==this.bg)this.de=this.Ke=0,this.type.Ga.Sl(this),this.Uc=!1,this.bg=this.width};k.zd=function(a){var b=this.ua;if(""!==this.text&&null!=b&&(this.sr(),!(this.height<this.Ze*this.$e+this.lineHeight))){a.globalAlpha=this.opacity;var b=this.x,c=this.y;this.b.Ed&&
|
||||
(b=b+.5|0,c=c+.5|0);a.save();a.translate(b,c);a.rotate(this.j);for(var b=this.Qf,c=this.$e,d=this.Ze*c,e=this.lineHeight,f=this.Dg,h=this.kc,k,l=-(this.tc*this.width),p=-(this.uc*this.height),p=p+this.ug*pa(0,this.height-this.de),t=0;t<h.length;t++){var q=h[t].text;k=b*pa(0,this.width-h[t].width);k=l+k;for(var p=p+e,r=0;r<q.length;r++){var G=q.charAt(r),K=this.Cj[G];if(k+this.Vh(G)*c>this.width+1E-5)break;void 0!==K&&a.drawImage(this.ua,K.x,K.y,K.ms,K.Lp,Math.round(k),Math.round(p),K.ms*c,K.Lp*c);
|
||||
k+=this.Vh(G)*c+f}p+=d;if(p+d+e>this.height)break}a.restore()}};var l=new xa;k.Ec=function(a){a.Kc(this.La);a.pg(this.opacity);if(""!==this.text&&(this.sr(),!(this.height<this.Ze*this.$e+this.lineHeight))){this.Ha();var b=this.Xe,c=0,d=0;this.b.Ed&&(c=(this.x+.5|0)-this.x,d=(this.y+.5|0)-this.y);var e=this.j,f=this.Qf,h=this.ug,k=this.$e,p=this.Ze*k,t=this.lineHeight,q=this.Dg,r=this.kc,F=this.de,G,K;0!==e&&(G=Math.cos(e),K=Math.sin(e));for(var R,c=b.Hb+c,b=b.Ib+d,h=h*pa(0,this.height-F),F=0;F<r.length;F++){d=
|
||||
r[F].text;R=f*pa(0,this.width-r[F].width);for(var h=h+t,T=0;T<d.length;T++){var M=d.charAt(T),v=this.Dj[M];if(R+this.Vh(M)*k>this.width+1E-5)break;if(void 0!==v){var C=this.Bj*k,S=this.Ze*k;l.Hb=R;l.Ib=h;l.gc=R+C;l.hc=h;l.Vb=R;l.Wb=h+S;l.Xb=R+C;l.Yb=h+S;if(0!==e){var C=l,S=G,I=K,D=void 0,D=C.Hb*S-C.Ib*I;C.Ib=C.Ib*S+C.Hb*I;C.Hb=D;D=C.gc*S-C.hc*I;C.hc=C.hc*S+C.gc*I;C.gc=D;D=C.Vb*S-C.Wb*I;C.Wb=C.Wb*S+C.Vb*I;C.Vb=D;D=C.Xb*S-C.Yb*I;C.Yb=C.Yb*S+C.Xb*I;C.Xb=D}l.offset(c,b);a.Fe(l.Hb,l.Ib,l.gc,l.hc,l.Xb,
|
||||
l.Yb,l.Vb,l.Wb,v)}R+=this.Vh(M)*k+q}h+=p;if(h+p+t>this.height)break}}};p.g=new function(){};t.prototype.sj=function(a){la(a)&&1E9>a&&(a=Math.round(1E10*a)/1E10);a=a.toString();this.text!==a&&(this.text=a,this.Uc=!0,this.b.Y=!0)};k.Gh=function(a,b){var c=parseInt(b,10);this.wd[a]!==c&&(this.wd[a]=c,this.Uc=!0,this.b.Y=!0)};p.J=new t;b.prototype.Text=function(a){a.Fb(this.text)};p.Ma=new b})();function yc(f){this.b=f}
|
||||
(function(){function f(){return h.length?h.pop():{}}function q(b){var a,d;a=0;for(d=b.length;a<d;a++)h.push(b[a]);N(b)}function r(b){return b.length&&" "===b.charAt(b.length-1)?b.substring(0,b.length-1):b}function t(){}function b(){}var p=yc.prototype;p.N=function(){p.J.Mt=function(b){this.width!==b&&(this.width=b,this.Uc=!0,this.ta())}};p.la=function(b){this.Ga=b;this.b=b.b};var k=p.la.prototype;k.N=function(){};k.Ik=function(){if(!this.V){var b,a,d;b=0;for(a=this.e.length;b<a;b++)d=this.e[b],d.Vd=
|
||||
null,d.hg=null,d.Hc=null}};p.da=function(b){this.type=b;this.b=b.b;this.Eb?N(this.kc):this.kc=[];this.Uc=!0};k=p.da.prototype;k.N=function(){this.text=this.q[0];this.visible=0===this.q[1];this.font=this.q[2];this.color=this.q[3];this.Qf=this.q[4];this.ug=this.q[5];this.mj=0===this.q[7];this.bg=this.rk=this.width;this.qk=this.height;this.ln=this.q[8];this.Yj=this.Jg="";this.de=this.Ke=this.Ri=0;this.Zw();this.Hc=this.hg=this.Vd=null;this.Nq=!1;this.ag=this.b.ee;this.Eb?this.oh.set(0,0,1,1):this.oh=
|
||||
new wa(0,0,1,1);this.b.C&&this.b.tl(this)};k.Zw=function(){var b=this.font.split(" "),a;for(a=0;a<b.length;a++)if("pt"===b[a].substr(b[a].length-2,2)){this.Ri=parseInt(b[a].substr(0,b[a].length-2));this.Nn=Math.ceil(this.Ri/72*96)+4;0<a&&(this.Yj=b[a-1]);this.Jg=b[a+1];for(a+=2;a<b.length;a++)this.Jg+=" "+b[a];break}};k.eb=function(){return{t:this.text,f:this.font,c:this.color,ha:this.Qf,va:this.ug,wr:this.mj,lho:this.ln,fn:this.Jg,fs:this.Yj,ps:this.Ri,pxh:this.Nn,tw:this.Ke,th:this.de,lrt:this.ag}};
|
||||
k.ub=function(b){this.text=b.t;this.font=b.f;this.color=b.c;this.Qf=b.ha;this.ug=b.va;this.mj=b.wr;this.ln=b.lho;this.Jg=b.fn;this.Yj=b.fs;this.Ri=b.ps;this.Nn=b.pxh;this.Ke=b.tw;this.de=b.th;this.ag=b.lrt;this.Uc=!0;this.bg=this.rk=this.width;this.qk=this.height};k.Sa=function(){if(this.b.C&&this.Hc&&300<=this.b.ee-this.ag){var b=this.k;this.Ha();var a=this.xa;if(a.right<b.Ea||a.bottom<b.Fa||a.left>b.Ja||a.top>b.Ia)this.b.C.deleteTexture(this.Hc),this.Vd=this.hg=this.Hc=null}};k.lg=function(){this.Vd=
|
||||
this.hg=null;this.b.C&&this.Hc&&this.b.C.deleteTexture(this.Hc);this.Hc=null};k.Gh=function(){this.font=this.Yj+" "+this.Ri.toString()+"pt "+this.Jg;this.Uc=!0;this.b.Y=!0};k.zd=function(b,a){b.font=this.font;b.textBaseline="top";b.fillStyle=this.color;b.globalAlpha=a?1:this.opacity;var d=1;a&&(d=Math.abs(this.k.sc()),b.save(),b.scale(d,d));if(this.Uc||this.width!==this.bg)this.type.Ga.Sl(this.text,this.kc,b,this.width,this.mj),this.Uc=!1,this.bg=this.width;this.Ha();var d=a?0:this.Xe.Hb,f=a?0:this.Xe.Ib;
|
||||
this.b.Ed&&(d=d+.5|0,f=f+.5|0);0===this.j||a||(b.save(),b.translate(d,f),b.rotate(this.j),f=d=0);var g=f+this.height,h=this.Nn,h=h+this.ln,k,p;1===this.ug?f+=Math.max(this.height/2-this.kc.length*h/2,0):2===this.ug&&(f+=Math.max(this.height-this.kc.length*h-2,0));for(p=0;p<this.kc.length&&!(k=d,1===this.Qf?k=d+(this.width-this.kc[p].width)/2:2===this.Qf&&(k=d+(this.width-this.kc[p].width)),b.fillText(this.kc[p].text,k,f),f+=h,f>=g-h);p++);(0!==this.j||a)&&b.restore();this.ag=this.b.ee};k.Ec=function(b){if(!(1>
|
||||
this.width||1>this.height)){var a=this.Uc||this.Nq;this.Nq=!1;var d=this.k.sc(),f=this.k.rb(),g=this.oh,h=d*this.width,k=d*this.height,p=Math.ceil(h),m=Math.ceil(k),t=Math.abs(p),q=Math.abs(m),r=this.b.M/2,W=this.b.L/2;this.hg||(this.Vd=document.createElement("canvas"),this.Vd.width=t,this.Vd.height=q,this.rk=t,this.qk=q,a=!0,this.hg=this.Vd.getContext("2d"));if(t!==this.rk||q!==this.qk)this.Vd.width=t,this.Vd.height=q,this.Hc&&(b.deleteTexture(this.Hc),this.Hc=null),a=!0;a&&(this.hg.clearRect(0,
|
||||
0,t,q),this.zd(this.hg,!0),this.Hc||(this.Hc=b.Mc(t,q,this.b.Ra,this.b.nf)),b.by(this.Vd,this.Hc,this.b.nf));this.rk=t;this.qk=q;b.Kc(this.Hc);b.pg(this.opacity);b.kd();b.translate(-r,-W);b.Xc();var E=this.Xe,a=this.k.Va(E.Hb,E.Ib,!0,!0),t=this.k.Va(E.Hb,E.Ib,!1,!0),q=this.k.Va(E.gc,E.hc,!0,!0),r=this.k.Va(E.gc,E.hc,!1,!0),W=this.k.Va(E.Xb,E.Yb,!0,!0),x=this.k.Va(E.Xb,E.Yb,!1,!0),y=this.k.Va(E.Vb,E.Wb,!0,!0),E=this.k.Va(E.Vb,E.Wb,!1,!0);if(this.b.Ed||0===this.j&&0===f)var F=(a+.5|0)-a,G=(t+.5|0)-
|
||||
t,a=a+F,t=t+G,q=q+F,r=r+G,W=W+F,x=x+G,y=y+F,E=E+G;0===this.j&&0===f?(q=a+p,r=t,W=q,x=t+m,y=a,E=x,g.right=1,g.bottom=1):(g.right=h/p,g.bottom=k/m);b.Fe(a,t,q,r,W,x,y,E,g);b.kd();b.scale(d,d);b.cl(-this.k.rb());b.translate((this.k.Ea+this.k.Ja)/-2,(this.k.Fa+this.k.Ia)/-2);b.Xc();this.ag=this.b.ee}};var d=[];p.Rl=function(b){N(d);for(var a="",e,f=0;f<b.length;)if(e=b.charAt(f),"\n"===e)a.length&&(d.push(a),a=""),d.push("\n"),++f;else if(" "===e||"\t"===e||"-"===e){do a+=b.charAt(f),f++;while(f<b.length&&
|
||||
(" "===b.charAt(f)||"\t"===b.charAt(f)));d.push(a);a=""}else f<b.length&&(a+=e,f++);a.length&&d.push(a)};var h=[];p.Sl=function(b,a,d,h,g){if(b&&b.length)if(2>=h)q(a);else{if(100>=b.length&&-1===b.indexOf("\n")){var k=d.measureText(b).width;if(k<=h){q(a);a.push(f());a[0].text=b;a[0].width=k;return}}this.Tl(b,a,d,h,g)}else q(a)};p.Tl=function(b,a,e,k,g){g&&(this.Rl(b),b=d);var p="",t,q,m,u=0;for(m=0;m<b.length;m++)"\n"===b[m]?(u>=a.length&&a.push(f()),p=r(p),q=a[u],q.text=p,q.width=e.measureText(p).width,
|
||||
u++,p=""):(t=p,p+=b[m],q=e.measureText(p).width,q>=k&&(u>=a.length&&a.push(f()),t=r(t),q=a[u],q.text=t,q.width=e.measureText(t).width,u++,p=b[m],g||" "!==p||(p="")));p.length&&(u>=a.length&&a.push(f()),p=r(p),q=a[u],q.text=p,q.width=e.measureText(p).width,u++);for(m=u;m<a.length;m++)h.push(a[m]);a.length=u};p.g=new function(){};t.prototype.sj=function(b){la(b)&&1E9>b&&(b=Math.round(1E10*b)/1E10);b=b.toString();this.text!==b&&(this.text=b,this.Uc=!0,this.b.Y=!0)};p.J=new t;b.prototype.Text=function(b){b.Fb(this.text)};
|
||||
p.Ma=new b})();function zc(f){this.b=f}
|
||||
(function(){function f(){}function q(){}function r(){}var t=zc.prototype;t.la=function(b){this.Ga=b;this.b=b.b};t.la.prototype.N=function(){};t.da=function(b){this.type=b;this.b=b.b};var b=t.da.prototype,p="text password email number tel url".split(" ");-1<navigator.userAgent.indexOf("MSIE 9")&&(p[2]="text",p[3]="text",p[4]="text",p[5]="text");b.N=function(){if(this.b.Ca)ga("[Construct 2] Textbox plugin not supported on this platform - the object will not be created");else{6===this.q[7]?(this.I=document.createElement("textarea"),
|
||||
jQuery(this.I).css("resize","none")):(this.I=document.createElement("input"),this.I.type=p[this.q[7]]);this.I.id=this.q[9];jQuery(this.I).appendTo(this.b.zj?this.b.zj:"body");this.I.autocomplete="off";this.I.value=this.q[0];this.I.placeholder=this.q[1];this.I.title=this.q[2];this.I.disabled=0===this.q[4];this.I.readOnly=1===this.q[5];this.I.spellcheck=1===this.q[6];this.bu=0!==this.q[8];this.Mf=!1;0===this.q[3]&&(jQuery(this.I).hide(),this.visible=!1,this.Mf=!0);var b=function(b){return function(){b.b.trigger(zc.prototype.g.tt,
|
||||
b)}}(this);this.I.oninput=b;-1!==navigator.userAgent.indexOf("MSIE")&&(this.I.oncut=b);this.I.onclick=function(b){return function(f){f.stopPropagation();b.b.ec=!0;b.b.trigger(zc.prototype.g.Qs,b);b.b.ec=!1}}(this);this.I.ondblclick=function(b){return function(f){f.stopPropagation();b.b.ec=!0;b.b.trigger(zc.prototype.g.Ts,b);b.b.ec=!1}}(this);this.I.addEventListener("touchstart",function(b){b.stopPropagation()},!1);this.I.addEventListener("touchmove",function(b){b.stopPropagation()},!1);this.I.addEventListener("touchend",
|
||||
function(b){b.stopPropagation()},!1);jQuery(this.I).mousedown(function(b){b.stopPropagation()});jQuery(this.I).mouseup(function(b){b.stopPropagation()});jQuery(this.I).keydown(function(b){13!==b.which&&27!=b.which&&b.stopPropagation()});jQuery(this.I).keyup(function(b){13!==b.which&&27!=b.which&&b.stopPropagation()});this.jq=this.kq=this.bq=this.gq=this.iq=this.dq=0;this.js(!0);this.b.tl(this)}};b.eb=function(){return{text:this.I.value,placeholder:this.I.placeholder,tooltip:this.I.title,disabled:!!this.I.disabled,
|
||||
readonly:!!this.I.readOnly,spellcheck:!!this.I.spellcheck}};b.ub=function(b){this.I.value=b.text;this.I.placeholder=b.placeholder;this.I.title=b.tooltip;this.I.disabled=b.disabled;this.I.readOnly=b.readonly;this.I.spellcheck=b.spellcheck};b.lg=function(){this.b.Ca||(jQuery(this.I).remove(),this.I=null)};b.Sa=function(){this.js()};b.js=function(b){if(!this.b.Ca){var d=this.k.Va(this.x,this.y,!0),f=this.k.Va(this.x,this.y,!1),c=this.k.Va(this.x+this.width,this.y+this.height,!0),a=this.k.Va(this.x+this.width,
|
||||
this.y+this.height,!1),e=this.b.width/this.b.devicePixelRatio,l=this.b.height/this.b.devicePixelRatio;!this.visible||!this.k.visible||0>=c||0>=a||d>=e||f>=l?(this.Mf||jQuery(this.I).hide(),this.Mf=!0):(1>d&&(d=1),1>f&&(f=1),c>=e&&(c=e-1),a>=l&&(a=l-1),e=window.innerWidth,l=window.innerHeight,b||this.dq!==d||this.iq!==f||this.gq!==c||this.bq!==a||this.kq!==e||this.jq!==l?(this.dq=d,this.iq=f,this.gq=c,this.bq=a,this.kq=e,this.jq=l,this.Mf&&(jQuery(this.I).show(),this.Mf=!1),b=Math.round(d)+jQuery(this.b.canvas).offset().left,
|
||||
e=Math.round(f)+jQuery(this.b.canvas).offset().top,jQuery(this.I).css("position","absolute"),jQuery(this.I).offset({left:b,top:e}),jQuery(this.I).width(Math.round(c-d)),jQuery(this.I).height(Math.round(a-f)),this.bu&&jQuery(this.I).css("font-size",this.k.sc(!0)/this.b.devicePixelRatio-.2+"em")):this.Mf&&(jQuery(this.I).show(),this.Mf=!1))}};b.zd=function(){};b.Ec=function(){};f.prototype.tt=function(){return!0};f.prototype.Qs=function(){return!0};f.prototype.Ts=function(){return!0};t.g=new f;q.prototype.sj=
|
||||
function(b){this.b.Ca||(this.I.value=b)};q.prototype.tj=function(b){this.b.Ca||(this.visible=0!==b)};q.prototype.Ol=function(b){this.b.Ca||(this.I.disabled=0===b)};q.prototype.Ht=function(){this.b.Ca||this.I.focus()};q.prototype.Ft=function(b,d){this.b.Ca||jQuery(this.I).css(b,d)};t.J=new q;r.prototype.Text=function(b){this.b.Ca?b.Fb(""):b.Fb(this.I.value)};t.Ma=new r})();function Z(f){this.b=f}
|
||||
(function(){function f(b){c=b.x;a=b.y;e=b.z}function q(a,b,c,d){var e;e=l.length?l.pop():new r;e.init(a,b,c,d);return e}function r(){this.aj=this.id=this.y=this.x=this.nl=this.ml=this.jn=this.time=this.eo=0;this.fj=this.wl=!1}function t(a){return a.sourceCapabilities&&a.sourceCapabilities.firesTouchEvents||a.originalEvent&&a.originalEvent.sourceCapabilities&&a.originalEvent.sourceCapabilities.firesTouchEvents}function b(){}function p(){}var k=Z.prototype;k.la=function(a){this.Ga=a;this.b=a.b};k.la.prototype.N=
|
||||
function(){};k.da=function(a){this.type=a;this.b=a.b;this.touches=[];this.vn=!1};var d=k.da.prototype,h={left:0,top:0};d.Uh=function(a){var b,c;b=0;for(c=this.touches.length;b<c;b++)if(this.touches[b].id===a)return b;return-1};var c=0,a=0,e=0,l=[];r.prototype.init=function(a,b,c,d){var e=$a();this.eo=this.jn=this.time=e;this.ml=a;this.nl=b;this.x=a;this.y=b;this.pressure=this.height=this.width=0;this.id=c;this.aj=d;this.fj=this.wl=!1};r.prototype.update=function(a,b,c,d,e,f){this.jn=this.time;this.time=
|
||||
a;this.x=b;this.y=c;this.width=d;this.height=e;this.pressure=f;!this.fj&&15<=Ua(this.ml,this.nl,this.x,this.y)&&(this.fj=!0)};r.prototype.Lw=function(a,b){!this.wl&&500<=$a()-this.eo&&!this.fj&&15>Ua(this.ml,this.nl,this.x,this.y)&&(this.wl=!0,a.ge=this.aj,a.wh=this.id,a.Ng=b,a.b.trigger(Z.prototype.g.bt,a),a.oe=this.x,a.pe=this.y,a.b.trigger(Z.prototype.g.ct,a),a.Ng=0)};var g=-1E3,n=-1E3,L=-1E4;r.prototype.Hq=function(a,b){if(!this.wl){var c=$a();333>=c-this.eo&&!this.fj&&15>Ua(this.ml,this.nl,this.x,
|
||||
this.y)&&(a.ge=this.aj,a.wh=this.id,a.Ng=b,666>=c-L&&25>Ua(g,n,this.x,this.y)?(a.b.trigger(Z.prototype.g.Us,a),a.oe=this.x,a.pe=this.y,a.b.trigger(Z.prototype.g.Vs,a),n=g=-1E3,L=-1E4):(a.b.trigger(Z.prototype.g.pt,a),a.oe=this.x,a.pe=this.y,a.b.trigger(Z.prototype.g.qt,a),g=this.x,n=this.y,L=c),a.Ng=0)}};d.N=function(){this.Bw=!("undefined"===typeof window.c2isWindows8||!window.c2isWindows8);this.Ng=this.wh=this.ge=this.pe=this.oe=this.Ro=this.Qo=this.Po=this.Wt=this.Vt=this.Ut=this.Nk=this.Mk=this.Lk=
|
||||
0;this.$x=0!==this.q[0];var a=0<this.b.rc?document:this.b.canvas,b=document;this.b.cc?b=a=window.Canvas:this.b.ed&&(b=a=window);var c=this;"undefined"!==typeof PointerEvent?(a.addEventListener("pointerdown",function(a){c.Yq(a)},!1),a.addEventListener("pointermove",function(a){c.Xq(a)},!1),b.addEventListener("pointerup",function(a){c.Jk(a,!1)},!1),b.addEventListener("pointercancel",function(a){c.Jk(a,!0)},!1),this.b.canvas&&(this.b.canvas.addEventListener("MSGestureHold",function(a){a.preventDefault()},
|
||||
!1),document.addEventListener("MSGestureHold",function(a){a.preventDefault()},!1),this.b.canvas.addEventListener("gesturehold",function(a){a.preventDefault()},!1),document.addEventListener("gesturehold",function(a){a.preventDefault()},!1))):window.navigator.msPointerEnabled?(a.addEventListener("MSPointerDown",function(a){c.Yq(a)},!1),a.addEventListener("MSPointerMove",function(a){c.Xq(a)},!1),b.addEventListener("MSPointerUp",function(a){c.Jk(a,!1)},!1),b.addEventListener("MSPointerCancel",function(a){c.Jk(a,
|
||||
!0)},!1),this.b.canvas&&(this.b.canvas.addEventListener("MSGestureHold",function(a){a.preventDefault()},!1),document.addEventListener("MSGestureHold",function(a){a.preventDefault()},!1))):(a.addEventListener("touchstart",function(a){c.br(a)},!1),a.addEventListener("touchmove",function(a){c.$q(a)},!1),b.addEventListener("touchend",function(a){c.Dn(a,!1)},!1),b.addEventListener("touchcancel",function(a){c.Dn(a,!0)},!1));if(this.Bw){var d=function(a){a=a.reading;c.Po=a.accelerationX;c.Qo=a.accelerationY;
|
||||
c.Ro=a.accelerationZ},e=function(a){a=a.reading;c.Lk=a.yawDegrees;c.Mk=a.pitchDegrees;c.Nk=a.rollDegrees},g=Windows.Devices.Sensors.Accelerometer.getDefault();g&&(g.reportInterval=Math.max(g.minimumReportInterval,16),g.addEventListener("readingchanged",d));var h=Windows.Devices.Sensors.Inclinometer.getDefault();h&&(h.reportInterval=Math.max(h.minimumReportInterval,16),h.addEventListener("readingchanged",e));document.addEventListener("visibilitychange",function(){document.hidden||document.msHidden?
|
||||
(g&&g.removeEventListener("readingchanged",d),h&&h.removeEventListener("readingchanged",e)):(g&&g.addEventListener("readingchanged",d),h&&h.addEventListener("readingchanged",e))},!1)}else window.addEventListener("deviceorientation",function(a){c.Lk=a.alpha||0;c.Mk=a.beta||0;c.Nk=a.gamma||0},!1),window.addEventListener("devicemotion",function(a){a.accelerationIncludingGravity&&(c.Ut=a.accelerationIncludingGravity.x||0,c.Vt=a.accelerationIncludingGravity.y||0,c.Wt=a.accelerationIncludingGravity.z||
|
||||
0);a.acceleration&&(c.Po=a.acceleration.x||0,c.Qo=a.acceleration.y||0,c.Ro=a.acceleration.z||0)},!1);this.$x&&!this.b.Ca&&(jQuery(document).mousemove(function(a){c.Tw(a)}),jQuery(document).mousedown(function(a){c.Sw(a)}),jQuery(document).mouseup(function(a){c.Uw(a)}));!this.b.Ug&&this.b.Qc&&navigator.accelerometer&&navigator.accelerometer.watchAcceleration&&navigator.accelerometer.watchAcceleration(f,null,{frequency:40});this.b.Rx(this)};d.Xq=function(a){if(a.pointerType!==a.MSPOINTER_TYPE_MOUSE&&
|
||||
"mouse"!==a.pointerType){a.preventDefault&&a.preventDefault();var b=this.Uh(a.pointerId),c=$a();if(0<=b){var d=this.b.Ca?h:jQuery(this.b.canvas).offset(),b=this.touches[b];2>c-b.time||b.update(c,a.pageX-d.left,a.pageY-d.top,a.width||0,a.height||0,a.pressure||0)}}};d.Yq=function(a){if(a.pointerType!==a.MSPOINTER_TYPE_MOUSE&&"mouse"!==a.pointerType){a.preventDefault&&ob(a)&&a.preventDefault();var b=this.b.Ca?h:jQuery(this.b.canvas).offset(),c=a.pageX-b.left,b=a.pageY-b.top;$a();this.ge=this.touches.length;
|
||||
this.wh=a.pointerId;this.touches.push(q(c,b,a.pointerId,this.ge));this.b.ec=!0;this.b.trigger(Z.prototype.g.Io,this);this.b.trigger(Z.prototype.g.Lo,this);this.oe=c;this.pe=b;this.b.trigger(Z.prototype.g.Ll,this);this.b.ec=!1}};d.Jk=function(a,b){if(a.pointerType!==a.MSPOINTER_TYPE_MOUSE&&"mouse"!==a.pointerType){a.preventDefault&&ob(a)&&a.preventDefault();var c=this.Uh(a.pointerId);this.ge=0<=c?this.touches[c].aj:-1;this.wh=0<=c?this.touches[c].id:-1;this.b.ec=!0;this.b.trigger(Z.prototype.g.Ho,
|
||||
this);this.b.trigger(Z.prototype.g.Ko,this);0<=c&&(b||this.touches[c].Hq(this,c),100>l.length&&l.push(this.touches[c]),this.touches.splice(c,1));this.b.ec=!1}};d.$q=function(a){a.preventDefault&&a.preventDefault();var b=$a(),c,d,e,f;c=0;for(d=a.changedTouches.length;c<d;c++)if(e=a.changedTouches[c],f=this.Uh(e.identifier),0<=f){var g=this.b.Ca?h:jQuery(this.b.canvas).offset();f=this.touches[f];2>b-f.time||f.update(b,e.pageX-g.left,e.pageY-g.top,2*(e.Sz||e.$z||e.Lz||e.Oz||0),2*(e.Tz||e.aA||e.Mz||e.Pz||
|
||||
0),e.Gz||e.Zz||e.Kz||e.Nz||0)}};d.br=function(a){a.preventDefault&&ob(a)&&a.preventDefault();var b=this.b.Ca?h:jQuery(this.b.canvas).offset();$a();this.b.ec=!0;var c,d,e,f;c=0;for(d=a.changedTouches.length;c<d;c++)if(e=a.changedTouches[c],f=this.Uh(e.identifier),-1===f){f=e.pageX-b.left;var g=e.pageY-b.top;this.ge=this.touches.length;this.wh=e.identifier;this.touches.push(q(f,g,e.identifier,this.ge));this.b.trigger(Z.prototype.g.Io,this);this.b.trigger(Z.prototype.g.Lo,this);this.oe=f;this.pe=g;this.b.trigger(Z.prototype.g.Ll,
|
||||
this)}this.b.ec=!1};d.Dn=function(a,b){a.preventDefault&&ob(a)&&a.preventDefault();this.b.ec=!0;var c,d,e;c=0;for(d=a.changedTouches.length;c<d;c++)e=a.changedTouches[c],e=this.Uh(e.identifier),0<=e&&(this.ge=this.touches[e].aj,this.wh=this.touches[e].id,this.b.trigger(Z.prototype.g.Ho,this),this.b.trigger(Z.prototype.g.Ko,this),b||this.touches[e].Hq(this,e),100>l.length&&l.push(this.touches[e]),this.touches.splice(e,1));this.b.ec=!1};d.Gh=function(){return this.b.Qc&&0===this.Lk&&0!==e?90*e:this.Lk};
|
||||
d.Ez=function(){return this.b.Qc&&0===this.Mk&&0!==a?90*a:this.Mk};d.Fz=function(){return this.b.Qc&&0===this.Nk&&0!==c?90*c:this.Nk};d.Sw=function(a){t(a)||(this.br({changedTouches:[{pageX:a.pageX,pageY:a.pageY,identifier:0}]}),this.vn=!0)};d.Tw=function(a){this.vn&&!t(a)&&this.$q({changedTouches:[{pageX:a.pageX,pageY:a.pageY,identifier:0}]})};d.Uw=function(a){a.preventDefault&&this.b.Mp&&!this.b.nf&&a.preventDefault();this.b.Mp=!0;t(a)||(this.Dn({changedTouches:[{pageX:a.pageX,pageY:a.pageY,identifier:0}]}),
|
||||
this.vn=!1)};d.ej=function(){var a,b,c,d=$a();a=0;for(b=this.touches.length;a<b;++a)c=this.touches[a],c.time<=d-50&&(c.jn=d),c.Lw(this,a)};b.prototype.Lo=function(){return!0};b.prototype.Ko=function(){return!0};b.prototype.Ll=function(a){return a?this.b.pl(a,this.oe,this.pe):!1};b.prototype.Io=function(a){a=Math.floor(a);return a===this.ge};b.prototype.Ho=function(a){a=Math.floor(a);return a===this.ge};b.prototype.bt=function(){return!0};b.prototype.pt=function(){return!0};b.prototype.Us=function(){return!0};
|
||||
b.prototype.ct=function(a){return a?this.b.pl(a,this.oe,this.pe):!1};b.prototype.qt=function(a){return a?this.b.pl(a,this.oe,this.pe):!1};b.prototype.Vs=function(a){return a?this.b.pl(a,this.oe,this.pe):!1};k.g=new b;k.J=new function(){};p.prototype.No=function(a,b){var c=this.Ng;if(0>c||c>=this.touches.length)a.H(0);else{var d,e,f,g,h;ka(b)?(d=this.b.Wh(0),e=d.scale,f=d.Qe,g=d.Be,h=d.j,d.scale=1,d.Qe=1,d.Be=1,d.j=0,a.H(d.ic(this.touches[c].x,this.touches[c].y,!0)),d.scale=e,d.Qe=f,d.Be=g,d.j=h):
|
||||
(d=la(b)?this.b.Wh(b):this.b.Im(b))?a.H(d.ic(this.touches[c].x,this.touches[c].y,!0)):a.H(0)}};p.prototype.Oo=function(a,b){var c=this.Ng;if(0>c||c>=this.touches.length)a.H(0);else{var d,e,f,g,h;ka(b)?(d=this.b.Wh(0),e=d.scale,f=d.Qe,g=d.Ce,h=d.j,d.scale=1,d.Qe=1,d.Ce=1,d.j=0,a.H(d.ic(this.touches[c].x,this.touches[c].y,!1)),d.scale=e,d.Qe=f,d.Ce=g,d.j=h):(d=la(b)?this.b.Wh(b):this.b.Im(b))?a.H(d.ic(this.touches[c].x,this.touches[c].y,!1)):a.H(0)}};k.Ma=new p})();function Ac(f){this.b=f}
|
||||
(function(){function f(){}var q=Ac.prototype;q.la=function(f){this.behavior=f;this.b=f.b};q.la.prototype.N=function(){};q.da=function(f,b){this.type=f;this.behavior=f.behavior;this.d=b;this.b=f.b};var r=q.da.prototype;r.N=function(){this.Xo=this.q[0];this.Yo=this.q[1];this.$t=this.q[2];this.Zt=this.q[3];this.d.Ha();this.El=this.d.xa.left;this.Hl=this.d.xa.top;this.Fl=this.b.Xa-this.d.xa.left;this.Gl=this.b.Wa-this.d.xa.top;this.Zk=this.b.Xa-this.d.xa.right;this.xj=this.b.Wa-this.d.xa.bottom;this.enabled=
|
||||
0!==this.q[4]};r.eb=function(){return{xleft:this.El,ytop:this.Hl,xright:this.Fl,ybottom:this.Gl,rdiff:this.Zk,bdiff:this.xj,enabled:this.enabled}};r.ub=function(f){this.El=f.xleft;this.Hl=f.ytop;this.Fl=f.xright;this.Gl=f.ybottom;this.Zk=f.rdiff;this.xj=f.bdiff;this.enabled=f.enabled};r.Sa=function(){if(this.enabled){var f,b=this.d.k,p=this.d,k=this.d.xa;0===this.Xo?(p.Ha(),f=b.Ea+this.El-k.left,0!==f&&(p.x+=f,p.ta())):1===this.Xo&&(p.Ha(),f=b.Ja-this.Fl-k.left,0!==f&&(p.x+=f,p.ta()));0===this.Yo?
|
||||
(p.Ha(),f=b.Fa+this.Hl-k.top,0!==f&&(p.y+=f,p.ta())):1===this.Yo&&(p.Ha(),f=b.Ia-this.Gl-k.top,0!==f&&(p.y+=f,p.ta()));1===this.$t&&(p.Ha(),f=b.Ja-this.Zk-k.right,0!==f&&(p.width+=f,0>p.width&&(p.width=0),p.ta()));1===this.Zt&&(p.Ha(),f=b.Ia-this.xj-k.bottom,0!==f&&(p.height+=f,0>p.height&&(p.height=0),p.ta()))}};q.g=new function(){};f.prototype.Ol=function(f){this.enabled&&0===f?this.enabled=!1:this.enabled||0===f||(this.d.Ha(),this.El=this.d.xa.left,this.Hl=this.d.xa.top,this.Fl=this.b.Xa-this.d.xa.left,
|
||||
this.Gl=this.b.Wa-this.d.xa.top,this.Zk=this.b.Xa-this.d.xa.right,this.xj=this.b.Wa-this.d.xa.bottom,this.enabled=!0)};q.J=new f;q.Ma=new function(){}})();function Bc(f){this.b=f}
|
||||
(function(){function f(){}function q(){}var r=Bc.prototype;r.la=function(b){this.behavior=b;this.b=b.b};r.la.prototype.N=function(){};r.da=function(b,f){this.type=b;this.behavior=b.behavior;this.d=f;this.b=b.b};var t=r.da.prototype;t.N=function(){this.So=1===this.q[0];this.Sh=this.q[1];this.kj=this.q[2];this.Sj=this.q[3];this.qu=this.q[4];this.yb=this.So?0:3;this.Eb?this.md.reset():this.md=new db;this.gg=this.d.opacity?this.d.opacity:1;this.So&&(0===this.Sh?(this.yb=1,0===this.kj&&(this.yb=2)):(this.d.opacity=
|
||||
0,this.b.Y=!0))};t.eb=function(){return{fit:this.Sh,wt:this.kj,fot:this.Sj,s:this.yb,st:this.md.Z,mo:this.gg}};t.ub=function(b){this.Sh=b.fit;this.kj=b.wt;this.Sj=b.fot;this.yb=b.s;this.md.reset();this.md.Z=b.st;this.gg=b.mo};t.Sa=function(){this.md.add(this.b.Pf(this.d));0===this.yb&&(this.d.opacity=this.md.Z/this.Sh*this.gg,this.b.Y=!0,this.d.opacity>=this.gg&&(this.d.opacity=this.gg,this.yb=1,this.md.reset(),this.b.trigger(Bc.prototype.g.Xs,this.d)));1===this.yb&&this.md.Z>=this.kj&&(this.yb=2,
|
||||
this.md.reset(),this.b.trigger(Bc.prototype.g.Nl,this.d));2===this.yb&&0!==this.Sj&&(this.d.opacity=this.gg-this.md.Z/this.Sj*this.gg,this.b.Y=!0,0>this.d.opacity&&(this.d.opacity=0,this.yb=3,this.md.reset(),this.b.trigger(Bc.prototype.g.Ys,this.d),1===this.qu&&this.b.ie(this.d)))};t.Ju=function(){this.yb=0;this.md.reset();0===this.Sh?(this.yb=1,0===this.kj&&(this.yb=2)):(this.d.opacity=0,this.b.Y=!0)};f.prototype.Ys=function(){return!0};f.prototype.Xs=function(){return!0};f.prototype.Nl=function(){return!0};
|
||||
r.g=new f;q.prototype.At=function(){this.Ju()};r.J=new q;r.Ma=new function(){}})();function Cc(f){this.b=f}
|
||||
(function(){function f(){}function q(){}var r=Cc.prototype;r.la=function(b){this.behavior=b;this.b=b.b};r.la.prototype.N=function(){};r.da=function(b,f){this.type=b;this.behavior=b.behavior;this.d=f;this.b=b.b};var t=r.da.prototype;t.N=function(){this.fe=this.ae=this.yb=this.Hk=this.Kk=0};t.eb=function(){return{ontime:this.Kk,offtime:this.Hk,stage:this.yb,stagetimeleft:this.ae,timeleft:this.fe}};t.ub=function(b){this.Kk=b.ontime;this.Hk=b.offtime;this.yb=b.stage;this.ae=b.stagetimeleft;this.fe=b.timeleft;
|
||||
null===this.fe&&(this.fe=Infinity)};t.Sa=function(){if(!(0>=this.fe)){var b=this.b.Pf(this.d);this.fe-=b;0>=this.fe?(this.fe=0,this.d.visible=!0,this.b.Y=!0,this.b.trigger(Cc.prototype.g.Zs,this.d)):(this.ae-=b,0>=this.ae&&(0===this.yb?(this.d.visible=!1,this.yb=1,this.ae+=this.Hk):(this.d.visible=!0,this.yb=0,this.ae+=this.Kk),this.b.Y=!0))}};f.prototype.Zs=function(){return!0};r.g=new f;q.prototype.Bs=function(b,f,k){this.Kk=b;this.Hk=f;this.yb=1;this.ae=f;this.fe=k;this.d.visible=!1;this.b.Y=!0};
|
||||
r.J=new q;r.Ma=new function(){}})();function Dc(f){this.b=f}
|
||||
(function(){function f(){}var q=Dc.prototype;q.la=function(f){this.behavior=f;this.b=f.b};q.la.prototype.N=function(){};q.da=function(f,b){this.type=f;this.behavior=f.behavior;this.d=b;this.b=f.b};var r=q.da.prototype;r.N=function(){this.xb=null;this.Pk=-1;this.mode=this.Vg=this.rl=this.eh=this.Ee=this.Pi=0;var f=this;this.Eb||(this.Lq=function(b){f.Bn(b)});this.b.Uo(this.Lq)};r.eb=function(){return{uid:this.xb?this.xb.uid:-1,pa:this.Pi,pd:this.Ee,msa:this.eh,tsa:this.rl,lka:this.Vg,m:this.mode}};
|
||||
r.ub=function(f){this.Pk=f.uid;this.Pi=f.pa;this.Ee=f.pd;this.eh=f.msa;this.rl=f.tsa;this.Vg=f.lka;this.mode=f.m};r.je=function(){-1===this.Pk?this.xb=null:this.xb=this.b.Xh(this.Pk);this.Pk=-1};r.Bn=function(f){this.xb==f&&(this.xb=null)};r.lg=function(){this.xb=null;this.b.ux(this.Lq)};r.Sa=function(){};r.ej=function(){if(this.xb){this.Vg!==this.d.j&&(this.eh=La(this.eh+(this.d.j-this.Vg)));var f=this.d.x,b=this.d.y;if(3===this.mode||4===this.mode){var p=Ua(this.d.x,this.d.y,this.xb.x,this.xb.y);
|
||||
if(p>this.Ee||4===this.mode&&p<this.Ee)b=Oa(this.xb.x,this.xb.y,this.d.x,this.d.y),f=this.xb.x+Math.cos(b)*this.Ee,b=this.xb.y+Math.sin(b)*this.Ee}else f=this.xb.x+Math.cos(this.xb.j+this.Pi)*this.Ee,b=this.xb.y+Math.sin(this.xb.j+this.Pi)*this.Ee;this.Vg=p=La(this.eh+(this.xb.j-this.rl));0!==this.mode&&1!==this.mode&&3!==this.mode&&4!==this.mode||this.d.x===f&&this.d.y===b||(this.d.x=f,this.d.y=b,this.d.ta());0!==this.mode&&2!==this.mode||this.d.j===p||(this.d.j=p,this.d.ta())}};q.g=new function(){};
|
||||
f.prototype.yt=function(f,b){if(f){var p=f.Fm(this.d);p&&(this.xb=p,this.Pi=Oa(p.x,p.y,this.d.x,this.d.y)-p.j,this.Ee=Ua(p.x,p.y,this.d.x,this.d.y),this.Vg=this.eh=this.d.j,this.rl=p.j,this.mode=b)}};q.J=new f;q.Ma=new function(){}})();function Ec(f){this.b=f}
|
||||
(function(){function f(){}function q(){}var r=Ec.prototype;r.la=function(b){this.behavior=b;this.b=b.b};r.la.prototype.N=function(){};r.da=function(b,f){this.type=b;this.behavior=b.behavior;this.d=f;this.b=b.b};var t=r.da.prototype;t.N=function(){this.enabled=1==this.q[0];this.Eb||(this.move={max:0,acc:0,dec:0});this.move.max=this.q[1];this.move.acc=this.q[2];this.move.dec=this.q[3];this.Eb||(this.target={x:0,y:0,a:0});this.of=!1;this.ng=this.ff=0;this.ki=!1;this.Eb||(this.Kd={x:0,y:0});this.Kd.x=
|
||||
0;this.Kd.y=0;this.Eb||(this.Zc={x:0,y:0,a:-1});this.Zc.x=0;this.Zc.y=0;this.Zc.a=-1;this.uj=null;this.cn=!1};t.Sa=function(){this.ki&&(this.d.x==this.target.x&&this.d.y==this.target.y&&(this.cn=!0,this.b.trigger(Ec.prototype.g.$s,this.d),this.cn=!1),this.ki=!1);if(this.enabled&&this.of){var b=this.b.Pf(this.d);if(0!=b){this.Kd.x==this.d.x&&this.Kd.y==this.d.y||this.Ul();var f=!1;0!=this.move.dec&&(f=this.ff,f=f*f/(2*this.move.dec)>=this.ng);f=f?-this.move.dec:this.move.acc;0!=f&&this.Bg(this.ff+
|
||||
f*b);b=this.ff*b;this.ng-=b;0>=this.ng||0>=this.ff?(this.of=!1,this.d.x=this.target.x,this.d.y=this.target.y,this.Bg(0),this.Jq(),this.ki=!0):(f=this.target.a,this.d.x+=b*Math.cos(f),this.d.y+=b*Math.sin(f));this.d.ta();this.Kd.x=this.d.x;this.Kd.y=this.d.y}}};t.ej=function(){this.Zc.x=this.d.x;this.Zc.y=this.d.y};t.Bg=function(b){null!=b?this.ff=b>this.move.max?this.move.max:b:0==this.move.acc&&(this.ff=this.move.max)};t.Ul=function(){var b=this.target.x-this.d.x,f=this.target.y-this.d.y;this.target.a=
|
||||
Math.atan2(f,b);this.ng=Math.sqrt(b*b+f*f);this.Kd.x=this.d.x;this.Kd.y=this.d.y};t.Pl=function(b,f){this.of=!0;this.target.x=b;this.target.y=f;this.Ul();this.Bg(null);this.Zc.x=this.d.x;this.Zc.y=this.d.y};t.Jl=function(b,f){this.target.x=b;this.target.y=f;this.Ul();this.of=!1;this.d.x=this.target.x;this.d.y=this.target.y;this.Bg(0);this.Jq();this.of=!0};t.Ew=function(){var b=this.b.ee,f=this.uj!=b;this.uj=b;return f};t.Jq=function(){if(this.Ew()){var b=this.d.x-this.Zc.x,f=this.d.y-this.Zc.y;if(0!=
|
||||
b||0!=f)this.Zc.a=Ma(Math.atan2(f,b))}};t.eb=function(){return{en:this.enabled,v:this.move,t:this.target,is_m:this.of,c_spd:this.ff,rd:this.ng,is_ht:this.ki,pp:this.Kd,ma:this.Zc,lt:this.uj}};t.ub=function(b){this.enabled=b.en;this.move=b.v;this.target=b.t;this.of=b.is_m;this.ff=b.c_spd;this.ng=b.rd;this.ki=b.is_ht;this.Kd=b.pp;this.Zc=b.ma;this.uj=b.lt};r.g=new f;f.prototype.$s=function(){return this.cn};r.J=new q;q.prototype.Ol=function(b){this.enabled=1===b};q.prototype.Pl=function(b,f){this.Pl(b,
|
||||
f)};q.prototype.Jl=function(b,f){this.Jl(b,f)};q.prototype.Bg=function(b){this.Bg(b)};q.prototype.Ql=function(){this.of=!1};r.Ma=new function(){}})();function Kc(f){this.b=f}
|
||||
(function(){function f(){}function q(){}function r(){}var t=Kc.prototype;t.la=function(b){this.behavior=b;this.b=b.b};t.la.prototype.N=function(){};t.da=function(b,c){this.type=b;this.behavior=b.behavior;this.d=c;this.b=b.b;this.A=0};var b=t.da.prototype,p=2*Math.PI,k=Math.PI/2,d=3*Math.PI/2;b.N=function(){this.B=1===this.q[0];this.bh=this.q[1];this.xo=this.q[2];this.De=this.q[3];this.De+=Math.random()*this.q[4];0===this.De?this.A=0:(this.A=this.q[5]/this.De*p,this.A+=Math.random()*this.q[6]/this.De*
|
||||
p);this.lc=this.q[7];this.lc+=Math.random()*this.q[8];this.Yd=this.Uf=this.ja=0;5===this.bh&&(this.lc=Q(this.lc));this.init()};b.eb=function(){return{i:this.A,a:this.B,mv:this.bh,w:this.xo,p:this.De,mag:this.lc,iv:this.ja,iv2:this.Uf,r:this.Yd,lkv:this.Ab,lkv2:this.qi}};b.ub=function(b){this.A=b.i;this.B=b.a;this.bh=b.mv;this.xo=b.w;this.De=b.p;this.lc=b.mag;this.ja=b.iv;this.Uf=b.iv2||0;this.Yd=b.r;this.Ab=b.lkv;this.qi=b.lkv2||0};b.init=function(){switch(this.bh){case 0:this.ja=this.d.x;break;case 1:this.ja=
|
||||
this.d.y;break;case 2:this.ja=this.d.width;this.Yd=this.d.height/this.d.width;break;case 3:this.ja=this.d.width;break;case 4:this.ja=this.d.height;break;case 5:this.ja=this.d.j;break;case 6:this.ja=this.d.opacity;break;case 7:this.ja=0;break;case 8:this.ja=this.d.x,this.Uf=this.d.y}this.Ab=this.ja;this.qi=this.Uf};b.he=function(b){b=b%p;switch(this.xo){case 0:return Math.sin(b);case 1:return b<=k?b/k:b<=d?1-2*(b-k)/Math.PI:(b-d)/k-1;case 2:return 2*b/p-1;case 3:return-2*b/p+1;case 4:return b<Math.PI?
|
||||
-1:1}return 0};b.Sa=function(){var b=this.b.Pf(this.d);this.B&&0!==b&&(0===this.De?this.A=0:(this.A+=b/this.De*p,this.A=this.A%p),this.Vx())};b.Vx=function(){switch(this.bh){case 0:this.d.x!==this.Ab&&(this.ja+=this.d.x-this.Ab);this.d.x=this.ja+this.he(this.A)*this.lc;this.Ab=this.d.x;break;case 1:this.d.y!==this.Ab&&(this.ja+=this.d.y-this.Ab);this.d.y=this.ja+this.he(this.A)*this.lc;this.Ab=this.d.y;break;case 2:this.d.width=this.ja+this.he(this.A)*this.lc;this.d.height=this.d.width*this.Yd;break;
|
||||
case 3:this.d.width=this.ja+this.he(this.A)*this.lc;break;case 4:this.d.height=this.ja+this.he(this.A)*this.lc;break;case 5:this.d.j!==this.Ab&&(this.ja=La(this.ja+(this.d.j-this.Ab)));this.d.j=La(this.ja+this.he(this.A)*this.lc);this.Ab=this.d.j;break;case 6:this.d.opacity=this.ja+this.he(this.A)*this.lc/100;0>this.d.opacity?this.d.opacity=0:1<this.d.opacity&&(this.d.opacity=1);break;case 8:this.d.x!==this.Ab&&(this.ja+=this.d.x-this.Ab),this.d.y!==this.qi&&(this.Uf+=this.d.y-this.qi),this.d.x=this.ja+
|
||||
Math.cos(this.d.j)*this.he(this.A)*this.lc,this.d.y=this.Uf+Math.sin(this.d.j)*this.he(this.A)*this.lc,this.Ab=this.d.x,this.qi=this.d.y}this.d.ta()};b.Zq=function(b,c){switch(this.bh){case 2:this.ja*=c.width/b.width;this.Yd=c.height/c.width;break;case 3:this.ja*=c.width/b.width;break;case 4:this.ja*=c.height/b.height}};f.prototype.Fs=function(){return this.B};t.g=new f;q.prototype.Mo=function(b){this.B=1===b};t.J=new q;r.prototype.Rt=function(b){b.H(this.he(this.A)*this.lc)};t.Ma=new r})();
|
||||
function Lc(f){this.b=f}
|
||||
(function(){function f(b,f){return(b/=f)<1/2.75?7.5625*b*b+0:b<2/2.75?1*(7.5625*(b-=1.5/2.75)*b+.75)+0:b<2.5/2.75?1*(7.5625*(b-=2.25/2.75)*b+.9375)+0:1*(7.5625*(b-=2.625/2.75)*b+.984375)+0}var q=Lc.prototype;q.la=function(b){this.behavior=b;this.b=b.b};q.la.prototype.N=function(){};q.da=function(b,f){this.type=b;this.behavior=b.behavior;this.d=f;this.b=b.b;this.A=0};var r=q.da.prototype;r.Gh=function(b){1<b&&(b=1);ic[this.group]=-1;ic[this.group]=b;ic[this.group]>=b&&(ic[this.group]=b)};r.Kp=function(){""!=
|
||||
this.group&&("undefined"===typeof jc&&(jc={},ic={}),"undefined"===typeof jc[this.group]&&(jc[this.group]=[],ic[this.group]=-1),-1==jc[this.group].indexOf(this)&&jc[this.group].push(this))};r.vf=function(){this.Wc=this.d.width;this.Vc=this.d.height;this.xh=this.d.j;this.cs=this.d.opacity;this.zf=this.d.x;this.Af=this.d.y;this.yl=this.value};r.N=function(){this.B=1===this.q[0];this.F=this.q[1];this.Oh=this.q[2];this.u=this.q[3];this.target=this.q[4];this.duration=this.q[5];this.vg=this.q[6];this.O=
|
||||
this.q[7];this.value=this.q[8];this.Zb=this.q[9];this.zm=1===this.q[10];this.group=this.q[11];this.oc=null;this.wc=0;5==this.O&&(this.wc=1);this.Kp();this.Vf=!1;this.U=this.d.x;this.jb=this.d.y;this.W=parseFloat(this.target.split(",")[0]);this.fb=parseFloat(this.target.split(",")[1]);this.vf();this.yh=this.Sb=this.Ba=this.gb=this.ba=0;this.Yd=this.d.height/this.d.width;this.al=this.reverse=!1;this.yd=this.xd=!0;this.loop=!1;this.Oa=this.ya=0;this.hn=this.O;this.vc=this.Ab=this.ba;this.Rc=this.gb;
|
||||
this.zm&&this.init();""==this.u&&(this.u="current");this.Ii=this.fh=this.Ji=this.gh=this.Mi=this.ih=this.Li=this.hh=!1;this.B&&this.init()};r.init=function(){this.hh=!1;""===this.u&&(this.u="current");""===this.target&&(this.target="current");var b="current"===this.u,f="current"===this.target,k="OBJ"===this.target;"OBJ"===this.target&&null!=this.oc&&(0==this.F?this.target=1==this.Zb?this.oc.x-this.d.x+","+(this.oc.y-this.d.y):this.oc.x+","+this.oc.y:1==this.F||2==this.F||3==this.F||7==this.F?this.target=
|
||||
1==this.Zb?(2==this.F?1:this.oc.width)+","+(3==this.F?1:this.oc.height):(2==this.F?1:this.oc.width/this.Wc)+","+(3==this.F?1:this.oc.height/this.Vc):4==this.F?this.target=1==this.Zb?Ia(this.oc.j-this.d.j)+"":Ia(this.oc.j)+"":5==this.F&&(this.target=1==this.Zb?100*(this.oc.opacity-this.d.opacity)+"":100*this.oc.opacity+""));if(0==this.F)f&&(this.target=this.d.x+","+this.d.y),b?this.u=1==this.Zb?this.d.x+","+this.d.y:this.zf+","+this.Af:this.reverse||1==this.O||(this.d.x=parseFloat(this.u.split(",")[0]),
|
||||
this.d.y=parseFloat(this.u.split(",")[1])),1==this.Zb?(this.loop&&(this.d.x=this.zf,this.d.y=this.Af),this.U=this.d.x,this.jb=this.d.y,this.reverse?(this.W=-parseFloat(this.target.split(",")[0]),this.fb=-parseFloat(this.target.split(",")[1])):(this.W=parseFloat(this.target.split(",")[0]),this.fb=parseFloat(this.target.split(",")[1])),this.ba=this.U,this.gb=this.jb,this.Ba=this.ba+this.W,this.Sb=this.gb+this.fb):(this.reverse?(this.d.x=parseFloat(this.target.split(",")[0]),this.d.y=parseFloat(this.target.split(",")[1]),
|
||||
this.W=this.zf,this.fb=this.Af):(this.d.x=this.zf,this.d.y=this.Af,this.W=parseFloat(this.target.split(",")[0]),this.fb=parseFloat(this.target.split(",")[1])),this.U=this.d.x,this.jb=this.d.y,this.ba=this.U,this.gb=this.jb,this.Ba=this.W,this.Sb=this.fb,-6==this.O&&(this.Ba=this.zf,this.Sb=this.Af));else if(1==this.F||2==this.F||3==this.F){f&&(this.target="1,1");"current"==this.u&&(this.u="1,1");this.u=""+this.u;this.target=""+this.target;2==this.F?(-1==this.u.indexOf(",")&&(this.u=parseFloat(this.u)+
|
||||
",1"),-1==this.target.indexOf(",")&&(this.target=parseFloat(this.target)+",1")):3==this.F?(-1==this.u.indexOf(",")&&(this.u="1,"+parseFloat(this.u)),-1==this.target.indexOf(",")&&(this.target="1,"+parseFloat(this.target))):(-1==this.u.indexOf(",")&&(this.u=parseFloat(this.u)+","+parseFloat(this.u)),-1==this.target.indexOf(",")&&(this.target=parseFloat(this.target)+","+parseFloat(this.target)));var d=parseFloat(this.u.split(",")[0]),h=parseFloat(this.u.split(",")[1]);this.xd=!0;var c=parseFloat(this.target.split(",")[0]);
|
||||
if(0==c||isNaN(c))this.xd=!1;3==this.F&&(this.xd=!1);this.yd=!0;var a=parseFloat(this.target.split(",")[1]);if(0==a||isNaN(a))this.yd=!1;2==this.F&&(this.yd=!1);1==this.Zb?(this.loop&&(this.d.width=this.Wc,this.d.height=this.Vc),b||(this.reverse?(this.d.width=this.d.width*c,this.d.height=this.d.height*a):(this.d.width=this.d.width*d,this.d.height=this.d.height*h)),this.U=this.d.width,this.jb=this.d.height,this.ba=this.U,this.gb=this.jb,this.reverse?(this.W=this.U*d/c,this.fb=this.jb*h/a):(this.W=
|
||||
this.U*c,this.fb=this.jb*a)):(b||(this.reverse?(this.d.width=this.Wc*c,this.d.height=this.Vc*a):(this.d.width=this.Wc*d,this.d.height=this.Vc*h)),this.U=this.d.width,this.jb=this.d.height,this.ba=this.U,this.gb=this.jb,this.reverse?(this.W=this.Wc*d,this.fb=this.Vc*h):(this.W=this.Wc*c,this.fb=this.Vc*a));this.Ba=this.W;this.Sb=this.fb;-6==this.O&&(this.Ba=this.Wc*d,this.Sb=this.Vc*h)}else if(4==this.F)f&&(this.target=Ia(this.d.j)),"current"==this.u||this.reverse||1==this.O||(this.d.j=Q(parseFloat(this.u.split(",")[0]))),
|
||||
1==this.Zb?(this.loop&&(this.d.j=this.xh),this.U=this.d.j,this.reverse?this.W=this.d.j-Q(parseFloat(this.target.split(",")[0])):this.W=this.d.j+Q(parseFloat(this.target.split(",")[0]))):this.reverse?(this.d.j=Q(parseFloat(this.target.split(",")[0])),this.U=this.d.j,this.W=this.xh):(this.d.j=this.xh,this.U=this.d.j,this.W=Q(parseFloat(this.target.split(",")[0]))),this.ba=this.U,this.Ba=Ia(this.W),-6==this.O&&(this.Ba=Ia(this.xh)),this.yh=Q(this.Ba);else if(5==this.F)"current"==this.u&&(this.u=this.d.opacity),
|
||||
f&&(this.target=""+this.d.opacity),b||this.reverse||1==this.O||(this.d.opacity=parseFloat(this.u.split(",")[0])/100),1==this.Zb?(this.loop&&(this.d.opacity=this.cs),this.ba=this.U=this.d.opacity,this.W=this.reverse?-parseFloat(this.target.split(",")[0])/100:parseFloat(this.target.split(",")[0])/100,this.Ba=this.ba+this.W):(this.U=this.d.opacity,this.reverse?(this.ba=parseFloat(this.target.split(",")[0])/100,this.W=parseFloat(this.u.split(",")[0])/100):(this.ba=this.U,this.W=parseFloat(this.target.split(",")[0])/
|
||||
100),this.Ba=this.W),-6==this.O&&(this.Ba=this.cs);else if(6==this.F)isNaN(this.value)&&(this.value=0),"current"==this.u&&(this.u=""+this.value),f&&(this.target=""+this.value),b||this.reverse||1==this.O||(this.value=parseFloat(this.u.split(",")[0])),1==this.Zb?(this.loop&&(this.value=this.yl),b||(this.value=this.reverse?parseFloat(this.target.split(",")[0]):parseFloat(this.u.split(",")[0])),this.U=this.value,this.reverse?this.W=this.U-parseFloat(this.target.split(",")[0]):this.W=this.U+parseFloat(this.target.split(",")[0]),
|
||||
this.ba=this.U,this.Ba=this.W):(b||(this.value=this.reverse?parseFloat(this.target.split(",")[0]):parseFloat(this.u.split(",")[0])),this.U=this.value,this.W=this.reverse?parseFloat(this.u.split(",")[0]):parseFloat(this.target.split(",")[0]),this.ba=this.U,this.Ba=this.W),-6==this.O&&(this.Ba=this.yl);else if(7==this.F){f&&(this.target=this.d.width+","+this.d.height);"current"==this.u||this.reverse||1==this.O||(this.d.width=parseFloat(this.u.split(",")[0]),this.d.height=parseFloat(this.u.split(",")[1]));
|
||||
this.xd=!0;c=parseFloat(this.target.split(",")[0]);if(0>c||isNaN(c))this.xd=!1;this.yd=!0;a=parseFloat(this.target.split(",")[1]);if(0>a||isNaN(a))this.yd=!1;1==this.Zb?(this.loop&&(this.d.width=this.Wc,this.d.height=this.Vc),this.U=this.d.width,this.jb=this.d.height,this.reverse?(this.W=this.U-parseFloat(this.target.split(",")[0]),this.fb=this.jb-parseFloat(this.target.split(",")[1])):(this.W=this.U+parseFloat(this.target.split(",")[0]),this.fb=this.jb+parseFloat(this.target.split(",")[1]))):(b||
|
||||
(this.reverse?(this.d.width=parseFloat(this.target.split(",")[0]),this.d.height=parseFloat(this.target.split(",")[1])):(this.d.width=this.Wc,this.d.height=this.Vc)),this.U=this.d.width,this.jb=this.d.height,this.reverse?(this.W=this.Wc,this.fb=this.Vc):(this.W=parseFloat(this.target.split(",")[0]),this.fb=parseFloat(this.target.split(",")[1])));this.ba=this.U;this.gb=this.jb;this.Ba=this.W;this.Sb=this.fb;-6==this.O&&(this.Ba=this.Wc,this.Sb=this.Vc)}this.vc=this.Ab=this.ba;this.Rc=this.gb;this.ya=
|
||||
parseFloat(this.vg.split(",")[0]);this.Oa=parseFloat(this.vg.split(",")[1]);if(0>this.ya||isNaN(this.ya))this.ya=0;if(0>this.Oa||isNaN(this.Oa))this.Oa=0;b&&(this.u="current");f&&(this.target="current");k&&(this.target="OBJ")};r.Ru=function(b,p){switch(this.Oh){case 0:return 1*b/p+0;case 1:return 1*(b/=p)*b+0;case 2:return-1*(b/=p)*(b-2)+0;case 3:return 1>(b/=p/2)?.5*b*b+0:-.5*(--b*(b-2)-1)+0;case 4:return 1*(b/=p)*b*b+0;case 5:return 1*((b=b/p-1)*b*b+1)+0;case 6:return 1>(b/=p/2)?.5*b*b*b+0:.5*((b-=
|
||||
2)*b*b+2)+0;case 7:return 1*(b/=p)*b*b*b+0;case 8:return-1*((b=b/p-1)*b*b*b-1)+0;case 9:return 1>(b/=p/2)?.5*b*b*b*b+0:-.5*((b-=2)*b*b*b-2)+0;case 10:return 1*(b/=p)*b*b*b*b+0;case 11:return 1*((b=b/p-1)*b*b*b*b+1)+0;case 12:return 1>(b/=p/2)?.5*b*b*b*b*b+0:.5*((b-=2)*b*b*b*b+2)+0;case 13:return-1*(Math.sqrt(1-(b/=p)*b)-1)+0;case 14:return 1*Math.sqrt(1-(b=b/p-1)*b)+0;case 15:return 1>(b/=p/2)?-.5*(Math.sqrt(1-b*b)-1)+0:.5*(Math.sqrt(1-(b-=2)*b)+1)+0;case 16:var k=0;0==k&&(k=1.70158);return 1*(b/=
|
||||
p)*b*((k+1)*b-k)+0;case 17:return k=0,0==k&&(k=1.70158),1*((b=b/p-1)*b*((k+1)*b+k)+1)+0;case 18:return k=0,0==k&&(k=1.70158),1>(b/=p/2)?.5*b*b*(((k*=1.525)+1)*b-k)+0:.5*((b-=2)*b*(((k*=1.525)+1)*b+k)+2)+0;case 19:var d=0,h=0;if(0==b)break;if(1==(b/=p))return 1;0==h&&(h=.3*p);0==d||d<Math.abs(1)?(d=1,k=h/4):k=h/(2*Math.PI)*Math.asin(1/d);return-(d*Math.pow(2,10*--b)*Math.sin(2*(b*p-k)*Math.PI/h))+0;case 20:h=d=0;if(0==b)break;if(1==(b/=p))return 1;0==h&&(h=.3*p);0==d||d<Math.abs(1)?(d=1,k=h/4):k=h/
|
||||
(2*Math.PI)*Math.asin(1/d);return d*Math.pow(2,-10*b)*Math.sin(2*(b*p-k)*Math.PI/h)+1;case 21:h=d=0;if(0==b)break;if(2==(b/=p/2))return 1;0==h&&(h=.3*p*1.5);0==d||d<Math.abs(1)?(d=1,k=h/4):k=h/(2*Math.PI)*Math.asin(1/d);return 1>b?-.5*d*Math.pow(2,10*--b)*Math.sin(2*(b*p-k)*Math.PI/h)+0:d*Math.pow(2,-10*--b)*Math.sin(2*(b*p-k)*Math.PI/h)*.5+1;case 22:return 1-f(p-b,p)+0;case 23:return f(b,p);case 24:return b<p/2?.5*(1-f(p-2*b,p)+0)+0:.5*f(2*b-p,p)+.5;case 25:return k=b/p/2,2*k*k*(3-2*k);case 26:return k=
|
||||
(b/p+1)/2,2*k*k*(3-2*k)-1;case 27:return k=b/p,k*k*(3-2*k)}return 0};r.eb=function(){return{i:this.A,active:this.B,tweened:this.F,easing:this.Oh,initial:this.u,target:this.target,duration:this.duration,wait:this.vg,playmode:this.O,value:this.value,coord_mode:this.Zb,forceInit:this.zm,group:this.group,targetObject:this.oc,pingpongCounter:this.wc,isPaused:this.Vf,initialX:this.U,initialY:this.jb,targetX:this.W,targetY:this.fb,tweenSaveWidth:this.Wc,tweenSaveHeight:this.Vc,tweenSaveAngle:this.xh,tweenSaveX:this.zf,
|
||||
tweenSaveY:this.Af,tweenSaveValue:this.yl,tweenInitialX:this.ba,tweenInitialY:this.gb,tweenTargetX:this.Ba,tweenTargetY:this.Sb,tweenTargetAngle:this.yh,ratio:this.Yd,reverse:this.reverse,rewindMode:this.al,doTweenX:this.xd,doTweenY:this.yd,loop:this.loop,initiating:this.ya,cooldown:this.Oa,lastPlayMode:this.hn,lastKnownValue:this.Ab,lastKnownX:this.vc,lastKnownY:this.Rc,onStarted:this.hh,onStartedDone:this.Li,onWaitEnd:this.ih,onWaitEndDone:this.Mi,onEnd:this.gh,onEndDone:this.Ji,onCooldown:this.fh,
|
||||
onCooldownDone:this.Ii}};r.ub=function(b){this.A=b.i;this.B=b.active;this.F=b.tweened;this.Oh=b.easing;this.u=b.initial;this.target=b.target;this.duration=b.duration;this.vg=b.wait;this.O=b.playmode;this.value=b.value;this.Zb=b.coord_mode;this.zm=b.forceInit;this.group=b.group;this.oc=b.targetObject;this.wc=b.pingpongCounter;this.Vf=b.isPaused;this.U=b.initialX;this.jb=b.initialY;this.W=b.targetX;this.fb=b.targetY;this.Wc=b.tweenSaveWidth;this.Vc=b.tweenSaveHeight;this.xh=b.tweenSaveAngle;this.zf=
|
||||
b.tweenSaveX;this.Af=b.tweenSaveY;this.yl=b.tweenSaveValue;this.ba=b.tweenInitialX;this.gb=b.tweenInitialY;this.Ba=b.tweenTargetX;this.Sb=b.tweenTargetY;this.yh=b.tweenTargetAngle;this.Yd=b.ratio;this.reverse=b.reverse;this.al=b.rewindMode;this.xd=b.doTweenX;this.yd=b.doTweenY;this.loop=b.loop;this.ya=b.initiating;this.Oa=b.cooldown;this.hn=b.lastPlayMode;this.Ab=b.lastKnownValue;this.vc=b.lastKnownX;this.Rc=b.lastKnownY;this.hh=b.onStarted;this.Li=b.onStartedDone;this.ih=b.onWaitEnd;this.Mi=b.onWaitEndDone;
|
||||
this.gh=b.onEnd;this.Ji=b.onEndDone;this.fh=b.onCooldown;this.Ii=b.onCooldownDone;this.Kp()};r.Sa=function(){var b=this.b.Pf(this.d),f=-1==this.A;this.B&&0!==b&&(0!=this.A||this.hh||(this.hh=!0,this.Ii=this.fh=this.Ji=this.gh=this.Mi=this.ih=this.Li=!1,this.b.trigger(Lc.prototype.g.ot,this.d),this.Li=!0),this.A=-1==this.A?this.ya+this.duration+this.Oa:this.A+b,this.A<=this.ya||(0==this.ih&&(this.ih=!0,this.b.trigger(Lc.prototype.g.Nl,this.d),this.Mi=!0),this.A<=this.duration+this.ya&&(b=this.Ru(this.A-
|
||||
this.ya,this.duration),0==this.F?(1==this.Zb?(this.d.x!==this.vc&&(this.ba+=this.d.x-this.vc,this.Ba+=this.d.x-this.vc),this.d.y!==this.Rc&&(this.gb+=this.d.y-this.Rc,this.Sb+=this.d.y-this.Rc)):(this.d.x!==this.vc&&(this.ba+=this.d.x-this.vc),this.d.y!==this.Rc&&(this.gb+=this.d.y-this.Rc)),this.d.x=this.ba+(this.Ba-this.ba)*b,this.d.y=this.gb+(this.Sb-this.gb)*b,this.vc=this.d.x,this.Rc=this.d.y):1==this.F||2==this.F||3==this.F?(this.d.width!==this.vc&&(this.ba=this.d.width),this.d.height!==this.Rc&&
|
||||
(this.gb=this.d.height),this.xd&&(this.d.width=this.ba+(this.Ba-this.ba)*b),this.yd?this.d.height=this.gb+(this.Sb-this.gb)*b:1==this.F&&(this.d.height=this.d.width*this.Yd),this.vc=this.d.width,this.Rc=this.d.height):4==this.F?(b=this.ba+(this.yh-this.ba)*b,this.A>=this.duration+this.ya&&(b=this.yh),this.d.j=La(b)):5==this.F?(1==this.Zb&&this.d.opacity!==this.vc&&(this.ba=this.d.opacity),this.d.opacity=this.ba+(this.Ba-this.ba)*b,this.vc=this.d.opacity):6==this.F?this.value=this.ba+(this.Ba-this.ba)*
|
||||
b:7==this.F&&(1==this.Zb&&(this.d.width!==this.vc&&(this.ba=this.d.width),this.d.height!==this.Rc&&(this.gb=this.d.height)),this.xd&&(this.d.width=this.ba+(this.Ba-this.ba)*b),this.yd&&(this.d.height=this.gb+(this.Sb-this.gb)*b),this.vc=this.d.width,this.Rc=this.d.height),this.d.ta()),this.A>=this.duration+this.ya&&(this.vu(f),this.d.ta(),0==this.gh&&(this.gh=!0,this.b.trigger(Lc.prototype.g.Ws,this.d),this.Ji=!0))))};r.vu=function(b){switch(this.F){case 0:this.d.x=this.Ba;this.d.y=this.Sb;break;
|
||||
case 1:this.xd&&(this.d.width=this.Ba);this.yd?this.d.height=this.Sb:this.d.height=this.d.width*this.Yd;break;case 2:this.d.width=this.Ba;break;case 3:this.d.height=this.Sb;break;case 4:this.d.j=La(this.yh);this.Ab=this.d.j;break;case 5:this.d.opacity=this.Ba;break;case 6:this.value=this.Ba;break;case 7:this.xd&&(this.d.width=this.Ba),this.yd&&(this.d.height=this.Sb)}this.A>=this.duration+this.ya+this.Oa&&(0==this.O?(this.reverse=this.B=!1,this.A=this.duration+this.ya+this.Oa):1==this.O?(this.A=0,
|
||||
this.init(),this.B=!0):2==this.O?b?(this.reverse=!1,this.init()):(this.reverse=!this.reverse,this.A=0,this.init(),this.B=!0):3==this.O?this.b.ie(this.d):4==this.O?(this.loop=!0,this.A=0,this.init(),this.B=!0):5==this.O?b?(this.reverse=!1,this.init()):0>=this.wc?(this.A=this.duration+this.ya+this.Oa,this.B=!1):(this.reverse?(--this.wc,this.reverse=!1):(--this.wc,this.reverse=!0),this.A=0,this.init(),this.B=!0):-6==this.O?(this.O=this.hn,this.reverse=!1,this.A=0,this.B=!1):6==this.O&&(this.reverse=
|
||||
!1,this.A=this.duration+this.ya+this.Oa,this.B=!1));0==this.fh&&(this.fh=!0,this.b.trigger(Lc.prototype.g.Rs,this.d),this.Ii=!0)};q.g={};r=q.g;r.Fs=function(){return this.B};r.ly=function(b,f){var k=[];jc[this.group].forEach(function(b){k.push(b.A/(b.duration+b.ya+b.Oa))});return hc(Math.min.apply(null,k),b,f)};r.oy=function(b,f){return hc(this.A/(this.duration+this.ya+this.Oa),b,f)};r.ot=function(){if(!1===this.Li)return this.hh};r.Nl=function(){if(!1===this.Mi)return this.ih};r.Ws=function(){if(!1===
|
||||
this.Ji)return this.gh};r.Rs=function(){if(!1===this.Ii)return this.fh};q.J={};var t=q.J;t.Mo=function(b){this.B=1===b};t.Pt=function(b,f){""===f&&(f=this.group);(1===b||jc[f].every(function(b){return!b.B}))&&jc[f].forEach(function(f){1===b?t.Ds.apply(f):t.Ot.apply(f)})};t.uz=function(b,f){""===f&&(f=this.group);jc[f].forEach(function(f){t.Ql.apply(f,[b])})};t.Dt=function(b,f,k){""===k&&(k=this.group);(1===b||jc[k].every(function(b){return!b.B}))&&jc[k].forEach(function(d){1===b?t.Es.apply(d,[f]):
|
||||
t.Ct.apply(d,[f])})};t.Ds=function(){this.loop=4===this.O;5==this.O&&(this.wc=1);6==this.O||-6==this.O?this.A<this.duration+this.Oa+this.ya&&(this.reverse=!1,this.init(),this.B=!0):(this.reverse=!1,this.A=0,this.init(),this.B=!0)};t.Es=function(b){this.al=1==b;this.loop=4===this.O;5==this.O&&(this.wc=1);6==this.O||-6==this.O?this.A<this.duration+this.Oa+this.ya&&(this.reverse=!0,this.init(),this.B=!0):b?1==this.wc&&this.A>=this.duration+this.Oa+this.ya&&(this.reverse=!0,this.A=0,this.wc=2,this.init(),
|
||||
this.B=!0):(this.reverse=!0,this.A=0,this.init(),this.B=!0)};t.Ot=function(){this.B||(this.loop=4===this.O,5==this.O&&(this.wc=1),6==this.O||-6==this.O?this.A<this.duration+this.Oa+this.ya&&(this.reverse=!1,this.init(),this.B=!0):(this.wc=1,this.reverse=!1,this.A=0,this.init(),this.B=!0))};t.Ql=function(b){this.B&&(2==this.O||4==this.O?this.A=this.reverse?0:-1:1==b?this.vf():0==b?this.A=this.ya+this.Oa+this.duration:this.A=0,this.Sa(),this.B=!1)};t.Ly=function(){this.B&&(this.Vf=!0,this.B=!1)};t.Uy=
|
||||
function(){this.Vf?(this.B=!0,this.Vf=!1):this.B||(this.reverse=!1,this.A=0,this.init(),this.B=!0)};t.Ct=function(b){this.al=1==b;this.B||(this.loop=4===this.O,5==this.O&&(this.wc=1),6==this.O||-6==this.O?this.A<this.duration+this.Oa+this.ya&&(this.reverse=!0,this.init(),this.B=!0):b?1==this.wc&&this.A>=this.duration+this.Oa+this.ya&&(this.reverse=!0,this.A=0,this.wc=2,this.init(),this.B=!0):(this.reverse=!0,this.A=0,this.init(),this.B=!0))};t.Gt=function(b){this.duration=b};t.Lt=function(b){this.vg=
|
||||
b;this.ya=parseFloat(this.vg.split(",")[0]);this.Oa=parseFloat(this.vg.split(",")[1]);if(0>this.ya||isNaN(this.ya))this.ya=0;if(0>this.Oa||isNaN(this.Oa))this.Oa=0};t.Kt=function(b){"string"==typeof b?(this.target=b,this.W=parseFloat(b.split(",")[0]),this.fb=parseFloat(b.split(",")[1])):this.W=this.target=b;this.B||this.init()};t.lz=function(b){b&&(b=b.Fm())&&(this.oc=b,this.target="OBJ")};t.mz=function(b){2==this.F||3==this.F||4==this.F||5==this.F||6==this.F?("string"==typeof b?this.target=parseFloat(b.split(",")[0]):
|
||||
this.target=""+b+","+this.fb,this.W=this.target):(this.target=String(b)+","+this.target.split(",")[1],this.W=parseFloat(this.target.split(",")[0]),this.fb=parseFloat(this.target.split(",")[1]));this.B||(this.vf(),this.init())};t.nz=function(b){2==this.F||3==this.F||4==this.F||5==this.F||6==this.F?this.W=this.target="string"==typeof b?parseFloat(b)+"":this.W+","+b:(this.target=this.target.split(",")[0]+","+String(b),this.W=parseFloat(this.target.split(",")[0]),this.fb=parseFloat(this.target.split(",")[1]));
|
||||
this.B||(this.vf(),this.init())};t.It=function(b){"string"==typeof b?(this.u=b,this.U=parseFloat(b.split(",")[0]),this.jb=parseFloat(b.split(",")[1])):(this.u=""+b,this.U=b);6==this.F&&(this.value=this.U);this.B||(this.vf(),this.init())};t.dz=function(b){2==this.F||3==this.F||4==this.F||5==this.F||6==this.F?("string"==typeof b?this.u=parseFloat(b):this.u=""+b+","+this.jb,this.U=this.u):(""==this.u&&(this.u="current"),this.u=String(b)+","+("current"==this.u?this.Af:this.u.split(",")[1]),this.U=parseFloat(this.u.split(",")[0]),
|
||||
this.jb=parseFloat(this.u.split(",")[1]));6==this.F&&(this.value=this.U);this.B||(this.vf(),this.init())};t.ez=function(b){2==this.F||3==this.F||4==this.F||5==this.F||6==this.F?("string"==typeof b?this.u=parseFloat(b):this.u=""+this.U+","+b,this.U=this.u):(""==this.u&&(this.u="current"),this.u=("current"==this.u?this.zf:this.u.split(",")[0])+","+String(b),this.U=parseFloat(this.u.split(",")[0]),this.jb=parseFloat(this.u.split(",")[1]));this.B||(this.vf(),this.init())};t.qz=function(b){this.value=
|
||||
b};t.pz=function(b){this.F=b};t.$y=function(b){this.Oh=b};t.hz=function(b){this.O=b};t.gz=function(b,f,k,d,h,c,a,e){this.F=b;this.O=f;this.Oh=k;t.It.apply(this,[d]);t.Kt.apply(this,[h]);t.Gt.apply(this,[c]);t.Lt.apply(this,[a]);this.Zb=e;this.vf()};q.Ma={};q=q.Ma;q.Sy=function(b){b.H(this.A/(this.duration+this.ya+this.Oa))};q.Ty=function(b){b.H(this.A)};q.ys=function(b){b.H(this.duration)};q.yy=function(b){b.H(this.ya)};q.uy=function(b){b.H(this.Oa)};q.wz=function(b){b.Fb(this.target)};q.Rt=function(b){b.H(this.value)};
|
||||
q.Vf=function(b){b.Na(this.Vf?1:0)}})();
|
||||
function sc(){return[vc,Y,wc,uc,xc,tc,yc,zc,Z,Kc,Ec,Lc,Bc,Dc,Cc,Ac,X.prototype.g.Eo,X.prototype.J.ws,tc.prototype.Ma.No,tc.prototype.Ma.Oo,Dc.prototype.J.yt,uc.prototype.J.CallFunction,tc.prototype.J.xs,X.prototype.J.St,Y.prototype.J.As,uc.prototype.g.qj,zc.prototype.J.tj,tc.prototype.J.tj,zc.prototype.J.sj,zc.prototype.J.Ht,xc.prototype.J.sj,Y.prototype.Ma.zs,X.prototype.g.Cs,tc.prototype.J.Ls,Ec.prototype.J.Pl,tc.prototype.J.Jt,Ec.prototype.J.Jl,Z.prototype.g.Ll,tc.prototype.g.Is,vc.prototype.J.Play,
|
||||
Kc.prototype.J.Mo,Cc.prototype.J.Bs,X.prototype.J.zt,X.prototype.J.Bt,xc.prototype.J.tj,zc.prototype.J.Ol,tc.prototype.g.vs,Lc.prototype.J.Pt,Lc.prototype.J.Dt,X.prototype.g.us,zc.prototype.J.Ft,Bc.prototype.J.At,vc.prototype.J.Qt,tc.prototype.J.Et,X.prototype.g.zo,zc.prototype.Ma.Text,wc.prototype.g.Bo]};
|
||||
1
GameQuiz-InputKeyBoard/data.js
Normal file
BIN
GameQuiz-InputKeyBoard/icon-114.png
Normal file
|
After Width: | Height: | Size: 25 KiB |
BIN
GameQuiz-InputKeyBoard/icon-128.png
Normal file
|
After Width: | Height: | Size: 33 KiB |
BIN
GameQuiz-InputKeyBoard/icon-16.png
Normal file
|
After Width: | Height: | Size: 1.0 KiB |
BIN
GameQuiz-InputKeyBoard/icon-256.png
Normal file
|
After Width: | Height: | Size: 96 KiB |
BIN
GameQuiz-InputKeyBoard/icon-32.png
Normal file
|
After Width: | Height: | Size: 2.9 KiB |
BIN
GameQuiz-InputKeyBoard/images/answers-sheet0.png
Normal file
|
After Width: | Height: | Size: 2.3 MiB |
BIN
GameQuiz-InputKeyBoard/images/answers-sheet1.png
Normal file
|
After Width: | Height: | Size: 2.2 MiB |
BIN
GameQuiz-InputKeyBoard/images/answers2-sheet0.png
Normal file
|
After Width: | Height: | Size: 23 KiB |
BIN
GameQuiz-InputKeyBoard/images/back-sheet0.png
Normal file
|
After Width: | Height: | Size: 58 KiB |
BIN
GameQuiz-InputKeyBoard/images/bg-sheet0.png
Normal file
|
After Width: | Height: | Size: 137 KiB |
BIN
GameQuiz-InputKeyBoard/images/bgm-sheet0.png
Normal file
|
After Width: | Height: | Size: 668 KiB |
BIN
GameQuiz-InputKeyBoard/images/bgm-sheet1.png
Normal file
|
After Width: | Height: | Size: 604 KiB |
BIN
GameQuiz-InputKeyBoard/images/button-sheet0.png
Normal file
|
After Width: | Height: | Size: 29 KiB |
BIN
GameQuiz-InputKeyBoard/images/complete-sheet0.png
Normal file
|
After Width: | Height: | Size: 131 KiB |
BIN
GameQuiz-InputKeyBoard/images/correct-sheet0.png
Normal file
|
After Width: | Height: | Size: 149 KiB |
BIN
GameQuiz-InputKeyBoard/images/dim-sheet0.png
Normal file
|
After Width: | Height: | Size: 168 B |
BIN
GameQuiz-InputKeyBoard/images/greenborder-sheet0.png
Normal file
|
After Width: | Height: | Size: 79 KiB |
BIN
GameQuiz-InputKeyBoard/images/inputframe-sheet0.png
Normal file
|
After Width: | Height: | Size: 190 KiB |
BIN
GameQuiz-InputKeyBoard/images/khunganh-sheet0.png
Normal file
|
After Width: | Height: | Size: 288 KiB |
BIN
GameQuiz-InputKeyBoard/images/khunganh-sheet1.png
Normal file
|
After Width: | Height: | Size: 80 KiB |
BIN
GameQuiz-InputKeyBoard/images/next-sheet0.png
Normal file
|
After Width: | Height: | Size: 30 KiB |
BIN
GameQuiz-InputKeyBoard/images/next-sheet1.png
Normal file
|
After Width: | Height: | Size: 99 KiB |
BIN
GameQuiz-InputKeyBoard/images/nextqs-sheet0.png
Normal file
|
After Width: | Height: | Size: 25 KiB |
BIN
GameQuiz-InputKeyBoard/images/question-sheet0.png
Normal file
|
After Width: | Height: | Size: 1.7 MiB |
BIN
GameQuiz-InputKeyBoard/images/quiz-sheet0.png
Normal file
|
After Width: | Height: | Size: 325 KiB |
BIN
GameQuiz-InputKeyBoard/images/replay-sheet0.png
Normal file
|
After Width: | Height: | Size: 73 KiB |
BIN
GameQuiz-InputKeyBoard/images/sound-sheet0.png
Normal file
|
After Width: | Height: | Size: 123 KiB |
BIN
GameQuiz-InputKeyBoard/images/sprite-sheet0.png
Normal file
|
After Width: | Height: | Size: 168 B |
BIN
GameQuiz-InputKeyBoard/images/submit-sheet0.png
Normal file
|
After Width: | Height: | Size: 72 KiB |
BIN
GameQuiz-InputKeyBoard/images/txt_scenario.png
Normal file
|
After Width: | Height: | Size: 92 KiB |
BIN
GameQuiz-InputKeyBoard/images/wrong-sheet0.png
Normal file
|
After Width: | Height: | Size: 11 KiB |
BIN
GameQuiz-InputKeyBoard/images/zoom-sheet0.png
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
GameQuiz-InputKeyBoard/images/zoom-sheet1.png
Normal file
|
After Width: | Height: | Size: 39 KiB |
139
GameQuiz-InputKeyBoard/index.html
Normal file
@@ -0,0 +1,139 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="UTF-8" />
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
|
||||
<title>GameQuiz-InputKeyBoard</title>
|
||||
|
||||
<!-- Standardised web app manifest -->
|
||||
<link rel="manifest" href="appmanifest.json" />
|
||||
|
||||
<!-- Allow fullscreen mode on iOS devices. (These are Apple specific meta tags.) -->
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, user-scalable=no, minimal-ui" />
|
||||
<meta name="apple-mobile-web-app-capable" content="yes" />
|
||||
<meta name="apple-mobile-web-app-status-bar-style" content="black" />
|
||||
<link rel="apple-touch-icon" sizes="256x256" href="icon-256.png" />
|
||||
<meta name="HandheldFriendly" content="true" />
|
||||
|
||||
<!-- Chrome for Android web app tags -->
|
||||
<meta name="mobile-web-app-capable" content="yes" />
|
||||
<link rel="shortcut icon" sizes="256x256" href="icon-256.png" />
|
||||
|
||||
<!-- All margins and padding must be zero for the canvas to fill the screen. -->
|
||||
<style type="text/css">
|
||||
* {
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
}
|
||||
html, body {
|
||||
color: #fff;
|
||||
overflow: hidden;
|
||||
touch-action: none;
|
||||
-ms-touch-action: none;
|
||||
}
|
||||
canvas {
|
||||
touch-action-delay: none;
|
||||
touch-action: none;
|
||||
-ms-touch-action: none;
|
||||
}
|
||||
</style>
|
||||
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="fb-root"></div>
|
||||
<div style="width: 100%; height: 100%; position: absolute; top: 0; left: 0; z-index: -1;">
|
||||
<!--<img src = "./bg.jpg" style="width:100%; height: 100%; object-fit: cover;"/> -->
|
||||
<video autoplay="" loop="" muted="" style="width : 100%; height: 100%;object-fit: cover;" src="bg.mp4">
|
||||
</video>
|
||||
</div>
|
||||
<script>
|
||||
// Issue a warning if trying to preview an exported project on disk.
|
||||
(function(){
|
||||
// Check for running exported on file protocol
|
||||
if (window.location.protocol.substr(0, 4) === "file")
|
||||
{
|
||||
alert("Exported games won't work until you upload them. (When running on the file:/// protocol, browsers block many features from working for security reasons.)");
|
||||
}
|
||||
})();
|
||||
</script>
|
||||
|
||||
<!-- The canvas must be inside a div called c2canvasdiv -->
|
||||
<div id="c2canvasdiv">
|
||||
|
||||
<!-- The canvas the project will render to. If you change its ID, don't forget to change the
|
||||
ID the runtime looks for in the jQuery events above (ready() and cr_sizeCanvas()). -->
|
||||
<canvas id="c2canvas" width="1400" height="900">
|
||||
<!-- This text is displayed if the visitor's browser does not support HTML5.
|
||||
You can change it, but it is a good idea to link to a description of a browser
|
||||
and provide some links to download some popular HTML5-compatible browsers. -->
|
||||
<h1>Your browser does not appear to support HTML5. Try upgrading your browser to the latest version. <a href="http://www.whatbrowser.org">What is a browser?</a>
|
||||
<br/><br/><a href="http://www.microsoft.com/windows/internet-explorer/default.aspx">Microsoft Internet Explorer</a><br/>
|
||||
<a href="http://www.mozilla.com/firefox/">Mozilla Firefox</a><br/>
|
||||
<a href="http://www.google.com/chrome/">Google Chrome</a><br/>
|
||||
<a href="http://www.apple.com/safari/download/">Apple Safari</a></h1>
|
||||
</canvas>
|
||||
|
||||
</div>
|
||||
|
||||
<!-- Pages load faster with scripts at the bottom -->
|
||||
|
||||
<!-- Construct 2 exported games require jQuery. -->
|
||||
<script src="jquery-3.4.1.min.js"></script>
|
||||
<script src="tdv_sdk.js"></script>
|
||||
|
||||
|
||||
<!-- The runtime script. You can rename it, but don't forget to rename the reference here as well.
|
||||
This file will have been minified and obfuscated if you enabled "Minify script" during export. -->
|
||||
<script src="c2runtime.js"></script>
|
||||
|
||||
<script>
|
||||
// Start the Construct 2 project running on window load.
|
||||
jQuery(document).ready(function ()
|
||||
{
|
||||
// Create new runtime using the c2canvas
|
||||
cr_createRuntime("c2canvas");
|
||||
});
|
||||
|
||||
// Pause and resume on page becoming visible/invisible
|
||||
function onVisibilityChanged() {
|
||||
if (document.hidden || document.mozHidden || document.webkitHidden || document.msHidden)
|
||||
cr_setSuspended(true);
|
||||
else
|
||||
cr_setSuspended(false);
|
||||
};
|
||||
|
||||
document.addEventListener("visibilitychange", onVisibilityChanged, false);
|
||||
document.addEventListener("mozvisibilitychange", onVisibilityChanged, false);
|
||||
document.addEventListener("webkitvisibilitychange", onVisibilityChanged, false);
|
||||
document.addEventListener("msvisibilitychange", onVisibilityChanged, false);
|
||||
|
||||
function OnRegisterSWError(e)
|
||||
{
|
||||
console.warn("Failed to register service worker: ", e);
|
||||
};
|
||||
|
||||
// Runtime calls this global method when ready to start caching (i.e. after startup).
|
||||
// This registers the service worker which caches resources for offline support.
|
||||
window.C2_RegisterSW = function C2_RegisterSW()
|
||||
{
|
||||
if (!navigator.serviceWorker)
|
||||
return; // no SW support, ignore call
|
||||
|
||||
try {
|
||||
navigator.serviceWorker.register("sw.js", { scope: "./" })
|
||||
.then(function (reg)
|
||||
{
|
||||
console.log("Registered service worker on " + reg.scope);
|
||||
})
|
||||
.catch(OnRegisterSWError);
|
||||
}
|
||||
catch (e)
|
||||
{
|
||||
OnRegisterSWError(e);
|
||||
}
|
||||
};
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
2
GameQuiz-InputKeyBoard/jquery-3.4.1.min.js
vendored
Normal file
BIN
GameQuiz-InputKeyBoard/loading-logo.png
Normal file
|
After Width: | Height: | Size: 9.2 KiB |
BIN
GameQuiz-InputKeyBoard/media/alert-234711.ogg
Normal file
BIN
GameQuiz-InputKeyBoard/media/applause-383901.ogg
Normal file
BIN
GameQuiz-InputKeyBoard/media/bubble-pop-389501.ogg
Normal file
BIN
GameQuiz-InputKeyBoard/media/button-124476.ogg
Normal file
BIN
GameQuiz-InputKeyBoard/media/click-234708.ogg
Normal file
BIN
GameQuiz-InputKeyBoard/media/click.m4a
Normal file
BIN
GameQuiz-InputKeyBoard/media/click.ogg
Normal file
BIN
GameQuiz-InputKeyBoard/media/collect-5930.ogg
Normal file
BIN
GameQuiz-InputKeyBoard/media/correct-156911.ogg
Normal file
BIN
GameQuiz-InputKeyBoard/media/correct.m4a
Normal file
BIN
GameQuiz-InputKeyBoard/media/correct.ogg
Normal file
BIN
GameQuiz-InputKeyBoard/media/error-010-206498.ogg
Normal file
BIN
GameQuiz-InputKeyBoard/media/error-04-199275.ogg
Normal file
BIN
GameQuiz-InputKeyBoard/media/error-08-206492.ogg
Normal file
BIN
GameQuiz-InputKeyBoard/media/fail.m4a
Normal file
BIN
GameQuiz-InputKeyBoard/media/fail.ogg
Normal file
BIN
GameQuiz-InputKeyBoard/media/happy-christmas-music-412753.ogg
Normal file
BIN
GameQuiz-InputKeyBoard/media/material-buy-success-394517.ogg
Normal file
BIN
GameQuiz-InputKeyBoard/media/pop-402324-1.m4a
Normal file
BIN
GameQuiz-InputKeyBoard/media/pop-402324.m4a
Normal file
BIN
GameQuiz-InputKeyBoard/media/pop-402324.ogg
Normal file
BIN
GameQuiz-InputKeyBoard/media/successed-295058.ogg
Normal file
BIN
GameQuiz-InputKeyBoard/media/wrong-answer-129254.ogg
Normal file
72
GameQuiz-InputKeyBoard/offline.js
Normal file
@@ -0,0 +1,72 @@
|
||||
{
|
||||
"version": 1768986142,
|
||||
"fileList": [
|
||||
"data.js",
|
||||
"c2runtime.js",
|
||||
"jquery-3.4.1.min.js",
|
||||
"offlineClient.js",
|
||||
"images/answers-sheet0.png",
|
||||
"images/answers-sheet1.png",
|
||||
"images/question-sheet0.png",
|
||||
"images/bg-sheet0.png",
|
||||
"images/txt_scenario.png",
|
||||
"images/wrong-sheet0.png",
|
||||
"images/replay-sheet0.png",
|
||||
"images/next-sheet0.png",
|
||||
"images/next-sheet1.png",
|
||||
"images/sound-sheet0.png",
|
||||
"images/sprite-sheet0.png",
|
||||
"images/quiz-sheet0.png",
|
||||
"images/complete-sheet0.png",
|
||||
"images/nextqs-sheet0.png",
|
||||
"images/answers2-sheet0.png",
|
||||
"images/khunganh-sheet0.png",
|
||||
"images/khunganh-sheet1.png",
|
||||
"images/dim-sheet0.png",
|
||||
"images/greenborder-sheet0.png",
|
||||
"images/button-sheet0.png",
|
||||
"images/zoom-sheet0.png",
|
||||
"images/zoom-sheet1.png",
|
||||
"images/back-sheet0.png",
|
||||
"images/bgm-sheet0.png",
|
||||
"images/bgm-sheet1.png",
|
||||
"images/submit-sheet0.png",
|
||||
"images/inputframe-sheet0.png",
|
||||
"images/correct-sheet0.png",
|
||||
"media/click.m4a",
|
||||
"media/click.ogg",
|
||||
"media/correct.m4a",
|
||||
"media/correct.ogg",
|
||||
"media/fail.m4a",
|
||||
"media/fail.ogg",
|
||||
"media/applause-383901.ogg",
|
||||
"media/correct-156911.ogg",
|
||||
"media/error-04-199275.ogg",
|
||||
"media/pop-402324-1.m4a",
|
||||
"media/pop-402324.m4a",
|
||||
"media/pop-402324.ogg",
|
||||
"media/successed-295058.ogg",
|
||||
"media/wrong-answer-129254.ogg",
|
||||
"media/alert-234711.ogg",
|
||||
"media/bubble-pop-389501.ogg",
|
||||
"media/button-124476.ogg",
|
||||
"media/christmas-background-music-436117.ogg",
|
||||
"media/christmas-happy-background-442036.ogg",
|
||||
"media/christmas-holiday-background-431002.ogg",
|
||||
"media/happy-christmas-music-412753.ogg",
|
||||
"media/collect-5930.ogg",
|
||||
"media/error-010-206498.ogg",
|
||||
"media/error-08-206492.ogg",
|
||||
"media/material-buy-success-394517.ogg",
|
||||
"media/sample_input_typing01_kofi_by_miraclei-363634.ogg",
|
||||
"media/click-234708.ogg",
|
||||
"icon-16.png",
|
||||
"icon-32.png",
|
||||
"icon-114.png",
|
||||
"icon-128.png",
|
||||
"icon-256.png",
|
||||
"loading-logo.png",
|
||||
"tdv_sdk.js",
|
||||
"bg.mp4"
|
||||
]
|
||||
}
|
||||
53
GameQuiz-InputKeyBoard/offlineClient.js
Normal file
@@ -0,0 +1,53 @@
|
||||
"use strict";
|
||||
|
||||
(function() {
|
||||
|
||||
class OfflineClient
|
||||
{
|
||||
constructor()
|
||||
{
|
||||
// Create a BroadcastChannel, if supported.
|
||||
this._broadcastChannel = (typeof BroadcastChannel === "undefined" ? null : new BroadcastChannel("offline"));
|
||||
|
||||
// Queue of messages received before a message callback is set.
|
||||
this._queuedMessages = [];
|
||||
|
||||
// The message callback.
|
||||
this._onMessageCallback = null;
|
||||
|
||||
// If BroadcastChannel is supported, listen for messages.
|
||||
if (this._broadcastChannel)
|
||||
this._broadcastChannel.onmessage = (e => this._OnBroadcastChannelMessage(e));
|
||||
}
|
||||
|
||||
_OnBroadcastChannelMessage(e)
|
||||
{
|
||||
// Have a message callback set: just forward the call.
|
||||
if (this._onMessageCallback)
|
||||
{
|
||||
this._onMessageCallback(e);
|
||||
return;
|
||||
}
|
||||
|
||||
// Otherwise the app hasn't loaded far enough to set a message callback.
|
||||
// Buffer the incoming messages to replay when the app sets a callback.
|
||||
this._queuedMessages.push(e);
|
||||
}
|
||||
|
||||
SetMessageCallback(f)
|
||||
{
|
||||
this._onMessageCallback = f;
|
||||
|
||||
// Replay any queued messages through the handler, then clear the queue.
|
||||
for (let e of this._queuedMessages)
|
||||
this._onMessageCallback(e);
|
||||
|
||||
this._queuedMessages.length = 0;
|
||||
}
|
||||
};
|
||||
|
||||
// Create the offline client ASAP so we receive and start queueing any messages the SW broadcasts.
|
||||
window.OfflineClientInfo = new OfflineClient();
|
||||
|
||||
}());
|
||||
|
||||
403
GameQuiz-InputKeyBoard/sw.js
Normal file
@@ -0,0 +1,403 @@
|
||||
"use strict";
|
||||
|
||||
const OFFLINE_DATA_FILE = "offline.js";
|
||||
const CACHE_NAME_PREFIX = "c2offline";
|
||||
const BROADCASTCHANNEL_NAME = "offline";
|
||||
const CONSOLE_PREFIX = "[SW] ";
|
||||
const LAZYLOAD_KEYNAME = "";
|
||||
|
||||
// Create a BroadcastChannel if supported.
|
||||
const broadcastChannel = (typeof BroadcastChannel === "undefined" ? null : new BroadcastChannel(BROADCASTCHANNEL_NAME));
|
||||
|
||||
//////////////////////////////////////
|
||||
// Utility methods
|
||||
function PostBroadcastMessage(o)
|
||||
{
|
||||
if (!broadcastChannel)
|
||||
return; // not supported
|
||||
|
||||
// Impose artificial (and arbitrary!) delay of 3 seconds to make sure client is listening by the time the message is sent.
|
||||
// Note we could remove the delay on some messages, but then we create a race condition where sometimes messages can arrive
|
||||
// in the wrong order (e.g. "update ready" arrives before "started downloading update"). So to keep the consistent ordering,
|
||||
// delay all messages by the same amount.
|
||||
setTimeout(() => broadcastChannel.postMessage(o), 3000);
|
||||
};
|
||||
|
||||
function Broadcast(type)
|
||||
{
|
||||
PostBroadcastMessage({
|
||||
"type": type
|
||||
});
|
||||
};
|
||||
|
||||
function BroadcastDownloadingUpdate(version)
|
||||
{
|
||||
PostBroadcastMessage({
|
||||
"type": "downloading-update",
|
||||
"version": version
|
||||
});
|
||||
}
|
||||
|
||||
function BroadcastUpdateReady(version)
|
||||
{
|
||||
PostBroadcastMessage({
|
||||
"type": "update-ready",
|
||||
"version": version
|
||||
});
|
||||
}
|
||||
|
||||
function IsUrlInLazyLoadList(url, lazyLoadList)
|
||||
{
|
||||
if (!lazyLoadList)
|
||||
return false; // presumably lazy load list failed to load
|
||||
|
||||
try {
|
||||
for (const lazyLoadRegex of lazyLoadList)
|
||||
{
|
||||
if (new RegExp(lazyLoadRegex).test(url))
|
||||
return true;
|
||||
}
|
||||
}
|
||||
catch (err)
|
||||
{
|
||||
console.error(CONSOLE_PREFIX + "Error matching in lazy-load list: ", err);
|
||||
}
|
||||
|
||||
return false;
|
||||
};
|
||||
|
||||
function WriteLazyLoadListToStorage(lazyLoadList)
|
||||
{
|
||||
if (typeof localforage === "undefined")
|
||||
return Promise.resolve(); // bypass if localforage not imported
|
||||
else
|
||||
return localforage.setItem(LAZYLOAD_KEYNAME, lazyLoadList)
|
||||
};
|
||||
|
||||
function ReadLazyLoadListFromStorage()
|
||||
{
|
||||
if (typeof localforage === "undefined")
|
||||
return Promise.resolve([]); // bypass if localforage not imported
|
||||
else
|
||||
return localforage.getItem(LAZYLOAD_KEYNAME);
|
||||
};
|
||||
|
||||
function GetCacheBaseName()
|
||||
{
|
||||
// Include the scope to avoid name collisions with any other SWs on the same origin.
|
||||
// e.g. "c2offline-https://example.com/foo/" (won't collide with anything under bar/)
|
||||
return CACHE_NAME_PREFIX + "-" + self.registration.scope;
|
||||
};
|
||||
|
||||
function GetCacheVersionName(version)
|
||||
{
|
||||
// Append the version number to the cache name.
|
||||
// e.g. "c2offline-https://example.com/foo/-v2"
|
||||
return GetCacheBaseName() + "-v" + version;
|
||||
};
|
||||
|
||||
// Return caches.keys() filtered down to just caches we're interested in (with the right base name).
|
||||
// This filters out caches from unrelated scopes.
|
||||
async function GetAvailableCacheNames()
|
||||
{
|
||||
const cacheNames = await caches.keys();
|
||||
const cacheBaseName = GetCacheBaseName();
|
||||
return cacheNames.filter(n => n.startsWith(cacheBaseName));
|
||||
};
|
||||
|
||||
// Identify if an update is pending, which is the case when we have 2 or more available caches.
|
||||
// One must be an update that is waiting, since the next navigate that does an upgrade will
|
||||
// delete all the old caches leaving just one currently-in-use cache.
|
||||
async function IsUpdatePending()
|
||||
{
|
||||
const availableCacheNames = await GetAvailableCacheNames();
|
||||
return (availableCacheNames.length >= 2);
|
||||
};
|
||||
|
||||
// Automatically deduce the main page URL (e.g. index.html or main.aspx) from the available browser windows.
|
||||
// This prevents having to hard-code an index page in the file list, implicitly caching it like AppCache did.
|
||||
async function GetMainPageUrl()
|
||||
{
|
||||
const allClients = await clients.matchAll({
|
||||
includeUncontrolled: true,
|
||||
type: "window"
|
||||
});
|
||||
|
||||
for (const c of allClients)
|
||||
{
|
||||
// Parse off the scope from the full client URL, e.g. https://example.com/index.html -> index.html
|
||||
let url = c.url;
|
||||
if (url.startsWith(self.registration.scope))
|
||||
url = url.substring(self.registration.scope.length);
|
||||
|
||||
if (url && url !== "/") // ./ is also implicitly cached so don't bother returning that
|
||||
{
|
||||
// If the URL is solely a search string, prefix it with / to ensure it caches correctly.
|
||||
// e.g. https://example.com/?foo=bar needs to cache as /?foo=bar, not just ?foo=bar.
|
||||
if (url.startsWith("?"))
|
||||
url = "/" + url;
|
||||
|
||||
return url;
|
||||
}
|
||||
}
|
||||
|
||||
return ""; // no main page URL could be identified
|
||||
};
|
||||
|
||||
// Hack to fetch optionally bypassing HTTP cache until fetch cache options are supported in Chrome (crbug.com/453190)
|
||||
function fetchWithBypass(request, bypassCache)
|
||||
{
|
||||
if (typeof request === "string")
|
||||
request = new Request(request);
|
||||
|
||||
if (bypassCache)
|
||||
{
|
||||
// bypass enabled: add a random search parameter to avoid getting a stale HTTP cache result
|
||||
const url = new URL(request.url);
|
||||
url.search += Math.floor(Math.random() * 1000000);
|
||||
|
||||
return fetch(url, {
|
||||
headers: request.headers,
|
||||
mode: request.mode,
|
||||
credentials: request.credentials,
|
||||
redirect: request.redirect,
|
||||
cache: "no-store"
|
||||
});
|
||||
}
|
||||
else
|
||||
{
|
||||
// bypass disabled: perform normal fetch which is allowed to return from HTTP cache
|
||||
return fetch(request);
|
||||
}
|
||||
};
|
||||
|
||||
// Effectively a cache.addAll() that only creates the cache on all requests being successful (as a weak attempt at making it atomic)
|
||||
// and can optionally cache-bypass with fetchWithBypass in every request
|
||||
async function CreateCacheFromFileList(cacheName, fileList, bypassCache)
|
||||
{
|
||||
// Kick off all requests and wait for them all to complete
|
||||
const responses = await Promise.all(fileList.map(url => fetchWithBypass(url, bypassCache)));
|
||||
|
||||
// Check if any request failed. If so don't move on to opening the cache.
|
||||
// This makes sure we only open a cache if all requests succeeded.
|
||||
let allOk = true;
|
||||
|
||||
for (const response of responses)
|
||||
{
|
||||
if (!response.ok)
|
||||
{
|
||||
allOk = false;
|
||||
console.error(CONSOLE_PREFIX + "Error fetching '" + response.url + "' (" + response.status + " " + response.statusText + ")");
|
||||
}
|
||||
}
|
||||
|
||||
if (!allOk)
|
||||
throw new Error("not all resources were fetched successfully");
|
||||
|
||||
// Can now assume all responses are OK. Open a cache and write all responses there.
|
||||
// TODO: ideally we can do this transactionally to ensure a complete cache is written as one atomic operation.
|
||||
// This needs either new transactional features in the spec, or at the very least a way to rename a cache
|
||||
// (so we can write to a temporary name that won't be returned by GetAvailableCacheNames() and then rename it when ready).
|
||||
const cache = await caches.open(cacheName);
|
||||
|
||||
try {
|
||||
return await Promise.all(responses.map(
|
||||
(response, i) => cache.put(fileList[i], response)
|
||||
));
|
||||
}
|
||||
catch (err)
|
||||
{
|
||||
// Not sure why cache.put() would fail (maybe if storage quota exceeded?) but in case it does,
|
||||
// clean up the cache to try to avoid leaving behind an incomplete cache.
|
||||
console.error(CONSOLE_PREFIX + "Error writing cache entries: ", err);
|
||||
caches.delete(cacheName);
|
||||
throw err;
|
||||
}
|
||||
};
|
||||
|
||||
async function UpdateCheck(isFirst)
|
||||
{
|
||||
try {
|
||||
// Always bypass cache when requesting offline.js to make sure we find out about new versions.
|
||||
const response = await fetchWithBypass(OFFLINE_DATA_FILE, true);
|
||||
|
||||
if (!response.ok)
|
||||
throw new Error(OFFLINE_DATA_FILE + " responded with " + response.status + " " + response.statusText);
|
||||
|
||||
const data = await response.json();
|
||||
|
||||
const version = data.version;
|
||||
const fileList = data.fileList;
|
||||
const lazyLoadList = data.lazyLoad;
|
||||
const currentCacheName = GetCacheVersionName(version);
|
||||
|
||||
const cacheExists = await caches.has(currentCacheName);
|
||||
|
||||
// Don't recache if there is already a cache that exists for this version. Assume it is complete.
|
||||
if (cacheExists)
|
||||
{
|
||||
// Log whether we are up-to-date or pending an update.
|
||||
const isUpdatePending = await IsUpdatePending();
|
||||
if (isUpdatePending)
|
||||
{
|
||||
console.log(CONSOLE_PREFIX + "Update pending");
|
||||
Broadcast("update-pending");
|
||||
}
|
||||
else
|
||||
{
|
||||
console.log(CONSOLE_PREFIX + "Up to date");
|
||||
Broadcast("up-to-date");
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
// Implicitly add the main page URL to the file list, e.g. "index.html", so we don't have to assume a specific name.
|
||||
const mainPageUrl = await GetMainPageUrl();
|
||||
|
||||
// Prepend the main page URL to the file list if we found one and it is not already in the list.
|
||||
// Also make sure we request the base / which should serve the main page.
|
||||
fileList.unshift("./");
|
||||
|
||||
if (mainPageUrl && fileList.indexOf(mainPageUrl) === -1)
|
||||
fileList.unshift(mainPageUrl);
|
||||
|
||||
console.log(CONSOLE_PREFIX + "Caching " + fileList.length + " files for offline use");
|
||||
|
||||
if (isFirst)
|
||||
Broadcast("downloading");
|
||||
else
|
||||
BroadcastDownloadingUpdate(version);
|
||||
|
||||
// Note we don't bypass the cache on the first update check. This is because SW installation and the following
|
||||
// update check caching will race with the normal page load requests. For any normal loading fetches that have already
|
||||
// completed or are in-flight, it is pointless and wasteful to cache-bust the request for offline caching, since that
|
||||
// forces a second network request to be issued when a response from the browser HTTP cache would be fine.
|
||||
if (lazyLoadList)
|
||||
await WriteLazyLoadListToStorage(lazyLoadList); // dump lazy load list to local storage#
|
||||
|
||||
await CreateCacheFromFileList(currentCacheName, fileList, !isFirst);
|
||||
const isUpdatePending = await IsUpdatePending();
|
||||
|
||||
if (isUpdatePending)
|
||||
{
|
||||
console.log(CONSOLE_PREFIX + "All resources saved, update ready");
|
||||
BroadcastUpdateReady(version);
|
||||
}
|
||||
else
|
||||
{
|
||||
console.log(CONSOLE_PREFIX + "All resources saved, offline support ready");
|
||||
Broadcast("offline-ready");
|
||||
}
|
||||
}
|
||||
catch (err)
|
||||
{
|
||||
// Update check fetches fail when we're offline, but in case there's any other kind of problem with it, log a warning.
|
||||
console.warn(CONSOLE_PREFIX + "Update check failed: ", err);
|
||||
}
|
||||
};
|
||||
|
||||
self.addEventListener("install", event =>
|
||||
{
|
||||
// On install kick off an update check to cache files on first use.
|
||||
// If it fails we can still complete the install event and leave the SW running, we'll just
|
||||
// retry on the next navigate.
|
||||
event.waitUntil(
|
||||
UpdateCheck(true) // first update
|
||||
.catch(() => null)
|
||||
);
|
||||
});
|
||||
|
||||
async function GetCacheNameToUse(availableCacheNames, doUpdateCheck)
|
||||
{
|
||||
// Prefer the oldest cache available. This avoids mixed-version responses by ensuring that if a new cache
|
||||
// is created and filled due to an update check while the page is running, we keep returning resources
|
||||
// from the original (oldest) cache only.
|
||||
if (availableCacheNames.length === 1 || !doUpdateCheck)
|
||||
return availableCacheNames[0];
|
||||
|
||||
// We are making a navigate request with more than one cache available. Check if we can expire any old ones.
|
||||
const allClients = await clients.matchAll();
|
||||
|
||||
// If there are other clients open, don't expire anything yet. We don't want to delete any caches they
|
||||
// might be using, which could cause mixed-version responses.
|
||||
if (allClients.length > 1)
|
||||
return availableCacheNames[0];
|
||||
|
||||
// Identify newest cache to use. Delete all the others.
|
||||
const latestCacheName = availableCacheNames[availableCacheNames.length - 1];
|
||||
console.log(CONSOLE_PREFIX + "Updating to new version");
|
||||
|
||||
await Promise.all(
|
||||
availableCacheNames.slice(0, -1)
|
||||
.map(c => caches.delete(c))
|
||||
);
|
||||
|
||||
return latestCacheName;
|
||||
};
|
||||
|
||||
async function HandleFetch(event, doUpdateCheck)
|
||||
{
|
||||
const availableCacheNames = await GetAvailableCacheNames();
|
||||
|
||||
// No caches available: go to network
|
||||
if (!availableCacheNames.length)
|
||||
return fetch(event.request);
|
||||
|
||||
const useCacheName = await GetCacheNameToUse(availableCacheNames, doUpdateCheck);
|
||||
const cache = await caches.open(useCacheName);
|
||||
const cachedResponse = await cache.match(event.request);
|
||||
|
||||
if (cachedResponse)
|
||||
return cachedResponse; // use cached response
|
||||
|
||||
// We need to check if this request is to be lazy-cached. Send the request and load the lazy-load list
|
||||
// from storage simultaneously.
|
||||
const result = await Promise.all([fetch(event.request), ReadLazyLoadListFromStorage()]);
|
||||
const fetchResponse = result[0];
|
||||
const lazyLoadList = result[1];
|
||||
|
||||
if (IsUrlInLazyLoadList(event.request.url, lazyLoadList))
|
||||
{
|
||||
// Handle failure writing to the cache. This can happen if the storage quota is exceeded, which is particularly
|
||||
// likely in Safari 11.1, which appears to have very tight storage limits. Make sure even in the event of an error
|
||||
// we continue to return the response from the fetch.
|
||||
try {
|
||||
// Note clone response since we also respond with it
|
||||
await cache.put(event.request, fetchResponse.clone());
|
||||
}
|
||||
catch (err)
|
||||
{
|
||||
console.warn(CONSOLE_PREFIX + "Error caching '" + event.request.url + "': ", err);
|
||||
}
|
||||
}
|
||||
|
||||
return fetchResponse;
|
||||
};
|
||||
|
||||
self.addEventListener("fetch", event =>
|
||||
{
|
||||
/** NOTE (iain)
|
||||
* This check is to prevent a bug with XMLHttpRequest where if its
|
||||
* proxied with "FetchEvent.prototype.respondWith" no upload progress
|
||||
* events are triggered. By returning we allow the default action to
|
||||
* occur instead. Currently all cross-origin requests fall back to default.
|
||||
*/
|
||||
if (new URL(event.request.url).origin !== location.origin)
|
||||
return;
|
||||
|
||||
// Check for an update on navigate requests
|
||||
const doUpdateCheck = (event.request.mode === "navigate");
|
||||
|
||||
const responsePromise = HandleFetch(event, doUpdateCheck);
|
||||
|
||||
if (doUpdateCheck)
|
||||
{
|
||||
// allow the main request to complete, then check for updates
|
||||
event.waitUntil(
|
||||
responsePromise
|
||||
.then(() => UpdateCheck(false)) // not first check
|
||||
);
|
||||
}
|
||||
|
||||
event.respondWith(responsePromise);
|
||||
});
|
||||
160
GameQuiz-InputKeyBoard/tdv_sdk.js
Normal file
@@ -0,0 +1,160 @@
|
||||
var tdv_sdk = {};
|
||||
|
||||
tdv_sdk.list = [
|
||||
{
|
||||
"id": "q1",
|
||||
"question": "What is this?",
|
||||
"answer": "Scissors", // Đáp án chuẩn
|
||||
"image": "https://images.senaai.vn/images/Scissors21.jpg",
|
||||
"audio": "https://audio.senaai.vn/audio/en_male_1_what_is_this.mp3",
|
||||
"text": "It is scissors."
|
||||
},
|
||||
{
|
||||
"id": "q2",
|
||||
"question": "What is this?",
|
||||
"answer": "Glue",
|
||||
"image": "https://images.senaai.vn/images/glue.jpg",
|
||||
"audio": "https://audio.senaai.vn/audio/en_male_1_what_is_this.mp3",
|
||||
"text": "It is glue."
|
||||
},
|
||||
{
|
||||
"id": "q3",
|
||||
"question": "What is this?",
|
||||
"answer": "Eraser", // Học sinh cần nhập đủ "An Eraser"
|
||||
"image": "https://images.senaai.vn/images/eraser52.jpg",
|
||||
"audio": "https://audio.senaai.vn/audio/en_male_1_what_is_this.mp3",
|
||||
"text": "It is an eraser."
|
||||
},
|
||||
{
|
||||
"id": "q4",
|
||||
"question": "What is this?",
|
||||
"answer": "Pencil Sharpener",
|
||||
"image": "https://images.senaai.vn/images/sharpener.jpg",
|
||||
"audio": "https://audio.senaai.vn/audio/en_male_1_what_is_this.mp3",
|
||||
"text": "It is a pencil sharpener."
|
||||
},
|
||||
{
|
||||
"id": "q5",
|
||||
"question": "What are these?",
|
||||
"answer": "Pencils",
|
||||
"image": "https://images.senaai.vn/images/colored_pencils18.jpg",
|
||||
"audio": "https://audio.senaai.vn/audio/en_male_1_what_are_these.mp3",
|
||||
"text": "They are colored pencils."
|
||||
}
|
||||
];
|
||||
|
||||
|
||||
tdv_sdk.currentTotal = 0;
|
||||
tdv_sdk.currentLevel = 0;
|
||||
tdv_sdk.question = {};
|
||||
|
||||
|
||||
tdv_sdk.shuffleArray = function(Array) {
|
||||
for (let i = Array.length - 1; i > 0; i--) {
|
||||
const j = Math.floor(Math.random() * (i + 1));
|
||||
[Array[i], Array[j]] = [Array[j], Array[i]];
|
||||
}
|
||||
};
|
||||
|
||||
// Bắt đầu game
|
||||
tdv_sdk.start = function() {
|
||||
tdv_sdk.currentLevel = 0;
|
||||
tdv_sdk.currentTotal = tdv_sdk.list.length;
|
||||
tdv_sdk.shuffleArray(tdv_sdk.list);
|
||||
};
|
||||
|
||||
// Lấy câu hỏi hiện tại
|
||||
tdv_sdk.getQuestions = function(){
|
||||
console.log("Current level:", tdv_sdk.currentLevel);
|
||||
// Clone dữ liệu để tránh tham chiếu sai
|
||||
var currentItem = tdv_sdk.list[tdv_sdk.currentLevel];
|
||||
|
||||
tdv_sdk.question = {
|
||||
id: currentItem.id,
|
||||
question: currentItem.question,
|
||||
answer: currentItem.answer,
|
||||
audio: currentItem.audio,
|
||||
image: currentItem.image,
|
||||
text: currentItem.text
|
||||
};
|
||||
console.log("Question Data:", tdv_sdk.question);
|
||||
};
|
||||
|
||||
// Lấy thông tin cụ thể (dùng trong Construct 2)
|
||||
tdv_sdk.getQuestionsInfo = function(attr){
|
||||
if (tdv_sdk.question && tdv_sdk.question[attr]) {
|
||||
return tdv_sdk.question[attr];
|
||||
}
|
||||
return "";
|
||||
};
|
||||
|
||||
// Phát âm thanh
|
||||
tdv_sdk.playSoundQuestion = function(rate) {
|
||||
const audioSrc = tdv_sdk.question.audio;
|
||||
if (!audioSrc) return;
|
||||
|
||||
if ((window.audio) && (!window.audio.paused)) {
|
||||
window.audio.pause();
|
||||
}
|
||||
|
||||
const audio = new Audio(audioSrc);
|
||||
audio.playbackRate = rate || 1;
|
||||
window.audio = audio;
|
||||
audio.play();
|
||||
};
|
||||
|
||||
/* =========================================
|
||||
PHẦN 4: LOGIC KIỂM TRA ĐÁP ÁN (NEW)
|
||||
========================================= */
|
||||
|
||||
// Hàm làm sạch chuỗi: Viết thường -> Xóa dấu câu -> Xóa khoảng trắng thừa
|
||||
tdv_sdk.normalizeString = function(str) {
|
||||
if (!str) return "";
|
||||
str = str.toString().toLowerCase().trim();
|
||||
// Xóa dấu chấm, phẩy, chấm than, chấm hỏi
|
||||
str = str.replace(/[.,!?]/g, "");
|
||||
// Gộp nhiều khoảng trắng thành 1 (Ví dụ: "a b" -> "a b")
|
||||
str = str.replace(/\s\s+/g, ' ');
|
||||
return str;
|
||||
};
|
||||
|
||||
// Hàm chấm điểm: Trả về 1 (Đúng) hoặc 0 (Sai)
|
||||
// Construct 2 gọi: Browser.ExecJS("tdv_sdk.checkAnswer('" & TextBox.Text & "')")
|
||||
tdv_sdk.checkAnswer = function(studentInput) {
|
||||
if (!tdv_sdk.question || !tdv_sdk.question.answer) return 0;
|
||||
|
||||
var inputClean = tdv_sdk.normalizeString(studentInput);
|
||||
var answerClean = tdv_sdk.normalizeString(tdv_sdk.question.answer);
|
||||
|
||||
console.log("Student input:", inputClean, "| Correct answer:", answerClean);
|
||||
|
||||
if (inputClean === answerClean) {
|
||||
return 1;
|
||||
} else {
|
||||
return 0;
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
|
||||
tdv_sdk.getCorrectAnswerImage = function() {
|
||||
// Logic mới: Lấy thẳng ảnh của câu hỏi hiện tại
|
||||
if (tdv_sdk.question && tdv_sdk.question.image) {
|
||||
return tdv_sdk.question.image;
|
||||
}
|
||||
return "";
|
||||
};
|
||||
|
||||
tdv_sdk.getTotalQuestion = function(){
|
||||
return tdv_sdk.currentTotal;
|
||||
};
|
||||
|
||||
tdv_sdk.nextLevel = function(){
|
||||
if (tdv_sdk.currentLevel < tdv_sdk.list.length) {
|
||||
tdv_sdk.currentLevel++;
|
||||
}
|
||||
};
|
||||
|
||||
tdv_sdk.getCurrentLevel = function(){
|
||||
return tdv_sdk.currentLevel;
|
||||
};
|
||||