// Generated by Construct 2, the HTML5 game and app creator :: http://www.scirra.com
'use strict';var ba,ca,da,K,fa,ga,ha,O,ia,ja,ma,oa,qa,P,ra,sa,R,va,wa,xa,ya,za,Aa,Ba,T,Ca,Da,Ea,Ga,Ha,Ia,Ja,Oa,Pa,Qa,Ra,Sa,Ta,Ua,U,Va,Wa,Xa,Ya,Za,$a,ab,bb,cb,db,eb,fb,gb,hb,ib,jb,kb,lb,mb,nb,pb,qb,rb,sb,tb,ub,vb,wb,xb,yb,zb,Ab,Bb,Cb,Db,Eb,Fb,Gb,Hb,Ib,Jb,Kb,Lb,Mb,Nb,Ob,Pb,Qb,Rb,Sb,Tb,Ub,Vb,V,Wb,Xb={};"function"!==typeof Object.getPrototypeOf&&(Object.getPrototypeOf="object"===typeof"test".__proto__?function(k){return k.__proto__}:function(k){return k.constructor.prototype});
(function(){function k(f,h,a,r){this.set(f,h,a,r)}function q(){this.tc=this.sc=this.vc=this.uc=this.Oc=this.Nc=this.Db=this.Cb=0}function e(f,h,a,r){f<h?a<r?(x=f<a?f:a,v=h>r?h:r):(x=f<r?f:r,v=h>a?h:a):a<r?(x=h<a?h:a,v=f>r?f:r):(x=h<r?h:r,v=f>a?f:a)}function m(){this.items=this.mc=null;this.Ue=0;y&&(this.mc=new Set);this.rf=[];this.xd=!0}function s(f){B[A++]=f}function d(){this.U=this.ci=this.y=this.vi=0}function b(f){this.gf=[];this.al=this.cl=this.dl=this.bl=0;this.zg(f)}function c(f,h){this.Bi=
f;this.Ai=h;this.cells={}}function w(f,h){this.Bi=f;this.Ai=h;this.cells={}}function n(f,h,a){var r;return S.length?(r=S.pop(),r.gj=f,r.x=h,r.y=a,r):new ba(f,h,a)}function a(f,h,a){this.gj=f;this.x=h;this.y=a;this.Da=new ca}function l(f,h,a){var r;return X.length?(r=X.pop(),r.gj=f,r.x=h,r.y=a,r):new da(f,h,a)}function p(f,h,a){this.gj=f;this.x=h;this.y=a;this.Da=[];this.Te=!0;this.Hc=new ca;this.vf=!1}function g(f,h){return f.qc-h.qc}K=function(f){window.console&&window.console.log&&window.console.log(f)};
fa=function(f){window.console&&window.console.error&&window.console.error(f)};ga=function(f){return"undefined"===typeof f};ha=function(f){return"number"===typeof f};O=function(f){return"string"===typeof f};ia=function(f){return 0<f&&0===(f-1&f)};ja=function(f){--f;for(var h=1;32>h;h<<=1)f|=f>>h;return f+1};ma=function(f){return 0>f?-f:f};oa=function(f,h){return f<h?f:h};qa=Math.PI;P=function(f){return 0<=f?f|0:(f|0)-1};ra=function(f){var h=f|0;return h===f?h:h+1};sa=function(f,h,a,r,b,u,l,c){var g,
d,B,y;f<a?(d=f,g=a):(d=a,g=f);b<l?(y=b,B=l):(y=l,B=b);if(g<y||d>B)return!1;h<r?(d=h,g=r):(d=r,g=h);u<c?(y=u,B=c):(y=c,B=u);if(g<y||d>B)return!1;g=b-f+l-a;d=u-h+c-r;f=a-f;h=r-h;b=l-b;u=c-u;c=ma(h*b-u*f);return ma(b*d-u*g)>c?!1:ma(f*d-h*g)<=c};k.prototype.set=function(f,h,a,r){this.left=f;this.top=h;this.right=a;this.bottom=r};k.prototype.Sg=function(f){this.left=f.left;this.top=f.top;this.right=f.right;this.bottom=f.bottom};k.prototype.width=function(){return this.right-this.left};k.prototype.height=
function(){return this.bottom-this.top};k.prototype.offset=function(f,h){this.left+=f;this.top+=h;this.right+=f;this.bottom+=h;return this};k.prototype.normalize=function(){var f=0;this.left>this.right&&(f=this.left,this.left=this.right,this.right=f);this.top>this.bottom&&(f=this.top,this.top=this.bottom,this.bottom=f)};k.prototype.Hb=function(f,h){return f>=this.left&&f<=this.right&&h>=this.top&&h<=this.bottom};k.prototype.ah=function(f){return this.left===f.left&&this.top===f.top&&this.right===
f.right&&this.bottom===f.bottom};R=k;q.prototype.Yh=function(f){this.Cb=f.left;this.Db=f.top;this.Nc=f.right;this.Oc=f.top;this.uc=f.right;this.vc=f.bottom;this.sc=f.left;this.tc=f.bottom};q.prototype.un=function(f,h){if(0===h)this.Yh(f);else{var a=Math.sin(h),r=Math.cos(h),b=f.left*a,u=f.top*a,l=f.right*a,a=f.bottom*a,c=f.left*r,g=f.top*r,d=f.right*r,r=f.bottom*r;this.Cb=c-u;this.Db=g+b;this.Nc=d-u;this.Oc=g+l;this.uc=d-a;this.vc=r+l;this.sc=c-a;this.tc=r+b}};q.prototype.offset=function(f,h){this.Cb+=
f;this.Db+=h;this.Nc+=f;this.Oc+=h;this.uc+=f;this.vc+=h;this.sc+=f;this.tc+=h;return this};var x=0,v=0;q.prototype.fl=function(f){e(this.Cb,this.Nc,this.uc,this.sc);f.left=x;f.right=v;e(this.Db,this.Oc,this.vc,this.tc);f.top=x;f.bottom=v};q.prototype.Hb=function(f,h){var a=this.Nc-this.Cb,r=this.Oc-this.Db,b=this.uc-this.Cb,u=this.vc-this.Db,l=f-this.Cb,c=h-this.Db,g=a*a+r*r,d=a*b+r*u,r=a*l+r*c,B=b*b+u*u,y=b*l+u*c,n=1/(g*B-d*d),a=(B*r-d*y)*n,g=(g*y-d*r)*n;if(0<=a&&0<g&&1>a+g)return!0;a=this.sc-this.Cb;
r=this.tc-this.Db;g=a*a+r*r;d=a*b+r*u;r=a*l+r*c;n=1/(g*B-d*d);a=(B*r-d*y)*n;g=(g*y-d*r)*n;return 0<=a&&0<g&&1>a+g};va=q;wa=function(f,h){for(var a in h)h.hasOwnProperty(a)&&(f[a]=h[a]);return f};xa=function(f,h){var a,r;h=P(h);if(!(0>h||h>=f.length)){a=h;for(r=f.length-1;a<r;a++)f[a]=f[a+1];f.length=r}};ya=function(f,h){f.length=h.length;var a,r;a=0;for(r=h.length;a<r;a++)f[a]=h[a]};za=function(f,h){f.push.apply(f,h)};Aa=function(f,h){var a,r;a=0;for(r=f.length;a<r;++a)if(f[a]===h)return a;return-1};
Ba=function(f,h){var a=Aa(f,h);-1!==a&&xa(f,a)};T=function(f){return f/(180/qa)};Ca=function(f){return 180/qa*f};Da=function(f){f%=360;0>f&&(f+=360);return f};Ea=function(f){f%=2*qa;0>f&&(f+=2*qa);return f};Ga=function(f){return Da(Ca(f))};Ha=function(f){return Ea(T(f))};Ia=function(f,h,a,r){return Math.atan2(r-h,a-f)};Ja=function(f,h){if(f===h)return 0;var a=Math.sin(f),r=Math.cos(f),b=Math.sin(h),u=Math.cos(h),a=a*b+r*u;return 1<=a?0:-1>=a?qa:Math.acos(a)};Oa=function(f,h,a){var r=Math.sin(f),b=
Math.cos(f),u=Math.sin(h),l=Math.cos(h);return Math.acos(r*u+b*l)>a?0<b*u-r*l?Ea(f+a):Ea(f-a):Ea(h)};Pa=function(f,h){var a=Math.sin(f),r=Math.cos(f),b=Math.sin(h),u=Math.cos(h);return 0>=r*b-a*u};Qa=function(f,h,a,r,b,u){if(0===a)return u?f:h;var l=Math.sin(a);a=Math.cos(a);f-=r;h-=b;var c=f*l;f=f*a-h*l;h=h*a+c;return u?f+r:h+b};Ra=function(f,h,a,r){f=a-f;h=r-h;return Math.sqrt(f*f+h*h)};Sa=function(f,h){return!f!==!h};Ta=function(f){for(var h in f)if(f.hasOwnProperty(h))return!0;return!1};Ua=function(f){for(var h in f)f.hasOwnProperty(h)&&
delete f[h]};var h=+new Date;U=function(){if("undefined"!==typeof window.performance){var f=window.performance;if("undefined"!==typeof f.now)return f.now();if("undefined"!==typeof f.webkitNow)return f.webkitNow();if("undefined"!==typeof f.mozNow)return f.mozNow();if("undefined"!==typeof f.msNow)return f.msNow()}return Date.now()-h};var f=!1,r=f=!1,u=!1;"undefined"!==typeof window&&(f=/chrome/i.test(navigator.userAgent)||/chromium/i.test(navigator.userAgent),f=!f&&/safari/i.test(navigator.userAgent),
r=/(iphone|ipod|ipad)/i.test(navigator.userAgent),u=window.c2ejecta);var y=!f&&!u&&!r&&"undefined"!==typeof Set&&"undefined"!==typeof Set.prototype.forEach;m.prototype.contains=function(f){return this.$c()?!1:y?this.mc.has(f):this.items&&this.items.hasOwnProperty(f)};m.prototype.add=function(f){if(y)this.mc.has(f)||(this.mc.add(f),this.xd=!1);else{var h=f.toString(),a=this.items;a?a.hasOwnProperty(h)||(a[h]=f,this.Ue++,this.xd=!1):(this.items={},this.items[h]=f,this.Ue=1,this.xd=!1)}};m.prototype.remove=
function(f){if(!this.$c())if(y)this.mc.has(f)&&(this.mc["delete"](f),this.xd=!1);else if(this.items){f=f.toString();var h=this.items;h.hasOwnProperty(f)&&(delete h[f],this.Ue--,this.xd=!1)}};m.prototype.clear=function(){this.$c()||(y?this.mc.clear():(this.items=null,this.Ue=0),this.rf.length=0,this.xd=!0)};m.prototype.$c=function(){return 0===this.count()};m.prototype.count=function(){return y?this.mc.size:this.Ue};var B=null,A=0;m.prototype.ns=function(){if(!this.xd){if(y)this.rf.length=this.mc.size,
B=this.rf,A=0,this.mc.forEach(s),B=null,A=0;else{var f=this.rf;f.length=this.Ue;var h,a=0,r=this.items;if(r)for(h in r)r.hasOwnProperty(h)&&(f[a++]=r[h])}this.xd=!0}};m.prototype.Sd=function(){this.ns();return this.rf};ca=m;new ca;Va=function(f,h){y?Wa(f,h.mc):Xa(f,h.Sd())};Wa=function(f,h){var a,r,b,u;r=a=0;for(b=f.length;a<b;++a)u=f[a],h.has(u)||(f[r++]=u);f.length=r};Xa=function(f,h){var a,r,b,u;r=a=0;for(b=f.length;a<b;++a)u=f[a],-1===Aa(h,u)&&(f[r++]=u);f.length=r};d.prototype.add=function(f){this.y=
f-this.vi;this.ci=this.U+this.y;this.vi=this.ci-this.U-this.y;this.U=this.ci};d.prototype.reset=function(){this.U=this.ci=this.y=this.vi=0};Ya=d;Za=function(f){return f.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")};b.prototype.zg=function(f){this.dn=f;this.Sh=f.length/2;this.gf.length=f.length;this.wi=this.xi=-1;this.il=0};b.prototype.dr=function(){return!this.dn.length};b.prototype.Ta=function(){for(var f=this.gf,h=f[0],a=h,r=f[1],b=r,u,l,c=1,g=this.Sh;c<g;++c)l=2*c,u=f[l],l=f[l+1],u<h&&(h=u),u>a&&
(a=u),l<r&&(r=l),l>b&&(b=l);this.bl=h;this.cl=a;this.dl=r;this.al=b};b.prototype.Yh=function(f,h,a){this.gf.length=8;this.Sh=4;var r=this.gf;r[0]=f.left-h;r[1]=f.top-a;r[2]=f.right-h;r[3]=f.top-a;r[4]=f.right-h;r[5]=f.bottom-a;r[6]=f.left-h;r[7]=f.bottom-a;this.xi=f.right-f.left;this.wi=f.bottom-f.top;this.Ta()};b.prototype.fp=function(f,h,a){if(this.xi!==f||this.wi!==h||this.il!==a){this.xi=f;this.wi=h;this.il=a;var r,b,u,l,c,g=0,d=1,B=this.dn,y=this.gf;0!==a&&(g=Math.sin(a),d=Math.cos(a));a=0;for(u=
this.Sh;a<u;a++)r=2*a,b=r+1,l=B[r]*f,c=B[b]*h,y[r]=l*d-c*g,y[b]=c*d+l*g;this.Ta()}};b.prototype.Hb=function(f,h){var a=this.gf;if(f===a[0]&&h===a[1])return!0;var r,b,u,l=this.Sh,c=this.bl-110,g=this.dl-101,d=this.cl+131,B=this.al+120,y,n,A=0,p=0;for(r=0;r<l;r++)b=2*r,u=(r+1)%l*2,y=a[b],b=a[b+1],n=a[u],u=a[u+1],sa(c,g,f,h,y,b,n,u)&&A++,sa(d,B,f,h,y,b,n,u)&&p++;return 1===A%2||1===p%2};$a=b;c.prototype.Dd=function(f,h,a){var r;r=this.cells[f];return r?(r=r[h])?r:a?(r=n(this,f,h),this.cells[f][h]=r):
null:a?(r=n(this,f,h),this.cells[f]={},this.cells[f][h]=r):null};c.prototype.tb=function(f){return P(f/this.Bi)};c.prototype.ub=function(f){return P(f/this.Ai)};c.prototype.update=function(f,h,a){var r,b,u,l,c;if(h)for(r=h.left,b=h.right;r<=b;++r)for(u=h.top,l=h.bottom;u<=l;++u)if(!a||!a.Hb(r,u))if(c=this.Dd(r,u,!1))c.remove(f),c.$c()&&(c.Da.clear(),1E3>S.length&&S.push(c),this.cells[r][u]=null);if(a)for(r=a.left,b=a.right;r<=b;++r)for(u=a.top,l=a.bottom;u<=l;++u)h&&h.Hb(r,u)||this.Dd(r,u,!0).pj(f)};
c.prototype.gn=function(f,h){var a,r,b,u,l,c;a=this.tb(f.left);b=this.ub(f.top);r=this.tb(f.right);for(l=this.ub(f.bottom);a<=r;++a)for(u=b;u<=l;++u)(c=this.Dd(a,u,!1))&&c.dump(h)};ab=c;w.prototype.Dd=function(f,h,a){var r;r=this.cells[f];return r?(r=r[h])?r:a?(r=l(this,f,h),this.cells[f][h]=r):null:a?(r=l(this,f,h),this.cells[f]={},this.cells[f][h]=r):null};w.prototype.tb=function(f){return P(f/this.Bi)};w.prototype.ub=function(f){return P(f/this.Ai)};w.prototype.update=function(f,h,a){var r,b,u,
l,c;if(h)for(r=h.left,b=h.right;r<=b;++r)for(u=h.top,l=h.bottom;u<=l;++u)if(!a||!a.Hb(r,u))if(c=this.Dd(r,u,!1))c.remove(f),c.$c()&&(c.reset(),1E3>X.length&&X.push(c),this.cells[r][u]=null);if(a)for(r=a.left,b=a.right;r<=b;++r)for(u=a.top,l=a.bottom;u<=l;++u)h&&h.Hb(r,u)||this.Dd(r,u,!0).pj(f)};w.prototype.gn=function(f,h,a,r,b){var u,l;f=this.tb(f);h=this.ub(h);a=this.tb(a);for(u=this.ub(r);f<=a;++f)for(r=h;r<=u;++r)(l=this.Dd(f,r,!1))&&l.dump(b)};w.prototype.kr=function(f){var h,a,r,b,u;h=f.left;
r=f.top;a=f.right;for(b=f.bottom;h<=a;++h)for(f=r;f<=b;++f)if(u=this.Dd(h,f,!1))u.Te=!1};bb=w;var S=[];a.prototype.$c=function(){return this.Da.$c()};a.prototype.pj=function(f){this.Da.add(f)};a.prototype.remove=function(f){this.Da.remove(f)};a.prototype.dump=function(f){za(f,this.Da.Sd())};ba=a;var X=[];p.prototype.$c=function(){if(!this.Da.length)return!0;if(this.Da.length>this.Hc.count())return!1;this.Ti();return!0};p.prototype.pj=function(f){this.Hc.contains(f)?(this.Hc.remove(f),this.Hc.$c()&&
(this.vf=!1)):this.Da.length?(this.Da[this.Da.length-1].Bc()>f.Bc()&&(this.Te=!1),this.Da.push(f)):(this.Da.push(f),this.Te=!0)};p.prototype.remove=function(f){this.Hc.add(f);this.vf=!0;30<=this.Hc.count()&&this.Ti()};p.prototype.Ti=function(){this.vf&&(this.Hc.count()===this.Da.length?this.reset():(Va(this.Da,this.Hc),this.Hc.clear(),this.vf=!1))};p.prototype.Jp=function(){this.Te||(this.Da.sort(g),this.Te=!0)};p.prototype.reset=function(){this.Da.length=0;this.Te=!0;this.Hc.clear();this.vf=!1};
p.prototype.dump=function(f){this.Ti();this.Jp();this.Da.length&&f.push(this.Da)};da=p;var z="lighter xor copy destination-over source-in destination-in source-out destination-out source-atop destination-atop".split(" ");cb=function(f){return 0>=f||11<=f?"source-over":z[f-1]};db=function(f,h,a){if(a)switch(f.Sa=a.ONE,f.Qa=a.ONE_MINUS_SRC_ALPHA,h){case 1:f.Sa=a.ONE;f.Qa=a.ONE;break;case 3:f.Sa=a.ONE;f.Qa=a.ZERO;break;case 4:f.Sa=a.ONE_MINUS_DST_ALPHA;f.Qa=a.ONE;break;case 5:f.Sa=a.DST_ALPHA;f.Qa=a.ZERO;
break;case 6:f.Sa=a.ZERO;f.Qa=a.SRC_ALPHA;break;case 7:f.Sa=a.ONE_MINUS_DST_ALPHA;f.Qa=a.ZERO;break;case 8:f.Sa=a.ZERO;f.Qa=a.ONE_MINUS_SRC_ALPHA;break;case 9:f.Sa=a.DST_ALPHA;f.Qa=a.ONE_MINUS_SRC_ALPHA;break;case 10:f.Sa=a.ONE_MINUS_DST_ALPHA,f.Qa=a.SRC_ALPHA}};eb=function(f){return Math.round(1E6*f)/1E6};fb=function(f,h){return"string"!==typeof f||"string"!==typeof h||f.length!==h.length?!1:f===h?!0:f.toLowerCase()===h.toLowerCase()};gb=function(f){f=f.target;return!f||f===document||f===window||
document&&document.body&&f===document.body||fb(f.tagName,"canvas")?!0:!1}})();var Yb="undefined"!==typeof Float32Array?Float32Array:Array;function Zb(k){var q=new Yb(3);k&&(q[0]=k[0],q[1]=k[1],q[2]=k[2]);return q}function $b(k){var q=new Yb(16);k&&(q[0]=k[0],q[1]=k[1],q[2]=k[2],q[3]=k[3],q[4]=k[4],q[5]=k[5],q[6]=k[6],q[7]=k[7],q[8]=k[8],q[9]=k[9],q[10]=k[10],q[11]=k[11],q[12]=k[12],q[13]=k[13],q[14]=k[14],q[15]=k[15]);return q}
function ac(k,q){q[0]=k[0];q[1]=k[1];q[2]=k[2];q[3]=k[3];q[4]=k[4];q[5]=k[5];q[6]=k[6];q[7]=k[7];q[8]=k[8];q[9]=k[9];q[10]=k[10];q[11]=k[11];q[12]=k[12];q[13]=k[13];q[14]=k[14];q[15]=k[15]}function bc(k,q){var e=q[0],m=q[1];q=q[2];k[0]*=e;k[1]*=e;k[2]*=e;k[3]*=e;k[4]*=m;k[5]*=m;k[6]*=m;k[7]*=m;k[8]*=q;k[9]*=q;k[10]*=q;k[11]*=q}
function cc(k,q,e,m){m||(m=$b());var s,d,b,c,w,n,a,l,p=k[0],g=k[1];k=k[2];d=e[0];b=e[1];s=e[2];e=q[1];n=q[2];p===q[0]&&g===e&&k===n?(k=m,k[0]=1,k[1]=0,k[2]=0,k[3]=0,k[4]=0,k[5]=1,k[6]=0,k[7]=0,k[8]=0,k[9]=0,k[10]=1,k[11]=0,k[12]=0,k[13]=0,k[14]=0,k[15]=1):(e=p-q[0],n=g-q[1],a=k-q[2],l=1/Math.sqrt(e*e+n*n+a*a),e*=l,n*=l,a*=l,q=b*a-s*n,s=s*e-d*a,d=d*n-b*e,(l=Math.sqrt(q*q+s*s+d*d))?(l=1/l,q*=l,s*=l,d*=l):d=s=q=0,b=n*d-a*s,c=a*q-e*d,w=e*s-n*q,(l=Math.sqrt(b*b+c*c+w*w))?(l=1/l,b*=l,c*=l,w*=l):w=c=b=0,
m[0]=q,m[1]=b,m[2]=e,m[3]=0,m[4]=s,m[5]=c,m[6]=n,m[7]=0,m[8]=d,m[9]=w,m[10]=a,m[11]=0,m[12]=-(q*p+s*g+d*k),m[13]=-(b*p+c*g+w*k),m[14]=-(e*p+n*g+a*k),m[15]=1)}
(function(){function k(d){this.ne=/msie/i.test(navigator.userAgent)||/trident/i.test(navigator.userAgent);this.height=this.width=0;this.jl=Zb([0,0,100]);this.jm=Zb([0,0,0]);this.Qn=Zb([0,1,0]);this.Gk=Zb([1,1,1]);this.sl=!0;this.Hj=$b();this.Tb=$b();this.$l=$b();this.Ii=$b();this.i=d;this.Ol()}function q(d,b,c){this.i=d;this.Ag=b;this.name=c;this.Sb=d.getAttribLocation(b,"aPos");this.Id=d.getAttribLocation(b,"aTex");this.hm=d.getUniformLocation(b,"matP");this.Fh=d.getUniformLocation(b,"matMV");this.Ye=
d.getUniformLocation(b,"opacity");this.im=d.getUniformLocation(b,"samplerFront");this.fg=d.getUniformLocation(b,"samplerBack");this.ve=d.getUniformLocation(b,"destStart");this.ue=d.getUniformLocation(b,"destEnd");this.Ej=d.getUniformLocation(b,"seconds");this.Dj=d.getUniformLocation(b,"pixelWidth");this.Cj=d.getUniformLocation(b,"pixelHeight");this.eg=d.getUniformLocation(b,"layerScale");this.dg=d.getUniformLocation(b,"layerAngle");this.hg=d.getUniformLocation(b,"viewOrigin");this.gg=d.getUniformLocation(b,
"scrollPos");this.Rq=!!(this.Dj||this.Cj||this.Ej||this.fg||this.ve||this.ue||this.eg||this.dg||this.hg||this.gg);this.rm=this.tm=-999;this.Hh=1;this.nm=this.mm=0;this.pm=this.lm=this.km=1;this.vm=this.um=this.xm=this.wm=this.om=0;this.zj=[];this.qm=$b();this.Ye&&d.uniform1f(this.Ye,1);this.im&&d.uniform1i(this.im,0);this.fg&&d.uniform1i(this.fg,1);this.ve&&d.uniform2f(this.ve,0,0);this.ue&&d.uniform2f(this.ue,1,1);this.eg&&d.uniform1f(this.eg,1);this.dg&&d.uniform1f(this.dg,0);this.hg&&d.uniform2f(this.hg,
0,0);this.gg&&d.uniform2f(this.gg,0,0);this.ie=!1}function e(d,b){this.type=d;this.q=b;this.i=b.i;this.Cc=this.Wb=this.Pm=0;this.P=this.oc=null;this.vn=[]}k.prototype.Ol=function(){var d=this.i,b;this.am=1;this.re=this.qe=null;this.Wg=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.DEPTH_TEST);this.cm=d.ONE;this.Zl=d.ONE_MINUS_SRC_ALPHA;this.Wj=d.createBuffer();d.bindBuffer(d.ARRAY_BUFFER,this.Wj);this.Kg=
Array(4);this.Fg=Array(4);for(b=0;4>b;b++)this.Kg[b]=d.createBuffer(),d.bindBuffer(d.ARRAY_BUFFER,this.Kg[b]),this.Fg[b]=d.createBuffer(),d.bindBuffer(d.ARRAY_BUFFER,this.Fg[b]);this.Tc=0;this.Uq=d.createBuffer();d.bindBuffer(d.ELEMENT_ARRAY_BUFFER,this.Uq);this.Dk=new Float32Array(16E3);this.qk=new Float32Array(16E3);this.Br=new Float32Array(32E3);for(var c=new Uint16Array(12E3),e=b=0;12E3>b;)c[b++]=e,c[b++]=e+1,c[b++]=e+2,c[b++]=e,c[b++]=e+2,c[b++]=e+3,e+=4;d.bufferData(d.ELEMENT_ARRAY_BUFFER,c,
d.STATIC_DRAW);this.Xj=this.Pc=0;this.za=[];b=this.Hi({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}"},"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}","<default>");
this.za.push(b);b=this.Hi({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.za.push(b);for(var n in dc)dc.hasOwnProperty(n)&&this.za.push(this.Hi(dc[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}",n));d.activeTexture(d.TEXTURE0);d.bindTexture(d.TEXTURE_2D,null);this.wd=[];this.Sc=0;this.kb=!1;this.ol=this.Yf=-1;this.Ef=null;this.jq=d.createFramebuffer();this.jn=null;this.Qd=Zb([0,0,0]);this.ym=d.getParameter(d.ALIASED_POINT_SIZE_RANGE)[1];2048<this.ym&&
(this.ym=2048);this.Kc(0)};q.prototype.zk=function(d){var b=this.qm;if(b[0]!==d[0]||b[1]!==d[1]||b[2]!==d[2]||b[3]!==d[3]||b[4]!==d[4]||b[5]!==d[5]||b[6]!==d[6]||b[7]!==d[7]||b[8]!==d[8]||b[9]!==d[9]||b[10]!==d[10]||b[11]!==d[11]||b[12]!==d[12]||b[13]!==d[13]||b[14]!==d[14]||b[15]!==d[15])ac(d,this.qm),this.i.uniformMatrix4fv(this.Fh,!1,d)};k.prototype.Hi=function(d,b,c){var e=this.i,n=e.createShader(e.FRAGMENT_SHADER);e.shaderSource(n,d.src);e.compileShader(n);if(!e.getShaderParameter(n,e.COMPILE_STATUS))return e.deleteShader(n),
null;var a=e.createShader(e.VERTEX_SHADER);e.shaderSource(a,b);e.compileShader(a);if(!e.getShaderParameter(a,e.COMPILE_STATUS))return e.deleteShader(n),e.deleteShader(a),null;b=e.createProgram();e.attachShader(b,n);e.attachShader(b,a);e.linkProgram(b);if(!e.getProgramParameter(b,e.LINK_STATUS))return e.deleteShader(n),e.deleteShader(a),e.deleteProgram(b),null;e.useProgram(b);e.deleteShader(n);e.deleteShader(a);c=new q(e,b,c);c.Pi=d.Pi||0;c.Qi=d.Qi||0;c.nl=!!d.nl;c.Xk=!!d.Xk;c.F=d.F||[];d=0;for(n=
c.F.length;d<n;d++)c.F[d][1]=e.getUniformLocation(b,c.F[d][0]),c.zj.push(0),e.uniform1f(c.F[d][1],0);return c};k.prototype.dj=function(d){var b,c;b=0;for(c=this.za.length;b<c;b++)if(this.za[b].name===d)return b;return-1};k.prototype.cn=function(d,b,c){var e=this.Tb,n=this.Hj,a=[0,0,0,0,0,0,0,0];a[0]=e[0]*d+e[4]*b+e[12];a[1]=e[1]*d+e[5]*b+e[13];a[2]=e[2]*d+e[6]*b+e[14];a[3]=e[3]*d+e[7]*b+e[15];a[4]=n[0]*a[0]+n[4]*a[1]+n[8]*a[2]+n[12]*a[3];a[5]=n[1]*a[0]+n[5]*a[1]+n[9]*a[2]+n[13]*a[3];a[6]=n[2]*a[0]+
n[6]*a[1]+n[10]*a[2]+n[14]*a[3];a[7]=-a[2];0!==a[7]&&(a[7]=1/a[7],a[4]*=a[7],a[5]*=a[7],a[6]*=a[7],c[0]=(.5*a[4]+.5)*this.width,c[1]=(.5*a[5]+.5)*this.height)};k.prototype.lf=function(d,b,c){if(this.width!==d||this.height!==b||c){this.de();this.width=d;this.height=b;this.i.viewport(0,0,d,b);b=d/b;var e=this.Hj,n;n=1*Math.tan(45*Math.PI/360);b*=n;d=-b;c=-n;e||(e=$b());var a=b-d,l=n-c;e[0]=2/a;e[1]=0;e[2]=0;e[3]=0;e[4]=0;e[5]=2/l;e[6]=0;e[7]=0;e[8]=(b+d)/a;e[9]=(n+c)/l;e[10]=-1001/999;e[11]=-1;e[12]=
0;e[13]=0;e[14]=-2E3/999;e[15]=0;cc(this.jl,this.jm,this.Qn,this.Tb);d=[0,0];b=[0,0];this.cn(0,0,d);this.cn(1,1,b);this.Gk[0]=1/(b[0]-d[0]);this.Gk[1]=-1/(b[1]-d[1]);d=0;for(b=this.za.length;d<b;d++)c=this.za[d],c.ie=!1,c.hm&&(this.i.useProgram(c.Ag),this.i.uniformMatrix4fv(c.hm,!1,this.Hj));this.i.useProgram(this.za[this.Yf].Ag);this.i.bindTexture(this.i.TEXTURE_2D,null);this.i.activeTexture(this.i.TEXTURE1);this.i.bindTexture(this.i.TEXTURE_2D,null);this.i.activeTexture(this.i.TEXTURE0);this.re=
this.qe=null}};k.prototype.Ld=function(){cc(this.jl,this.jm,this.Qn,this.Tb);bc(this.Tb,this.Gk)};k.prototype.translate=function(d,b){if(0!==d||0!==b){this.Qd[0]=d;this.Qd[1]=b;this.Qd[2]=0;var c=this.Tb,e=this.Qd,n=e[0],a=e[1],e=e[2];c[12]=c[0]*n+c[4]*a+c[8]*e+c[12];c[13]=c[1]*n+c[5]*a+c[9]*e+c[13];c[14]=c[2]*n+c[6]*a+c[10]*e+c[14];c[15]=c[3]*n+c[7]*a+c[11]*e+c[15]}};k.prototype.scale=function(d,b){if(1!==d||1!==b)this.Qd[0]=d,this.Qd[1]=b,this.Qd[2]=1,bc(this.Tb,this.Qd)};k.prototype.kn=function(d){if(0!==
d){var b=this.Tb,c,e=Math.sin(d);d=Math.cos(d);var n=b[0],a=b[1],l=b[2],p=b[3],g=b[4],x=b[5],v=b[6],h=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]=n*d+g*e;c[1]=a*d+x*e;c[2]=l*d+v*e;c[3]=p*d+h*e;c[4]=n*-e+g*d;c[5]=a*-e+x*d;c[6]=l*-e+v*d;c[7]=p*-e+h*d}};k.prototype.Rd=function(){for(var d=!1,b=0;16>b;b++)if(this.$l[b]!==this.Tb[b]){d=!0;break}d&&(d=this.lc(),d.type=5,d.P?ac(this.Tb,d.P):d.P=$b(this.Tb),ac(this.Tb,this.$l),this.kb=
!1)};e.prototype.zp=function(){this.i.bindTexture(this.i.TEXTURE_2D,this.oc)};e.prototype.Ap=function(){var d=this.i;d.activeTexture(d.TEXTURE1);d.bindTexture(d.TEXTURE_2D,this.oc);d.activeTexture(d.TEXTURE0)};e.prototype.wp=function(){var d=this.Pm,b=this.q;b.Wg=d;b=b.Ef;b.Ye&&b.Hh!==d&&(b.Hh=d,this.i.uniform1f(b.Ye,d))};e.prototype.tp=function(){this.i.drawElements(this.i.TRIANGLES,this.Cc,this.i.UNSIGNED_SHORT,2*this.Wb)};e.prototype.vp=function(){this.i.blendFunc(this.Wb,this.Cc)};e.prototype.Bp=
function(){var d,b,c,e=this.q.za,n=this.q.ol;d=0;for(b=e.length;d<b;d++)c=e[d],d===n&&c.Fh?(c.zk(this.P),c.ie=!0):c.ie=!1;ac(this.P,this.q.Ii)};e.prototype.up=function(){var d=this.i,b=this.q;this.oc?(b.re===this.oc&&(d.activeTexture(d.TEXTURE1),d.bindTexture(d.TEXTURE_2D,null),b.re=null,d.activeTexture(d.TEXTURE0)),d.bindFramebuffer(d.FRAMEBUFFER,b.jq),d.framebufferTexture2D(d.FRAMEBUFFER,d.COLOR_ATTACHMENT0,d.TEXTURE_2D,this.oc,0)):(d.framebufferTexture2D(d.FRAMEBUFFER,d.COLOR_ATTACHMENT0,d.TEXTURE_2D,
null,0),d.bindFramebuffer(d.FRAMEBUFFER,null))};e.prototype.rp=function(){var d=this.i;0===this.Wb?(d.clearColor(this.P[0],this.P[1],this.P[2],this.P[3]),d.clear(d.COLOR_BUFFER_BIT)):(d.enable(d.SCISSOR_TEST),d.scissor(this.P[0],this.P[1],this.P[2],this.P[3]),d.clearColor(0,0,0,0),d.clear(this.i.COLOR_BUFFER_BIT),d.disable(d.SCISSOR_TEST))};e.prototype.sp=function(){var d=this.i,b=this.q,c=b.za[1];d.useProgram(c.Ag);!c.ie&&c.Fh&&(c.zk(b.Ii),c.ie=!0);d.enableVertexAttribArray(c.Sb);d.bindBuffer(d.ARRAY_BUFFER,
b.Wj);d.vertexAttribPointer(c.Sb,4,d.FLOAT,!1,0,0);d.drawArrays(d.POINTS,this.Wb/4,this.Cc);c=b.Ef;d.useProgram(c.Ag);0<=c.Sb&&(d.enableVertexAttribArray(c.Sb),d.bindBuffer(d.ARRAY_BUFFER,b.Kg[b.Tc]),d.vertexAttribPointer(c.Sb,2,d.FLOAT,!1,0,0));0<=c.Id&&(d.enableVertexAttribArray(c.Id),d.bindBuffer(d.ARRAY_BUFFER,b.Fg[b.Tc]),d.vertexAttribPointer(c.Id,2,d.FLOAT,!1,0,0))};e.prototype.xp=function(){var d=this.i,b=this.q,c=b.za[this.Wb];b.ol=this.Wb;b.Ef=c;d.useProgram(c.Ag);!c.ie&&c.Fh&&(c.zk(b.Ii),
c.ie=!0);c.Ye&&c.Hh!==b.Wg&&(c.Hh=b.Wg,d.uniform1f(c.Ye,b.Wg));0<=c.Sb&&(d.enableVertexAttribArray(c.Sb),d.bindBuffer(d.ARRAY_BUFFER,b.Kg[b.Tc]),d.vertexAttribPointer(c.Sb,2,d.FLOAT,!1,0,0));0<=c.Id&&(d.enableVertexAttribArray(c.Id),d.bindBuffer(d.ARRAY_BUFFER,b.Fg[b.Tc]),d.vertexAttribPointer(c.Id,2,d.FLOAT,!1,0,0))};e.prototype.yp=function(){var d,b,c=this.q.Ef,e=this.i;d=this.P;c.fg&&this.q.re!==this.oc&&(e.activeTexture(e.TEXTURE1),e.bindTexture(e.TEXTURE_2D,this.oc),this.q.re=this.oc,e.activeTexture(e.TEXTURE0));
var n=d[0];c.Dj&&n!==c.tm&&(c.tm=n,e.uniform1f(c.Dj,n));n=d[1];c.Cj&&n!==c.rm&&(c.rm=n,e.uniform1f(c.Cj,n));n=d[2];b=d[3];!c.ve||n===c.mm&&b===c.nm||(c.mm=n,c.nm=b,e.uniform2f(c.ve,n,b));n=d[4];b=d[5];!c.ue||n===c.km&&b===c.lm||(c.km=n,c.lm=n,e.uniform2f(c.ue,n,b));n=d[6];c.eg&&n!==c.pm&&(c.pm=n,e.uniform1f(c.eg,n));n=d[7];c.dg&&n!==c.om&&(c.om=n,e.uniform1f(c.dg,n));n=d[8];b=d[9];!c.hg||n===c.wm&&b===c.xm||(c.wm=n,c.xm=b,e.uniform2f(c.hg,n,b));n=d[10];b=d[11];!c.gg||n===c.um&&b===c.vm||(c.um=n,c.vm=
b,e.uniform2f(c.gg,n,b));c.Ej&&e.uniform1f(c.Ej,U()/1E3);if(c.F.length)for(d=0,b=c.F.length;d<b;d++)n=this.vn[d],n!==c.zj[d]&&(c.zj[d]=n,e.uniform1f(c.F[d][1],n))};k.prototype.lc=function(){this.Sc===this.wd.length&&this.wd.push(new e(0,this));return this.wd[this.Sc++]};k.prototype.de=function(){if(0!==this.Sc&&!this.i.isContextLost()){var d=this.i;0<this.Xj&&(d.bindBuffer(d.ARRAY_BUFFER,this.Wj),d.bufferData(d.ARRAY_BUFFER,this.Br.subarray(0,this.Xj),d.STREAM_DRAW),b&&0<=b.Sb&&"<point>"===b.name&&
d.vertexAttribPointer(b.Sb,4,d.FLOAT,!1,0,0));if(0<this.Pc){var b=this.Ef;d.bindBuffer(d.ARRAY_BUFFER,this.Kg[this.Tc]);d.bufferData(d.ARRAY_BUFFER,this.Dk.subarray(0,this.Pc),d.STREAM_DRAW);b&&0<=b.Sb&&"<point>"!==b.name&&d.vertexAttribPointer(b.Sb,2,d.FLOAT,!1,0,0);d.bindBuffer(d.ARRAY_BUFFER,this.Fg[this.Tc]);d.bufferData(d.ARRAY_BUFFER,this.qk.subarray(0,this.Pc),d.STREAM_DRAW);b&&0<=b.Id&&"<point>"!==b.name&&d.vertexAttribPointer(b.Id,2,d.FLOAT,!1,0,0)}for(var c,d=0,b=this.Sc;d<b;d++)switch(c=
this.wd[d],c.type){case 1:c.tp();break;case 2:c.zp();break;case 3:c.wp();break;case 4:c.vp();break;case 5:c.Bp();break;case 6:c.up();break;case 7:c.rp();break;case 8:c.sp();break;case 9:c.xp();break;case 10:c.yp();break;case 11:c.Ap()}this.Xj=this.Pc=this.Sc=0;this.kb=!1;this.Tc++;4<=this.Tc&&(this.Tc=0)}};k.prototype.xg=function(d){if(d!==this.am){var b=this.lc();b.type=3;this.am=b.Pm=d;this.kb=!1}};k.prototype.Vb=function(d){if(d!==this.qe){var b=this.lc();b.type=2;this.qe=b.oc=d;this.kb=!1}};k.prototype.Md=
function(d,b){if(d!==this.cm||b!==this.Zl){var c=this.lc();c.type=4;c.Wb=d;c.Cc=b;this.cm=d;this.Zl=b;this.kb=!1}};k.prototype.qn=function(){this.Md(this.i.ONE,this.i.ONE_MINUS_SRC_ALPHA)};k.prototype.Th=function(d,b,c,e,n,a,l,p){15992<=this.Pc&&this.de();var g=this.Pc,x=this.Dk,v=this.qk;if(this.kb)this.wd[this.Sc-1].Cc+=6;else{var h=this.lc();h.type=1;h.Wb=g/4*3;h.Cc=6;this.kb=!0}x[g]=d;v[g++]=0;x[g]=b;v[g++]=0;x[g]=c;v[g++]=1;x[g]=e;v[g++]=0;x[g]=n;v[g++]=1;x[g]=a;v[g++]=1;x[g]=l;v[g++]=0;x[g]=
p;v[g++]=1;this.Pc=g};k.prototype.ze=function(d,b,c,e,n,a,l,p,g){15992<=this.Pc&&this.de();var x=this.Pc,v=this.Dk,h=this.qk;if(this.kb)this.wd[this.Sc-1].Cc+=6;else{var f=this.lc();f.type=1;f.Wb=x/4*3;f.Cc=6;this.kb=!0}var f=g.left,r=g.top,u=g.right;g=g.bottom;v[x]=d;h[x++]=f;v[x]=b;h[x++]=r;v[x]=c;h[x++]=u;v[x]=e;h[x++]=r;v[x]=n;h[x++]=u;v[x]=a;h[x++]=g;v[x]=l;h[x++]=f;v[x]=p;h[x++]=g;this.Pc=x};k.prototype.Kc=function(d){if(this.Yf!==d){if(!this.za[d]){if(0===this.Yf)return;d=0}var b=this.lc();
b.type=9;this.Yf=b.Wb=d;this.kb=!1}};k.prototype.sg=function(d){d=this.za[d];return!(!d.ve&&!d.ue)};k.prototype.Yj=function(d){d=this.za[d];return!!(d.ve||d.ue||d.nl)};k.prototype.Ir=function(d){d=this.za[d];return 0!==d.Pi||0!==d.Qi};k.prototype.zq=function(d){return this.za[d].Pi};k.prototype.Aq=function(d){return this.za[d].Qi};k.prototype.Bq=function(d,b){return this.za[d].F[b][2]};k.prototype.Rh=function(d){return this.za[d].Xk};k.prototype.kf=function(d,b,c,e,n,a,l,p,g,x,v,h,f,r){var u=this.za[this.Yf],
y,B;if(u.Rq||r.length){y=this.lc();y.type=10;y.P?ac(this.Tb,y.P):y.P=$b();B=y.P;B[0]=b;B[1]=c;B[2]=e;B[3]=n;B[4]=a;B[5]=l;B[6]=p;B[7]=g;B[8]=x;B[9]=v;B[10]=h;B[11]=f;y.oc=u.fg?d:null;if(r.length)for(c=y.vn,c.length=r.length,d=0,b=r.length;d<b;d++)c[d]=r[d];this.kb=!1}};k.prototype.clear=function(d,b,c,e){var n=this.lc();n.type=7;n.Wb=0;n.P||(n.P=$b());n.P[0]=d;n.P[1]=b;n.P[2]=c;n.P[3]=e;this.kb=!1};k.prototype.clearRect=function(d,b,c,e){if(!(0>c||0>e)){var n=this.lc();n.type=7;n.Wb=1;n.P||(n.P=$b());
n.P[0]=d;n.P[1]=b;n.P[2]=c;n.P[3]=e;this.kb=!1}};k.prototype.Hr=function(){this.de();this.i.flush()};var m=[],s={};k.prototype.jp=function(){m.length=0;s={}};k.prototype.gm=function(d,b,c){var e;e=!1;b=!!b;var n=d.src+","+e+","+b+(e?",undefined":""),a=null;if("undefined"!==typeof d.src&&s.hasOwnProperty(n))return a=s[n],a.Og++,a;this.de();var l=this.i,p=ia(d.width)&&ia(d.height),a=l.createTexture();l.bindTexture(l.TEXTURE_2D,a);l.pixelStorei(l.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!0);var g=l.RGBA,x=l.RGBA,
v=l.UNSIGNED_BYTE;if(c&&!this.ne)switch(c){case 1:x=g=l.RGB;break;case 2:v=l.UNSIGNED_SHORT_4_4_4_4;break;case 3:v=l.UNSIGNED_SHORT_5_5_5_1;break;case 4:x=g=l.RGB,v=l.UNSIGNED_SHORT_5_6_5}if(!p&&e){c=document.createElement("canvas");c.width=ja(d.width);c.height=ja(d.height);var h=c.getContext("2d");h.webkitImageSmoothingEnabled=b;h.mozImageSmoothingEnabled=b;h.msImageSmoothingEnabled=b;h.imageSmoothingEnabled=b;h.drawImage(d,0,0,d.width,d.height,0,0,c.width,c.height);l.texImage2D(l.TEXTURE_2D,0,g,
x,v,c)}else l.texImage2D(l.TEXTURE_2D,0,g,x,v,d);e?(l.texParameteri(l.TEXTURE_2D,l.TEXTURE_WRAP_S,l.REPEAT),l.texParameteri(l.TEXTURE_2D,l.TEXTURE_WRAP_T,l.REPEAT)):(l.texParameteri(l.TEXTURE_2D,l.TEXTURE_WRAP_S,l.CLAMP_TO_EDGE),l.texParameteri(l.TEXTURE_2D,l.TEXTURE_WRAP_T,l.CLAMP_TO_EDGE));b?(l.texParameteri(l.TEXTURE_2D,l.TEXTURE_MAG_FILTER,l.LINEAR),p&&this.sl?(l.texParameteri(l.TEXTURE_2D,l.TEXTURE_MIN_FILTER,l.LINEAR_MIPMAP_LINEAR),l.generateMipmap(l.TEXTURE_2D)):l.texParameteri(l.TEXTURE_2D,
l.TEXTURE_MIN_FILTER,l.LINEAR)):(l.texParameteri(l.TEXTURE_2D,l.TEXTURE_MAG_FILTER,l.NEAREST),l.texParameteri(l.TEXTURE_2D,l.TEXTURE_MIN_FILTER,l.NEAREST));l.bindTexture(l.TEXTURE_2D,null);this.qe=null;a.zf=d.width;a.yf=d.height;a.Og=1;a.hl=n;m.push(a);return s[n]=a};k.prototype.zd=function(d,b,c){var e;this.de();var n=this.i;this.ne&&(e=!1);var a=n.createTexture();n.bindTexture(n.TEXTURE_2D,a);n.texImage2D(n.TEXTURE_2D,0,n.RGBA,d,b,0,n.RGBA,e?n.UNSIGNED_SHORT_4_4_4_4:n.UNSIGNED_BYTE,null);n.texParameteri(n.TEXTURE_2D,
n.TEXTURE_WRAP_S,n.CLAMP_TO_EDGE);n.texParameteri(n.TEXTURE_2D,n.TEXTURE_WRAP_T,n.CLAMP_TO_EDGE);n.texParameteri(n.TEXTURE_2D,n.TEXTURE_MAG_FILTER,c?n.LINEAR:n.NEAREST);n.texParameteri(n.TEXTURE_2D,n.TEXTURE_MIN_FILTER,c?n.LINEAR:n.NEAREST);n.bindTexture(n.TEXTURE_2D,null);this.qe=null;a.zf=d;a.yf=b;m.push(a);return a};k.prototype.deleteTexture=function(d){d&&("undefined"!==typeof d.Og&&1<d.Og?d.Og--:(this.de(),d===this.qe&&(this.i.bindTexture(this.i.TEXTURE_2D,null),this.qe=null),d===this.re&&(this.i.activeTexture(this.i.TEXTURE1),
this.i.bindTexture(this.i.TEXTURE_2D,null),this.i.activeTexture(this.i.TEXTURE0),this.re=null),Ba(m,d),"undefined"!==typeof d.hl&&delete s[d.hl],this.i.deleteTexture(d)))};k.prototype.Jc=function(d){if(d!==this.jn){var b=this.lc();b.type=6;this.jn=b.oc=d;this.kb=!1}};hb=k})();
(function(){function k(){return"undefined"!==typeof jQuery?jQuery(window).width():window.innerWidth}function q(){return"undefined"!==typeof jQuery?jQuery(window).height():window.innerHeight}function e(h){if(h&&(h.getContext||h.dc)&&!h.c2runtime){h.c2runtime=this;var f=this;this.Ob=(this.Sf=/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.Ja=!!h.dc;this.Ne="undefined"!==typeof window.AppMobi||this.Ja;this.Nb=!!window.c2cocoonjs;this.hc=!!window.c2ejecta;this.Nb&&(CocoonJS.App.onSuspended.addEventListener(function(){f.setSuspended(!0)}),CocoonJS.App.onActivated.addEventListener(function(){f.setSuspended(!1)}));this.hc&&(document.addEventListener("pagehide",function(){f.setSuspended(!0)}),document.addEventListener("pageshow",
function(){f.setSuspended(!1)}),document.addEventListener("resize",function(){f.setSize(window.innerWidth,window.innerHeight)}));this.ca=this.Ja||this.Nb||this.hc;this.ne=/msie/i.test(navigator.userAgent)||/trident/i.test(navigator.userAgent)||/iemobile/i.test(navigator.userAgent)||/edge\//i.test(navigator.userAgent);this.Ul=/tizen/i.test(navigator.userAgent);this.oh=/android/i.test(navigator.userAgent)&&!this.Ul&&!this.ne;this.yj=(/iphone/i.test(navigator.userAgent)||/ipod/i.test(navigator.userAgent))&&
!this.ne;this.Yl=/ipad/i.test(navigator.userAgent);this.uh=this.yj||this.Yl||this.hc;this.er=this.yj&&/os\s6/i.test(navigator.userAgent);this.Rf=(/chrome/i.test(navigator.userAgent)||/chromium/i.test(navigator.userAgent))&&!this.ne;this.sj=/amazonwebappplatform/i.test(navigator.userAgent);this.Xq=/firefox/i.test(navigator.userAgent);this.Tl=/safari/i.test(navigator.userAgent)&&!this.Rf&&!this.ne;this.$q=/windows/i.test(navigator.userAgent);this.Gd="undefined"!==typeof window.c2nodewebkit||"undefined"!==
typeof window.c2nwjs||/nodewebkit/i.test(navigator.userAgent)||/nwjs/i.test(navigator.userAgent);this.Wl=!("undefined"===typeof window.c2isWindows8||!window.c2isWindows8);this.cr=!("undefined"===typeof window.c2isWindows8Capable||!window.c2isWindows8Capable);this.Qe=!("undefined"===typeof window.c2isWindowsPhone8||!window.c2isWindowsPhone8);this.qh=!("undefined"===typeof window.c2isWindowsPhone81||!window.c2isWindowsPhone81);this.Vl=this.Wl||this.cr||this.qh;this.Wq=!("undefined"===typeof window.c2isBlackberry10||
!window.c2isBlackberry10);this.ph=this.oh&&!this.Rf&&!this.Sf&&!this.Xq&&!this.sj&&!this.ca;this.devicePixelRatio=1;this.oe=this.Ob||this.Sf||this.Ne||this.Nb||this.oh||this.uh||this.Qe||this.qh||this.Wq||this.Ul||this.hc;this.oe||(this.oe=/(blackberry|bb10|playbook|palm|symbian|nokia|windows\s+ce|phone|mobile|tablet|kindle|silk)/i.test(navigator.userAgent));"undefined"===typeof cr_is_preview||this.Gd||"?nw"!==window.location.search&&!/nodewebkit/i.test(navigator.userAgent)&&!/nwjs/i.test(navigator.userAgent)||
(this.Gd=!0);this.canvas=h;this.kl=document.getElementById("c2canvasdiv");this.V=this.q=this.i=null;this.Wi="";this.gh=!1;this.Hm=this.Im=0;this.canvas.oncontextmenu=function(f){f.preventDefault&&f.preventDefault();return!1};this.canvas.onselectstart=function(f){f.preventDefault&&f.preventDefault();return!1};this.Ja&&(window.c2runtime=this);this.Gd&&(window.ondragover=function(f){f.preventDefault();return!1},window.ondrop=function(f){f.preventDefault();return!1},require("nw.gui").App.clearCache());
this.ph&&"undefined"!==typeof jQuery&&jQuery("canvas").parents("*").css("overflow","visible");this.width=h.width;this.height=h.height;this.H=this.width;this.G=this.height;this.Ug=this.width;this.Tg=this.height;this.$f=window.innerWidth;this.Zf=window.innerHeight;this.lq=!1;this.X=!0;this.Uf=!1;Date.now||(Date.now=function(){return+new Date});this.plugins=[];this.types={};this.j=[];this.la=[];this.Bj={};this.kc=[];this.Oi={};this.Xc=[];this.tf=[];this.hi=[];this.Yo=[];this.Zo=[];this.Zd={};this.tj=
this.Ed=!1;this.ic=0;this.vj=!1;this.xc=[];this.ad=this.Wa=this.Bh=this.kk="";this.Dg=this.zn=!1;this.Gi=this.ig=this.Bd=this.be=0;this.of=1;this.Qb=new Ya;this.Qc=new Ya;this.Kh=this.hh=this.dh=this.Gg=this.te=this.Vi=this.yh=0;this.Af=null;this.Li=[];this.Ni=[];this.bh=-1;this.Fj=[[]];this.wk=this.Gh=0;this.$j(null);this.Hf=this.Cm=this.lg=0;this.Eg=[];this.tk=this.ak=-1;this.Xf=!0;this.Xe=0;this.Tf=!1;this.bs=0;this.He=null;this.Dc=this.hj=!1;this.Gm=new ca;this.Nj=new ca;this.Oj=new ca;this.Lr=
[];new $a([]);new $a([]);this.Ge=[];this.Nf={};this.Ie={};this.Fe={};this.sf={};this.el={};this.fm=this.Ah=this.nb=this.Bb=this.em=this.zh=this.S=null;this.qf=this.xj=!1;this.Xi=[null,null];this.ge=0;this.Si="";this.dd={};this.Bg=this.We=null;this.Jh=[];this.Mr()}}function m(h){h.target.result.createObjectStore("saves",{keyPath:"slot"})}function s(h,f,a,b){var l=indexedDB.open("_C2SaveStates");l.onupgradeneeded=m;l.onerror=b;l.onsuccess=function(l){l=l.target.result;l.onerror=b;l.transaction(["saves"],
"readwrite").objectStore("saves").put({slot:h,data:f}).onsuccess=a}}function d(h,f,a){var b=indexedDB.open("_C2SaveStates");b.onupgradeneeded=m;b.onerror=a;b.onsuccess=function(b){b=b.target.result;b.onerror=a;var u=b.transaction(["saves"]).objectStore("saves").get(h);u.onsuccess=function(){u.result?f(u.result.data):f(null)}}}function b(){K("Reloading for continuous preview");window.c2cocoonjs?CocoonJS.App.reload():-1<window.location.search.indexOf("continuous")?window.location.reload(!0):window.location+=
"?continuous"}function c(h){var f,a={};for(f in h)!h.hasOwnProperty(f)||h[f]instanceof ca||h[f]&&"undefined"!==typeof h[f].At||(a[f]=h[f]);return a}e.prototype.Mr=function(){var h=this,f;f=this.Qe?new ActiveXObject("Microsoft.XMLHTTP"):new XMLHttpRequest;var a="data.js";if(this.Wl||this.Qe||this.qh)a="data.json";f.open("GET",a,!0);var b=!1;if(!this.ca&&"response"in f&&"responseType"in f)try{f.responseType="json",b="json"===f.responseType}catch(l){b=!1}if(!b&&"responseType"in f)try{f.responseType=
"text"}catch(c){}if("overrideMimeType"in f)try{f.overrideMimeType("application/json; charset=utf-8")}catch(g){}this.Qe?f.onreadystatechange=function(){4===f.readyState&&h.Dh(JSON.parse(f.responseText))}:(f.onload=function(){if(b)h.Dh(f.response);else if(h.hc){var a=f.responseText,a=a.substr(a.indexOf("{"));h.Dh(JSON.parse(a))}else h.Dh(JSON.parse(f.responseText))},f.onerror=function(f){fa("Error requesting "+a+":");fa(f)});f.send()};e.prototype.Vq=function(){var h=this,f,a,b,l,c,g,d,e,n;this.devicePixelRatio=
(this.Pe=(!this.ca||this.hc)&&this.ps&&!this.ph)?window.devicePixelRatio||window.webkitDevicePixelRatio||window.mozDevicePixelRatio||window.msDevicePixelRatio||1:1;this.Oa();a=!(!this.lq&&(!this.pi||this.Gd||this.Vl||this.Qe||this.Sf||this.Ob||this.sj));0<this.ib&&this.setSize(k(),q(),!0);try{this.Hp&&(this.Nb||this.hc||!this.ca)&&(f={alpha:a,depth:!1,antialias:!1,failIfMajorPerformanceCaveat:!0},this.i=this.canvas.getContext("webgl",f)||this.canvas.getContext("experimental-webgl",f))}catch(p){}if(this.i){this.ca||
(this.Ka=document.createElement("canvas"),jQuery(this.Ka).appendTo(this.canvas.parentNode),this.Ka.oncontextmenu=function(){return!1},this.Ka.onselectstart=function(){return!1},this.Ka.width=this.Ug,this.Ka.height=this.Tg,jQuery(this.Ka).css({width:this.Ug+"px",height:this.Tg+"px"}),this.an(),this.Vj=this.Ka.getContext("2d"));this.q=new hb(this.i,this.oe);this.q.lf(this.canvas.width,this.canvas.height);this.q.sl=0!==this.Cp;this.V=null;this.canvas.addEventListener("webglcontextlost",function(f){f.preventDefault();
h.pr();K("[Construct 2] WebGL context lost");window.cr_setSuspended(!0)},!1);this.canvas.addEventListener("webglcontextrestored",function(){h.q.Ol();h.q.lf(h.q.width,h.q.height,!0);h.Bb=null;h.nb=null;h.Xi[0]=null;h.Xi[1]=null;h.qr();h.X=!0;K("[Construct 2] WebGL context restored");window.cr_setSuspended(!1)},!1);f=0;for(a=this.j.length;f<a;f++)for(c=this.j[f],b=0,l=c.A.length;b<l;b++)d=c.A[b],d.Na=this.q.dj(d.id),this.qf=this.qf||this.q.sg(d.Na);f=0;for(a=this.kc.length;f<a;f++){e=this.kc[f];b=0;
for(l=e.A.length;b<l;b++)d=e.A[b],d.Na=this.q.dj(d.id);b=0;for(l=e.D.length;b<l;b++)for(n=e.D[b],c=0,g=n.A.length;c<g;c++)d=n.A[c],d.Na=this.q.dj(d.id),this.qf=this.qf||this.q.sg(d.Na)}}else{if(0<this.ib&&this.Ja){this.canvas=null;document.oncontextmenu=function(){return!1};document.onselectstart=function(){return!1};this.V=AppMobi.canvas.getContext("2d");try{this.V.samplingMode=this.R?"smooth":"sharp",this.V.globalScale=1,this.V.HTML5CompatibilityMode=!0,this.V.imageSmoothingEnabled=this.R}catch(x){}0!==
this.width&&0!==this.height&&(this.V.width=this.width,this.V.height=this.height)}this.V||(f=this.Nb?{antialias:!!this.R,alpha:a}:{alpha:a},this.V=this.canvas.getContext("2d",f),this.V.webkitImageSmoothingEnabled=this.R,this.V.mozImageSmoothingEnabled=this.R,this.V.msImageSmoothingEnabled=this.R,this.V.imageSmoothingEnabled=this.R);this.Vj=this.Ka=null}this.Hn=function(f){h.bb(!1,f)};window==window.top||this.ca||this.Vl||this.Qe||(document.addEventListener("mousedown",function(){window.focus()},!0),
document.addEventListener("touchstart",function(){window.focus()},!0));"undefined"!==typeof cr_is_preview&&(this.Nb&&console.log("[Construct 2] In preview-over-wifi via CocoonJS mode"),-1<window.location.search.indexOf("continuous")&&(K("Reloading for continuous preview"),this.Bh="__c2_continuouspreview",this.Dg=!0),this.yr&&!this.oe&&(jQuery(window).focus(function(){h.setSuspended(!1)}),jQuery(window).blur(function(){h.setSuspended(!0)})));this.ca||(f=function(f){if(gb(f)&&document.activeElement&&
document.activeElement!==document.getElementsByTagName("body")[0]&&document.activeElement.blur)try{document.activeElement.blur()}catch(h){}},window.navigator.pointerEnabled?document.addEventListener("pointerdown",f):window.navigator.msPointerEnabled?document.addEventListener("MSPointerDown",f):document.addEventListener("touchstart",f),document.addEventListener("mousedown",f));0===this.ib&&this.Pe&&1<this.devicePixelRatio&&this.setSize(this.wa,this.va,!0);this.Ln();this.Oq();this.go();this.ea={}};
e.prototype.setSize=function(h,f,a){var b=0,l=0,c=0,g=0,g=0,d=this.er&&this.Tl&&!navigator.standalone&&!this.ca&&!this.Ob;d&&(f+=60);if(this.$f!==h||this.Zf!==f||a){this.$f=h;this.Zf=f;var e=this.ib,n=(document.mozFullScreen||document.webkitIsFullScreen||!!document.msFullscreenElement||document.fullScreen||this.Tf)&&!this.Ob;if(n||0!==this.ib||a)n&&0<this.ge&&(e=this.ge),a=this.devicePixelRatio,4<=e?(c=this.wa/this.va,h/f>c?(c*=f,5===e?(g=c*a/this.wa,1<g?g=Math.floor(g):1>g&&(g=1/Math.ceil(1/g)),
c=this.wa*g/a,g=this.va*g/a,b=(h-c)/2,l=(f-g)/2,h=c,f=g):(b=(h-c)/2,h=c)):(g=h/c,5===e?(g=g*a/this.va,1<g?g=Math.floor(g):1>g&&(g=1/Math.ceil(1/g)),c=this.wa*g/a,g=this.va*g/a,b=(h-c)/2,l=(f-g)/2,h=c):l=(f-g)/2,f=g),n&&!this.Gd&&(l=b=0)):this.Gd&&this.Tf&&0===this.zl&&(b=Math.floor((h-this.wa)/2),l=Math.floor((f-this.va)/2),h=this.wa,f=this.va),2>e&&(this.xf=a),this.Pe&&this.Yl&&1<a&&(1024<=h&&(h=1023),1024<=f&&(f=1023)),this.Ug=Math.round(h),this.Tg=Math.round(f),this.width=Math.round(h*a),this.height=
Math.round(f*a),this.X=!0,this.Xn?(this.H=this.width,this.G=this.height,this.Mb=!0):this.width<this.wa&&this.height<this.va||1===e?(this.H=this.width,this.G=this.height,this.Mb=!0):(this.H=this.wa,this.G=this.va,this.Mb=!1,2===e?(c=this.wa/this.va,e=this.$f/this.Zf,e<c?this.H=this.G*e:e>c&&(this.G=this.H/e)):3===e&&(c=this.wa/this.va,e=this.$f/this.Zf,e>c?this.H=this.G*e:e<c&&(this.G=this.H/e))),this.kl&&!this.ca&&(jQuery(this.kl).css({width:Math.round(h)+"px",height:Math.round(f)+"px","margin-left":Math.floor(b)+
"px","margin-top":Math.floor(l)+"px"}),"undefined"!==typeof cr_is_preview&&jQuery("#borderwrap").css({width:Math.round(h)+"px",height:Math.round(f)+"px"})),this.canvas&&(this.canvas.width=Math.round(h*a),this.canvas.height=Math.round(f*a),this.hc?(this.canvas.style.left=Math.floor(b)+"px",this.canvas.style.top=Math.floor(l)+"px",this.canvas.style.width=Math.round(h)+"px",this.canvas.style.height=Math.round(f)+"px"):this.Pe&&!this.ca&&jQuery(this.canvas).css({width:Math.round(h)+"px",height:Math.round(f)+
"px"})),this.Ka&&(this.Ka.width=Math.round(h),this.Ka.height=Math.round(f),jQuery(this.Ka).css({width:Math.round(h)+"px",height:Math.round(f)+"px"})),this.q&&this.q.lf(Math.round(h*a),Math.round(f*a)),this.Ja&&this.V&&(this.V.width=Math.round(h),this.V.height=Math.round(f)),this.V&&(this.V.webkitImageSmoothingEnabled=this.R,this.V.mozImageSmoothingEnabled=this.R,this.V.msImageSmoothingEnabled=this.R,this.V.imageSmoothingEnabled=this.R),this.Ln(),this.ca||!d&&!this.yj||window.setTimeout(function(){window.scrollTo(0,
1)},100)}};e.prototype.Ln=function(){if(this.bp&&0!==this.Tj){var h="portrait";2===this.Tj&&(h="landscape");screen.orientation&&screen.orientation.lock?screen.orientation.lock(h):screen.lockOrientation?screen.lockOrientation(h):screen.webkitLockOrientation?screen.webkitLockOrientation(h):screen.mozLockOrientation?screen.mozLockOrientation(h):screen.msLockOrientation&&screen.msLockOrientation(h)}};e.prototype.pr=function(){this.q.jp();this.xj=!0;var h,f,a;h=0;for(f=this.j.length;h<f;h++)a=this.j[h],
a.Jm&&a.Jm()};e.prototype.qr=function(){this.xj=!1;var h,f,a;h=0;for(f=this.j.length;h<f;h++)a=this.j[h],a.Mm&&a.Mm()};e.prototype.an=function(){if(!this.ca){var h=(document.mozFullScreen||document.webkitIsFullScreen||document.fullScreen||document.msFullscreenElement||this.Tf)&&!this.Ob?jQuery(this.canvas).offset():jQuery(this.canvas).position();h.position="absolute";jQuery(this.Ka).css(h)}};var w=window.cancelAnimationFrame||window.mozCancelAnimationFrame||window.webkitCancelAnimationFrame||window.msCancelAnimationFrame||
window.oCancelAnimationFrame;e.prototype.setSuspended=function(h){var f;if(h&&!this.Uf)for(K("[Construct 2] Suspending"),this.Uf=!0,-1!==this.ak&&w&&w(this.ak),-1!==this.tk&&clearTimeout(this.tk),h=0,f=this.Eg.length;h<f;h++)this.Eg[h](!0);else if(!h&&this.Uf){K("[Construct 2] Resuming");this.Uf=!1;this.yh=U();this.te=U();h=this.ig=this.hh=0;for(f=this.Eg.length;h<f;h++)this.Eg[h](!1);this.bb(!1)}};e.prototype.Uk=function(h){this.Eg.push(h)};e.prototype.rd=function(h){return this.Jh[h]};e.prototype.Dh=
function(h){h&&h.project||fa("Project model unavailable");h=h.project;this.name=h[0];this.yl=h[1];this.ib=h[12];this.zl=h[12];this.wa=h[10];this.va=h[11];this.Wm=this.wa/2;this.Xm=this.va/2;this.ca&&!this.hc&&(4<=h[12]||0===h[12])&&(K("[Construct 2] Letterbox scale fullscreen modes are not supported on this platform - falling back to 'Scale outer'"),this.zl=this.ib=3);this.Ck=h[18];this.bg=h[19];0===this.bg&&(this.We=new Image,this.We.src="loading-logo.png");this.lg=h[21];this.Jh=ec();this.Lc=new Y(this);
var f,a,b,l,c,g,d,e,n;f=0;for(a=h[2].length;f<a;f++)d=h[2][f],b=this.rd(d[0]),ib(d,b.prototype),n=new b(this),n.Zh=d[1],n.Hd=d[2],n.Am=d[9],n.ua&&n.ua(),this.plugins.push(n);this.Jh=ec();f=0;for(a=h[3].length;f<a;f++){d=h[3][f];c=this.rd(d[1]);n=null;b=0;for(l=this.plugins.length;b<l;b++)if(this.plugins[b]instanceof c){n=this.plugins[b];break}var p=new n.Zb(n);p.name=d[0];p.K=d[2];p.qj=d[3].slice(0);p.rs=d[3].length;p.cp=d[4];p.nq=d[5];p.I=d[11];p.K?(p.Ih=[],p.Yc=this.Hf++,p.Z=null):(p.Ih=null,p.Yc=
-1,p.Z=[]);p.eh=null;p.Je=null;p.tl=null;p.Ab=!1;p.gb=null;d[6]?(p.En=d[6][0],p.Fn=d[6][1],p.es=d[6][2]):(p.En=null,p.Fn=0,p.es=0);p.eb=d[7]?d[7]:null;p.index=f;p.c=[];p.Yg=[];p.Od=[new jb(p)];p.Wc=0;p.Kb=null;p.pp=0;p.nf=!0;p.ii=kb;p.sq=lb;p.xq=mb;p.W=nb;p.tg=pb;p.Zj=qb;p.ff=rb;p.jh=sb;p.Yi=tb;p.$i=ub;p.ud=vb;p.Fl=wb;p.Ei=new ab(this.wa,this.va);p.Yk=!0;p.Zk=!1;p.ea={};p.toString=xb;p.la=[];b=0;for(l=d[8].length;b<l;b++){e=d[8][b];var x=this.rd(e[1]),v=null;c=0;for(g=this.la.length;c<g;c++)if(this.la[c]instanceof
x){v=this.la[c];break}v||(v=new x(this),v.Bm=[],v.Lj=new ca,v.ua&&v.ua(),this.la.push(v));-1===v.Bm.indexOf(p)&&v.Bm.push(p);c=new v.Zb(v,p);c.name=e[0];c.I=e[2];c.ua();p.la.push(c)}p.global=d[9];p.uj=d[10];p.A=[];b=0;for(l=d[12].length;b<l;b++)p.A.push({id:d[12][b][0],name:d[12][b][1],Na:-1,wb:!0,index:b});p.Mt=d[13];this.Ck&&!p.K&&!p.uj&&n.Hd||p.ua();p.name&&(this.types[p.name]=p);this.j.push(p);n.Zh&&(b=new n.cb(p),b.uid=this.lg++,b.en=this.Cm++,b.ke=0,b.Lf=yb,b.toString=zb,b.Ma=d[14],b.ua(),p.c.push(b),
this.dd[b.uid.toString()]=b)}f=0;for(a=h[4].length;f<a;f++)for(c=h[4][f],g=this.j[c[0]],b=1,l=c.length;b<l;b++)d=this.j[c[b]],d.Z.push(g),g.Ih.push(d);f=0;for(a=h[27].length;f<a;f++){c=h[27][f];g=[];b=0;for(l=c.length;b<l;b++)g.push(this.j[c[b]]);b=0;for(l=g.length;b<l;b++)g[b].Ab=!0,g[b].gb=g}if(0<this.Hf)for(f=0,a=this.j.length;f<a;f++)if(d=this.j[f],!d.K&&d.Z.length){d.eh=Array(this.Hf);d.Je=Array(this.Hf);d.tl=Array(this.Hf);p=[];b=v=x=e=0;for(l=d.Z.length;b<l;b++)for(n=d.Z[b],d.eh[n.Yc]=e,e+=
n.rs,d.Je[n.Yc]=x,x+=n.cp,d.tl[n.Yc]=v,v+=n.nq,c=0,g=n.A.length;c<g;c++)p.push(wa({},n.A[c]));d.A=p.concat(d.A);b=0;for(l=d.A.length;b<l;b++)d.A[b].index=b}f=0;for(a=h[5].length;f<a;f++)d=h[5][f],b=new Ab(this,d),this.Bj[b.name]=b,this.kc.push(b);f=0;for(a=h[6].length;f<a;f++)d=h[6][f],b=new Bb(this,d),this.Oi[b.name]=b,this.Xc.push(b);f=0;for(a=this.Xc.length;f<a;f++)this.Xc[f].ja();f=0;for(a=this.Xc.length;f<a;f++)this.Xc[f].yk();f=0;for(a=this.hi.length;f<a;f++)this.hi[f].ja();this.hi.length=0;
this.$o=h[7];this.Si=h[8];this.ef=h[9];this.xf=1;this.Hp=h[13];this.R=h[14];this.pi=h[15];this.ps=h[17];this.Tj=h[20];this.bp=0<this.Tj;this.yr=h[22];this.Mb=this.Xn=h[23];this.Cp=h[24];this.Fr=h[25];this.$h=Date.now();this.Jh.length=0;this.Vq()};var n=!1;e.prototype.ss=function(a,f){a.cocoonLazyLoad=!0;a.onerror=function(f){n=a.gl=!0;console&&console.error&&console.error("Error loading image '"+a.src+"': ",f)};this.hc?a.src=f:a.src||("undefined"!==typeof XAPKReader?XAPKReader.get(f,function(f){a.src=
f},function(b){n=a.gl=!0;console&&console.error&&console.error("Error extracting image '"+f+"' from expansion file: ",b)}):a.src=f);this.tf.push(a)};e.prototype.kq=function(a){var f,b;f=0;for(b=this.tf.length;f<b;f++)if(this.tf[f].lp===a)return this.tf[f];return null};var a=0,l=!1;e.prototype.Oq=function(){this.He&&(a=this.He.Zr(this.$o))};e.prototype.$k=function(){var h=a,f=0,b=0,c=!0,g,d,b=0;for(g=this.tf.length;b<g;b++){d=this.tf[b];var e=d.kp;if(!e||0>=e)e=5E4;h+=e;d.src&&(d.complete||d.loaded)&&
!d.gl?f+=e:c=!1}c&&this.Fr&&this.He&&(l||(this.He.cs(),l=!0),b=this.He.yq(),f+=b,b<a&&(c=!1));this.ye=0==h?0:f/h;return c};e.prototype.go=function(){if(this.V||this.q){var a=this.V||this.Vj;this.Ka&&this.an();this.ye=0;this.dm=-1;if(this.$k())this.Pq();else{var f=Date.now()-this.$h;if(a){var b=this.width,l=this.height,c=this.devicePixelRatio;this.Ka&&(b=this.Ug,l=this.Tg,c=1);if(3!==this.bg&&(this.Nb||500<=f&&this.dm!=this.ye)){a.clearRect(0,0,b,l);var f=b/2,l=l/2,b=0===this.bg&&this.We.complete,
g=40*c,d=0,e=80*c,p;b&&(e=this.We.width*c,p=this.We.height*c,g=e/2,d=p/2,a.drawImage(this.We,P(f-g),P(l-d),e,p));1>=this.bg?(f=P(f-g)+.5,l=P(l+(d+(b?12*c:0)))+.5,a.fillStyle=n?"red":"DodgerBlue",a.fillRect(f,l,Math.floor(e*this.ye),6*c),a.strokeStyle="black",a.strokeRect(f,l,e,6*c),a.strokeStyle="white",a.strokeRect(f-1*c,l-1*c,e+2*c,8*c)):2===this.bg&&(a.font=this.hc?"12pt ArialMT":"12pt Arial",a.fillStyle=n?"#f00":"#999",a.Lt="middle",c=Math.round(100*this.ye)+"%",b=a.measureText?a.measureText(c):
null,a.fillText(c,f-(b?b.width:0)/2,l))}this.dm=this.ye}setTimeout(function(f){return function(){f.go()}}(this),this.Nb?10:100)}}};e.prototype.Pq=function(){this.Ka&&(this.canvas.parentNode.removeChild(this.Ka),this.Ka=this.Vj=null);this.$h=Date.now();this.te=U();var a,f,b;if(this.Ck)for(a=0,f=this.j.length;a<f;a++)b=this.j[a],b.K||b.uj||!b.ha.Hd||b.ua();else this.Xf=!1;a=0;for(f=this.kc.length;a<f;a++)this.kc[a].mp();2<=this.ib&&(a=this.wa/this.va,f=this.width/this.height,this.xf=2!==this.ib&&f>
a||2===this.ib&&f<a?this.height/this.va:this.width/this.wa);this.yl?this.Bj[this.yl].ok():this.kc[0].ok();this.Ck||(this.Xe=1,this.trigger(Y.prototype.e.Ik,null));navigator.splashscreen&&navigator.splashscreen.hide&&navigator.splashscreen.hide();a=0;for(f=this.j.length;a<f;a++)b=this.j[a],b.or&&b.or();document.hidden||document.webkitHidden||document.mozHidden||document.msHidden?window.cr_setSuspended(!0):this.bb(!1);this.Ja&&AppMobi.webview.execute("onGameReady();")};var p=window.requestAnimationFrame||
window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||window.msRequestAnimationFrame||window.oRequestAnimationFrame;e.prototype.bb=function(a,f,b){if(this.S){var l=U();if(b||!this.Uf||a){a||(p?this.ak=p(this.Hn):this.tk=setTimeout(this.Hn,this.oe?1:16));f=f||l;var c=this.ib;((b=(document.mozFullScreen||document.webkitIsFullScreen||document.fullScreen||!!document.msFullscreenElement)&&!this.Ob)||this.Tf)&&0<this.ge&&(c=this.ge);0<c&&(!this.uh||window.self!==window.top)&&(c=window.innerHeight,
this.$f===window.innerWidth&&this.Zf===c||this.setSize(k(),q()));this.ca||(b?(this.gh||(this.Wi=jQuery(this.canvas).css("margin")||"0",this.gh=!0),this.Rf||this.Gd||jQuery(this.canvas).css({"margin-left":""+Math.floor((screen.width-this.width/this.devicePixelRatio)/2)+"px","margin-top":""+Math.floor((screen.height-this.height/this.devicePixelRatio)/2)+"px"})):this.gh?(this.Rf||this.Gd||jQuery(this.canvas).css("margin",this.Wi),this.Wi="",this.gh=!1,0===this.ib&&this.setSize(Math.round(this.Im/this.devicePixelRatio),
Math.round(this.Hm/this.devicePixelRatio),!0)):(this.Im=this.width,this.Hm=this.height));this.Xf&&(b=this.$k(),this.Xe=this.ye,b&&(this.Xf=!1,this.ye=1,this.trigger(Y.prototype.e.Ik,null)));this.jr(f);!this.X&&!this.Nb||this.xj||this.Dg||a||(this.X=!1,this.q?this.yc():this.ae(),this.Bg&&(this.canvas&&this.canvas.toDataURL&&(this.canvas.toDataURL(this.Bg[0],this.Bg[1]),this.trigger(Y.prototype.e.to,null)),this.Bg=null));this.Gt||(this.Gg++,this.dh++,this.hh++);this.ig+=U()-l}}};e.prototype.jr=function(a){var f,
b,l,c,g,d,e,p;1E3<=a-this.te&&(this.te+=1E3,1E3<=a-this.te&&(this.te=a),this.Vi=this.hh,this.hh=0,this.Gi=this.ig,this.ig=0);0!==this.yh&&(f=a-this.yh,0>f&&(f=0),this.Bd=f/1E3,.5<this.Bd?this.Bd=0:.1<this.Bd&&(this.Bd=.1));this.yh=a;this.be=this.Bd*this.of;this.Qb.add(this.be);this.Qc.add(this.Bd);a=(document.mozFullScreen||document.webkitIsFullScreen||document.fullScreen||!!document.msFullscreenElement||this.Tf)&&!this.Ob;2<=this.ib||a&&0<this.ge?(f=this.wa/this.va,b=this.width/this.height,l=this.ib,
a&&0<this.ge&&(l=this.ge),this.xf=2!==l&&b>f||2===l&&b<f?this.height/this.va:this.width/this.wa,this.S&&(this.S.nn(this.S.scrollX),this.S.pn(this.S.scrollY))):this.xf=this.Pe?this.devicePixelRatio:1;this.Oa();this.ic++;this.Lc.Pr();this.ic--;this.Oa();this.ic++;b=this.Gm.Sd();a=0;for(f=b.length;a<f;a++)b[a].It();a=0;for(f=this.j.length;a<f;a++)if(d=this.j[a],!d.K&&(d.la.length||d.Z.length))for(b=0,l=d.c.length;b<l;b++)for(e=d.c[b],c=0,g=e.C.length;c<g;c++)e.C[c].bb();a=0;for(f=this.j.length;a<f;a++)if(d=
this.j[a],!d.K&&(d.la.length||d.Z.length))for(b=0,l=d.c.length;b<l;b++)for(e=d.c[b],c=0,g=e.C.length;c<g;c++)p=e.C[c],p.Er&&p.Er();b=this.Nj.Sd();a=0;for(f=b.length;a<f;a++)b[a].bb();this.ic--;this.Qq();for(a=0;this.Af&&10>a++;)this.rl(this.Af);a=0;for(f=this.Xc.length;a<f;a++)this.Xc[a].jj=!1;this.S.ee&&this.S.ee.xa();this.Lr.length=0;this.ic++;a=0;for(f=this.j.length;a<f;a++)if(d=this.j[a],!d.K&&(d.la.length||d.Z.length))for(b=0,l=d.c.length;b<l;b++)for(e=d.c[b],c=0,g=e.C.length;c<g;c++)p=e.C[c],
p.rk&&p.rk();b=this.Oj.Sd();a=0;for(f=b.length;a<f;a++)b[a].rk();this.ic--};e.prototype.rl=function(a){var f=this.S;this.S.ds();var b,l,c,g,d,e,p;if(this.q)for(b=0,l=this.j.length;b<l;b++)d=this.j[b],d.K||!d.Pn||d.global&&0!==d.c.length||-1!==a.Qf.indexOf(d)||d.Pn();f==a&&(this.Lc.sb.length=0);a.ok();b=0;for(l=this.j.length;b<l;b++)if(d=this.j[b],d.global||d.ha.Zh)for(a=0,f=d.c.length;a<f;a++)if(e=d.c[a],e.Rj&&e.Rj(),e.C)for(c=0,g=e.C.length;c<g;c++)p=e.C[c],p.Rj&&p.Rj();this.X=!0;this.Oa()};e.prototype.sk=
function(a){this.Nj.add(a)};e.prototype.gs=function(a){this.Oj.add(a)};e.prototype.Dl=function(a){return a&&-1!==a.kg?this.Bd*a.kg:this.be};e.prototype.ae=function(){this.S.ae(this.V);this.Ja&&this.V.present()};e.prototype.yc=function(){this.S.yc(this.q);this.q.Hr()};e.prototype.Wo=function(a){a&&this.Li.push(a)};e.prototype.lh=function(a){a=a.toString();return this.dd.hasOwnProperty(a)?this.dd[a]:null};var g=[];e.prototype.Td=function(a){var f,b;f=a.type.name;var l=null;if(this.Zd.hasOwnProperty(f)){if(l=
this.Zd[f],l.contains(a))return}else l=g.length?g.pop():new ca,this.Zd[f]=l;l.add(a);this.Ed=!0;if(a.Ab)for(f=0,b=a.siblings.length;f<b;f++)this.Td(a.siblings[f]);this.tj&&l.rf.push(a);this.ic++;this.trigger(Object.getPrototypeOf(a.type.ha).e.uo,a);this.ic--};e.prototype.Oa=function(){if(this.Ed){var a,f,b,l,c,d;this.tj=!0;b=0;for(c=this.xc.length;b<c;++b)for(a=this.xc[b],f=a.type,f.c.push(a),l=0,d=f.Z.length;l<d;++l)f.Z[l].c.push(a),f.Z[l].nf=!0;this.xc.length=0;this.po();Ua(this.Zd);this.Ed=this.tj=
!1}};e.prototype.po=function(){for(var a in this.Zd)this.Zd.hasOwnProperty(a)&&this.bo(this.Zd[a])};e.prototype.bo=function(a){var f=a.Sd(),b=f[0].type,l,c,d,e,p,n;Va(b.c,a);b.nf=!0;0===b.c.length&&(b.Zk=!1);l=0;for(c=b.Z.length;l<c;++l)n=b.Z[l],Va(n.c,a),n.nf=!0;l=0;for(c=this.Lc.sb.length;l<c;++l)if(p=this.Lc.sb[l],p.qb.hasOwnProperty(b.index)&&Va(p.qb[b.index].me,a),!b.K)for(d=0,e=b.Z.length;d<e;++d)n=b.Z[d],p.qb.hasOwnProperty(n.index)&&Va(p.qb[n.index].me,a);if(p=f[0].g){if(p.pc)for(d=p.c,l=
0,c=d.length;l<c;++l)e=d[l],a.contains(e)&&(e.Ta(),p.pb.update(e,e.Za,null),e.Za.set(0,0,-1,-1));Va(p.c,a);p.yg(0)}for(l=0;l<f.length;++l)this.ao(f[l],b);a.clear();g.push(a);this.X=!0};e.prototype.ao=function(a,f){var b,l,c;b=0;for(l=this.Li.length;b<l;++b)this.Li[b](a);a.Fb&&f.Ei.update(a,a.Fb,null);(b=a.g)&&b.hf(a,!0);if(a.C)for(b=0,l=a.C.length;b<l;++b)c=a.C[b],c.Qj&&c.Qj(),c.behavior.Lj.remove(a);this.Gm.remove(a);this.Nj.remove(a);this.Oj.remove(a);a.Qj&&a.Qj();this.dd.hasOwnProperty(a.uid.toString())&&
delete this.dd[a.uid.toString()];this.Kh--;100>f.Yg.length&&f.Yg.push(a)};e.prototype.ml=function(a,f,b,l){if(a.K){var c=P(Math.random()*a.Ih.length);return this.ml(a.Ih[c],f,b,l)}return a.Kb?this.Ad(a.Kb,f,!1,b,l,!1):null};var x=[];e.prototype.Ad=function(a,f,b,l,c,d){var g,e,p,n;if(!a)return null;var v=this.j[a[1]],k=v.ha.Hd;if(this.Xf&&k&&!v.uj||k&&!this.q&&11===a[0][11])return null;var q=f;k||(f=null);var m;v.Yg.length?(m=v.Yg.pop(),m.Ic=!0,v.ha.cb.call(m,v)):(m=new v.ha.cb(v),m.Ic=!1);m.uid=
!b||d||this.dd.hasOwnProperty(a[2].toString())?this.lg++:a[2];this.dd[m.uid.toString()]=m;m.en=this.Cm++;m.ke=v.c.length;g=0;for(e=this.xc.length;g<e;++g)this.xc[g].type===v&&m.ke++;m.Lf=yb;m.toString=zb;p=a[3];if(m.Ic)Ua(m.ea);else{m.ea={};if("undefined"!==typeof cr_is_preview)for(m.Rl=[],m.Rl.length=p.length,g=0,e=p.length;g<e;g++)m.Rl[g]=p[g][1];m.ra=[];m.ra.length=p.length}g=0;for(e=p.length;g<e;g++)m.ra[g]=p[g][0];if(k){var w=a[0];m.x=ga(l)?w[0]:l;m.y=ga(c)?w[1]:c;m.z=w[2];m.width=w[3];m.height=
w[4];m.depth=w[5];m.k=w[6];m.opacity=w[7];m.lb=w[8];m.mb=w[9];m.Xa=w[10];g=w[11];!this.q&&v.A.length&&(m.Xa=g);m.Bf=cb(m.Xa);this.i&&db(m,m.Xa,this.i);if(m.Ic){g=0;for(e=w[12].length;g<e;g++)for(p=0,n=w[12][g].length;p<n;p++)m.ba[g][p]=w[12][g][p];m.Ua.set(0,0,0,0);m.Fb.set(0,0,-1,-1);m.Za.set(0,0,-1,-1);m.Ng.Yh(m.Ua);m.ti.length=0}else{m.ba=w[12].slice(0);g=0;for(e=m.ba.length;g<e;g++)m.ba[g]=w[12][g].slice(0);m.N=[];m.sd=[];m.sd.length=v.A.length;m.Ua=new R(0,0,0,0);m.Fb=new R(0,0,-1,-1);m.Za=new R(0,
0,-1,-1);m.Ng=new va;m.ti=[];m.ya=Cb;m.zt=Db;m.Hb=Eb;m.Ta=Fb;m.os=Gb;m.Nt=Hb;m.Bc=Ib}m.js=!1;m.ls=0;m.ks=0;m.hs=null;14===w.length&&(m.js=!0,m.ls=w[13][0],m.ks=w[13][1],m.hs=w[13][2]);g=0;for(e=v.A.length;g<e;g++)m.sd[g]=!0;m.nd=Jb;m.nd();m.Un=!!m.N.length;m.si=!0;m.yi=!0;v.Yk=!0;m.visible=!0;m.kg=-1;m.g=f;m.qc=f.c.length;"undefined"===typeof m.wc&&(m.wc=null);this.X=m.yd=!0}var s;g=x.length=0;for(e=v.Z.length;g<e;g++)x.push.apply(x,v.Z[g].la);x.push.apply(x,v.la);if(m.Ic)for(g=0,e=x.length;g<e;g++){var F=
x[g];s=m.C[g];s.Ic=!0;F.behavior.cb.call(s,F,m);w=a[4][g];p=0;for(n=w.length;p<n;p++)s.Ma[p]=w[p];s.ua();F.behavior.Lj.add(m)}else for(m.C=[],g=0,e=x.length;g<e;g++)F=x[g],s=new F.behavior.cb(F,m),s.Ic=!1,s.Ma=a[4][g].slice(0),s.ua(),m.C.push(s),F.behavior.Lj.add(m);w=a[5];if(m.Ic)for(g=0,e=w.length;g<e;g++)m.Ma[g]=w[g];else m.Ma=w.slice(0);this.xc.push(m);this.Ed=!0;f&&(f.wf(m,!0),1!==f.ed||1!==f.fd)&&(v.Zk=!0);this.Kh++;if(v.Ab){if(m.Ab=!0,m.Ic?m.siblings.length=0:m.siblings=[],!b&&!d){g=0;for(e=
v.gb.length;g<e;g++)if(v.gb[g]!==v){if(!v.gb[g].Kb)return null;m.siblings.push(this.Ad(v.gb[g].Kb,q,!1,k?m.x:l,k?m.y:c,!0))}g=0;for(e=m.siblings.length;g<e;g++)for(m.siblings[g].siblings.push(m),p=0;p<e;p++)g!==p&&m.siblings[g].siblings.push(m.siblings[p])}}else m.Ab=!1,m.siblings=null;m.ua();g=0;for(e=m.C.length;g<e;g++)m.C[g].Dr&&m.C[g].Dr();return m};e.prototype.bj=function(a){var f,b;f=0;for(b=this.S.D.length;f<b;f++){var l=this.S.D[f];if(fb(l.name,a))return l}return null};e.prototype.Jf=function(a){a=
P(a);0>a&&(a=0);a>=this.S.D.length&&(a=this.S.D.length-1);return this.S.D[a]};e.prototype.Di=function(a){var f,b;f=0;for(b=a.length;f<b;f++)a[f].W().Y=!0};e.prototype.tg=function(a){var f,b;f=0;for(b=a.length;f<b;f++)a[f].tg()};e.prototype.Zj=function(a){var f,b;f=0;for(b=a.length;f<b;f++)a[f].Zj()};e.prototype.ff=function(a){var f,b;f=0;for(b=a.length;f<b;f++)a[f].ff()};e.prototype.di=function(a,f,b){var l=a.W(),c,g,d,e,p,n;if(l.Y)for(l.Y=!1,c=l.c.length=0,e=a.c.length;c<e;c++)d=a.c[c],d.Ta(),p=
d.g.fb(f,b,!0),n=d.g.fb(f,b,!1),d.Hb(p,n)&&l.c.push(d);else{c=g=0;for(e=l.c.length;c<e;c++)d=l.c[c],d.Ta(),p=d.g.fb(f,b,!0),n=d.g.fb(f,b,!1),d.Hb(p,n)&&(l.c[g]=l.c[c],g++);l.c.length=g}a.ud();return l.ij()};new va;new R(0,0,0,0);e.prototype.Mn=function(a,f){if(!f)return!1;var b,l,c,g,d;b=0;for(l=a.la.length;b<l;b++)if(a.la[b].behavior instanceof f)return!0;if(!a.K)for(b=0,l=a.Z.length;b<l;b++)for(d=a.Z[b],c=0,g=d.la.length;c<g;c++)if(d.la[c].behavior instanceof f)return!0;return!1};e.prototype.Nn=
function(a){return this.Mn(a,Xb.Ss)};e.prototype.xk=function(a){return this.Mn(a,Xb.Ts)};var v=-1;e.prototype.trigger=function(a,f,b){if(!this.S)return!1;var l=this.S.ee;if(!l)return!1;var c=!1,g,d,e;v++;var p=l.Ki;d=0;for(e=p.length;d<e;++d)g=this.Jn(a,f,p[d],b),c=c||g;g=this.Jn(a,f,l,b);v--;return c||g};e.prototype.Jn=function(a,f,b,l){var c=!1,g,d,e,p;if(f)for(e=this.vk(a,f,f.type.name,b,l),c=c||e,p=f.type.Z,g=0,d=p.length;g<d;++g)e=this.vk(a,f,p[g].name,b,l),c=c||e;else e=this.vk(a,f,"system",
b,l),c=c||e;return c};e.prototype.vk=function(a,f,b,l,c){var g,d=!1,e=!1,e="undefined"!==typeof c,p=(e?l.wl:l.Kn)[b];if(!p)return d;var n=null;l=0;for(g=p.length;l<g;++l)if(p[l].method==a){n=p[l].Gf;break}if(!n)return d;a=e?n[c]:n;if(!a)return null;l=0;for(g=a.length;l<g;l++)c=a[l][0],e=a[l][1],e=this.iq(f,b,c,e),d=d||e;return d};e.prototype.iq=function(a,f,b,l){var c,g,d=!1;this.wk++;var e=this.jb().ec;e&&this.tg(e.Nd);var p=1<this.wk;this.tg(b.Nd);p&&this.Jr();var n=this.$j(b);n.ec=b;a&&(c=this.types[f].W(),
c.Y=!1,c.c.length=1,c.c[0]=a,this.types[f].ud());a=!0;if(b.parent){f=n.Dn;for(c=b.parent;c;)f.push(c),c=c.parent;f.reverse();c=0;for(g=f.length;c<g;c++)if(!f[c].Rr()){a=!1;break}}a&&(this.dh++,b.Fc?b.Qr(l):b.xa(),d=d||n.se);this.$m();p&&this.Cr();this.ff(b.Nd);e&&this.ff(e.Nd);this.Ed&&0===this.ic&&0===v&&!this.vj&&this.Oa();this.wk--;return d};e.prototype.rq=function(){var a=this.jb();return a.ec.Pa[a.Ya]};e.prototype.Jr=function(){this.Gh++;this.Gh>=this.Fj.length&&this.Fj.push([])};e.prototype.Cr=
function(){this.Gh--};e.prototype.Cl=function(){return this.Fj[this.Gh]};e.prototype.$j=function(a){this.bh++;this.bh>=this.Ni.length&&this.Ni.push(new Kb);var f=this.jb();f.reset(a);return f};e.prototype.$m=function(){this.bh--};e.prototype.jb=function(){return this.Ni[this.bh]};e.prototype.El=function(a,f){for(var b,l,c,g,d,e;f;){b=0;for(l=f.Xb.length;b<l;b++)if(e=f.Xb[b],e instanceof Lb&&fb(a,e.name))return e;f=f.parent}b=0;for(l=this.Xc.length;b<l;b++)for(d=this.Xc[b],c=0,g=d.Cd.length;c<g;c++)if(e=
d.Cd[c],e instanceof Lb&&fb(a,e.name))return e;return null};e.prototype.Gl=function(a){var f,b;f=0;for(b=this.kc.length;f<b;f++)if(this.kc[f].I===a)return this.kc[f];return null};e.prototype.mh=function(a){var f,b;f=0;for(b=this.j.length;f<b;f++)if(this.j[f].I===a)return this.j[f];return null};e.prototype.tq=function(a){var f,b;f=0;for(b=this.Ge.length;f<b;f++)if(this.Ge[f].I===a)return this.Ge[f];return null};e.prototype.Qq=function(){var a=this,f=this.kk,l=this.ad,c=this.Bh,g=!1;this.zn&&(g=!0,
f="__c2_continuouspreview",this.zn=!1);if(f.length){this.Oa();l=this.Vr();if(window.indexedDB&&!this.Nb)s(f,l,function(){K("Saved state to IndexedDB storage ("+l.length+" bytes)");a.ad=l;a.trigger(Y.prototype.e.ni,null);a.ad="";g&&b()},function(c){try{localStorage.setItem("__c2save_"+f,l),K("Saved state to WebStorage ("+l.length+" bytes)"),a.ad=l,a.trigger(Y.prototype.e.ni,null),a.ad="",g&&b()}catch(d){K("Failed to save game state: "+c+"; "+d)}});else try{localStorage.setItem("__c2save_"+f,l),K("Saved state to WebStorage ("+
l.length+" bytes)"),a.ad=l,this.trigger(Y.prototype.e.ni,null),a.ad="",g&&b()}catch(e){K("Error saving to WebStorage: "+e)}this.Wa=this.Bh=this.kk=""}c.length&&(window.indexedDB&&!this.Nb?d(c,function(f){f?(a.Wa=f,K("Loaded state from IndexedDB storage ("+a.Wa.length+" bytes)")):(a.Wa=localStorage.getItem("__c2save_"+c)||"",K("Loaded state from WebStorage ("+a.Wa.length+" bytes)"));a.Dg=!1;a.Wa.length||a.trigger(Y.prototype.e.mi,null)},function(){a.Wa=localStorage.getItem("__c2save_"+c)||"";K("Loaded state from WebStorage ("+
a.Wa.length+" bytes)");a.Dg=!1;a.Wa.length||a.trigger(Y.prototype.e.mi,null)}):(this.Wa=localStorage.getItem("__c2save_"+c)||"",K("Loaded state from WebStorage ("+this.Wa.length+" bytes)"),this.Dg=!1,a.Wa.length||a.trigger(Y.prototype.e.mi,null)),this.kk=this.Bh="");this.Wa.length&&(this.Oa(),this.hr(this.Wa),this.ad=this.Wa,this.trigger(Y.prototype.e.Ao,null),this.Wa=this.ad="")};e.prototype.Vr=function(){var a,f,b,l,g,d,e,p={c2save:!0,version:1,rt:{time:this.Qb.U,walltime:this.Qc.U,timescale:this.of,
tickcount:this.Gg,execcount:this.dh,next_uid:this.lg,running_layout:this.S.I,start_time_offset:Date.now()-this.$h},types:{},layouts:{},events:{groups:{},cnds:{},acts:{},vars:{}}};a=0;for(f=this.j.length;a<f;a++)if(g=this.j[a],!g.K&&!this.Nn(g)){d={instances:[]};Ta(g.ea)&&(d.ex=c(g.ea));b=0;for(l=g.c.length;b<l;b++)d.instances.push(this.jk(g.c[b]));p.types[g.I.toString()]=d}a=0;for(f=this.kc.length;a<f;a++)b=this.kc[a],p.layouts[b.I.toString()]=b.nc();l=p.events.groups;a=0;for(f=this.Ge.length;a<f;a++)b=
this.Ge[a],l[b.I.toString()]=this.Nf[b.Mf].Me;f=p.events.cnds;for(e in this.Ie)this.Ie.hasOwnProperty(e)&&(a=this.Ie[e],Ta(a.ea)&&(f[e]={ex:c(a.ea)}));f=p.events.acts;for(e in this.Fe)this.Fe.hasOwnProperty(e)&&(a=this.Fe[e],Ta(a.ea)&&(f[e]={ex:a.ea}));f=p.events.vars;for(e in this.sf)this.sf.hasOwnProperty(e)&&(a=this.sf[e],a.rh||a.parent&&!a.Wf||(f[e]=a.data));p.system=this.Lc.nc();return JSON.stringify(p)};e.prototype.hn=function(){var a,f,b,l,c,g;this.dd={};a=0;for(f=this.j.length;a<f;a++)if(b=
this.j[a],!b.K)for(l=0,c=b.c.length;l<c;l++)g=b.c[l],this.dd[g.uid.toString()]=g};e.prototype.hr=function(a){a=JSON.parse(a);if(a.c2save&&!(1<a.version)){var f=a.rt;this.Qb.reset();this.Qb.U=f.time;this.Qc.reset();this.Qc.U=f.walltime||0;this.of=f.timescale;this.Gg=f.tickcount;this.dh=f.execcount;this.$h=Date.now()-f.start_time_offset;var b=f.running_layout;if(b!==this.S.I)if(b=this.Gl(b))this.rl(b);else return;var l,c,g,d,e,p,n;p=a.types;for(c in p)if(p.hasOwnProperty(c)&&(d=this.mh(parseInt(c,10)))&&
!d.K&&!this.Nn(d)){p[c].ex?d.ea=p[c].ex:Ua(d.ea);e=d.c;g=p[c].instances;b=0;for(l=oa(e.length,g.length);b<l;b++)this.Ch(e[b],g[b]);b=g.length;for(l=e.length;b<l;b++)this.Td(e[b]);b=e.length;for(l=g.length;b<l;b++){e=null;if(d.ha.Hd&&(e=this.S.kh(g[b].w.l),!e))continue;e=this.Ad(d.Kb,e,!1,0,0,!0);this.Ch(e,g[b])}d.nf=!0}this.Oa();this.hn();l=a.layouts;for(c in l)l.hasOwnProperty(c)&&(b=this.Gl(parseInt(c,10)))&&b.bd(l[c]);l=a.events.groups;for(c in l)l.hasOwnProperty(c)&&(b=this.tq(parseInt(c,10)))&&
this.Nf[b.Mf]&&this.Nf[b.Mf].Xr(l[c]);b=a.events.cnds;for(c in b)b.hasOwnProperty(c)&&this.Ie.hasOwnProperty(c)&&(this.Ie[c].ea=b[c].ex);b=a.events.acts;for(c in b)b.hasOwnProperty(c)&&this.Fe.hasOwnProperty(c)&&(this.Fe[c].ea=b[c].ex);b=a.events.vars;for(c in b)b.hasOwnProperty(c)&&this.sf.hasOwnProperty(c)&&(this.sf[c].data=b[c]);this.lg=f.next_uid;this.Lc.bd(a.system);b=0;for(l=this.j.length;b<l;b++)if(d=this.j[b],!d.K)for(c=0,a=d.c.length;c<a;c++){e=d.c[c];if(d.Ab)for(p=e.Lf(),f=e.siblings.length=
0,g=d.gb.length;f<g;f++)n=d.gb[f],d!==n&&e.siblings.push(n.c[p]);e.td&&e.td();if(e.C)for(f=0,g=e.C.length;f<g;f++)p=e.C[f],p.td&&p.td()}this.X=!0}};e.prototype.jk=function(a,f){var b,l,g,d,e;d=a.type;g=d.ha;var p={};f?p.c2=!0:p.uid=a.uid;Ta(a.ea)&&(p.ex=c(a.ea));if(a.ra&&a.ra.length)for(p.ivs={},b=0,l=a.ra.length;b<l;b++)p.ivs[a.type.qj[b].toString()]=a.ra[b];if(g.Hd){g={x:a.x,y:a.y,w:a.width,h:a.height,l:a.g.I,zi:a.Bc()};0!==a.k&&(g.a=a.k);1!==a.opacity&&(g.o=a.opacity);.5!==a.lb&&(g.hX=a.lb);.5!==
a.mb&&(g.hY=a.mb);0!==a.Xa&&(g.bm=a.Xa);a.visible||(g.v=a.visible);a.yd||(g.ce=a.yd);-1!==a.kg&&(g.mts=a.kg);if(d.A.length)for(g.fx=[],b=0,l=d.A.length;b<l;b++)e=d.A[b],g.fx.push({name:e.name,active:a.sd[e.index],params:a.ba[e.index]});p.w=g}if(a.C&&a.C.length)for(p.behs={},b=0,l=a.C.length;b<l;b++)d=a.C[b],d.nc&&(p.behs[d.type.I.toString()]=d.nc());a.nc&&(p.data=a.nc());return p};e.prototype.vq=function(a,f){var b,l;b=0;for(l=a.qj.length;b<l;b++)if(a.qj[b]===f)return b;return-1};e.prototype.qq=function(a,
f){var b,l;b=0;for(l=a.C.length;b<l;b++)if(a.C[b].type.I===f)return b;return-1};e.prototype.Ch=function(a,f,b){var l,c,g,d,e;e=a.type;g=e.ha;if(b){if(!f.c2)return}else a.uid=f.uid;f.ex?a.ea=f.ex:Ua(a.ea);if(c=f.ivs)for(l in c)c.hasOwnProperty(l)&&(b=this.vq(e,parseInt(l,10)),0>b||b>=a.ra.length||(a.ra[b]=c[l]));if(g.Hd){g=f.w;a.g.I!==g.l&&(b=a.g,a.g=this.S.kh(g.l),a.g?(b.hf(a,!0),a.g.wf(a,!0),a.ya(),a.g.yg(0)):(a.g=b,this.Td(a)));a.x=g.x;a.y=g.y;a.width=g.w;a.height=g.h;a.qc=g.zi;a.k=g.hasOwnProperty("a")?
g.a:0;a.opacity=g.hasOwnProperty("o")?g.o:1;a.lb=g.hasOwnProperty("hX")?g.hX:.5;a.mb=g.hasOwnProperty("hY")?g.hY:.5;a.visible=g.hasOwnProperty("v")?g.v:!0;a.yd=g.hasOwnProperty("ce")?g.ce:!0;a.kg=g.hasOwnProperty("mts")?g.mts:-1;a.Xa=g.hasOwnProperty("bm")?g.bm:0;a.Bf=cb(a.Xa);this.i&&db(a,a.Xa,this.i);a.ya();if(g.hasOwnProperty("fx"))for(b=0,c=g.fx.length;b<c;b++)d=e.$i(g.fx[b].name),0>d||(a.sd[d]=g.fx[b].active,a.ba[d]=g.fx[b].params);a.nd()}if(e=f.behs)for(l in e)e.hasOwnProperty(l)&&(g=this.qq(a,
parseInt(l,10)),0>g||a.C[g].bd(e[l]));f.data&&a.bd(f.data)};Mb=function(a){return new e(document.getElementById(a))};Nb=function(a,f){return new e({dc:!0,width:a,height:f})};window.cr_createRuntime=Mb;window.cr_createDCRuntime=Nb;window.createCocoonJSRuntime=function(){window.c2cocoonjs=!0;var a=document.createElement("screencanvas")||document.createElement("canvas");a.Kt=!0;document.body.appendChild(a);a=new e(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 e(document.getElementById("canvas"));window.c2runtime=a;window.c2runtime.setSize(window.innerWidth,window.innerHeight);return a}})();window.cr_getC2Runtime=function(){var k=document.getElementById("c2canvas");return k?k.c2runtime:window.c2runtime?window.c2runtime:null};
window.cr_sizeCanvas=function(k,q){if(0!==k&&0!==q){var e=window.cr_getC2Runtime();e&&e.setSize(k,q)}};window.cr_setSuspended=function(k){var q=window.cr_getC2Runtime();q&&q.setSuspended(k)};
(function(){function k(a,b){this.b=a;this.ee=null;this.scrollX=this.b.wa/2;this.scrollY=this.b.va/2;this.scale=1;this.k=0;this.Ke=!0;this.name=b[0];this.width=b[1];this.height=b[2];this.On=b[3];this.wn=b[4];this.I=b[5];var c=b[6],g,d;this.D=[];this.Qf=[];g=0;for(d=c.length;g<d;g++){var e=new Ob(this,c[g]);e.Em=g;this.D.push(e)}c=b[7];this.le=[];g=0;for(d=c.length;g<d;g++){var e=c[g],h=this.b.j[e[1]];h.Kb||(h.Kb=e);this.le.push(e);-1===this.Qf.indexOf(h)&&this.Qf.push(h)}this.A=[];this.N=[];this.ba=
[];g=0;for(d=b[8].length;g<d;g++)this.A.push({id:b[8][g][0],name:b[8][g][1],Na:-1,wb:!0,index:g}),this.ba.push(b[8][g][2].slice(0));this.nd();this.bk=new R(0,0,1,1);this.ck=new R(0,0,1,1);this.Jd={}}function q(a,b){return a.qc-b.qc}function e(a,b){this.Ca=a;this.b=a.b;this.c=[];this.scale=1;this.k=0;this.$d=!1;this.ld=new R(0,0,0,0);this.In=new va;this.Ga=this.pa=this.Ha=this.na=0;this.Be=!1;this.pd=-1;this.name=b[0];this.index=b[1];this.I=b[2];this.visible=b[3];this.vd=b[4];this.md=b[5];this.ed=
b[6];this.fd=b[7];this.opacity=b[8];this.Ui=b[9];this.pc=b[10];this.qd=b[11];this.Xa=b[12];this.Gp=b[13];this.Bf="source-over";this.Qa=this.Sa=0;this.pb=null;this.Ve=m();this.gd=!0;this.xh=new R(0,0,-1,-1);this.Jb=new R(0,0,-1,-1);this.pc&&(this.pb=new bb(this.b.wa,this.b.va));this.Kd=!1;var c=b[14],g,d;this.Bn=[];this.zb=[];this.Cf=[];g=0;for(d=c.length;g<d;g++){var e=c[g],h=this.b.j[e[1]];h.Kb||(h.Kb=e,h.pp=this.index);this.zb.push(e);-1===this.Ca.Qf.indexOf(h)&&this.Ca.Qf.push(h)}ya(this.Bn,this.zb);
this.A=[];this.N=[];this.ba=[];g=0;for(d=b[15].length;g<d;g++)this.A.push({id:b[15][g][0],name:b[15][g][1],Na:-1,wb:!0,index:g}),this.ba.push(b[15][g][2].slice(0));this.nd();this.bk=new R(0,0,1,1);this.ck=new R(0,0,1,1)}function m(){return c.length?c.pop():[]}function s(a){a.length=0;c.push(a)}k.prototype.Ur=function(a){var b=a.type.I.toString();this.Jd.hasOwnProperty(b)||(this.Jd[b]=[]);this.Jd[b].push(this.b.jk(a))};k.prototype.Ll=function(){var a=this.D[0];return!a.md&&1===a.opacity&&!a.Ui&&a.visible};
k.prototype.nd=function(){this.N.length=0;var a,b,c;a=0;for(b=this.A.length;a<b;a++)c=this.A[a],c.wb&&this.N.push(c)};k.prototype.Zi=function(a){var b,c,g;b=0;for(c=this.A.length;b<c;b++)if(g=this.A[b],g.name===a)return g;return null};var d=[],b=!0;k.prototype.ok=function(){this.wn&&(this.ee=this.b.Oi[this.wn],this.ee.yk());this.b.S=this;this.scrollX=this.b.wa/2;this.scrollY=this.b.va/2;var a,c,e,g,n,m,h;a=0;for(e=this.b.j.length;a<e;a++)if(c=this.b.j[a],!c.K)for(n=c.c,c=0,g=n.length;c<g;c++)if(m=
n[c],m.g){var f=m.g.Em;f>=this.D.length&&(f=this.D.length-1);m.g=this.D[f];-1===m.g.c.indexOf(m)&&m.g.c.push(m);m.g.Be=!0}if(!b)for(a=0,e=this.D.length;a<e;++a)this.D[a].c.sort(q);d.length=0;this.dp();a=0;for(e=this.D.length;a<e;a++)m=this.D[a],m.np(),m.Ak();n=!1;if(!this.Ke){for(h in this.Jd)if(this.Jd.hasOwnProperty(h)&&(c=this.b.mh(parseInt(h,10)))&&!c.K&&this.b.xk(c)){g=this.Jd[h];a=0;for(e=g.length;a<e;a++){m=null;if(c.ha.Hd&&(m=this.kh(g[a].w.l),!m))continue;m=this.b.Ad(c.Kb,m,!1,0,0,!0);this.b.Ch(m,
g[a]);n=!0;d.push(m)}g.length=0}a=0;for(e=this.D.length;a<e;a++)this.D[a].c.sort(q),this.D[a].Be=!0}n&&(this.b.Oa(),this.b.hn());for(a=0;a<d.length;a++)if(m=d[a],m.type.Ab)for(e=m.Lf(),c=0,g=m.type.gb.length;c<g;c++)h=m.type.gb[c],m.type!==h&&(h.c.length>e?m.siblings.push(h.c[e]):h.Kb&&(n=this.b.Ad(h.Kb,m.g,!0,m.x,m.y,!0),this.b.Oa(),h.ii(),m.siblings.push(n),d.push(n)));a=0;for(e=this.le.length;a<e;a++)this.b.Ad(this.le[a],null,!0);this.b.Af=null;this.b.Oa();if(this.b.V&&!this.b.ca)for(a=0,e=this.b.j.length;a<
e;a++)h=this.b.j[a],!h.K&&h.c.length&&h.bn&&h.bn(this.b.V);a=0;for(e=d.length;a<e;a++)m=d[a],this.b.trigger(Object.getPrototypeOf(m.type.ha).e.Lg,m);d.length=0;this.b.trigger(Y.prototype.e.Hk,null);this.Ke=!1};k.prototype.mp=function(){var a,b,c,g,d;b=a=0;for(c=this.le.length;a<c;a++)g=this.le[a],d=this.b.j[g[1]],d.global?this.b.Ad(g,null,!0):(this.le[b]=g,b++);this.le.length=b};k.prototype.ds=function(){this.b.trigger(Y.prototype.e.zo,null);this.b.Lc.sb.length=0;var a,c,d,g,e,n;if(!this.Ke)for(a=
0,c=this.D.length;a<c;a++)for(this.D[a].Bk(),e=this.D[a].c,d=0,g=e.length;d<g;d++)n=e[d],n.type.global||this.b.xk(n.type)&&this.Ur(n);a=0;for(c=this.D.length;a<c;a++){e=this.D[a].c;d=0;for(g=e.length;d<g;d++)n=e[d],n.type.global||this.b.Td(n);this.b.Oa();e.length=0;this.D[a].Be=!0}a=0;for(c=this.b.j.length;a<c;a++)if(e=this.b.j[a],!(e.global||e.ha.Hd||e.ha.Zh||e.K)){d=0;for(g=e.c.length;d<g;d++)this.b.Td(e.c[d]);this.b.Oa()}b=!1};new R(0,0,0,0);k.prototype.ae=function(a){var b,c=a,g=!1,d=!this.b.Mb;
d&&(this.b.Ah||(this.b.Ah=document.createElement("canvas"),b=this.b.Ah,b.width=this.b.H,b.height=this.b.G,this.b.fm=b.getContext("2d"),g=!0),b=this.b.Ah,c=this.b.fm,b.width!==this.b.H&&(b.width=this.b.H,g=!0),b.height!==this.b.G&&(b.height=this.b.G,g=!0),g&&(c.webkitImageSmoothingEnabled=this.b.R,c.mozImageSmoothingEnabled=this.b.R,c.msImageSmoothingEnabled=this.b.R,c.imageSmoothingEnabled=this.b.R));c.globalAlpha=1;c.globalCompositeOperation="source-over";this.b.pi&&!this.Ll()&&c.clearRect(0,0,this.b.H,
this.b.G);var e,h,g=0;for(e=this.D.length;g<e;g++)h=this.D[g],h.visible&&0<h.opacity&&11!==h.Xa&&(h.c.length||!h.md)?h.ae(c):h.Ak();d&&a.drawImage(b,0,0,this.b.width,this.b.height)};k.prototype.yc=function(a){var b=0<this.N.length||this.b.qf||!this.b.Mb;if(b){this.b.nb||(this.b.nb=a.zd(this.b.H,this.b.G,this.b.R));if(this.b.nb.zf!==this.b.H||this.b.nb.yf!==this.b.G)a.deleteTexture(this.b.nb),this.b.nb=a.zd(this.b.H,this.b.G,this.b.R);a.Jc(this.b.nb);this.b.Mb||a.lf(this.b.H,this.b.G)}else this.b.nb&&
(a.Jc(null),a.deleteTexture(this.b.nb),this.b.nb=null);this.b.pi&&!this.Ll()&&a.clear(0,0,0,0);var c,g,d;c=0;for(g=this.D.length;c<g;c++)d=this.D[c],d.visible&&0<d.opacity&&(d.c.length||!d.md)?d.yc(a):d.Ak();b&&(0===this.N.length||1===this.N.length&&this.b.Mb?(1===this.N.length?(b=this.N[0].index,a.Kc(this.N[0].Na),a.kf(null,1/this.b.H,1/this.b.G,0,0,1,1,this.scale,this.k,0,0,this.b.H/2,this.b.G/2,this.ba[b]),a.Rh(this.N[0].Na)&&(this.b.X=!0)):a.Kc(0),this.b.Mb||a.lf(this.b.width,this.b.height),a.Jc(null),
a.xg(1),a.Vb(this.b.nb),a.qn(),a.Ld(),a.Rd(),b=this.b.width/2,c=this.b.height/2,a.Th(-b,c,b,c,b,-c,-b,-c),a.Vb(null)):this.dk(a,null,null,null))};k.prototype.Kf=function(){return 0<this.N.length||this.b.qf||!this.b.Mb?this.b.nb:null};k.prototype.Hl=function(){var a=this.D[0].gc(),b,c,g;b=1;for(c=this.D.length;b<c;b++)g=this.D[b],(0!==g.ed||0!==g.fd)&&g.gc()<a&&(a=g.gc());return a};k.prototype.nn=function(a){if(!this.On){var b=1/this.Hl()*this.b.H/2;a>this.width-b&&(a=this.width-b);a<b&&(a=b)}this.scrollX!==
a&&(this.scrollX=a,this.b.X=!0)};k.prototype.pn=function(a){if(!this.On){var b=1/this.Hl()*this.b.G/2;a>this.height-b&&(a=this.height-b);a<b&&(a=b)}this.scrollY!==a&&(this.scrollY=a,this.b.X=!0)};k.prototype.dp=function(){this.nn(this.scrollX);this.pn(this.scrollY)};k.prototype.dk=function(a,b,c,g){var d=c?c.N:b?b.N:this.N,e=1,h=0,f=0,n=0,u=this.b.H,m=this.b.G;c?(e=c.g.gc(),h=c.g.Ba(),f=c.g.na,n=c.g.pa,u=c.g.Ha,m=c.g.Ga):b&&(e=b.gc(),h=b.Ba(),f=b.na,n=b.pa,u=b.Ha,m=b.Ga);var k=this.b.Xi,q,w,s,z,I=
0,ta=1,W,G=this.b.H,t=this.b.G,ua=G/2,F=t/2,N=b?b.bk:this.bk,D=b?b.ck:this.ck,E=0,M=0,C=0,J=0,H=G,ka=G,L=t,na=t,ea=s=0,pa=c?c.g.Ba():0;if(c){q=0;for(w=d.length;q<w;q++)s+=a.zq(d[q].Na),ea+=a.Aq(d[q].Na);z=c.Ua;E=b.Rb(z.left,z.top,!0);C=b.Rb(z.left,z.top,!1);H=b.Rb(z.right,z.bottom,!0);L=b.Rb(z.right,z.bottom,!1);0!==pa&&(q=b.Rb(z.right,z.top,!0),w=b.Rb(z.right,z.top,!1),M=b.Rb(z.left,z.bottom,!0),J=b.Rb(z.left,z.bottom,!1),z=Math.min(E,H,q,M),H=Math.max(E,H,q,M),E=z,z=Math.min(C,L,w,J),L=Math.max(C,
L,w,J),C=z);E-=s;C-=ea;H+=s;L+=ea;D.left=E/G;D.top=1-C/t;D.right=H/G;D.bottom=1-L/t;M=E=P(E);J=C=P(C);ka=H=ra(H);na=L=ra(L);M-=s;J-=ea;ka+=s;na+=ea;0>E&&(E=0);0>C&&(C=0);H>G&&(H=G);L>t&&(L=t);0>M&&(M=0);0>J&&(J=0);ka>G&&(ka=G);na>t&&(na=t);N.left=E/G;N.top=1-C/t;N.right=H/G;N.bottom=1-L/t}else N.left=D.left=0,N.top=D.top=0,N.right=D.right=1,N.bottom=D.bottom=1;ea=c&&((c.k||pa)&&a.sg(d[0].Na)||0!==s||0!==ea||1!==c.opacity||c.type.ha.Am)||b&&!c&&1!==b.opacity;a.qn();if(ea){k[I]||(k[I]=a.zd(G,t,this.b.R));
if(k[I].zf!==G||k[I].yf!==t)a.deleteTexture(k[I]),k[I]=a.zd(G,t,this.b.R);a.Kc(0);a.Jc(k[I]);W=na-J;a.clearRect(M,t-J-W,ka-M,W);c?c.yc(a):(a.Vb(this.b.Bb),a.xg(b.opacity),a.Ld(),a.translate(-ua,-F),a.Rd(),a.ze(E,L,H,L,H,C,E,C,N));D.left=D.top=0;D.right=D.bottom=1;c&&(z=N.top,N.top=N.bottom,N.bottom=z);I=1;ta=0}a.xg(1);s=d.length-1;var pa=a.Yj(d[s].Na)||!b&&!c&&!this.b.Mb,aa=0;q=0;for(w=d.length;q<w;q++){k[I]||(k[I]=a.zd(G,t,this.b.R));if(k[I].zf!==G||k[I].yf!==t)a.deleteTexture(k[I]),k[I]=a.zd(G,
t,this.b.R);a.Kc(d[q].Na);aa=d[q].index;a.Rh(d[q].Na)&&(this.b.X=!0);0!=q||ea?(a.kf(g,1/G,1/t,D.left,D.top,D.right,D.bottom,e,h,f,n,(f+u)/2,(n+m)/2,c?c.ba[aa]:b?b.ba[aa]:this.ba[aa]),a.Vb(null),q!==s||pa?(a.Jc(k[I]),W=na-J,z=t-J-W,a.clearRect(M,z,ka-M,W)):(c?a.Md(c.Sa,c.Qa):b&&a.Md(b.Sa,b.Qa),a.Jc(g)),a.Vb(k[ta]),a.Ld(),a.translate(-ua,-F),a.Rd(),a.ze(E,L,H,L,H,C,E,C,N),q!==s||pa||a.Vb(null)):(a.Jc(k[I]),W=na-J,z=t-J-W,a.clearRect(M,z,ka-M,W),c?(a.kf(g,1/c.width,1/c.height,D.left,D.top,D.right,D.bottom,
e,h,f,n,(f+u)/2,(n+m)/2,c.ba[aa]),c.yc(a)):(a.kf(g,1/G,1/t,0,0,1,1,e,h,f,n,(f+u)/2,(n+m)/2,b?b.ba[aa]:this.ba[aa]),a.Vb(b?this.b.Bb:this.b.nb),a.Ld(),a.translate(-ua,-F),a.Rd(),a.ze(E,L,H,L,H,C,E,C,N)),D.left=D.top=0,D.right=D.bottom=1,c&&!pa&&(z=L,L=C,C=z));I=0===I?1:0;ta=0===I?1:0}pa&&(a.Kc(0),c?a.Md(c.Sa,c.Qa):b?a.Md(b.Sa,b.Qa):this.b.Mb||(a.lf(this.b.width,this.b.height),ua=this.b.width/2,F=this.b.height/2,C=E=0,H=this.b.width,L=this.b.height),a.Jc(g),a.Vb(k[ta]),a.Ld(),a.translate(-ua,-F),a.Rd(),
c&&1===d.length&&!ea?a.ze(E,C,H,C,H,L,E,L,N):a.ze(E,L,H,L,H,C,E,C,N),a.Vb(null))};k.prototype.kh=function(a){var b,c;b=0;for(c=this.D.length;b<c;b++)if(this.D[b].I===a)return this.D[b];return null};k.prototype.nc=function(){var a,b,c,g={sx:this.scrollX,sy:this.scrollY,s:this.scale,a:this.k,w:this.width,h:this.height,fv:this.Ke,persist:this.Jd,fx:[],layers:{}};a=0;for(b=this.A.length;a<b;a++)c=this.A[a],g.fx.push({name:c.name,active:c.wb,params:this.ba[c.index]});a=0;for(b=this.D.length;a<b;a++)c=
this.D[a],g.layers[c.I.toString()]=c.nc();return g};k.prototype.bd=function(a){var b,c,g,d;this.scrollX=a.sx;this.scrollY=a.sy;this.scale=a.s;this.k=a.a;this.width=a.w;this.height=a.h;this.Jd=a.persist;"undefined"!==typeof a.fv&&(this.Ke=a.fv);var e=a.fx;b=0;for(c=e.length;b<c;b++)if(g=this.Zi(e[b].name))g.wb=e[b].active,this.ba[g.index]=e[b].params;this.nd();b=a.layers;for(d in b)b.hasOwnProperty(d)&&(a=this.kh(parseInt(d,10)))&&a.bd(b[d])};Ab=k;e.prototype.nd=function(){this.N.length=0;var a,b,
c;a=0;for(b=this.A.length;a<b;a++)c=this.A[a],c.wb&&this.N.push(c)};e.prototype.Zi=function(a){var b,c,g;b=0;for(c=this.A.length;b<c;b++)if(g=this.A[b],g.name===a)return g;return null};e.prototype.np=function(){var a,b,c,g,e,n;b=a=0;for(c=this.zb.length;a<c;a++){g=this.zb[a];e=this.b.j[g[1]];n=this.b.xk(e);e=!0;if(!n||this.Ca.Ke)g=this.b.Ad(g,this,!0),d.push(g),g.type.global&&(e=!1,this.Cf.push(g.uid));e&&(this.zb[b]=this.zb[a],b++)}this.zb.length=b;this.b.Oa();!this.b.q&&this.A.length&&(this.Xa=
this.Gp);this.Bf=cb(this.Xa);this.b.i&&db(this,this.Xa,this.b.i);this.gd=!0};e.prototype.hf=function(a,b){var c=Aa(this.c,a);0>c||(b&&this.pc&&a.Za&&a.Za.right>=a.Za.left&&(a.Ta(),this.pb.update(a,a.Za,null),a.Za.set(0,0,-1,-1)),c===this.c.length-1?this.c.pop():(xa(this.c,c),this.yg(c)),this.gd=!0)};e.prototype.wf=function(a,b){a.qc=this.c.length;this.c.push(a);b&&this.pc&&a.Za&&a.ya();this.gd=!0};e.prototype.Gr=function(a){this.c.unshift(a);this.yg(0)};e.prototype.nr=function(a,b,c){var g=a.Bc();
b=b.Bc();xa(this.c,g);g<b&&b--;c&&b++;b===this.c.length?this.c.push(a):this.c.splice(b,0,a);this.yg(g<b?g:b)};e.prototype.yg=function(a){-1===this.pd?this.pd=a:a<this.pd&&(this.pd=a);this.gd=this.Be=!0};e.prototype.Bk=function(){if(this.Be){-1===this.pd&&(this.pd=0);var a,b,c;if(this.pc)for(a=this.pd,b=this.c.length;a<b;++a)c=this.c[a],c.qc=a,this.pb.kr(c.Za);else for(a=this.pd,b=this.c.length;a<b;++a)this.c[a].qc=a;this.Be=!1;this.pd=-1}};e.prototype.gc=function(a){return this.wq()*(this.b.Mb||a?
this.b.xf:1)};e.prototype.wq=function(){return(this.scale*this.Ca.scale-1)*this.qd+1};e.prototype.Ba=function(){return this.$d?0:Ea(this.Ca.k+this.k)};var c=[],w=[],n=[];e.prototype.Il=function(){this.Bk();this.pb.gn(this.na,this.pa,this.Ha,this.Ga,n);if(!n.length)return m();if(1===n.length){var a=m();ya(a,n[0]);n.length=0;return a}for(var b=!0;1<n.length;){for(var a=n,c=void 0,g=void 0,d=void 0,e=void 0,h=void 0,c=0,g=a.length;c<g-1;c+=2){var d=a[c],e=a[c+1],h=m(),f=d,r=e,u=h,k=0,q=0,A=0,S=f.length,
X=r.length,z=void 0,I=void 0;for(u.length=S+X;k<S&&q<X;++A)z=f[k],I=r[q],z.qc<I.qc?(u[A]=z,++k):(u[A]=I,++q);for(;k<S;++k,++A)u[A]=f[k];for(;q<X;++q,++A)u[A]=r[q];b||(s(d),s(e));w.push(h)}1===g%2&&(b?(d=m(),ya(d,a[g-1]),w.push(d)):w.push(a[g-1]));ya(a,w);w.length=0;b=!1}a=n[0];n.length=0;return a};e.prototype.ae=function(a){this.Kd=this.Ui||1!==this.opacity||0!==this.Xa;var b=this.b.canvas,c=a,g=!1;this.Kd&&(this.b.zh||(this.b.zh=document.createElement("canvas"),b=this.b.zh,b.width=this.b.H,b.height=
this.b.G,this.b.em=b.getContext("2d"),g=!0),b=this.b.zh,c=this.b.em,b.width!==this.b.H&&(b.width=this.b.H,g=!0),b.height!==this.b.G&&(b.height=this.b.G,g=!0),g&&(c.webkitImageSmoothingEnabled=this.b.R,c.mozImageSmoothingEnabled=this.b.R,c.msImageSmoothingEnabled=this.b.R,c.imageSmoothingEnabled=this.b.R),this.md&&c.clearRect(0,0,this.b.H,this.b.G));c.globalAlpha=1;c.globalCompositeOperation="source-over";this.md||(c.fillStyle="rgb("+this.vd[0]+","+this.vd[1]+","+this.vd[2]+")",c.fillRect(0,0,this.b.H,
this.b.G));c.save();this.$d=!0;var g=this.fb(0,0,!0,!0),d=this.fb(0,0,!1,!0);this.$d=!1;this.b.ef&&(g=Math.round(g),d=Math.round(d));this.fk(g,d,c);var e=this.gc();c.scale(e,e);c.translate(-g,-d);this.pc?(this.Jb.left=this.pb.tb(this.na),this.Jb.top=this.pb.ub(this.pa),this.Jb.right=this.pb.tb(this.Ha),this.Jb.bottom=this.pb.ub(this.Ga),this.gd||!this.Jb.ah(this.xh)?(s(this.Ve),g=this.Il(),this.gd=!1,this.xh.Sg(this.Jb)):g=this.Ve):g=this.c;for(var h,f=null,d=0,e=g.length;d<e;++d)h=g[d],h!==f&&(this.Dp(h,
c),f=h);this.pc&&(this.Ve=g);c.restore();this.Kd&&(a.globalCompositeOperation=this.Bf,a.globalAlpha=this.opacity,a.drawImage(b,0,0))};e.prototype.Dp=function(a,b){if(a.visible&&0!==a.width&&0!==a.height){a.Ta();var c=a.Ua;c.right<this.na||c.bottom<this.pa||c.left>this.Ha||c.top>this.Ga||(b.globalCompositeOperation=a.Bf,a.ae(b))}};e.prototype.Ak=function(){this.$d=!0;var a=this.fb(0,0,!0,!0),b=this.fb(0,0,!1,!0);this.$d=!1;this.b.ef&&(a=Math.round(a),b=Math.round(b));this.fk(a,b,null)};e.prototype.fk=
function(a,b,c){var g=this.gc();this.na=a;this.pa=b;this.Ha=a+1/g*this.b.H;this.Ga=b+1/g*this.b.G;a=this.Ba();0!==a&&(c&&(c.translate(this.b.H/2,this.b.G/2),c.rotate(-a),c.translate(this.b.H/-2,this.b.G/-2)),this.ld.set(this.na,this.pa,this.Ha,this.Ga),this.ld.offset((this.na+this.Ha)/-2,(this.pa+this.Ga)/-2),this.In.un(this.ld,a),this.In.fl(this.ld),this.ld.offset((this.na+this.Ha)/2,(this.pa+this.Ga)/2),this.na=this.ld.left,this.pa=this.ld.top,this.Ha=this.ld.right,this.Ga=this.ld.bottom)};e.prototype.yc=
function(a){var b=0,c=0;if(this.Kd=this.Ui||1!==this.opacity||0<this.N.length||0!==this.Xa){this.b.Bb||(this.b.Bb=a.zd(this.b.H,this.b.G,this.b.R));if(this.b.Bb.zf!==this.b.H||this.b.Bb.yf!==this.b.G)a.deleteTexture(this.b.Bb),this.b.Bb=a.zd(this.b.H,this.b.G,this.b.R);a.Jc(this.b.Bb);this.md&&a.clear(0,0,0,0)}this.md||a.clear(this.vd[0]/255,this.vd[1]/255,this.vd[2]/255,1);this.$d=!0;var g=this.fb(0,0,!0,!0),b=this.fb(0,0,!1,!0);this.$d=!1;this.b.ef&&(g=Math.round(g),b=Math.round(b));this.fk(g,b,
null);g=this.gc();a.Ld();a.scale(g,g);a.kn(-this.Ba());a.translate((this.na+this.Ha)/-2,(this.pa+this.Ga)/-2);a.Rd();this.pc?(this.Jb.left=this.pb.tb(this.na),this.Jb.top=this.pb.ub(this.pa),this.Jb.right=this.pb.tb(this.Ha),this.Jb.bottom=this.pb.ub(this.Ga),this.gd||!this.Jb.ah(this.xh)?(s(this.Ve),b=this.Il(),this.gd=!1,this.xh.Sg(this.Jb)):b=this.Ve):b=this.c;var d,e,h=null,c=0;for(d=b.length;c<d;++c)e=b[c],e!==h&&(this.Ep(b[c],a),h=e);this.pc&&(this.Ve=b);this.Kd&&(b=this.N.length?this.N[0].Na:
0,c=this.N.length?this.N[0].index:0,0===this.N.length||1===this.N.length&&!a.Yj(b)&&1===this.opacity?(1===this.N.length?(a.Kc(b),a.kf(this.Ca.Kf(),1/this.b.H,1/this.b.G,0,0,1,1,g,this.Ba(),this.na,this.pa,(this.na+this.Ha)/2,(this.pa+this.Ga)/2,this.ba[c]),a.Rh(b)&&(this.b.X=!0)):a.Kc(0),a.Jc(this.Ca.Kf()),a.xg(this.opacity),a.Vb(this.b.Bb),a.Md(this.Sa,this.Qa),a.Ld(),a.Rd(),g=this.b.H/2,b=this.b.G/2,a.Th(-g,b,g,b,g,-b,-g,-b),a.Vb(null)):this.Ca.dk(a,this,null,this.Ca.Kf()))};e.prototype.Ep=function(a,
b){if(a.visible&&0!==a.width&&0!==a.height){a.Ta();var c=a.Ua;c.right<this.na||c.bottom<this.pa||c.left>this.Ha||c.top>this.Ga||(a.Un?this.Fp(a,b):(b.Kc(0),b.Md(a.Sa,a.Qa),a.yc(b)))}};e.prototype.Fp=function(a,b){var c=a.N[0].Na,g=a.N[0].index,d=this.gc();if(1!==a.N.length||b.Yj(c)||b.Ir(c)||(a.k||a.g.Ba())&&b.sg(c)||1!==a.opacity||a.type.ha.Am)this.Ca.dk(b,this,a,this.Kd?this.b.Bb:this.Ca.Kf()),b.Ld(),b.scale(d,d),b.kn(-this.Ba()),b.translate((this.na+this.Ha)/-2,(this.pa+this.Ga)/-2),b.Rd();else{b.Kc(c);
b.Md(a.Sa,a.Qa);b.Rh(c)&&(this.b.X=!0);var e=0,h=0,f=0,n=0;b.sg(c)&&(c=a.Ua,e=this.Rb(c.left,c.top,!0),h=this.Rb(c.left,c.top,!1),f=this.Rb(c.right,c.bottom,!0),c=this.Rb(c.right,c.bottom,!1),e/=windowWidth,h=1-h/windowHeight,f/=windowWidth,n=1-c/windowHeight);b.kf(this.Kd?this.b.Bb:this.Ca.Kf(),1/a.width,1/a.height,e,h,f,n,d,this.Ba(),this.na,this.pa,(this.na+this.Ha)/2,(this.pa+this.Ga)/2,a.ba[g]);a.yc(b)}};e.prototype.fb=function(a,b,c,g){var d=this.b.devicePixelRatio;this.b.Pe&&(a*=d,b*=d);var d=
this.b.Wm,e=this.b.Xm,d=(this.Ca.scrollX-d)*this.ed+d,e=(this.Ca.scrollY-e)*this.fd+e,h=d,f=e,n=1/this.gc(!g);g?(h-=this.b.H*n/2,f-=this.b.G*n/2):(h-=this.b.width*n/2,f-=this.b.height*n/2);h+=a*n;f+=b*n;b=this.Ba();0!==b&&(h-=d,f-=e,a=Math.cos(b),b=Math.sin(b),g=h*a-f*b,f=f*a+h*b,h=g+d,f+=e);return c?h:f};e.prototype.Rb=function(a,b,c){var d=this.b.Wm,e=this.b.Xm,d=(this.Ca.scrollX-d)*this.ed+d,n=(this.Ca.scrollY-e)*this.fd+e,e=d,h=n,f=this.Ba();if(0!==f){a-=d;b-=n;var r=Math.cos(-f),f=Math.sin(-f),
u=a*r-b*f;b=b*r+a*f;a=u+d;b+=n}d=1/this.gc(!1);e-=this.b.H*d/2;h-=this.b.G*d/2;e=(a-e)/d;return c?e:(b-h)/d};e.prototype.nc=function(){var a,b,c,d={s:this.scale,a:this.k,vl:this.na,vt:this.pa,vr:this.Ha,vb:this.Ga,v:this.visible,bc:this.vd,t:this.md,px:this.ed,py:this.fd,o:this.opacity,zr:this.qd,fx:[],cg:this.Cf,instances:[]};a=0;for(b=this.A.length;a<b;a++)c=this.A[a],d.fx.push({name:c.name,active:c.wb,params:this.ba[c.index]});return d};e.prototype.bd=function(a){var b,c,d;this.scale=a.s;this.k=
a.a;this.na=a.vl;this.pa=a.vt;this.Ha=a.vr;this.Ga=a.vb;this.visible=a.v;this.vd=a.bc;this.md=a.t;this.ed=a.px;this.fd=a.py;this.opacity=a.o;this.qd=a.zr;this.Cf=a.cg||[];ya(this.zb,this.Bn);var e=new ca;b=0;for(d=this.Cf.length;b<d;++b)e.add(this.Cf[b]);c=b=0;for(d=this.zb.length;b<d;++b)e.contains(this.zb[b][2])||(this.zb[c]=this.zb[b],++c);this.zb.length=c;c=a.fx;b=0;for(d=c.length;b<d;b++)if(a=this.Zi(c[b].name))a.wb=c[b].active,this.ba[a.index]=c[b].params;this.nd();this.c.sort(q);this.Be=!0};
Ob=e})();
(function(){function k(a,b){var c,d=a.length;switch(d){case 0:return!0;case 1:return a[0]===b[0];case 2:return a[0]===b[0]&&a[1]===b[1];default:for(c=0;c<d;c++)if(a[c]!==b[c])return!1;return!0}}function q(a,b){return a.index-b.index}function e(a){var b,c,d,g;2===a.length?a[0].index>a[1].index&&(b=a[0],a[0]=a[1],a[1]=b):2<a.length&&a.sort(q);a.length>=x.length&&(x.length=a.length+1);x[a.length]||(x[a.length]=[]);g=x[a.length];b=0;for(c=g.length;b<c;b++)if(d=g[b],k(a,d))return d;g.push(a);return a}
function m(a,b){this.b=a;this.Kn={};this.wl={};this.jj=!1;this.Nl=new ca;this.Ki=[];this.qi=[];this.name=b[0];var c=b[1];this.Cd=[];var d,g;d=0;for(g=c.length;d<g;d++)this.Pl(c[d],null,this.Cd)}function s(a){this.type=a;this.c=[];this.L=[];this.Y=!0}function d(a,b,c){this.sheet=a;this.parent=b;this.b=a.b;this.ka=[];this.Nd=[];this.Ml=this.fi=this.uk=this.oj=this.group=this.An=!1;this.Pa=[];this.$b=[];this.Xb=[];this.Mf="";this.Me=this.oj=this.group=!1;this.Qg=null;c[1]&&(this.Mf=c[1][1].toLowerCase(),
this.group=!0,this.oj=!!c[1][0],this.Qg=[],this.Me=this.oj,this.b.Ge.push(this),this.b.Nf[this.Mf]=this);this.Fc=c[2];this.I=c[4];this.group||(this.b.el[this.I.toString()]=this);var d=c[5];a=0;for(b=d.length;a<b;a++){var g=new Pb(this,d[a]);g.index=a;this.Pa.push(g);this.Tk(g.type)}d=c[6];a=0;for(b=d.length;a<b;a++)g=new Qb(this,d[a]),g.index=a,this.$b.push(g);if(8===c.length)for(c=c[7],a=0,b=c.length;a<b;a++)this.sheet.Pl(c[a],this,this.Xb);this.sh=!1;this.Pa.length&&(this.sh=null==this.Pa[0].type&&
this.Pa[0].Ia==Y.prototype.e.jo)}function b(a,b){var c,d,g;if(a&&(-1===b.indexOf(a)&&b.push(a),a.Ab))for(c=0,d=a.gb.length;c<d;c++)g=a.gb[c],a!==g&&-1===b.indexOf(g)&&b.push(g)}function c(a,b){this.xb=a;this.sheet=a.sheet;this.b=a.b;this.F=[];this.da=[];this.ea={};this.index=-1;this.uf=!1;this.Ia=this.b.rd(b[1]);this.trigger=0<b[3];this.ul=2===b[3];this.Ec=b[4];this.rj=b[5];this.fr=b[6];this.I=b[7];this.b.Ie[this.I.toString()]=this;-1===b[0]?(this.type=null,this.xa=this.ik,this.Xd=null,this.cc=-1):
(this.type=this.b.j[b[0]],this.xa=this.fr?this.Sr:this.hk,b[2]?(this.Xd=this.type.jh(b[2]),this.cc=this.type.Yi(b[2])):(this.Xd=null,this.cc=-1),this.xb.parent&&this.xb.parent.Wh());this.ul&&(this.xa=this.Tr);if(10===b.length){var c,d,g=b[9];c=0;for(d=g.length;c<d;c++){var e=new Rb(this,g[c]);this.F.push(e)}this.da.length=g.length}}function w(a,b){this.xb=a;this.sheet=a.sheet;this.b=a.b;this.F=[];this.da=[];this.ea={};this.index=-1;this.uf=!1;this.Ia=this.b.rd(b[1]);-1===b[0]?(this.type=null,this.xa=
this.ik,this.Xd=null,this.cc=-1):(this.type=this.b.j[b[0]],this.xa=this.hk,b[2]?(this.Xd=this.type.jh(b[2]),this.cc=this.type.Yi(b[2])):(this.Xd=null,this.cc=-1));this.I=b[3];this.b.Fe[this.I.toString()]=this;if(6===b.length){var c,d,g=b[5];c=0;for(d=g.length;c<d;c++){var e=new Rb(this,g[c]);this.F.push(e)}this.da.length=g.length}}function n(){h++;v.length===h&&v.push(new Sb);return v[h]}function a(a,b){this.Ub=a;this.xb=a.xb;this.sheet=a.sheet;this.b=a.b;this.type=b[0];this.zc=null;this.kd=0;this.get=
null;this.ll=0;this.Ca=null;this.key=0;this.object=null;this.index=0;this.Ig=this.Ae=this.Ig=this.Ae=this.xl=this.fe=this.Jg=null;this.Yb=!1;var c,d,g;switch(b[0]){case 0:case 7:this.zc=new Tb(this,b[1]);this.kd=0;this.get=this.Fq;break;case 1:this.zc=new Tb(this,b[1]);this.kd=0;this.get=this.Gq;break;case 5:this.zc=new Tb(this,b[1]);this.kd=0;this.get=this.Kq;break;case 3:case 8:this.ll=b[1];this.get=this.Dq;break;case 6:this.Ca=this.b.Bj[b[1]];this.get=this.Lq;break;case 9:this.key=b[1];this.get=
this.Jq;break;case 4:this.object=this.b.j[b[1]];this.get=this.Mq;this.xb.Tk(this.object);this.Ub instanceof Qb?this.xb.Wh():this.xb.parent&&this.xb.parent.Wh();break;case 10:this.index=b[1];a.type.K?(this.get=this.Hq,this.Yb=!0):this.get=this.Iq;break;case 11:this.Jg=b[1];this.fe=null;this.get=this.Eq;break;case 2:case 12:this.xl=b[1];this.get=this.Cq;break;case 13:for(this.get=this.Nq,this.Ae=[],this.Ig=[],c=1,d=b.length;c<d;c++)g=new Rb(this.Ub,b[c]),this.Ae.push(g),this.Ig.push(0)}}function l(a,
b,c){this.sheet=a;this.parent=b;this.b=a.b;this.ka=[];this.name=c[1];this.Wn=c[2];this.nj=c[3];this.Wf=!!c[4];this.rh=!!c[5];this.I=c[6];this.b.sf[this.I.toString()]=this;this.data=this.nj;this.parent?(this.we=this.Wf||this.rh?-1:this.b.bs++,this.b.Zo.push(this)):(this.we=-1,this.b.Yo.push(this))}function p(a,b,c){this.sheet=a;this.parent=b;this.b=a.b;this.ka=[];this.Pf=null;this.Tq=c[1];this.wb=!0}function g(){this.Dn=[];this.reset(null)}var x=[];m.prototype.toString=function(){return this.name};
m.prototype.Pl=function(a,b,c){switch(a[0]){case 0:a=new Ub(this,b,a);if(a.Fc)for(c.push(a),c=0,b=a.Pa.length;c<b;c++)a.Pa[c].trigger&&this.Ql(a,c);else a.Xl()?this.Ql(a,0):c.push(a);break;case 1:a=new Lb(this,b,a);c.push(a);break;case 2:a=new Vb(this,b,a),c.push(a)}};m.prototype.ja=function(){var a,b;a=0;for(b=this.Cd.length;a<b;a++)this.Cd[a].ja(a<b-1&&this.Cd[a+1].sh)};m.prototype.yk=function(){this.Ki.length=0;this.qi.length=0;this.Sk(this);this.qi.length=0};m.prototype.Sk=function(a){var b,c,
d,g,e=a.Ki,h=a.qi,l=this.Nl.Sd();b=0;for(c=l.length;b<c;++b)d=l[b],g=d.Pf,!d.wb||a===g||-1<h.indexOf(g)||(h.push(g),g.Sk(a),e.push(g))};m.prototype.xa=function(a){this.b.Jt||(this.jj=!0,a||(this.b.vj=!0));var b,c;b=0;for(c=this.Cd.length;b<c;b++){var d=this.Cd[b];d.xa();this.b.Di(d.ka);this.b.Ed&&this.b.Oa()}a||(this.b.vj=!1)};m.prototype.Ql=function(a,b){a.Fc||this.b.hi.push(a);var c,d,g=a.Pa[b],e;e=g.type?g.type.name:"system";var h=(c=g.ul)?this.wl:this.Kn;h[e]||(h[e]=[]);e=h[e];h=g.Ia;if(c){if(g.F.length&&
(g=g.F[0],1===g.type&&2===g.zc.type)){g=g.zc.value.toLowerCase();c=0;for(d=e.length;c<d;c++)if(e[c].method==h){c=e[c].Gf;c[g]?c[g].push([a,b]):c[g]=[[a,b]];return}c={};c[g]=[[a,b]];e.push({method:h,Gf:c})}}else{c=0;for(d=e.length;c<d;c++)if(e[c].method==h){e[c].Gf.push([a,b]);return}fc&&h===fc.prototype.e.Ee?e.unshift({method:h,Gf:[[a,b]]}):e.push({method:h,Gf:[[a,b]]})}};Bb=m;s.prototype.ij=function(){return this.Y?this.type.c.length:this.c.length};s.prototype.fc=function(){return this.Y?this.type.c:
this.c};s.prototype.rg=function(a){a&&(a.b.jb().ec.Fc?(this.Y&&(this.c.length=0,ya(this.L,a.type.c),this.Y=!1),a=this.L.indexOf(a),-1!==a&&(this.c.push(this.L[a]),this.L.splice(a,1))):(this.Y=!1,this.c.length=1,this.c[0]=a))};jb=s;window._c2hh_="595E09B44298EB3B8CBCAEB682CEB86C9AE43304";d.prototype.ja=function(a){var b,c=this.parent;if(this.group)for(this.fi=!0;c;){if(!c.group){this.fi=!1;break}c=c.parent}this.uk=!this.Xl()&&(!this.parent||this.parent.group&&this.parent.fi);this.Ml=!!a;this.Nd=this.ka.slice(0);
for(c=this.parent;c;){a=0;for(b=c.ka.length;a<b;a++)this.Xo(c.ka[a]);c=c.parent}this.ka=e(this.ka);this.Nd=e(this.Nd);a=0;for(b=this.Pa.length;a<b;a++)this.Pa[a].ja();a=0;for(b=this.$b.length;a<b;a++)this.$b[a].ja();a=0;for(b=this.Xb.length;a<b;a++)this.Xb[a].ja(a<b-1&&this.Xb[a+1].sh)};d.prototype.Xr=function(a){if(this.Me!==!!a){this.Me=!!a;var b;a=0;for(b=this.Qg.length;a<b;++a)this.Qg[a].Rn();0<b&&this.b.S.ee&&this.b.S.ee.yk()}};d.prototype.Tk=function(a){b(a,this.ka)};d.prototype.Xo=function(a){b(a,
this.Nd)};d.prototype.Wh=function(){this.An=!0;this.parent&&this.parent.Wh()};d.prototype.Xl=function(){return this.Pa.length?this.Pa[0].trigger:!1};d.prototype.xa=function(){var a,b=!1,c,d=this.b,g=this.b.jb();g.ec=this;var e=this.Pa;this.sh||(g.Mi=!1);if(this.Fc){0===e.length&&(b=!0);g.Ya=0;for(a=e.length;g.Ya<a;g.Ya++)e[g.Ya].trigger||(c=e[g.Ya].xa())&&(b=!0);(g.se=b)&&this.gk()}else{g.Ya=0;for(a=e.length;g.Ya<a;g.Ya++)if(c=e[g.Ya].xa(),!c){g.se=!1;this.uk&&d.Ed&&d.Oa();return}g.se=!0;this.gk()}this.Ip(g)};
d.prototype.Ip=function(a){a.se&&this.Ml&&(a.Mi=!0);this.uk&&this.b.Ed&&this.b.Oa()};d.prototype.Qr=function(a){this.b.jb().ec=this;this.Pa[a].xa()&&(this.gk(),this.b.jb().se=!0)};d.prototype.gk=function(){var a=this.b.jb(),b;a.Eb=0;for(b=this.$b.length;a.Eb<b;a.Eb++)if(this.$b[a.Eb].xa())return;this.ln()};d.prototype.Or=function(){var a=this.b.jb(),b;for(b=this.$b.length;a.Eb<b;a.Eb++)if(this.$b[a.Eb].xa())return;this.ln()};d.prototype.ln=function(){if(this.Xb.length){var a,b,c,d,g=this.Xb.length-
1;this.b.$j(this);if(this.An)for(a=0,b=this.Xb.length;a<b;a++)c=this.Xb[a],(d=!this.fi||!this.group&&a<g)&&this.b.Zj(c.ka),c.xa(),d?this.b.ff(c.ka):this.b.Di(c.ka);else for(a=0,b=this.Xb.length;a<b;a++)this.Xb[a].xa();this.b.$m()}};d.prototype.Rr=function(){var a=this.b.jb();a.ec=this;var b=!1,c;a.Ya=0;for(c=this.Pa.length;a.Ya<c;a.Ya++)if(this.Pa[a.Ya].xa())b=!0;else if(!this.Fc)return!1;return this.Fc?b:!0};d.prototype.Yq=function(a){var b=a.index;if(0===b)return!0;for(--b;0<=b;--b)if(this.Pa[b].type===
a.type)return!1;return!0};Ub=d;c.prototype.ja=function(){var a,b,c;a=0;for(b=this.F.length;a<b;a++)c=this.F[a],c.ja(),c.Yb&&(this.uf=!0)};c.prototype.Tr=function(){return!0};c.prototype.ik=function(){var a,b;a=0;for(b=this.F.length;a<b;a++)this.da[a]=this.F[a].get();return Sa(this.Ia.apply(this.b.Lc,this.da),this.rj)};c.prototype.Sr=function(){var a,b;a=0;for(b=this.F.length;a<b;a++)this.da[a]=this.F[a].get();a=this.Ia.apply(this.Xd?this.Xd:this.type,this.da);this.type.ud();return a};c.prototype.hk=
function(){var a,b,c,d,g,e,h,l,n=this.type,m=n.W(),p=this.xb.Fc&&!this.trigger;b=0;var k=n.Ab,q=n.K,x=n.Yc,v=this.cc,w=-1<v,s=this.uf,D=this.F,E=this.da,M=this.rj,C=this.Ia,J;if(s)for(b=0,g=D.length;b<g;++b)e=D[b],e.Yb||(E[b]=e.get(0));else for(b=0,g=D.length;b<g;++b)E[b]=D[b].get(0);if(m.Y){m.c.length=0;m.L.length=0;J=n.c;a=0;for(d=J.length;a<d;++a){l=J[a];if(s)for(b=0,g=D.length;b<g;++b)e=D[b],e.Yb&&(E[b]=e.get(a));w?(b=0,q&&(b=l.type.Je[x]),b=C.apply(l.C[v+b],E)):b=C.apply(l,E);(h=Sa(b,M))?m.c.push(l):
p&&m.L.push(l)}n.finish&&n.finish(!0);m.Y=!1;n.ud();return m.ij()}c=0;J=(h=p&&!this.xb.Yq(this))?m.L:m.c;var H=!1;a=0;for(d=J.length;a<d;++a){l=J[a];if(s)for(b=0,g=D.length;b<g;++b)e=D[b],e.Yb&&(E[b]=e.get(a));w?(b=0,q&&(b=l.type.Je[x]),b=C.apply(l.C[v+b],E)):b=C.apply(l,E);if(Sa(b,M))if(H=!0,h){if(m.c.push(l),k)for(b=0,g=l.siblings.length;b<g;b++)e=l.siblings[b],e.type.W().c.push(e)}else{J[c]=l;if(k)for(b=0,g=l.siblings.length;b<g;b++)e=l.siblings[b],e.type.W().c[c]=e;c++}else if(h){J[c]=l;if(k)for(b=
0,g=l.siblings.length;b<g;b++)e=l.siblings[b],e.type.W().L[c]=e;c++}else if(p&&(m.L.push(l),k))for(b=0,g=l.siblings.length;b<g;b++)e=l.siblings[b],e.type.W().L.push(e)}J.length=c;if(k)for(q=n.gb,a=0,d=q.length;a<d;a++)l=q[a].W(),h?l.L.length=c:l.c.length=c;c=H;if(h&&!H)for(a=0,d=m.c.length;a<d;a++){l=m.c[a];if(s)for(b=0,g=D.length;b<g;b++)e=D[b],e.Yb&&(E[b]=e.get(a));b=w?C.apply(l.C[v],E):C.apply(l,E);if(Sa(b,M)){H=!0;break}}n.finish&&n.finish(c||p);return p?H:m.ij()};Pb=c;w.prototype.ja=function(){var a,
b,c;a=0;for(b=this.F.length;a<b;a++)c=this.F[a],c.ja(),c.Yb&&(this.uf=!0)};w.prototype.ik=function(){var a=this.b,b,c,d=this.F,g=this.da;b=0;for(c=d.length;b<c;++b)g[b]=d[b].get();return this.Ia.apply(a.Lc,g)};w.prototype.hk=function(){var a=this.type,b=this.cc,c=a.Yc,d=this.uf,g=this.F,e=this.da,h=this.Ia,l=a.W().fc(),a=a.K,n=-1<b,m,p,k,q,x,v;if(d)for(p=0,q=g.length;p<q;++p)x=g[p],x.Yb||(e[p]=x.get(0));else for(p=0,q=g.length;p<q;++p)e[p]=g[p].get(0);m=0;for(k=l.length;m<k;++m){v=l[m];if(d)for(p=
0,q=g.length;p<q;++p)x=g[p],x.Yb&&(e[p]=x.get(m));n?(p=0,a&&(p=v.type.Je[c]),h.apply(v.C[b+p],e)):h.apply(v,e)}return!1};Qb=w;var v=[],h=-1;a.prototype.ja=function(){var a,b;if(11===this.type)this.fe=this.b.El(this.Jg,this.xb.parent);else if(13===this.type)for(a=0,b=this.Ae.length;a<b;a++)this.Ae[a].ja();this.zc&&this.zc.ja()};a.prototype.mr=function(a){this.Yb||!a||a.ha.Zh||(this.Yb=!0)};a.prototype.sn=function(){this.Yb=!0};a.prototype.Fq=function(a){this.kd=a||0;a=n();this.zc.get(a);h--;return a.data};
a.prototype.Gq=function(a){this.kd=a||0;a=n();this.zc.get(a);h--;return O(a.data)?a.data:""};a.prototype.Mq=function(){return this.object};a.prototype.Dq=function(){return this.ll};a.prototype.Kq=function(a){this.kd=a||0;a=n();this.zc.get(a);h--;return a.ta()?this.b.Jf(a.data):this.b.bj(a.data)};a.prototype.Lq=function(){return this.Ca};a.prototype.Jq=function(){return this.key};a.prototype.Iq=function(){return this.index};a.prototype.Hq=function(a){a=a||0;var b=this.Ub.type,c=null,c=b.W(),d=c.fc();
if(d.length)c=d[a%d.length].type;else if(c.L.length)c=c.L[a%c.L.length].type;else if(b.c.length)c=b.c[a%b.c.length].type;else return 0;return this.index+c.eh[b.Yc]};a.prototype.Eq=function(){return this.fe};a.prototype.Cq=function(){return this.xl};a.prototype.Nq=function(){var a,b;a=0;for(b=this.Ae.length;a<b;a++)this.Ig[a]=this.Ae[a].get();return this.Ig};Rb=a;l.prototype.ja=function(){this.ka=e(this.ka)};l.prototype.Xh=function(a){var b=this.b.Cl();this.parent&&!this.Wf&&b?(this.we>=b.length&&
(b.length=this.we+1),b[this.we]=a):this.data=a};l.prototype.Kl=function(){var a=this.b.Cl();return!this.parent||this.Wf||!a||this.rh?this.data:this.we>=a.length||"undefined"===typeof a[this.we]?this.nj:a[this.we]};l.prototype.xa=function(){!this.parent||this.Wf||this.rh||this.Xh(this.nj)};Lb=l;p.prototype.toString=function(){return"include:"+this.Pf.toString()};p.prototype.ja=function(){this.Pf=this.b.Oi[this.Tq];this.sheet.Nl.add(this);this.ka=e(this.ka);for(var a=this.parent;a;)a.group&&a.Qg.push(this),
a=a.parent;this.Rn()};p.prototype.xa=function(){this.parent&&this.b.tg(this.b.j);this.Pf.jj||this.Pf.xa(!0);this.parent&&this.b.ff(this.b.j)};p.prototype.Rn=function(){for(var a=this.parent;a;){if(a.group&&!a.Me){this.wb=!1;return}a=a.parent}this.wb=!0};Vb=p;g.prototype.reset=function(a){this.ec=a;this.Eb=this.Ya=0;this.Dn.length=0;this.Mi=this.se=!1};Kb=g})();
(function(){function k(b,c){this.Ub=b;this.b=b.b;this.type=c[0];this.get=[this.Vp,this.Rp,this.dq,this.hq,this.Kp,this.fq,this.Zp,this.Op,this.Yp,this.cq,this.Lp,this.bq,this.Pp,this.$p,this.Wp,this.Xp,this.Sp,this.Tp,this.Np,this.gq,this.aq,this.Up,this.Mp,this.Qp][this.type];var d=null;this.cd=this.F=this.da=this.Ia=this.ei=this.Fa=this.first=this.value=null;this.cc=-1;this.Fd=null;this.Vn=-1;this.fe=this.Jg=null;this.jf=!1;switch(this.type){case 0:case 1:case 2:this.value=c[1];break;case 3:this.first=
new Tb(b,c[1]);break;case 18:this.first=new Tb(b,c[1]);this.Fa=new Tb(b,c[2]);this.ei=new Tb(b,c[3]);break;case 19:this.Ia=this.b.rd(c[1]);this.Ia!==Y.prototype.hb.random&&this.Ia!==Y.prototype.hb.ip||this.Ub.sn();this.da=[];this.F=[];3===c.length?(d=c[2],this.da.length=d.length+1):this.da.length=1;break;case 20:this.cd=this.b.j[c[1]];this.cc=-1;this.Ia=this.b.rd(c[2]);this.jf=c[3];gc&&this.Ia===gc.prototype.hb.$n&&this.Ub.sn();this.Fd=c[4]?new Tb(b,c[4]):null;this.da=[];this.F=[];6===c.length?(d=
c[5],this.da.length=d.length+1):this.da.length=1;break;case 21:this.cd=this.b.j[c[1]];this.jf=c[2];this.Fd=c[3]?new Tb(b,c[3]):null;this.Vn=c[4];break;case 22:this.cd=this.b.j[c[1]];this.cd.jh(c[2]);this.cc=this.cd.Yi(c[2]);this.Ia=this.b.rd(c[3]);this.jf=c[4];this.Fd=c[5]?new Tb(b,c[5]):null;this.da=[];this.F=[];7===c.length?(d=c[6],this.da.length=d.length+1):this.da.length=1;break;case 23:this.Jg=c[1],this.fe=null}this.Ub.mr(this.cd);4<=this.type&&17>=this.type&&(this.first=new Tb(b,c[1]),this.Fa=
new Tb(b,c[2]));if(d){var e,a;e=0;for(a=d.length;e<a;e++)this.F.push(new Tb(b,d[e]))}}function q(){++d;s.length===d&&s.push(new Sb);return s[d]}function e(b,c,d){var e,a;e=0;for(a=b.length;e<a;++e)b[e].get(d),c[e+1]=d.data}function m(b,c){this.type=b||V.De;this.data=c||0;this.xe=null;this.type==V.De&&(this.data=Math.floor(this.data))}k.prototype.ja=function(){23===this.type&&(this.fe=this.Ub.b.El(this.Jg,this.Ub.xb.parent));this.first&&this.first.ja();this.Fa&&this.Fa.ja();this.ei&&this.ei.ja();this.Fd&&
this.Fd.ja();if(this.F){var b,c;b=0;for(c=this.F.length;b<c;b++)this.F[b].ja()}};var s=[],d=-1;k.prototype.gq=function(b){var c=this.F,m=this.da;m[0]=b;b=q();e(c,m,b);--d;this.Ia.apply(this.b.Lc,m)};k.prototype.aq=function(b){var c=this.cd,m=this.da,n=this.F,a=this.Fd,l=this.Ia,p=this.Ub.kd,g=c.W(),k=g.fc();if(!k.length)if(g.L.length)k=g.L;else{this.jf?b.Ra(""):b.T(0);return}m[0]=b;b.xe=c;b=q();e(n,m,b);a&&(a.get(b),b.ta()&&(p=b.data,k=c.c));--d;c=k.length;if(p>=c||p<=-c)p%=c;0>p&&(p+=c);l.apply(k[p],
m)};k.prototype.Mp=function(b){var c=this.cd,m=this.da,n=this.F,a=this.Fd,l=this.cc,p=this.Ia,g=this.Ub.kd,k=c.W(),v=k.fc();if(!v.length)if(k.L.length)v=k.L;else{this.jf?b.Ra(""):b.T(0);return}m[0]=b;b.xe=c;b=q();e(n,m,b);a&&(a.get(b),b.ta()&&(g=b.data,v=c.c));--d;n=v.length;if(g>=n||g<=-n)g%=n;0>g&&(g+=n);g=v[g];v=0;c.K&&(v=g.type.Je[c.Yc]);p.apply(g.C[l+v],m)};k.prototype.Up=function(b){var c=this.Fd,e=this.cd,n=this.Vn,a=this.Ub.kd,l=e.W(),m=l.fc();if(!m.length)if(l.L.length)m=l.L;else{this.jf?
b.Ra(""):b.T(0);return}if(c){l=q();c.get(l);if(l.ta()){a=l.data;e=e.c;a%=e.length;0>a&&(a+=e.length);n=e[a].ra[n];O(n)?b.Ra(n):b.n(n);--d;return}--d}c=m.length;if(a>=c||a<=-c)a%=c;0>a&&(a+=c);a=m[a];m=0;e.K&&(m=a.type.eh[e.Yc]);n=a.ra[n+m];O(n)?b.Ra(n):b.n(n)};k.prototype.Vp=function(b){b.type=V.De;b.data=this.value};k.prototype.Rp=function(b){b.type=V.Ce;b.data=this.value};k.prototype.dq=function(b){b.type=V.String;b.data=this.value};k.prototype.hq=function(b){this.first.get(b);b.ta()&&(b.data=-b.data)};
k.prototype.Kp=function(b){this.first.get(b);var c=q();this.Fa.get(c);b.ta()&&c.ta()&&(b.data+=c.data,c.Re()&&b.Ze());--d};k.prototype.fq=function(b){this.first.get(b);var c=q();this.Fa.get(c);b.ta()&&c.ta()&&(b.data-=c.data,c.Re()&&b.Ze());--d};k.prototype.Zp=function(b){this.first.get(b);var c=q();this.Fa.get(c);b.ta()&&c.ta()&&(b.data*=c.data,c.Re()&&b.Ze());--d};k.prototype.Op=function(b){this.first.get(b);var c=q();this.Fa.get(c);b.ta()&&c.ta()&&(b.data/=c.data,b.Ze());--d};k.prototype.Yp=function(b){this.first.get(b);
var c=q();this.Fa.get(c);b.ta()&&c.ta()&&(b.data%=c.data,c.Re()&&b.Ze());--d};k.prototype.cq=function(b){this.first.get(b);var c=q();this.Fa.get(c);b.ta()&&c.ta()&&(b.data=Math.pow(b.data,c.data),c.Re()&&b.Ze());--d};k.prototype.Lp=function(b){this.first.get(b);var c=q();this.Fa.get(c);b.ta()?c.th()?b.Ra(b.data.toString()+c.data):b.data&&c.data?b.T(1):b.T(0):b.th()&&(b.data=c.th()?b.data+c.data:b.data+(Math.round(1E10*c.data)/1E10).toString());--d};k.prototype.bq=function(b){this.first.get(b);var c=
q();this.Fa.get(c);b.ta()&&c.ta()&&(b.data||c.data?b.T(1):b.T(0));--d};k.prototype.Np=function(b){this.first.get(b);b.data?this.Fa.get(b):this.ei.get(b)};k.prototype.Pp=function(b){this.first.get(b);var c=q();this.Fa.get(c);b.T(b.data===c.data?1:0);--d};k.prototype.$p=function(b){this.first.get(b);var c=q();this.Fa.get(c);b.T(b.data!==c.data?1:0);--d};k.prototype.Wp=function(b){this.first.get(b);var c=q();this.Fa.get(c);b.T(b.data<c.data?1:0);--d};k.prototype.Xp=function(b){this.first.get(b);var c=
q();this.Fa.get(c);b.T(b.data<=c.data?1:0);--d};k.prototype.Sp=function(b){this.first.get(b);var c=q();this.Fa.get(c);b.T(b.data>c.data?1:0);--d};k.prototype.Tp=function(b){this.first.get(b);var c=q();this.Fa.get(c);b.T(b.data>=c.data?1:0);--d};k.prototype.Qp=function(b){var c=this.fe.Kl();ha(c)?b.n(c):b.Ra(c)};Tb=k;m.prototype.Re=function(){return this.type===V.Ce};m.prototype.ta=function(){return this.type===V.De||this.type===V.Ce};m.prototype.th=function(){return this.type===V.String};m.prototype.Ze=
function(){this.Re()||(this.th()&&(this.data=parseFloat(this.data)),this.type=V.Ce)};m.prototype.T=function(b){this.type=V.De;this.data=Math.floor(b)};m.prototype.n=function(b){this.type=V.Ce;this.data=b};m.prototype.Ra=function(b){this.type=V.String;this.data=b};m.prototype.tn=function(b){ha(b)?(this.type=V.Ce,this.data=b):O(b)?(this.type=V.String,this.data=b.toString()):(this.type=V.De,this.data=0)};Sb=m;V={De:0,Ce:1,String:2}})();function Y(k){this.b=k;this.sb=[]}
Y.prototype.nc=function(){var k={},q,e,m,s,d,b,c,w;k.waits=[];var n=k.waits,a;q=0;for(e=this.sb.length;q<e;q++){b=this.sb[q];a={t:b.time,st:b.as,s:b.yn,ev:b.Ff.I,sm:[],sols:{}};b.Ff.$b[b.Eb]&&(a.act=b.Ff.$b[b.Eb].I);m=0;for(s=b.ka.length;m<s;m++)a.sm.push(b.ka[m].I);for(d in b.qb)if(b.qb.hasOwnProperty(d)){c=this.b.j[parseInt(d,10)];w={sa:b.qb[d].mn,insts:[]};m=0;for(s=b.qb[d].me.length;m<s;m++)w.insts.push(b.qb[d].me[m].uid);a.sols[c.I.toString()]=w}n.push(a)}return k};
Y.prototype.bd=function(k){k=k.waits;var q,e,m,s,d,b,c,w,n,a,l;q=this.sb.length=0;for(e=k.length;q<e;q++)if(b=k[q],w=this.b.el[b.ev.toString()]){n=-1;m=0;for(s=w.$b.length;m<s;m++)if(w.$b[m].I===b.act){n=m;break}if(-1!==n){c={qb:{},ka:[],pl:!1};c.time=b.t;c.as=b.st||"";c.yn=!!b.s;c.Ff=w;c.Eb=n;m=0;for(s=b.sm.length;m<s;m++)(w=this.b.mh(b.sm[m]))&&c.ka.push(w);for(d in b.sols)if(b.sols.hasOwnProperty(d)&&(w=this.b.mh(parseInt(d,10)))){n=b.sols[d];a={mn:n.sa,me:[]};m=0;for(s=n.insts.length;m<s;m++)(l=
this.b.lh(n.insts[m]))&&a.me.push(l);c.qb[w.index.toString()]=a}this.sb.push(c)}}};
(function(){function k(){}function q(){}function e(){}var m=Y.prototype;k.prototype.Hk=function(){return!0};k.prototype.zo=function(){return!0};k.prototype.co=function(b,c,d){return Wb(b,c,d)};k.prototype.fo=function(b,c,d){return Wb(b.Kl(),c,d)};k.prototype.no=function(b){return(b=this.b.Nf[b.toLowerCase()])&&b.Me};k.prototype.jo=function(){var b=this.b.jb();return b.Mi?!1:!b.se};k.prototype.Ik=function(){return!0};k.prototype.to=function(){return!0};k.prototype.ni=function(){return!0};k.prototype.Ao=
function(){return!0};k.prototype.mi=function(){return!0};k.prototype.Yn=function(b,c,d){return Ja(T(b),T(d))<=T(c)};k.prototype.mo=function(b,c){return Pa(T(b),T(c))};k.prototype.lo=function(b,c,d){b=Ha(b);c=Ha(c);d=Ha(d);return Pa(d,c)?Pa(b,c)&&!Pa(b,d):!(!Pa(b,c)&&Pa(b,d))};m.e=new k;q.prototype.ko=function(b){this.b.Xf||this.b.Af||(this.b.Af=b)};q.prototype.ho=function(b,c,d,e){if(c&&b&&(c=this.b.ml(b,c,d,e))){this.b.ic++;var a;this.b.trigger(Object.getPrototypeOf(b.ha).e.Lg,c);if(c.Ab)for(d=0,
e=c.siblings.length;d<e;d++)a=c.siblings[d],this.b.trigger(Object.getPrototypeOf(a.type.ha).e.Lg,a);this.b.ic--;b=b.W();b.Y=!1;b.c.length=1;b.c[0]=c;if(c.Ab)for(d=0,e=c.siblings.length;d<e;d++)a=c.siblings[d],b=a.type.W(),b.Y=!1,b.c.length=1,b.c[0]=a}};q.prototype.Mo=function(b,c){0===b.Wn?ha(c)?b.Xh(c):b.Xh(parseFloat(c)):1===b.Wn&&b.Xh(c.toString())};var s=[],d=[];q.prototype.Oo=function(b,c){this.b.Bg=[0===b?"image/png":"image/jpeg",c/100];this.b.X=!0};m.Aa=new q;e.prototype["int"]=function(b,
c){O(c)?(b.T(parseInt(c,10)),isNaN(b.data)&&(b.data=0)):b.T(c)};e.prototype["float"]=function(b,c){O(c)?(b.n(parseFloat(c)),isNaN(b.data)&&(b.data=0)):b.n(c)};e.prototype.random=function(b,c,d){void 0===d?b.n(Math.random()*c):b.n(Math.random()*(d-c)+c)};e.prototype.sqrt=function(b,c){b.n(Math.sqrt(c))};e.prototype.abs=function(b,c){b.n(Math.abs(c))};e.prototype.round=function(b,c){b.T(Math.round(c))};e.prototype.floor=function(b,c){b.T(Math.floor(c))};e.prototype.ceil=function(b,c){b.T(Math.ceil(c))};
e.prototype.sin=function(b,c){b.n(Math.sin(T(c)))};e.prototype.cos=function(b,c){b.n(Math.cos(T(c)))};e.prototype.tan=function(b,c){b.n(Math.tan(T(c)))};e.prototype.asin=function(b,c){b.n(Ca(Math.asin(c)))};e.prototype.acos=function(b,c){b.n(Ca(Math.acos(c)))};e.prototype.atan=function(b,c){b.n(Ca(Math.atan(c)))};e.prototype.exp=function(b,c){b.n(Math.exp(c))};e.prototype.log10=function(b,c){b.n(Math.log(c)/Math.LN10)};e.prototype.max=function(b){var c=arguments[1];"number"!==typeof c&&(c=0);var d,
e,a;d=2;for(e=arguments.length;d<e;d++)a=arguments[d],"number"===typeof a&&c<a&&(c=a);b.n(c)};e.prototype.min=function(b){var c=arguments[1];"number"!==typeof c&&(c=0);var d,e,a;d=2;for(e=arguments.length;d<e;d++)a=arguments[d],"number"===typeof a&&c>a&&(c=a);b.n(c)};e.prototype.be=function(b){b.n(this.b.be)};e.prototype.of=function(b){b.n(this.b.of)};e.prototype.time=function(b){b.n(this.b.Qb.U)};e.prototype.Gg=function(b){b.T(this.b.Gg)};e.prototype.Kh=function(b){b.T(this.b.Kh)};e.prototype.Vi=
function(b){b.T(this.b.Vi)};e.prototype.k=function(b,c,d,e,a){b.n(Ca(Ia(c,d,e,a)))};e.prototype.find=function(b,c,d){O(c)&&O(d)?b.T(c.search(new RegExp(Za(d),"i"))):b.T(-1)};e.prototype.left=function(b,c,d){b.Ra(O(c)?c.substr(0,d):"")};e.prototype.right=function(b,c,d){b.Ra(O(c)?c.substr(c.length-d):"")};e.prototype.replace=function(b,c,d,e){O(c)&&O(d)&&O(e)?b.Ra(c.replace(new RegExp(Za(d),"gi"),e)):b.Ra(O(c)?c:"")};e.prototype.trim=function(b,c){b.Ra(O(c)?c.trim():"")};e.prototype.gr=function(b){this.b.S?
b.Ra(this.b.S.name):b.Ra("")};e.prototype.ip=function(b){var c=P(Math.random()*(arguments.length-1));b.tn(arguments[c+1])};e.prototype.Gi=function(b){b.n(this.b.Gi/1E3)};e.prototype.Xe=function(b){b.n(this.b.Xe)};m.hb=new e;m.Pr=function(){var b,c,e,n,a,l,m=this.b.jb();b=0;for(e=this.sb.length;b<e;b++){n=this.sb[b];if(-1===n.time){if(!n.yn)continue}else if(n.time>this.b.Qb.U)continue;m.ec=n.Ff;m.Eb=n.Eb;m.Ya=0;for(c in n.qb)n.qb.hasOwnProperty(c)&&(a=this.b.j[parseInt(c,10)].W(),l=n.qb[c],a.Y=l.mn,
ya(a.c,l.me),a=l,a.me.length=0,d.push(a));n.Ff.Or();this.b.Di(n.ka);n.pl=!0}c=b=0;for(e=this.sb.length;b<e;b++)n=this.sb[b],this.sb[c]=n,n.pl?(Ua(n.qb),n.ka.length=0,s.push(n)):c++;this.sb.length=c}})();
(function(){ib=function(k,e){var m=k[1],s=k[3],d=k[4],b=k[5],c=k[6],w=k[7],n=k[8];e.e||(e.e={});e.Aa||(e.Aa={});e.hb||(e.hb={});var a=e.e,l=e.Aa,p=e.hb;s&&(a.Cs=function(a,b){return Wb(this.x,a,b)},a.Ds=function(a,b){return Wb(this.y,a,b)},a.Js=function(){var a=this.g;this.Ta();var b=this.Ua;return!(b.right<a.na||b.bottom<a.pa||b.left>a.Ha||b.top>a.Ga)},a.Ks=function(){this.Ta();var a=this.Ua,b=this.b.S;return 0>a.right||0>a.bottom||a.left>b.width||a.top>b.height},a.Vs=function(a,b,c){var d=this.W(),
f=d.fc();if(!f.length)return!1;var e=f[0],l=e,n=Ra(e.x,e.y,b,c),m,p,k;m=1;for(p=f.length;m<p;m++)if(e=f[m],k=Ra(e.x,e.y,b,c),0===a&&k<n||1===a&&k>n)n=k,l=e;d.rg(l);return!0},l.ot=function(a){this.x!==a&&(this.x=a,this.ya())},l.pt=function(a){this.y!==a&&(this.y=a,this.ya())},l.jt=function(a,b){if(this.x!==a||this.y!==b)this.x=a,this.y=b,this.ya()},l.kt=function(a,b){var c=a.xq(this);if(c){var d;c.aj?(d=c.aj(b,!0),c=c.aj(b,!1)):(d=c.x,c=c.y);if(this.x!==d||this.y!==c)this.x=d,this.y=c,this.ya()}},
l.Os=function(a){0!==a&&(this.x+=Math.cos(this.k)*a,this.y+=Math.sin(this.k)*a,this.ya())},l.Ns=function(a,b){0!==b&&(this.x+=Math.cos(T(a))*b,this.y+=Math.sin(T(a))*b,this.ya())},p.Qo=function(a){a.n(this.x)},p.Ro=function(a){a.n(this.y)},p.be=function(a){a.n(this.b.Dl(this))});d&&(a.Bs=function(a,b){return Wb(this.width,a,b)},a.zs=function(a,b){return Wb(this.height,a,b)},l.nt=function(a){this.width!==a&&(this.width=a,this.ya())},l.ht=function(a){this.height!==a&&(this.height=a,this.ya())},l.lt=
function(a,b){if(this.width!==a||this.height!==b)this.width=a,this.height=b,this.ya()},p.wt=function(a){a.n(this.width)},p.Fs=function(a){a.n(this.height)},p.ws=function(a){this.Ta();a.n(this.Ua.left)},p.ys=function(a){this.Ta();a.n(this.Ua.top)},p.xs=function(a){this.Ta();a.n(this.Ua.right)},p.vs=function(a){this.Ta();a.n(this.Ua.bottom)});b&&(a.Yn=function(a,b){return Ja(this.k,T(b))<=T(a)},a.mo=function(a){return Pa(this.k,T(a))},a.lo=function(a,b){var c=Ha(a),d=Ha(b),f=Ea(this.k);return Pa(d,
c)?Pa(f,c)&&!Pa(f,d):!(!Pa(f,c)&&Pa(f,d))},l.dt=function(a){a=T(Da(a));isNaN(a)||this.k===a||(this.k=a,this.ya())},l.Zs=function(a){0===a||isNaN(a)||(this.k+=T(a),this.k=Ea(this.k),this.ya())},l.$s=function(a){0===a||isNaN(a)||(this.k-=T(a),this.k=Ea(this.k),this.ya())},l.bt=function(a,b){var c=Oa(this.k,T(b),T(a));isNaN(c)||this.k===c||(this.k=c,this.ya())},l.ct=function(a,b,c){a=Oa(this.k,Math.atan2(c-this.y,b-this.x),T(a));isNaN(a)||this.k===a||(this.k=a,this.ya())},l.mt=function(a,b){var c=Math.atan2(b-
this.y,a-this.x);isNaN(c)||this.k===c||(this.k=c,this.ya())},p.us=function(a){a.n(Ga(this.k))});m||(a.eo=function(a,b,c){return Wb(this.ra[a],b,c)},a.Hs=function(a){return this.ra[a]},a.Ws=function(a,b){var c=this.W(),d=c.fc();if(!d.length)return!1;var f=d[0],e=f,l=f.ra[b],n,m,p;n=1;for(m=d.length;n<m;n++)if(f=d[n],p=f.ra[b],0===a&&p<l||1===a&&p>l)l=p,e=f;c.rg(e);return!0},a.Us=function(a){var b,c,d,f,e;if(this.b.rq().rj){e=this.W();if(e.Y)for(e.Y=!1,e.c.length=0,e.L.length=0,d=this.c,b=0,c=d.length;b<
c;b++)f=d[b],f.uid===a?e.L.push(f):e.c.push(f);else{d=b=0;for(c=e.c.length;b<c;b++)f=e.c[b],e.c[d]=f,f.uid===a?e.L.push(f):d++;e.c.length=d}this.ud();return!!e.c.length}f=this.b.lh(a);if(!f)return!1;e=this.W();if(!e.Y&&-1===e.c.indexOf(f))return!1;if(this.K)for(a=f.type.Z,b=0,c=a.length;b<c;b++){if(a[b]===this)return e.rg(f),this.ud(),!0}else if(f.type===this)return e.rg(f),this.ud(),!0;return!1},a.Lg=function(){return!0},a.uo=function(){return!0},l.Lo=function(a,b){var c=this.ra;ha(c[a])?c[a]=ha(b)?
b:parseFloat(b):O(c[a])&&(c[a]=O(b)?b:b.toString())},l.ts=function(a,b){var c=this.ra;ha(c[a])?c[a]=ha(b)?c[a]+b:c[a]+parseFloat(b):O(c[a])&&(c[a]=O(b)?c[a]+b:c[a]+b.toString())},l.qt=function(a,b){var c=this.ra;ha(c[a])&&(c[a]=ha(b)?c[a]-b:c[a]-parseFloat(b))},l.et=function(a,b){this.ra[a]=b?1:0},l.tt=function(a){this.ra[a]=1-this.ra[a]},l.io=function(){this.b.Td(this)},l.qo||(l.qo=function(a){var b,c;try{b=JSON.parse(a)}catch(d){return}this.b.Ch(this,b,!0);this.td&&this.td();if(this.C)for(a=0,b=
this.C.length;a<b;++a)c=this.C[a],c.td&&c.td()}),p.Es=function(a){var b=a.xe.c.length,c,d,f;c=0;for(d=this.b.xc.length;c<d;c++)f=this.b.xc[c],a.xe.K?0<=f.type.Z.indexOf(a.xe)&&b++:f.type===a.xe&&b++;a.T(b)},p.Ys=function(a){a.T(a.xe.W().fc().length)},p.ut=function(a){a.T(this.uid)},p.Gs=function(a){a.T(this.Lf())},p.Zn||(p.Zn=function(a){a.Ra(JSON.stringify(this.b.jk(this,!0)))}));c&&(a.oo=function(){return this.visible},l.No=function(a){!a!==!this.visible&&(this.visible=a,this.b.X=!0)},a.As=function(a,
b){return Wb(eb(100*this.opacity),a,b)},l.it=function(a){a/=100;0>a?a=0:1<a&&(a=1);a!==this.opacity&&(this.opacity=a,this.b.X=!0)},p.Opacity=function(a){a.n(eb(100*this.opacity))});w&&(a.Is=function(a){return a?this.g===a:!1},a.Xs=function(a){var b=this.W(),c=b.fc();if(!c.length)return!1;var d=c[0],f=d,e,l;e=1;for(l=c.length;e<l;e++)if(d=c[e],0===a){if(d.g.index>f.g.index||d.g.index===f.g.index&&d.Bc()>f.Bc())f=d}else if(d.g.index<f.g.index||d.g.index===f.g.index&&d.Bc()<f.Bc())f=d;b.rg(f);return!0},
l.Rs=function(){var a=this.g,b=a.c;b.length&&b[b.length-1]===this||(a.hf(this,!1),a.wf(this,!1),this.b.X=!0)},l.Ps=function(){var a=this.g,b=a.c;b.length&&b[0]===this||(a.hf(this,!1),a.Gr(this),this.b.X=!0)},l.Qs=function(a){a&&a!=this.g&&(this.g.hf(this,!0),this.g=a,a.wf(this,!0),this.b.X=!0)},l.yt=function(a,b){var c=0===a;if(b){var d=b.sq(this);d&&d.uid!==this.uid&&(this.g.index!==d.g.index&&(this.g.hf(this,!0),this.g=d.g,d.g.wf(this,!0)),this.g.nr(this,d,c),this.b.X=!0)}},p.Ms=function(a){a.T(this.g.Em)},
p.Ls=function(a){a.Ra(this.g.name)},p.xt=function(a){a.T(this.Bc())});n&&(l.ft=function(a,b){if(this.b.q){var c=this.type.$i(b);if(!(0>c)){var d=1===a;this.sd[c]!==d&&(this.sd[c]=d,this.nd(),this.b.X=!0)}}},l.gt=function(a,b,c){if(this.b.q){var d=this.type.$i(a);0>d||(a=this.type.A[d],d=this.ba[d],b=Math.floor(b),0>b||b>=d.length||(1===this.b.q.Bq(a.Na,b)&&(c/=100),d[b]!==c&&(d[b]=c,a.wb&&(this.b.X=!0))))}})};Cb=function(){this.yi=this.si=!0;this.type.Yk=!0;this.b.X=!0;var k,e,m=this.ti;k=0;for(e=
m.length;k<e;++k)m[k](this);this.g.pc&&this.Ta()};Db=function(k){k&&this.ti.push(k)};Fb=function(){if(this.si){var k=this.Ua,e=this.Ng;k.set(this.x,this.y,this.x+this.width,this.y+this.height);k.offset(-this.lb*this.width,-this.mb*this.height);this.k?(k.offset(-this.x,-this.y),e.un(k,this.k),e.offset(this.x,this.y),e.fl(k)):e.Yh(k);k.normalize();this.si=!1;this.os()}};var k=new R(0,0,0,0);Gb=function(){if(this.g.pc){var q=this.g.pb,e=this.Ua;k.set(q.tb(e.left),q.ub(e.top),q.tb(e.right),q.ub(e.bottom));
this.Za.ah(k)||(this.Za.right<this.Za.left?q.update(this,null,k):q.update(this,this.Za,k),this.Za.Sg(k),this.g.gd=!0)}};Hb=function(){if(this.yi&&this.yd){this.Ta();var q=this.type.Ei,e=this.Ua;k.set(q.tb(e.left),q.ub(e.top),q.tb(e.right),q.ub(e.bottom));this.Fb.ah(k)||(this.Fb.right<this.Fb.left?q.update(this,null,k):q.update(this,this.Fb,k),this.Fb.Sg(k),this.yi=!1)}};Eb=function(k,e){return this.Ua.Hb(k,e)&&this.Ng.Hb(k,e)?this.wc&&!this.wc.dr()?(this.wc.fp(this.width,this.height,this.k),this.wc.Hb(k-
this.x,e-this.y)):!0:!1};yb=function(){this.type.ii();return this.ke};Ib=function(){this.g.Bk();return this.qc};Jb=function(){this.N.length=0;var k,e;k=0;for(e=this.sd.length;k<e;k++)this.sd[k]&&this.N.push(this.type.A[k]);this.Un=!!this.N.length};zb=function(){return"Inst"+this.en};lb=function(k){if(k&&k.Ab&&k.type!=this){var e,m,s;e=0;for(m=k.siblings.length;e<m;e++)if(s=k.siblings[e],s.type==this)return s}k=this.W().fc();return k.length?k[0]:null};mb=function(k){var e=this.W().fc();return e.length?
e[k.Lf()%e.length]:null};kb=function(){if(this.nf&&!this.K){var k,e;k=0;for(e=this.c.length;k<e;k++)this.c[k].ke=k;var m=k,s=this.b.xc;k=0;for(e=s.length;k<e;++k)s[k].type===this&&(s[k].ke=m++);this.nf=!1}};wb=function(k){if(k<this.c.length)return this.c[k];k-=this.c.length;var e=this.b.xc,m,s;m=0;for(s=e.length;m<s;++m)if(e[m].type===this){if(0===k)return e[m];--k}return null};nb=function(){return this.Od[this.Wc]};pb=function(){this.Wc++;this.Wc===this.Od.length?this.Od.push(new jb(this)):this.Od[this.Wc].Y=
!0};qb=function(){this.Wc++;this.Wc===this.Od.length&&this.Od.push(new jb(this));var k=this.Od[this.Wc],e=this.Od[this.Wc-1];e.Y?k.Y=!0:(k.Y=!1,ya(k.c,e.c),ya(k.L,e.L))};rb=function(){this.Wc--};sb=function(k){var e,m,s,d,b,c=0;if(!this.K)for(e=0,m=this.Z.length;e<m;e++)for(b=this.Z[e],s=0,d=b.la.length;s<d;s++){if(k===b.la[s].name)return this.ea.lastBehIndex=c,b.la[s];c++}e=0;for(m=this.la.length;e<m;e++){if(k===this.la[e].name)return this.ea.lastBehIndex=c,this.la[e];c++}return null};tb=function(k){return this.jh(k)?
this.ea.lastBehIndex:-1};ub=function(k){var e,m;e=0;for(m=this.A.length;e<m;e++)if(this.A[e].name===k)return e;return-1};vb=function(){if(this.Ab&&!this.K){var k,e,m,s,d,b,c;this.ii();b=this.W();var w=b.Y,n=(k=this.b.jb())&&k.ec&&k.ec.Fc;k=0;for(e=this.gb.length;k<e;k++)if(d=this.gb[k],d!==this&&(d.ii(),c=d.W(),c.Y=w,!w)){c.c.length=b.c.length;m=0;for(s=b.c.length;m<s;m++)c.c[m]=d.Fl(b.c[m].ke);if(n)for(c.L.length=b.L.length,m=0,s=b.L.length;m<s;m++)c.L[m]=d.Fl(b.L[m].ke)}}};xb=function(){return"Type"+
this.I};Wb=function(k,e,m){if("undefined"===typeof k||"undefined"===typeof m)return!1;switch(e){case 0:return k===m;case 1:return k!==m;case 2:return k<m;case 3:return k<=m;case 4:return k>m;case 5:return k>=m;default:return!1}}})();var dc={};function hc(k){this.b=k}
(function(){function k(a){0>a&&(a=0);1<a&&(a=1);return Math.log(a)/Math.log(10)*20}function q(a){a=a.toLowerCase();return Q.hasOwnProperty(a)&&Q[a].length?Q[a][0].yb():t.destination}function e(){return t.createGain?t.createGain():t.createGainNode()}function m(a){return t.createDelay?t.createDelay(a):t.createDelayNode(a)}function s(a){a.start?a.start(0):a.noteOn(0)}function d(a,b,c){a.start?a.start(0,b):a.noteGrainOn(0,b,c-b)}function b(a){try{a.stop?a.stop(0):a.noteOff(0)}catch(b){}}function c(a,
b,c,d,f,g){this.type="filter";this.La=[a,b,c,d,f,g];this.J=e();this.u=e();this.u.gain.value=g;this.p=e();this.p.gain.value=1-g;this.ma=t.createBiquadFilter();this.ma.type="number"===typeof this.ma.type?a:kc[a];this.ma.frequency.value=b;this.ma.detune&&(this.ma.detune.value=c);this.ma.Q.value=d;this.ma.gain.value=f;this.J.connect(this.ma);this.J.connect(this.p);this.ma.connect(this.u)}function w(a,b,c){this.type="delay";this.La=[a,b,c];this.J=e();this.u=e();this.u.gain.value=c;this.p=e();this.p.gain.value=
1-c;this.jg=e();this.Lb=m(a);this.Lb.delayTime.value=a;this.Zg=e();this.Zg.gain.value=b;this.J.connect(this.jg);this.J.connect(this.p);this.jg.connect(this.u);this.jg.connect(this.Lb);this.Lb.connect(this.Zg);this.Zg.connect(this.jg)}function n(a,b,c,d){this.type="convolve";this.La=[b,c,d];this.J=e();this.u=e();this.u.gain.value=c;this.p=e();this.p.gain.value=1-c;this.Yd=t.createConvolver();a&&(this.Yd.normalize=b,this.Yd.buffer=a);this.J.connect(this.Yd);this.J.connect(this.p);this.Yd.connect(this.u)}
function a(a,b,c,d,f){this.type="flanger";this.La=[a,b,c,d,f];this.J=e();this.p=e();this.p.gain.value=1-f/2;this.u=e();this.u.gain.value=f/2;this.fh=e();this.fh.gain.value=d;this.Lb=m(a+b);this.Lb.delayTime.value=a;this.Ea=t.createOscillator();this.Ea.frequency.value=c;this.ob=e();this.ob.gain.value=b;this.J.connect(this.Lb);this.J.connect(this.p);this.Lb.connect(this.u);this.Lb.connect(this.fh);this.fh.connect(this.Lb);this.Ea.connect(this.ob);this.ob.connect(this.Lb.delayTime);s(this.Ea)}function l(a,
b,c,d,f,g){this.type="phaser";this.La=[a,b,c,d,f,g];this.J=e();this.p=e();this.p.gain.value=1-g/2;this.u=e();this.u.gain.value=g/2;this.ma=t.createBiquadFilter();this.ma.type="number"===typeof this.ma.type?7:"allpass";this.ma.frequency.value=a;this.ma.detune&&(this.ma.detune.value=b);this.ma.Q.value=c;this.Ea=t.createOscillator();this.Ea.frequency.value=f;this.ob=e();this.ob.gain.value=d;this.J.connect(this.ma);this.J.connect(this.p);this.ma.connect(this.u);this.Ea.connect(this.ob);this.ob.connect(this.ma.frequency);
s(this.Ea)}function p(a){this.type="gain";this.La=[a];this.M=e();this.M.gain.value=a}function g(a,b){this.type="tremolo";this.La=[a,b];this.M=e();this.M.gain.value=1-b/2;this.Ea=t.createOscillator();this.Ea.frequency.value=a;this.ob=e();this.ob.gain.value=b/2;this.Ea.connect(this.ob);this.ob.connect(this.M.gain);s(this.Ea)}function x(a,b){this.type="ringmod";this.La=[a,b];this.J=e();this.u=e();this.u.gain.value=b;this.p=e();this.p.gain.value=1-b;this.vg=e();this.vg.gain.value=0;this.Ea=t.createOscillator();
this.Ea.frequency.value=a;this.Ea.connect(this.vg.gain);s(this.Ea);this.J.connect(this.vg);this.J.connect(this.p);this.vg.connect(this.u)}function v(a,b,c,d,f){this.type="distortion";this.La=[a,b,c,d,f];this.J=e();this.Qh=e();this.Ph=e();this.Wr(c,Math.pow(10,d/20));this.u=e();this.u.gain.value=f;this.p=e();this.p.gain.value=1-f;this.ji=t.createWaveShaper();this.Xg=new Float32Array(65536);this.oq(a,b);this.ji.Xg=this.Xg;this.J.connect(this.Qh);this.J.connect(this.p);this.Qh.connect(this.ji);this.ji.connect(this.Ph);
this.Ph.connect(this.u)}function h(a,b,c,d,f){this.type="compressor";this.La=[a,b,c,d,f];this.M=t.createDynamicsCompressor();try{this.M.threshold.value=a,this.M.knee.value=b,this.M.ratio.value=c,this.M.attack.value=d,this.M.release.value=f}catch(e){}}function f(a,b){this.type="analyser";this.La=[a,b];this.M=t.createAnalyser();this.M.fftSize=a;this.M.smoothingTimeConstant=b;this.mq=new Float32Array(this.M.frequencyBinCount);this.xn=new Uint8Array(a);this.qg=0}function r(){this.r=null;this.Eh=0;this.Pd=
[];this.Kj=this.wh=this.vh=0}function u(a,b){this.src=a;this.B=G;this.jc=b;this.Vk=!1;var c=this;this.Ij=this.Uj=null;this.df=[];this.Vh=0;this.Fk=this.Ri=this.Cn=this.Mh=!1;1===G&&b&&(this.B=0,this.Uj=e());this.Wd=this.O=null;var d;switch(this.B){case 0:this.O=new Audio;this.O.addEventListener("canplaythrough",function(){c.Fk=!0});1===G&&t.createMediaElementSource&&!/wiiu/i.test(navigator.userAgent)&&(this.Cn=!0,this.O.addEventListener("canplay",function(){c.Ij||(c.Ij=t.createMediaElementSource(c.O),
c.Ij.connect(c.Uj))}));this.O.autoplay=!1;this.O.Ht="auto";this.O.src=a;break;case 1:d=new XMLHttpRequest;d.open("GET",a,!0);d.responseType="arraybuffer";d.onload=function(){c.Wd=d.response;c.op()};d.onerror=function(){c.Ri=!0};d.send();break;case 2:this.O=!0;break;case 3:this.O=!0}}function y(a,b){var c=this;this.tag=b;this.rb=this.Ac=!0;this.src=a.src;this.buffer=a;this.B=G;this.jc=a.jc;this.playbackRate=1;this.Fi=!0;this.Pb=this.hd=!1;this.$a=0;this.Vf=this.Se=this.Ec=!1;this.volume=1;this.pe=
1===E&&!this.jc||2===E;this.$e=1;this.startTime=this.pe?z.Qb.U:z.Qc.U;this.ga=this.qa=null;this.Gc=!1;this.fa=null;this.Tm=this.Sm=this.Rm=this.Qm=this.Vm=this.Um=0;this.d=null;var d=!1;1!==this.B||0!==this.buffer.B||this.buffer.Cn||(this.B=0);switch(this.B){case 0:this.jc?(this.d=a.O,d=!a.Vk,a.Vk=!0):(this.d=new Audio,this.d.autoplay=!1,this.d.src=a.O.src,d=!0);d&&this.d.addEventListener("ended",function(){ta=c.tag;c.rb=!0;z.trigger(hc.prototype.e.li,I)});break;case 1:this.qa=e();this.qa.connect(q(b));
1===this.buffer.B?a.O&&(this.d=t.createBufferSource(),this.d.buffer=a.O,this.d.connect(this.qa)):(this.d=this.buffer.O,this.buffer.Uj.connect(this.qa));break;case 2:this.d=new window.Media(W+this.src,null,null,function(a){a===window.Media.MEDIA_STOPPED&&(c.Fi=!0,c.rb=!0,ta=c.tag,z.trigger(hc.prototype.e.li,I))});break;case 3:this.d=!0}}function B(a,b){Q.hasOwnProperty(a)?Q[a].push(b):Q[a]=[b];var c,d,f,e,g=t.destination;if(Q.hasOwnProperty(a)&&(f=Q[a],f.length))for(g=f[0].yb(),c=0,d=f.length;c<d;c++)e=
f[c],c+1===d?e.Gb(t.destination):e.Gb(f[c+1].yb());Fa.length=0;if(a.length)for(c=0,d=F.length;c<d;c++)f=F[c],fb(a,f.tag)&&Fa.push(f);else N&&!N.je()&&(Fa.length=1,Fa[0]=N);c=0;for(d=Fa.length;c<d;c++)Fa[c].Kr(g);aa&&ob===a&&(aa.disconnect(),aa.connect(g))}function A(){}function S(){}var X=hc.prototype;X.Zb=function(a){this.ha=a;this.b=a.b};X.Zb.prototype.ua=function(){};var z=null,I=null,ta="",W="",G=0,t=null,ua=[],F=[],N=null,D=!1,E=0,M=!1,C=1,J=0,H=0,ka=1,L=1,na=10,ea=1E4,pa=1,aa=null,ob="",Ka=
!1,La=[],Q={},kc="lowpass highpass bandpass lowshelf highshelf peaking notch allpass".split(" ");c.prototype.Gb=function(a){this.u.disconnect();this.u.connect(a);this.p.disconnect();this.p.connect(a)};c.prototype.remove=function(){this.J.disconnect();this.ma.disconnect();this.u.disconnect();this.p.disconnect()};c.prototype.yb=function(){return this.J};w.prototype.Gb=function(a){this.u.disconnect();this.u.connect(a);this.p.disconnect();this.p.connect(a)};w.prototype.remove=function(){this.J.disconnect();
this.jg.disconnect();this.Lb.disconnect();this.Zg.disconnect();this.u.disconnect();this.p.disconnect()};w.prototype.yb=function(){return this.J};n.prototype.Gb=function(a){this.u.disconnect();this.u.connect(a);this.p.disconnect();this.p.connect(a)};n.prototype.remove=function(){this.J.disconnect();this.Yd.disconnect();this.u.disconnect();this.p.disconnect()};n.prototype.yb=function(){return this.J};a.prototype.Gb=function(a){this.p.disconnect();this.p.connect(a);this.u.disconnect();this.u.connect(a)};
a.prototype.remove=function(){this.J.disconnect();this.Lb.disconnect();this.Ea.disconnect();this.ob.disconnect();this.p.disconnect();this.u.disconnect();this.fh.disconnect()};a.prototype.yb=function(){return this.J};l.prototype.Gb=function(a){this.p.disconnect();this.p.connect(a);this.u.disconnect();this.u.connect(a)};l.prototype.remove=function(){this.J.disconnect();this.ma.disconnect();this.Ea.disconnect();this.ob.disconnect();this.p.disconnect();this.u.disconnect()};l.prototype.yb=function(){return this.J};
p.prototype.Gb=function(a){this.M.disconnect();this.M.connect(a)};p.prototype.remove=function(){this.M.disconnect()};p.prototype.yb=function(){return this.M};g.prototype.Gb=function(a){this.M.disconnect();this.M.connect(a)};g.prototype.remove=function(){this.Ea.disconnect();this.ob.disconnect();this.M.disconnect()};g.prototype.yb=function(){return this.M};x.prototype.Gb=function(a){this.u.disconnect();this.u.connect(a);this.p.disconnect();this.p.connect(a)};x.prototype.remove=function(){this.Ea.disconnect();
this.vg.disconnect();this.J.disconnect();this.u.disconnect();this.p.disconnect()};x.prototype.yb=function(){return this.J};v.prototype.Wr=function(a,b){.01>a&&(a=.01);this.Qh.gain.value=a;this.Ph.gain.value=Math.pow(1/a,.6)*b};v.prototype.shape=function(a,b,c){var d=1.05*c*b-b;c=0>a?-1:1;a=0>a?-a:a;b=a<b?a:b+d*(1-Math.exp(-(1/d)*(a-b)));return b*c};v.prototype.oq=function(a,b){for(var c=Math.pow(10,a/20),d=Math.pow(10,b/20),f=0,e=0;32768>e;++e)f=e/32768,f=this.shape(f,c,d),this.Xg[32768+e]=f,this.Xg[32768-
e-1]=-f};v.prototype.Gb=function(a){this.u.disconnect();this.u.connect(a);this.p.disconnect();this.p.connect(a)};v.prototype.remove=function(){this.J.disconnect();this.Qh.disconnect();this.ji.disconnect();this.Ph.disconnect();this.u.disconnect();this.p.disconnect()};v.prototype.yb=function(){return this.J};h.prototype.Gb=function(a){this.M.disconnect();this.M.connect(a)};h.prototype.remove=function(){this.M.disconnect()};h.prototype.yb=function(){return this.M};f.prototype.bb=function(){this.M.getFloatFrequencyData(this.mq);
this.M.getByteTimeDomainData(this.xn);for(var a=this.M.fftSize,b=0,c=this.qg=0,d=0;b<a;b++)d=(this.xn[b]-128)/128,0>d&&(d=-d),this.qg<d&&(this.qg=d),c+=d*d;this.qg=k(this.qg);k(Math.sqrt(c/a))};f.prototype.Gb=function(a){this.M.disconnect();this.M.connect(a)};f.prototype.remove=function(){this.M.disconnect()};f.prototype.yb=function(){return this.M};r.prototype.wg=function(a){if(this.r=a)this.vh=this.r.x,this.wh=this.r.y;this.Pd.length=0};r.prototype.nh=function(){return!!this.r};r.prototype.bb=function(a){this.r&&
0!==a&&(this.Kj=Ia(this.vh,this.wh,this.r.x,this.r.y),a=Ra(this.vh,this.wh,this.r.x,this.r.y)/a,4>this.Pd.length||this.Pd.shift(),this.Pd.push(a),this.vh=this.r.x,this.wh=this.r.y)};r.prototype.Jl=function(){if(!this.Pd.length)return 0;var a,b,c=0;a=0;for(b=this.Pd.length;a<b;a++)c+=this.Pd[a];return c/this.Pd.length};r.prototype.ej=function(){return Math.cos(this.Kj)*this.Jl()};r.prototype.fj=function(){return Math.sin(this.Kj)*this.Jl()};var jc=!1;u.prototype.op=function(){if(!this.O&&this.Wd){var a=
this;if(t.decodeAudioData)t.decodeAudioData(this.Wd,function(b){a.O=b;a.Wd=null;var c,d,f;if(ga(a.Nh)||M)ga(a.Rg)||(c=a.Rg.Yd,c.normalize=a.Dm,c.buffer=b);else if(a.df.length){c=0;for(d=a.df.length;c<d;c++){b=a.df[c];f=new y(a,b.Gn);f.mk(!0);if("undefined"!==typeof b.Fm&&(b.r=z.lh(b.Fm),!b.r))continue;if(b.r){var e=Qa(b.r.x,b.r.y,-b.r.g.Ba(),J,H,!0),g=Qa(b.r.x,b.r.y,-b.r.g.Ba(),J,H,!1);f.lk(e,g,Ca(b.r.k-b.r.g.Ba()),b.kj,b.Mj,b.Pj);f.wg(b.r)}else f.lk(b.x,b.y,b.So,b.kj,b.Mj,b.Pj);f.play(a.Gj,a.Ek,
a.Vh);a.Mh&&f.pause();F.push(f)}a.df.length=0}else f=new y(a,a.Nh),f.play(a.Gj,a.Ek,a.Vh),a.Mh&&f.pause(),F.push(f)},function(){a.Ri=!0});else if(this.O=t.createBuffer(this.Wd,!1),this.Wd=null,ga(this.Nh)||M)ga(this.Rg)||(b=this.Rg.Yd,b.normalize=this.Dm,b.buffer=this.O);else{var b=new y(this,this.Nh);b.play(this.Gj,this.Ek,this.Vh);this.Mh&&b.pause();F.push(b)}}};u.prototype.Sl=function(){switch(this.B){case 0:var a=4<=this.O.readyState;a&&(this.Fk=!0);return a||this.Fk;case 1:return!!this.Wd||!!this.O;
case 2:return!0;case 3:return!0}return!1};u.prototype.Zq=function(){switch(this.B){case 0:return this.Sl();case 1:return!!this.O;case 2:return!0;case 3:return!0}return!1};u.prototype.Sq=function(){switch(this.B){case 0:return!!this.O.error;case 1:return this.Ri}return!1};y.prototype.je=function(){var a;switch(this.B){case 0:return this.d.ended;case 1:if(1===this.buffer.B){if(!this.Ac&&!this.rb&&this.d.loop||this.Pb)return!1;a=this.pe?z.Qb.U:z.Qc.U;var b=this.playbackRate;0===b&&(b=1E-6);return a-
this.startTime>this.buffer.O.duration/b}return this.d.ended;case 2:return this.Fi;case 3:!0}return!0};y.prototype.gp=function(){return this.Ac||this.rb?!0:this.je()};y.prototype.mk=function(a){1===G&&(!this.Gc&&a?this.qa&&(this.ga||(this.ga=t.createPanner(),this.ga.panningModel="number"===typeof this.ga.panningModel?ka:["equalpower","HRTF","soundfield"][ka],this.ga.distanceModel="number"===typeof this.ga.distanceModel?L:["linear","inverse","exponential"][L],this.ga.refDistance=na,this.ga.maxDistance=
ea,this.ga.rolloffFactor=pa),this.qa.disconnect(),this.qa.connect(this.ga),this.ga.connect(q(this.tag)),this.Gc=!0):this.Gc&&!a&&this.qa&&(this.ga.disconnect(),this.qa.disconnect(),this.qa.connect(q(this.tag)),this.Gc=!1))};y.prototype.lk=function(a,b,c,d,f,e){this.Gc&&1===G&&(this.ga.setPosition(a,b,0),this.ga.setOrientation(Math.cos(T(c)),Math.sin(T(c)),0),this.ga.coneInnerAngle=d,this.ga.coneOuterAngle=f,this.ga.coneOuterGain=e,this.Um=a,this.Vm=b,this.Qm=c,this.Rm=d,this.Sm=f,this.Tm=e)};y.prototype.wg=
function(a){this.Gc&&1===G&&(this.fa||(this.fa=new r),this.fa.wg(a))};y.prototype.bb=function(a){if(this.Gc&&1===G&&this.fa&&this.fa.nh()&&this.Oe()){this.fa.bb(a);a=this.fa.r;var b=Qa(a.x,a.y,-a.g.Ba(),J,H,!0),c=Qa(a.x,a.y,-a.g.Ba(),J,H,!1);this.ga.setPosition(b,c,0);b=0;"undefined"!==typeof this.fa.r.k&&(b=a.k-a.g.Ba(),this.ga.setOrientation(Math.cos(b),Math.sin(b),0));b=Qa(this.fa.ej(),this.fa.fj(),-a.g.Ba(),0,0,!0);c=Qa(this.fa.ej(),this.fa.fj(),-a.g.Ba(),0,0,!1);this.ga.setVelocity(b,c,0)}};
y.prototype.play=function(a,b,c){var f=this.d;this.Ec=a;this.volume=b;c=c||0;switch(this.B){case 0:1!==f.playbackRate&&(f.playbackRate=1);f.volume!==b*C&&(f.volume=b*C);f.loop!==a&&(f.loop=a);f.muted&&(f.muted=!1);if(f.currentTime!==c)try{f.currentTime=c}catch(e){}if(this.jc&&Ka&&!z.Dc)La.push(this);else try{this.d.play()}catch(g){console&&console.log&&console.log("[C2] WARNING: exception trying to play audio '"+this.buffer.src+"': ",g)}break;case 1:this.muted=!1;this.$e=1;if(1===this.buffer.B)this.qa.gain.value=
b*C,this.Ac||(this.d=t.createBufferSource(),this.d.buffer=this.buffer.O,this.d.connect(this.qa)),this.d.loop=a,0===c?s(this.d):d(this.d,c,this.he());else{1!==f.playbackRate&&(f.playbackRate=1);f.loop!==a&&(f.loop=a);f.volume=b*C;if(f.currentTime!==c)try{f.currentTime=c}catch(l){}this.jc&&Ka&&!z.Dc?La.push(this):f.play()}break;case 2:(!this.Ac&&this.rb||0!==c)&&f.seekTo(c);f.play();this.Fi=!1;break;case 3:z.Ja?AppMobi.context.playSound(this.src,a):AppMobi.player.playSound(this.src,a)}this.playbackRate=
1;this.startTime=(this.pe?z.Qb.U:z.Qc.U)-c;this.Pb=this.rb=this.Ac=!1};y.prototype.stop=function(){switch(this.B){case 0:this.d.paused||this.d.pause();break;case 1:1===this.buffer.B?b(this.d):this.d.paused||this.d.pause();break;case 2:this.d.stop();break;case 3:z.Ja&&AppMobi.context.stopSound(this.src)}this.rb=!0;this.Pb=!1};y.prototype.pause=function(){if(!(this.Ac||this.rb||this.je()||this.Pb)){switch(this.B){case 0:this.d.paused||this.d.pause();break;case 1:1===this.buffer.B?(this.$a=this.cj(),
this.Ec&&(this.$a%=this.he()),b(this.d)):this.d.paused||this.d.pause();break;case 2:this.d.pause();break;case 3:z.Ja&&AppMobi.context.stopSound(this.src)}this.Pb=!0}};y.prototype.Nr=function(){if(!(this.Ac||this.rb||this.je())&&this.Pb){switch(this.B){case 0:this.d.play();break;case 1:1===this.buffer.B?(this.d=t.createBufferSource(),this.d.buffer=this.buffer.O,this.d.connect(this.qa),this.d.loop=this.Ec,this.qa.gain.value=C*this.volume*this.$e,this.startTime=(this.pe?z.Qb.U:z.Qc.U)-this.$a,d(this.d,
this.$a,this.he())):this.d.play();break;case 2:this.d.play();break;case 3:z.Ja&&AppMobi.context.resumeSound(this.src)}this.Pb=!1}};y.prototype.seek=function(a){if(!(this.Ac||this.rb||this.je()))switch(this.B){case 0:try{this.d.currentTime=a}catch(b){}break;case 1:if(1===this.buffer.B)this.Pb?this.$a=a:(this.pause(),this.$a=a,this.Nr());else try{this.d.currentTime=a}catch(c){}break;case 3:z.Ja&&AppMobi.context.seekSound(this.src,a)}};y.prototype.Kr=function(a){1===this.B&&(this.Gc?(this.ga.disconnect(),
this.ga.connect(a)):(this.qa.disconnect(),this.qa.connect(a)))};y.prototype.he=function(){switch(this.B){case 0:if("undefined"!==typeof this.d.duration)return this.d.duration;break;case 1:return this.buffer.O.duration;case 2:return this.d.getDuration();case 3:if(z.Ja)return AppMobi.context.getDurationSound(this.src)}return 0};y.prototype.cj=function(){var a=this.he(),b=0;switch(this.B){case 0:"undefined"!==typeof this.d.currentTime&&(b=this.d.currentTime);break;case 1:if(1===this.buffer.B){if(this.Pb)return this.$a;
b=(this.pe?z.Qb.U:z.Qc.U)-this.startTime}else"undefined"!==typeof this.d.currentTime&&(b=this.d.currentTime);break;case 3:z.Ja&&(b=AppMobi.context.getPlaybackTimeSound(this.src))}!this.Ec&&b>a&&(b=a);return b};y.prototype.Oe=function(){return!this.Pb&&!this.Ac&&!this.rb&&!this.je()};y.prototype.ms=function(){var a=this.volume*C;switch(this.B){case 0:"undefined"!==typeof this.d.volume&&this.d.volume!==a&&(this.d.volume=a);break;case 1:1===this.buffer.B?this.qa.gain.value=a*this.$e:"undefined"!==typeof this.d.volume&&
this.d.volume!==a&&(this.d.volume=a)}};y.prototype.$g=function(a){switch(this.B){case 0:this.d.muted!==!!a&&(this.d.muted=!!a);break;case 1:1===this.buffer.B?(this.$e=a?0:1,this.qa.gain.value=C*this.volume*this.$e):this.d.muted!==!!a&&(this.d.muted=!!a)}};y.prototype.Yr=function(){this.Se=!0;this.$g(this.Se||this.Vf)};y.prototype.rn=function(a){this.Vf=!!a;this.$g(this.Se||this.Vf)};y.prototype.Tn=function(){var a=this.playbackRate;this.pe&&(a*=z.of);switch(this.B){case 0:this.d.playbackRate!==a&&
(this.d.playbackRate=a);break;case 1:1===this.buffer.B?this.d.playbackRate.value!==a&&(this.d.playbackRate.value=a):this.d.playbackRate!==a&&(this.d.playbackRate=a)}};y.prototype.$r=function(a){switch(this.B){case 0:a?this.Oe()?(this.d.pause(),this.hd=!0):this.hd=!1:this.hd&&this.d.play();break;case 1:a?this.Oe()?(1===this.buffer.B?(this.$a=this.cj(),this.Ec&&(this.$a%=this.he()),b(this.d)):this.d.pause(),this.hd=!0):this.hd=!1:this.hd&&(1===this.buffer.B?(this.d=t.createBufferSource(),this.d.buffer=
this.buffer.O,this.d.connect(this.qa),this.d.loop=this.Ec,this.qa.gain.value=C*this.volume*this.$e,this.startTime=(this.pe?z.Qb.U:z.Qc.U)-this.$a,d(this.d,this.$a,this.he())):this.d.play());break;case 2:a?this.Oe()?(this.d.pause(),this.hd=!0):this.hd=!1:this.hd&&this.d.play()}};X.cb=function(a){this.type=a;z=this.b=a.b;I=this;this.Va=null;this.ag=-600;!(this.b.uh||this.b.oh&&(this.b.Rf||this.b.ph))||this.b.Sf||this.b.ca||this.b.sj||(Ka=!0);t=null;"undefined"!==typeof AudioContext?(G=1,t=new AudioContext):
"undefined"!==typeof webkitAudioContext&&(G=1,t=new webkitAudioContext);(this.b.uh&&1===G||Ka)&&document.addEventListener("touchstart",function(){var a,b,c;!jc&&t&&(a=t.createBuffer(1,1,22050),b=t.createBufferSource(),b.buffer=a,b.connect(t.destination),s(b),jc=!0);if(Ka){if(!M)for(a=0,b=La.length;a<b;++a)c=La[a],c.rb||c.Pb||c.d.play();La.length=0}},!0);1!==G&&(this.b.Ob&&"undefined"!==typeof window.Media?G=2:this.b.Ne&&(G=3));2===G&&(W=location.href,a=W.lastIndexOf("/"),-1<a&&(W=W.substr(0,a+1)),
W=W.replace("file://",""));if(this.b.Tl&&this.b.$q&&"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.Td(this);else{if(this.b.Ja)D=this.b.oh;else try{D=!!(new Audio).canPlayType('audio/ogg; codecs="vorbis"')}catch(b){D=!1}this.b.sk(this)}};var la=X.cb.prototype;la.ua=function(){this.b.He=this;E=this.Ma[0];this.jd=this.Ma[1];this.Ar=0!==this.Ma[2];ka=this.Ma[3];L=this.Ma[4];this.ag=-this.Ma[5];
na=this.Ma[6];ea=this.Ma[7];pa=this.Ma[8];this.Va=new r;var a=this.b.H||this.b.width,b=this.b.G||this.b.height;1===G&&("undefined"!==typeof t.listener.dopplerFactor&&(t.listener.dopplerFactor=0),t.listener.setPosition(a/2,b/2,this.ag),t.listener.setOrientation(0,0,1,0,-1,0),window.c2OnAudioMicStream=function(a,b){aa&&aa.disconnect();ob=b.toLowerCase();aa=t.createMediaStreamSource(a);aa.connect(q(ob))});this.b.Uk(function(a){I.xr(a)});var c=this;this.b.Wo(function(a){c.rr(a)})};la.rr=function(a){var b,
c,d;b=0;for(c=F.length;b<c;b++)d=F[b],d.fa&&d.fa.r===a&&(d.fa.r=null,d.Gc&&d.Oe()&&d.Ec&&d.stop());this.Va.r===a&&(this.Va.r=null)};la.nc=function(){var a={silent:M,masterVolume:C,listenerZ:this.ag,listenerUid:this.Va.nh()?this.Va.r.uid:-1,playing:[],effects:{}},b=a.playing,c,d,f,e,g,l;c=0;for(d=F.length;c<d;c++)f=F[c],!f.Oe()||3===this.jd||f.jc&&1===this.jd||!f.jc&&2===this.jd||(e=f.cj(),f.Ec&&(e%=f.he()),e={tag:f.tag,buffersrc:f.buffer.src,is_music:f.jc,playbackTime:e,volume:f.volume,looping:f.Ec,
muted:f.Se,playbackRate:f.playbackRate,paused:f.Pb,resume_position:f.$a},f.Gc&&(e.pan={},l=e.pan,f.fa&&f.fa.nh()?l.objUid=f.fa.r.uid:(l.x=f.Um,l.y=f.Vm,l.a=f.Qm),l.ia=f.Rm,l.oa=f.Sm,l.og=f.Tm),b.push(e));b=a.effects;for(g in Q)if(Q.hasOwnProperty(g)){f=[];c=0;for(d=Q[g].length;c<d;c++)f.push({type:Q[g][c].type,params:Q[g][c].La});b[g]=f}return a};var Ma=[];la.bd=function(b){var d=b.silent;C=b.masterVolume;this.ag=b.listenerZ;this.Va.wg(null);var e=b.listenerUid;-1!==e&&(this.Va.Eh=e,Ma.push(this.Va));
var e=b.playing,k,m,u,q,s,y,I,z,A,t,S;if(3!==this.jd)for(k=0,m=F.length;k<m;k++)A=F[k],A.jc&&1===this.jd||(A.jc||2!==this.jd)&&A.stop();for(s in Q)if(Q.hasOwnProperty(s))for(k=0,m=Q[s].length;k<m;k++)Q[s][k].remove();Ua(Q);for(s in b.effects)if(b.effects.hasOwnProperty(s))for(y=b.effects[s],k=0,m=y.length;k<m;k++)switch(u=y[k].type,t=y[k].params,u){case "filter":B(s,new c(t[0],t[1],t[2],t[3],t[4],t[5]));break;case "delay":B(s,new w(t[0],t[1],t[2]));break;case "convolve":u=t[2];A=this.ih(u,!1);A.O?
u=new n(A.O,t[0],t[1],u):(u=new n(null,t[0],t[1],u),A.Dm=t[0],A.Rg=u);B(s,u);break;case "flanger":B(s,new a(t[0],t[1],t[2],t[3],t[4]));break;case "phaser":B(s,new l(t[0],t[1],t[2],t[3],t[4],t[5]));break;case "gain":B(s,new p(t[0]));break;case "tremolo":B(s,new g(t[0],t[1]));break;case "ringmod":B(s,new x(t[0],t[1]));break;case "distortion":B(s,new v(t[0],t[1],t[2],t[3],t[4]));break;case "compressor":B(s,new h(t[0],t[1],t[2],t[3],t[4]));break;case "analyser":B(s,new f(t[0],t[1]))}k=0;for(m=e.length;k<
m;k++)3===this.jd||(b=e[k],u=b.buffersrc,q=b.is_music,s=b.tag,y=b.playbackTime,I=b.looping,z=b.volume,S=(t=b.pan)&&t.hasOwnProperty("objUid")?t.objUid:-1,q&&1===this.jd)||!q&&2===this.jd||((A=this.Bl(u,s,q,I,z))?(A.$a=b.resume_position,A.mk(!!t),A.play(I,z,y),A.Tn(),A.ms(),A.$g(A.Se||A.Vf),b.paused&&A.pause(),b.muted&&A.Yr(),A.$g(A.Se||A.Vf),t&&(-1!==S?(A.fa=A.fa||new r,A.fa.Eh=S,Ma.push(A.fa)):A.lk(t.x,t.y,t.a,t.ia,t.oa,t.og))):(A=this.ih(u,q),A.Vh=y,A.Mh=b.paused,t&&(-1!==S?A.df.push({Fm:S,kj:t.ia,
Mj:t.oa,Pj:t.og,Gn:s}):A.df.push({x:t.x,y:t.y,So:t.a,kj:t.ia,Mj:t.oa,Pj:t.og,Gn:s}))));if(d&&!M){k=0;for(m=F.length;k<m;k++)F[k].rn(!0);M=!0}else if(!d&&M){k=0;for(m=F.length;k<m;k++)F[k].rn(!1);M=!1}};la.td=function(){var a,b,c,d;a=0;for(b=Ma.length;a<b;a++)c=Ma[a],d=this.b.lh(c.Eh),c.wg(d),c.Eh=-1,d&&(J=d.x,H=d.y);Ma.length=0};la.xr=function(a){if(!this.Ar){!a&&t&&t.resume&&t.resume();var b,c;b=0;for(c=F.length;b<c;b++)F[b].$r(a);a&&t&&t.suspend&&t.suspend()}};la.bb=function(){var a=this.b.be,b,
c,d;b=0;for(c=F.length;b<c;b++)d=F[b],d.bb(a),0===d.B||3===d.B||d.Ac||d.rb||!d.je()||(d.rb=!0,ta=d.tag,z.trigger(hc.prototype.e.li,I)),0!==E&&d.Tn();var f,e;for(f in Q)if(Q.hasOwnProperty(f))for(d=Q[f],b=0,c=d.length;b<c;b++)e=d[b],e.bb&&e.bb();1===G&&this.Va.nh()&&(this.Va.bb(a),J=this.Va.r.x,H=this.Va.r.y,t.listener.setPosition(this.Va.r.x,this.Va.r.y,this.ag),t.listener.setVelocity(this.Va.ej(),this.Va.fj(),0))};var Na=[];la.Zr=function(a){var b,c,d,f,e,g=0;b=0;for(c=a.length;b<c;++b)if(d=a[b],
f=d[0],d=2*d[1],(e=4<f.length&&".ogg"===f.substr(f.length-4))&&D||!e&&!D)Na.push({filename:f,size:d,r:null}),g+=d;return g};la.cs=function(){var a,b,c,d;a=0;for(b=Na.length;a<b;++a)c=Na[a],d=this.b.Si+c.filename,c.r=this.ih(d,!1)};la.yq=function(){var a=0,b,c,d;b=0;for(c=Na.length;b<c;++b)d=Na[b],d.r.Zq()||d.r.Sq()||this.b.ca||this.b.ph?a+=d.size:d.r.Sl()&&(a+=Math.floor(d.size/2));return a};la.ih=function(a,b){var c,d,f,e=null;c=0;for(d=ua.length;c<d;c++)if(f=ua[c],f.src===a){e=f;break}e||(e=new u(a,
b),ua.push(e));return e};la.Bl=function(a,b,c,d,f){var e,g,l;e=0;for(g=F.length;e<g;e++)if(l=F[e],l.src===a&&(l.gp()||c))return l.tag=b,l;a=this.ih(a,c);if(!a.O)return"<preload>"!==b&&(a.Nh=b,a.Gj=d,a.Ek=f),null;l=new y(a,b);F.push(l);return l};var Fa=[];A.prototype.li=function(a){return fb(ta,a)};X.e=new A;S.prototype.Play=function(a,b,c,d){!M&&(c=Math.pow(10,c/20),0>c&&(c=0),1<c&&(c=1),N=this.Bl(this.b.Si+a[0]+(D?".ogg":".m4a"),d,a[1],0!==b,c))&&(N.mk(!1),N.play(0!==b,c))};S.prototype.Po=function(){var a,
b;a=0;for(b=F.length;a<b;a++)F[a].stop()};X.Aa=new S;X.hb=new function(){}})();function ic(k){this.b=k}
(function(){function k(){}function q(){}var e=ic.prototype;e.Zb=function(e){this.ha=e;this.b=e.b};e.Zb.prototype.ua=function(){};e.cb=function(e){this.type=e;this.b=e.b};e.cb.prototype.ua=function(){var e=this;window.addEventListener("resize",function(){e.b.trigger(ic.prototype.e.Fo,e)});"undefined"!==typeof navigator.onLine&&(window.addEventListener("online",function(){e.b.trigger(ic.prototype.e.Co,e)}),window.addEventListener("offline",function(){e.b.trigger(ic.prototype.e.Bo,e)}));"undefined"!==
typeof window.applicationCache&&(window.applicationCache.addEventListener("updateready",function(){e.b.Xe=1;e.b.trigger(ic.prototype.e.Ok,e)}),window.applicationCache.addEventListener("progress",function(k){e.b.Xe=k.loaded/k.total}));this.b.Ja||(document.addEventListener("appMobi.device.update.available",function(){e.b.trigger(ic.prototype.e.Ok,e)}),document.addEventListener("backbutton",function(){e.b.trigger(ic.prototype.e.ki,e)}),document.addEventListener("menubutton",function(){e.b.trigger(ic.prototype.e.Jk,
e)}),document.addEventListener("searchbutton",function(){e.b.trigger(ic.prototype.e.Go,e)}),document.addEventListener("tizenhwkey",function(k){var d;switch(k.keyName){case "back":d=e.b.trigger(ic.prototype.e.ki,e);!d&&window.tizen&&window.tizen.application.getCurrentApplication().exit();break;case "menu":(d=e.b.trigger(ic.prototype.e.Jk,e))||k.preventDefault()}}));this.b.qh&&(WinJS.Application.onbackclick=function(){return!!e.b.trigger(ic.prototype.e.ki,e)});this.b.Uk(function(k){k?e.b.trigger(ic.prototype.e.Do,
e):e.b.trigger(ic.prototype.e.Eo,e)})};k.prototype.Co=function(){return!0};k.prototype.Bo=function(){return!0};k.prototype.Ok=function(){return!0};k.prototype.Eo=function(){return!0};k.prototype.Do=function(){return!0};k.prototype.Fo=function(){return!0};k.prototype.ki=function(){return!0};k.prototype.Jk=function(){return!0};k.prototype.Go=function(){return!0};e.e=new k;e.Aa=new function(){};q.prototype.URL=function(e){e.Ra(this.b.ca?"":window.location.toString())};e.hb=new q})();
function gc(k){this.b=k}
(function(){function k(){this.name="";this.ug=0;this.La=[]}function q(){c++;c===b.length&&b.push(new k);return b[c]}function e(){}function m(){}function s(){}var d=gc.prototype;d.Zb=function(b){this.ha=b;this.b=b.b};d.Zb.prototype.ua=function(){};d.cb=function(b){this.type=b;this.b=b.b};var b=[],c=-1;d.cb.prototype.ua=function(){var b=this;window.c2_callFunction=function(d,a){var e,k,g,m=q();m.name=d.toLowerCase();m.ug=0;if(a)for(m.La.length=a.length,e=0,k=a.length;e<k;++e)g=a[e],m.La[e]="number"===
typeof g||"string"===typeof g?g:"boolean"===typeof g?g?1:0:0;else m.La.length=0;b.b.trigger(gc.prototype.e.Mg,b,m.name);c--;return m.ug}};e.prototype.Mg=function(d){var e=0>c?null:b[c];return e?fb(d,e.name):!1};d.e=new e;m.prototype.CallFunction=function(b,d){var a=q();a.name=b.toLowerCase();a.ug=0;ya(a.La,d);this.b.trigger(gc.prototype.e.Mg,this,a.name);c--};d.Aa=new m;s.prototype.$n=function(b,d){var a=q();a.name=d.toLowerCase();a.ug=0;a.La.length=0;var e,k;e=2;for(k=arguments.length;e<k;e++)a.La.push(arguments[e]);
this.b.trigger(gc.prototype.e.Mg,this,a.name);c--;b.tn(a.ug)};d.hb=new s})();function fc(k){this.b=k}
(function(){function k(){if(0===this.Ji.length){var b=document.createElement("canvas");b.width=this.width;b.height=this.height;var a=b.getContext("2d");this.mf?a.drawImage(this.ab,this.bf,this.cf,this.width,this.height,0,0,this.width,this.height):a.drawImage(this.ab,0,0,this.width,this.height);this.Ji=b.toDataURL("image/png")}return this.Ji}function q(){}function e(){}var m=fc.prototype;m.Zb=function(b){this.ha=b;this.b=b.b};var s=m.Zb.prototype;s.ua=function(){if(!this.K){var b,a,c,d,e,m,q,h,f;this.ac=
[];this.Of=!1;b=0;for(a=this.eb.length;b<a;b++){e=this.eb[b];q={};q.name=e[0];q.speed=e[1];q.loop=e[2];q.ek=e[3];q.Uh=e[4];q.Ym=e[5];q.I=e[6];q.frames=[];c=0;for(d=e[7].length;c<d;c++)m=e[7][c],h={},h.En=m[0],h.Fn=m[1],h.bf=m[2],h.cf=m[3],h.width=m[4],h.height=m[5],h.duration=m[6],h.lb=m[7],h.mb=m[8],h.lj=m[9],h.Oh=m[10],h.Zm=m[11],h.mf=0!==h.width,h.Ji="",h.Dt=k,f={left:0,top:0,right:1,bottom:1},h.nk=f,h.od=null,(f=this.b.kq(m[0]))?h.ab=f:(h.ab=new Image,h.ab.lp=m[0],h.ab.kp=m[1],h.ab.ep=null,this.b.ss(h.ab,
m[0])),q.frames.push(h),this.ac.push(h);this.eb[b]=q}}};s.Sn=function(){var b,a,c;b=0;for(a=this.c.length;b<a;b++)c=this.c[b],c.Vg=c.Ib.od};s.Jm=function(){if(!this.K){var b,a,c;b=0;for(a=this.ac.length;b<a;++b)c=this.ac[b],c.ab.ep=null,c.od=null;this.Of=!1;this.Sn()}};s.Mm=function(){if(!this.K&&this.c.length){var b,a,c;b=0;for(a=this.ac.length;b<a;++b)c=this.ac[b],c.od=this.b.q.gm(c.ab,this.b.R,c.Zm);this.Sn()}};s.ir=function(){if(!this.K&&!this.Of&&this.b.q){var b,a,c;b=0;for(a=this.ac.length;b<
a;++b)c=this.ac[b],c.od=this.b.q.gm(c.ab,this.b.R,c.Zm);this.Of=!0}};s.Pn=function(){if(!this.K&&!this.c.length&&this.Of){var b,a,c;b=0;for(a=this.ac.length;b<a;++b)c=this.ac[b],this.b.q.deleteTexture(c.od),c.od=null;this.Of=!1}};var d=[];s.bn=function(b){var a,c,e;a=d.length=0;for(c=this.ac.length;a<c;++a)e=this.ac[a].ab,-1===d.indexOf(e)&&(b.drawImage(e,0,0),d.push(e))};m.cb=function(b){this.type=b;this.b=b.b;b=this.type.eb[0].frames[0].Oh;this.Ic?this.wc.zg(b):this.wc=new $a(b)};var b=m.cb.prototype;
b.ua=function(){this.visible=0===this.Ma[0];this.mj=this.wj=!1;this.yd=0!==this.Ma[3];1===this.type.eb.length&&1===this.type.eb[0].frames.length||0===this.type.eb[0].speed||(this.b.sk(this),this.wj=!0);this.aa=this.Al(this.Ma[1])||this.type.eb[0];this.m=this.Ma[2];0>this.m&&(this.m=0);this.m>=this.aa.frames.length&&(this.m=this.aa.frames.length-1);var b=this.aa.frames[this.m];this.wc.zg(b.Oh);this.lb=b.lb;this.mb=b.mb;this.Df=this.aa.speed;this.Ic?this.rc.reset():this.rc=new Ya;this.Zc=this.rc.U;
this.Vd=!0;this.Rc=0;this.Ud=!0;this.Ci=this.Wk="";this.hp=0;this.Pg=-1;this.type.ir();var a,c,d,e,k,m,h,b=0;for(a=this.type.eb.length;b<a;b++)for(e=this.type.eb[b],c=0,d=e.frames.length;c<d;c++)k=e.frames[c],0===k.width&&(k.width=k.ab.width,k.height=k.ab.height),k.mf&&(h=k.ab,m=k.nk,m.left=k.bf/h.width,m.top=k.cf/h.height,m.right=(k.bf+k.width)/h.width,m.bottom=(k.cf+k.height)/h.height,0===k.bf&&0===k.cf&&k.width===h.width&&k.height===h.height&&(k.mf=!1));this.Ib=this.aa.frames[this.m];this.Vg=this.Ib.od};
b.nc=function(){var b={a:this.aa.I,f:this.m,cas:this.Df,fs:this.Zc,ar:this.Rc,at:this.rc.U};this.Vd||(b.ap=this.Vd);this.Ud||(b.af=this.Ud);return b};b.bd=function(b){var a=this.pq(b.a);a&&(this.aa=a);this.m=b.f;0>this.m&&(this.m=0);this.m>=this.aa.frames.length&&(this.m=this.aa.frames.length-1);this.Df=b.cas;this.Zc=b.fs;this.Rc=b.ar;this.rc.reset();this.rc.U=b.at;this.Vd=b.hasOwnProperty("ap")?b.ap:!0;this.Ud=b.hasOwnProperty("af")?b.af:!0;this.Ib=this.aa.frames[this.m];this.Vg=this.Ib.od;this.wc.zg(this.Ib.Oh);
this.lb=this.Ib.lb;this.mb=this.Ib.mb};b.ri=function(b){this.m=b?0:this.aa.frames.length-1;this.Vd=!1;this.Wk=this.aa.name;this.mj=!0;this.b.trigger(fc.prototype.e.so,this);this.b.trigger(fc.prototype.e.ro,this);this.mj=!1;this.Rc=0};b.Ft=function(){return this.rc.U};b.bb=function(){this.rc.add(this.b.Dl(this));this.Ci.length&&this.qp();0<=this.Pg&&this.ql();var b=this.rc.U,a=this.aa,c=a.frames[this.m],d=c.duration/this.Df;this.Vd&&b>=this.Zc+d&&(this.Ud?this.m++:this.m--,this.Zc+=d,this.m>=a.frames.length&&
(a.Ym?(this.Ud=!1,this.m=a.frames.length-2):a.loop?this.m=a.Uh:(this.Rc++,this.Rc>=a.ek?this.ri(!1):this.m=a.Uh)),0>this.m&&(a.Ym?(this.m=1,this.Ud=!0,a.loop||(this.Rc++,this.Rc>=a.ek&&this.ri(!0))):a.loop?this.m=a.Uh:(this.Rc++,this.Rc>=a.ek?this.ri(!0):this.m=a.Uh)),0>this.m?this.m=0:this.m>=a.frames.length&&(this.m=a.frames.length-1),b>this.Zc+a.frames[this.m].duration/this.Df&&(this.Zc=b),b=a.frames[this.m],this.Ee(c,b),this.b.X=!0)};b.Al=function(b){var a,c,d;a=0;for(c=this.type.eb.length;a<
c;a++)if(d=this.type.eb[a],fb(d.name,b))return d;return null};b.pq=function(b){var a,c,d;a=0;for(c=this.type.eb.length;a<c;a++)if(d=this.type.eb[a],d.I===b)return d;return null};b.qp=function(){var b=this.aa.frames[this.m],a=this.Al(this.Ci);this.Ci="";!a||fb(a.name,this.aa.name)&&this.Vd||(this.aa=a,this.Df=a.speed,0>this.m&&(this.m=0),this.m>=this.aa.frames.length&&(this.m=this.aa.frames.length-1),1===this.hp&&(this.m=0),this.Vd=!0,this.Zc=this.rc.U,this.Ud=!0,this.Ee(b,this.aa.frames[this.m]),
this.b.X=!0)};b.ql=function(){var b=this.aa.frames[this.m],a=this.m;this.m=P(this.Pg);0>this.m&&(this.m=0);this.m>=this.aa.frames.length&&(this.m=this.aa.frames.length-1);a!==this.m&&(this.Ee(b,this.aa.frames[this.m]),this.Zc=this.rc.U,this.b.X=!0);this.Pg=-1};b.Ee=function(b,a){var c=b.width,d=b.height,e=a.width,k=a.height;c!=e&&(this.width*=e/c);d!=k&&(this.height*=k/d);this.lb=a.lb;this.mb=a.mb;this.wc.zg(a.Oh);this.ya();this.Ib=a;this.Vg=a.od;c=0;for(d=this.C.length;c<d;c++)e=this.C[c],e.wr&&
e.wr(b,a);this.b.trigger(fc.prototype.e.Ee,this)};b.ae=function(b){b.globalAlpha=this.opacity;var a=this.Ib,c=a.mf,d=a.ab,e=this.x,k=this.y,m=this.width,h=this.height;if(0===this.k&&0<=m&&0<=h)e-=this.lb*m,k-=this.mb*h,this.b.ef&&(e=Math.round(e),k=Math.round(k)),c?b.drawImage(d,a.bf,a.cf,a.width,a.height,e,k,m,h):b.drawImage(d,e,k,m,h);else{this.b.ef&&(e=Math.round(e),k=Math.round(k));b.save();var f=0<m?1:-1,q=0<h?1:-1;b.translate(e,k);1===f&&1===q||b.scale(f,q);b.rotate(this.k*f*q);e=0-this.lb*
ma(m);k=0-this.mb*ma(h);c?b.drawImage(d,a.bf,a.cf,a.width,a.height,e,k,ma(m),ma(h)):b.drawImage(d,e,k,ma(m),ma(h));b.restore()}};b.yc=function(b){b.Vb(this.Vg);b.xg(this.opacity);var a=this.Ib,c=this.Ng;if(this.b.ef){var d=Math.round(this.x)-this.x,e=Math.round(this.y)-this.y;a.mf?b.ze(c.Cb+d,c.Db+e,c.Nc+d,c.Oc+e,c.uc+d,c.vc+e,c.sc+d,c.tc+e,a.nk):b.Th(c.Cb+d,c.Db+e,c.Nc+d,c.Oc+e,c.uc+d,c.vc+e,c.sc+d,c.tc+e)}else a.mf?b.ze(c.Cb,c.Db,c.Nc,c.Oc,c.uc,c.vc,c.sc,c.tc,a.nk):b.Th(c.Cb,c.Db,c.Nc,c.Oc,c.uc,
c.vc,c.sc,c.tc)};b.uq=function(b){var a=this.Ib,c,d;c=0;for(d=a.lj.length;c<d;c++)if(fb(b,a.lj[c][0]))return c;return-1};b.aj=function(b,a){var c=this.Ib,d=c.lj,e;e=O(b)?this.uq(b):b-1;e=P(e);if(0>e||e>=d.length)return a?this.x:this.y;var k=(d[e][1]-c.lb)*this.width,d=d[e][2],d=(d-c.mb)*this.height,c=Math.cos(this.k);e=Math.sin(this.k);var m=k*c-d*e,d=d*c+k*e,k=m+this.x,d=d+this.y;return a?k:d};var c=new ca,w=!1;new R(0,0,0,0);s.finish=function(b){if(w){if(b){var a=this.b.jb().ec.Fc;b=null.W();var d=
c.Sd(),e,g;if(b.Y){b.Y=!1;b.c.length=d.length;e=0;for(g=d.length;e<g;e++)b.c[e]=d[e];if(a)for(e=b.L.length=0,g=null.c.length;e<g;e++)d=null.c[e],c.contains(d)||b.L.push(d)}else if(a)for(a=b.c.length,b.c.length=a+d.length,e=0,g=d.length;e<g;e++)b.c[a+e]=d[e],Ba(b.L,d[e]);else ya(b.c,d);null.ud()}c.clear();w=!1}};q.prototype.ro=function(b){return fb(this.Wk,b)};q.prototype.so=function(){return!0};q.prototype.Ee=function(){return!0};m.e=new q;e.prototype.Jo=function(b){this.Pg=b;this.wj||(this.b.sk(this),
this.wj=!0);this.mj||this.ql()};e.prototype.Ko=function(b){this.yd!==(0!==b)&&((this.yd=0!==b)?this.ya():(this.Fb.right>=this.Fb.left&&this.type.Ei.update(this,this.Fb,null),this.Fb.set(0,0,-1,-1)))};m.Aa=new e;m.hb=new function(){}})();function Z(k){this.b=k}
(function(){function k(b){n=b.x;a=b.y;l=b.z}function q(a){p=a.x;g=a.y;x=a.z}function e(a,b,c,d){var e;e=v.length?v.pop():new m;e.init(a,b,c,d);return e}function m(){this.Cg=this.id=this.y=this.x=this.bi=this.ai=this.Aj=this.time=this.pk=0;this.Hg=this.gi=!1}function s(){}function d(){}var b=Z.prototype;b.Zb=function(a){this.ha=a;this.b=a.b};b.Zb.prototype.ua=function(){};b.cb=function(a){this.type=a;this.b=a.b;this.touches=[];this.Jj=!1};var c=b.cb.prototype,w={left:0,top:0};c.If=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 n=0,a=0,l=0,p=0,g=0,x=0,v=[];m.prototype.init=function(a,b,c,d){var e=U();this.pk=this.Aj=this.time=e;this.ai=a;this.bi=b;this.x=a;this.y=b;this.id=c;this.Cg=d;this.Hg=this.gi=!1};m.prototype.update=function(a,b,c){this.Aj=this.time;this.time=a;this.x=b;this.y=c;!this.Hg&&15<=Ra(this.ai,this.bi,this.x,this.y)&&(this.Hg=!0)};m.prototype.lr=function(a,b){!this.gi&&500<=U()-this.pk&&!this.Hg&&15>Ra(this.ai,this.bi,
this.x,this.y)&&(this.gi=!0,a.Mc=this.Cg,a.pf=this.id,a.Le=b,a.b.trigger(Z.prototype.e.xo,a),a.Uc=this.x,a.Vc=this.y,a.b.trigger(Z.prototype.e.yo,a),a.Le=0)};var h=-1E3,f=-1E3,r=-1E4;m.prototype.zm=function(a,b){if(!this.gi){var c=U();333>=c-this.pk&&!this.Hg&&15>Ra(this.ai,this.bi,this.x,this.y)&&(a.Mc=this.Cg,a.pf=this.id,a.Le=b,666>=c-r&&25>Ra(h,f,this.x,this.y)?(a.b.trigger(Z.prototype.e.vo,a),a.Uc=this.x,a.Vc=this.y,a.b.trigger(Z.prototype.e.wo,a),f=h=-1E3,r=-1E4):(a.b.trigger(Z.prototype.e.Ho,
a),a.Uc=this.x,a.Vc=this.y,a.b.trigger(Z.prototype.e.Io,a),h=this.x,f=this.y,r=c),a.Le=0)}};c.ua=function(){this.br=!("undefined"===typeof window.c2isWindows8||!window.c2isWindows8);this.Le=this.pf=this.Mc=this.Vc=this.Uc=this.Rk=this.Qk=this.Pk=this.Vo=this.Uo=this.To=this.pg=this.ng=this.mg=0;this.qs=0!==this.Ma[0];var a=0<this.b.ib?document:this.b.canvas,b=document;this.b.Ja?b=a=window.Canvas:this.b.Nb&&(b=a=window);var c=this;window.navigator.pointerEnabled?(a.addEventListener("pointerdown",function(a){c.Lm(a)},
!1),a.addEventListener("pointermove",function(a){c.Km(a)},!1),b.addEventListener("pointerup",function(a){c.Lh(a,!1)},!1),b.addEventListener("pointercancel",function(a){c.Lh(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.Lm(a)},!1),a.addEventListener("MSPointerMove",function(a){c.Km(a)},!1),b.addEventListener("MSPointerUp",function(a){c.Lh(a,!1)},!1),b.addEventListener("MSPointerCancel",function(a){c.Lh(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.Om(a)},
!1),a.addEventListener("touchmove",function(a){c.Nm(a)},!1),b.addEventListener("touchend",function(a){c.Sj(a,!1)},!1),b.addEventListener("touchcancel",function(a){c.Sj(a,!0)},!1));if(this.br){var d=function(a){a=a.reading;c.Pk=a.accelerationX;c.Qk=a.accelerationY;c.Rk=a.accelerationZ},e=function(a){a=a.reading;c.mg=a.yawDegrees;c.ng=a.pitchDegrees;c.pg=a.rollDegrees},f=Windows.Devices.Sensors.Accelerometer.getDefault();f&&(f.reportInterval=Math.max(f.minimumReportInterval,16),f.addEventListener("readingchanged",
d));var g=Windows.Devices.Sensors.Inclinometer.getDefault();g&&(g.reportInterval=Math.max(g.minimumReportInterval,16),g.addEventListener("readingchanged",e));document.addEventListener("visibilitychange",function(){document.hidden||document.msHidden?(f&&f.removeEventListener("readingchanged",d),g&&g.removeEventListener("readingchanged",e)):(f&&f.addEventListener("readingchanged",d),g&&g.addEventListener("readingchanged",e))},!1)}else window.addEventListener("deviceorientation",function(a){c.mg=a.alpha||
0;c.ng=a.beta||0;c.pg=a.gamma||0},!1),window.addEventListener("devicemotion",function(a){a.accelerationIncludingGravity&&(c.To=a.accelerationIncludingGravity.x||0,c.Uo=a.accelerationIncludingGravity.y||0,c.Vo=a.accelerationIncludingGravity.z||0);a.acceleration&&(c.Pk=a.acceleration.x||0,c.Qk=a.acceleration.y||0,c.Rk=a.acceleration.z||0)},!1);this.qs&&!this.b.ca&&(jQuery(document).mousemove(function(a){c.tr(a)}),jQuery(document).mousedown(function(a){c.sr(a)}),jQuery(document).mouseup(function(a){c.ur(a)}));
this.b.Ne&&!this.b.Ja&&AppMobi.accelerometer.watchAcceleration(k,{frequency:40,adjustForRotation:!0});this.b.Ob&&navigator.accelerometer&&navigator.accelerometer.watchAcceleration&&navigator.accelerometer.watchAcceleration(q,null,{frequency:40});this.b.gs(this)};c.Km=function(a){if(a.pointerType!==a.MSPOINTER_TYPE_MOUSE&&"mouse"!==a.pointerType){a.preventDefault&&a.preventDefault();var b=this.If(a.pointerId),c=U();if(0<=b){var d=this.b.ca?w:jQuery(this.b.canvas).offset(),b=this.touches[b];2>c-b.time||
b.update(c,a.pageX-d.left,a.pageY-d.top)}}};c.Lm=function(a){if(a.pointerType!==a.MSPOINTER_TYPE_MOUSE&&"mouse"!==a.pointerType){a.preventDefault&&gb(a)&&a.preventDefault();var b=this.b.ca?w:jQuery(this.b.canvas).offset(),c=a.pageX-b.left,b=a.pageY-b.top;U();this.Mc=this.touches.length;this.pf=a.pointerId;this.touches.push(e(c,b,a.pointerId,this.Mc));this.b.Dc=!0;this.b.trigger(Z.prototype.e.Lk,this);this.b.trigger(Z.prototype.e.Nk,this);this.Uc=c;this.Vc=b;this.b.trigger(Z.prototype.e.oi,this);this.b.Dc=
!1}};c.Lh=function(a,b){if(a.pointerType!==a.MSPOINTER_TYPE_MOUSE&&"mouse"!==a.pointerType){a.preventDefault&&gb(a)&&a.preventDefault();var c=this.If(a.pointerId);this.Mc=0<=c?this.touches[c].Cg:-1;this.pf=0<=c?this.touches[c].id:-1;this.b.Dc=!0;this.b.trigger(Z.prototype.e.Kk,this);this.b.trigger(Z.prototype.e.Mk,this);0<=c&&(b||this.touches[c].zm(this,c),100>v.length&&v.push(this.touches[c]),this.touches.splice(c,1));this.b.Dc=!1}};c.Nm=function(a){a.preventDefault&&a.preventDefault();var b=U(),
c,d,e,f;c=0;for(d=a.changedTouches.length;c<d;c++)if(e=a.changedTouches[c],f=this.If(e.identifier),0<=f){var g=this.b.ca?w:jQuery(this.b.canvas).offset();f=this.touches[f];2>b-f.time||f.update(b,e.pageX-g.left,e.pageY-g.top)}};c.Om=function(a){a.preventDefault&&gb(a)&&a.preventDefault();var b=this.b.ca?w:jQuery(this.b.canvas).offset();U();this.b.Dc=!0;var c,d,f,g;c=0;for(d=a.changedTouches.length;c<d;c++)if(f=a.changedTouches[c],g=this.If(f.identifier),-1===g){g=f.pageX-b.left;var h=f.pageY-b.top;
this.Mc=this.touches.length;this.pf=f.identifier;this.touches.push(e(g,h,f.identifier,this.Mc));this.b.trigger(Z.prototype.e.Lk,this);this.b.trigger(Z.prototype.e.Nk,this);this.Uc=g;this.Vc=h;this.b.trigger(Z.prototype.e.oi,this)}this.b.Dc=!1};c.Sj=function(a,b){a.preventDefault&&gb(a)&&a.preventDefault();this.b.Dc=!0;var c,d,e;c=0;for(d=a.changedTouches.length;c<d;c++)e=a.changedTouches[c],e=this.If(e.identifier),0<=e&&(this.Mc=this.touches[e].Cg,this.pf=this.touches[e].id,this.b.trigger(Z.prototype.e.Kk,
this),this.b.trigger(Z.prototype.e.Mk,this),b||this.touches[e].zm(this,e),100>v.length&&v.push(this.touches[e]),this.touches.splice(e,1));this.b.Dc=!1};c.Bt=function(){return this.b.Ne&&0===this.mg&&0!==l?90*l:this.b.Ob&&0===this.mg&&0!==x?90*x:this.mg};c.Ct=function(){return this.b.Ne&&0===this.ng&&0!==a?-90*a:this.b.Ob&&0===this.ng&&0!==g?90*g:this.ng};c.Et=function(){return this.b.Ne&&0===this.pg&&0!==n?90*n:this.b.Ob&&0===this.pg&&0!==p?90*p:this.pg};c.sr=function(a){a.preventDefault&&this.b.hj&&
!this.b.oe&&a.preventDefault();this.Om({changedTouches:[{pageX:a.pageX,pageY:a.pageY,identifier:0}]});this.Jj=!0};c.tr=function(a){this.Jj&&this.Nm({changedTouches:[{pageX:a.pageX,pageY:a.pageY,identifier:0}]})};c.ur=function(a){a.preventDefault&&this.b.hj&&!this.b.oe&&a.preventDefault();this.b.hj=!0;this.Sj({changedTouches:[{pageX:a.pageX,pageY:a.pageY,identifier:0}]});this.Jj=!1};c.rk=function(){var a,b,c,d=U();a=0;for(b=this.touches.length;a<b;++a)c=this.touches[a],c.time<=d-50&&(c.Aj=d),c.lr(this,
a)};s.prototype.Nk=function(){return!0};s.prototype.Mk=function(){return!0};s.prototype.oi=function(a){return a?this.b.di(a,this.Uc,this.Vc):!1};s.prototype.Lk=function(a){a=Math.floor(a);return a===this.Mc};s.prototype.Kk=function(a){a=Math.floor(a);return a===this.Mc};s.prototype.xo=function(){return!0};s.prototype.Ho=function(){return!0};s.prototype.vo=function(){return!0};s.prototype.yo=function(a){return a?this.b.di(a,this.Uc,this.Vc):!1};s.prototype.Io=function(a){return a?this.b.di(a,this.Uc,
this.Vc):!1};s.prototype.wo=function(a){return a?this.b.di(a,this.Uc,this.Vc):!1};b.e=new s;d.prototype.Qo=function(a,b){var c=this.Le;if(0>c||c>=this.touches.length)a.n(0);else{var d,e,f,g,h;ga(b)?(d=this.b.Jf(0),e=d.scale,f=d.qd,g=d.ed,h=d.k,d.scale=1,d.qd=1,d.ed=1,d.k=0,a.n(d.fb(this.touches[c].x,this.touches[c].y,!0)),d.scale=e,d.qd=f,d.ed=g,d.k=h):(d=ha(b)?this.b.Jf(b):this.b.bj(b))?a.n(d.fb(this.touches[c].x,this.touches[c].y,!0)):a.n(0)}};d.prototype.Ro=function(a,b){var c=this.Le;if(0>c||
c>=this.touches.length)a.n(0);else{var d,e,f,g,h;ga(b)?(d=this.b.Jf(0),e=d.scale,f=d.qd,g=d.fd,h=d.k,d.scale=1,d.qd=1,d.fd=1,d.k=0,a.n(d.fb(this.touches[c].x,this.touches[c].y,!1)),d.scale=e,d.qd=f,d.fd=g,d.k=h):(d=ha(b)?this.b.Jf(b):this.b.bj(b))?a.n(d.fb(this.touches[c].x,this.touches[c].y,!1)):a.n(0)}};b.hb=new d})();
function ec(){return[hc,ic,gc,fc,Z,Y.prototype.e.Hk,Y.prototype.e.fo,Y.prototype.Aa.ho,Y.prototype.e.co,Y.prototype.hb.gr,hc.prototype.Aa.Po,hc.prototype.Aa.Play,fc.prototype.e.Lg,fc.prototype.Aa.Jo,fc.prototype.e.eo,fc.prototype.Aa.Lo,Z.prototype.e.oi,Y.prototype.Aa.ko,fc.prototype.Aa.No,Y.prototype.Aa.Mo,fc.prototype.Aa.io,fc.prototype.e.oo,Y.prototype.Aa.Oo,fc.prototype.Aa.Ko,Y.prototype.e.no,gc.prototype.e.Mg,gc.prototype.Aa.CallFunction,Y.prototype.hb.floor,Y.prototype.hb.random]};
