-
Notifications
You must be signed in to change notification settings - Fork 0
/
c2runtime.js
519 lines (519 loc) · 216 KB
/
c2runtime.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
// Generated by Construct 2, the HTML5 game and app creator :: http://www.scirra.com
'use strict';var l=void 0,m=!0,p=null,q=!1;function v(){return function(){}}function ba(a){return function(b){this[a]=b}}function y(a){return function(){return this[a]}}function D(a){return function(){return a}}var F,ca,da,ea,fa,H,ga,ha,ia,ja,ka,la,ma,na,oa,pa,qa,ra,K,sa,ta,ua,va,wa,za,Aa,Ba,Ca,Da,Ea,Fa,Ga,Ha,Ia,Ja,Ka,La,Ma,Na,Oa,Pa,Qa,Ra,Sa,Ta,Ua,Va,Wa,Xa,Ya,ab={};"function"!==typeof Object.getPrototypeOf&&(Object.getPrototypeOf="object"===typeof"test".__proto__?function(a){return a.__proto__}:function(a){return a.constructor.prototype});
function bb(a,b,c,d){this.set(a,b,c,d)}function cb(){this.bc=this.ac=this.ec=this.cc=this.lc=this.kc=this.pb=this.ob=0}function db(){this.Bg={};this.xh=0;this.ji=[];this.Mi=m}function eb(){this.de=this.ql=this.y=this.g=0}function fb(a){this.ic=[];this.co(a)}da=function(a){console&&console.log&&console.log(a)};ca=function(a){return a};ea=function(a){return"undefined"===typeof a};fa=function(a){return"number"===typeof a};H=function(a){return"string"===typeof a};ga=function(a){return 0<a&&0===(a-1&a)};
ha=function(a){return 0>a?-a:a};ia=function(a,b){return a>b?a:b};ja=function(a,b){return a<b?a:b};ka=Math.PI;la=function(a){return a|0};ma=function(a,b,c,d,e,f,g,h){if(ia(a,c)<ja(e,g)||ja(a,c)>ia(e,g)||ia(b,d)<ja(f,h)||ja(b,d)>ia(f,h))return q;var i=e-a+g-c,j=f-b+h-d,a=c-a,b=d-b,e=g-e,f=h-f,h=ha(b*e-f*a);return ha(e*j-f*i)<=h&&ha(a*j-b*i)<=h};F=bb.prototype;F.set=function(a,b,c,d){this.left=a;this.top=b;this.right=c;this.bottom=d};F.width=function(){return this.right-this.left};
F.height=function(){return this.bottom-this.top};F.offset=function(a,b){this.left+=a;this.top+=b;this.right+=a;this.bottom+=b;return this};F.pu=function(a){return!(a.right<this.left||a.bottom<this.top||a.left>this.right||a.top>this.bottom)};F.pd=function(a,b){return a>=this.left&&a<=this.right&&b>=this.top&&b<=this.bottom};F=cb.prototype;F.bo=function(a){this.ob=a.left;this.pb=a.top;this.kc=a.right;this.lc=a.top;this.cc=a.right;this.ec=a.bottom;this.ac=a.left;this.bc=a.bottom};
F.lr=function(a,b){if(0===b)this.bo(a);else{var c=Math.sin(b),d=Math.cos(b),e=a.left*c,f=a.top*c,g=a.right*c,c=a.bottom*c,h=a.left*d,i=a.top*d,j=a.right*d,d=a.bottom*d;this.ob=h-f;this.pb=i+e;this.kc=j-f;this.lc=i+g;this.cc=j-c;this.ec=d+g;this.ac=h-c;this.bc=d+e}};F.offset=function(a,b){this.ob+=a;this.pb+=b;this.kc+=a;this.lc+=b;this.cc+=a;this.ec+=b;this.ac+=a;this.bc+=b;return this};
F.hp=function(a){a.left=ja(ja(this.ob,this.kc),ja(this.cc,this.ac));a.top=ja(ja(this.pb,this.lc),ja(this.ec,this.bc));a.right=ia(ia(this.ob,this.kc),ia(this.cc,this.ac));a.bottom=ia(ia(this.pb,this.lc),ia(this.ec,this.bc))};
F.pd=function(a,b){var c=this.kc-this.ob,d=this.lc-this.pb,e=this.cc-this.ob,f=this.ec-this.pb,g=a-this.ob,h=b-this.pb,i=c*c+d*d,j=c*e+d*f,d=c*g+d*h,k=e*e+f*f,n=e*g+f*h,r=1/(i*k-j*j),c=(k*d-j*n)*r,i=(i*n-j*d)*r;if(0<=c&&0<i&&1>c+i)return m;c=this.ac-this.ob;d=this.bc-this.pb;i=c*c+d*d;j=c*e+d*f;d=c*g+d*h;r=1/(i*k-j*j);c=(k*d-j*n)*r;i=(i*n-j*d)*r;return 0<=c&&0<i&&1>c+i};
F.Ff=function(a,b){a%=4;0>a&&(a+=4);switch(a){case 0:return b?this.ob:this.pb;case 1:return b?this.kc:this.lc;case 2:return b?this.cc:this.ec;case 3:return b?this.ac:this.bc;default:return b?this.ob:this.pb}};F.Pg=function(){return(this.ob+this.kc+this.cc+this.ac)/4};F.Qg=function(){return(this.pb+this.lc+this.ec+this.bc)/4};
F.ou=function(a){var b=a.Pg(),c=a.Qg();if(this.pd(b,c))return m;b=this.Pg();c=this.Qg();if(a.pd(b,c))return m;var d,e,f,g,h,i,j,k;for(j=0;4>j;j++)for(k=0;4>k;k++)if(b=this.Ff(j,m),c=this.Ff(j,q),d=this.Ff(j+1,m),e=this.Ff(j+1,q),f=a.Ff(k,m),g=a.Ff(k,q),h=a.Ff(k+1,m),i=a.Ff(k+1,q),ma(b,c,d,e,f,g,h,i))return m;return q};na=function(a,b){for(var c in b)b.hasOwnProperty(c)&&(a[c]=b[c]);return a};
oa=function(a,b){var c,d,b=la(b);if(!(0>b||b>=a.length))if(0===b)a.shift();else if(b===a.length-1)a.pop();else{c=b;for(d=a.length-1;c<d;c++)a[c]=a[c+1];a.length=d}};pa=function(a,b){a.length=b.length;var c,d;c=0;for(d=b.length;c<d;c++)a[c]=b[c]};qa=function(a,b){var c=a.indexOf(b);-1!==c&&oa(a,c)};ra=function(a,b,c){return a<b?b:a>c?c:a};K=function(a){return a/(180/ka)};sa=function(a){return a*(180/ka)};ta=function(a){a%=360;0>a&&(a+=360);return a};ua=function(a){a%=2*ka;0>a&&(a+=2*ka);return a};
va=function(a){return ta(sa(a))};wa=function(a){return ua(K(a))};za=function(a,b,c,d){return Math.atan2(d-b,c-a)};Aa=function(a,b){if(a===b)return 0;var c=Math.sin(a),d=Math.cos(a),e=Math.sin(b),f=Math.cos(b),c=c*e+d*f;return 1<=c?0:-1>=c?ka:Math.acos(c)};Ba=function(a,b,c){var d=Math.sin(a),e=Math.cos(a),f=Math.sin(b),g=Math.cos(b);return Math.acos(d*f+e*g)>c?0<e*f-d*g?ua(a+c):ua(a-c):ua(b)};Ca=function(a,b){var c=Math.sin(a),d=Math.cos(a),e=Math.sin(b),f=Math.cos(b);return 0>=d*e-c*f};
Da=function(a,b,c,d){a=c-a;b=d-b;return Math.sqrt(a*a+b*b)};Ea=function(a,b){return!a!==!b};Fa=function(a){for(var b in a)a.hasOwnProperty(b)&&delete a[b]};Ga=function(){if("undefined"!==typeof window.performance){var a=window.performance;if("undefined"!==typeof a.now)return a.now();if("undefined"!==typeof a.webkitNow)return a.webkitNow();if("undefined"!==typeof a.msNow)return a.msNow()}return Date.now()};F=db.prototype;F.contains=function(a){return this.Bg.hasOwnProperty(a.toString())};
F.add=function(a){this.contains(a)||(this.Bg[a.toString()]=a,this.xh++,this.Mi=q);return this};F.remove=function(a){this.contains(a)&&(delete this.Bg[a.toString()],this.xh--,this.Mi=q);return this};F.clear=function(){Fa(this.Bg);this.xh=0;this.ji.length=0;this.Mi=m;return this};F.Bk=function(){return 0===this.xh};F.count=y("xh");F.Er=function(){if(!this.Mi){this.ji.length=this.xh;var a,b=0;for(a in this.Bg)this.Bg.hasOwnProperty(a)&&(this.ji[b++]=this.Bg[a]);this.Mi=m}};
F.Qv=function(){this.Er();return this.ji.slice(0)};F.hg=function(){this.Er();return this.ji};eb.prototype.add=function(a){this.y=a-this.g;this.ql=this.de+this.y;this.g=this.ql-this.de-this.y;this.de=this.ql};eb.prototype.reset=function(){this.de=this.ql=this.y=this.g=0};Ha=function(a){return a.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")};F=fb.prototype;F.co=function(a){this.cr=a;this.Fe=a.length/2;this.ic.length=a.length;this.ak=this.Ni=-1;this.ip=0};F.uh=function(){return!this.cr.length};
F.ol=function(a,b,c,d,e){this.ic.length=8;this.Fe=4;var f=this.ic;f[0]=a.ob-b;f[1]=a.pb-c;f[2]=a.kc-b;f[3]=a.lc-c;f[4]=a.cc-b;f[5]=a.ec-c;f[6]=a.ac-b;f[7]=a.bc-c;this.Ni=d;this.ak=e};F.kr=function(a){this.Fe=a.Fe;pa(this.ic,a.ic)};F.mh=function(a,b,c){if(!(this.Ni===a&&this.ak===b&&this.ip===c)){this.Ni=a;this.ak=b;this.ip=c;var d,e,f,g=0,h=1,i=this.cr,j=this.ic;0!==c&&(g=Math.sin(c),h=Math.cos(c));c=0;for(d=this.Fe;c<d;c++)e=i[2*c]*a,f=i[2*c+1]*b,j[2*c]=e*h-f*g,j[2*c+1]=f*h+e*g}};
F.pd=function(a,b){var c=this.ic;if(a===c[0]&&b===c[1])return m;var d=5*-this.Ni-1,e=5*-this.ak-1,f=5*this.Ni+1,g,h,i,j,k,n,r=0,s=0;k=0;for(n=this.Fe;k<n;k++)g=c[2*k],h=c[2*k+1],i=c[2*((k+1)%n)],j=c[2*((k+1)%n)+1],ma(d,e,a,b,g,h,i,j)&&r++,ma(f,-1,a,b,g,h,i,j)&&s++;return 1===r%2||1===s%2};
F.Wp=function(a,b,c){var d=a.ic,e=this.ic;if(this.pd(d[0]+b,d[1]+c)||a.pd(e[0]-b,e[1]-c))return m;var f,g,h,i,j,k,n,r,s,t,u,w;f=0;for(g=this.Fe;f<g;f++){j=e[2*f];k=e[2*f+1];n=e[2*((f+1)%g)];r=e[2*((f+1)%g)+1];h=0;for(i=a.Fe;h<i;h++)if(s=d[2*h]+b,t=d[2*h+1]+c,u=d[2*((h+1)%i)]+b,w=d[2*((h+1)%i)+1]+c,ma(j,k,n,r,s,t,u,w))return m}return q};var gb="lighter xor copy destination-over source-in destination-in source-out destination-out source-atop destination-atop".split(" ");
Ia=function(a){return 0>=a||11<=a?"source-over":gb[a-1]};
Ja=function(a,b,c){if(c)switch(a.tc=c.ONE,a.nc=c.ONE_MINUS_SRC_ALPHA,b){case 1:a.tc=c.ONE;a.nc=c.ONE;break;case 3:a.tc=c.ONE;a.nc=c.ZERO;break;case 4:a.tc=c.ONE_MINUS_DST_ALPHA;a.nc=c.ONE;break;case 5:a.tc=c.DST_ALPHA;a.nc=c.ZERO;break;case 6:a.tc=c.ZERO;a.nc=c.SRC_ALPHA;break;case 7:a.tc=c.ONE_MINUS_DST_ALPHA;a.nc=c.ZERO;break;case 8:a.tc=c.ZERO;a.nc=c.ONE_MINUS_SRC_ALPHA;break;case 9:a.tc=c.DST_ALPHA;a.nc=c.ONE_MINUS_SRC_ALPHA;break;case 10:a.tc=c.ONE_MINUS_DST_ALPHA,a.nc=c.SRC_ALPHA}};
Ka=function(a){return Math.round(1E6*a)/1E6};var hb="undefined"!==typeof Float32Array?Float32Array:Array;function ib(a){var b=new hb(3);a&&(b[0]=a[0],b[1]=a[1],b[2]=a[2]);return b}function jb(a){var b=new hb(16);a&&(b[0]=a[0],b[1]=a[1],b[2]=a[2],b[3]=a[3],b[4]=a[4],b[5]=a[5],b[6]=a[6],b[7]=a[7],b[8]=a[8],b[9]=a[9],b[10]=a[10],b[11]=a[11],b[12]=a[12],b[13]=a[13],b[14]=a[14],b[15]=a[15]);return b}
function kb(a,b){b[0]=a[0];b[1]=a[1];b[2]=a[2];b[3]=a[3];b[4]=a[4];b[5]=a[5];b[6]=a[6];b[7]=a[7];b[8]=a[8];b[9]=a[9];b[10]=a[10];b[11]=a[11];b[12]=a[12];b[13]=a[13];b[14]=a[14];b[15]=a[15]}function lb(a,b){var c=b[0],d=b[1],b=b[2];a[0]*=c;a[1]*=c;a[2]*=c;a[3]*=c;a[4]*=d;a[5]*=d;a[6]*=d;a[7]*=d;a[8]*=b;a[9]*=b;a[10]*=b;a[11]*=b}
function mb(a,b,c,d){d||(d=jb());var e,f,g,h,i,j,k,n,r=a[0],s=a[1],a=a[2];f=c[0];g=c[1];e=c[2];c=b[1];j=b[2];r===b[0]&&s===c&&a===j?(a=d,a[0]=1,a[1]=0,a[2]=0,a[3]=0,a[4]=0,a[5]=1,a[6]=0,a[7]=0,a[8]=0,a[9]=0,a[10]=1,a[11]=0,a[12]=0,a[13]=0,a[14]=0,a[15]=1):(c=r-b[0],j=s-b[1],k=a-b[2],n=1/Math.sqrt(c*c+j*j+k*k),c*=n,j*=n,k*=n,b=g*k-e*j,e=e*c-f*k,f=f*j-g*c,(n=Math.sqrt(b*b+e*e+f*f))?(n=1/n,b*=n,e*=n,f*=n):f=e=b=0,g=j*f-k*e,h=k*b-c*f,i=c*e-j*b,(n=Math.sqrt(g*g+h*h+i*i))?(n=1/n,g*=n,h*=n,i*=n):i=h=g=0,
d[0]=b,d[1]=g,d[2]=c,d[3]=0,d[4]=e,d[5]=h,d[6]=j,d[7]=0,d[8]=f,d[9]=i,d[10]=k,d[11]=0,d[12]=-(b*r+e*s+f*a),d[13]=-(g*r+h*s+i*a),d[14]=-(c*r+j*s+k*a),d[15]=1)}function nb(a){this.height=this.width=0;this.jp=ib([0,0,100]);this.xq=ib([0,0,0]);this.Cr=ib([0,1,0]);this.Bo=ib([1,1,1]);this.zn=jb();this.xd=jb();this.iq=jb();this.mm=jb();this.U=a;this.Tp()}
function ob(a,b,c){this.U=a;this.Aj=b;this.name=c;this.sd=a.getAttribLocation(b,"aPos");this.Of=a.getAttribLocation(b,"aTex");this.vq=a.getUniformLocation(b,"matP");this.Ih=a.getUniformLocation(b,"matMV");this.Jh=a.getUniformLocation(b,"opacity");this.wq=a.getUniformLocation(b,"samplerFront");this.Ok=a.getUniformLocation(b,"samplerBack");this.Hh=a.getUniformLocation(b,"destStart");this.Gh=a.getUniformLocation(b,"destEnd");this.dn=a.getUniformLocation(b,"seconds");this.cn=a.getUniformLocation(b,"pixelWidth");
this.bn=a.getUniformLocation(b,"pixelHeight");this.an=a.getUniformLocation(b,"layerScale");this.Jh&&a.uniform1f(this.Jh,1);this.wq&&a.uniform1i(this.wq,0);this.Ok&&a.uniform1i(this.Ok,1);this.Hh&&a.uniform2f(this.Hh,0,0);this.Gh&&a.uniform2f(this.Gh,1,1);this.zg=q}function pb(a,b){this.type=a;this.P=b;this.U=b.U;this.se=this.Cd=this.Vq=0;this.$=this.Zg=p;this.eo=[]}function qb(a){--a;for(var b=1;32>b;b<<=1)a|=a>>b;return a+1}F=nb.prototype;
F.Tp=function(){var a=this.U,b;this.jq=1;this.Cg=p;this.up=1;a.clearColor(0,0,0,0);a.clear(a.COLOR_BUFFER_BIT);a.enable(a.BLEND);a.blendFunc(a.ONE,a.ONE_MINUS_SRC_ALPHA);a.disable(a.CULL_FACE);a.disable(a.DEPTH_TEST);this.ox=a.getParameter(a.MAX_TEXTURE_SIZE);this.kq=a.ONE;this.fq=a.ONE_MINUS_SRC_ALPHA;this.Kn=a.createBuffer();a.bindBuffer(a.ARRAY_BUFFER,this.Kn);this.Kj=Array(4);this.Ej=Array(4);for(b=0;4>b;b++)this.Kj[b]=a.createBuffer(),a.bindBuffer(a.ARRAY_BUFFER,this.Kj[b]),this.Ej[b]=a.createBuffer(),
a.bindBuffer(a.ARRAY_BUFFER,this.Ej[b]);this.Ve=0;this.mu=a.createBuffer();a.bindBuffer(a.ELEMENT_ARRAY_BUFFER,this.mu);this.Ao=new Float32Array(16E3);this.oo=new Float32Array(16E3);this.jv=new Float32Array(32E3);for(var c=new Uint16Array(12E3),d=b=0;12E3>b;)c[b++]=d,c[b++]=d+1,c[b++]=d+2,c[b++]=d,c[b++]=d+2,c[b++]=d+3,d+=4;a.bufferData(a.ELEMENT_ARRAY_BUFFER,c,a.STATIC_DRAW);this.Ln=this.Me=0;this.Ob=[];b=this.jm({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.Ob.push(b);b=this.jm({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.Ob.push(b);for(var e in rb)rb.hasOwnProperty(e)&&this.Ob.push(this.jm(rb[e],"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}",e));a.activeTexture(a.TEXTURE0);a.bindTexture(a.TEXTURE_2D,p);this.Gf=[];this.Pe=0;this.rd=this.Qc=q;this.vp=this.fj=-1;this.Ri=p;this.It=a.createFramebuffer();this.fr=
p;this.gg=ib([0,0,0]);a=a.getParameter(a.ALIASED_POINT_SIZE_RANGE);this.px=a[0];this.nx=a[1];this.Je(0)};
F.jm=function(a,b,c){var d=this.U,e=d.createShader(d.FRAGMENT_SHADER);d.shaderSource(e,a.src);d.compileShader(e);if(!d.getShaderParameter(e,d.COMPILE_STATUS))return d.deleteShader(e),p;var f=d.createShader(d.VERTEX_SHADER);d.shaderSource(f,b);d.compileShader(f);if(!d.getShaderParameter(f,d.COMPILE_STATUS))return d.deleteShader(e),d.deleteShader(f),p;b=d.createProgram();d.attachShader(b,e);d.attachShader(b,f);d.linkProgram(b);if(!d.getProgramParameter(b,d.LINK_STATUS))return d.deleteShader(e),d.deleteShader(f),
d.deleteProgram(b),p;d.useProgram(b);d.validateProgram(b);d.deleteShader(e);d.deleteShader(f);c=new ob(d,b,c);c.Ti=a.Ti||0;c.Ui=a.Ui||0;c.gk=!!a.gk;c.Uj=!!a.Uj;c.N=a.N||[];a=0;for(e=c.N.length;a<e;a++)c.N[a][1]=d.getUniformLocation(b,c.N[a][0]),d.uniform1f(c.N[a][1],0);return c};F.Fm=function(a){var b,c;b=0;for(c=this.Ob.length;b<c;b++)if(this.Ob[b].name===a)return b;return-1};
F.br=function(a,b,c){var d=[0,0,this.width,this.height],e=this.xd,f=this.zn,g=[0,0,0,0,0,0,0,0];g[0]=e[0]*a+e[4]*b+e[12];g[1]=e[1]*a+e[5]*b+e[13];g[2]=e[2]*a+e[6]*b+e[14];g[3]=e[3]*a+e[7]*b+e[15];g[4]=f[0]*g[0]+f[4]*g[1]+f[8]*g[2]+f[12]*g[3];g[5]=f[1]*g[0]+f[5]*g[1]+f[9]*g[2]+f[13]*g[3];g[6]=f[2]*g[0]+f[6]*g[1]+f[10]*g[2]+f[14]*g[3];g[7]=-g[2];0!==g[7]&&(g[7]=1/g[7],g[4]*=g[7],g[5]*=g[7],g[6]*=g[7],c[0]=(0.5*g[4]+0.5)*d[2]+d[0],c[1]=(0.5*g[5]+0.5)*d[3]+d[1])};
F.$n=function(a,b,c){if(!(this.width===a&&this.height===b&&!c)){this.Kf();this.width=a;this.height=b;this.U.viewport(0,0,a,b);var b=a/b,d=this.zn,e;e=1*Math.tan(45*Math.PI/360);b*=e;a=-b;c=-e;d||(d=jb());var f=b-a,g=e-c;d[0]=2/f;d[1]=0;d[2]=0;d[3]=0;d[4]=0;d[5]=2/g;d[6]=0;d[7]=0;d[8]=(b+a)/f;d[9]=(e+c)/g;d[10]=-1001/999;d[11]=-1;d[12]=0;d[13]=0;d[14]=-2E3/999;d[15]=0;mb(this.jp,this.xq,this.Cr,this.xd);a=[0,0];b=[0,0];this.br(0,0,a);this.br(1,1,b);this.Bo[0]=1/(b[0]-a[0]);this.Bo[1]=-1/(b[1]-a[1]);
a=0;for(b=this.Ob.length;a<b;a++)c=this.Ob[a],c.zg=q,c.vq&&(this.U.useProgram(c.Aj),this.U.uniformMatrix4fv(c.vq,q,this.zn));this.U.useProgram(this.Ob[this.fj].Aj);this.U.bindTexture(this.U.TEXTURE_2D,p);this.Cg=p}};F.Ie=function(){mb(this.jp,this.xq,this.Cr,this.xd);lb(this.xd,this.Bo)};
F.translate=function(a,b){if(!(0===a&&0===b)){this.gg[0]=a;this.gg[1]=b;this.gg[2]=0;var c=this.xd,d=this.gg,e=d[0],f=d[1],d=d[2];c[12]=c[0]*e+c[4]*f+c[8]*d+c[12];c[13]=c[1]*e+c[5]*f+c[9]*d+c[13];c[14]=c[2]*e+c[6]*f+c[10]*d+c[14];c[15]=c[3]*e+c[7]*f+c[11]*d+c[15]}};F.scale=function(a,b){1===a&&1===b||(this.gg[0]=a,this.gg[1]=b,this.gg[2]=1,lb(this.xd,this.gg))};
F.Xn=function(a){if(0!==a){var b=this.xd,c,d=Math.sin(a),a=Math.cos(a),e=b[0],f=b[1],g=b[2],h=b[3],i=b[4],j=b[5],k=b[6],n=b[7];c?b!==c&&(c[8]=b[8],c[9]=b[9],c[10]=b[10],c[11]=b[11],c[12]=b[12],c[13]=b[13],c[14]=b[14],c[15]=b[15]):c=b;c[0]=e*a+i*d;c[1]=f*a+j*d;c[2]=g*a+k*d;c[3]=h*a+n*d;c[4]=e*-d+i*a;c[5]=f*-d+j*a;c[6]=g*-d+k*a;c[7]=h*-d+n*a}};
F.Le=function(){for(var a=q,b=0;16>b;b++)if(this.iq[b]!==this.xd[b]){a=m;break}a&&(a=this.be(),a.type=5,a.$?kb(this.xd,a.$):a.$=jb(this.xd),kb(this.xd,this.iq),this.rd=this.Qc=q)};F=pb.prototype;F.ft=function(){this.U.bindTexture(this.U.TEXTURE_2D,this.Zg)};F.ct=function(){var a=this.Vq,b=this.P;b.up=a;b=b.Ri;b.Jh&&this.U.uniform1f(b.Jh,a)};F.$s=function(){this.U.drawElements(this.U.TRIANGLES,this.se,this.U.UNSIGNED_SHORT,2*this.Cd)};F.bt=function(){this.U.blendFunc(this.Cd,this.se)};
F.gt=function(){var a,b,c,d=this.P.Ob,e=this.P.vp;a=0;for(b=d.length;a<b;a++)c=d[a],a===e&&c.Ih?(this.U.uniformMatrix4fv(c.Ih,q,this.$),c.zg=m):c.zg=q;kb(this.$,this.P.mm)};F.at=function(){var a=this.U,b=this.P;this.Zg?(a.bindFramebuffer(a.FRAMEBUFFER,b.It),a.framebufferTexture2D(a.FRAMEBUFFER,a.COLOR_ATTACHMENT0,a.TEXTURE_2D,this.Zg,0)):(a.framebufferTexture2D(a.FRAMEBUFFER,a.COLOR_ATTACHMENT0,a.TEXTURE_2D,p,0),a.bindFramebuffer(a.FRAMEBUFFER,p))};
F.Vs=function(){var a=this.U;0===this.Cd?(a.clearColor(this.$[0],this.$[1],this.$[2],this.$[3]),a.clear(a.COLOR_BUFFER_BIT)):(a.enable(a.SCISSOR_TEST),a.scissor(this.$[0],this.$[1],this.$[2],this.$[3]),a.clearColor(0,0,0,0),a.clear(this.U.COLOR_BUFFER_BIT),a.disable(a.SCISSOR_TEST))};
F.Zs=function(){var a=this.U,b=this.P,c=b.Ob[1];a.useProgram(c.Aj);!c.zg&&c.Ih&&(a.uniformMatrix4fv(c.Ih,q,b.mm),c.zg=m);a.enableVertexAttribArray(c.sd);a.bindBuffer(a.ARRAY_BUFFER,b.Kn);a.vertexAttribPointer(c.sd,4,a.FLOAT,q,0,0);a.drawArrays(a.POINTS,this.Cd/4,this.se);c=b.Ri;a.useProgram(c.Aj);0<=c.sd&&(a.enableVertexAttribArray(c.sd),a.bindBuffer(a.ARRAY_BUFFER,b.Kj[b.Ve]),a.vertexAttribPointer(c.sd,2,a.FLOAT,q,0,0));0<=c.Of&&(a.enableVertexAttribArray(c.Of),a.bindBuffer(a.ARRAY_BUFFER,b.Ej[b.Ve]),
a.vertexAttribPointer(c.Of,2,a.FLOAT,q,0,0))};F.dt=function(){var a=this.U,b=this.P,c=b.Ob[this.Cd];b.vp=this.Cd;b.Ri=c;a.useProgram(c.Aj);!c.zg&&c.Ih&&(a.uniformMatrix4fv(c.Ih,q,b.mm),c.zg=m);c.Jh&&a.uniform1f(c.Jh,b.up);0<=c.sd&&(a.enableVertexAttribArray(c.sd),a.bindBuffer(a.ARRAY_BUFFER,b.Kj[b.Ve]),a.vertexAttribPointer(c.sd,2,a.FLOAT,q,0,0));0<=c.Of&&(a.enableVertexAttribArray(c.Of),a.bindBuffer(a.ARRAY_BUFFER,b.Ej[b.Ve]),a.vertexAttribPointer(c.Of,2,a.FLOAT,q,0,0))};
F.et=function(){var a,b,c=this.P.Ri,d=this.U;c.Ok&&(d.activeTexture(d.TEXTURE1),d.bindTexture(d.TEXTURE_2D,this.Zg),d.activeTexture(d.TEXTURE0));c.cn&&d.uniform1f(c.cn,this.$[0]);c.bn&&d.uniform1f(c.bn,this.$[1]);c.Hh&&d.uniform2f(c.Hh,this.$[2],this.$[3]);c.Gh&&d.uniform2f(c.Gh,this.$[4],this.$[5]);c.an&&d.uniform1f(c.an,this.$[6]);c.dn&&d.uniform1f(c.dn,Ga()/1E3);if(c.N.length){a=0;for(b=c.N.length;a<b;a++)d.uniform1f(c.N[a][1],this.eo[a])}};F=nb.prototype;
F.be=function(){this.Pe===this.Gf.length&&this.Gf.push(new pb(0,this));return this.Gf[this.Pe++]};
F.Kf=function(){if(0!==this.Pe&&!this.U.isContextLost()){var a=this.U;0<this.Ln&&(a.bindBuffer(a.ARRAY_BUFFER,this.Kn),a.bufferData(a.ARRAY_BUFFER,this.jv.subarray(0,this.Ln),a.STREAM_DRAW),b&&(0<=b.sd&&"<point>"===b.name)&&a.vertexAttribPointer(b.sd,4,a.FLOAT,q,0,0));if(0<this.Me){var b=this.Ri;a.bindBuffer(a.ARRAY_BUFFER,this.Kj[this.Ve]);a.bufferData(a.ARRAY_BUFFER,this.Ao.subarray(0,this.Me),a.STREAM_DRAW);b&&(0<=b.sd&&"<point>"!==b.name)&&a.vertexAttribPointer(b.sd,2,a.FLOAT,q,0,0);a.bindBuffer(a.ARRAY_BUFFER,
this.Ej[this.Ve]);a.bufferData(a.ARRAY_BUFFER,this.oo.subarray(0,this.Me),a.STREAM_DRAW);b&&(0<=b.Of&&"<point>"!==b.name)&&a.vertexAttribPointer(b.Of,2,a.FLOAT,q,0,0)}for(var c,a=0,b=this.Pe;a<b;a++)switch(c=this.Gf[a],c.type){case 1:c.$s();break;case 2:c.ft();break;case 3:c.ct();break;case 4:c.bt();break;case 5:c.gt();break;case 6:c.at();break;case 7:c.Vs();break;case 8:c.Zs();break;case 9:c.dt();break;case 10:c.et()}this.Ln=this.Me=this.Pe=0;this.rd=this.Qc=q;this.Ve++;4<=this.Ve&&(this.Ve=0)}};
F.Vg=function(a){if(a!==this.jq){var b=this.be();b.type=3;this.jq=b.Vq=a;this.rd=this.Qc=q}};F.gd=function(a){if(a!==this.Cg){var b=this.be();b.type=2;this.Cg=b.Zg=a;this.rd=this.Qc=q}};F.ag=function(a,b){if(!(a===this.kq&&b===this.fq)){var c=this.be();c.type=4;c.Cd=a;c.se=b;this.kq=a;this.fq=b;this.rd=this.Qc=q}};F.jr=function(){this.ag(this.U.ONE,this.U.ONE_MINUS_SRC_ALPHA)};
F.hl=function(a,b,c,d,e,f,g,h){15992<=this.Me&&this.Kf();var i=this.Me,j=this.Ao,k=this.oo;if(this.Qc)this.Gf[this.Pe-1].se+=6;else{var n=this.be();n.type=1;n.Cd=3*(i/4);n.se=6;this.Qc=m;this.rd=q}j[i]=a;k[i++]=0;j[i]=b;k[i++]=0;j[i]=c;k[i++]=1;j[i]=d;k[i++]=0;j[i]=e;k[i++]=1;j[i]=f;k[i++]=1;j[i]=g;k[i++]=0;j[i]=h;k[i++]=1;this.Me=i};
F.Ge=function(a,b,c,d,e,f,g,h,i){15992<=this.Me&&this.Kf();var j=this.Me,k=this.Ao,n=this.oo;if(this.Qc)this.Gf[this.Pe-1].se+=6;else{var r=this.be();r.type=1;r.Cd=3*(j/4);r.se=6;this.Qc=m;this.rd=q}k[j]=a;n[j++]=i.left;k[j]=b;n[j++]=i.top;k[j]=c;n[j++]=i.right;k[j]=d;n[j++]=i.top;k[j]=e;n[j++]=i.right;k[j]=f;n[j++]=i.bottom;k[j]=g;n[j++]=i.left;k[j]=h;n[j++]=i.bottom;this.Me=j};
F.Je=function(a){if(this.fj!==a){if(!this.Ob[a]){if(0===this.fj)return;a=0}var b=this.be();b.type=9;this.fj=b.Cd=a;this.rd=this.Qc=q}};F.vj=function(a){a=this.Ob[a];return!(!a.Hh&&!a.Gh)};F.Nn=function(a){return this.Ob[a].gk};F.ov=function(a){a=this.Ob[a];return 0!==a.Ti||0!==a.Ui};F.Rt=function(a){return this.Ob[a].Ti};F.St=function(a){return this.Ob[a].Ui};F.Tt=function(a,b){return this.Ob[a].N[b][2]};F.fl=function(a){return this.Ob[a].Uj};
F.$h=function(a,b,c,d,e,f,g,h,i){var j=this.Ob[this.fj];if(j.cn||j.bn||j.dn||j.Ok||j.Hh||j.Gh||j.an||i.length){j=this.be();j.type=10;j.$?kb(this.xd,j.$):j.$=jb();j.$[0]=b;j.$[1]=c;j.$[2]=d;j.$[3]=e;j.$[4]=f;j.$[5]=g;j.$[6]=h;j.Zg=a;if(i.length){j.eo.length=i.length;a=0;for(b=i.length;a<b;a++)j.eo[a]=i[a]}this.rd=this.Qc=q}};F.clear=function(a,b,c,d){var e=this.be();e.type=7;e.Cd=0;e.$||(e.$=jb());e.$[0]=a;e.$[1]=b;e.$[2]=c;e.$[3]=d;this.rd=this.Qc=q};
F.clearRect=function(a,b,c,d){var e=this.be();e.type=7;e.Cd=1;e.$||(e.$=jb());e.$[0]=a;e.$[1]=b;e.$[2]=c;e.$[3]=d;this.rd=this.Qc=q};F.mv=function(){this.Kf();this.U.flush()};var sb=[];F=nb.prototype;
F.Nk=function(a,b,c,d){this.Kf();var e=this.U,f=ga(a.width)&&ga(a.height),g=e.createTexture();e.bindTexture(e.TEXTURE_2D,g);e.pixelStorei(e.UNPACK_PREMULTIPLY_ALPHA_WEBGL,m);var h=e.RGBA,i=e.RGBA,j=e.UNSIGNED_BYTE;if(d)switch(d){case 1:i=h=e.RGB;break;case 2:j=e.UNSIGNED_SHORT_4_4_4_4;break;case 3:j=e.UNSIGNED_SHORT_5_5_5_1;break;case 4:i=h=e.RGB,j=e.UNSIGNED_SHORT_5_6_5}!f&&b?(d=document.createElement("canvas"),d.width=qb(a.width),d.height=qb(a.height),d.getContext("2d").drawImage(a,0,0,a.width,
a.height,0,0,d.width,d.height),e.texImage2D(e.TEXTURE_2D,0,h,i,j,d)):e.texImage2D(e.TEXTURE_2D,0,h,i,j,a);e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_S,b?e.REPEAT:e.CLAMP_TO_EDGE);e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_T,b?e.REPEAT:e.CLAMP_TO_EDGE);c?(e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MAG_FILTER,e.LINEAR),f?(e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,e.LINEAR_MIPMAP_NEAREST),e.generateMipmap(e.TEXTURE_2D)):e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,e.LINEAR)):(e.texParameteri(e.TEXTURE_2D,
e.TEXTURE_MAG_FILTER,e.NEAREST),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,e.NEAREST));e.bindTexture(e.TEXTURE_2D,p);this.Cg=p;g.Li=a.width;g.Ji=a.height;sb.push(g);return g};
F.Te=function(a,b,c,d){this.Kf();var e=this.U,f=e.createTexture();e.bindTexture(e.TEXTURE_2D,f);e.texImage2D(e.TEXTURE_2D,0,e.RGBA,a,b,0,e.RGBA,d?e.UNSIGNED_SHORT_4_4_4_4:e.UNSIGNED_BYTE,p);e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_S,e.CLAMP_TO_EDGE);e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_T,e.CLAMP_TO_EDGE);e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MAG_FILTER,c?e.LINEAR:e.NEAREST);e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,c?e.LINEAR:e.NEAREST);e.bindTexture(e.TEXTURE_2D,p);this.Cg=p;f.Li=
a;f.Ji=b;sb.push(f);return f};F.Sv=function(a,b,c){this.Kf();var d=this.U;d.bindTexture(d.TEXTURE_2D,b);d.texImage2D(d.TEXTURE_2D,0,d.RGBA,d.RGBA,c?d.UNSIGNED_SHORT_4_4_4_4:d.UNSIGNED_BYTE,a);d.bindTexture(d.TEXTURE_2D,p);this.Cg=p};F.deleteTexture=function(a){this.Kf();this.U.bindTexture(this.U.TEXTURE_2D,p);this.Cg=p;this.U.deleteTexture(a);qa(sb,a)};F.uf=function(a){if(a!==this.fr){var b=this.be();b.type=6;this.fr=b.Zg=a;this.rd=this.Qc=q}};
function tb(a){if(a&&(a.getContext||a.dc)&&!a.c2runtime){a.c2runtime=this;var b=this;this.Pm="undefined"!==typeof window.device&&("undefined"!==typeof window.device.cordova||"undefined"!==typeof window.device.phonegap);this.te=!!a.dc;this.Yp="undefined"!==typeof window.AppMobi||this.te;if(this.dj=!!window.c2cocoonjs)CocoonJS.App.onSuspended.addEventListener(function(){b.ao(m)}),CocoonJS.App.onActivated.addEventListener(function(){b.ao(q)});this.pc=this.te||this.dj;this.Xp=/android/i.test(navigator.userAgent);
this.$w=/msie/i.test(navigator.userAgent);this.Hk=/iphone/i.test(navigator.userAgent)||/ipod/i.test(navigator.userAgent);this.cq=/ipad/i.test(navigator.userAgent);this.cf=this.Hk||this.cq;this.Zp=/chrome/i.test(navigator.userAgent)||/chromium/i.test(navigator.userAgent);this.tu=!this.Zp&&/safari/i.test(navigator.userAgent);this.$p=/windows/i.test(navigator.userAgent);this.cj=/awesomium/i.test(navigator.userAgent);this.ru="undefined"!==typeof window.is_scirra_arcade;this.devicePixelRatio=1;this.th=
this.Pm||this.Yp||this.dj||this.Xp||this.cf;this.th||(this.th=/(blackberry|bb10|playbook|palm|symbian|nokia|windows\s+ce|phone|mobile|tablet)/i.test(navigator.userAgent));this.canvas=a;this.bk=document.getElementById("c2canvasdiv");this.La=this.P=this.U=p;this.canvas.oncontextmenu=function(a){a.preventDefault&&a.preventDefault();return q};this.canvas.Uq=function(a){a.preventDefault&&a.preventDefault();return q};this.te&&(window.c2runtime=this);this.width=a.width;this.height=a.height;this.Ch=this.width;
this.Bh=this.height;this.Pa=m;this.ej=q;Date.now||(Date.now=function(){return+new Date});this.plugins=[];this.types={};this.da=[];this.Sb=[];this.Xm={};this.Dh=[];this.um={};this.ug=[];this.wf=[];this.xl=[];this.As=[];this.Xe=new db;this.Nm=q;this.Od=0;this.Qm=q;this.Ue=[];this.Zv=this.im=this.Qk=this.Jf=this.fa=0;this.fg=1;this.Nf=new eb;this.Kk=0;this.Lq=m;this.bl=this.ok=this.vm=this.eg=this.gj=this.zm=0;this.Hf=p;this.ik=[];this.tm=[];this.kk=-1;this.en=[[]];this.uo=this.Pk=0;this.gl(p);this.gn=
[];this.Rk=-1;this.al=0;this.uq=m;this.Vi=0;this.Bj=[];this.so=this.Qn=0;this.wh=m;this.Fh=0;this.Ak=q;this.Gv=0;this.Hm=q;this.En=new db;this.Sq=new db;this.il=[];this.Yg=new fb([]);this.mo=new fb([]);this.Vl=[];this.Xo={};this.Pd=this.Zc=this.tq=this.Lk=this.bb=p;this.ii=this.Rm=q;this.Cm=[p,p];this.Bm=0;this.Jt="";this.pl=this.Eh=p;this.Ev="";this.load();this.devicePixelRatio=!this.pc&&this.Al&&this.cf?window.devicePixelRatio||1:1;this.ld();var c;"undefined"!==typeof jQuery&&0<this.Mf&&this.setSize(jQuery(window).width(),
jQuery(window).height());try{if(this.it&&!this.pc){c={depth:q,antialias:!this.th};var d=m;if(this.Zp&&this.$p){var e=document.createElement("canvas");if("OES_texture_float,OES_standard_derivatives,WEBKIT_WEBGL_lose_context"===(e.getContext("webgl",c)||e.getContext("experimental-webgl",c)).getSupportedExtensions().toString())d=q}d&&(this.U=a.getContext("webgl",c)||a.getContext("experimental-webgl",c))}}catch(f){}if(this.U){this.Lc=document.createElement("canvas");jQuery(this.Lc).appendTo(this.canvas.parentNode);
this.Lc.oncontextmenu=D(q);this.Lc.Uq=D(q);this.Lc.width=a.width;this.Lc.height=a.height;this.Zq();this.In=this.Lc.getContext("2d");this.P=new nb(this.U);this.P.$n(a.width,a.height);this.La=p;this.canvas.addEventListener("webglcontextlost",function(a){console.log("WebGL context lost");a.preventDefault();b.$u();window.cr_setSuspended(m)},q);this.canvas.addEventListener("webglcontextrestored",function(){console.log("WebGL context restored");b.P.Tp();b.P.$n(b.P.width,b.P.height,m);b.Zc=p;b.Pd=p;b.Cm[0]=
p;b.Cm[1]=p;b.av();b.Pa=m;window.cr_setSuspended(q)},q);var g,h,i,j,k,a=0;for(c=this.da.length;a<c;a++){g=this.da[a];d=0;for(e=g.Ea.length;d<e;d++)i=g.Ea[d],i.jc=this.P.Fm(i.id),this.ii=this.ii||this.P.vj(i.jc)}a=0;for(c=this.Dh.length;a<c;a++){j=this.Dh[a];d=0;for(e=j.Ea.length;d<e;d++)i=j.Ea[d],i.jc=this.P.Fm(i.id);d=0;for(e=j.Ta.length;d<e;d++){k=j.Ta[d];g=0;for(h=k.Ea.length;g<h;g++)i=k.Ea[g],i.jc=this.P.Fm(i.id),this.ii=this.ii||this.P.vj(i.jc)}}}else{if(0<this.Mf&&this.te){this.canvas=p;document.oncontextmenu=
D(q);document.Uq=D(q);this.La=AppMobi.canvas.getContext("2d");try{this.La.samplingMode=this.ib?"smooth":"sharp",this.La.globalScale=1,this.La.HTML5CompatibilityMode=m}catch(n){}0!==this.width&&0!==this.height&&(this.La.width=this.width,this.La.height=this.height)}this.La||(this.dj?(c={antialias:!!this.ib},this.La=a.getContext("2d",c)):this.La=a.getContext("2d"),this.La.webkitImageSmoothingEnabled=this.ib,this.La.mozImageSmoothingEnabled=this.ib,this.La.msImageSmoothingEnabled=this.ib,this.La.imageSmoothingEnabled=
this.ib);this.In=this.Lc=p}var r=this;this.vr=function(){r.Gc()};this.go();this.Ma={}}}
tb.prototype.setSize=function(a,b){var c=this.iu&&this.Hk&&!navigator.standalone&&!this.pc&&!this.Pm,d=0;c&&(this.Hk?d=60:this.Xp&&(d=56),b+=d);var e=0,f=0,g=0,h=0,i=0,i=this.Mf,j=document.mozFullScreen||document.webkitIsFullScreen||document.fullScreen||this.Ak;j&&0<this.Bm&&(i=this.Bm);3<=i?(g=this.Uc/this.Tc,a/b>g?(g*=b,4===i?(i=g/this.Uc,1<i?i=Math.floor(i):1>i&&(i=1/Math.ceil(1/i)),g=this.Uc*i,h=this.Tc*i,e=(a-g)/2,f=(b-h)/2,a=g,b=h):(e=(a-g)/2,a=g)):(h=a/g,4===i?(i=h/this.Tc,1<i?i=Math.floor(i):
1>i&&(i=1/Math.ceil(1/i)),g=this.Uc*i,h=this.Tc*i,e=(a-g)/2,f=(b-h)/2,a=g):f=(b-h)/2,b=h),j&&!this.cj&&(f=e=0),e=Math.floor(e),f=Math.floor(f),a=Math.floor(a),b=Math.floor(b)):this.cj&&(this.Ak&&0===this.Gp)&&(e=Math.floor((a-this.Uc)/2),f=Math.floor((b-this.Tc)/2),a=this.Uc,b=this.Tc);if((j=!this.pc&&this.Al&&this.cf)&&this.cq&&1<this.devicePixelRatio)1024<=a&&(a=1023),1024<=b&&(b=1023);g=this.devicePixelRatio;this.width=a*g;this.height=b*g;this.Pa=m;this.bk&&!this.pc&&(jQuery(this.bk).css({width:a+
"px",height:b+"px","margin-left":e,"margin-top":f}),"undefined"!==typeof cr_is_preview&&jQuery("#borderwrap").css({width:a+"px",height:b+"px"}));this.canvas&&(this.canvas.width=a*g,this.canvas.height=b*g,j&&jQuery(this.canvas).css({width:a+"px",height:b+"px"}));this.Lc&&(this.Lc.width=a,this.Lc.height=b);this.P&&this.P.$n(a,b);this.te&&this.La&&(this.La.width=a,this.La.height=b);this.La&&(this.La.webkitImageSmoothingEnabled=this.ib,this.La.mozImageSmoothingEnabled=this.ib,this.La.msImageSmoothingEnabled=
this.ib,this.La.imageSmoothingEnabled=this.ib);c&&0<d&&window.setTimeout(function(){window.scrollTo(0,1)},100)};tb.prototype.$u=function(){this.Rm=m;var a,b,c;a=0;for(b=this.da.length;a<b;a++)c=this.da[a],c.cl&&c.cl()};tb.prototype.av=function(){this.Rm=q;var a,b,c;a=0;for(b=this.da.length;a<b;a++)c=this.da[a],c.Hn&&c.Hn()};
tb.prototype.Zq=function(){var a=document.mozFullScreen||document.webkitIsFullScreen||document.fullScreen||this.Ak?jQuery(this.canvas).offset():jQuery(this.canvas).position();a.position="absolute";jQuery(this.Lc).css(a)};var ub=window.cancelAnimationFrame||window.mozCancelAnimationFrame||window.webkitCancelAnimationFrame||window.msCancelAnimationFrame||window.oCancelAnimationFrame;
tb.prototype.setSuspended=function(a){var b;if(a&&!this.ej){this.ej=m;0!==this.Qn&&ub&&ub(this.Qn);0!==this.so&&clearTimeout(this.so);a=0;for(b=this.Bj.length;a<b;a++)this.Bj[a](m)}else if(!a&&this.ej){this.ej=q;this.Kk=Ga();this.gj=Ga();a=this.ok=0;for(b=this.Bj.length;a<b;a++)this.Bj[a](q);this.Gc()}};F=tb.prototype;F.$o=function(a){this.Bj.push(a)};
F.load=function(){var a=vb();this.name=a[0];this.Cp=a[1];this.Mf=a[11];this.Gp=a[11];this.pc&&3<=a[11]&&(da("[Construct 2] Letterbox scale fullscreen modes are not supported on this platform - falling back to 'Scale'"),this.Gp=this.Mf=2);this.yo=a[17];this.hj=a[18];0===this.hj&&(this.Eh=new Image,this.Eh.src="logo.png");this.Xg=new L(this);var b,c,d,e,f,g,h,i,j;b=0;for(c=a[2].length;b<c;b++)h=a[2][b],wb(h),j=new h[0](this),j.io=h[1],j.Gk=h[2],j.Nq=h[9],j.X&&j.X(),this.plugins.push(j);a=vb();b=0;for(c=
a[3].length;b<c;b++){h=a[3][b];f=h[1];j=p;d=0;for(e=this.plugins.length;d<e;d++)if(this.plugins[d]instanceof f){j=this.plugins[d];break}var k=new j.ta(j);k.name=h[0];k.Sa=h[2];k.Rv=h[3];k.Ks=h[4];k.Lt=h[5];k.Sa?(k.Zk=[],k.ne=this.Vi++,k.Kb=p):(k.Zk=p,k.ne=-1,k.Kb=[]);k.mk=p;k.qh=p;k.yp=p;k.ue=q;k.Xc=p;h[6]?(k.po=h[6][0],k.qo=h[6][1],k.ro=h[6][2]):(k.po=p,k.qo=0,k.ro=0);k.Qb=h[7]?h[7]:p;k.index=b;k.l=[];k.hk=[];k.dg=[new La(k)];k.We=0;k.le=p;k.Wg=m;k.yl=xb;k.Zw=yb;k.Qt=zb;k.Na=Ab;k.wj=Bb;k.xj=Cb;k.Yf=
Db;k.pk=Eb;k.Dm=Fb;k.Jp=Gb;k.Gi=Hb;k.Ma={};k.toString=Ib;k.Sb=[];d=0;for(e=h[8].length;d<e;d++){i=h[8][d];var n=i[1],r=p;f=0;for(g=this.Sb.length;f<g;f++)if(this.Sb[f]instanceof n){r=this.Sb[f];break}r||(r=new n(this),r.Th=new db,r.X&&r.X(),this.Sb.push(r));f=new r.ta(r,k);f.name=i[0];f.X();k.Sb.push(f)}k.global=h[9];k.Om=h[10];k.Ea=[];d=0;for(e=h[11].length;d<e;d++)k.Ea.push({id:h[11][d][0],name:h[11][d][1],jc:-1,ie:m,index:d});(!this.yo||k.Sa||k.Om||!j.Gk)&&k.X();k.name&&(this.types[k.name]=k);
this.da.push(k);j.io&&(d=new j.la(k),d.uid=this.al,this.al++,d.aj=0,d.uk=Jb,d.toString=Kb,d.G=h[12],d.X(),k.l.push(d))}b=0;for(c=a[4].length;b<c;b++){f=a[4][b];g=this.da[f[0]];d=1;for(e=f.length;d<e;d++)h=this.da[f[d]],h.Kb.push(g),g.Zk.push(h)}b=0;for(c=a[20].length;b<c;b++){f=a[20][b];g=[];d=0;for(e=f.length;d<e;d++)g.push(this.da[f[d]]);d=0;for(e=g.length;d<e;d++)g[d].ue=m,g[d].Xc=g}if(0<this.Vi){b=0;for(c=this.da.length;b<c;b++)if(h=this.da[b],!h.Sa&&h.Kb.length){h.mk=Array(this.Vi);h.qh=Array(this.Vi);
h.yp=Array(this.Vi);k=[];d=r=n=i=0;for(e=h.Kb.length;d<e;d++){j=h.Kb[d];h.mk[j.ne]=i;i+=j.Rv;h.qh[j.ne]=n;n+=j.Ks;h.yp[j.ne]=r;r+=j.Lt;f=0;for(g=j.Ea.length;f<g;f++)k.push(na({},j.Ea[f]))}h.Ea=k.concat(h.Ea);d=0;for(e=h.Ea.length;d<e;d++)h.Ea[d].index=d}}b=0;for(c=a[5].length;b<c;b++)h=a[5][b],d=new Ma(this,h),this.Xm[d.name]=d,this.Dh.push(d);b=0;for(c=a[6].length;b<c;b++)h=a[6][b],d=new Na(this,h),this.um[d.name]=d,this.ug.push(d);b=0;for(c=this.ug.length;b<c;b++)this.ug[b].xb();b=0;for(c=this.xl.length;b<
c;b++)this.xl[b].xb();this.xl.length=0;this.Jt=a[7];this.Ee=a[8];this.Uc=a[9];this.Tc=a[10];this.Yl=1;this.it=a[12];this.ib=a[13];this.kp=a[14];this.Ax=a[15];b=a[16];2===b&&(b=this.Hk?1:0);this.Al=0!==b;this.iu=a[19];this.lo=Date.now()};F.Kt=function(a){var b,c;b=0;for(c=this.wf.length;b<c;b++)if(this.wf[b].Os===a)return this.wf[b];return p};
F.ep=function(){var a=0,b=0,c=m,d,e;d=0;for(e=this.wf.length;d<e;d++){var f=this.wf[d].qp;if(!f||0>=f)f=5E4;a+=f;this.wf[d].complete||this.wf[d].loaded?b+=f:c=q}this.Tg=0==a?0:b/a;return c};
F.go=function(){if(this.La||this.P){var a=this.La||this.In;this.Lc&&this.Zq();this.Tg=0;this.nq=-1;if(this.ep())this.gu();else{var b=Date.now()-this.lo;if(3!==this.hj&&500<=b&&this.nq!=this.Tg){a.clearRect(0,0,this.width,this.height);var b=this.width/2,c=this.height/2,d=0===this.hj&&this.Eh.complete,e=40,f=0,g=80;d&&(g=this.Eh.width,e=g/2,f=this.Eh.height/2,a.drawImage(this.Eh,la(b-e),la(c-f)));1>=this.hj?(b=la(b-e)+0.5,c=la(c+(f+(d?12:0)))+0.5,a.fillStyle="DodgerBlue",a.fillRect(b,c,Math.floor(g*
this.Tg),6),a.strokeStyle="black",a.strokeRect(b,c,g,6),a.strokeStyle="white",a.strokeRect(b-1,c-1,g+2,8)):2===this.hj&&(a.font="12pt Arial",a.fillStyle="#999",a.ux="middle",d=Math.round(100*this.Tg)+"%",e=a.measureText?a.measureText(d):p,a.fillText(d,b-(e?e.width:0)/2,c));this.nq=this.Tg}var h=this;setTimeout(function(){h.go()},100)}}};
F.gu=function(){this.Lc&&(this.canvas.parentNode.removeChild(this.Lc),this.Lc=this.In=p);this.lo=Date.now();this.gj=Ga();var a,b,c;if(this.yo){a=0;for(b=this.da.length;a<b;a++)c=this.da[a],!c.Sa&&(!c.Om&&c.Mb.Gk)&&c.X()}else this.wh=q;a=0;for(b=this.Dh.length;a<b;a++)this.Dh[a].Ps();this.Cp?this.Xm[this.Cp].ko():this.Dh[0].ko();this.yo||(this.Fh=1,this.trigger(L.prototype.C.Oo,p));this.Gc();this.te&&AppMobi.webview.execute("onGameReady();")};
var Lb=window.requestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||window.msRequestAnimationFrame||window.oRequestAnimationFrame;F=tb.prototype;
F.Gc=function(){if(this.ru){var a=jQuery(window).width(),b=jQuery(window).height();if(this.Ch!==a||this.Bh!==b)this.Ch=a,this.Bh=b,this.setSize(a,b)}a=Ga();this.wh&&(b=this.ep(),this.Fh=this.Tg,b&&(this.wh=q,this.Tg=1,this.trigger(L.prototype.C.Oo,p)));this.Bu();if((this.Pa||this.cj&&60>this.eg)&&!this.Rm)this.Pa=q,this.P?this.Yc():this.Kd(),this.pl&&(this.canvas&&this.canvas.toDataURL&&(this.Ev=this.canvas.toDataURL(this.pl[0],this.pl[1]),this.trigger(L.prototype.C.Xr,p)),this.pl=p);this.eg++;this.vm++;
this.ok++;this.Qk+=Ga()-a;this.ej||(Lb?this.Qn=Lb(this.vr,this.canvas):this.so=setTimeout(this.vr,this.th?1:16))};
F.Bu=function(){var a,b,c,d,e,f,g,h;a=Ga();1E3<=a-this.gj&&(this.gj+=1E3,this.zm=this.ok,this.ok=0,this.im=this.Qk,this.Qk=0);this.Lq&&(0!==this.Kk&&(b=a-this.Kk,0===b?(this.Zv++,10<=this.Bx&&(this.Lq=q),this.Jf=1/60):(this.Jf=b/1E3,0.5<this.Jf?this.Jf=0:0.1<this.Jf&&(this.Jf=0.1))),this.Kk=a);this.fa=this.Jf*this.fg;this.Nf.add(this.fa);a=document.mozFullScreen||document.webkitIsFullScreen||document.fullScreen||this.Ak;2<=this.Mf||a&&0<this.Bm?(this.Yl=this.width/this.height>this.Uc/this.Tc?this.height/
this.Tc:this.width/this.Uc,this.bb&&(this.bb.hr(this.bb.scrollX),this.bb.ir(this.bb.scrollY))):this.Yl=1;this.ld();this.Od++;this.Xg.wv();this.Od--;this.ld();this.Od++;a=0;for(b=this.da.length;a<b;a++)if(g=this.da[a],g.Sb.length){c=0;for(d=g.l.length;c<d;c++){var i=g.l[c];e=0;for(f=i.Rb.length;e<f;e++)i.Rb[e].Gc()}}c=this.En.hg();a=0;for(b=c.length;a<b;a++)c[a].Gc();this.Od--;for(a=0;this.Hf&&10>a++;){this.bb.Iv();c=0;for(d=this.da.length;c<d;c++)g=this.da[c],g.vo&&-1===this.Hf.bj.indexOf(g)&&g.vo();
this.Hf.ko();a=0;for(b=this.da.length;a<b;a++)if(g=this.da[a],g.global||g.Mb.io){c=0;for(d=g.l.length;c<d;c++)i=g.l[c],i.dv&&i.dv()}this.uq=this.Pa=m;this.ld()}a=0;for(b=this.ug.length;a<b;a++)this.ug[a].Km=q;this.bb.jk&&this.bb.jk.Fb();this.il.length=0;this.uq=q;this.Od++;a=0;for(b=this.da.length;a<b;a++)if(g=this.da[a],g.Sb.length){c=0;for(d=g.l.length;c<d;c++){i=g.l[c];e=0;for(f=i.Rb.length;e<f;e++)h=i.Rb[e],h.Fj&&h.Fj()}}c=this.Sq.hg();a=0;for(b=c.length;a<b;a++)c[a].Fj();this.Od--};F.sl=function(a){this.En.add(a)};
F.qk=function(a){return!a||-1===a.$k?this.fa:this.Jf*a.$k};F.Kd=function(){this.bb.Kd(this.La);this.te&&this.La.present()};F.Yc=function(){this.bb.Yc(this.P)};F.Yo=function(a){a&&this.ik.push(a)};F.uv=function(a){qa(this.ik,a)};F.eh=function(a){var b,c;if(!this.Xe.contains(a)){this.Xe.add(a);if(a.ue){b=0;for(c=a.siblings.length;b<c;b++)this.eh(a.siblings[b])}this.Nm&&this.Xe.ji.push(a);this.Od++;this.trigger(Object.getPrototypeOf(a.type.Mb).C.Zr,a);this.Od--}};
F.ld=function(){var a,b,c,d,e,f,g,h,i,j;this.Nm=m;d=0;for(f=this.Ue.length;d<f;d++){a=this.Ue[d];b=a.type;b.l.push(a);b.Wg=m;e=0;for(g=b.Kb.length;e<g;e++)b.Kb[e].l.push(a),b.Kb[e].Wg=m}this.Ue.length=0;f=this.Xe.hg();for(d=0;d<f.length;d++){a=f[d];b=a.type;c=b.l;e=0;for(g=this.ik.length;e<g;e++)this.ik[e](a);qa(c,a);a.F&&(oa(a.F.l,a.$e()),a.F.ig=m);e=0;for(g=b.Kb.length;e<g;e++)qa(b.Kb[e].l,a),b.Kb[e].Wg=m;if(a.Rb){e=0;for(g=a.Rb.length;e<g;e++)c=a.Rb[e],c.Rg&&c.Rg(),c.O.Th.remove(a)}this.En.remove(a);
this.Sq.remove(a);e=0;for(g=this.Xg.xf.length;e<g;e++)if(i=this.Xg.xf[e],i.ai.hasOwnProperty(b.index)&&qa(i.ai[b.index],a),!b.Sa){c=0;for(h=b.Kb.length;c<h;c++)j=b.Kb[c],i.ai.hasOwnProperty(j.index)&&qa(i.ai[j.index],a)}a.Rg&&a.Rg();this.bl--;32>b.hk.length&&b.hk.push(a);b.Wg=m}this.Xe.Bk()||(this.Pa=m);this.Xe.clear();this.Nm=q};F.sp=function(a,b,c,d){if(a.Sa){var e=la(Math.random()*a.Zk.length);return this.sp(a.Zk[e],b,c,d)}return!a.le?p:this.nh(a.le,b,q,c,d)};var Mb=[];F=tb.prototype;
F.nh=function(a,b,c,d,e,f){var g,h,i,j;if(!a)return p;var k=this.da[a[1]],n=k.Mb.Gk;if(this.wh&&n&&!k.Om||n&&!this.P&&11===a[0][11])return p;n||(b=p);var r,s=q;k.hk.length?(r=k.hk.pop(),s=m,k.Mb.la.call(r,k)):r=new k.Mb.la(k);r.uid=this.al;this.al++;r.aj=0;r.uk=Jb;k.Wg=m;i=a[2];if(s){g=0;for(h=i.length;g<h;g++)r.Nd[g]=i[g];Fa(r.Ma)}else r.Nd=i.slice(0),r.Ma={};if(n){var t=a[0];r.x=ea(d)?t[0]:d;r.y=ea(e)?t[1]:e;r.o=t[2];r.width=t[3];r.height=t[4];r.depth=t[5];r.v=t[6];r.opacity=t[7];r.qe=t[8];r.re=
t[9];r.je=t[10];g=t[11];!this.P&&k.Ea.length&&(r.je=g);r.ck=Ia(r.je);this.U&&Ja(r,r.je,this.U);if(s){g=0;for(h=t[12].length;g<h;g++){i=0;for(j=t[12][g].length;i<j;i++)r.oc[g][i]=t[12][g][i]}r.ea.set(0,0,0,0);r.Ka.bo(r.ea);r.Vj.length=0}else{r.oc=t[12].slice(0);g=0;for(h=r.oc.length;g<h;g++)r.oc[g]=t[12][g].slice(0);r.za=[];r.jh=[];r.jh.length=k.Ea.length;r.ea=new bb(0,0,0,0);r.Ka=new cb;r.Vj=[];r.ha=Nb;r.Tw=Ob;r.pd=Pb;r.gb=Qb;r.$e=Rb}g=0;for(h=k.Ea.length;g<h;g++)r.jh[g]=m;r.hi=Sb;r.hi();r.Hr=!!r.za.length;
r.Zl=m;r.visible=m;r.$k=-1;r.F=b;r.Co=b.l.length;"undefined"===typeof r.Da&&(r.Da=p);this.Pa=r.Pi=m}r.toString=Kb;var u;g=Mb.length=0;for(h=k.Kb.length;g<h;g++)Mb.push.apply(Mb,k.Kb[g].Sb);Mb.push.apply(Mb,k.Sb);if(s){g=0;for(h=Mb.length;g<h;g++){var w=Mb[g];u=r.Rb[g];w.O.la.call(u,w,r);t=a[3][g];i=0;for(j=t.length;i<j;i++)u.G[i]=t[i];u.X();w.O.Th.add(r)}}else{r.Rb=[];g=0;for(h=Mb.length;g<h;g++)w=Mb[g],u=new w.O.la(w,r),u.G=a[3][g].slice(0),u.X(),r.Rb.push(u),w.O.Th.add(r)}t=a[4];if(s){g=0;for(h=
t.length;g<h;g++)r.G[g]=t[g]}else r.G=t.slice(0);this.Ue.push(r);b&&b.l.push(r);this.bl++;if(k.ue){if(r.ue=m,r.siblings=[],!c&&!f){g=0;for(h=k.Xc.length;g<h;g++)if(k.Xc[g]!==k){if(!k.Xc[g].le)return p;r.siblings.push(this.nh(k.Xc[g].le,b,q,n?r.x:d,n?r.y:e,m))}g=0;for(h=r.siblings.length;g<h;g++){r.siblings[g].siblings.push(r);for(i=0;i<h;i++)g!==i&&r.siblings[g].siblings.push(r.siblings[i])}}}else r.ue=q,r.siblings=p;r.X();g=0;for(h=r.Rb.length;g<h;g++)r.Rb[g].$q&&r.Rb[g].$q();return r};
F.Em=function(a){var b,c;b=0;for(c=this.bb.Ta.length;b<c;b++){var d=this.bb.Ta[b];if(d.name.toLowerCase()===a.toLowerCase())return d}return p};F.Zi=function(a){a=la(a);0>a&&(a=0);a>=this.bb.Ta.length&&(a=this.bb.Ta.length-1);return this.bb.Ta[a]};F.dm=function(a){var b,c;b=0;for(c=a.length;b<c;b++)a[b].Na().fb=m};F.wj=function(a){var b,c;b=0;for(c=a.length;b<c;b++)a[b].wj()};F.xj=function(a){var b,c;b=0;for(c=a.length;b<c;b++)a[b].xj()};F.Yf=function(a){var b,c;b=0;for(c=a.length;b<c;b++)a[b].Yf()};
F.Lv=function(a,b,c){var d=a.Na(),e,f,g,h,i,j;if(d.fb){d.fb=q;e=d.l.length=0;for(h=a.l.length;e<h;e++)g=a.l[e],g.gb(),i=g.F.Pc(b,c,m),j=g.F.Pc(b,c,q),g.pd(i,j)&&d.l.push(g)}else{e=f=0;for(h=d.l.length;e<h;e++)g=d.l[e],g.gb(),i=g.F.Pc(b,c,m),j=g.F.Pc(b,c,q),g.pd(i,j)&&(d.l[f]=d.l[e],f++);d.l.length=f}a.Gi();return d.Jm()};
F.no=function(a,b){if(!a||!b||a===b||!a.Pi||!b.Pi)return q;a.gb();b.gb();var c=a.F,d=b.F,e,f,g,h,i,j;if(c!==d&&(c.Wf!==d.Wf||d.Xf!==d.Xf||c.scale!==d.scale||c.v!==d.v||c.zf!==d.zf)){i=a.Da&&!a.Da.uh();e=b.Da&&!b.Da.uh();i?(a.Da.mh(a.width,a.height,a.v),this.Yg.kr(a.Da)):this.Yg.ol(a.Ka,a.x,a.y,a.width,a.height);i=this.Yg;e?(b.Da.mh(b.width,b.height,b.v),this.mo.kr(b.Da)):this.mo.ol(b.Ka,b.x,b.y,b.width,b.height);j=this.mo;e=0;for(f=i.Fe;e<f;e++)g=i.ic[2*e],h=i.ic[2*e+1],i.ic[2*e]=c.Ja(g+a.x,h+a.y,
m),i.ic[2*e+1]=c.Ja(g+a.x,h+a.y,q);e=0;for(f=j.Fe;e<f;e++)g=j.ic[2*e],h=j.ic[2*e+1],j.ic[2*e]=d.Ja(g+b.x,h+b.y,m),j.ic[2*e+1]=d.Ja(g+b.x,h+b.y,q);return i.Wp(j,0,0)}if(!a.ea.pu(b.ea)||!a.Ka.ou(b.Ka))return q;i=a.Da&&!a.Da.uh();e=b.Da&&!b.Da.uh();if(!i&&!e)return m;i?(a.Da.mh(a.width,a.height,a.v),i=a.Da):(this.Yg.ol(a.Ka,a.x,a.y,a.width,a.height),i=this.Yg);e?(b.Da.mh(b.width,b.height,b.v),j=b.Da):(this.Yg.ol(b.Ka,b.x,b.y,b.width,b.height),j=this.Yg);return i.Wp(j,b.x-a.x,b.y-a.y)};
F.Dj=function(a){var b=p,c,d;if(!ab.Fv)return p;c=0;for(d=this.Sb.length;c<d;c++)if(this.Sb[c]instanceof ab.Fv){b=this.Sb[c];break}if(!b)return p;var e=b.Th.hg();c=0;for(d=e.length;c<d;++c)if(b=e[c],b.Ma.tx&&this.no(a,b))return b;return p};
F.rv=function(a){for(var b=ea(l)?100:l,c=0,d=a.x,e=a.y,f=0,g=0,h=0,i=p;c<=b;){switch(f){case 0:g=0;h=-1;c++;break;case 1:g=1;h=-1;break;case 2:g=1;h=0;break;case 3:h=g=1;break;case 4:g=0;h=1;break;case 5:g=-1;h=1;break;case 6:g=-1;h=0;break;case 7:h=g=-1}f=(f+1)%8;a.x=la(d+g*c);a.y=la(e+h*c);a.ha();if(!this.no(a,i)&&(i=this.Dj(a),!i))return m}a.x=d;a.y=e;a.ha();return q};F.yj=function(a,b){a.Pi&&b.Pi&&this.il.push([a,b])};
F.Ns=function(a,b){var c,d,e;c=0;for(d=this.il.length;c<d;c++)if(e=this.il[c],e[0]==a&&e[1]==b||e[0]==b&&e[1]==a)return m;return q};var Tb=[],Ub=-1;F=tb.prototype;F.trigger=function(a,b,c){if(!this.bb)return q;var d=this.bb.jk;if(!d)return q;Ub++;Ub===Tb.length?Tb.push(new db):Tb[Ub].clear();a=this.zr(a,b,d,c);Ub--;return a};
F.zr=function(a,b,c,d){var e=Tb[Ub];if(e.contains(c))return q;e.add(c);var e=c.Sp.hg(),f=q,g,h,i;g=0;for(h=e.length;g<h;g++)i=this.zr(a,b,e[g],d),f=f||i;if(b){i=this.to(a,b,b.type.name,c,d);f=f||i;g=0;for(h=b.type.Kb.length;g<h;g++)i=this.to(a,b,b.type.Kb[g].name,c,d),f=f||i}else i=this.to(a,b,"system",c,d),f=f||i;return f};
F.to=function(a,b,c,d,e){var f,g=q,h=q,h="undefined"!==typeof e,i=(h?d.Ap:d.Ar)[c];if(!i)return g;var j=p,d=0;for(f=i.length;d<f;d++)if(i[d].method==a){j=i[d].lk;break}if(!j)return g;a=h?j[e]:j;if(!a)return p;d=0;for(f=a.length;d<f;d++)e=a[d][0],h=a[d][1],h=this.Ht(b,c,e,h),g=g||h;return g};
F.Ht=function(a,b,c,d){var e,f,g=q;this.uo++;var h=this.zc().yc;h&&this.wj(h.bg);var i=1<this.uo;this.wj(c.bg);i&&this.pv();var j=this.gl(c);j.yc=c;a&&(e=this.types[b].Na(),e.fb=q,e.l.length=1,e.l[0]=a,this.types[b].Gi());a=m;if(c.parent){b=j.ur;for(e=c.parent;e;)b.push(e),e=e.parent;b.reverse();e=0;for(f=b.length;e<f;e++)if(!b[e].yv()){a=q;break}}a&&(this.vm++,c.Yd?c.xv(d):c.Fb(),g=g||j.Ah);this.el();i&&this.kv();this.Yf(c.bg);h&&this.Yf(h.bg);0===this.Od&&(0===Ub&&!this.Qm&&(!this.Xe.Bk()||this.Ue.length))&&
this.ld();this.uo--;return g};F.Hp=function(){var a=this.zc();return a.yc.cb[a.zb]};F.pv=function(){this.Pk++;this.Pk>=this.en.length&&this.en.push([])};F.kv=function(){this.Pk--};F.Ip=function(){return this.en[this.Pk]};F.gl=function(a){this.kk++;this.kk>=this.tm.length&&this.tm.push(new Oa);var b=this.zc();b.reset(a);return b};F.el=function(){this.kk--};F.zc=function(){return this.tm[this.kk]};
F.qv=function(a){this.Rk++;this.Rk>=this.gn.length&&this.gn.push(ca({name:a,index:0,Fc:q}));var b=this.Nt();b.name=a;b.index=0;b.Fc=q;return b};F.lv=function(){this.Rk--};F.Nt=function(){return this.gn[this.Rk]};F.Kp=function(a,b){for(var c,d,e,f,g,h;b;){c=0;for(d=b.Dd.length;c<d;c++)if(h=b.Dd[c],h instanceof Pa&&a.toLowerCase()===h.name.toLowerCase())return h;b=b.parent}c=0;for(d=this.ug.length;c<d;c++){g=this.ug[c];e=0;for(f=g.Lf.length;e<f;e++)if(h=g.Lf[e],h instanceof Pa&&a.toLowerCase()===h.name.toLowerCase())return h}return p};
window.cr_createRuntime=function(a){return new tb(document.getElementById(a))};window.cr_createDCRuntime=function(a,b){return new tb({dc:m,width:a,height:b})};window.createCocoonJSRuntime=function(){window.c2cocoonjs=m;var a=document.createElement("canvas");document.body.appendChild(a);a.width=window.innerWidth;a.height=window.innerHeight;a=new tb(a);window.c2runtime=a;window.addEventListener("orientationchange",function(){window.c2runtime.setSize(window.innerWidth,window.innerHeight)});return a};
window.cr_getC2Runtime=function(){var a=document.getElementById("c2canvas");if(a)return a.c2runtime;if(window.c2runtime)return window.c2runtime};window.cr_sizeCanvas=function(a,b){if(!(0===a||0===b)){var c=window.cr_getC2Runtime();c&&c.setSize(a,b)}};window.cr_setSuspended=function(a){var b=window.cr_getC2Runtime();b&&b.setSuspended(a)};
function Vb(a,b){this.a=a;this.jk=p;this.scrollX=this.a.Uc/2;this.scrollY=this.a.Tc/2;this.scale=1;this.v=0;this.name=b[0];this.width=b[1];this.height=b[2];this.Br=b[3];this.nr=b[4];var c=b[5],d,e;this.Ta=[];this.bj=[];d=0;for(e=c.length;d<e;d++){var f=new Qa(this,c[d]);f.Rq=d;this.Ta.push(f)}c=b[6];this.Ag=[];d=0;for(e=c.length;d<e;d++){var f=c[d],g=this.a.da[f[1]];g.le||(g.le=f);this.Ag.push(f);-1===this.bj.indexOf(g)&&this.bj.push(g)}this.Ea=[];this.za=[];this.oc=[];d=0;for(e=b[7].length;d<e;d++)this.Ea.push({id:b[7][d][0],
name:b[7][d][1],jc:-1,ie:m,index:d}),this.oc.push(b[7][d][2].slice(0));this.hi();this.Ug=new bb(0,0,1,1);this.Rn=new bb(0,0,1,1)}
function Wb(a,b){this.Ga=a;this.a=a.a;this.l=[];this.scale=1;this.v=0;this.tg=q;this.vf=new bb(0,0,0,0);this.wr=new cb;this.jd=this.Fd=this.kd=this.Ed=0;this.ig=q;this.name=b[0];this.index=b[1];this.visible=b[2];this.kh=b[3];this.Gj=b[4];this.Wf=b[5];this.Xf=b[6];this.opacity=b[7];this.ym=b[8];this.zf=b[9];this.je=b[10];this.ht=b[11];this.ck="source-over";this.nc=this.tc=0;this.$f=q;var c=b[12],d,e;this.sh=[];d=0;for(e=c.length;d<e;d++){var f=c[d],g=this.a.da[f[1]];g.le||(g.le=f);this.sh.push(f);
-1===this.Ga.bj.indexOf(g)&&this.Ga.bj.push(g)}this.Ea=[];this.za=[];this.oc=[];d=0;for(e=b[13].length;d<e;d++)this.Ea.push({id:b[13][d][0],name:b[13][d][1],jc:-1,ie:m,index:d}),this.oc.push(b[13][d][2].slice(0));this.hi();this.Ug=new bb(0,0,1,1);this.Rn=new bb(0,0,1,1)}F=Vb.prototype;F.Pp=function(){var a=this.Ta[0];return!a.Gj&&1===a.opacity&&!a.ym&&a.visible};F.hi=function(){this.za.length=0;var a,b,c;a=0;for(b=this.Ea.length;a<b;a++)c=this.Ea[a],c.ie&&this.za.push(c)};
F.ko=function(){this.nr&&(this.jk=this.a.um[this.nr]);this.a.bb=this;this.scrollX=this.a.Uc/2;this.scrollY=this.a.Tc/2;var a,b,c,d,e,f;a=0;for(c=this.a.da.length;a<c;a++)if(b=this.a.da[a],!b.Sa){e=b.l;b=0;for(d=e.length;b<d;b++)if(f=e[b],f.F){var g=f.F.Rq;g>=this.Ta.length&&(g=this.Ta.length-1);f.F=this.Ta[g];f.F.l.push(f);f.F.ig=m}}a=0;for(c=this.Ta.length;a<c;a++)b=this.Ta[a],b.Qs(),b.tg=m,d=b.Pc(0,0,m),e=b.Pc(0,0,q),b.tg=q,this.a.Ee&&(d=d+0.5|0,e=e+0.5|0),b.Wn(d,e,p);a=0;for(c=this.Ag.length;a<
c;a++)this.a.nh(this.Ag[a],p,m);this.a.Hf=p;this.a.ld();this.a.trigger(L.prototype.C.No,p)};F.Ps=function(){var a,b,c,d,e;b=a=0;for(c=this.Ag.length;a<c;a++)d=this.Ag[a],e=this.a.da[d[1]],e.global?this.a.nh(d,p,m):(this.Ag[b]=d,b++);this.Ag.length=b};
F.Iv=function(){this.a.trigger(L.prototype.C.fs,p);this.a.Xg.xf.length=0;var a,b,c,d,e,f;a=0;for(b=this.Ta.length;a<b;a++){e=this.Ta[a].l;c=0;for(d=e.length;c<d;c++)f=e[c],f.type.global||this.a.eh(f);this.a.ld();e.length=0;this.Ta[a].ig=m}a=0;for(b=this.a.da.length;a<b;a++)if(e=this.a.da[a],!e.global&&!e.Mb.Gk&&!e.Mb.io){c=0;for(d=e.l.length;c<d;c++)this.a.eh(e.l[c]);this.a.ld()}};
F.Kd=function(a){a.globalAlpha=1;a.globalCompositeOperation="source-over";this.a.kp&&!this.Pp()&&a.clearRect(0,0,this.a.width,this.a.height);var b,c,d;b=0;for(c=this.Ta.length;b<c;b++)d=this.Ta[b],d.visible&&(0<d.opacity&&11!==d.je)&&d.Kd(a)};
F.Yc=function(a){var b=0<this.za.length||this.a.ii;if(b){this.a.Pd||(this.a.Pd=a.Te(this.a.width,this.a.height,this.a.ib));if(this.a.Pd.Li!==this.a.width||this.a.Pd.Ji!==this.a.height)a.deleteTexture(this.a.Pd),this.a.Pd=a.Te(this.a.width,this.a.height,this.a.ib);a.uf(this.a.Pd)}this.a.kp&&!this.Pp()&&a.clear(0,0,0,0);var c,d;c=0;for(d=this.Ta.length;c<d;c++)this.Ta[c].visible&&0<this.Ta[c].opacity&&this.Ta[c].Yc(a);b&&(1>=this.za.length?(1===this.za.length?(b=this.za[0].index,a.Je(this.za[0].jc),
a.$h(p,1/this.a.width,1/this.a.height,0,0,1,1,this.scale,this.oc[b]),a.fl(this.za[0].jc)&&(this.a.Pa=m)):a.Je(0),a.uf(p),a.Vg(1),a.gd(this.a.Pd),a.jr(),a.Ie(),a.Le(),b=this.a.width/2,c=this.a.height/2,a.hl(-b,c,b,c,b,-c,-b,-c),a.gd(p)):this.Sn(a,p,p,p));a.mv()};F.$i=function(){return 0<this.za.length||this.a.ii?this.a.Pd:p};F.Lp=function(){var a=this.Ta[0].Jc(),b,c,d;b=1;for(c=this.Ta.length;b<c;b++)d=this.Ta[b],0===d.Wf&&0===d.Xf||d.Jc()<a&&(a=d.Jc());return a};
F.hr=function(a){if(!this.Br){var b=this.a.width*(1/this.Lp())/2;a>this.width-b&&(a=this.width-b);a<b&&(a=b)}this.scrollX!==a&&(this.scrollX=a,this.a.Pa=m)};F.ir=function(a){if(!this.Br){var b=this.a.height*(1/this.Lp())/2;a>this.height-b&&(a=this.height-b);a<b&&(a=b)}this.scrollY!==a&&(this.scrollY=a,this.a.Pa=m)};
F.Sn=function(a,b,c,d){var e=c?c.za:b?b.za:this.za,f=c?c.F.Jc():b?b.Jc():1,g=this.a.Cm,h,i,j,k,n=0,r=1,s,t=this.a.width,u=this.a.height,w=t/2,x=u/2,C=b?b.Ug:this.Ug,B=b?b.Rn:this.Rn,z=0,E=0,A=0,I=0,J=t,aa=t,G=u,xa=u,ya=j=0,Za=c?c.F.Ze():0;if(c){h=0;for(i=e.length;h<i;h++)j+=a.Rt(e[h].jc),ya+=a.St(e[h].jc);k=c.ea;z=b.Ja(k.left,k.top,m);A=b.Ja(k.left,k.top,q);J=b.Ja(k.right,k.bottom,m);G=b.Ja(k.right,k.bottom,q);0!==Za&&(h=b.Ja(k.right,k.top,m),i=b.Ja(k.right,k.top,q),E=b.Ja(k.left,k.bottom,m),I=b.Ja(k.left,
k.bottom,q),k=Math.min(z,J,h,E),J=Math.max(z,J,h,E),z=k,k=Math.min(A,G,i,I),G=Math.max(A,G,i,I),A=k);z-=j;A-=ya;J+=j;G+=ya;B.left=z/t;B.top=1-A/u;B.right=J/t;B.bottom=1-G/u;E=z=Math.floor(z);I=A=Math.floor(A);aa=J=Math.ceil(J);xa=G=Math.ceil(G);E-=j;I-=ya;aa+=j;xa+=ya;0>z&&(z=0);0>A&&(A=0);J>t&&(J=t);G>u&&(G=u);0>E&&(E=0);0>I&&(I=0);aa>t&&(aa=t);xa>u&&(xa=u);C.left=z/t;C.top=1-A/u;C.right=J/t;C.bottom=1-G/u}else C.left=B.left=0,C.top=B.top=0,C.right=B.right=1,C.bottom=B.bottom=1;ya=c&&((c.v||Za)&&
a.vj(e[0].jc)||0!==j||0!==ya||1!==c.opacity||c.type.Mb.Nq)||b&&!c&&1!==b.opacity;a.jr();if(ya){g[n]||(g[n]=a.Te(t,u,this.a.ib));if(g[n].Li!==t||g[n].Ji!==u)a.deleteTexture(g[n]),g[n]=a.Te(t,u,this.a.ib);a.Je(0);a.uf(g[n]);s=xa-I;a.clearRect(E,u-I-s,aa-E,s);c?c.Yc(a):(a.gd(this.a.Zc),a.Vg(b.opacity),a.Ie(),a.translate(-w,-x),a.Le(),a.Ge(z,G,J,G,J,A,z,A,C));B.left=B.top=0;B.right=B.bottom=1;c&&(k=C.top,C.top=C.bottom,C.bottom=k);n=1;r=0}a.Vg(1);j=e.length-1;var Za=a.Nn(e[j].jc),$a=0;h=0;for(i=e.length;h<
i;h++){g[n]||(g[n]=a.Te(t,u,this.a.ib));if(g[n].Li!==t||g[n].Ji!==u)a.deleteTexture(g[n]),g[n]=a.Te(t,u,this.a.ib);a.Je(e[h].jc);$a=e[h].index;a.fl(e[h].jc)&&(this.a.Pa=m);0==h&&!ya?(a.uf(g[n]),s=xa-I,k=u-I-s,a.clearRect(E,k,aa-E,s),c?(a.$h(d,1/c.width,1/c.height,B.left,B.top,B.right,B.bottom,f,c.oc[$a]),c.Yc(a)):(a.$h(d,1/t,1/u,0,0,1,1,f,b?b.oc[$a]:this.oc[$a]),a.gd(b?this.a.Zc:this.a.Pd),a.Ie(),a.translate(-w,-x),a.Le(),a.Ge(z,G,J,G,J,A,z,A,C)),B.left=B.top=0,B.right=B.bottom=1,c&&!Za&&(k=G,G=A,
A=k)):(a.$h(d,1/t,1/u,B.left,B.top,B.right,B.bottom,f,c?c.oc[$a]:b?b.oc[$a]:this.oc[$a]),h===j&&!Za?(c?a.ag(c.tc,c.nc):b&&a.ag(b.tc,b.nc),a.uf(d)):(a.uf(g[n]),s=xa-I,k=u-I-s,a.clearRect(E,k,aa-E,s)),a.gd(g[r]),a.Ie(),a.translate(-w,-x),a.Le(),a.Ge(z,G,J,G,J,A,z,A,C),h===j&&!Za&&a.gd(p));n=0===n?1:0;r=0===n?1:0}Za&&(a.Je(0),c?a.ag(c.tc,c.nc):b&&a.ag(b.tc,b.nc),a.uf(d),a.gd(g[r]),a.Ie(),a.translate(-w,-x),a.Le(),c&&1===e.length&&!ya?a.Ge(z,A,J,A,J,G,z,G,C):a.Ge(z,G,J,G,J,A,z,A,C),a.gd(p))};Ma=Vb;
Wb.prototype.hi=function(){this.za.length=0;var a,b,c;a=0;for(b=this.Ea.length;a<b;a++)c=this.Ea[a],c.ie&&this.za.push(c)};var Xb=[];F=Wb.prototype;
F.Qs=function(){Xb.length=0;var a,b,c,d,e,f,g;b=a=0;for(c=this.sh.length;a<c;a++)d=this.a.nh(this.sh[a],this,m),Xb.push(d),d&&!d.type.global&&(this.sh[b]=this.sh[a],b++);this.sh.length=b;this.a.ld();for(a=0;a<Xb.length;a++)if(d=Xb[a],d.type.ue){f=d.uk();b=0;for(c=d.type.Xc.length;b<c;b++)e=d.type.Xc[b],d.type!==e&&(e.l.length>f?d.siblings.push(e.l[f]):e.le&&(g=this.a.nh(e.le,this,m,d.x,d.y,m),this.a.ld(),e.yl(),d.siblings.push(g),Xb.push(g)))}!this.a.P&&this.Ea.length&&(this.je=this.ht);this.ck=Ia(this.je);
this.a.U&&Ja(this,this.je,this.a.U)};F.Ov=function(){if(this.ig){var a,b;a=0;for(b=this.l.length;a<b;a++)this.l[a].Co=a;this.ig=q}};F.Jc=function(){return this.Pt()*this.a.Yl};F.Pt=function(){return(this.scale*this.Ga.scale-1)*this.zf+1};F.Ze=function(){return this.tg?0:ua(this.Ga.v+this.v)};
F.Kd=function(a){this.$f=this.ym||1!==this.opacity||0!==this.je;var b=this.a.canvas,c=a;a.globalAlpha=1;a.globalCompositeOperation="source-over";this.$f&&(this.a.Lk||(this.a.Lk=document.createElement("canvas"),b=this.a.Lk,b.width=this.a.width,b.height=this.a.height,this.a.tq=b.getContext("2d")),b=this.a.Lk,c=this.a.tq,b.width!==this.a.width&&(b.width=this.a.width),b.height!==this.a.height&&(b.height=this.a.height),this.Gj&&c.clearRect(0,0,this.a.width,this.a.height));this.Gj||(c.fillStyle="rgb("+
this.kh[0]+","+this.kh[1]+","+this.kh[2]+")",c.fillRect(0,0,this.a.width,this.a.height));c.save();this.tg=m;var d=this.Pc(0,0,m),e=this.Pc(0,0,q);this.tg=q;this.a.Ee&&(d=d+0.5|0,e=e+0.5|0);this.Wn(d,e,c);var f=this.Jc();c.scale(f,f);c.translate(-d,-e);for(var g,d=0,e=this.l.length;d<e;d++)if(f=this.l[d],f.visible&&!(0===f.width||0===f.height))f.gb(),g=f.ea,g.right<this.Ed||(g.bottom<this.Fd||g.left>this.kd||g.top>this.jd)||(c.globalCompositeOperation=f.ck,f.Kd(c));c.restore();this.$f&&(a.globalCompositeOperation=
this.ck,a.globalAlpha=this.opacity,a.drawImage(b,0,0))};
F.Wn=function(a,b,c){var d=this.Jc();this.Ed=a;this.Fd=b;this.kd=a+this.a.width*(1/d);this.jd=b+this.a.height*(1/d);a=this.Ze();0!==a&&(c&&(c.translate(this.a.width/2,this.a.height/2),c.rotate(-a),c.translate(this.a.width/-2,this.a.height/-2)),this.vf.set(this.Ed,this.Fd,this.kd,this.jd),this.vf.offset((this.Ed+this.kd)/-2,(this.Fd+this.jd)/-2),this.wr.lr(this.vf,a),this.wr.hp(this.vf),this.vf.offset((this.Ed+this.kd)/2,(this.Fd+this.jd)/2),this.Ed=this.vf.left,this.Fd=this.vf.top,this.kd=this.vf.right,
this.jd=this.vf.bottom)};
F.Yc=function(a){var b=this.a.width,c=this.a.height,d=0,e=0;if(this.$f=this.ym||1!==this.opacity||0<this.za.length||0!==this.je){this.a.Zc||(this.a.Zc=a.Te(this.a.width,this.a.height,this.a.ib));if(this.a.Zc.Li!==this.a.width||this.a.Zc.Ji!==this.a.height)a.deleteTexture(this.a.Zc),this.a.Zc=a.Te(this.a.width,this.a.height,this.a.ib);a.uf(this.a.Zc);this.Gj&&a.clear(0,0,0,0)}this.Gj||a.clear(this.kh[0]/255,this.kh[1]/255,this.kh[2]/255,1);this.tg=m;var e=this.Pc(0,0,m),f=this.Pc(0,0,q);this.tg=q;
this.a.Ee&&(e=e+0.5|0,f=f+0.5|0);this.Wn(e,f,p);f=this.Jc();a.Ie();a.scale(f,f);a.Xn(-this.Ze());a.translate((this.Ed+this.kd)/-2,(this.Fd+this.jd)/-2);a.Le();var g,h,i;g=0;for(h=this.l.length;g<h;g++)if(i=this.l[g],i.visible&&!(0===i.width||0===i.height))if(i.gb(),d=i.ea,!(d.right<this.Ed||d.bottom<this.Fd||d.left>this.kd||d.top>this.jd))if(i.Hr)if(d=i.za[0].jc,e=i.za[0].index,1===i.za.length&&!a.Nn(d)&&!a.ov(d)&&(!i.v&&!i.F.Ze()||!a.vj(d))&&1===i.opacity&&!i.type.Mb.Nq){a.Je(d);a.ag(i.tc,i.nc);
a.fl(d)&&(this.a.Pa=m);var j=0,k=0,n=0,r=0;a.vj(d)&&(d=i.ea,j=this.Ja(d.left,d.top,m),k=this.Ja(d.left,d.top,q),n=this.Ja(d.right,d.bottom,m),d=this.Ja(d.right,d.bottom,q),j/=b,k=1-k/c,n/=b,r=1-d/c);a.$h(this.$f?this.a.Zc:this.Ga.$i(),1/i.width,1/i.height,j,k,n,r,this.Jc(),i.oc[e]);i.Yc(a)}else this.Ga.Sn(a,this,i,this.$f?this.a.Zc:this.Ga.$i()),a.Ie(),a.scale(f,f),a.Xn(-this.Ze()),a.translate((this.Ed+this.kd)/-2,(this.Fd+this.jd)/-2),a.Le();else a.Je(0),a.ag(i.tc,i.nc),i.Yc(a);this.$f&&(d=this.za.length?
this.za[0].jc:0,e=this.za.length?this.za[0].index:0,0===this.za.length||1===this.za.length&&!a.Nn(d)&&1===this.opacity?(1===this.za.length?(a.Je(d),a.$h(this.Ga.$i(),1/this.a.width,1/this.a.height,0,0,1,1,this.Jc(),this.oc[e]),a.fl(d)&&(this.a.Pa=m)):a.Je(0),a.uf(this.Ga.$i()),a.Vg(this.opacity),a.gd(this.a.Zc),a.ag(this.tc,this.nc),a.Ie(),a.Le(),b=this.a.width/2,c=this.a.height/2,a.hl(-b,c,b,c,b,-c,-b,-c),a.gd(p)):this.Ga.Sn(a,this,p,this.Ga.$i()))};
F.Pc=function(a,b,c){var d=this.a.devicePixelRatio;!this.a.pc&&(this.a.Al&&this.a.cf)&&0<this.a.Mf&&(a*=d,b*=d);var d=this.a.Uc/2,e=this.a.Tc/2,d=(this.Ga.scrollX-d)*this.Wf+d,e=(this.Ga.scrollY-e)*this.Xf+e,f=1/this.Jc(),d=d-this.a.width*f/2,e=e-this.a.height*f/2,d=d+a*f,e=e+b*f,b=this.Ze();0!==b&&(d-=this.Ga.scrollX,e-=this.Ga.scrollY,a=Math.cos(b),b=Math.sin(b),f=d*a-e*b,e=e*a+d*b,d=f+this.Ga.scrollX,e+=this.Ga.scrollY);return c?d:e};
F.Ja=function(a,b,c){var d=this.Ze();if(0!==d)var a=a-this.Ga.scrollX,b=b-this.Ga.scrollY,e=Math.cos(-d),d=Math.sin(-d),f=a*e-b*d,b=b*e+a*d,a=f+this.Ga.scrollX,b=b+this.Ga.scrollY;e=this.a.Uc/2;d=this.a.Tc/2;e=(this.Ga.scrollX-e)*this.Wf+e;d=(this.Ga.scrollY-d)*this.Xf+d;f=1/this.Jc();e-=this.a.width*f/2;d-=this.a.height*f/2;e=(a-e)/f;d=(b-d)/f;a=this.a.devicePixelRatio;!this.a.pc&&(this.a.Al&&this.a.cf)&&0<this.a.Mf&&(e/=a,d/=a);return c?e:d};Qa=Wb;
function Yb(a,b){var c,d=a.length;switch(d){case 0:return m;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 q;return m}}function Zb(a,b){return a.index-b.index}function $b(a){var b,c,d,e;2===a.length?a[0].index>a[1].index&&(b=a[0],a[0]=a[1],a[1]=b):2<a.length&&a.sort(Zb);a.length>=ac.length&&(ac.length=a.length+1);ac[a.length]||(ac[a.length]=[]);e=ac[a.length];b=0;for(c=e.length;b<c;b++)if(d=e[b],Yb(a,d))return d;e.push(a);return a}
function bc(a,b){this.a=a;this.Ar={};this.Ap={};this.Km=q;this.Sp=new db;this.name=b[0];var c=b[1];this.Lf=[];var d,e;d=0;for(e=c.length;d<e;d++)this.Up(c[d],p,this.Lf)}function cc(a){this.type=a;this.l=[];this.rb=[];this.fb=m}
function dc(a,b,c){this.sheet=a;this.parent=b;this.a=a.a;this.yb=[];this.bg=[];this.Qp=this.tl=this.xr=this.yk=this.group=this.jo=q;this.cb=[];this.mg=[];this.Dd=[];c[1]?(this.Gm=c[1][1].toLowerCase(),this.group=m,this.yk=!!c[1][0],this.a.Vl.push(this),this.a.Xo[this.Gm.toLowerCase()]=this.yk):(this.Gm="",this.yk=this.group=q);this.Yd=c[2];for(var d=c[3],a=0,b=d.length;a<b;a++){var e=new Ra(this,d[a]);this.cb.push(e);this.Zo(e.type)}d=c[4];a=0;for(b=d.length;a<b;a++)e=new Sa(this,d[a]),this.mg.push(e);
if(6===c.length){c=c[5];a=0;for(b=c.length;a<b;a++)this.sheet.Up(c[a],this,this.Dd)}this.Ck=q;this.cb.length&&(this.Ck=this.cb[0].type==p&&this.cb[0].Bb==L.prototype.C.Or)}function ec(a,b){var c,d,e;if(a&&(-1===b.indexOf(a)&&b.push(a),a.ue)){c=0;for(d=a.Xc.length;c<d;c++)e=a.Xc[c],a!==e&&-1===b.indexOf(e)&&b.push(e)}}
function fc(a,b){this.od=a;this.sheet=a.sheet;this.a=a.a;this.N=[];this.ga=[];this.Ma={};this.Bb=b[1];this.trigger=0<b[3];this.zp=2===b[3];this.hn=b[4];this.zk=b[5];this.wu=b[6];-1===b[0]?(this.type=p,this.Fb=this.Zn,this.Hi=p,this.$b=-1):(this.type=this.a.da[b[0]],this.Fb=this.wu?this.zv:this.Yn,b[2]?(this.Hi=this.type.pk(b[2]),this.$b=this.type.Dm(b[2])):(this.Hi=p,this.$b=-1),this.od.parent&&this.od.parent.nl());this.zp&&(this.Fb=this.Av);if(8===b.length){var c,d,e=b[7];c=0;for(d=e.length;c<d;c++){var f=
new Ta(this,e[c]);this.N.push(f)}this.ga.length=e.length}}function gc(a,b){this.od=a;this.sheet=a.sheet;this.a=a.a;this.N=[];this.ga=[];this.Ma={};this.Bb=b[1];-1===b[0]?(this.type=p,this.Fb=this.Zn,this.Hi=p,this.$b=-1):(this.type=this.a.da[b[0]],this.Fb=this.Yn,b[2]?(this.Hi=this.type.pk(b[2]),this.$b=this.type.Dm(b[2])):(this.Hi=p,this.$b=-1));if(4===b.length){var c,d,e=b[3];c=0;for(d=e.length;c<d;c++){var f=new Ta(this,e[c]);this.N.push(f)}this.ga.length=e.length}}
function hc(a,b){this.Y=a;this.od=a.od;this.sheet=a.sheet;this.a=a.a;this.type=b[0];this.me=p;this.mp=this.cg=0;this.Ga=p;this.key=0;this.object=p;this.index=0;this.Bl=this.ci=this.Bp=this.vg=this.Hj=p;var c,d,e;switch(b[0]){case 0:case 7:this.me=new Ua(this,b[1]);this.cg=0;this.get=this.Yt;break;case 1:this.me=new Ua(this,b[1]);this.cg=0;this.get=this.Zt;break;case 5:this.me=new Ua(this,b[1]);this.cg=0;this.get=this.cu;break;case 3:case 8:this.mp=b[1];this.get=this.Wt;break;case 6:this.Ga=this.a.Xm[b[1]];
this.get=this.du;break;case 9:this.key=b[1];this.get=this.bu;break;case 4:this.object=this.a.da[b[1]];this.get=this.eu;this.od.Zo(this.object);this.Y instanceof Sa?this.od.nl():this.od.parent&&this.od.parent.nl();break;case 10:this.index=b[1];this.get=a.type.Sa?this.$t:this.au;break;case 11:this.Hj=b[1];this.vg=p;this.get=this.Xt;break;case 2:case 12:this.Bp=b[1];this.get=this.Vt;break;case 13:this.get=this.fu;this.ci=[];this.Bl=[];c=1;for(d=b.length;c<d;c++)e=new Ta(this.Y,b[c]),this.ci.push(e),
this.Bl.push(0)}}function ic(a,b,c){this.sheet=a;this.parent=b;this.a=a.a;this.yb=[];this.name=c[1];this.zx=c[2];this.Mm=c[3];this.Ek=!!c[4];this.aq=!!c[5];this.data=this.Mm;this.parent?this.Fg=this.Ek||this.aq?-1:this.a.Gv++:(this.Fg=-1,this.a.As.push(this))}function jc(a,b,c){this.sheet=a;this.parent=b;this.a=a.a;this.yb=[];this.xk=p;this.lu=c[1]}function kc(){this.ur=[];this.reset(p)}var ac=[];F=bc.prototype;F.toString=y("name");
F.Up=function(a,b,c){switch(a[0]){case 0:a=new Va(this,b,a);if(a.Yd){c.push(a);c=0;for(b=a.cb.length;c<b;c++)a.cb[c].trigger&&this.Vp(a,c)}else a.bq()?this.Vp(a,0):c.push(a);break;case 1:a=new Pa(this,b,a);c.push(a);break;case 2:a=new Wa(this,b,a),c.push(a)}};F.xb=function(){var a,b;a=0;for(b=this.Lf.length;a<b;a++)this.Lf[a].xb(a<b-1&&this.Lf[a+1].Ck)};
F.Fb=function(){this.Km=m;this.a.Qm=m;var a,b;a=0;for(b=this.Lf.length;a<b;a++){var c=this.Lf[a];c.Fb();this.a.dm(c.yb);(!this.a.Xe.Bk()||this.a.Ue.length)&&this.a.ld()}this.a.Qm=q};
F.Vp=function(a,b){a.Yd||this.a.xl.push(a);var c,d,e=a.cb[b],f;f=e.type?e.type.name:"system";var g=(c=e.zp)?this.Ap:this.Ar;g[f]||(g[f]=[]);f=g[f];g=e.Bb;if(c){if(e.N.length&&(e=e.N[0],!(1!==e.type||2!==e.me.type))){e=e.me.value.toLowerCase();c=0;for(d=f.length;c<d;c++)if(f[c].method==g){c=f[c].lk;c[e]?c[e].push([a,b]):c[e]=[[a,b]];return}c={};c[e]=[[a,b]];f.push({method:g,lk:c})}}else{c=0;for(d=f.length;c<d;c++)if(f[c].method==g){f[c].lk.push([a,b]);return}f.push({method:g,lk:[[a,b]]})}};Na=bc;
cc.prototype.Jm=function(){return this.fb?this.type.l.length:this.l.length};cc.prototype.Ld=function(){return this.fb?this.type.l:this.l};cc.prototype.Wq=function(a){a&&(a.a.zc().yc.Yd?(this.fb&&(this.l.length=0,pa(this.rb,a.type.l),this.fb=q),a=this.rb.indexOf(a),-1!==a&&(this.l.push(this.rb[a]),this.rb.splice(a,1))):(this.fb=q,this.l.length=1,this.l[0]=a))};La=cc;F=dc.prototype;
F.xb=function(a){var b,c=this.parent;if(this.group)for(this.tl=m;c;){if(!c.group){this.tl=q;break}c=c.parent}this.xr=!this.bq()&&(!this.parent||this.parent.group&&this.parent.tl);this.Qp=!!a;this.bg=this.yb.slice(0);for(c=this.parent;c;){a=0;for(b=c.yb.length;a<b;a++)this.ys(c.yb[a]);c=c.parent}this.yb=$b(this.yb);this.bg=$b(this.bg);a=0;for(b=this.cb.length;a<b;a++)this.cb[a].xb();a=0;for(b=this.mg.length;a<b;a++)this.mg[a].xb();a=0;for(b=this.Dd.length;a<b;a++)this.Dd[a].xb(a<b-1&&this.Dd[a+1].Ck)};
F.Zo=function(a){ec(a,this.yb)};F.ys=function(a){ec(a,this.bg)};F.nl=function(){this.jo=m;this.parent&&this.parent.nl()};F.bq=function(){return this.cb.length?this.cb[0].trigger:q};
F.Fb=function(){var a,b=q,c=this.a.zc();c.yc=this;this.Ck||(c.sm=q);if(this.Yd){0===this.cb.length&&(b=m);c.zb=0;for(a=this.cb.length;c.zb<a;c.zb++)this.cb[c.zb].trigger||this.cb[c.zb].Fb()&&(b=m);(c.Ah=b)&&this.kl()}else{c.zb=0;for(a=this.cb.length;c.zb<a;c.zb++)if(!this.cb[c.zb].Fb()){c.Ah=q;return}c.Ah=m;this.kl()}c.Ah&&this.Qp&&(c.sm=m);this.xr&&(!this.a.Xe.Bk()||this.a.Ue.length)&&this.a.ld()};F.xv=function(a){this.a.zc().yc=this;this.cb[a].Fb()&&this.kl()};
F.kl=function(){var a=this.a.zc(),b;a.Oe=0;for(b=this.mg.length;a.Oe<b;a.Oe++)if(this.mg[a.Oe].Fb())return;this.gr()};F.vv=function(){var a=this.a.zc(),b;for(b=this.mg.length;a.Oe<b;a.Oe++)if(this.mg[a.Oe].Fb())return;this.gr()};F.gr=function(){if(this.Dd.length){var a,b,c,d,e=this.Dd.length-1;this.a.gl(this);if(this.jo){a=0;for(b=this.Dd.length;a<b;a++)c=this.Dd[a],(d=!this.tl||!this.group&&a<e)&&this.a.xj(c.yb),c.Fb(),d?this.a.Yf(c.yb):this.a.dm(c.yb)}else{a=0;for(b=this.Dd.length;a<b;a++)this.Dd[a].Fb()}this.a.el()}};
F.yv=function(){var a=this.a.zc();a.yc=this;var b=q,c;a.zb=0;for(c=this.cb.length;a.zb<c;a.zb++)if(this.cb[a.zb].Fb())b=m;else if(!this.Yd)return q;return this.Yd?b:m};F.Un=function(){this.a.vm++;var a=this.a.zc().zb,b=this.a.gl(this);if(!this.Yd){b.zb=a+1;for(a=this.cb.length;b.zb<a;b.zb++)if(!this.cb[b.zb].Fb()){this.a.el();return}}this.kl();this.a.el()};Va=dc;F=fc.prototype;F.xb=function(){var a,b;a=0;for(b=this.N.length;a<b;a++)this.N[a].xb()};F.Av=D(m);
F.Zn=function(){var a,b;a=0;for(b=this.N.length;a<b;a++)this.ga[a]=this.N[a].get();return Ea(this.Bb.apply(this.a.Xg,this.ga),this.zk)};F.zv=function(){var a,b;a=0;for(b=this.N.length;a<b;a++)this.ga[a]=this.N[a].get();a=this.Bb.apply(this.type,this.ga);this.type.Gi();return a};
F.Yn=function(){var a,b,c,d,e,f,g,h=this.type.Na(),i=this.od.Yd&&!this.trigger,j=0,k=this.type.ue;if(h.fb){h.l.length=0;a=h.rb.length=0;for(c=this.type.l.length;a<c;a++){f=this.type.l[a];b=0;for(d=this.N.length;b<d;b++)this.ga[b]=this.N[b].get(a);-1<this.$b?(this.type.Sa&&(j=f.type.qh[this.type.ne]),b=this.Bb.apply(f.Rb[this.$b+j],this.ga)):b=this.Bb.apply(f,this.ga);(e=Ea(b,this.zk))?h.l.push(f):i&&h.rb.push(f)}this.type.finish&&this.type.finish(m);h.fb=q;this.type.Gi();return h.Jm()}var n=0,r=i?
h.rb:h.l;e=q;a=0;for(c=r.length;a<c;a++){f=r[a];b=0;for(d=this.N.length;b<d;b++)this.ga[b]=this.N[b].get(a);-1<this.$b?(this.type.Sa&&(j=f.type.qh[this.type.ne]),b=this.Bb.apply(f.Rb[this.$b+j],this.ga)):b=this.Bb.apply(f,this.ga);if(Ea(b,this.zk))if(e=m,i){if(h.l.push(f),k){b=0;for(d=f.siblings.length;b<d;b++)g=f.siblings[b],g.type.Na().l.push(g)}}else{r[n]=f;if(k){b=0;for(d=f.siblings.length;b<d;b++)g=f.siblings[b],g.type.Na().l[n]=g}n++}else if(i){r[n]=f;if(k){b=0;for(d=f.siblings.length;b<d;b++)g=
f.siblings[b],g.type.Na().rb[n]=g}n++}}r.length=n;if(k){a=0;for(c=this.type.Xc.length;a<c;a++)f=this.type.Xc[a].Na(),i?f.rb.length=n:f.l.length=n}j=e;if(i&&!e){a=0;for(c=h.l.length;a<c;a++){f=h.l[a];b=0;for(d=this.N.length;b<d;b++)this.ga[b]=this.N[b].get(a);b=-1<this.$b?this.Bb.apply(f.Rb[this.$b],this.ga):this.Bb.apply(f,this.ga);if(Ea(b,this.zk)){e=m;break}}}this.type.finish&&this.type.finish(j||i);return i?e:h.Jm()};Ra=fc;gc.prototype.xb=function(){var a,b;a=0;for(b=this.N.length;a<b;a++)this.N[a].xb()};
gc.prototype.Zn=function(){var a,b;a=0;for(b=this.N.length;a<b;a++)this.ga[a]=this.N[a].get();return this.Bb.apply(this.a.Xg,this.ga)};gc.prototype.Yn=function(){var a=this.type.Na().Ld(),b,c,d,e,f;b=0;for(d=a.length;b<d;b++){f=a[b];c=0;for(e=this.N.length;c<e;c++)this.ga[c]=this.N[c].get(b);-1<this.$b?(c=0,this.type.Sa&&(c=f.type.qh[this.type.ne]),this.Bb.apply(f.Rb[this.$b+c],this.ga)):this.Bb.apply(f,this.ga)}return q};Sa=gc;var lc=[],mc=-1;F=hc.prototype;
F.xb=function(){var a,b;if(11===this.type)this.vg=this.a.Kp(this.Hj,this.od.parent);else if(13===this.type){a=0;for(b=this.ci.length;a<b;a++)this.ci[a].xb()}this.me&&this.me.xb()};F.Nb=function(){mc++;lc.length===mc&&lc.push(new Xa);return lc[mc]};F.Eb=function(){mc--};F.Yt=function(a){this.cg=a||0;a=this.Nb();this.me.get(a);this.Eb();return a.data};F.Zt=function(a){this.cg=a||0;a=this.Nb();this.me.get(a);this.Eb();return H(a.data)?a.data:""};F.eu=y("object");F.Wt=y("mp");
F.cu=function(a){this.cg=a||0;a=this.Nb();this.me.get(a);this.Eb();return a.Wb()?this.a.Zi(a.data):this.a.Em(a.data)};F.du=y("Ga");F.bu=y("key");F.au=y("index");F.$t=function(a){var b=this.Y.type,c=p,c=b.Na(),d=c.Ld(),c=d.length?d[a%d.length].type:c.rb[a%c.rb.length].type;return this.index+c.mk[b.ne]};F.Xt=y("vg");F.Vt=y("Bp");F.fu=function(){var a,b;a=0;for(b=this.ci.length;a<b;a++)this.Bl[a]=this.ci[a].get();return this.Bl};Ta=hc;ic.prototype.xb=function(){this.yb=$b(this.yb)};
ic.prototype.Bv=function(a){var b=this.a.Ip();!this.parent||this.Ek||!b?this.data=a:(this.Fg>=b.length&&(b.length=this.Fg+1),b[this.Fg]=a)};ic.prototype.Ut=function(){var a=this.a.Ip();return!this.parent||this.Ek||!a?this.data:this.Fg>=a.length||"undefined"===typeof a[this.Fg]?this.Mm:a[this.Fg]};ic.prototype.Fb=function(){this.parent&&(!this.Ek&&!this.aq)&&this.Bv(this.Mm)};Pa=ic;jc.prototype.xb=function(){this.xk=this.a.um[this.lu];this.sheet.Sp.add(this.xk);this.yb=$b(this.yb)};
jc.prototype.Fb=function(){this.parent&&this.a.wj(this.a.da);this.xk.Km||this.xk.Fb();this.parent&&this.a.Yf(this.a.da)};Wa=jc;kc.prototype.reset=function(a){this.yc=a;this.Oe=this.zb=0;this.ur.length=0;this.sm=this.Ah=q};kc.prototype.su=function(){return this.yc.jo?m:this.zb<this.yc.cb.length-1?!!this.yc.yb.length:q};Oa=kc;
function nc(a,b){this.Y=a;this.a=a.a;this.type=b[0];this.get=[this.vt,this.rt,this.Dt,this.Gt,this.lt,this.Et,this.zt,this.ot,this.yt,this.Ct,this.mt,this.Bt,this.pt,this.At,this.wt,this.xt,this.st,this.tt,this.nt,this.Ft,this.wp,this.ut,this.wp,this.qt][this.type];var c=p;this.Sc=this.N=this.ga=this.Bb=this.rl=this.Yb=this.first=this.value=p;this.$b=-1;this.af=p;this.zo=-1;this.vg=this.Hj=this.Js=p;this.zj=q;switch(this.type){case 0:case 1:case 2:this.value=b[1];break;case 3:this.first=new Ua(a,
b[1]);break;case 18:this.first=new Ua(a,b[1]);this.Yb=new Ua(a,b[2]);this.rl=new Ua(a,b[3]);break;case 19:this.Bb=b[1];this.ga=[];this.N=[];3===b.length?(c=b[2],this.ga.length=c.length+1):this.ga.length=1;break;case 20:this.Sc=this.a.da[b[1]];this.$b=-1;this.Bb=b[2];this.zj=b[3];this.af=b[4]?new Ua(a,b[4]):p;this.ga=[];this.N=[];6===b.length?(c=b[5],this.ga.length=c.length+1):this.ga.length=1;break;case 21:this.Sc=this.a.da[b[1]];this.zj=b[2];this.af=b[3]?new Ua(a,b[3]):p;this.zo=b[4];break;case 22:this.Sc=
this.a.da[b[1]];this.Js=this.Sc.pk(b[2]);this.$b=this.Sc.Dm(b[2]);this.Bb=b[3];this.zj=b[4];this.af=b[5]?new Ua(a,b[5]):p;this.ga=[];this.N=[];7===b.length?(c=b[6],this.ga.length=c.length+1):this.ga.length=1;break;case 23:this.Hj=b[1],this.vg=p}4<=this.type&&17>=this.type&&(this.first=new Ua(a,b[1]),this.Yb=new Ua(a,b[2]));if(c){var d,e;d=0;for(e=c.length;d<e;d++)this.N.push(new Ua(a,c[d]))}}
function oc(a,b){this.type=a||Ya.ti;this.data=b||0;this.Vh=p;this.type==Ya.ti&&(this.data=Math.floor(this.data))}F=nc.prototype;F.xb=function(){23===this.type&&(this.vg=this.Y.a.Kp(this.Hj,this.Y.od.parent));this.first&&this.first.xb();this.Yb&&this.Yb.xb();this.rl&&this.rl.xb();this.af&&this.af.xb();if(this.N){var a,b;a=0;for(b=this.N.length;a<b;a++)this.N[a].xb()}};
F.Ft=function(a){this.ga[0]=a;var a=this.Y.Nb(),b,c;b=0;for(c=this.N.length;b<c;b++)this.N[b].get(a),this.ga[b+1]=a.data;this.Y.Eb();this.Bb.apply(this.a.Xg,this.ga)};
F.wp=function(a){var b=this.Sc.Na(),c=b.Ld();if(!c.length)if(b.rb.length)c=b.rb;else{this.zj?a.ce(""):a.Va(0);return}this.ga[0]=a;a.Vh=this.Sc;var a=this.Y.Nb(),d,b=0;for(d=this.N.length;b<d;b++)this.N[b].get(a),this.ga[b+1]=a.data;b=this.Y.cg;this.af&&(this.af.get(a),a.Wb()&&(b=a.data,c=this.Sc.l));this.Y.Eb();b%=c.length;0>b&&(b+=c.length);c=c[b];-1<this.$b?(a=0,this.Sc.Sa&&(a=c.type.qh[this.Sc.ne]),this.Bb.apply(c.Rb[this.$b+a],this.ga)):this.Bb.apply(c,this.ga)};
F.ut=function(a){var b=this.Sc.Na(),c=b.Ld();if(!c.length)if(b.rb.length)c=b.rb;else{this.zj?a.ce(""):a.Va(0);return}b=this.Y.cg;if(this.af){var d=this.Y.Nb();this.af.get(d);if(d.Wb()){b=d.data;c=this.Sc.l;b%=c.length;0>b&&(b+=c.length);c=c[b].Nd[this.zo];H(c)?a.ce(c):a.pa(c);this.Y.Eb();return}this.Y.Eb()}b%=c.length;0>b&&(b+=c.length);c=c[b];b=0;this.Sc.Sa&&(b=c.type.mk[this.Sc.ne]);c=c.Nd[this.zo+b];H(c)?a.ce(c):a.pa(c)};F.vt=function(a){a.type=Ya.ti;a.data=this.value};
F.rt=function(a){a.type=Ya.pi;a.data=this.value};F.Dt=function(a){a.type=Ya.Tl;a.data=this.value};F.Gt=function(a){this.first.get(a);a.Wb()&&(a.data=-a.data)};F.lt=function(a){this.first.get(a);var b=this.Y.Nb();this.Yb.get(b);a.Wb()&&b.Wb()&&(a.data+=b.data,b.vh()&&a.Sh());this.Y.Eb()};F.Et=function(a){this.first.get(a);var b=this.Y.Nb();this.Yb.get(b);a.Wb()&&b.Wb()&&(a.data-=b.data,b.vh()&&a.Sh());this.Y.Eb()};
F.zt=function(a){this.first.get(a);var b=this.Y.Nb();this.Yb.get(b);a.Wb()&&b.Wb()&&(a.data*=b.data,b.vh()&&a.Sh());this.Y.Eb()};F.ot=function(a){this.first.get(a);var b=this.Y.Nb();this.Yb.get(b);a.Wb()&&b.Wb()&&(a.data/=b.data,a.Sh());this.Y.Eb()};F.yt=function(a){this.first.get(a);var b=this.Y.Nb();this.Yb.get(b);a.Wb()&&b.Wb()&&(a.data%=b.data,b.vh()&&a.Sh());this.Y.Eb()};
F.Ct=function(a){this.first.get(a);var b=this.Y.Nb();this.Yb.get(b);a.Wb()&&b.Wb()&&(a.data=Math.pow(a.data,b.data),b.vh()&&a.Sh());this.Y.Eb()};F.mt=function(a){this.first.get(a);var b=this.Y.Nb();this.Yb.get(b);a.Wb()?b.Fk()?a.ce(a.data.toString()+b.data):a.data&&b.data?a.Va(1):a.Va(0):a.Fk()&&(a.data=b.Fk()?a.data+b.data:a.data+(Math.round(1E10*b.data)/1E10).toString());this.Y.Eb()};
F.Bt=function(a){this.first.get(a);var b=this.Y.Nb();this.Yb.get(b);a.Wb()&&b.Wb()&&(a.data||b.data?a.Va(1):a.Va(0));this.Y.Eb()};F.nt=function(a){this.first.get(a);a.data?this.Yb.get(a):this.rl.get(a)};F.pt=function(a){this.first.get(a);var b=this.Y.Nb();this.Yb.get(b);a.Va(a.data===b.data?1:0);this.Y.Eb()};F.At=function(a){this.first.get(a);var b=this.Y.Nb();this.Yb.get(b);a.Va(a.data!==b.data?1:0);this.Y.Eb()};
F.wt=function(a){this.first.get(a);var b=this.Y.Nb();this.Yb.get(b);a.Va(a.data<b.data?1:0);this.Y.Eb()};F.xt=function(a){this.first.get(a);var b=this.Y.Nb();this.Yb.get(b);a.Va(a.data<=b.data?1:0);this.Y.Eb()};F.st=function(a){this.first.get(a);var b=this.Y.Nb();this.Yb.get(b);a.Va(a.data>b.data?1:0);this.Y.Eb()};F.tt=function(a){this.first.get(a);var b=this.Y.Nb();this.Yb.get(b);a.Va(a.data>=b.data?1:0);this.Y.Eb()};F.qt=function(a){var b=this.vg.Ut();fa(b)?a.pa(b):a.ce(b)};Ua=nc;F=oc.prototype;
F.vh=function(){return this.type===Ya.pi};F.Wb=function(){return this.type===Ya.ti||this.type===Ya.pi};F.Fk=function(){return this.type===Ya.Tl};F.Sh=function(){this.vh()||(this.Fk()&&(this.data=parseFloat(this.data)),this.type=Ya.pi)};F.Va=function(a){this.type=Ya.ti;this.data=Math.floor(a)};F.pa=function(a){this.type=Ya.pi;this.data=a};F.ce=function(a){this.type=Ya.Tl;this.data=a};Xa=oc;Ya={ti:0,pi:1,Tl:2};function L(a){this.a=a;this.xf=[]}function pc(){}function qc(){}function rc(){}var sc=L.prototype;
F=pc.prototype;F.No=D(m);F.fs=D(m);F.Mr=function(a,b,c){return tc(a,b,c)};F.Rr=function(a,b,c){var d=this.a.zc(),e=d.yc,d=d.su(),a=this.a.qv(a);if(d)for(;b<=c&&!a.Fc;b++)this.a.xj(e.yb),a.index=b,e.Un(),this.a.Yf(e.yb);else for(;b<=c&&!a.Fc;b++)a.index=b,e.Un();this.a.lv();return q};F.Pr=function(a){var b=this.a.Hp(),c=b.Ma.Gl||0,d=this.a.Nf.de;return d>=c+a?(b.Ma.Gl=c+a,d>=b.Ma.Gl+a&&(b.Ma.Gl=d),m):q};F.Or=function(){var a=this.a.zc();return a.sm?q:!a.Ah};F.Oo=D(m);F.Xr=D(m);sc.C=new pc;
qc.prototype.Oj=function(a){!this.a.wh&&!this.a.Hf&&(this.a.Hf=a)};qc.prototype.Fl=function(a,b,c,d){if(b&&a&&(b=this.a.sp(a,b,c,d))){this.a.Od++;this.a.trigger(Object.getPrototypeOf(a.Mb).C.Yr,b);this.a.Od--;a=a.Na();a.fb=q;a.l.length=1;a.l[0]=b;var e;if(b.ue){c=0;for(d=b.siblings.length;c<d;c++)e=b.siblings[c],a=e.type.Na(),a.fb=q,a.l.length=1,a.l[0]=e}}};qc.prototype.rs=function(a,b){a&&(b=ra(b/100,0,1),a.opacity!==b&&(a.opacity=b,this.a.Pa=m))};
qc.prototype.Ro=function(){if(!this.a.wh&&!this.a.Hf&&this.a.bb){this.a.Hf=this.a.bb;var a,b,c;a=0;for(b=this.a.Vl.length;a<b;a++)c=this.a.Vl[a],this.a.Xo[c.Gm.toLowerCase()]=c.yk}};sc.L=new qc;rc.prototype["int"]=function(a,b){H(b)?(a.Va(parseInt(b,10)),isNaN(a.data)&&(a.data=0)):a.Va(b)};rc.prototype["float"]=function(a,b){H(b)?(a.pa(parseFloat(b)),isNaN(a.data)&&(a.data=0)):a.pa(b)};F=rc.prototype;F.random=function(a,b,c){c===l?a.pa(Math.random()*b):a.pa(Math.random()*(c-b)+b)};
F.sqrt=function(a,b){a.pa(Math.sqrt(b))};F.abs=function(a,b){a.pa(Math.abs(b))};F.round=function(a,b){a.Va(Math.round(b))};F.floor=function(a,b){a.Va(Math.floor(b))};F.ceil=function(a,b){a.Va(Math.ceil(b))};F.sin=function(a,b){a.pa(Math.sin(K(b)))};F.cos=function(a,b){a.pa(Math.cos(K(b)))};F.tan=function(a,b){a.pa(Math.tan(K(b)))};F.asin=function(a,b){a.pa(sa(Math.asin(b)))};F.acos=function(a,b){a.pa(sa(Math.acos(b)))};
F.max=function(a){var b=arguments[1],c,d;c=2;for(d=arguments.length;c<d;c++)b<arguments[c]&&(b=arguments[c]);a.pa(b)};F.min=function(a){var b=arguments[1],c,d;c=2;for(d=arguments.length;c<d;c++)b>arguments[c]&&(b=arguments[c]);a.pa(b)};F.fa=function(a){a.pa(this.a.fa)};F.fg=function(a){a.pa(this.a.fg)};F.time=function(a){a.pa(this.a.Nf.de)};F.eg=function(a){a.Va(this.a.eg)};F.bl=function(a){a.Va(this.a.bl)};F.zm=function(a){a.Va(this.a.zm)};F.Ye=function(a,b,c,d,e){a.pa(Da(b,c,d,e))};
F.v=function(a,b,c,d,e){a.pa(sa(za(b,c,d,e)))};F.left=function(a,b,c){a.ce(H(b)?b.substr(0,c):"")};F.right=function(a,b,c){a.ce(H(b)?b.substr(b.length-c):"")};F.replace=function(a,b,c,d){H(b)&&H(c)&&H(d)?a.ce(b.replace(RegExp(Ha(c),"gi"),d)):a.ce(H(b)?b:"")};F.im=function(a){a.pa(this.a.im/1E3)};F.Fh=function(a){a.pa(this.a.Fh)};sc.Fa=new rc;
sc.wv=function(){var a,b,c,d,e,f=this.a.zc();a=0;for(c=this.xf.length;a<c;a++)if(d=this.xf[a],!(d.time>this.a.Nf.de)){f.yc=d.kt;f.Oe=d.Oe;f.zb=0;for(b in d.ai)d.ai.hasOwnProperty(b)&&(e=this.a.da[parseInt(b,10)].Na(),e.fb=q,e.l=d.ai[b]);d.kt.vv();this.a.dm(d.yb);d.Ss=m}b=a=0;for(c=this.xf.length;a<c;a++)d=this.xf[a],this.xf[b]=d,d.Ss||b++;this.xf.length=b};
function wb(a){var b=a[0].prototype,c=a[1],d=a[3],e=a[4],f=a[5],g=a[6],h=a[7],a=a[8];b.C||(b.C={});b.L||(b.L={});b.Fa||(b.Fa={});var i=b.C,j=b.L,b=b.Fa;d&&(i.fw=function(a,b){return tc(this.x,a,b)},i.Fo=function(a,b){return tc(this.y,a,b)},i.mw=function(){var a=this.F;this.gb();var b=this.ea;return!(b.right<a.Ed||b.bottom<a.Fd||b.left>a.kd||b.top>a.jd)},i.nw=function(){this.gb();var a=this.ea,b=this.a.bb;return 0>a.right||0>a.bottom||a.left>b.width||a.top>b.height},i.yw=function(a,b,c){var d=this.Na(),
e=d.Ld();if(!e.length)return q;var f=e[0],g=f,h=Da(f.x,f.y,b,c),i,j,z;i=1;for(j=e.length;i<j;i++)if(f=e[i],z=Da(f.x,f.y,b,c),0===a&&z<h||1===a&&z>h)h=z,g=f;d.Wq(g);return m},j.Ow=function(a){this.x!==a&&(this.x=a,this.ha())},j.Rl=function(a){this.y!==a&&(this.y=a,this.ha())},j.Kw=function(a,b){if(this.x!==a||this.y!==b)this.x=a,this.y=b,this.ha()},j.Lw=function(a,b){var c=a.Qt(this);if(c){var d;c.pe?(d=c.pe(b,m),c=c.pe(b,q)):(d=c.x,c=c.y);if(this.x!==d||this.y!==c)this.x=d,this.y=c,this.ha()}},j.sw=
function(a){0!==a&&(this.x+=Math.cos(this.v)*a,this.y+=Math.sin(this.v)*a,this.ha())},j.rw=function(a,b){0!==b&&(this.x+=Math.cos(K(a))*b,this.y+=Math.sin(K(a))*b,this.ha())},b.Ci=function(a){a.pa(this.x)},b.xs=function(a){a.pa(this.y)},b.fa=function(a){a.pa(this.a.qk(this))});e&&(i.ew=function(a,b){return tc(this.width,a,b)},i.cw=function(a,b){return tc(this.height,a,b)},j.Ql=function(a){this.width!==a&&(this.width=a,this.ha())},j.Iw=function(a){this.height!==a&&(this.height=a,this.ha())},j.Mw=function(a,
b){if(this.width!==a||this.height!==b)this.width=a,this.height=b,this.ha()},b.Rw=function(a){a.pa(this.width)},b.gw=function(a){a.pa(this.height)});f&&(i.bw=function(a,b){return Aa(this.v,K(b))<=K(a)},i.kw=function(a){return Ca(this.v,K(a))},i.iw=function(a,b){var c=wa(a),d=wa(b),e=ua(this.v);return Ca(d,c)?Ca(e,c)&&!Ca(e,d):!(!Ca(e,c)&&Ca(e,d))},j.So=function(a){a=K(ta(a));!isNaN(a)&&this.v!==a&&(this.v=a,this.ha())},j.Bw=function(a){0!==a&&!isNaN(a)&&(this.v+=K(a),this.v=ua(this.v),this.ha())},
j.Cw=function(a){0!==a&&!isNaN(a)&&(this.v-=K(a),this.v=ua(this.v),this.ha())},j.Dw=function(a,b){var c=Ba(this.v,K(b),K(a));!isNaN(c)&&this.v!==c&&(this.v=c,this.ha())},j.Ew=function(a,b,c){a=Ba(this.v,Math.atan2(c-this.y,b-this.x),K(a));!isNaN(a)&&this.v!==a&&(this.v=a,this.ha())},j.Nw=function(a,b){var c=Math.atan2(b-this.y,a-this.x);!isNaN(c)&&this.v!==c&&(this.v=c,this.ha())},b.aw=function(a){a.pa(va(this.v))});c||(i.li=function(a,b,c){return tc(this.Nd[a],b,c)},i.jw=function(a){return this.Nd[a]},
i.xw=function(a){return this.uid===a},i.Yr=D(m),i.Zr=D(m),j.Ol=function(a,b){var c=this.Nd;fa(c[a])?c[a]=fa(b)?b:parseFloat(b):H(c[a])&&(c[a]=H(b)?b:b.toString())},j.$v=function(a,b){var c=this.Nd;fa(c[a])?c[a]=fa(b)?c[a]+b:c[a]+parseFloat(b):H(c[a])&&(c[a]=H(b)?c[a]+b:c[a]+b.toString())},j.Ul=function(a,b){var c=this.Nd;fa(c[a])&&(c[a]=fa(b)?c[a]-b:c[a]-parseFloat(b))},j.Fw=function(a,b){this.Nd[a]=b?1:0},j.Pw=function(a){this.Nd[a]=1-this.Nd[a]},j.vc=function(){this.a.eh(this)},b.Go=function(a){var b=
a.Vh.l.length,c,d,e;c=0;for(d=this.a.Ue.length;c<d;c++)e=this.a.Ue[c],a.Vh.Sa?0<=e.type.Kb.indexOf(a.Vh)&&b++:e.type===a.Vh&&b++;a.Va(b)},b.Aw=function(a){a.Va(a.Vh.Na().Ld().length)},b.Qw=function(a){a.Va(this.uid)},b.hw=function(a){a.Va(this.uk())});g&&(i.ow=y("visible"),j.To=function(a){!a!==!this.visible&&(this.visible=a,this.a.Pa=m)},i.dw=function(a,b){return tc(Ka(100*this.opacity),a,b)},j.Jw=function(a){a/=100;0>a?a=0:1<a&&(a=1);a!==this.opacity&&(this.opacity=a,this.a.Pa=m)},b.ww=function(a){a.pa(Ka(100*
this.opacity))});h&&(i.lw=function(a){return!a?q:this.F===a},i.zw=function(a){var b=this.Na(),c=b.Ld();if(!c.length)return q;var d=c[0],e=d,f,g;f=1;for(g=c.length;f<g;f++)if(d=c[f],0===a){if(d.F.index>e.F.index||d.F.index===e.F.index&&d.$e()>e.$e())e=d}else if(d.F.index<e.F.index||d.F.index===e.F.index&&d.$e()<e.$e())e=d;b.Wq(e);return m},j.vw=function(){var a=this.$e();a!==this.F.l.length-1&&(oa(this.F.l,a),this.F.l.push(this),this.a.Pa=m,this.F.ig=m)},j.tw=function(){var a=this.$e();0!==a&&(oa(this.F.l,
a),this.F.l.unshift(this),this.a.Pa=m,this.F.ig=m)},j.uw=function(a){a&&a!=this.F&&(oa(this.F.l,this.$e()),this.F.ig=m,this.F=a,this.Co=a.l.length,a.l.push(this),this.a.Pa=m)},b.qw=function(a){a.Va(this.F.Rq)},b.pw=function(a){a.ce(this.F.name)},b.Sw=function(a){a.Va(this.$e())});a&&(j.Gw=function(a,b){if(this.a.P){var c=this.type.Jp(b);if(!(0>c)){var d=1===a;this.jh[c]!==d&&(this.jh[c]=d,this.hi(),this.a.Pa=m)}}},j.Hw=function(a,b,c){if(this.a.P){var d=this.type.Jp(a);0>d||(a=this.type.Ea[d],d=this.oc[d],
b=Math.floor(b),0>b||b>=d.length||(1===this.a.P.Tt(a.jc,b)&&(c/=100),d[b]!==c&&(d[b]=c,a.ie&&(this.a.Pa=m))))}})}function Nb(){this.Zl=m;this.a.Pa=m;var a,b;a=0;for(b=this.Vj.length;a<b;a++)this.Vj[a](this)}function Ob(a){a&&this.Vj.push(a)}
function Qb(){if(this.Zl){this.ea.set(this.x,this.y,this.x+this.width,this.y+this.height);this.ea.offset(-this.qe*this.width,-this.re*this.height);this.v?(this.ea.offset(-this.x,-this.y),this.Ka.lr(this.ea,this.v),this.Ka.offset(this.x,this.y),this.Ka.hp(this.ea)):this.Ka.bo(this.ea);var a=0;this.ea.left>this.ea.right&&(a=this.ea.left,this.ea.left=this.ea.right,this.ea.right=a);this.ea.top>this.ea.bottom&&(a=this.ea.top,this.ea.top=this.ea.bottom,this.ea.bottom=a);this.Zl=q}}
function Pb(a,b){return!this.ea.pd(a,b)||!this.Ka.pd(a,b)?q:this.Da&&!this.Da.uh()?(this.Da.mh(this.width,this.height,this.v),this.Da.pd(a-this.x,b-this.y)):m}function Jb(){this.type.yl();return this.aj}function Rb(){this.F.Ov();return this.Co}function Sb(){this.za.length=0;var a,b;a=0;for(b=this.jh.length;a<b;a++)this.jh[a]&&this.za.push(this.type.Ea[a]);this.Hr=!!this.za.length}function Kb(){return"inst:"+this.type.name+"#"+this.uid}function yb(){var a=this.Na().Ld();return a.length?a[0]:p}
function zb(a){var b=this.Na().Ld();return b.length?b[a.uk()%b.length]:p}function xb(){if(this.Wg&&!this.Sa){var a,b;a=0;for(b=this.l.length;a<b;a++)this.l[a].aj=a;this.Wg=q}}function Ab(){return this.dg[this.We]}function Bb(){this.We++;this.We===this.dg.length?this.dg.push(new La(this)):this.dg[this.We].fb=m}function Cb(){this.We++;this.We===this.dg.length&&this.dg.push(new La(this));var a=this.dg[this.We],b=this.dg[this.We-1];b.fb?a.fb=m:(a.fb=q,pa(a.l,b.l))}function Db(){this.We--}
function Eb(a){var b,c,d,e,f,g=0;if(!this.Sa){b=0;for(c=this.Kb.length;b<c;b++){f=this.Kb[b];d=0;for(e=f.Sb.length;d<e;d++){if(a===f.Sb[d].name)return this.Ma.dq=g,f.Sb[d];g++}}}b=0;for(c=this.Sb.length;b<c;b++){if(a===this.Sb[b].name)return this.Ma.dq=g,this.Sb[b];g++}return p}function Fb(a){return this.pk(a)?this.Ma.dq:-1}function Gb(a){var b,c;b=0;for(c=this.Ea.length;b<c;b++)if(this.Ea[b].name===a)return b;return-1}
function Hb(){if(this.ue&&!this.Sa){var a,b,c,d,e,f,g;this.yl();f=this.Na();var h=f.fb,i=(a=this.a.zc())&&a.yc&&a.yc.Yd;a=0;for(b=this.Xc.length;a<b;a++)if(e=this.Xc[a],e!==this&&(e.yl(),g=e.Na(),g.fb=h,!h)){g.l.length=f.l.length;g.rb.length=f.l.length;c=0;for(d=f.l.length;c<d;c++)g.l[c]=e.l[f.l[c].aj];if(i){c=0;for(d=f.rb.length;c<d;c++)g.rb[c]=e.l[f.rb[c].aj]}}}}function Ib(){return this.name}
function tc(a,b,c){if("undefined"===typeof a||"undefined"===typeof c)return q;switch(b){case 0:return a===c;case 1:return a!==c;case 2:return a<c;case 3:return a<=c;case 4:return a>c;case 5:return a>=c;default:return q}}
var rb={colorblend:{src:"varying mediump vec2 vTex;\nuniform lowp sampler2D samplerFront;\nuniform lowp sampler2D samplerBack;\nuniform mediump vec2 destStart;\nuniform mediump vec2 destEnd;\nprecision mediump float;\nvec3 rgb_to_hsl(vec3 color)\n{\nvec3 hsl = vec3(0.0, 0.0, 0.0);\nfloat fmin = min(min(color.r, color.g), color.b);\nfloat fmax = max(max(color.r, color.g), color.b);\nfloat delta = fmax - fmin;\nhsl.z = (fmax + fmin) / 2.0;\nif (delta == 0.0)\n{\nhsl.x = 0.0;\nhsl.y = 0.0;\n}\nelse\n{\nif (hsl.z < 0.5)\nhsl.y = delta / (fmax + fmin);\nelse\nhsl.y = delta / (2.0 - fmax - fmin);\nfloat dR = (((fmax - color.r) / 6.0) + (delta / 2.0)) / delta;\nfloat dG = (((fmax - color.g) / 6.0) + (delta / 2.0)) / delta;\nfloat dB = (((fmax - color.b) / 6.0) + (delta / 2.0)) / delta;\nif (color.r == fmax)\nhsl.x = dB - dG;\nelse if (color.g == fmax)\nhsl.x = (1.0 / 3.0) + dR - dB;\nelse if (color.b == fmax)\nhsl.x = (2.0 / 3.0) + dG - dR;\nif (hsl.x < 0.0)\nhsl.x += 1.0;\nelse if (hsl.x > 1.0)\nhsl.x -= 1.0;\n}\nreturn hsl;\n}\nfloat hue_to_rgb(float f1, float f2, float hue)\n{\nif (hue < 0.0)\nhue += 1.0;\nelse if (hue > 1.0)\nhue -= 1.0;\nfloat ret;\nif ((6.0 * hue) < 1.0)\nret = f1 + (f2 - f1) * 6.0 * hue;\nelse if ((2.0 * hue) < 1.0)\nret = f2;\nelse if ((3.0 * hue) < 2.0)\nret = f1 + (f2 - f1) * ((2.0 / 3.0) - hue) * 6.0;\nelse\nret = f1;\nreturn ret;\n}\nvec3 hsl_to_rgb(vec3 hsl)\n{\nvec3 rgb = vec3(hsl.z);\nif (hsl.y != 0.0)\n{\nfloat f2;\nif (hsl.z < 0.5)\nf2 = hsl.z * (1.0 + hsl.y);\nelse\nf2 = (hsl.z + hsl.y) - (hsl.y * hsl.z);\nfloat f1 = 2.0 * hsl.z - f2;\nrgb.r = hue_to_rgb(f1, f2, hsl.x + (1.0 / 3.0));\nrgb.g = hue_to_rgb(f1, f2, hsl.x);\nrgb.b = hue_to_rgb(f1, f2, hsl.x - (1.0 / 3.0));\n}\nreturn rgb;\n}\nvoid main(void)\n{\nvec4 front = texture2D(samplerFront, vTex);\nvec3 fronthsl = rgb_to_hsl(front.rgb / front.a);\nvec4 back = texture2D(samplerBack, mix(destStart, destEnd, vTex));\nvec3 backhsl = rgb_to_hsl(back.rgb / back.a);\nfronthsl = hsl_to_rgb(vec3(fronthsl.x, fronthsl.y, backhsl.z));\nfronthsl *= front.a;\ngl_FragColor = vec4(fronthsl.r, fronthsl.g, fronthsl.b, front.a) * back.a;\n}",Ti:0,
Ui:0,gk:q,Uj:q,N:[]},water:{src:"varying mediump vec2 vTex;\nuniform lowp sampler2D samplerFront;\nprecision mediump float;\nuniform float seconds;\nuniform float pixelWidth;\nuniform float pixelHeight;\nconst float PI = 3.1415926535897932;\nuniform float speed;\nuniform float speed_x;\nuniform float speed_y;\nuniform float intensity;\nconst int steps = 8;\nuniform float frequency;\nuniform float angle; // better when a prime\nuniform float delta;\nuniform float intence;\nuniform float emboss;\nfloat col(vec2 coord)\n{\nfloat delta_theta = 2.0 * PI / angle;\nfloat col = 0.0;\nfloat theta = 0.0;\nfor (int i = 0; i < steps; i++)\n{\nvec2 adjc = coord;\ntheta = delta_theta*float(i);\nadjc.x += cos(theta)*seconds*speed + seconds * speed_x;\nadjc.y -= sin(theta)*seconds*speed - seconds * speed_y;\ncol = col + cos( (adjc.x*cos(theta) - adjc.y*sin(theta))*frequency)*intensity;\n}\nreturn cos(col);\n}\nvoid main(void)\n{\nvec2 p = vTex, c1 = p, c2 = p;\nfloat cc1 = col(c1);\nc2.x += (1.0 / pixelWidth) / delta;\nfloat dx = emboss*(cc1-col(c2))/delta;\nc2.x = p.x;\nc2.y += (1.0 / pixelHeight) / delta;\nfloat dy = emboss*(cc1-col(c2))/delta;\nc1.x += dx;\nc1.y = -(c1.y+dy);\nfloat alpha = 1.+dot(dx,dy)*intence;\nc1.y = -c1.y;\ngl_FragColor = texture2D(samplerFront,c1)*(alpha);\n}",
Ti:25,Ui:25,gk:q,Uj:m,N:[["speed",0,1],["speed_x",0,1],["speed_y",0,1],["intensity",0,0],["frequency",0,0],["angle",0,0],["delta",0,0],["intence",0,0],["emboss",0,1]]}};function uc(a){this.a=a}
function vc(a,b){this.src=a;this.Wd=wc;this.Dk=b;this.ap=q;var c=this;wc===xc&&(b&&!yc.cj&&!yc.cf)&&(this.Wd=zc);this.xc=p;var d;switch(this.Wd){case zc:b&&yc.dj&&CocoonJS.App.markAsMusic(a);this.xc=new Audio;this.xc.autoplay=q;this.xc.sx="auto";this.xc.src=a;break;case xc:d=new XMLHttpRequest;d.open("GET",a,m);d.responseType="arraybuffer";d.onload=function(){if(Ac.decodeAudioData)Ac.decodeAudioData(d.response,function(a){c.xc=a;ea(c.dl)||(a=new Bc(c,c.dl),a.play(c.yq,c.Kr),Cc.push(a))});else if(c.xc=
Ac.createBuffer(d.response,q),!ea(c.dl)){var a=new Bc(c,c.dl);a.play(c.yq,c.Kr);Cc.push(a)}};d.send();break;case Dc:this.xc=m;break;case Ec:this.xc=m}}
function Bc(a,b){this.Cj=b;this.Fc=this.oe=m;this.src=a.src;this.buffer=a;this.Wd=a.Wd;this.Dk=a.Dk;this.playbackRate=1;this.Jn=m;this.hn=this.tf=q;var c=this;this.Oq=this.volume=1;this.startTime=yc.Nf.de;this.ma=p;var d=q;switch(this.Wd){case zc:this.Dk?(this.ma=a.xc,d=!a.ap,a.ap=m):(this.ma=new Audio,this.ma.autoplay=q,this.ma.src=a.xc.src,d=m);d&&this.ma.addEventListener("ended",function(){Fc=c.Cj;c.Fc=m;yc.trigger(uc.prototype.C.Kl,Gc)});break;case xc:a.xc&&(this.ma=Ac.createBufferSource(),this.ma.buffer=
a.xc,this.ma.connect(Ac.destination));break;case Dc:this.ma=new window.Media(Hc+this.src,p,p,function(a){a===window.Media.MEDIA_STOPPED&&(c.Jn=m,c.Fc=m,Fc=c.Cj,yc.trigger(uc.prototype.C.Kl,Gc))});break;case Ec:this.ma=m}}function Ic(){}var Jc=uc.prototype;Jc.ta=function(a){this.Mb=a;this.a=a.a};Jc.ta.prototype.X=v();var yc=p,Gc=p,Fc="",Hc="",zc=0,xc=1,Dc=2,Ec=3,wc=zc,Ac=p,Kc=[],Cc=[],Lc=0,Mc=q,Nc=[];F=Bc.prototype;
F.Op=function(){switch(this.Wd){case zc:return this.ma.ended;case xc:return!this.oe&&!this.Fc&&this.ma.loop?q:yc.Nf.de-this.startTime>this.buffer.xc.duration;case Dc:return this.Jn;case Ec:m}return m};F.Ls=function(){return this.oe||this.Fc?m:this.Op()};
F.play=function(a,b){var c=this.ma;this.hn=a;switch(this.Wd){case zc:1!==c.playbackRate&&(c.playbackRate=1);c.volume!==b&&(c.volume=b);c.loop!==a&&(c.loop=a);c.muted&&(c.muted=q);if(!this.oe&&this.Fc&&0!==c.currentTime)try{c.currentTime=0}catch(d){}this.ma.play();break;case xc:this.muted=q;this.volume=b;this.Oq=1;if(yc.cf&&3<Nc.length)break;this.oe||(this.ma=Ac.createBufferSource(),this.ma.buffer=this.buffer.xc,this.ma.connect(Ac.destination));this.ma.loop=a;this.ma.gain.value=b;yc.cf&&!Mc?Nc.push(this.ma):
this.ma.noteOn(0);break;case Dc:!this.oe&&this.Fc&&c.seekTo(0);c.play();this.Jn=q;break;case Ec:yc.te?AppMobi.context.playSound(this.src):AppMobi.player.playSound(this.src)}this.playbackRate=1;this.startTime=yc.Nf.de;this.Fc=this.oe=q};F.Nv=function(){var a=this.playbackRate;if(1===Lc&&!this.Dk||2===Lc)a*=yc.fg;switch(this.Wd){case zc:this.ma.playbackRate!==a&&(this.ma.playbackRate=a);break;case xc:this.ma.playbackRate.value!==a&&(this.ma.playbackRate.value=a)}};
F.ao=function(a){switch(this.Wd){case zc:a?!this.oe&&!this.Fc?(this.ma.pause(),this.tf=m):this.tf=q:this.tf&&this.ma.play();break;case xc:a?!this.oe&&!this.Fc?(this.ma.noteOff(0),this.tf=m):this.tf=q:this.tf&&(this.ma=Ac.createBufferSource(),this.ma.buffer=this.buffer.xc,this.ma.connect(Ac.destination),this.ma.loop=this.hn,this.ma.gain.value=this.volume*this.Oq,this.ma.noteOn(0));break;case Dc:a?!this.oe&&!this.Fc?(this.ma.pause(),this.tf=m):this.tf=q:this.tf&&this.ma.play()}};
Jc.la=function(a){this.type=a;yc=this.a=a.a;Gc=this;Ac=p;"undefined"!==typeof AudioContext?(wc=xc,Ac=new AudioContext):"undefined"!==typeof webkitAudioContext&&(wc=xc,Ac=new webkitAudioContext);this.a.cf&&wc===xc&&document.addEventListener("touchstart",function(){if(!Mc){Nc.length&&(Mc=m);var a,c;a=0;for(c=Nc.length;a<c;a++)Nc[a].noteOn(0);Nc.length=0}},q);wc!==xc&&(this.a.Pm?wc=Dc:this.a.Yp&&(wc=Ec));wc===Dc&&(Hc=location.href,a=Hc.lastIndexOf("/"),-1<a&&(Hc=Hc.substr(0,a+1)),Hc=Hc.replace("file://",
""));this.a.tu&&this.a.$p&&"undefined"===typeof Audio?(alert("It looks like you're using Safari for Windows without Quicktime. Audio cannot be played until Quicktime is installed."),this.a.eh(this)):(this.a.te||new Audio,this.a.sl(this))};var Oc=Jc.la.prototype;Oc.X=function(){Lc=this.G[0];this.a.$o(function(a){Gc.hv(a)})};Oc.hv=function(a){var b,c;b=0;for(c=Cc.length;b<c;b++)Cc[b].ao(a)};
Oc.Gc=function(){var a,b,c;a=0;for(b=Cc.length;a<b;a++)c=Cc[a],c.Wd!==zc&&c.Wd!==Ec&&(!c.oe&&!c.Fc&&c.Op())&&(c.Fc=m,Fc=c.Cj,yc.trigger(uc.prototype.C.Kl,Gc)),0!==Lc&&c.Nv()};Oc.Mt=function(a,b){var c,d,e;c=0;for(d=Kc.length;c<d;c++)if(e=Kc[c],e.src===a)return e;e=new vc(a,b);Kc.push(e);return e};
Oc.Xw=function(a,b,c,d,e){var f,g,h;f=0;for(g=Cc.length;f<g;f++)if(h=Cc[f],h.src===a&&h.Ls())return h.Cj=b,h;a=this.Mt(a,c);if(!a.xc)return"<preload>"!==b&&(a.dl=b,a.yq=d,a.Kr=e),p;h=new Bc(a,b);Cc.push(h);return h};var Pc=[];Oc.Ww=function(a){Pc.length=0;if(a.length){var b,c,d;b=0;for(c=Cc.length;b<c;b++)d=Cc[b],a.toLowerCase()===d.Cj.toLowerCase()&&Pc.push(d)}};Ic.prototype.Kl=function(a){return Fc.toLowerCase()===a.toLowerCase()};Jc.C=new Ic;Jc.L=new (v());Jc.Fa=new (v());
function Qc(a){this.a=a}function Rc(){}var Sc=Qc.prototype;Sc.ta=function(a){this.Mb=a;this.a=a.a};Sc.ta.prototype.X=v();Sc.la=function(a){this.type=a;this.a=a.a};
Sc.la.prototype.X=function(){var a=this;window.addEventListener("resize",function(){a.a.trigger(Qc.prototype.C.ns,a)});"undefined"!==typeof navigator.onLine&&(window.addEventListener("online",function(){a.a.trigger(Qc.prototype.C.js,a)}),window.addEventListener("offline",function(){a.a.trigger(Qc.prototype.C.hs,a)}));"undefined"!==typeof window.applicationCache&&(window.applicationCache.addEventListener("updateready",function(){a.a.Fh=1;a.a.trigger(Qc.prototype.C.Qo,a)}),window.applicationCache.addEventListener("progress",
function(b){a.a.Fh=b.loaded/b.total}));this.a.te||(document.addEventListener("appMobi.device.update.available",function(){a.a.trigger(Qc.prototype.C.Qo,a)}),document.addEventListener("menubutton",function(){a.a.trigger(Qc.prototype.C.gs,a)}),document.addEventListener("searchbutton",function(){a.a.trigger(Qc.prototype.C.os,a)}));this.a.$o(function(b){b?a.a.trigger(Qc.prototype.C.ks,a):a.a.trigger(Qc.prototype.C.ls,a)});this.ax="undefined"!==typeof window.is_scirra_arcade;this.Vw=""};F=Rc.prototype;
F.js=D(m);F.hs=D(m);F.Qo=D(m);F.ls=D(m);F.ks=D(m);F.ns=D(m);F.gs=D(m);F.os=D(m);Sc.C=new Rc;Sc.L=new (v());Sc.Fa=new (v());function Tc(a){this.a=a}function Uc(){}function Vc(){}var Wc=Tc.prototype;Wc.ta=function(a){this.Mb=a;this.a=a.a};Wc.ta.prototype.X=v();Wc.la=function(a){this.type=a;this.a=a.a};var Xc=Wc.la.prototype;
Xc.X=function(){if(this.a.pc)da("[Construct 2] Button plugin not supported on this platform - the object will not be created");else{this.eb=document.createElement("input");this.eb.type="button";this.eb.id=this.G[5];jQuery(this.eb).appendTo(this.a.bk?this.a.bk:"body");this.eb.value=this.G[0];this.eb.title=this.G[1];this.eb.disabled=0===this.G[3];this.Gs=0!==this.G[4];0===this.G[2]&&(jQuery(this.eb).hide(),this.visible=q);var a=this;this.eb.onclick=function(b){b.stopPropagation();a.a.trigger(Tc.prototype.C.Jl,
a)};this.eb.addEventListener("touchstart",function(a){a.stopPropagation()},q);this.eb.addEventListener("touchmove",function(a){a.stopPropagation()},q);this.eb.addEventListener("touchend",function(a){a.stopPropagation()},q);jQuery(this.eb).mousedown(function(a){a.stopPropagation()});jQuery(this.eb).mouseup(function(a){a.stopPropagation()});jQuery(this.eb).keydown(function(a){a.stopPropagation()});jQuery(this.eb).keyup(function(a){a.stopPropagation()});this.Dr();this.a.sl(this)}};
Xc.Rg=function(){this.a.pc||(jQuery(this.eb).remove(),this.eb=p)};Xc.Gc=function(){this.Dr()};
Xc.Dr=function(){if(!this.a.pc){var a=this.F.Ja(this.x,this.y,m),b=this.F.Ja(this.x,this.y,q),c=this.F.Ja(this.x+this.width,this.y+this.height,m),d=this.F.Ja(this.x+this.width,this.y+this.height,q);if(!this.visible||!this.F.visible||0>=c||0>=d||a>=this.a.width||b>=this.a.height)jQuery(this.eb).hide();else{1>a&&(a=1);1>b&&(b=1);c>=this.a.width&&(c=this.a.width-1);d>=this.a.height&&(d=this.a.height-1);jQuery(this.eb).show();var e=Math.round(a)+jQuery(this.a.canvas).offset().left,f=Math.round(b)+jQuery(this.a.canvas).offset().top;
jQuery(this.eb).offset({left:e,top:f});jQuery(this.eb).width(Math.round(c-a));jQuery(this.eb).height(Math.round(d-b));this.Gs&&jQuery(this.eb).css("font-size",this.F.Jc()-0.2+"em")}}};Xc.Kd=v();Xc.Yc=v();Uc.prototype.Jl=D(m);Wc.C=new Uc;Vc.prototype.Pl=function(a){this.a.pc||(this.eb.value=a)};Vc.prototype.To=function(a){this.a.pc||(this.visible=0!==a)};Wc.L=new Vc;Wc.Fa=new (v());function Yc(a){this.a=a}function Zc(){}var $c=Yc.prototype;$c.ta=function(a){this.Mb=a;this.a=a.a};
$c.ta.prototype.X=v();$c.la=function(a){this.type=a;this.a=a.a;this.Jk=Array(256);this.zl=Array(256);this.gi=0};var ad=$c.la.prototype;ad.X=function(){var a=this;this.a.pc||(jQuery(document).keydown(function(b){a.Fn(b)}),jQuery(document).keyup(function(b){a.Gn(b)}))};
ad.Fn=function(a){if(this.Jk[a.which])this.zl[a.which]&&a.preventDefault();else{this.Jk[a.which]=m;this.gi=a.which;this.a.trigger(Yc.prototype.C.Vr,this);var b=this.a.trigger(Yc.prototype.C.bs,this),c=this.a.trigger(Yc.prototype.C.cs,this);if(b||c)this.zl[a.which]=m,a.preventDefault()}};
ad.Gn=function(a){this.Jk[a.which]=q;this.gi=a.which;this.a.trigger(Yc.prototype.C.Wr,this);var b=this.a.trigger(Yc.prototype.C.es,this),c=this.a.trigger(Yc.prototype.C.ds,this);if(b||c||this.zl[a.which])this.zl[a.which]=m,a.preventDefault()};F=Zc.prototype;F.Jo=function(a){return this.Jk[a]};F.bs=function(a){return a===this.gi};F.Vr=D(m);F.Wr=D(m);F.es=function(a){return a===this.gi};F.cs=function(a){return a===this.gi};F.ds=function(a){return a===this.gi};$c.C=new Zc;$c.L=new (v());$c.Fa=new (v());
function bd(a){this.a=a}function cd(){}function dd(){}var ed=bd.prototype;ed.ta=function(a){this.Mb=a;this.a=a.a};ed.ta.prototype.X=v();ed.la=function(a){this.type=a;this.a=a.a;this.$l=Array(4);this.yr=this.wl=this.fi=this.Vf=this.Uf=0;this.Im=q};var fd=ed.la.prototype;
fd.X=function(){var a=this;if(!this.a.pc){jQuery(document).mousemove(function(b){a.fv(b)});jQuery(document).mousedown(function(b){a.ev(b)});jQuery(document).mouseup(function(b){a.gv(b)});jQuery(document).dblclick(function(b){a.bv(b)});var b=function(b){a.iv(b)};document.addEventListener("mousewheel",b,q);document.addEventListener("DOMMouseScroll",b,q)}};var gd={left:0,top:0};fd.fv=function(a){var b=this.a.pc?gd:jQuery(this.a.canvas).offset();this.Uf=a.pageX-b.left;this.Vf=a.pageY-b.top};
fd.Mq=function(){return 0<this.a.Mf?m:0<=this.Uf&&0<=this.Vf&&this.Uf<this.a.width&&this.Vf<this.a.height};fd.ev=function(a){this.Mq()&&(this.a.Hm&&a.preventDefault(),this.$l[a.which]=m,this.a.trigger(bd.prototype.C.Ur,this),this.fi=a.which-1,this.wl=0,this.a.trigger(bd.prototype.C.Lo,this),this.a.trigger(bd.prototype.C.Po,this))};fd.gv=function(a){this.$l[a.which]&&(this.a.Hm&&a.preventDefault(),this.a.Hm=m,this.$l[a.which]=q,this.fi=a.which-1,this.a.trigger(bd.prototype.C.ms,this))};
fd.bv=function(a){this.Mq()&&(a.preventDefault(),this.fi=a.which-1,this.wl=1,this.a.trigger(bd.prototype.C.Lo,this),this.a.trigger(bd.prototype.C.Po,this))};fd.iv=function(a){var b=a.wheelDelta?a.wheelDelta:a.detail?-a.detail:0;this.a.cj&&(b*=-1);this.yr=0>b?0:1;this.Im=q;this.a.trigger(bd.prototype.C.ps,this);this.Im&&a.preventDefault()};F=cd.prototype;F.Lo=function(a,b){return a===this.fi&&b===this.wl};F.Ur=D(m);F.ms=function(a){return a===this.fi};
F.Po=function(a,b,c){return a!==this.fi||b!==this.wl?q:this.a.Lv(c,this.Uf,this.Vf)};F.ps=function(a){this.Im=m;return a===this.yr};ed.C=new cd;ed.L=new (v());dd.prototype.Ci=function(a,b){var c,d,e,f,g;ea(b)?(c=this.a.Zi(0),d=c.scale,e=c.zf,f=c.Wf,g=c.v,c.scale=this.a.bb.scale,c.zf=1,c.Wf=1,c.v=this.a.bb.v,a.pa(c.Pc(this.Uf,this.Vf,m)),c.scale=d,c.zf=e,c.Wf=f,c.v=g):(c=fa(b)?this.a.Zi(b):this.a.Em(b))?a.pa(c.Pc(this.Uf,this.Vf,m)):a.pa(0)};
dd.prototype.xs=function(a,b){var c,d,e,f,g;ea(b)?(c=this.a.Zi(0),d=c.scale,e=c.zf,f=c.Xf,g=c.v,c.scale=this.a.bb.scale,c.zf=1,c.Xf=1,c.v=this.a.bb.v,a.pa(c.Pc(this.Uf,this.Vf,q)),c.scale=d,c.zf=e,c.Xf=f,c.v=g):(c=fa(b)?this.a.Zi(b):this.a.Em(b))?a.pa(c.Pc(this.Uf,this.Vf,q)):a.pa(0)};ed.Fa=new dd;function M(a){this.a=a}
function hd(){if(0===this.om.length){var a=document.createElement("canvas");a.width=this.width;a.height=this.height;var b=a.getContext("2d");this.bi?b.drawImage(this.R,this.Xh,this.Yh,this.width,this.height,0,0,this.width,this.height):b.drawImage(this.R,0,0,this.width,this.height);this.om=a.toDataURL("image/png")}return this.om}function id(){}function jd(){}var kd=M.prototype;kd.ta=function(a){this.Mb=a;this.a=a.a};var ld=kd.ta.prototype;
ld.X=function(){if(!this.Sa){var a,b,c,d,e,f,g,h,i;a=0;for(b=this.Qb.length;a<b;a++){e=this.Qb[a];g={};g.name=e[0];g.speed=e[1];g.loop=e[2];g.Tn=e[3];g.jl=e[4];g.Xq=e[5];g.frames=[];c=0;for(d=e[6].length;c<d;c++)f=e[6][c],h={},h.po=f[0],h.qo=f[1],h.Xh=f[2],h.Yh=f[3],h.width=f[4],h.height=f[5],h.duration=f[6],h.qe=f[7],h.re=f[8],h.Lm=f[9],h.Mn=f[10],h.Yq=f[11],h.bi=0!==h.width,h.om="",h.Yw=hd,i={left:0,top:0,right:1,bottom:1},h.ho=i,h.hb=p,(i=this.a.Kt(f[0]))?h.R=i:(h.R=new Image,h.R.src=f[0],h.R.Os=
f[0],h.R.qp=f[1],h.R.Re=p,this.a.wf.push(h.R)),g.frames.push(h);this.Qb[a]=g}}};ld.cl=function(){if(!this.Sa){var a,b,c,d,e,f;a=0;for(b=this.Qb.length;a<b;a++){e=this.Qb[a];c=0;for(d=e.frames.length;c<d;c++)f=e.frames[c],f.R.Re=p,f.hb=p}}};
ld.Hn=function(){if(!this.Sa&&this.l.length){var a,b,c,d,e,f;a=0;for(b=this.Qb.length;a<b;a++){e=this.Qb[a];c=0;for(d=e.frames.length;c<d;c++)f=e.frames[c],f.R.Re||(f.R.Re=this.a.P.Nk(f.R,q,this.a.ib,f.Yq)),f.hb=f.R.Re}a=0;for(b=this.l.length;a<b;a++)c=this.l[a],c.km=c.sg.hb}};var md=[];
ld.vo=function(){if(!this.Sa&&!this.l.length){var a=!!this.a.P,b,c,d,e,f,g,h,i;b=md.length=0;for(c=this.Qb.length;b<c;b++){g=this.Qb[b];d=0;for(e=g.frames.length;d<e;d++)if(h=g.frames[d],i=a?h.R.Re:h.R)f=md.indexOf(i),-1===f&&md.push(i),h.R.Re=p,h.hb=p}b=0;for(c=md.length;b<c;b++)i=md[b],a?this.a.P.deleteTexture(i):i.hintUnload&&i.hintUnload();md.length=0}};kd.la=function(a){this.type=a;this.a=a.a;this.Da=new fb(this.type.Qb[0].frames[0].Mn)};var nd=kd.la.prototype;
nd.X=function(){this.visible=0===this.G[0];this.Rp=this.vu=q;this.Pi=0!==this.G[2];!(1===this.type.Qb.length&&1===this.type.Qb[0].frames.length)&&0!==this.type.Qb[0].speed&&(this.a.sl(this),this.vu=m);this.Jb=this.type.Qb[0];this.T=this.G[1];0>this.T&&(this.T=0);this.T>=this.Jb.frames.length&&(this.T=this.Jb.frames.length-1);if(0!==this.T){var a=this.Jb.frames[this.T];this.Da.co(a.Mn);this.qe=a.qe;this.re=a.re}this.lm=this.type.Qb[0].speed;this.xg=this.tk();this.Tj=m;this.pg=0;this.Sj=m;this.cm=this.dp=
"";this.Ms=0;this.bm=-1;var b,c,d,e,f,g,h,a=0;for(b=this.type.Qb.length;a<b;a++){e=this.type.Qb[a];c=0;for(d=e.frames.length;c<d;c++)f=e.frames[c],f.R.hintLoad&&f.R.hintLoad(),0===f.width&&(f.width=f.R.width,f.height=f.R.height),f.bi&&(h=f.R,g=f.ho,g.left=f.Xh/h.width,g.top=f.Yh/h.height,g.right=(f.Xh+f.width)/h.width,g.bottom=(f.Yh+f.height)/h.height,0===f.Xh&&(0===f.Yh&&f.width===h.width&&f.height===h.height)&&(f.bi=q)),this.a.P&&(f.R.Re||(f.R.Re=this.a.P.Nk(f.R,q,this.a.ib,f.Yq)),f.hb=f.R.Re)}this.sg=
this.Jb.frames[this.T];this.km=this.sg.hb};nd.Xl=function(a){this.T=a?0:this.Jb.frames.length-1;this.Tj=q;this.dp=this.Jb.name;this.Rp=m;this.a.trigger(M.prototype.C.Tr,this);this.a.trigger(M.prototype.C.Sr,this);this.Rp=q;this.pg=0};nd.tk=function(){return(Date.now()-this.a.lo)/1E3};
nd.Gc=function(){this.cm.length&&this.Ts();0<=this.bm&&this.Us();var a=this.tk(),b=this.Jb,c=b.frames[this.T],d=c.duration/this.lm,e=this.a.fg;-1!==this.$k&&(e=this.$k);d/=0===e?1E-9:e;if(this.Tj&&a>=this.xg+d){this.Sj?this.T++:this.T--;this.xg+=d;this.T>=b.frames.length&&(b.Xq?(this.Sj=q,this.T=b.frames.length-2):b.loop?this.T=b.jl:(this.pg++,this.pg>=b.Tn?this.Xl(q):this.T=b.jl));0>this.T&&(b.Xq?(this.T=1,this.Sj=m,b.loop||(this.pg++,this.pg>=b.Tn&&this.Xl(m))):b.loop?this.T=b.jl:(this.pg++,this.pg>=
b.Tn?this.Xl(m):this.T=b.jl));0>this.T?this.T=0:this.T>=b.frames.length&&(this.T=b.frames.length-1);if(a>this.xg+b.frames[this.T].duration/this.lm/(0===e?1E-9:e))this.xg=a;a=b.frames[this.T];this.yi(c,a);this.a.Pa=m}};
nd.Ts=function(){var a=this.Jb.frames[this.T],b,c,d,e=p;b=0;for(c=this.type.Qb.length;b<c;b++)if(d=this.type.Qb[b],d.name.toLowerCase()===this.cm.toLowerCase()){e=d;break}this.cm="";e&&!(e.name.toLowerCase()===this.Jb.name.toLowerCase()&&this.Tj)&&(this.Jb=e,this.lm=e.speed,0>this.T&&(this.T=0),this.T>=this.Jb.frames.length&&(this.T=this.Jb.frames.length-1),1===this.Ms&&(this.T=0),this.Tj=m,this.xg=this.tk(),this.Sj=m,this.yi(a,this.Jb.frames[this.T]),this.a.Pa=m)};
nd.Us=function(){var a=this.Jb.frames[this.T],b=this.T;this.T=la(this.bm);0>this.T&&(this.T=0);this.T>=this.Jb.frames.length&&(this.T=this.Jb.frames.length-1);b!==this.T&&(this.yi(a,this.Jb.frames[this.T]),this.xg=this.tk(),this.a.Pa=m);this.bm=-1};
nd.yi=function(a,b){var c=a.width,d=a.height,e=b.width,f=b.height;c!=e&&(this.width*=e/c);d!=f&&(this.height*=f/d);this.qe=b.qe;this.re=b.re;this.Da.co(b.Mn);this.ha();this.sg=b;this.km=b.hb;c=0;for(d=this.Rb.length;c<d;c++)e=this.Rb[c],e.Tq&&e.Tq(a,b);this.a.trigger(M.prototype.C.yi,this)};
nd.Kd=function(a){a.globalAlpha=this.opacity;var b=this.sg,c=b.bi,d=b.R,e=this.x,f=this.y,g=this.width,h=this.height;if(0===this.v&&0<=g&&0<=h)e-=this.qe*g,f-=this.re*h,this.a.Ee&&(e=e+0.5|0,f=f+0.5|0),c?a.drawImage(d,b.Xh,b.Yh,b.width,b.height,e,f,g,h):a.drawImage(d,e,f,g,h);else{this.a.Ee&&(e=e+0.5|0,f=f+0.5|0);a.save();var i=0<g?1:-1,j=0<h?1:-1;a.translate(e,f);(1!==i||1!==j)&&a.scale(i,j);a.rotate(this.v*i*j);e=0-this.qe*ha(g);f=0-this.re*ha(h);c?a.drawImage(d,b.Xh,b.Yh,b.width,b.height,e,f,ha(g),
ha(h)):a.drawImage(d,e,f,ha(g),ha(h));a.restore()}};nd.Yc=function(a){a.gd(this.km);a.Vg(this.opacity);var b=this.sg,c=this.Ka;if(this.a.Ee){var d=(this.x+0.5|0)-this.x,e=(this.y+0.5|0)-this.y;b.bi?a.Ge(c.ob+d,c.pb+e,c.kc+d,c.lc+e,c.cc+d,c.ec+e,c.ac+d,c.bc+e,b.ho):a.hl(c.ob+d,c.pb+e,c.kc+d,c.lc+e,c.cc+d,c.ec+e,c.ac+d,c.bc+e)}else b.bi?a.Ge(c.ob,c.pb,c.kc,c.lc,c.cc,c.ec,c.ac,c.bc,b.ho):a.hl(c.ob,c.pb,c.kc,c.lc,c.cc,c.ec,c.ac,c.bc)};
nd.Ot=function(a){var b=this.sg,c,d;c=0;for(d=b.Lm.length;c<d;c++)if(a.toLowerCase()===b.Lm[c][0].toLowerCase())return c;return-1};nd.pe=function(a,b){var c=this.sg,d=c.Lm,e;e=H(a)?this.Ot(a):a-1;e=la(e);if(0>e||e>=d.length)return b?this.x:this.y;var f=(d[e][1]-c.qe)*this.width,d=d[e][2],d=(d-c.re)*this.height,c=Math.cos(this.v);e=Math.sin(this.v);var g=f*c-d*e,d=d*c+f*e,f=g+this.x,d=d+this.y;return b?f:d};
id.prototype.Mo=function(a){if(!a)return q;var b=this.a,c=b.Hp(),d=c.type;if(!c.Ma.Qi){c.Ma.Qi=[];var e=c.Ma.Qi;b.Yo(function(a){var b,c=0,d,f;b=0;for(d=e.length;b<d;b++)f=e[b],f[0]!==a&&f[1]!==a&&(e[c]=e[b],c++);e.length=c})}var f=d.Na(),g=a.Na(),f=f.Ld(),g=g.Ld(),h,i,j,k,n,r,s,t,u=b.zc().yc;h=0;for(i=f.length;h<i;h++){j=f[h];k=0;for(n=g.length;k<n;k++)if(r=g[k],b.no(j,r)||b.Ns(j,r)){a:{s=c.Ma.Qi;var w=t=l,x=l;t=0;for(w=s.length;t<w;t++)if(x=s[t],x[0]===j&&x[1]===r||x[0]===r&&x[1]===j){s=m;break a}s=
q}s||(c.Ma.Qi.push([j,r]),b.xj(u.yb),s=d.Na(),t=a.Na(),s.fb=q,t.fb=q,d===a?(s.l.length=2,s.l[0]=j,s.l[1]=r):(s.l.length=1,t.l.length=1,s.l[0]=j,t.l[0]=r),u.Un(),b.Yf(u.yb))}else{s=c.Ma.Qi;t=j;for(var w=l,x=0,C=l,B=l,w=0,C=s.length;w<C;w++)B=s[w],B[0]===t&&B[1]===r||B[0]===r&&B[1]===t||(s[x]=s[w],x++);s.length=x}}return q};var od=new db,pd=q;
ld.finish=function(a){if(pd){if(a){var b=this.a.zc().yc.Yd,a=p.Na(),c=od.hg(),d,e;if(a.fb){a.fb=q;a.l.length=c.length;d=0;for(e=c.length;d<e;d++)a.l[d]=c[d];if(b){d=a.rb.length=0;for(e=p.l.length;d<e;d++)b=p.l[d],od.contains(b)||a.rb.push(b)}}else{var f=a.l.length;a.l.length=f+c.length;d=0;for(e=c.length;d<e;d++)a.l[f+d]=c[d],b&&qa(a.rb,c[d])}p.Gi()}od.clear();pd=q}};id.prototype.Sr=function(a){return this.dp.toLowerCase()===a.toLowerCase()};id.prototype.Tr=D(m);id.prototype.yi=D(m);kd.C=new id;
jd.prototype.Qj=function(a){a=ha(this.width)*(0===a?-1:1);this.width!==a&&(this.width=a,this.ha())};kd.L=new jd;kd.Fa=new (v());function qd(a){this.a=a}function rd(){}function sd(){}var td=qd.prototype;td.X=function(){td.L.Ql=function(a){this.width!==a&&(this.width=a,this.di=m,this.ha())}};td.ta=function(a){this.Mb=a;this.a=a.a};var ud=td.ta.prototype;ud.X=v();ud.cl=function(){if(!this.Sa){var a,b,c;a=0;for(b=this.l.length;a<b;a++)c=this.l[a],c.pf=p,c.Uh=p,c.Xd=p}};
td.la=function(a){this.type=a;this.a=a.a;this.Dg=[];this.di=m};var vd=td.la.prototype;
vd.X=function(){this.text=this.G[0];this.visible=0===this.G[1];this.font=this.G[2];this.color=this.G[3];this.Np=this.G[4];this.Ir=this.G[5];this.Uv=0===this.G[7];this.sq=this.Ch=this.width;this.Bh=this.height;this.yu=this.G[8];this.Fp=this.xp="";var a=this.font.split(" ");this.vx=this.wx=this.On=0;var b;for(b=0;b<a.length;b++)if("pt"===a[b].substr(a[b].length-2,2)){this.On=parseInt(a[b].substr(0,a[b].length-2));this.sv=Math.ceil(96*(this.On/72))+4;this.xp=a[b+1];0<b&&(this.Fp=a[b-1]);break}this.Xd=
this.Uh=this.pf=p;this.Qq=q;this.Ug=new bb(0,0,1,1)};vd.Rg=function(){this.pf=this.Uh=p;this.a.P&&this.Xd&&this.a.P.deleteTexture(this.Xd);this.Xd=p};vd.xx=function(){this.font=this.Fp+" "+this.On.toString()+"pt "+this.xp;this.di=m;this.a.Pa=m};
vd.Kd=function(a,b){a.font=this.font;a.textBaseline="top";a.fillStyle=this.color;a.globalAlpha=b?1:this.opacity;var c=1;b&&(c=this.F.Jc(),a.save(),a.scale(c,c));if(this.di||this.width!==this.sq)this.type.Mb.vs(this.text,this.Dg,a,this.width,this.Uv),this.di=q,this.sq=this.width;this.gb();var c=b?0:this.Ka.ob,d=b?0:this.Ka.pb;this.a.Ee&&(c=c+0.5|0,d=d+0.5|0);0!==this.v&&!b&&(a.save(),a.translate(c,d),a.rotate(this.v),d=c=0);var e=d+this.height,f=this.sv,f=f+this.yu*this.a.devicePixelRatio,g,h;1===
this.Ir?d+=Math.max(this.height/2-this.Dg.length*f/2,0):2===this.Ir&&(d+=Math.max(this.height-this.Dg.length*f-2,0));for(h=0;h<this.Dg.length&&!(g=c,1===this.Np?g=c+(this.width-this.Dg[h].width)/2:2===this.Np&&(g=c+(this.width-this.Dg[h].width)),a.fillText(this.Dg[h].text,g,d),d+=f,d>=e-f);h++);(0!==this.v||b)&&a.restore()};
vd.Yc=function(a){if(!(1>this.width||1>this.height)){var b=this.di||this.Qq;this.Qq=q;var c=this.F.Jc(),d=this.F.Ze(),e=this.Ug,f=c*this.width,g=c*this.height,h=Math.ceil(f),i=Math.ceil(g),j=this.a.width/2,k=this.a.height/2;this.Uh||(this.pf=document.createElement("canvas"),this.pf.width=h,this.pf.height=i,this.Ch=h,this.Bh=i,b=m,this.Uh=this.pf.getContext("2d"));if(h!==this.Ch||i!==this.Bh)this.pf.width=h,this.pf.height=i,this.Xd&&(a.deleteTexture(this.Xd),this.Xd=p),b=m;b&&(this.Uh.clearRect(0,
0,h,i),this.Kd(this.Uh,m),this.Xd||(this.Xd=a.Te(h,i,this.a.ib,this.a.th)),a.Sv(this.pf,this.Xd,this.a.th));this.Ch=h;this.Bh=i;a.gd(this.Xd);a.Vg(this.opacity);a.Ie();a.translate(-j,-k);a.Le();var n=this.Ka,b=this.F.Ja(n.ob,n.pb,m),j=this.F.Ja(n.ob,n.pb,q),k=this.F.Ja(n.kc,n.lc,m),r=this.F.Ja(n.kc,n.lc,q),s=this.F.Ja(n.cc,n.ec,m),t=this.F.Ja(n.cc,n.ec,q),u=this.F.Ja(n.ac,n.bc,m),n=this.F.Ja(n.ac,n.bc,q);if(this.a.Ee||0===this.v&&0===d)var w=(b+0.5|0)-b,x=(j+0.5|0)-j,b=b+w,j=j+x,k=k+w,r=r+x,s=s+w,
t=t+x,u=u+w,n=n+x;0===this.v&&0===d?(k=b+h,r=j,s=k,t=j+i,u=b,n=t,e.right=1,e.bottom=1):(e.right=f/h,e.bottom=g/i);a.Ge(b,j,k,r,s,t,u,n,e);a.Ie();a.scale(c,c);a.Xn(-this.F.Ze());a.translate((this.F.Ed+this.F.kd)/-2,(this.F.Fd+this.F.jd)/-2);a.Le()}};var wd=[];
td.us=function(a){wd.length=0;for(var b="",c,d=0;d<a.length;)if(c=a.charAt(d),"\n"===c)b.length&&(wd.push(b),b=""),wd.push("\n"),++d;else if(" "===c||"\t"===c||"-"===c){do b+=a.charAt(d),d++;while(d<a.length&&(" "===a.charAt(d)||"\t"===a.charAt(d)));wd.push(b);b=""}else d<a.length&&(b+=c,d++);b.length&&wd.push(b)};
td.vs=function(a,b,c,d,e){if(!a||!a.length)b.length=0;else if(2>=d)b.length=0;else{if(100>=a.length&&-1===a.indexOf("\n")){var f=0,f=c.measureText(a).width;if(f<=d){b.length?b.length=1:b.push({});b[0].text=a;b[0].width=f;return}}this.ws(a,b,c,d,e)}};
td.ws=function(a,b,c,d,e){e&&(this.us(a),a=wd);var f="",g,h,i,j=0;for(i=0;i<a.length;i++)"\n"===a[i]?(j>=b.length&&b.push({}),h=b[j],h.text=f,h.width=0,h.width=c.measureText(f).width,j++,f=""):(g=f,f+=a[i],h=c.measureText(f).width,h>=d&&(j>=b.length&&b.push({}),h=b[j],h.text=g,h.width=0,h.width=c.measureText(g).width,j++,f=a[i],!e&&" "===f&&(f="")));f.length&&(j>=b.length&&b.push({}),h=b[j],h.text=f,h.width=0,h.width=c.measureText(f).width,j++);b.length=j};
rd.prototype.Nr=function(a,b){return b?this.text==a:this.text.toLowerCase()==a.toLowerCase()};td.C=new rd;sd.prototype.Pl=function(a){fa(a)&&1E9>a&&(a=Math.round(1E10*a)/1E10);a=a.toString();this.text!==a&&(this.text=a,this.di=m,this.a.Pa=m)};td.L=new sd;td.Fa=new (v());function xd(a){this.a=a}var yd=xd.prototype;yd.ta=function(a){this.Mb=a;this.a=a.a};var zd=yd.ta.prototype;
zd.X=function(){this.Sa||(this.R=new Image,this.R.src=this.po,this.R.qp=this.qo,this.a.wf.push(this.R),this.hb=this.pattern=p)};zd.cl=function(){this.Sa||(this.hb=p)};zd.Hn=function(){if(!this.Sa&&this.l.length){this.hb||(this.hb=this.a.P.Nk(this.R,m,this.a.ib,this.ro));var a,b;a=0;for(b=this.l.length;a<b;a++)this.l[a].hb=this.hb}};zd.vo=function(){!this.Sa&&!this.l.length&&(this.a.P?this.hb&&(this.a.P.deleteTexture(this.hb),this.hb=p):this.R.hintUnload&&this.R.hintUnload())};
yd.la=function(a){this.type=a;this.a=a.a};var Ad=yd.la.prototype;Ad.X=function(){this.visible=0===this.G[0];this.Ug=new bb(0,0,0,0);this.hu=q;this.R=this.type.R;this.a.P?(this.type.hb||(this.type.hb=this.a.P.Nk(this.type.R,m,this.a.ib,this.type.ro)),this.hb=this.type.hb):(this.R.hintLoad&&this.R.hintLoad(),this.type.pattern||(this.type.pattern=this.a.La.createPattern(this.type.R,"repeat")),this.pattern=this.type.pattern)};
Ad.Rg=function(){this.a.P&&(this.hu&&this.hb)&&(this.a.P.deleteTexture(this.hb),this.hb=p)};Ad.Kd=function(a){a.globalAlpha=this.opacity;a.save();a.fillStyle=this.pattern;var b=this.x,c=this.y;this.a.Ee&&(b=b+0.5|0,c=c+0.5|0);var d=-(this.qe*this.width),e=-(this.re*this.height),f=d%this.R.width,g=e%this.R.height;0>f&&(f+=this.R.width);0>g&&(g+=this.R.height);a.translate(b,c);a.rotate(this.v);a.translate(f,g);a.fillRect(d-f,e-g,this.width,this.height);a.restore()};
Ad.Yc=function(a){a.gd(this.hb);a.Vg(this.opacity);var b=this.Ug;b.right=this.width/this.R.width;b.bottom=this.height/this.R.height;var c=this.Ka;if(this.a.Ee){var d=(this.x+0.5|0)-this.x,e=(this.y+0.5|0)-this.y;a.Ge(c.ob+d,c.pb+e,c.kc+d,c.lc+e,c.cc+d,c.ec+e,c.ac+d,c.bc+e,b)}else a.Ge(c.ob,c.pb,c.kc,c.lc,c.cc,c.ec,c.ac,c.bc,b)};yd.C=new (v());yd.L=new (v());yd.Fa=new (v());function Bd(a){this.a=a}function Cd(a,b){return b?4<=a?-1:a+Dd:16<=a?-1:a}
function Ed(a){Fd[a.gamepad.index]=a.gamepad;Gd.trigger(Bd.prototype.C.$r,Hd)}function Id(a){Gd.trigger(Bd.prototype.C.as,Hd);Fd[a.gamepad.index]=p}function Jd(){}var Kd=Bd.prototype;Kd.ta=function(a){this.Mb=a;this.a=a.a};Kd.ta.prototype.X=v();var Gd=p,Hd=p,Fd=Array(16),Ld="",Md="",Dd=16,Nd=p,Od={windows:{}};Od.windows.firefox={};var Pd=[0,1,2,3,4,5,8,9,10,11],Qd=[0,1,[7,6],2,3,[14,15],[12,13]];
Od.windows.firefox.xbox360=function(a,b){return b?a>=Qd.length?-1:fa(Qd[a])?Qd[a]+Dd:Qd[a]:a>=Pd.length?-1:Pd[a]};var Rd=[2,0,1,3,4,6,5,7,8,9],Sd=[0,1,2,3,[14,15],[12,13]];Od.windows.firefox.logitechdualaction=function(a,b){return b?a>=Sd.length?-1:fa(Sd[a])?Sd[a]+Dd:Sd[a]:a>=Rd.length?-1:Rd[a]};Kd.la=function(a){this.type=a;Gd=this.a=a.a;Hd=this};var Td=Kd.la.prototype;
Td.X=function(){this.Uw=this.G[0];this.xu=0;var a=navigator.userAgent;/windows/i.test(a)?Ld="windows":/mac/i.test(a)&&(Ld="mac");Nd=Od[Ld];/(chrome|chromium)/i.test(a)?Md="chrome":/firefox/i.test(a)&&(Md="firefox");Nd&&(Nd=Nd[Md]);window.addEventListener("webkitgamepadconnected",Ed,q);window.addEventListener("webkitgamepaddisconnected",Id,q);window.addEventListener("MozGamepadConnected",Ed,q);window.addEventListener("MozGamepadDisconnected",Id,q);window.addEventListener("gamepadconnected",Ed,q);window.addEventListener("gamepaddisconnected",
Id,q);this.a.sl(this);this.Wo=[]};
Td.Gc=function(){this.Wo.length=0;var a=p;if(a=navigator.webkitGetGamepads?navigator.webkitGetGamepads():navigator.mozGetGamepads?navigator.mozGetGamepads():navigator.getGamepads?navigator.getGamepads():navigator.gamepads||navigator.webkitGamepads||navigator.MozGamepads||Fd){var b,c,d,e,f,g,h;b=0;for(c=a.length;b<c;b++){var i=a[b];if(i){if(i.Qe)for(d=0;20>d;d++)i.am[d]=i.Qe[d];else{i.Qe=Array(20);i.am=Array(20);for(d=0;20>d;d++)i.am[d]=0}Nd?(d="",e=i.id.toLowerCase(),-1<e.indexOf("xbox 360")?d="xbox360":
-1<e.indexOf("logitech dual action")&&(d="logitechdualaction"),f=Nd[d]||Cd):f=Cd;d=0;for(e=i.buttons.length;d<e;d++)h=i.buttons[d],g=f(d,q,h),0<=g&&20>g&&(i.Qe[g]=100*h,50<=i.Qe[g]&&50>i.am[g]&&(this.xu=g));d=0;for(e=i.axes.length;d<e;d++)h=i.axes[d],g=f(d,m,h),fa(g)?0<=g&&20>g&&(i.Qe[g]=100*h):(i.Qe[g[0]]=0,i.Qe[g[1]]=0,0>=h?i.Qe[g[0]]=Math.abs(100*h):i.Qe[g[1]]=Math.abs(100*h));this.Wo.push(i)}}}};Jd.prototype.$r=D(m);Jd.prototype.as=D(m);Kd.C=new Jd;Kd.L=new (v());Kd.Fa=new (v());
function Ud(a){this.a=a}var Vd=Ud.prototype;Vd.ta=function(a,b){this.O=a;this.Wh=b;this.a=a.a};Vd.ta.prototype.X=v();Vd.la=function(a,b){this.type=a;this.O=a.O;this.k=b;this.a=a.a};var Wd=Vd.la.prototype;Wd.X=function(){this.bp=this.G[0];this.cp=this.G[1];this.Ds=this.G[2];this.Cs=this.G[3];this.k.gb();this.Vv=this.k.ea.left;this.Yv=this.k.ea.top;this.Wv=this.a.Uc-this.k.ea.left;this.Xv=this.a.Tc-this.k.ea.top;this.tv=this.a.Uc-this.k.ea.right;this.Is=this.a.Tc-this.k.ea.bottom;this.enabled=m};
Wd.Gc=function(){if(this.enabled){var a,b=this.k.F,c=this.k,d=this.k.ea;0===this.bp?(c.gb(),a=b.Ed+this.Vv-d.left,0!==a&&(c.x+=a,c.ha())):1===this.bp&&(c.gb(),a=b.kd-this.Wv-d.left,0!==a&&(c.x+=a,c.ha()));0===this.cp?(c.gb(),a=b.Fd+this.Yv-d.top,0!==a&&(c.y+=a,c.ha())):1===this.cp&&(c.gb(),a=b.jd-this.Xv-d.top,0!==a&&(c.y+=a,c.ha()));1===this.Ds&&(c.gb(),a=b.kd-this.tv-d.right,0!==a&&(c.width+=a,0>c.width&&(c.width=0),c.ha()));1===this.Cs&&(c.gb(),a=b.jd-this.Is-d.bottom,0!==a&&(c.height+=a,0>c.height&&
(c.height=0),c.ha()))}};Vd.C=new (v());Vd.L=new (v());Vd.Fa=new (v());function Xd(a){this.a=a}var Yd=Xd.prototype;Yd.ta=function(a,b){this.O=a;this.Wh=b;this.a=a.a};Yd.ta.prototype.X=v();Yd.la=function(a,b){this.type=a;this.O=a.O;this.k=b;this.a=a.a;this.qr=this.pr=this.or=this.rr=this.ju=this.Vn=this.Ym=this.rm=this.wo=q;this.qq=this.pq=this.oq=this.rq=-1;this.Ra=this.Qa=0;this.enabled=m};var Zd=Yd.la.prototype;
Zd.X=function(){this.Cn=this.G[0];this.Ef=this.G[1];this.If=this.G[2];this.qm=this.G[3];this.Wl=this.G[4];if((this.Rs=1===this.G[5])&&!this.a.pc)jQuery(document).keydown(function(a){return function(b){a.Fn(b)}}(this)),jQuery(document).keyup(function(a){return function(b){a.Gn(b)}}(this))};
Zd.Fn=function(a){var b=this.a.eg;switch(a.which){case 37:a.preventDefault();this.pq<b&&(this.Ym=m);break;case 38:a.preventDefault();this.rq<b&&(this.wo=m);break;case 39:a.preventDefault();this.qq<b&&(this.Vn=m);break;case 40:a.preventDefault(),this.oq<b&&(this.rm=m)}};
Zd.Gn=function(a){var b=this.a.eg;switch(a.which){case 37:a.preventDefault();this.Ym=q;this.pq=b;break;case 38:a.preventDefault();this.wo=q;this.rq=b;break;case 39:a.preventDefault();this.Vn=q;this.qq=b;break;case 40:a.preventDefault(),this.rm=q,this.oq=b}};
Zd.Gc=function(){var a=this.a.qk(this.k),b=this.Ym||this.pr,c=this.Vn||this.qr,d=this.wo||this.rr,e=this.rm||this.or;this.or=this.rr=this.qr=this.pr=q;if(this.enabled){var f=this.a.Dj(this.k);if(f&&(this.a.yj(this.k,f),!this.a.rv(this.k)))return;this.ju&&(e=d=c=b=q);0===this.qm?c=b=q:1===this.qm&&(e=d=q);if(2===this.qm&&(d||e))c=b=q;b==c&&(0>this.Qa?(this.Qa+=this.If*a,0<this.Qa&&(this.Qa=0)):0<this.Qa&&(this.Qa-=this.If*a,0>this.Qa&&(this.Qa=0)));d==e&&(0>this.Ra?(this.Ra+=this.If*a,0<this.Ra&&(this.Ra=
0)):0<this.Ra&&(this.Ra-=this.If*a,0>this.Ra&&(this.Ra=0)));b&&!c&&(this.Qa=0<this.Qa?this.Qa-(this.Ef+this.If)*a:this.Qa-this.Ef*a);c&&!b&&(this.Qa=0>this.Qa?this.Qa+(this.Ef+this.If)*a:this.Qa+this.Ef*a);d&&!e&&(this.Ra=0<this.Ra?this.Ra-(this.Ef+this.If)*a:this.Ra-this.Ef*a);e&&!d&&(this.Ra=0>this.Ra?this.Ra+(this.Ef+this.If)*a:this.Ra+this.Ef*a);if(0!==this.Qa||0!==this.Ra){Math.sqrt(this.Qa*this.Qa+this.Ra*this.Ra)>this.Cn&&(f=Math.atan2(this.Ra,this.Qa),this.Qa=this.Cn*Math.cos(f),this.Ra=this.Cn*
Math.sin(f));c=this.k.x;d=this.k.y;b=this.k.v;this.k.x+=this.Qa*a;this.k.ha();if(f=this.a.Dj(this.k))this.k.x=c,this.Qa=0,this.k.ha(),this.a.yj(this.k,f);this.k.y+=this.Ra*a;this.k.ha();if(f=this.a.Dj(this.k))this.k.y=d,this.Ra=0,this.k.ha(),this.a.yj(this.k,f);a=Ka(this.Qa);f=Ka(this.Ra);if(0!==a||0!==f)1===this.Wl?this.k.v=wa(90*Math.round(sa(Math.atan2(f,a))/90)):2===this.Wl?this.k.v=wa(45*Math.round(sa(Math.atan2(f,a))/45)):3===this.Wl&&(this.k.v=Math.atan2(f,a));this.k.ha();if(this.k.v!=b&&(f=
this.a.Dj(this.k)))this.k.v=b,this.k.ha(),this.a.yj(this.k,f)}}};Yd.C=new (v());Yd.L=new (v());Yd.Fa=new (v());function N(a,b){for(var c in b.prototype)b.prototype.hasOwnProperty(c)&&(a.prototype[c]=b.prototype[c])}var $d=2/180*Math.PI,ae=8/180*Math.PI,be=0.5*Math.PI,ce=be*be,de=2/180*Math.PI,ee=Number.MIN_VALUE*Number.MIN_VALUE;function fe(a,b){return a.x*b.x+a.y*b.y}function ge(a,b){return a.x*b.y-a.y*b.x}function he(a){return O(1*a.y,-1*a.x)}
function P(a,b){return O(a.c.x*b.x+a.d.x*b.y,a.c.y*b.x+a.d.y*b.y)}function ie(a,b){return O(fe(b,a.c),fe(b,a.d))}function Q(a,b){var c=P(a.e,b);c.x+=a.position.x;c.y+=a.position.y;return c}function R(a,b){return O(a.x-b.x,a.y-b.y)}function S(a,b,c){return a<b?b:a>c?c:a}function je(){this.c=O(0,0);this.d=O(0,0);this.Pj()}function ke(a){var b=new je;b.p(a);return b}F=je.prototype;F.p=function(a){var b=Math.cos(a),a=Math.sin(a);this.c.p(b,a);this.d.p(-a,b)};F.Gb=function(){var a=new je;a.hh(this);return a};
F.hh=function(a){this.c.m(a.c);this.d.m(a.d)};F.Dl=function(a){this.c.Af(a.c);this.d.Af(a.d)};F.Pj=function(){this.c.p(1,0);this.d.p(0,1)};F.S=function(){this.c.p(0,0);this.d.p(0,0)};F.Hd=function(){return Math.atan2(this.c.y,this.c.x)};function le(a,b){var c=a.c.x*a.d.y-a.d.x*a.c.y;0!==c&&(c=1/c);b.c.x=c*a.d.y;b.d.x=-c*a.d.x;b.c.y=-c*a.c.y;b.d.y=c*a.c.x}F.lg=function(a,b,c){var d=this.c.x*this.d.y-this.d.x*this.c.y;0!==d&&(d=1/d);a.x=d*(this.d.y*b-this.d.x*c);a.y=d*(this.c.x*c-this.c.y*b);return a};
function me(a,b,c){this.c=new ne(0,0,0);this.d=new ne(0,0,0);this.aa=new ne(0,0,0);a&&this.c.m(a);b&&this.d.m(b);c&&this.aa.m(c)}F=me.prototype;F.Gb=function(){return new me(this.c,this.d,this.aa)};F.hh=function(a){this.c.m(a.c);this.d.m(a.d);this.aa.m(a.aa)};F.Dl=function(a){this.c.x+=a.c.x;this.c.y+=a.c.y;this.c.o+=a.c.o;this.d.x+=a.d.x;this.d.y+=a.d.y;this.d.o+=a.d.o;this.aa.x+=a.aa.x;this.aa.y+=a.aa.y;this.aa.o+=a.aa.o};F.Pj=function(){this.c.p(1,0,0);this.d.p(0,1,0);this.aa.p(0,0,1)};
F.S=function(){this.c.p(0,0,0);this.d.p(0,0,0);this.aa.p(0,0,0)};function oe(a,b,c,d){var e=a.c.x,f=a.d.x,g=a.c.y,a=a.d.y,h=e*a-f*g;0!=h&&(h=1/h);b.x=h*(a*c-f*d);b.y=h*(e*d-g*c);return b}function pe(a,b,c,d,e){var f=a.c.x,g=a.c.y,h=a.c.o,i=a.d.x,j=a.d.y,k=a.d.o,n=a.aa.x,r=a.aa.y,a=a.aa.o,s=f*(j*a-k*r)+g*(k*n-i*a)+h*(i*r-j*n);0!=s&&(s=1/s);b.x=s*(c*(j*a-k*r)+d*(k*n-i*a)+e*(i*r-j*n));b.y=s*(f*(d*a-e*r)+g*(e*n-c*a)+h*(c*r-d*n));b.o=s*(f*(j*e-k*d)+g*(k*c-i*e)+h*(i*d-j*c));return b}
function qe(){this.r=O(0,0);this.Ub=O(0,0);this.g=O(0,0)}qe.prototype.p=function(a){this.r.m(a.r);this.Ub.m(a.Ub);this.g.m(a.g);this.nd=a.nd;this.q=a.q;this.uc=a.uc};qe.prototype.Gb=function(){var a=new qe;a.r.m(this.r);a.Ub.m(this.Ub);a.g.m(this.g);a.nd=this.nd;a.q=this.q;a.uc=this.uc;return a};
qe.prototype.Nc=function(a,b){b===l&&(b=0);a.position.x=(1-b)*this.Ub.x+b*this.g.x;a.position.y=(1-b)*this.Ub.y+b*this.g.y;a.e.p((1-b)*this.nd+b*this.q);var c=a.e;a.position.x-=c.c.x*this.r.x+c.d.x*this.r.y;a.position.y-=c.c.y*this.r.x+c.d.y*this.r.y};qe.prototype.Bf=function(a){a===l&&(a=0);if(this.uc<a&&1-this.uc>Number.MIN_VALUE){var b=(a-this.uc)/(1-this.uc);this.Ub.x=(1-b)*this.Ub.x+b*this.g.x;this.Ub.y=(1-b)*this.Ub.y+b*this.g.y;this.nd=(1-b)*this.nd+b*this.q;this.uc=a}};
function re(a,b){this.position=O(0,0);this.e=new je;a&&this.position.m(a);b&&this.e.hh(b)}re.prototype.Hb=function(a,b){this.position.m(a);this.e.hh(b)};re.prototype.Pj=function(){this.position.S();this.e.Pj()};re.prototype.p=function(a){this.position.m(a.position);this.e.hh(a.e)};re.prototype.Hd=function(){return Math.atan2(this.e.c.y,this.e.c.x)};function se(a,b){this.x=a;this.y=b}var te=[];function O(a,b){if(0<te.length){var c=te.pop();c.p(a,b);return c}return new se(a,b)}
function T(a){te.push(a)}F=se.prototype;F.S=function(){this.y=this.x=0};F.p=function(a,b){this.x=a;this.y=b};F.m=function(a){this.x=a.x;this.y=a.y};F.Cf=function(){return O(-this.x,-this.y)};F.Ko=function(){this.x=-this.x;this.y=-this.y};F.Gb=function(){return O(this.x,this.y)};F.Af=function(a){this.x+=a.x;this.y+=a.y};F.Uo=function(a){this.x-=a.x;this.y-=a.y};F.Hc=function(a){this.x*=a;this.y*=a};function ue(a){return Math.sqrt(ve(a))}function ve(a){return a.x*a.x+a.y*a.y}
function we(a){var b=ue(a);if(b<Number.MIN_VALUE)return 0;var c=1/b;a.x*=c;a.y*=c;return b}function ne(a,b,c){this.x=a;this.y=b;this.o=c}F=ne.prototype;F.S=function(){this.o=this.y=this.x=0};F.p=function(a,b,c){this.x=a;this.y=b;this.o=c};F.m=function(a){this.x=a.x;this.y=a.y;this.o=a.o};F.Cf=function(){return new ne(-this.x,-this.y,-this.o)};F.Ko=function(){this.x=-this.x;this.y=-this.y;this.o=-this.o};F.Gb=function(){return new ne(this.x,this.y,this.o)};
F.Af=function(a){this.x+=a.x;this.y+=a.y;this.o+=a.o};F.Uo=function(a){this.x-=a.x;this.y-=a.y;this.o-=a.o};F.Hc=function(a){this.x*=a;this.y*=a;this.o*=a};function xe(){this.ra=0.005}F=xe.prototype;F.jg=v();F.Gb=v();F.p=function(a){this.ra=a.ra};F.dh=v();F.mi=v();F.Mj=v();F.Nl=v();function ye(a){this.ra=0.005;this.ra=a;this.Qh=a*a;this.Aa=O(0,0)}N(ye,xe);F=ye.prototype;F.jg=D("b2CircleShape");F.Gb=function(){var a=new ye(this.ra);a.p(this);return a};
F.p=function(a){xe.prototype.p.call(this,a);a instanceof ye&&this.Aa.m(a.Aa)};F.dh=function(a,b){var c=b.e,d=b.position.x+(c.c.x*this.Aa.x+c.d.x*this.Aa.y),c=b.position.y+(c.c.y*this.Aa.x+c.d.y*this.Aa.y);a.na.p(d-this.ra,c-this.ra);a.qa.p(d+this.ra,c+this.ra)};F.mi=function(a,b){a.De=b*Math.PI*this.Qh;a.Se.m(this.Aa);a.fh=a.De*(0.5*this.Qh+(this.Aa.x*this.Aa.x+this.Aa.y*this.Aa.y))};
F.Mj=function(a,b,c,d){var c=Q(c,this.Aa),e=-(fe(a,c)-b);if(e<-this.ra+Number.MIN_VALUE)return 0;if(e>this.ra)return d.m(c),Math.PI*this.Qh;b=e*e;e=this.Qh*(Math.asin(e/this.ra)+Math.PI/2)+e*Math.sqrt(this.Qh-b);b=-2/3*Math.pow(this.Qh-b,1.5)/e;d.x=c.x+a.x*b;d.y=c.y+a.y*b;return e};F.Nl=function(a){a.s=[this.Aa];a.V=1;a.ra=this.ra};
function ze(a,b){this.ra=0.005;this.kx=this.mx=p;this.W=a;this.ja=b;this.Hg=O(this.ja.x-this.W.x,this.ja.y-this.W.y);this.rn=we(this.Hg);this.Z=O(this.Hg.y,-this.Hg.x);this.cx=O(-0.04*(this.Z.x-this.Hg.x)+this.W.x,-0.04*(this.Z.y-this.Hg.y)+this.W.y);this.dx=O(-0.04*(this.Z.x+this.Hg.x)+this.ja.x,-0.04*(this.Z.y+this.Hg.y)+this.ja.y);this.hx=this.Z;this.ix=O(-this.Z.x,-this.Z.y);this.gx=this.ex=q}N(ze,xe);ze.prototype.jg=D("b2EdgeShape");
ze.prototype.dh=function(a,b){var c=b.e,d=b.position.x+(c.c.x*this.W.x+c.d.x*this.W.y),e=b.position.y+(c.c.y*this.W.x+c.d.y*this.W.y),f=b.position.x+(c.c.x*this.ja.x+c.d.x*this.ja.y),c=b.position.y+(c.c.y*this.ja.x+c.d.y*this.ja.y);d<f?(a.na.x=d,a.qa.x=f):(a.na.x=f,a.qa.x=d);e<c?(a.na.y=e,a.qa.y=c):(a.na.y=c,a.qa.y=e)};ze.prototype.mi=function(a){a.De=0;a.Se.m(this.W);a.fh=0};
ze.prototype.Mj=function(a,b,c,d){b===l&&(b=0);var e=O(a.x*b,a.y*b),f=Q(c,this.W),c=Q(c,this.ja),g=fe(a,f)-b,a=fe(a,c)-b;if(0<g){if(0<a)return 0;f.x=-a/(g-a)*f.x+g/(g-a)*c.x;f.y=-a/(g-a)*f.y+g/(g-a)*c.y}else 0<a&&(c.x=-a/(g-a)*f.x+g/(g-a)*c.x,c.y=-a/(g-a)*f.y+g/(g-a)*c.y);d.x=(e.x+f.x+c.x)/3;d.y=(e.y+f.y+c.y)/3;return 0.5*((f.x-e.x)*(c.y-e.y)-(f.y-e.y)*(c.x-e.x))};function Ae(){this.De=0;this.Se=O(0,0);this.fh=0}function Be(){this.ra=0.005;this.ud=O(0,0);this.s=[];this.Ha=[]}N(Be,xe);F=Be.prototype;
F.jg=D("b2PolygonShape");F.Gb=function(){var a=new Be;a.p(this);return a};F.p=function(a){xe.prototype.p.call(this,a);if(a instanceof Be){this.ud.m(a.ud);this.wa=a.wa;Ce(this,this.wa);for(var b=0;b<this.wa;b++)this.s[b].m(a.s[b]),this.Ha[b].m(a.Ha[b])}};function De(a,b,c){a.wa=4;Ce(a,4);a.s[0].p(-b,-c);a.s[1].p(b,-c);a.s[2].p(b,c);a.s[3].p(-b,c);a.Ha[0].p(0,-1);a.Ha[1].p(1,0);a.Ha[2].p(0,1);a.Ha[3].p(-1,0);a.ud.S()}
F.dh=function(a,b){for(var c=b.e,d=this.s[0],e=b.position.x+(c.c.x*d.x+c.d.x*d.y),f=b.position.y+(c.c.y*d.x+c.d.y*d.y),g=e,h=f,i=1;i<this.wa;++i)var d=this.s[i],j=b.position.x+(c.c.x*d.x+c.d.x*d.y),d=b.position.y+(c.c.y*d.x+c.d.y*d.y),e=e<j?e:j,f=f<d?f:d,g=g>j?g:j,h=h>d?h:d;a.na.x=e-this.ra;a.na.y=f-this.ra;a.qa.x=g+this.ra;a.qa.y=h+this.ra};
F.mi=function(a,b){if(2==this.wa)a.Se.x=0.5*(this.s[0].x+this.s[1].x),a.Se.y=0.5*(this.s[0].y+this.s[1].y),a.De=0,a.fh=0;else{for(var c=0,d=0,e=0,f=0,g=1/3,h=0;h<this.wa;++h)var i=this.s[h],j=h+1<this.wa?this.s[h+1]:this.s[0],k=i.x-0,n=i.y-0,r=j.x-0,s=j.y-0,t=k*s-n*r,u=0.5*t,e=e+u,c=c+u*g*(0+i.x+j.x),d=d+u*g*(0+i.y+j.y),i=k,f=f+t*(g*(0.25*(i*i+r*i+r*r)+(0*i+0*r))+0+(g*(0.25*(n*n+s*n+s*s)+(0*n+0*s))+0));a.De=b*e;a.Se.p(c*(1/e),d*(1/e));a.fh=b*f}};
F.Mj=function(a,b,c,d){for(var e=ie(c.e,a),f=b-fe(a,c.position),g=[],h=0,i=-1,b=-1,j=q,a=a=0;a<this.wa;++a){g[a]=fe(e,this.s[a])-f;var k=g[a]<-Number.MIN_VALUE;0<a&&(k?j||(i=a-1,h++):j&&(b=a-1,h++));j=k}switch(h){case 0:return j?(a=new Ae,this.mi(a,1),d.m(Q(c,a.Se)),a.De):0;case 1:-1==i?i=this.wa-1:b=this.wa-1}a=(i+1)%this.wa;e=(b+1)%this.wa;f=(0-g[i])/(g[a]-g[i]);g=(0-g[b])/(g[e]-g[b]);i=O(this.s[i].x*(1-f)+this.s[a].x*f,this.s[i].y*(1-f)+this.s[a].y*f);b=O(this.s[b].x*(1-g)+this.s[e].x*g,this.s[b].y*
(1-g)+this.s[e].y*g);g=0;f=O(0,0);for(h=this.s[a];a!=e;)a=(a+1)%this.wa,j=a==e?b:this.s[a],k=0.5*((h.x-i.x)*(j.y-i.y)-(h.y-i.y)*(j.x-i.x)),g+=k,f.x+=k*(i.x+h.x+j.x)/3,f.y+=k*(i.y+h.y+j.y)/3,h=j;f.Hc(1/g);d.m(Q(c,f));return g};F.Nl=function(a){a.s=this.s;a.V=this.wa;a.ra=this.ra};F.Nj=function(a){for(var b=0,c=this.s[0].x*a.x+this.s[0].y*a.y,d=1;d<this.wa;++d){var e=this.s[d].x*a.x+this.s[d].y*a.y;e>c&&(b=d,c=e)}return b};
F.si=function(a){for(var b=0,c=this.s[0].x*a.x+this.s[0].y*a.y,d=1;d<this.wa;++d){var e=this.s[d].x*a.x+this.s[d].y*a.y;e>c&&(b=d,c=e)}return this.s[b]};function Ce(a,b){a.s=[];a.Ha=[];for(var c=a.s.length;c<b;c++)a.s[c]=O(0,0),a.Ha[c]=O(0,0)}new je;function Ee(){this.Ei=this.Di=this.Fi=this.qb=0}function Fe(a,b){a.qb=b;a.Fi=a.qb&255;a.Di=(a.qb&65280)>>8&255;a.Ei=(a.qb&16711680)>>16&255;a.Vo=(a.qb&4278190080)>>24&255}Ee.prototype.p=function(a){Fe(this,a.qb)};
Ee.prototype.Gb=function(){var a=new Ee;a.p(this);return a};function Ge(){this.hd=O(0,0);this.id=new Ee}Ge.prototype.p=function(a){this.hd.m(a.hd);this.id.p(a.id)};function He(){this.na=O(0,0);this.qa=O(0,0)}var Ie=[];function Je(){if(0<Ie.length){var a=Ie.pop();a.S();return a}return new He}He.prototype.S=function(){this.na.p(0,0);this.qa.p(0,0)};function Ke(a,b){var c;return c=(c=(c=(c=m&&a.na.x<=b.na.x)&&a.na.y<=b.na.y)&&b.qa.x<=a.qa.x)&&b.qa.y<=a.qa.y}
He.prototype.Bi=function(a){return 0<a.na.x-this.qa.x||0<a.na.y-this.qa.y||0<this.na.x-a.qa.x||0<this.na.y-a.qa.y?q:m};function Le(a,b,c){a.na.x=Math.min(b.na.x,c.na.x);a.na.y=Math.min(b.na.y,c.na.y);a.qa.x=Math.max(b.qa.x,c.qa.x);a.qa.y=Math.max(b.qa.y,c.qa.y)}
function Me(a,b,c,d){var e=0,f=b[0].hd,g=b[1].hd,h=c.x*f.x+c.y*f.y-d,c=c.x*g.x+c.y*g.y-d;0>=h&&a[e++].p(b[0]);0>=c&&a[e++].p(b[1]);0>h*c&&(c=h/(h-c),d=a[e].hd,d.x=f.x+c*(g.x-f.x),d.y=f.y+c*(g.y-f.y),a[e].id=0<h?b[0].id:b[1].id,e++);return e}
function Ne(a,b,c,d,e){for(var f=b.e.c.x*a.Ha[c].x+b.e.d.x*a.Ha[c].y,g=b.e.c.y*a.Ha[c].x+b.e.d.y*a.Ha[c].y,h=e.e.c.x*f+e.e.c.y*g,i=e.e.d.x*f+e.e.d.y*g,j=0,k=Number.MAX_VALUE,n=0;n<d.wa;n++){var r=d.s[n].x*h+d.s[n].y*i;r<k&&(k=r,j=n)}return(e.position.x+(e.e.c.x*d.s[j].x+e.e.d.x*d.s[j].y)-(b.position.x+(b.e.c.x*a.s[c].x+b.e.d.x*a.s[c].y)))*f+(e.position.y+(e.e.c.y*d.s[j].x+e.e.d.y*d.s[j].y)-(b.position.y+(b.e.c.y*a.s[c].x+b.e.d.y*a.s[c].y)))*g}
function Oe(a,b,c,d){for(var e=d.position.x+(d.e.c.x*c.ud.x+d.e.d.x*c.ud.y),f=d.position.y+(d.e.c.y*c.ud.x+d.e.d.y*c.ud.y),e=e-(b.position.x+(b.e.c.x*a.ud.x+b.e.d.x*a.ud.y)),f=f-(b.position.y+(b.e.c.y*a.ud.x+b.e.d.y*a.ud.y)),g=e*b.e.c.x+f*b.e.c.y,f=e*b.e.d.x+f*b.e.d.y,e=0,h=-Number.MAX_VALUE,i=0;i<a.wa;++i){var j=a.Ha[i].x*g+a.Ha[i].y*f;j>h&&(h=j,e=i)}g=Ne(a,b,e,c,d);f=e-1;0>f&&(f=a.wa-1);h=Ne(a,b,f,c,d);i=e+1;i>=a.wa&&(i=0);var j=Ne(a,b,i,c,d),k=0,n=0;if(h>g&&h>j){k=f;for(n=h;;)if(e=k-1,0>e&&(e=
a.wa-1),g=Ne(a,b,e,c,d),g>n)k=e,n=g;else break}else if(j>g){k=i;for(n=j;;)if(e=k+1,e>=a.wa&&(e=0),g=Ne(a,b,e,c,d),g>n)k=e,n=g;else break}else k=e,n=g;return{fp:k,ml:n}}
function Pe(a,b,c){var d=new Qe,e=c.rf,f=c.ul,g=c.sf,h=c.vl,i,j;d.V=b.count;for(var k=d.s,n=0;n<d.V;n++){var r=k[n];r.sb=b.sb[n];r.tb=b.tb[n];i=U(e,r.sb);j=U(g,r.tb);r.mc=Q(f,i);r.Gd=Q(h,j);r.Zb=R(r.Gd,r.mc);r.q=0}if(1<d.V&&(i=b.Yu,j=Re(d),j<0.5*i||2*i<j||j<Number.MIN_VALUE))d.V=0;0==d.V&&(r=k[0],r.sb=0,r.tb=0,i=U(e,0),j=U(g,0),r.mc=Q(f,i),r.Gd=Q(h,j),r.Zb=R(r.Gd,r.mc),d.V=1);for(e=0;20>e;){f=[];for(g=0;g<d.V;g++)f[g]={},f[g].sb=d.s[g].sb,f[g].tb=d.s[g].tb;if(2==d.V)g=d,h=g.W.Zb,k=g.ja.Zb,i=R(k,h),
h=-(h.x*i.x+h.y*i.y),0>=h?(g.W.q=1,g.V=1):(k=k.x*i.x+k.y*i.y,0>=k?(g.ja.q=1,g.V=1,g.W.p(g.ja)):(i=1/(k+h),g.W.q=k*i,g.ja.q=h*i,g.V=2));else if(3==d.V){var g=d,s=g.W.Zb,t=g.ja.Zb,u=g.Rc.Zb,w=R(t,s),h=fe(t,w),k=-fe(s,w),x=R(u,s);i=fe(u,x);j=-fe(s,x);r=R(u,t);n=fe(u,r);r=-fe(t,r);x=ge(w,x);w=x*ge(t,u);u=x*ge(u,s);s=x*ge(s,t);0>=k&&0>=j?(g.W.q=1,g.V=1):0<h&&0<k&&0>=s?(i=1/(h+k),g.W.q=h*i,g.ja.q=k*i,g.V=2):0<i&&0<j&&0>=u?(h=1/(i+j),g.W.q=i*h,g.Rc.q=j*h,g.V=2,g.ja.p(g.Rc)):0>=h&&0>=r?(g.ja.q=1,g.V=1,g.W.p(g.ja)):
0>=i&&0>=n?(g.Rc.q=1,g.V=1,g.W.p(g.Rc)):0<n&&0<r&&0>=w?(h=1/(n+r),g.ja.q=n*h,g.Rc.q=r*h,g.V=2,g.W.p(g.Rc)):(h=1/(w+u+s),g.W.q=w*h,g.ja.q=u*h,g.Rc.q=s*h,g.V=3)}if(3==d.V)break;g=d;1==g.V?g=g.W.Zb.Cf():2==g.V?(h=R(g.ja.Zb,g.W.Zb),g=0<ge(h,g.W.Zb.Cf())?O(-1*h.y,1*h.x):he(h)):g=O(0,0);if(ve(g)<ee)break;h=g.Cf();d.s[d.V].sb=c.rf.Nj(ie(c.ul.e,h));d.s[d.V].mc=Q(c.ul,U(c.rf,d.s[d.V].sb));d.s[d.V].tb=c.sf.Nj(ie(c.vl.e,g));d.s[d.V].Gd=Q(c.vl,U(c.sf,d.s[d.V].tb));d.s[d.V].Zb=R(d.s[d.V].Gd,d.s[d.V].mc);T(g);
T(h);e++;h=q;for(g=0;g<f.length;g++)if(d.s[d.V].sb==f[g].sb&&d.s[d.V].tb==f[g].tb){h=m;break}if(h)break;d.V++}e=a.$d;f=a.ae;1==d.V?(e.m(d.W.mc),f.m(d.W.Gd)):2==d.V?(e.x=d.W.q*d.W.mc.x+d.ja.q*d.ja.mc.x,e.y=d.W.q*d.W.mc.y+d.ja.q*d.ja.mc.y,f.x=d.W.q*d.W.Gd.x+d.ja.q*d.ja.Gd.x,f.y=d.W.q*d.W.Gd.y+d.ja.q*d.ja.Gd.y):3==d.V&&(f.x=e.x=d.W.q*d.W.mc.x+d.ja.q*d.ja.mc.x+d.Rc.q*d.Rc.mc.x,f.y=e.y=d.W.q*d.W.mc.y+d.ja.q*d.ja.mc.y+d.Rc.q*d.Rc.mc.y);a.Ye=ue(R(a.$d,a.ae));b.Yu=Re(d);b.count=d.V;e=d.s;for(f=0;f<d.V;f++)b.sb[f]=
e[f].sb,b.tb[f]=e[f].tb;c.Gr&&(b=c.rf.ra,c=c.sf.ra,a.Ye>b+c&&a.Ye>Number.MIN_VALUE?(a.Ye-=b+c,d=R(a.ae,a.$d),we(d),a.$d.x+=b*d.x,a.$d.y+=b*d.y,a.ae.x-=c*d.x,a.ae.y-=c*d.y,T(d)):(c=O(0,0),c.x=0.5*(a.$d.x+a.ae.x),c.y=0.5*(a.$d.y+a.ae.y),a.$d.x=a.ae.x=c.x,a.$d.y=a.ae.y=c.y,a.Ye=0,T(c)))}function Se(){}function Te(){this.$d=O(0,0);this.ae=O(0,0);this.Ye=0}function Ue(){}Ue.prototype.p=function(a){a.Nl(this)};
Ue.prototype.Nj=function(a){for(var b=0,c=this.s[0].x*a.x+this.s[0].y*a.y,d=1;d<this.V;d++){var e=this.s[d].x*a.x+this.s[d].y*a.y;e>c&&(b=d,c=e)}return b};Ue.prototype.si=function(a){return this.s[this.Nj(a)]};function U(a,b){b===l&&(b=0);return a.s[b]}function Ve(){this.Ce=p;this.Lu=this.lx=0}F=Ve.prototype;F.ni=function(a,b){var c=We(b);c.ia.na.x=a.na.x-0.1;c.ia.na.y=a.na.y-0.1;c.ia.qa.x=a.qa.x+0.1;c.ia.qa.y=a.qa.y+0.1;Xe(this,c);return c};F.oi=function(a){Ye(this,a);a.vc()};
F.Il=function(a,b,c){if(Ke(a.ia,b))return q;Ye(this,a);var d=0.1+2*Math.abs(c.x),c=0.1+2*Math.abs(c.y);a.ia.na.x=b.na.x-d;a.ia.na.y=b.na.y-c;a.ia.qa.x=b.qa.x+d;a.ia.qa.y=b.qa.y+c;Xe(this,a);return m};F.qi=function(a){return a.ia};F.Ll=function(a,b){if(this.Ce!==p){var c=[];for(c.push(this.Ce);0<c.length;){var d=c.pop();if(d.ia.Bi(b))if(d.Ic===p){if(!a(d.qd))break}else c.push(d.Ic),c.push(d.ke)}}};
function Xe(a,b){a.Lu++;if(a.Ce===p)a.Ce=b,a.Ce.parent=p;else{var c;c=O((b.ia.na.x+b.ia.qa.x)/2,(b.ia.na.y+b.ia.qa.y)/2);for(var d=a.Ce;d.Ic!==p;)var e=d.Ic,d=d.ke,f=Math.abs((e.ia.na.x+e.ia.qa.x)/2-c.x)+Math.abs((e.ia.na.y+e.ia.qa.y)/2-c.y),g=Math.abs((d.ia.na.x+d.ia.qa.x)/2-c.x)+Math.abs((d.ia.na.y+d.ia.qa.y)/2-c.y),d=f<g?e:d;T(c);c=d;e=c.parent;d=We();d.parent=e;Le(d.ia,b.ia,c.ia);if(e){c.parent.Ic==c?e.Ic=d:e.ke=d;d.Ic=c;d.ke=b;c.parent=d;for(b.parent=d;e&&!Ke(e.ia,d.ia);)Le(e.ia,e.Ic.ia,e.ke.ia),
d=e,e=e.parent}else d.Ic=c,d.ke=b,c.parent=d,b.parent=d,a.Ce=d}}function Ye(a,b){if(b==a.Ce)a.Ce=p;else{var c=b.parent,d=c.parent,e;e=c.Ic==b?c.ke:c.Ic;if(d){d.Ic==c?d.Ic=e:d.ke=e;for(e.parent=d;d;){e=d.ia;Le(d.ia,d.Ic.ia,d.ke.ia);if(Ke(e,d.ia))break;d=d.parent}}else a.Ce=e,e.parent=p;c.vc()}}function Ze(){this.nf=new Ve;this.oj=[]}F=Ze.prototype;F.ni=function(a,b){var c=this.nf.ni(a,b);this.oj.push(c);return c};F.oi=function(a){qa(this.oj,a);this.nf.oi(a)};
F.Il=function(a,b,c){this.nf.Il(a,b,c)&&this.oj.push(a)};F.Bi=function(a,b){return this.nf.qi(a).Bi(this.nf.qi(b))};F.qi=function(a){return this.nf.qi(a)};F.Ll=function(a,b){this.nf.Ll(a,b)};function $e(a){this.ia=Je();this.qd=this.parent=this.ke=this.Ic=p;"undefined"!=typeof a&&(this.qd=a)}var af=[];function We(a){if(0<af.length){var b=af.pop();"undefined"!=typeof a&&(b.qd=a);b.ia.S();return b}return new $e(a)}$e.prototype.vc=function(){this.qd=this.parent=this.ke=this.Ic=p;af.push(this)};
function bf(a,b){this.Xi=a;this.Yi=b}function cf(){this.K=this.lb=0;this.Q=[];for(var a=0;2>a;a++)this.Q[a]=new df;this.Xb=O(0,0);this.ba=O(0,0)}cf.prototype.Pb=function(){for(var a=0;2>a;a++)this.Q[a].Pb();this.Xb.S();this.ba.S();this.lb=this.K=0};cf.prototype.p=function(a){this.lb=a.lb;for(var b=0;2>b;b++)this.Q[b].p(a.Q[b]);this.Xb.m(a.Xb);this.ba.m(a.ba);this.K=a.K};cf.prototype.Gb=function(){var a=new cf;a.p(this);return a};function df(){this.ba=O(0,0);this.wd=new Ee;this.Pb()}
df.prototype.Pb=function(){this.ba.S();this.Ng=this.Jg=0;Fe(this.wd,0)};df.prototype.p=function(a){this.ba.m(a.ba);this.Jg=a.Jg;this.Ng=a.Ng;this.wd.p(a.wd)};function ef(){this.ba=O(0,0);this.A=O(0,0)}
ef.prototype.Hb=function(a,b,c,d,e){this.Sf=b;this.Tf=d;var f,g,h,i=h=g=0,j=0,d=b=0,k,n,i=0;1==a.count?(this.K=ff,f=U(this.Sf,a.sb[0]),a=U(this.Tf,a.tb[0]),n=f,k=c.e,g=c.position.x+(k.c.x*n.x+k.d.x*n.y),h=c.position.y+(k.c.y*n.x+k.d.y*n.y),n=a,k=e.e,i=e.position.x+(k.c.x*n.x+k.d.x*n.y),j=e.position.y+(k.c.y*n.x+k.d.y*n.y),this.A.x=i-g,this.A.y=j-h,we(this.A)):(a.tb[0]==a.tb[1]?(this.K=gf,b=U(this.Sf,a.sb[0]),d=U(this.Sf,a.sb[1]),a=U(this.Tf,a.tb[0]),this.ba.x=0.5*(b.x+d.x),this.ba.y=0.5*(b.y+d.y),
this.A=he(R(d,b)),we(this.A),n=this.A,k=c.e,b=k.c.x*n.x+k.d.x*n.y,d=k.c.y*n.x+k.d.y*n.y,n=this.ba,k=c.e,g=c.position.x+(k.c.x*n.x+k.d.x*n.y),h=c.position.y+(k.c.y*n.x+k.d.y*n.y),n=a,k=e.e,i=e.position.x+(k.c.x*n.x+k.d.x*n.y),j=e.position.y+(k.c.y*n.x+k.d.y*n.y),i=(i-g)*b+(j-h)*d):a.sb[0]==a.sb[0]?(this.K=hf,g=U(this.Tf,a.tb[0]),h=U(this.Tf,a.tb[1]),f=U(this.Sf,a.sb[0]),this.ba.x=0.5*(g.x+h.x),this.ba.y=0.5*(g.y+h.y),this.A=he(R(h,g)),we(this.A),n=this.A,k=e.e,b=k.c.x*n.x+k.d.x*n.y,d=k.c.y*n.x+k.d.y*
n.y,n=this.ba,k=e.e,i=e.position.x+(k.c.x*n.x+k.d.x*n.y),j=e.position.y+(k.c.y*n.x+k.d.y*n.y),n=f,k=c.e,g=c.position.x+(k.c.x*n.x+k.d.x*n.y),h=c.position.y+(k.c.y*n.x+k.d.y*n.y),i=(g-i)*b+(h-j)*d):(b=U(this.Sf,a.sb[0]),d=U(this.Sf,a.sb[1]),g=U(this.Tf,a.tb[0]),h=U(this.Tf,a.tb[1]),i=P(c.e,R(d,b)),j=P(e.e,R(h,g)),e=i.x*i.x+i.y*i.y,c=j.x*j.x+j.y*j.y,f=R(j,i),a=i.x*f.x+i.y*f.y,f=j.x*f.x+j.y*f.y,j=i.x*j.x+i.y*j.y,k=e*c-j*j,i=0,0!=k&&(i=S((j*f-a*c)/k,0,1)),0>(j*i+f)/c&&(i=S((j-a)/e,0,1)),f=O(0,0),f.x=
b.x+i*(d.x-b.x),f.y=b.y+i*(d.y-b.y),a=O(0,0),a.x=g.x+i*(h.x-g.x),a.y=g.y+i*(h.y-g.y),0==i||1==i?(this.K=hf,this.A=he(R(h,g)),we(this.A),this.ba=a):(this.K=gf,this.A=he(R(d,b)),this.ba=f)),0>i&&this.A.Ko())};
ef.prototype.ge=function(a,b){var c,d,e=0;switch(this.K){case ff:c=ie(a.e,this.A);d=ie(b.e,this.A.Cf());c=this.Sf.si(c);d=this.Tf.si(d);c=Q(a,c);d=Q(b,d);e=(d.x-c.x)*this.A.x+(d.y-c.y)*this.A.y;break;case gf:e=P(a.e,this.A);c=Q(a,this.ba);d=ie(b.e,e.Cf());d=this.Tf.si(d);d=Q(b,d);e=(d.x-c.x)*e.x+(d.y-c.y)*e.y;break;case hf:e=P(b.e,this.A),d=Q(b,this.ba),c=ie(a.e,e.Cf()),c=this.Sf.si(c),c=Q(a,c),e=(c.x-d.x)*e.x+(c.y-d.y)*e.y}return e};var ff=1,gf=2,hf=4;
function Qe(){this.W=new jf;this.ja=new jf;this.Rc=new jf;this.s=[this.W,this.ja,this.Rc]}function Re(a){return 1==a.V?0:2==a.V?ue(R(a.W.Zb,a.ja.Zb)):3==a.V?ge(R(a.ja.Zb,a.W.Zb),R(a.Rc.Zb,a.W.Zb)):0}function kf(){this.sb=[0,0,0];this.tb=[0,0,0]}function jf(){}jf.prototype.p=function(a){this.mc.m(a.mc);this.Gd.m(a.Gd);this.Zb.m(a.Zb);this.q=a.q;this.sb=a.sb;this.tb=a.tb};function lf(){this.rf=new Ue;this.sf=new Ue;this.sr=new qe;this.tr=new qe}
function mf(){this.Z=O(0,0);this.Q=[];for(var a=this.lb=0;2>a;a++)this.Q[a]=O(0,0)}
mf.prototype.Hb=function(a,b,c,d,e){if(0!=a.lb){var f=0,g,h,i=0,j=0,k=0,n=0,r=0;g=0;switch(a.K){case 1:h=b.e;g=a.ba;f=b.position.x+h.c.x*g.x+h.d.x*g.y;b=b.position.y+h.c.y*g.x+h.d.y*g.y;h=d.e;g=a.Q[0].ba;a=d.position.x+h.c.x*g.x+h.d.x*g.y;d=d.position.y+h.c.y*g.x+h.d.y*g.y;g=a-f;h=d-b;i=g*g+h*h;i>ee?(i=Math.sqrt(i),this.Z.x=g/i,this.Z.y=h/i):(this.Z.x=1,this.Z.y=0);g=b+c*this.Z.y;d-=e*this.Z.y;this.Q[0].x=0.5*(f+c*this.Z.x+(a-e*this.Z.x));this.Q[0].y=0.5*(g+d);break;case 2:h=b.e;g=a.Xb;i=h.c.x*g.x+
h.d.x*g.y;j=h.c.y*g.x+h.d.y*g.y;h=b.e;g=a.ba;k=b.position.x+h.c.x*g.x+h.d.x*g.y;n=b.position.y+h.c.y*g.x+h.d.y*g.y;this.Z.x=i;this.Z.y=j;for(f=0;f<a.lb;f++)h=d.e,g=a.Q[f].ba,r=d.position.x+h.c.x*g.x+h.d.x*g.y,g=d.position.y+h.c.y*g.x+h.d.y*g.y,this.Q[f].x=r+0.5*(c-(r-k)*i-(g-n)*j-e)*i,this.Q[f].y=g+0.5*(c-(r-k)*i-(g-n)*j-e)*j;break;case 4:h=d.e;g=a.Xb;i=h.c.x*g.x+h.d.x*g.y;j=h.c.y*g.x+h.d.y*g.y;h=d.e;g=a.ba;k=d.position.x+h.c.x*g.x+h.d.x*g.y;n=d.position.y+h.c.y*g.x+h.d.y*g.y;this.Z.x=-i;this.Z.y=
-j;for(f=0;f<a.lb;f++)h=b.e,g=a.Q[f].ba,r=b.position.x+h.c.x*g.x+h.d.x*g.y,g=b.position.y+h.c.y*g.x+h.d.y*g.y,this.Q[f].x=r+0.5*(e-(r-k)*i-(g-n)*j-c)*i,this.Q[f].y=g+0.5*(e-(r-k)*i-(g-n)*j-c)*j}}};
function nf(a,b){this.wc="Body"+of++;this.i=new re;this.i.position.m(a.position);this.i.e.p(a.v);this.b=new qe;this.b.r.S();this.b.uc=1;this.b.nd=this.b.q=a.v;this.b.g.x=this.i.e.c.x*this.b.r.x+this.i.e.d.x*this.b.r.y;this.b.g.y=this.i.e.c.y*this.b.r.x+this.i.e.d.y*this.b.r.y;this.b.g.x+=this.i.position.x;this.b.g.y+=this.i.position.y;this.b.Ub.m(this.b.g);this.f=a.Au.Gb();this.hf=O(0,0);this.Lh=a.$j;this.Gu=a.Dp;this.ln=a.Bs;this.fc=a.Hs;this.kn=a.ie;this.hc=b;this.Ya=p;this.Vb=new pf;this.rg=new qf;
this.bx=0;this.j=a.Fs;this.Nu=a.Mk;this.Cu=a.Rj;this.rj=this.Og=0;this.K=a.type;this.w=2==this.K?1:0;this.n=2==this.K?1:0;this.z=this.td=0;this.Ku=a.nu;this.wg=new rf;this.Uk=[]}function sf(a,b){var c=new tf(a,0,b);a.kn&&c.ni(a.hc.Bc.Kh,a.i);var d=a.wg,e=c.wc;if(d.nk[e]==p){var f=new uf(c),g=d.xm;g!=p?g.Id(f):d.wm=f;f.Jd(g);d.xm=f;d.nk[e]=f;d.Ep++}c.mn=a;0<c.on&&vf(a);a.hc.wn=m}F=nf.prototype;F.vc=function(){T(this.f);T(this.hf)};
function wf(a,b,c){a.i.e.p(c);a.i.position.m(b);var b=a.i.e,d=a.b.r;a.b.g.x=b.c.x*d.x+b.d.x*d.y;a.b.g.y=b.c.y*d.x+b.d.y*d.y;a.b.g.x+=a.i.position.x;a.b.g.y+=a.i.position.y;a.b.Ub.m(a.b.g);a.b.nd=a.b.q=c;c=a.hc.Bc.Kh;for(b=a.wg.ka();b;b=b.next)xf(b.qd,c,a.i,a.i);yf(a.hc.Bc)}F.Nc=y("i");F.Hd=function(){return this.b.q};F.So=function(a){wf(this,this.i.position,a)};function zf(a,b){0!=a.K&&a.f.m(b)}F.Ml=function(a){a===l&&(a=0);0!=this.K&&(this.j=a)};
F.Ne=function(a,b){2==this.K&&(V(this,m),this.hf.x+=a.x,this.hf.y+=a.y,this.Og+=(b.x-this.b.g.x)*a.y-(b.y-this.b.g.y)*a.x)};F.El=function(a){a===l&&(a=0);2==this.K&&(V(this,m),this.Og+=a)};F.Io=function(a){a||(a=new Ae);a.De=this.w;a.fh=this.td;a.Se.m(this.b.r);return a};
function vf(a){a.w=0;a.n=0;a.td=0;a.z=0;a.b.r.S();if(!(0==a.K||1==a.K)){for(var b=O(0,0),c=a.wg.ka();c;c=c.next){var d=c.qd;0!=d.on&&(d=d.Io(),a.w+=d.De,b.x+=d.Se.x*d.De,b.y+=d.Se.y*d.De,a.td+=d.fh)}0<a.w?(a.n=1/a.w,b.x*=a.n,b.y*=a.n):(a.w=1,a.n=1);0<a.td&&!a.Gu?(a.td-=a.w*(b.x*b.x+b.y*b.y),a.td*=a.Ku,a.z=1/a.td):(a.td=0,a.z=0);c=a.b.g.Gb();a.b.r.m(b);a.b.Ub.m(Q(a.i,a.b.r));a.b.g.m(a.b.Ub);a.f.x+=a.j*-(a.b.g.y-c.y);a.f.y+=a.j*+(a.b.g.x-c.x);T(b);T(c)}}
function Af(a,b){var c=a.i.e,c=O(c.c.x*b.x+c.d.x*b.y,c.c.y*b.x+c.d.y*b.y);c.x+=a.i.position.x;c.y+=a.i.position.y;return c}function Bf(a,b){var c=a.i,d=R(b,c.position),e=d.x*c.e.c.x+d.y*c.e.c.y;d.y=d.x*c.e.d.x+d.y*c.e.d.y;d.x=e;return d}function V(a,b){if(a.fc!=b){a.fc=b;a.rj=0;b||(a.f.S(),a.j=0,a.hf.S(),a.Og=0);for(var c=0;c<a.Uk.length;c++)Cf(a.Uk[c],a)}}F.kg=y("kn");F.ki=function(a){this.rg.ki(a)};F.Ai=function(a){this.rg.Ai(a)};
function Df(a){Ef.e.p(a.b.nd);var b=Ef.e,c=a.b.r;Ef.position.x=a.b.Ub.x-(b.c.x*c.x+b.d.x*c.y);Ef.position.y=a.b.Ub.y-(b.c.y*c.x+b.d.y*c.y);b=a.hc.Bc.Kh;for(c=a.wg.ka();c;c=c.next)xf(c.qd,b,Ef,a.i)}function W(a){a.i.e.p(a.b.q);var b=a.i.e,c=a.b.r;a.i.position.x=a.b.g.x-(b.c.x*c.x+b.d.x*c.y);a.i.position.y=a.b.g.y-(b.c.y*c.x+b.d.y*c.y)}F.ih=function(a){if(2!=this.K&&2!=a.K)return q;for(var b=this.Ya;b;b=b.next)if(b.fd==a&&b.df.Bq==q)return q;return m};
F.Bf=function(a){this.b.Bf(a);this.b.g.m(this.b.Ub);this.b.q=this.b.nd;W(this)};var of=0;function Ff(){this.position=O(0,0);this.Au=O(0,0);this.Rj=this.Mk=this.Fs=this.v=0;this.Hs=this.Bs=m;this.$j=this.Dp=q;this.type=0;this.ie=m;this.nu=1}function Gf(){this.Yj=[];for(var a=0;a<=Hf;a++)this.Yj[a]=p;this.Zj=[];for(a=0;a<=Hf;a++)this.Zj[a]=p;this.lh={};this.gp=0}F=Gf.prototype;F.ka=function(a){return this.Yj[a]};
F.ah=function(a){var b=a.wc;this.lh[b]==p&&(this.fe(a,b,Hf),Cf(this,a),a.Uk.push(this),this.gp++)};function Cf(a,b){var c=b.K,d=b.wc,e=b.fc,f=b.kg();2==c?a.fe(b,d,If):a.he(d,If);0!=c?a.fe(b,d,Jf):a.he(d,Jf);0!=c&&f&&e?a.fe(b,d,Kf):a.he(d,Kf);e?a.fe(b,d,Lf):a.he(d,Lf);f?a.fe(b,d,Mf):a.he(d,Mf)}F.zi=function(a){var b=a.wc;if(this.lh[b]!=p){qa(a.Uk,this);for(a=0;a<=Hf;a++)this.he(b,a);delete this.lh[b];this.gp--}};
F.he=function(a,b){var c=this.lh[a];if(c!=p){var d=c[b];d!=p&&(c[b]=p,c=d.Ad,d=d.next,c==p?this.Yj[b]=d:c.Id(d),d==p?this.Zj[b]=c:d.Jd(c))}};F.fe=function(a,b,c){var d=this.lh[b];if(d==p){for(var d=[],e=0;e<=Hf;e++)d[e]=p;this.lh[b]=d}d[c]==p&&(d[c]=new Nf(a),a=this.Zj[c],a!=p?a.Id(d[c]):this.Yj[c]=d[c],d[c].Jd(a),this.Zj[c]=d[c])};var If=0,Jf=1,Mf=2,Kf=3,Lf=4,Hf=5;function Nf(a){this.body=a;this.Ad=this.next=p}Nf.prototype.Id=ba("next");Nf.prototype.Jd=ba("Ad");Nf.prototype.sa=y("body");
function Of(){}Of.prototype.ih=function(a,b){var c=a.Dq.Gb(),d=b.Dq.Gb();return c.yg==d.yg&&0!=c.yg?0<c.yg:0!=(c.sj&d.Oi)&&0!=(c.Oi&d.sj)};var Pf=new Of;function Qf(){this.Zu=[];this.Jv=[]}function Rf(){}Rf.prototype.Eo=v();function Sf(a){this.hc=a;this.nn=Pf;this.kj=Tf;this.Cq=new Uf;this.Kh=new Ze}
function yf(a){for(var b=a.Kh,c=[];0<b.oj.length;){var d=b.oj.pop();b.nf.Ll(function(a){a!=d.qd&&c.push(new bf(d.qd,a));return m},b.nf.qi(d))}for(b=0;b<c.length;){var e=c[b],f=e.Xi,g=e.Yi;a:{var h=a,i=f.sa(),j=g.sa();if(i!=j&&j.ih(i)&&h.nn.ih(f,g)){for(i=j.Vb.ka(Vf);i;i=i.next)if(j=i.Ib.wb,j==f){if(j=i.Ib.kb,j==g)break a}else if(j==g&&(j=i.Ib.kb,j==f))break a;h.Cq.ee(f,g)}}for(b++;b<c.length;){f=c[b];if(!(f.Xi==e.Xi&&f.Yi==e.Yi)&&!(f.Xi==e.Yi&&f.Yi==e.Xi))break;b++}}}
Sf.prototype.vc=function(a){0<a.dd.lb&&(V(a.wb.sa(),m),V(a.kb.sa(),m));Wf(a.Wj,a);Wf(a.Xj,a);Wf(a.Cl,a);this.Cq.vc(a)};function Xf(){this.Oi=1;this.sj=65535;this.yg=0}Xf.prototype.Gb=function(){var a=new Xf;a.Oi=this.Oi;a.sj=this.sj;a.yg=this.yg;return a};function tf(a,b,c){this.wc="Fixture"+Yf++;this.Dq=c.filter.Gb();this.Gg=Je();this.mn=a;this.Cb=c.shape.Gb();this.on=c.oh;this.Eq=c.rh;this.Xk=c.Zh;this.Mu=c.uu}F=tf.prototype;F.gh=y("Mu");F.sa=y("mn");
F.Io=function(a){a||(a=new Ae);this.Cb.mi(a,this.on);return a};F.vc=function(){Ie.push(this.Gg)};F.ni=function(a,b){this.Cb.dh(this.Gg,b);this.Kg=a.ni(this.Gg,this)};F.oi=function(a){this.Kg!=p&&(a.oi(this.Kg),this.Kg=p)};function xf(a,b,c,d){if(a.Kg){var e=Je(),f=Je();a.Cb.dh(e,c);a.Cb.dh(f,d);Le(a.Gg,e,f);Ie.push(e);Ie.push(f);c=R(d.position,c.position);b.Il(a.Kg,a.Gg,c);T(c)}}var Yf=0;
function Zf(){this.filter=new Xf;this.filter.Oi=1;this.filter.sj=65535;this.filter.yg=0;this.shape=p;this.rh=0.2;this.oh=this.Zh=0;this.uu=q}function rf(){this.xm=this.wm=p;this.nk={};this.Ep=0}rf.prototype.ka=y("wm");function uf(a){this.qd=a;this.Ad=this.next=p}uf.prototype.Id=ba("next");uf.prototype.Jd=ba("Ad");function $f(a,b){this.Ou=a;this.Sd=b;this.we=[];this.Sk=[];this.Rf=[];this.gf=[];this.gc=[]}F=$f.prototype;F.Lj=function(){this.we=[];this.Sk=[];this.Rf=[];this.gf=[];this.gc=[]};
F.lg=function(a,b,c){for(var d=0;d<this.Sk.length;d++){var e=this.Sk[d];e.f.x+=a.fa*(b.x+e.n*e.hf.x);e.f.y+=a.fa*(b.y+e.n*e.hf.y);e.j+=a.fa*e.z*e.Og;e.f.Hc(S(1-a.fa*e.Nu,0,1));e.j*=S(1-a.fa*e.Cu,0,1)}this.Sd.Hb(a,this.gf,this.gf.length);this.Sd.md(a);for(b=0;b<this.gc.length;b++)this.gc[b].md(a);for(b=0;b<a.Jj;b++){for(d=0;d<this.gc.length;d++)this.gc[d].Wc(a);this.Sd.Wc()}for(b=0;b<this.gc.length;b++)this.gc[b].Hl();this.Sd.Hl();for(b=0;b<this.Rf.length;++b){var d=this.Rf[b],e=a.fa*d.f.x,f=a.fa*
d.f.y;4<e*e+f*f&&(we(d.f),d.f.x*=2*a.bf,d.f.y*=2*a.bf);e=a.fa*d.j;e*e>ce&&(d.j=0>d.j?-be*a.bf:be*a.bf);d.b.Ub.m(d.b.g);d.b.nd=d.b.q;d.b.g.x+=a.fa*d.f.x;d.b.g.y+=a.fa*d.f.y;d.b.q+=a.fa*d.j;W(d)}for(b=0;b<a.uj;b++){d=this.Sd.Vc(0.2);e=m;for(f=0;f<this.gc.length;f++)var g=this.gc[f].Vc(0.2),e=e&&g;if(d&&e)break}ag(this,this.Sd.xe);if(c){c=Number.MAX_VALUE;for(b=0;b<this.Rf.length;b++)d=this.Rf[b],!d.ln||Math.abs(d.j)>de||1E-4<fe(d.f,d.f)?c=d.rj=0:(d.rj+=a.fa,c=Math.min(c,d.rj));if(0.5<=c)for(a=0;a<this.we.length;a++)V(this.we[a],
q)}};
F.Sl=function(a){var b=0,c=0;this.Sd.Hb(a,this.gf,this.gf.length);for(var d=this.Sd,b=0;b<this.gc.length;++b)this.gc[b].md(a);for(b=0;b<a.Jj;++b){d.Wc();for(c=0;c<this.gc.length;++c)this.gc[c].Wc(a)}for(b=0;b<this.Rf.length;++b){var c=this.Rf[b],e=a.fa*c.f.x,f=a.fa*c.f.y;4<e*e+f*f&&(we(c.f),c.f.x*=2*a.bf,c.f.y*=2*a.bf);e=a.fa*c.j;e*e>ce&&(c.j=0>c.j?-be*a.bf:be*a.bf);c.b.Ub.m(c.b.g);c.b.nd=c.b.q;c.b.g.x+=a.fa*c.f.x;c.b.g.y+=a.fa*c.f.y;c.b.q+=a.fa*c.j;W(c)}for(b=0;b<a.uj;++b){e=d.Vc(0.75);f=m;for(c=
0;c<this.gc.length;++c)var g=this.gc[c].Vc(0.2),f=f&&g;if(e&&f)break}ag(this,d.xe)};function ag(a,b){if(a.Ou!=p)for(var c=0;c<a.gf.length;++c)for(var d=b[c],e=new Qf,f=0;f<d.zd;++f)e.Zu[f]=d.nb[f].mb,e.Jv[f]=d.nb[f].Ke}F.ah=function(a){this.we.push(a);0!=a.K&&(this.Rf.push(a),2==a.K&&this.Sk.push(a))};F.bh=function(a){this.gf.push(a)};function bg(a,b,c,d,e){this.fa=a;var f=0;0<a&&(f=1/a);this.bf=f;this.Ab=b;this.uj=c;this.Jj=d;this.yf=e}
function cg(a,b){this.Bc=new Sf(this);this.Sd=new dg;this.wn=this.Gq=q;this.jx=p;this.Tb=new Gf;this.Vb=new pf;this.Ya=p;this.rg=new qf;this.Tk=0;this.Eu=this.Tu=m;this.ln=b;this.qn=a;this.Fq=0;this.Ju=eg(this,new Ff)}var fg=1-100*Number.MIN_VALUE;function eg(a,b){var c=new nf(b,a);a.Tb.ah(c);return c}
function gg(a,b){for(var c=b.Ya;c;){var d=c,c=c.next;hg(a,d.df)}for(c=b.rg.ka();c;c=c.next)c.op.zi(b);for(c=b.Vb.ka(Vf);c;c=c.next)a.Bc.vc(c.Ib);for(c=b.wg.ka();c;c=c.next){var d=b,e=c.qd,f=d.wg,g=e.wc,h=f.nk[g];if(h!=p){var i=h.Ad,h=h.next;i==p?f.wm=h:i.Id(h);h==p?f.xm=i:h.Jd(i);delete f.nk[g];f.Ep--}for(f=d.Vb.ka(Vf);f;f=f.next)(e==f.Ib.wb||e==f.Ib.kb)&&d.hc.Bc.vc(f.Ib);d.kn&&e.oi(d.hc.Bc.Kh);e.vc();e.mn=p;vf(d)}b.vc();a.Tb.zi(b)}
function ig(a,b){var c=b.ee();c.Nh=p;if(c.Qf=a.Ya)a.Ya.Nh=c;a.Ya=c;a.Tk++;c.Cc.df=c;c.Cc.fd=c.D;c.Cc.prev=p;if(c.Cc.next=c.B.Ya)c.B.Ya.prev=c.Cc;c.B.Ya=c.Cc;c.Dc.df=c;c.Dc.fd=c.B;c.Dc.prev=p;if(c.Dc.next=c.D.Ya)c.D.Ya.prev=c.Dc;c.D.Ya=c.Dc;var d=b.t,e=b.u;if(!b.em)for(var f=e.Vb.ka(Vf);f;f=f.next)jg(f.Ib,e)==d&&(f.Ib.Wi=m);return c}
function hg(a,b){var c=b.Bq;b.Nh&&(b.Nh.Qf=b.Qf);b.Qf&&(b.Qf.Nh=b.Nh);b==a.Ya&&(a.Ya=b.Qf);var d=b.B,e=b.D;V(d,m);V(e,m);b.Cc.prev&&(b.Cc.prev.next=b.Cc.next);b.Cc.next&&(b.Cc.next.prev=b.Cc.prev);b.Cc==d.Ya&&(d.Ya=b.Cc.next);b.Cc.prev=p;b.Cc.next=p;b.Dc.prev&&(b.Dc.prev.next=b.Dc.next);b.Dc.next&&(b.Dc.next.prev=b.Dc.prev);b.Dc==e.Ya&&(e.Ya=b.Dc.next);b.Dc.prev=p;b.Dc.next=p;a.Tk--;if(!c)for(c=e.Vb.ka(Vf);c;c=c.next)jg(c.Ib,e)==d&&(c.Ib.Wi=m)}
cg.prototype.ki=function(a){if(a.hc!==p&&a.hc!=this)throw Error("Controller can only be a member of one world");this.rg.ki(a);a.hc=this;return a};cg.prototype.Ai=function(a){this.rg.Ai(a);a.hc=p;a.Lj()};
cg.prototype.Df=function(a,b,c){this.wn&&(yf(this.Bc),this.wn=q);this.Gq=m;a=new bg(a,this.Fq*a,b,c,this.Tu);b=this.Bc;for(c=b.hc.Vb.ka(Vf);c;c=c.next){var d=c.Ib,e=d.wb,f=d.kb,g=e.sa(),h=f.sa();if(!(g.fc==q&&h.fc==q)){if(d.Wi){if(h.ih(g)==q){b.vc(d);continue}if(b.nn.ih(e,f)==q){b.vc(d);continue}d.Wi=q}b.Kh.Bi(e.Kg,f.Kg)==q?b.vc(d):kg(d,b.kj)}}0<a.fa&&(this.lg(a),this.Eu&&this.Sl(a),this.Fq=a.bf);this.Gq=q};var lg=[];
cg.prototype.lg=function(a){for(var b=this.rg.ka();b;b=b.next)b.op.Df(a);for(var b=new $f(this.Bc.kj,this.Sd),c=this.Tb.ka(Hf);c;c=c.next)c.body.Oa=q;for(var d=this.Vb.ka(Vf);d;d=d.next)d.Ib.Oa=q;for(c=this.Ya;c;c=c.Qf)c.Oa=q;for(c=this.Tb.ka(Kf);c;c=c.next)if(d=c.body,!d.Oa){b.Lj();lg.length=0;var e=lg;e.push(d);for(d.Oa=m;0<e.length;){var f=e.pop();b.ah(f);f.fc||V(f,m);if(0!=f.K){for(d=f.Vb.ka(mg);d;d=d.next){var g=d.Ib;g.Oa||(b.bh(g),g.Oa=m,g=jg(g,f),g.Oa||(e.push(g),g.Oa=m))}for(d=f.Ya;d;d=d.next)!d.df.Oa&&
d.fd.kg()&&(b.gc.push(d.df),d.df.Oa=m,d.fd.Oa||(e.push(d.fd),d.fd.Oa=m))}}b.lg(a,this.qn,this.ln)}for(c=this.Tb.ka(Kf);c;c=c.next)Df(c.body);yf(this.Bc)};
cg.prototype.Sl=function(a){var b,c,d=new $f(this.Bc.kj,this.Sd);for(c=this.Tb.ka(Hf);c;c=c.next){var e=c.body;e.Oa=q;e.b.uc=0}for(var f=this.Vb.ka(Vf);f;f=f.next)f.Ib.Oa=q,f.Ib.Rh=p;for(c=this.Ya;c;c=c.Qf)c.Oa=q;for(;;){b=p;c=1;for(e=this.Vb.ka(ng);e;e=e.next){var f=e.Ib,g=f.wb.sa(),h=f.kb.sa();if(2==g.K&&g.fc||2==h.K&&h.fc){h=1;if(f.Rh!=p)h=f.Rh;else{if(f.ei)h=1;else{var i=f.wb.sa(),j=f.kb.sa(),g=i.b.uc;i.b.uc<j.b.uc?(g=j.b.uc,i.b.Bf(g)):j.b.uc<i.b.uc&&(g=i.b.uc,j.b.Bf(g));h=f;i=i.b;j=j.b;og.rf.p(h.wb.Cb);
og.sf.p(h.kb.Cb);og.sr=i;og.tr=j;og.Mv=0.005;var k=og;pg++;var h=k.rf,j=k.sf,i=k.sr,n=k.tr,r=h.ra+j.ra,k=k.Mv,s=0,t=0,u=0;qg.count=0;for(rg.Gr=q;;){i.Nc(sg,s);n.Nc(tg,s);rg.rf=h;rg.sf=j;rg.ul=sg;rg.vl=tg;Pe(ug,qg,rg);if(0>=ug.Ye){s=1;break}vg.Hb(qg,h,sg,j,tg);var w=vg.ge(sg,tg);if(0>=w){s=1;break}0==t&&(u=w>r?Math.max(r-k,0.75*r):Math.max(w-k,0.02*r));if(w-u<0.5*k){if(0==t){s=1;break}break}var x=s,C=s,B=1;i.Nc(sg,B);n.Nc(tg,B);var z=vg.ge(sg,tg);if(z>=u){s=1;break}for(var E=0;;){var A=0,A=E&1?C+(u-
w)*(B-C)/(z-w):0.5*(C+B);i.Nc(sg,A);n.Nc(tg,A);var I=vg.ge(sg,tg);if(Math.abs(I-u)<0.025*k){x=A;break}I>u?(C=A,w=I):(B=A,z=I);E++;wg++;if(50==E)break}xg=Math.max(xg,E);if(x<(1+100*Number.MIN_VALUE)*s)break;s=x;t++;yg++;if(1E3==t)break}zg=Math.max(zg,t);h=s;0<h&&1>h&&(h=(1-h)*g+h)}f.Rh=h}Number.MIN_VALUE<h&&h<c&&(b=f,c=h)}}if(b===p||fg<c)break;f=b.wb.sa();e=b.kb.sa();Ag.p(f.b);Bg.p(e.b);f.Bf(c);e.Bf(c);kg(b,this.Bc.kj);b.Rh=p;if(b.ll||!b.enabled)f.b.p(Ag),e.b.p(Bg),W(f),W(e);else if(b.ei){2!=f.K&&
(f=e);d.Lj();lg.length=0;b=lg;b.push(f);for(f.Oa=m;0<b.length;)if(e=b.pop(),d.ah(e),e.fc||V(e,m),2==e.K){for(f=e.Vb.ka(mg);f&&32!=d.Du;f=f.next)g=f.Ib,g.Oa||(d.bh(g),g.Oa=m,g=jg(g,e),g.Oa||(0!=g.K&&(g.Bf(c),V(g,m),b.push(g)),g.Oa=m));for(e=e.Ya;e;e=e.next)32!=d.Tk&&(!e.df.Oa&&e.fd.kg())&&(d.gc.push(e.df),e.df.Oa=m,e.fd.Oa||(0!=e.fd.K&&(e.fd.Bf(c),V(e.fd,m),b.push(e.fd)),e.fd.Oa=m))}d.Sl(new bg((1-c)*a.fa,0,a.Jj,a.uj,q));for(c=0;c<d.we.length;c++)if(d.we[c].Oa=q,d.we[c].fc&&2==d.we[c].K){Df(d.we[c]);
for(f=d.we[c].Vb.ka(Vf);f;f=f.next)f.Ib.Rh=p}for(c=0;c<d.Du;c++)d.gf[c].Oa=q,d.gf[c].Rh=p;for(c=0;c<d.Tk;c++)d.gc[c].Oa=q;yf(this.Bc)}}};function X(a,b){this.wc="Contact"+Cg++;this.dd=new cf;this.pj=new cf;this.ei=q;var c=a.sa(),d=b.sa();this.fm=2!=c.K||c.Lh||2!=d.K||d.Lh;this.ll=a.gh()||b.gh();this.Wi=q;this.wb=a;this.kb=b;this.enabled=m;this.Wj=c.Vb;this.Xj=d.Vb;this.Cl=d.hc.Vb;Dg(this)}
X.prototype.Pb=function(a,b){this.dd.Pb();this.pj.Pb();this.ei=q;var c=a.sa(),d=b.sa();this.fm=2!=c.K||c.Lh||2!=d.K||d.Lh;this.ll=a.gh()||b.gh();this.Wi=q;this.wb=a;this.kb=b;this.enabled=m;this.Wj=c.Vb;this.Xj=d.Vb;this.Cl=d.hc.Vb;Dg(this)};function Dg(a){a.Wj.bh(a);a.Xj.bh(a);a.Cl.bh(a);Eg(a)}function Eg(a){var b=q,c=q;!a.gh()&&a.enabled&&(a.ei&&(b=m),a.fm&&(c=m));Fg(a.Wj,a,b,c);Fg(a.Xj,a,b,c);Fg(a.Cl,a,b,c)}X.prototype.gh=y("ll");function jg(a,b){var c=a.wb.sa();return c!=b?c:a.kb.sa()}
function kg(a,b){var c=a.pj;a.pj=a.dd;a.dd=c;a.enabled=m;var d=q,c=a.ei,e=a.wb.sa(),f=a.kb.sa(),g=a.wb.Gg.Bi(a.kb.Gg);if(a.ll){if(g){var d=a.wb.Cb,e=e.Nc(),g=a.kb.Cb,h=f.Nc(),f=new Se;f.rf=new Ue;f.rf.p(d);f.sf=new Ue;f.sf.p(g);f.ul=e;f.vl=h;f.Gr=m;e=new kf;e.count=0;d=new Te;Pe(d,e,f);d=d.Ye<10*Number.MIN_VALUE}a.dd.lb=0}else{a.fm=2!=e.K||e.Lh||2!=f.K||f.Lh?m:q;if(g){a.ge();d=0<a.dd.lb;for(g=0;g<a.dd.lb;g++){h=a.dd.Q[g];h.Jg=0;for(var i=h.Ng=0;i<a.pj.lb;i++){var j=a.pj.Q[i];if(j.wd.qb==h.wd.qb){h.Jg=
j.Jg;h.Ng=j.Ng;break}}}}else a.dd.lb=0;d!=c&&(V(e,m),V(f,m))}a.ei=d;d!=c&&Eg(a);!c&&d&&b.Eo(a)}X.prototype.ge=v();var og=new lf,Cg=0;function Gg(a,b){X.call(this,a,b)}N(Gg,X);Gg.prototype.Pb=function(a,b){X.prototype.Pb.call(this,a,b)};
Gg.prototype.ge=function(){var a=this.dd,b=this.wb.Cb,c=this.wb.sa().i,d=this.kb.Cb,e=this.kb.sa().i;a.lb=0;var f=e.position.x+(e.e.c.x*d.Aa.x+e.e.d.x*d.Aa.y)-(c.position.x+(c.e.c.x*b.Aa.x+c.e.d.x*b.Aa.y)),c=e.position.y+(e.e.c.y*d.Aa.x+e.e.d.y*d.Aa.y)-(c.position.y+(c.e.c.y*b.Aa.x+c.e.d.y*b.Aa.y)),e=b.ra+d.ra;f*f+c*c>e*e||(a.K=1,a.ba.m(b.Aa),a.Xb.S(),a.lb=1,a.Q[0].ba.m(d.Aa),Fe(a.Q[0].wd,0))};
function Hg(){this.ve=O(0,0);this.jb=O(0,0);this.sc=O(0,0);this.qf=new je;this.Oc=new je;this.nb=[];for(var a=0;2>a;a++)this.nb[a]=new Ig}function Ig(){this.jb=O(0,0);this.$a=O(0,0);this.ab=O(0,0)}Ig.prototype.Pb=function(){this.jb.p(0,0);this.$a.p(0,0);this.ab.p(0,0)};
function Uf(){this.Ud={};this.jf={};Jg(this,Gg,"b2CircleShape","b2CircleShape");Jg(this,Kg,"b2PolygonShape","b2CircleShape");Jg(this,Lg,"b2PolygonShape","b2PolygonShape");Jg(this,Mg,"b2EdgeShape","b2CircleShape");Jg(this,Ng,"b2PolygonShape","b2EdgeShape")}function Jg(a,b,c,d){a.jf[c]=a.jf[c]||{};a.jf[c][d]=a.jf[c][d]||[];a.Ud[c]=a.Ud[c]||{};a.Ud[c][d]=new Og;a.Ud[c][d].tp=b;a.Ud[c][d].ar=m;c!=d&&(a.Ud[d]=a.Ud[d]||{},a.Ud[d][c]=new Og,a.Ud[d][c].tp=b,a.Ud[d][c].ar=q)}
Uf.prototype.ee=function(a,b){var c=a.Cb.jg(),d=b.Cb.jg(),e=this.Ud[c][d],f=e.tp;return f!=p?e.ar?0<this.jf[c][d].length?(c=this.jf[c][d].pop(),c.Pb(a,b),c):new f(a,b):0<this.jf[d][c].length?(c=this.jf[d][c].pop(),c.Pb(b,a),c):new f(b,a):p};Uf.prototype.vc=function(a){this.jf[a.wb.Cb.jg()][a.kb.Cb.jg()].push(a)};function pf(){this.dk=[];for(var a=0;a<=Vf;a++)this.dk[a]=p;this.ek=[];for(a=0;a<=Vf;a++)this.ek[a]=p;this.qg={};this.np=0}pf.prototype.ka=function(a){return this.dk[a]};
pf.prototype.bh=function(a){var b=a.wc;if(this.qg[b]==p){this.qg[b]=[];for(var c=0;c<=Vf;c++)this.qg[b][c]=p;this.fe(a,b,Vf);this.np++}};function Fg(a,b,c,d){c?a.fe(b,b.wc,mg):a.he(b.wc,mg);d?a.fe(b,b.wc,ng):a.he(b.wc,ng)}function Wf(a,b){var c=b.wc;if(a.qg[c]!=p){for(var d=0;d<=Vf;d++)a.he(c,d);delete a.qg[c];a.np--}}pf.prototype.he=function(a,b){var c=this.qg[a];if(c!=p){var d=c[b];if(d!=p){c[b]=p;var c=d.Ad,e=d.next;c==p?this.dk[b]=e:c.Id(e);e==p?this.ek[b]=c:e.Jd(c);Pg.push(d)}}};
pf.prototype.fe=function(a,b,c){b=this.qg[b];if(b[c]==p){if(0<Pg.length){var d=Pg.pop();d.next=p;d.Ad=p;d.Ib=a;a=d}else a=new Qg(a);b[c]=a;a=this.ek[c];a!=p?(a.Id(b[c]),b[c].Jd(a)):this.dk[c]=b[c];this.ek[c]=b[c]}};var mg=0,ng=1,Vf=2;function Qg(a){this.Ib=a;this.Ad=this.next=p}var Pg=[];Qg.prototype.Id=ba("next");Qg.prototype.Jd=ba("Ad");function Og(){this.qx=p;this.rx=0}function Rg(){this.Z=O(0,0);this.Yk=[];this.Q=[];for(var a=0;2>a;a++)this.Q[a]=O(0,0)}
Rg.prototype.Hb=function(a){switch(a.type){case 1:var b=a.t.i.e,c=a.jb,d=a.t.i.position.x+(b.c.x*c.x+b.d.x*c.y),e=a.t.i.position.y+(b.c.y*c.x+b.d.y*c.y),b=a.u.i.e,c=a.nb[0].jb,f=a.u.i.position.x+(b.c.x*c.x+b.d.x*c.y),b=a.u.i.position.y+(b.c.y*c.x+b.d.y*c.y),c=f-d,g=b-e,h=c*c+g*g;h>ee?(h=Math.sqrt(h),this.Z.x=c/h,this.Z.y=g/h):(this.Z.x=1,this.Z.y=0);this.Q[0].x=0.5*(d+f);this.Q[0].y=0.5*(e+b);this.Yk[0]=c*this.Z.x+g*this.Z.y-a.Pn;break;case 2:this.Z.x=a.t.i.e.c.x*a.ve.x+a.t.i.e.d.x*a.ve.y;this.Z.y=
a.t.i.e.c.y*a.ve.x+a.t.i.e.d.y*a.ve.y;d=a.t.i.position.x+(a.t.i.e.c.x*a.jb.x+a.t.i.e.d.x*a.jb.y);e=a.t.i.position.y+(a.t.i.e.c.y*a.jb.x+a.t.i.e.d.y*a.jb.y);for(f=0;f<a.zd;f++)b=a.u.i.position.x+(a.u.i.e.c.x*a.nb[f].jb.x+a.u.i.e.d.x*a.nb[f].jb.y),c=a.u.i.position.y+(a.u.i.e.c.y*a.nb[f].jb.x+a.u.i.e.d.y*a.nb[f].jb.y),this.Yk[f]=(b-d)*this.Z.x+(c-e)*this.Z.y-a.Pn,this.Q[f].x=b,this.Q[f].y=c;break;case 4:this.Z.x=a.u.i.e.c.x*a.ve.x+a.u.i.e.d.x*a.ve.y;this.Z.y=a.u.i.e.c.y*a.ve.x+a.u.i.e.d.y*a.ve.y;d=a.u.i.position.x+
(a.u.i.e.c.x*a.jb.x+a.u.i.e.d.x*a.jb.y);e=a.u.i.position.y+(a.u.i.e.c.y*a.jb.x+a.u.i.e.d.y*a.jb.y);for(f=0;f<a.zd;f++)b=a.t.i.position.x+(a.t.i.e.c.x*a.nb[f].jb.x+a.t.i.e.d.x*a.nb[f].jb.y),c=a.t.i.position.y+(a.t.i.e.c.y*a.nb[f].jb.x+a.t.i.e.d.y*a.nb[f].jb.y),this.Yk[f]=(b-d)*this.Z.x+(c-e)*this.Z.y-a.Pn,this.Q[f].p(b,c);this.Z.x*=-1;this.Z.y*=-1}};function dg(){this.xe=[]}F=dg.prototype;
F.Hb=function(a,b,c){for(this.jj=c;this.xe.length<this.jj;)this.xe[this.xe.length]=new Hg;for(a=0;a<c;a++){var d=b[a],e=d.wb,f=d.kb,g=e.Cb.ra,h=f.Cb.ra,i=e.sa(),j=f.sa(),k=d.dd,n=Math.sqrt(e.Eq*f.Eq),r=e.Xk>f.Xk?e.Xk:f.Xk,s=i.f.x,t=i.f.y,u=j.f.x,w=j.f.y,x=i.j,C=j.j;Sg.Hb(k,i.i,g,j.i,h);f=Sg.Z.x;d=Sg.Z.y;e=this.xe[a];e.t=i;e.u=j;e.Uu=k;e.sc.x=f;e.sc.y=d;e.zd=k.lb;e.rh=n;e.Zh=r;e.ve.x=k.Xb.x;e.ve.y=k.Xb.y;e.jb.x=k.ba.x;e.jb.y=k.ba.y;e.Pn=g+h;e.type=k.K;for(g=0;g<e.zd;++g){n=k.Q[g];h=e.nb[g];h.mb=n.Jg;
h.Ke=n.Ng;h.jb.m(n.ba);var n=h.$a.x=Sg.Q[g].x-i.b.g.x,r=h.$a.y=Sg.Q[g].y-i.b.g.y,B=h.ab.x=Sg.Q[g].x-j.b.g.x,z=h.ab.y=Sg.Q[g].y-j.b.g.y,E=n*d-r*f,A=B*d-z*f,E=E*E,A=A*A;h.qf=1/(i.n+j.n+i.z*E+j.z*A);var I=i.w*i.n+j.w*j.n,I=I+(i.w*i.z*E+j.w*j.z*A);h.jt=1/I;A=d;I=-f;E=n*I-r*A;A=B*I-z*A;E*=E;A*=A;h.Kv=1/(i.n+j.n+i.z*E+j.z*A);h.Ij=0;n=e.sc.x*(u+-C*z-s- -x*r)+e.sc.y*(w+C*B-t-x*n);-1>n&&(h.Ij+=-e.Zh*n)}2==e.zd&&(w=e.nb[0],u=e.nb[1],k=i.n,i=i.z,s=j.n,j=j.z,t=w.$a.x*d-w.$a.y*f,w=w.ab.x*d-w.ab.y*f,x=u.$a.x*d-
u.$a.y*f,u=u.ab.x*d-u.ab.y*f,f=k+s+i*t*t+j*w*w,d=k+s+i*x*x+j*u*u,j=k+s+i*t*x+j*w*u,f*f<100*(f*d-j*j)?(e.Oc.c.p(f,j),e.Oc.d.p(j,d),le(e.Oc,e.qf)):e.zd=1)}};
F.md=function(a){for(var b=0;b<this.jj;++b){var c=this.xe[b],d=c.t,e=c.u,f=d.n,g=d.z,h=e.n,i=e.z,j=c.sc.x,k=c.sc.y,n=k,r=-j,s=0,t=0;if(a.yf){t=c.zd;for(s=0;s<t;++s){var u=c.nb[s];u.mb*=a.Ab;u.Ke*=a.Ab;var w=u.mb*j+u.Ke*n,x=u.mb*k+u.Ke*r;d.j-=g*(u.$a.x*x-u.$a.y*w);d.f.x-=f*w;d.f.y-=f*x;e.j+=i*(u.ab.x*x-u.ab.y*w);e.f.x+=h*w;e.f.y+=h*x}}else{t=c.zd;for(s=0;s<t;++s)d=c.nb[s],d.mb=0,d.Ke=0}}};
F.Wc=function(){for(var a=0;a<this.jj;a++){for(var b=this.xe[a],c=b.sc.x,d=b.sc.y,e=0;e<b.zd;e++){var f=b,g=b.nb[e],h=f.sc.y,i=-f.sc.x,j=f.rh*g.mb,j=S(g.Ke-g.Kv*((f.u.f.x-f.u.j*g.ab.y-f.t.f.x+f.t.j*g.$a.y)*h+(f.u.f.y+f.u.j*g.ab.x-f.t.f.y-f.t.j*g.$a.x)*i),-j,j),k=j-g.Ke,h=k*h,i=k*i;f.t.f.x-=f.t.n*h;f.t.f.y-=f.t.n*i;f.t.j-=f.t.z*(g.$a.x*i-g.$a.y*h);f.u.f.x+=f.u.n*h;f.u.f.y+=f.u.n*i;f.u.j+=f.u.z*(g.ab.x*i-g.ab.y*h);g.Ke=j}if(1==b.zd)e=b.nb[0],f=e.mb-e.qf*((b.u.f.x-b.u.j*e.ab.y-b.t.f.x+b.t.j*e.$a.y)*
c+(b.u.f.y+b.u.j*e.ab.x-b.t.f.y-b.t.j*e.$a.x)*d-e.Ij),f=0<f?f:0,g=f-e.mb,c*=g,d*=g,b.t.f.x-=b.t.n*c,b.t.f.y-=b.t.n*d,b.t.j-=b.t.z*(e.$a.x*d-e.$a.y*c),b.u.f.x+=b.u.n*c,b.u.f.y+=b.u.n*d,b.u.j+=b.u.z*(e.ab.x*d-e.ab.y*c),e.mb=f;else{e=b.nb[0];f=b.nb[1];g=e.mb;i=f.mb;j=(b.u.f.x-b.u.j*e.ab.y-b.t.f.x+b.t.j*e.$a.y)*c+(b.u.f.y+b.u.j*e.ab.x-b.t.f.y-b.t.j*e.$a.x)*d-e.Ij;d=(b.u.f.x-b.u.j*f.ab.y-b.t.f.x+b.t.j*f.$a.y)*c+(b.u.f.y+b.u.j*f.ab.x-b.t.f.y-b.t.j*f.$a.x)*d-f.Ij;j-=b.Oc.c.x*g+b.Oc.d.x*i;for(d-=b.Oc.c.y*
g+b.Oc.d.y*i;;){c=-(b.qf.c.x*j+b.qf.d.x*d);if(0<=c&&(h=-(b.qf.c.y*j+b.qf.d.y*d),0<=h)){Tg(b,e,f,c-g,h-i);e.mb=c;f.mb=h;break}c=-e.qf*j;if(0<=c&&0<=b.Oc.c.y*c+d){Tg(b,e,f,c-g,-i);e.mb=c;f.mb=0;break}c=-f.qf*d;if(0<=c&&0<=b.Oc.d.x*c+j){Tg(b,e,f,-g,c-i);e.mb=0;f.mb=c;break}if(0<=j&&0<=d){Tg(b,e,f,-g,-i);e.mb=0;f.mb=0;break}break}}}};
function Tg(a,b,c,d,e){var f=d*a.sc.x,d=d*a.sc.y,g=e*a.sc.x,e=e*a.sc.y;a.t.f.x-=a.t.n*(f+g);a.t.f.y-=a.t.n*(d+e);a.t.j-=a.t.z*(b.$a.x*d-b.$a.y*f+c.$a.x*e-c.$a.y*g);a.u.f.x+=a.u.n*(f+g);a.u.f.y+=a.u.n*(d+e);a.u.j+=a.u.z*(b.ab.x*d-b.ab.y*f+c.ab.x*e-c.ab.y*g);b.mb=0;c.mb=0}F.Hl=function(){for(var a=0;a<this.jj;++a)for(var b=this.xe[a],c=b.Uu,d=0;d<b.zd;++d){var e=c.Q[d],f=b.nb[d];e.Jg=f.mb;e.Ng=f.Ke}};
F.Vc=function(a){a===l&&(a=0);for(var b=0,c=0;c<this.jj;c++){var d=this.xe[c],e=d.t,f=d.u,g=e.w*e.n,h=e.w*e.z,i=f.w*f.n,j=f.w*f.z;Ug.Hb(d);for(var k=Ug.Z,n=0;n<d.zd;n++){var r=d.nb[n],s=Ug.Q[n],t=Ug.Yk[n],u=s.x-e.b.g.x,w=s.y-e.b.g.y,x=s.x-f.b.g.x,s=s.y-f.b.g.y,b=b<t?b:t,t=-r.jt*S(a*(t+0.005),-0.2,0),r=t*k.x,t=t*k.y;e.b.g.x-=g*r;e.b.g.y-=g*t;e.b.q-=h*(u*t-w*r);W(e);f.b.g.x+=i*r;f.b.g.y+=i*t;f.b.q+=j*(x*t-s*r);W(f)}}return-0.0075<b};function Mg(a,b){X.call(this,a,b)}N(Mg,X);
Mg.prototype.Pb=function(a,b){X.prototype.Pb.call(this,a,b)};Mg.prototype.ge=v();function Kg(a,b){X.call(this,a,b)}N(Kg,X);Kg.prototype.Pb=function(a,b){X.prototype.Pb.call(this,a,b)};
Kg.prototype.ge=function(){a:{var a=this.dd,b=this.wb.Cb,c=this.wb.sa().i,d=this.kb.Cb,e=this.kb.sa().i;a.lb=0;for(var f=e.position.x+(e.e.c.x*d.Aa.x+e.e.d.x*d.Aa.y)-c.position.x,g=e.position.y+(e.e.c.y*d.Aa.x+e.e.d.y*d.Aa.y)-c.position.y,e=f*c.e.c.x+g*c.e.c.y,c=f*c.e.d.x+g*c.e.d.y,f=0,g=-Number.MAX_VALUE,h=b.ra+d.ra,i=0;i<b.wa;++i){var j=b.Ha[i].x*(e-b.s[i].x)+b.Ha[i].y*(c-b.s[i].y);if(j>h)break a;j>g&&(g=j,f=i)}j=f+1;j>=b.wa&&(j=0);var i=b.s[f],k=b.s[j];g<Number.MIN_VALUE?(a.lb=1,a.K=2,a.Xb.m(b.Ha[f]),
a.ba.x=0.5*(i.x+k.x),a.ba.y=0.5*(i.y+k.y),a.Q[0].ba.m(d.Aa),Fe(a.Q[0].wd,0)):0>=(e-i.x)*(k.x-i.x)+(c-i.y)*(k.y-i.y)?(e-i.x)*(e-i.x)+(c-i.y)*(c-i.y)>h*h||(a.lb=1,a.K=2,a.Xb.x=e-i.x,a.Xb.y=c-i.y,we(a.Xb),a.ba.m(i),a.Q[0].ba.m(d.Aa),Fe(a.Q[0].wd,0)):0>=(e-k.x)*(i.x-k.x)+(c-k.y)*(i.y-k.y)?(e-k.x)*(e-k.x)+(c-k.y)*(c-k.y)>h*h||(a.lb=1,a.K=2,a.Xb.x=e-k.x,a.Xb.y=c-k.y,we(a.Xb),a.ba.m(k),a.Q[0].ba.m(d.Aa),Fe(a.Q[0].wd,0)):(j=0.5*(i.x+k.x),i=0.5*(i.y+k.y),g=(e-j)*b.Ha[f].x+(c-i)*b.Ha[f].y,g>h||(a.lb=1,a.K=
2,a.Xb.x=b.Ha[f].x,a.Xb.y=b.Ha[f].y,we(a.Xb),a.ba.p(j,i),a.Q[0].ba.m(d.Aa),Fe(a.Q[0].wd,0)))}};function Ng(a,b){X.call(this,a,b)}N(Ng,X);Ng.prototype.Pb=function(a,b){X.prototype.Pb.call(this,a,b)};Ng.prototype.ge=v();function Lg(a,b){X.call(this,a,b)}N(Lg,X);Lg.prototype.Pb=function(a,b){X.prototype.Pb.call(this,a,b)};
Lg.prototype.ge=function(){var a=this.dd,b=this.wb.Cb,c=this.wb.sa().i,d=this.kb.Cb,e=this.kb.sa().i;a.lb=0;var f=b.ra+d.ra,g=Oe(b,c,d,e),h=g.fp;if(!(g.ml>f)){var i=Oe(d,e,b,c);if(!(i.ml>f)){var j=b,k=d,n=c,r=e,s=0;a.K=2;i.ml>0.98*g.ml+0.001&&(j=d,k=b,n=e,r=c,h=i.fp,a.K=4,s=1);b=h;c=k;d=r;k=Vg;b===l&&(b=0);for(var g=n.e.c.x*j.Ha[b].x+n.e.d.x*j.Ha[b].y,i=n.e.c.y*j.Ha[b].x+n.e.d.y*j.Ha[b].y,e=d.e.c.x*g+d.e.c.y*i,i=d.e.d.x*g+d.e.d.y*i,g=e,e=0,t=Number.MAX_VALUE,u=0;u<c.wa;u++){var w=g*c.Ha[u].x+i*c.Ha[u].y;
w<t&&(t=w,e=u)}g=e+1;g>=c.wa&&(g=0);k[0].hd.x=d.position.x+(d.e.c.x*c.s[e].x+d.e.d.x*c.s[e].y);k[0].hd.y=d.position.y+(d.e.c.y*c.s[e].x+d.e.d.y*c.s[e].y);i=k[0].id;i.Fi=b;i.qb=i.qb&4294967040|i.Fi&255;i=k[0].id;i.Di=e;i.qb=i.qb&4294902015|i.Di<<8&65280;e=k[0].id;e.Ei=0;e.qb=e.qb&4278255615|e.Ei<<16&16711680;k[1].hd.x=d.position.x+(d.e.c.x*c.s[g].x+d.e.d.x*c.s[g].y);k[1].hd.y=d.position.y+(d.e.c.y*c.s[g].x+d.e.d.y*c.s[g].y);c=k[1].id;c.Fi=b;c.qb=c.qb&4294967040|c.Fi&255;b=k[1].id;b.Di=g;b.qb=b.qb&
4294902015|b.Di<<8&65280;b=k[1].id;b.Ei=1;b.qb=b.qb&4278255615|b.Ei<<16&16711680;b=j.s[h];h=h+1<j.wa?j.s[h+1]:j.s[0];Wg.p(h.x-b.x,h.y-b.y);we(Wg);Xg.x=Wg.y;Xg.y=-Wg.x;Yg.p(0.5*(b.x+h.x),0.5*(b.y+h.y));Zg.x=n.e.c.x*Wg.x+n.e.d.x*Wg.y;Zg.y=n.e.c.y*Wg.x+n.e.d.y*Wg.y;$g.x=-Zg.x;$g.y=-Zg.y;ah.x=Zg.y;ah.y=-Zg.x;bh.x=n.position.x+(n.e.c.x*b.x+n.e.d.x*b.y);bh.y=n.position.y+(n.e.c.y*b.x+n.e.d.y*b.y);ch.x=n.position.x+(n.e.c.x*h.x+n.e.d.x*h.y);ch.y=n.position.y+(n.e.c.y*h.x+n.e.d.y*h.y);if(!(2>Me(dh,Vg,$g,
-Zg.x*bh.x-Zg.y*bh.y+f))&&!(2>Me(eh,dh,Zg,Zg.x*ch.x+Zg.y*ch.y+f))){a.Xb.m(Xg);a.ba.m(Yg);n=ah.x*bh.x+ah.y*bh.y;for(j=h=0;2>j;++j)ah.x*eh[j].hd.x+ah.y*eh[j].hd.y-n<=f&&(b=eh[j].hd.x-r.position.x,k=eh[j].hd.y-r.position.y,a.Q[h].ba.x=b*r.e.c.x+k*r.e.c.y,a.Q[h].ba.y=b*r.e.d.x+k*r.e.d.y,a.Q[h].wd.p(eh[j].id),b=a.Q[h].wd,b.Vo=s,b.qb=b.qb&16777215|b.Vo<<24&4278190080,h++);a.lb=h}}}};function fh(){this.wc="Controller"+gh++;this.hc=p;this.Tb=new Gf}fh.prototype.Df=v();
fh.prototype.ah=function(a){this.Tb.ah(a);a.ki(this)};fh.prototype.zi=function(a){this.Tb.zi(a);a.Ai(this)};fh.prototype.Lj=function(){for(var a=this.Tb.ka(Hf);a;a=a.next)this.zi(a.body)};var gh=0;function hh(){fh.call(this);this.sc=O(0,-1);this.oh=this.offset=0;this.Jr=O(0,0);this.zu=2;this.Es=1;this.yx=q;this.Pv=m;this.Mp=p}N(hh,fh);
hh.prototype.Df=function(){this.Pv&&(this.Mp=this.hc.qn.Gb());for(var a=this.Tb.ka(Lf);a;a=a.next){for(var b=a.body,c=O(0,0),d=O(0,0),e=0,f=0,g=b.wg.ka();g;g=g.next){var h=O(0,0),i=g.qd.Cb.Mj(this.sc,this.offset,b.Nc(),h),e=e+i;c.x+=i*h.x;c.y+=i*h.y;var j=0,j=1,f=f+i*j;d.x+=i*h.x*j;d.y+=i*h.y*j}e<Number.MIN_VALUE||(c.x/=e,c.y/=e,d.x/=f,d.y/=f,f=this.Mp.Cf(),f.Hc(this.oh*e),b.Ne(f,d),f=O(b.f.x-b.j*(c.y-b.b.g.y),b.f.y+b.j*(c.x-b.b.g.x)),f.Uo(this.Jr),f.Hc(-this.zu*e),b.Ne(f,c),b.El(-b.td/b.w*e*b.j*
this.Es),T(c),T(d))}};function ih(){fh.call(this);this.Do=O(0,0)}N(ih,fh);ih.prototype.Df=function(a){for(var a=O(this.Do.x*a.fa,this.Do.y*a.fa),b=this.Tb.ka(Lf);b;b=b.next){var c=b.body,d=c.f;zf(c,O(d.x+a.x,d.y+a.y))}T(a)};function jh(){fh.call(this);this.Qr=O(0,0)}N(jh,fh);jh.prototype.Df=function(){for(var a=this.Tb.ka(Lf);a;a=a.next){var b=a.body;b.Ne(this.Qr,b.b.g)}};function qf(){this.hm=this.gm=p;this.fk={};this.pp=0}qf.prototype.ka=y("gm");
qf.prototype.ki=function(a){var b=a.wc;if(this.fk[b]==p){var a=new kh(a),c=this.hm;c!=p?c.Id(a):this.gm=a;a.Jd(c);this.hm=a;this.fk[b]=a;this.pp++}};qf.prototype.Ai=function(a){var a=a.wc,b=this.fk[a];if(b!=p){var c=b.Ad,b=b.next;c==p?this.gm=b:c.Id(b);b==p?this.hm=c:b.Jd(c);delete this.fk[a];this.pp--}};function kh(a){this.op=a;this.Ad=this.next=p}kh.prototype.Id=ba("next");kh.prototype.Jd=ba("Ad");function lh(){fh.call(this);this.Ho=1;this.qu=m}N(lh,fh);
lh.prototype.Df=function(){var a=p,b=p,c=0,d=p,e=p,f=0,g=0,h=0,f=p;if(this.qu)for(var i=this.Tb.ka(Hf);i;i=i.next)for(var a=i.body,b=a.b.g,c=a.w,j=this.Tb.ka(Hf);j;j=j.next){if(d=j.body,a.fc||d.fc)e=d.b.g,f=e.x-b.x,g=e.y-b.y,h=f*f+g*g,h<Number.MIN_VALUE||(f=O(f,g),f.Hc(this.Ho/h/Math.sqrt(h)*c*d.w),a.fc&&a.Ne(f,b),f.Hc(-1),d.fc&&d.Ne(f,e),T(f))}else for(i=this.Tb.ka(Hf);i;i=i.next){a=bodyNode.body;b=a.b.g;c=a.w;for(j=this.Tb.ka(Hf);j;j=j.next)if(d=bodyNode.body,a.fc||d.fc)e=d.b.g,f=e.x-b.x,g=e.y-
b.y,h=f*f+g*g,h<Number.MIN_VALUE||(f=O(f,g),f.Hc(this.Ho/h*c*d.w),a.fc&&a.Ne(f,b),f.Hc(-1),d.fc&&d.Ne(f,e),T(f))}};function mh(){fh.call(this);this.ts=new je;this.Bn=0}N(mh,fh);mh.prototype.Df=function(a){a=a.fa;if(!(a<=Number.MIN_VALUE)){a>this.Bn&&0<this.Bn&&(a=this.Bn);for(var b=this.Tb.ka(Lf);b;b=b.next){var c=b.body,d;d=P(this.ts,ie(c.i.e,c.f));d=P(c.i.e,d);zf(c,O(c.f.x+d.x*a,c.f.y+d.y*a))}}};
function Y(a){this.Cc=new nh;this.Dc=new nh;this.Ae=O(0,0);this.Be=O(0,0);this.K=a.type;this.Qf=this.Nh=p;this.B=a.t;this.D=a.u;this.Bq=a.em}F=Y.prototype;F.kg=function(){return this.B.kg()&&this.D.kg()};F.md=v();F.Wc=v();F.Hl=v();F.Vc=D(q);function Z(){this.type=0;this.u=this.t=p;this.em=q}function nh(){}function oh(a){Y.call(this,a);this.I=O(0,0);this.J=O(0,0);this.Db=O(0,0);this.I.m(a.ub);this.J.m(a.vb);this.rn=a.length;this.pn=a.Am;this.Fu=a.nm;this.Aq=this.Ig=this.h=0}N(oh,Y);
oh.prototype.md=function(a){var b,c=0,d=this.B,e=this.D;b=d.i.e;var f=this.I.x-d.b.r.x,g=this.I.y-d.b.r.y,c=b.c.x*f+b.d.x*g,g=b.c.y*f+b.d.y*g,f=c;b=e.i.e;var h=this.J.x-e.b.r.x,i=this.J.y-e.b.r.y,c=b.c.x*h+b.d.x*i,i=b.c.y*h+b.d.y*i,h=c;this.Db.x=e.b.g.x+h-d.b.g.x-f;this.Db.y=e.b.g.y+i-d.b.g.y-g;c=Math.sqrt(this.Db.x*this.Db.x+this.Db.y*this.Db.y);0.005<c?this.Db.Hc(1/c):this.Db.S();b=f*this.Db.y-g*this.Db.x;var j=h*this.Db.y-i*this.Db.x;b=d.n+d.z*b*b+e.n+e.z*j*j;this.w=0!=b?1/b:0;if(0<this.pn){var c=
c-this.rn,j=2*Math.PI*this.pn,k=this.w*j*j;this.Ig=a.fa*(2*this.w*this.Fu*j+a.fa*k);this.Ig=0!=this.Ig?1/this.Ig:0;this.Aq=c*a.fa*k*this.Ig;this.w=b+this.Ig;this.w=0!=this.w?1/this.w:0}a.yf?(this.h*=a.Ab,a=this.h*this.Db.x,b=this.h*this.Db.y,d.f.x-=d.n*a,d.f.y-=d.n*b,d.j-=d.z*(f*b-g*a),e.f.x+=e.n*a,e.f.y+=e.n*b,e.j+=e.z*(h*b-i*a)):this.h=0};
oh.prototype.Wc=function(){var a=this.I.x-this.B.b.r.x,b=this.I.y-this.B.b.r.y,c=this.B.i.e.c.x*a+this.B.i.e.d.x*b,b=this.B.i.e.c.y*a+this.B.i.e.d.y*b,a=c,d=this.J.x-this.D.b.r.x,e=this.J.y-this.D.b.r.y,c=this.D.i.e.c.x*d+this.D.i.e.d.x*e,e=this.D.i.e.c.y*d+this.D.i.e.d.y*e,d=c,f=-this.w*(this.Db.x*(this.D.f.x-this.D.j*e-(this.B.f.x-this.B.j*b))+this.Db.y*(this.D.f.y+this.D.j*d-(this.B.f.y+this.B.j*a))+this.Aq+this.Ig*this.h);this.h+=f;c=f*this.Db.x;f*=this.Db.y;this.B.f.x-=this.B.n*c;this.B.f.y-=
this.B.n*f;this.B.j-=this.B.z*(a*f-b*c);this.D.f.x+=this.D.n*c;this.D.f.y+=this.D.n*f;this.D.j+=this.D.z*(d*f-e*c)};
oh.prototype.Vc=function(){if(0<this.pn)return m;var a=this.I.x-this.B.b.r.x,b=this.I.y-this.B.b.r.y,c=this.B.i.e.c.x*a+this.B.i.e.d.x*b,b=this.B.i.e.c.y*a+this.B.i.e.d.y*b,a=c,d=this.J.x-this.D.b.r.x,e=this.J.y-this.D.b.r.y,c=this.D.i.e.c.x*d+this.D.i.e.d.x*e,e=this.D.i.e.c.y*d+this.D.i.e.d.y*e,d=c,f=this.D.b.g.x+d-this.B.b.g.x-a,g=this.D.b.g.y+e-this.B.b.g.y-b,h=Math.sqrt(f*f+g*g),c=S(h-this.rn,-0.2,0.2),i=-this.w*c;this.Db.p(f/h,g/h);f=i*this.Db.x;i*=this.Db.y;this.B.b.g.x-=this.B.n*f;this.B.b.g.y-=
this.B.n*i;this.B.b.q-=this.B.z*(a*i-b*f);this.D.b.g.x+=this.D.n*f;this.D.b.g.y+=this.D.n*i;this.D.b.q+=this.D.z*(d*i-e*f);W(this.B);W(this.D);return 0.005>Math.abs(c)};function ph(){Z.call(this);this.ub=O(0,0);this.vb=O(0,0);this.type=3;this.length=1;this.nm=this.Am=0}N(ph,Z);ph.prototype.Hb=function(a,b,c,d){this.t=a;this.u=b;this.ub.m(Bf(this.t,c));this.vb.m(Bf(this.u,d));a=d.x-c.x;c=d.y-c.y;this.length=Math.sqrt(a*a+c*c);this.nm=this.Am=0};ph.prototype.ee=function(){return new oh(this)};
function qh(a){Y.call(this,a);this.ad=O(0,0);this.bd=O(0,0);this.un=new je;this.$c=O(0,0);this.ad.m(a.ub);this.bd.m(a.vb);this.un.S();this.ij=0;this.$c.S();this.ff=0;this.Pu=a.Vu;this.Ru=a.Xu}N(qh,Y);
qh.prototype.md=function(a){var b,c=0,d=this.B,e=this.D;b=d.i.e;var f=this.ad.x-d.b.r.x,g=this.ad.y-d.b.r.y,c=b.c.x*f+b.d.x*g,g=b.c.y*f+b.d.y*g,f=c;b=e.i.e;var h=this.bd.x-e.b.r.x,i=this.bd.y-e.b.r.y,c=b.c.x*h+b.d.x*i,i=b.c.y*h+b.d.y*i,h=c;b=d.n;var c=e.n,j=d.z,k=e.z,n=new je;n.c.x=b+c;n.d.x=0;n.c.y=0;n.d.y=b+c;n.c.x+=j*g*g;n.d.x+=-j*f*g;n.c.y+=-j*f*g;n.d.y+=j*f*f;n.c.x+=k*i*i;n.d.x+=-k*h*i;n.c.y+=-k*h*i;n.d.y+=k*h*h;le(n,this.un);this.ij=j+k;0<this.ij&&(this.ij=1/this.ij);a.yf?(this.$c.x*=a.Ab,this.$c.y*=
a.Ab,this.ff*=a.Ab,a=this.$c,d.f.x-=b*a.x,d.f.y-=b*a.y,d.j-=j*(f*a.y-g*a.x+this.ff),e.f.x+=c*a.x,e.f.y+=c*a.y,e.j+=k*(h*a.y-i*a.x+this.ff)):(this.$c.S(),this.ff=0)};
qh.prototype.Wc=function(a){var b,c=0,d=this.B,e=this.D,f=d.f,g=d.j,h=e.f,i=e.j,j=d.n,k=e.n,n=d.z,r=e.z;b=d.i.e;var s=this.ad.x-d.b.r.x,t=this.ad.y-d.b.r.y,c=b.c.x*s+b.d.x*t,t=b.c.y*s+b.d.y*t,s=c;b=e.i.e;var u=this.bd.x-e.b.r.x,w=this.bd.y-e.b.r.y,c=b.c.x*u+b.d.x*w,w=b.c.y*u+b.d.y*w,u=c;b=0;var c=-this.ij*(i-g),x=this.ff;b=a.fa*this.Ru;this.ff=S(this.ff+c,-b,b);c=this.ff-x;g-=n*c;i+=r*c;b=P(this.un,O(-(h.x-i*w-f.x+g*t),-(h.y+i*u-f.y-g*s)));c=this.$c.Gb();this.$c.Af(b);b=a.fa*this.Pu;ve(this.$c)>b*
b&&(we(this.$c),this.$c.Hc(b));b=R(this.$c,c);f.x-=j*b.x;f.y-=j*b.y;g-=n*(s*b.y-t*b.x);h.x+=k*b.x;h.y+=k*b.y;i+=r*(u*b.y-w*b.x);d.j=g;e.j=i};qh.prototype.Vc=D(m);function rh(){Z.call(this);this.ub=O(0,0);this.vb=O(0,0);this.type=9;this.Xu=this.Vu=0}N(rh,Z);rh.prototype.Hb=function(a,b,c){this.t=a;this.u=b;this.ub.m(Bf(this.t,c));this.vb.m(Bf(this.u,c))};rh.prototype.ee=function(){return new qh(this)};
function sh(a){Y.call(this,a);this.kf=O(0,0);this.lf=O(0,0);this.I=O(0,0);this.J=O(0,0);this.Ua=new th;var b=a.yh.K,c=a.zh.K;this.Ph=this.Mg=this.Oh=this.Lg=p;var d=0,e=0;this.Hu=a.yh.B;this.B=a.yh.D;1==b?(this.Lg=a.yh,this.kf.m(this.Lg.I),this.I.m(this.Lg.J),d=uh(this.Lg)):(this.Oh=a.yh,this.kf.m(this.Oh.I),this.I.m(this.Oh.J),d=this.Oh.ri());this.Iu=a.zh.B;this.D=a.zh.D;1==c?(this.Mg=a.zh,this.lf.m(this.Mg.I),this.J.m(this.Mg.J),e=uh(this.Mg)):(this.Ph=a.zh,this.lf.m(this.Ph.I),this.J.m(this.Ph.J),
e=this.Ph.ri());this.Za=a.Bd;this.Mh=d+this.Za*e;this.h=0}N(sh,Y);
sh.prototype.md=function(a){var b=this.Hu,c=this.Iu,d=this.B,e=this.D,f=0,g=0,h=0,i=0,j=h=0,k=0;this.Ua.S();this.Lg?(this.Ua.ng=-1,k+=d.z):(b=b.i.e,g=this.Oh.Kc,f=b.c.x*g.x+b.d.x*g.y,g=b.c.y*g.x+b.d.y*g.y,b=d.i.e,h=this.I.x-d.b.r.x,i=this.I.y-d.b.r.y,j=b.c.x*h+b.d.x*i,i=b.c.y*h+b.d.y*i,h=j*g-i*f,this.Ua.Qd.p(-f,-g),this.Ua.ng=-h,k+=d.n+d.z*h*h);this.Mg?(this.Ua.og=-this.Za,k+=this.Za*this.Za*e.z):(b=c.i.e,g=this.Ph.Kc,f=b.c.x*g.x+b.d.x*g.y,g=b.c.y*g.x+b.d.y*g.y,b=e.i.e,h=this.J.x-e.b.r.x,i=this.J.y-
e.b.r.y,j=b.c.x*h+b.d.x*i,i=b.c.y*h+b.d.y*i,h=j*g-i*f,this.Ua.Rd.p(-this.Za*f,-this.Za*g),this.Ua.og=-this.Za*h,k+=this.Za*this.Za*(e.n+e.z*h*h));this.w=0<k?1/k:0;a.yf?(d.f.x+=d.n*this.h*this.Ua.Qd.x,d.f.y+=d.n*this.h*this.Ua.Qd.y,d.j+=d.z*this.h*this.Ua.ng,e.f.x+=e.n*this.h*this.Ua.Rd.x,e.f.y+=e.n*this.h*this.Ua.Rd.y,e.j+=e.z*this.h*this.Ua.og):this.h=0};
sh.prototype.Wc=function(){var a=this.B,b=this.D,c=this.Ua,d=a.f,e=a.j,f=b.f,g=b.j;e===l&&(e=0);g===l&&(g=0);c=-this.w*(c.Qd.x*d.x+c.Qd.y*d.y+c.ng*e+(c.Rd.x*f.x+c.Rd.y*f.y)+c.og*g);this.h+=c;a.f.x+=a.n*c*this.Ua.Qd.x;a.f.y+=a.n*c*this.Ua.Qd.y;a.j+=a.z*c*this.Ua.ng;b.f.x+=b.n*c*this.Ua.Rd.x;b.f.y+=b.n*c*this.Ua.Rd.y;b.j+=b.z*c*this.Ua.og};
sh.prototype.Vc=function(){var a=this.B,b=this.D,c=0,d=0,c=this.Lg?uh(this.Lg):this.Oh.ri(),d=this.Mg?uh(this.Mg):this.Ph.ri(),c=-this.w*(this.Mh-(c+this.Za*d));a.b.g.x+=a.n*c*this.Ua.Qd.x;a.b.g.y+=a.n*c*this.Ua.Qd.y;a.b.q+=a.z*c*this.Ua.ng;b.b.g.x+=b.n*c*this.Ua.Rd.x;b.b.g.y+=b.n*c*this.Ua.Rd.y;b.b.q+=b.z*c*this.Ua.og;W(a);W(b);return m};function vh(){Z.call(this);this.type=6;this.zh=this.yh=p;this.Bd=1}N(vh,Z);vh.prototype.Hb=function(a,b,c){this.yh=a;this.t=a.B;this.zh=b;this.u=b.B;this.Bd=c};
vh.prototype.ee=function(){return new sh(this)};function th(){this.Qd=O(0,0);this.Rd=O(0,0)}th.prototype.S=function(){this.Qd.S();this.ng=0;this.Rd.S();this.og=0};th.prototype.p=function(a,b,c,d){b===l&&(b=0);d===l&&(d=0);this.Qd.m(a);this.ng=b;this.Rd.m(c);this.og=d};
function wh(a){Y.call(this,a);this.I=O(0,0);this.J=O(0,0);this.Kc=O(0,0);this.mf=O(0,0);this.A=O(0,0);this.M=O(0,0);this.H=new je;this.h=O(0,0);this.I.m(a.ub);this.J.m(a.vb);this.Kc.m(a.Eg);this.mf.x=-this.Kc.y;this.mf.y=this.Kc.x;this.h.S();this.oa=this.Ec=0;this.cd=a.jn;this.ed=a.xo;this.vn=a.An;this.nj=a.tj;this.Td=a.ph;this.Pf=a.Si;this.ca=0;this.A.S();this.M.S()}N(wh,Y);
wh.prototype.ri=function(){var a=this.B,b=this.D,c=Af(a,this.I),d=Af(b,this.J),b=d.x-c.x,c=d.y-c.y,a=P(a.i.e,this.Kc);return a.x*b+a.y*c};
wh.prototype.md=function(a){var b=this.B,c=this.D,d,e=0;this.Ae.m(b.b.r);this.Be.m(c.b.r);var f=b.Nc();c.Nc();d=b.i.e;var g=this.I.x-this.Ae.x,h=this.I.y-this.Ae.y,e=d.c.x*g+d.d.x*h,h=d.c.y*g+d.d.y*h,g=e;d=c.i.e;var i=this.J.x-this.Be.x,j=this.J.y-this.Be.y,e=d.c.x*i+d.d.x*j,j=d.c.y*i+d.d.y*j,i=e;d=c.b.g.x+i-b.b.g.x-g;e=c.b.g.y+j-b.b.g.y-h;this.Wa=b.n;this.Xa=c.n;this.qc=b.z;this.rc=c.z;this.A.m(P(f.e,this.Kc));this.ua=(d+g)*this.A.y-(e+h)*this.A.x;this.va=i*this.A.y-j*this.A.x;this.Ec=this.Wa+this.Xa+
this.qc*this.ua*this.ua+this.rc*this.va*this.va;this.Ec=this.Ec>Number.MIN_VALUE?1/this.Ec:0;this.M.m(P(f.e,this.mf));this.xa=(d+g)*this.M.y-(e+h)*this.M.x;this.ya=i*this.M.y-j*this.M.x;f=this.Wa;g=this.Xa;h=this.qc;i=this.rc;this.H.c.x=f+g+h*this.xa*this.xa+i*this.ya*this.ya;this.H.c.y=h*this.xa*this.ua+i*this.ya*this.va;this.H.d.x=this.H.c.y;this.H.d.y=f+g+h*this.ua*this.ua+i*this.va*this.va;this.Td?(d=this.A.x*d+this.A.y*e,0.01>Math.abs(this.ed-this.cd)?this.ca=3:d<=this.cd?1!=this.ca&&(this.ca=
1,this.h.y=0):d>=this.ed?2!=this.ca&&(this.ca=2,this.h.y=0):(this.ca=0,this.h.y=0)):this.ca=0;this.Pf==q&&(this.oa=0);a.yf?(this.h.x*=a.Ab,this.h.y*=a.Ab,this.oa*=a.Ab,a=this.h.x*this.M.x+(this.oa+this.h.y)*this.A.x,d=this.h.x*this.M.y+(this.oa+this.h.y)*this.A.y,e=this.h.x*this.xa+(this.oa+this.h.y)*this.ua,f=this.h.x*this.ya+(this.oa+this.h.y)*this.va,b.f.x-=this.Wa*a,b.f.y-=this.Wa*d,b.j-=this.qc*e,c.f.x+=this.Xa*a,c.f.y+=this.Xa*d,c.j+=this.rc*f):(this.h.S(),this.oa=0)};
wh.prototype.Wc=function(a){var b=this.B,c=this.D,d=b.f,e=b.j,f=c.f,g=c.j,h=0,i=0,j=0,k=0;this.Pf&&3!=this.ca&&(k=this.Ec*(this.nj-(this.A.x*(f.x-d.x)+this.A.y*(f.y-d.y)+this.va*g-this.ua*e)),h=this.oa,i=a.fa*this.vn,this.oa=S(this.oa+k,-i,i),k=this.oa-h,h=k*this.A.x,i=k*this.A.y,j=k*this.ua,k*=this.va,d.x-=this.Wa*h,d.y-=this.Wa*i,e-=this.qc*j,f.x+=this.Xa*h,f.y+=this.Xa*i,g+=this.rc*k);i=this.M.x*(f.x-d.x)+this.M.y*(f.y-d.y)+this.ya*g-this.xa*e;this.Td&&0!=this.ca?(j=this.A.x*(f.x-d.x)+this.A.y*
(f.y-d.y)+this.va*g-this.ua*e,h=this.h.Gb(),a=this.H.lg(O(0,0),-i,-j),this.h.Af(a),1==this.ca?this.h.y=Math.max(this.h.y,0):2==this.ca&&(this.h.y=Math.min(this.h.y,0)),i=-i-(this.h.y-h.y)*this.H.d.x,j=0,j=0!=this.H.c.x?i/this.H.c.x+h.x:h.x,this.h.x=j,a.x=this.h.x-h.x,a.y=this.h.y-h.y,h=a.x*this.M.x+a.y*this.A.x,i=a.x*this.M.y+a.y*this.A.y,j=a.x*this.xa+a.y*this.ua,k=a.x*this.ya+a.y*this.va):(a=0,a=0!=this.H.c.x?-i/this.H.c.x:0,this.h.x+=a,h=a*this.M.x,i=a*this.M.y,j=a*this.xa,k=a*this.ya);d.x-=this.Wa*
h;d.y-=this.Wa*i;e-=this.qc*j;f.x+=this.Xa*h;f.y+=this.Xa*i;g+=this.rc*k;b.f.m(d);b.j=e;c.f.m(f);c.j=g};
wh.prototype.Vc=function(){var a=this.B,b=this.D,c=a.b.g,d=a.b.q,e=b.b.g,f=b.b.q,g,h=0,i=0,j=0,k=0,n=g=0,r=0,i=q,s=0,t=ke(d),j=ke(f);g=t;var r=this.I.x-this.Ae.x,u=this.I.y-this.Ae.y,h=g.c.x*r+g.d.x*u,u=g.c.y*r+g.d.y*u,r=h;g=j;j=this.J.x-this.Be.x;k=this.J.y-this.Be.y;h=g.c.x*j+g.d.x*k;k=g.c.y*j+g.d.y*k;j=h;g=e.x+j-c.x-r;h=e.y+k-c.y-u;if(this.Td){this.A=P(t,this.Kc);this.ua=(g+r)*this.A.y-(h+u)*this.A.x;this.va=j*this.A.y-k*this.A.x;var w=this.A.x*g+this.A.y*h;0.01>Math.abs(this.ed-this.cd)?(s=S(w,
-0.2,0.2),n=Math.abs(w),i=m):w<=this.cd?(s=S(w-this.cd+0.005,-0.2,0),n=this.cd-w,i=m):w>=this.ed&&(s=S(w-this.ed+0.005,0,0.2),n=w-this.ed,i=m)}this.M=P(t,this.mf);this.xa=(g+r)*this.M.y-(h+u)*this.M.x;this.ya=j*this.M.y-k*this.M.x;t=O(0,0);u=this.M.x*g+this.M.y*h;n=Math.max(n,Math.abs(u));r=0;i?(i=this.Wa,j=this.Xa,k=this.qc,g=this.rc,this.H.c.x=i+j+k*this.xa*this.xa+g*this.ya*this.ya,this.H.c.y=k*this.xa*this.ua+g*this.ya*this.va,this.H.d.x=this.H.c.y,this.H.d.y=i+j+k*this.ua*this.ua+g*this.va*this.va,
this.H.lg(t,-u,-s)):(i=this.Wa,j=this.Xa,k=this.qc,g=this.rc,s=i+j+k*this.xa*this.xa+g*this.ya*this.ya,t.x=0!=s?-u/s:0,t.y=0);s=t.x*this.M.x+t.y*this.A.x;i=t.x*this.M.y+t.y*this.A.y;u=t.x*this.xa+t.y*this.ua;t=t.x*this.ya+t.y*this.va;c.x-=this.Wa*s;c.y-=this.Wa*i;d-=this.qc*u;e.x+=this.Xa*s;e.y+=this.Xa*i;f+=this.rc*t;a.b.q=d;b.b.q=f;W(a);W(b);return 0.005>=n&&r<=$d};
function xh(){Z.call(this);this.ub=O(0,0);this.vb=O(0,0);this.Eg=O(0,0);this.type=7;this.Eg.p(1,0);this.ph=q;this.xo=this.jn=0;this.Si=q;this.tj=this.An=0}N(xh,Z);xh.prototype.Hb=function(a,b,c,d){this.t=a;this.u=b;this.ub=Bf(this.t,c);this.vb=Bf(this.u,c);this.Eg=ie(this.t.i.e,d)};xh.prototype.ee=function(){return new wh(this)};
function yh(a){Y.call(this,a);this.I=O(0,0);this.J=O(0,0);this.Kc=O(0,0);this.mf=O(0,0);this.A=O(0,0);this.M=O(0,0);this.H=new me;this.h=new ne(0,0,0);this.I.m(a.ub);this.J.m(a.vb);this.Kc.m(a.Eg);this.mf.x=-this.Kc.y;this.mf.y=this.Kc.x;this.Su=a.Zf;this.h.S();this.oa=this.Ec=0;this.cd=a.jn;this.ed=a.xo;this.vn=a.An;this.nj=a.tj;this.Td=a.ph;this.Pf=a.Si;this.ca=0;this.A.S();this.M.S()}N(yh,Y);
yh.prototype.ri=function(){var a=this.B,b=this.D,c=Af(a,this.I),d=Af(b,this.J),b=d.x-c.x,c=d.y-c.y,a=P(a.i.e,this.Kc);return a.x*b+a.y*c};
yh.prototype.md=function(a){var b=this.B,c=this.D,d,e=0;this.Ae.m(b.b.r);this.Be.m(c.b.r);var f=b.Nc();c.Nc();d=b.i.e;var g=this.I.x-this.Ae.x,h=this.I.y-this.Ae.y,e=d.c.x*g+d.d.x*h,h=d.c.y*g+d.d.y*h,g=e;d=c.i.e;var i=this.J.x-this.Be.x,j=this.J.y-this.Be.y,e=d.c.x*i+d.d.x*j,j=d.c.y*i+d.d.y*j,i=e;d=c.b.g.x+i-b.b.g.x-g;e=c.b.g.y+j-b.b.g.y-h;this.Wa=b.n;this.Xa=c.n;this.qc=b.z;this.rc=c.z;this.A.m(P(f.e,this.Kc));this.ua=(d+g)*this.A.y-(e+h)*this.A.x;this.va=i*this.A.y-j*this.A.x;this.Ec=this.Wa+this.Xa+
this.qc*this.ua*this.ua+this.rc*this.va*this.va;this.Ec>Number.MIN_VALUE&&(this.Ec=1/this.Ec);this.M.m(P(f.e,this.mf));this.xa=(d+g)*this.M.y-(e+h)*this.M.x;this.ya=i*this.M.y-j*this.M.x;f=this.Wa;g=this.Xa;h=this.qc;i=this.rc;this.H.c.x=f+g+h*this.xa*this.xa+i*this.ya*this.ya;this.H.c.y=h*this.xa+i*this.ya;this.H.c.o=h*this.xa*this.ua+i*this.ya*this.va;this.H.d.x=this.H.c.y;this.H.d.y=h+i;this.H.d.o=h*this.ua+i*this.va;this.H.aa.x=this.H.c.o;this.H.aa.y=this.H.d.o;this.H.aa.o=f+g+h*this.ua*this.ua+
i*this.va*this.va;this.Td?(d=this.A.x*d+this.A.y*e,0.01>Math.abs(this.ed-this.cd)?this.ca=3:d<=this.cd?1!=this.ca&&(this.ca=1,this.h.o=0):d>=this.ed?2!=this.ca&&(this.ca=2,this.h.o=0):(this.ca=0,this.h.o=0)):this.ca=0;this.Pf==q&&(this.oa=0);a.yf?(this.h.x*=a.Ab,this.h.y*=a.Ab,this.oa*=a.Ab,a=this.h.x*this.M.x+(this.oa+this.h.o)*this.A.x,d=this.h.x*this.M.y+(this.oa+this.h.o)*this.A.y,e=this.h.x*this.xa+this.h.y+(this.oa+this.h.o)*this.ua,f=this.h.x*this.ya+this.h.y+(this.oa+this.h.o)*this.va,b.f.x-=
this.Wa*a,b.f.y-=this.Wa*d,b.j-=this.qc*e,c.f.x+=this.Xa*a,c.f.y+=this.Xa*d,c.j+=this.rc*f):(this.h.S(),this.oa=0)};
yh.prototype.Wc=function(a){var b=this.B,c=this.D,d=b.f,e=b.j,f=c.f,g=c.j,h=0,i=0,j=0,k=0;this.Pf&&3!=this.ca&&(k=this.Ec*(this.nj-(this.A.x*(f.x-d.x)+this.A.y*(f.y-d.y)+this.va*g-this.ua*e)),h=this.oa,a=a.fa*this.vn,this.oa=S(this.oa+k,-a,a),k=this.oa-h,h=k*this.A.x,i=k*this.A.y,j=k*this.ua,k*=this.va,d.x-=this.Wa*h,d.y-=this.Wa*i,e-=this.qc*j,f.x+=this.Xa*h,f.y+=this.Xa*i,g+=this.rc*k);j=this.M.x*(f.x-d.x)+this.M.y*(f.y-d.y)+this.ya*g-this.xa*e;i=g-e;this.Td&&0!=this.ca?(a=this.A.x*(f.x-d.x)+this.A.y*
(f.y-d.y)+this.va*g-this.ua*e,h=this.h.Gb(),a=pe(this.H,new ne(0,0,0),-j,-i,-a),this.h.Af(a),1==this.ca?this.h.o=Math.max(this.h.o,0):2==this.ca&&(this.h.o=Math.min(this.h.o,0)),j=-j-(this.h.o-h.o)*this.H.aa.x,i=-i-(this.h.o-h.o)*this.H.aa.y,i=oe(this.H,O(0,0),j,i),i.x+=h.x,i.y+=h.y,this.h.x=i.x,this.h.y=i.y,a.x=this.h.x-h.x,a.y=this.h.y-h.y,a.o=this.h.o-h.o,h=a.x*this.M.x+a.o*this.A.x,i=a.x*this.M.y+a.o*this.A.y,j=a.x*this.xa+a.y+a.o*this.ua,k=a.x*this.ya+a.y+a.o*this.va):(a=oe(this.H,O(0,0),-j,
-i),this.h.x+=a.x,this.h.y+=a.y,h=a.x*this.M.x,i=a.x*this.M.y,j=a.x*this.xa+a.y,k=a.x*this.ya+a.y);d.x-=this.Wa*h;d.y-=this.Wa*i;e-=this.qc*j;f.x+=this.Xa*h;f.y+=this.Xa*i;g+=this.rc*k;b.f.m(d);b.j=e;c.f.m(f);c.j=g};
yh.prototype.Vc=function(){var a=this.B,b=this.D,c=a.b.g,d=a.b.q,e=b.b.g,f=b.b.q,g,h=0,i=0,j=0,k=h=g=0,n=0,i=q,r=0,s=ke(d),t=ke(f);g=s;var n=this.I.x-this.Ae.x,u=this.I.y-this.Ae.y,h=g.c.x*n+g.d.x*u,u=g.c.y*n+g.d.y*u,n=h;g=t;t=this.J.x-this.Be.x;j=this.J.y-this.Be.y;h=g.c.x*t+g.d.x*j;j=g.c.y*t+g.d.y*j;t=h;g=e.x+t-c.x-n;h=e.y+j-c.y-u;if(this.Td){this.A=P(s,this.Kc);this.ua=(g+n)*this.A.y-(h+u)*this.A.x;this.va=t*this.A.y-j*this.A.x;var w=this.A.x*g+this.A.y*h;0.01>Math.abs(this.ed-this.cd)?(r=S(w,
-0.2,0.2),k=Math.abs(w),i=m):w<=this.cd?(r=S(w-this.cd+0.005,-0.2,0),k=this.cd-w,i=m):w>=this.ed&&(r=S(w-this.ed+0.005,0,0.2),k=w-this.ed,i=m)}this.M=P(s,this.mf);this.xa=(g+n)*this.M.y-(h+u)*this.M.x;this.ya=t*this.M.y-j*this.M.x;s=new ne(0,0,0);u=this.M.x*g+this.M.y*h;t=f-d-this.Su;k=Math.max(k,Math.abs(u));n=Math.abs(t);i?(i=this.Wa,j=this.Xa,g=this.qc,h=this.rc,this.H.c.x=i+j+g*this.xa*this.xa+h*this.ya*this.ya,this.H.c.y=g*this.xa+h*this.ya,this.H.c.o=g*this.xa*this.ua+h*this.ya*this.va,this.H.d.x=
this.H.c.y,this.H.d.y=g+h,this.H.d.o=g*this.ua+h*this.va,this.H.aa.x=this.H.c.o,this.H.aa.y=this.H.d.o,this.H.aa.o=i+j+g*this.ua*this.ua+h*this.va*this.va,pe(this.H,s,-u,-t,-r)):(i=this.Wa,j=this.Xa,g=this.qc,h=this.rc,r=g*this.xa+h*this.ya,w=g+h,this.H.c.p(i+j+g*this.xa*this.xa+h*this.ya*this.ya,r,0),this.H.d.p(r,w,0),r=oe(this.H,O(0,0),-u,-t),s.x=r.x,s.y=r.y,s.o=0);r=s.x*this.M.x+s.o*this.A.x;i=s.x*this.M.y+s.o*this.A.y;u=s.x*this.xa+s.y+s.o*this.ua;s=s.x*this.ya+s.y+s.o*this.va;c.x-=this.Wa*r;
c.y-=this.Wa*i;d-=this.qc*u;e.x+=this.Xa*r;e.y+=this.Xa*i;f+=this.rc*s;a.b.q=d;b.b.q=f;W(a);W(b);return 0.005>=k&&n<=$d};function zh(){Z.call(this);this.ub=O(0,0);this.vb=O(0,0);this.Eg=O(0,0);this.type=2;this.Eg.p(1,0);this.Zf=0;this.ph=q;this.xo=this.jn=0;this.Si=q;this.tj=this.An=0}N(zh,Z);zh.prototype.Hb=function(a,b,c,d){this.t=a;this.u=b;this.ub=Bf(this.t,c);this.vb=Bf(this.u,c);this.Eg=ie(this.t.i.e,d);this.Zf=this.u.Hd()-this.t.Hd()};zh.prototype.ee=function(){return new yh(this)};
function Ah(a){Y.call(this,a);this.kf=O(0,0);this.lf=O(0,0);this.I=O(0,0);this.J=O(0,0);this.Ba=O(0,0);this.Ca=O(0,0);this.vd=this.B.hc.Ju;this.kf.x=a.vk.x-this.vd.i.position.x;this.kf.y=a.vk.y-this.vd.i.position.y;this.lf.x=a.wk.x-this.vd.i.position.x;this.lf.y=a.wk.y-this.vd.i.position.y;this.I.m(a.ub);this.J.m(a.vb);this.Za=a.Bd;this.Mh=a.Zm+this.Za*a.$m;this.Hq=Math.min(a.Jq,this.Mh-this.Za*Bh);this.Iq=Math.min(a.Kq,(this.Mh-Bh)/this.Za);this.ze=this.ye=this.h=0}N(Ah,Y);
Ah.prototype.md=function(a){var b=this.B,c=this.D,d;d=b.i.e;var e=this.I.x-b.b.r.x,f=this.I.y-b.b.r.y,g=d.c.x*e+d.d.x*f,f=d.c.y*e+d.d.y*f,e=g;d=c.i.e;var h=this.J.x-c.b.r.x,i=this.J.y-c.b.r.y,g=d.c.x*h+d.d.x*i,i=d.c.y*h+d.d.y*i,h=g;d=c.b.g.x+h;var g=c.b.g.y+i,j=this.vd.i.position.x+this.lf.x,k=this.vd.i.position.y+this.lf.y;this.Ba.p(b.b.g.x+e-(this.vd.i.position.x+this.kf.x),b.b.g.y+f-(this.vd.i.position.y+this.kf.y));this.Ca.p(d-j,g-k);d=ue(this.Ba);g=ue(this.Ca);0.005<d?this.Ba.Hc(1/d):this.Ba.S();
0.005<g?this.Ca.Hc(1/g):this.Ca.S();0<this.Mh-d-this.Za*g?this.h=this.xn=0:this.xn=2;d<this.Hq?this.ye=this.sn=0:this.sn=2;g<this.Iq?this.ze=this.tn=0:this.tn=2;d=e*this.Ba.y-f*this.Ba.x;g=h*this.Ca.y-i*this.Ca.x;this.lj=b.n+b.z*d*d;this.mj=c.n+c.z*g*g;this.Wk=this.lj+this.Za*this.Za*this.mj;this.lj=1/this.lj;this.mj=1/this.mj;this.Wk=1/this.Wk;a.yf?(this.h*=a.Ab,this.ye*=a.Ab,this.ze*=a.Ab,a=(-this.h-this.ye)*this.Ba.x,d=(-this.h-this.ye)*this.Ba.y,g=(-this.Za*this.h-this.ze)*this.Ca.x,j=(-this.Za*
this.h-this.ze)*this.Ca.y,b.f.x+=b.n*a,b.f.y+=b.n*d,b.j+=b.z*(e*d-f*a),c.f.x+=c.n*g,c.f.y+=c.n*j,c.j+=c.z*(h*j-i*g)):this.ze=this.ye=this.h=0};
Ah.prototype.Wc=function(){var a=this.B,b=this.D,c;c=a.i.e;var d=this.I.x-a.b.r.x,e=this.I.y-a.b.r.y,f=c.c.x*d+c.d.x*e,e=c.c.y*d+c.d.y*e,d=f;c=b.i.e;var g=this.J.x-b.b.r.x,h=this.J.y-b.b.r.y,f=c.c.x*g+c.d.x*h,h=c.c.y*g+c.d.y*h,g=f,i=f=c=0,j=0;c=j=c=j=i=f=c=0;2==this.xn&&(c=a.f.x+-a.j*e,f=a.f.y+a.j*d,i=b.f.x+-b.j*h,j=b.f.y+b.j*g,c=-(this.Ba.x*c+this.Ba.y*f)-this.Za*(this.Ca.x*i+this.Ca.y*j),j=this.Wk*-c,c=this.h,this.h=Math.max(0,this.h+j),j=this.h-c,c=-j*this.Ba.x,f=-j*this.Ba.y,i=-this.Za*j*this.Ca.x,
j=-this.Za*j*this.Ca.y,a.f.x+=a.n*c,a.f.y+=a.n*f,a.j+=a.z*(d*f-e*c),b.f.x+=b.n*i,b.f.y+=b.n*j,b.j+=b.z*(g*j-h*i));2==this.sn&&(c=a.f.x+-a.j*e,f=a.f.y+a.j*d,c=-(this.Ba.x*c+this.Ba.y*f),j=-this.lj*c,c=this.ye,this.ye=Math.max(0,this.ye+j),j=this.ye-c,c=-j*this.Ba.x,f=-j*this.Ba.y,a.f.x+=a.n*c,a.f.y+=a.n*f,a.j+=a.z*(d*f-e*c));2==this.tn&&(i=b.f.x+-b.j*h,j=b.f.y+b.j*g,c=-(this.Ca.x*i+this.Ca.y*j),j=-this.mj*c,c=this.ze,this.ze=Math.max(0,this.ze+j),j=this.ze-c,i=-j*this.Ca.x,j=-j*this.Ca.y,b.f.x+=b.n*
i,b.f.y+=b.n*j,b.j+=b.z*(g*j-h*i))};
Ah.prototype.Vc=function(){var a=this.B,b=this.D,c,d=this.vd.i.position.x+this.kf.x,e=this.vd.i.position.y+this.kf.y,f=this.vd.i.position.x+this.lf.x,g=this.vd.i.position.y+this.lf.y,h=0,i=0,j=0,k=0,n=c=0,r=0,s=0,t=n=s=c=n=c=0;2==this.xn&&(c=a.i.e,h=this.I.x-a.b.r.x,i=this.I.y-a.b.r.y,n=c.c.x*h+c.d.x*i,i=c.c.y*h+c.d.y*i,h=n,c=b.i.e,j=this.J.x-b.b.r.x,k=this.J.y-b.b.r.y,n=c.c.x*j+c.d.x*k,k=c.c.y*j+c.d.y*k,j=n,c=a.b.g.x+h,n=a.b.g.y+i,r=b.b.g.x+j,s=b.b.g.y+k,this.Ba.p(c-d,n-e),this.Ca.p(r-f,s-g),c=ue(this.Ba),
n=ue(this.Ca),0.005<c?this.Ba.Hc(1/c):this.Ba.S(),0.005<n?this.Ca.Hc(1/n):this.Ca.S(),c=this.Mh-c-this.Za*n,t=Math.max(t,-c),c=S(c+0.005,-0.2,0),s=-this.Wk*c,c=-s*this.Ba.x,n=-s*this.Ba.y,r=-this.Za*s*this.Ca.x,s=-this.Za*s*this.Ca.y,a.b.g.x+=a.n*c,a.b.g.y+=a.n*n,a.b.q+=a.z*(h*n-i*c),b.b.g.x+=b.n*r,b.b.g.y+=b.n*s,b.b.q+=b.z*(j*s-k*r),W(a),W(b));2==this.sn&&(c=a.i.e,h=this.I.x-a.b.r.x,i=this.I.y-a.b.r.y,n=c.c.x*h+c.d.x*i,i=c.c.y*h+c.d.y*i,h=n,c=a.b.g.x+h,n=a.b.g.y+i,this.Ba.p(c-d,n-e),c=ue(this.Ba),
0.005<c?(this.Ba.x*=1/c,this.Ba.y*=1/c):this.Ba.S(),c=this.Hq-c,t=Math.max(t,-c),c=S(c+0.005,-0.2,0),s=-this.lj*c,c=-s*this.Ba.x,n=-s*this.Ba.y,a.b.g.x+=a.n*c,a.b.g.y+=a.n*n,a.b.q+=a.z*(h*n-i*c),W(a));2==this.tn&&(c=b.i.e,j=this.J.x-b.b.r.x,k=this.J.y-b.b.r.y,n=c.c.x*j+c.d.x*k,k=c.c.y*j+c.d.y*k,j=n,r=b.b.g.x+j,s=b.b.g.y+k,this.Ca.p(r-f,s-g),n=ue(this.Ca),0.005<n?(this.Ca.x*=1/n,this.Ca.y*=1/n):this.Ca.S(),c=this.Iq-n,t=Math.max(t,-c),c=S(c+0.005,-0.2,0),s=-this.mj*c,r=-s*this.Ca.x,s=-s*this.Ca.y,
b.b.g.x+=b.n*r,b.b.g.y+=b.n*s,b.b.q+=b.z*(j*s-k*r),W(b));return 0.005>t};var Bh=1;function Ch(){Z.call(this);this.vk=O(0,0);this.wk=O(0,0);this.ub=O(0,0);this.vb=O(0,0);this.type=4;this.vk.p(-1,1);this.wk.p(1,1);this.ub.p(-1,0);this.vb.p(1,0);this.Kq=this.$m=this.Jq=this.Zm=0;this.Bd=1;this.em=m}N(Ch,Z);
Ch.prototype.Hb=function(a,b,c,d,e,f,g){g===l&&(g=0);this.t=a;this.u=b;this.vk.m(c);this.wk.m(d);this.ub=Bf(this.t,e);this.vb=Bf(this.u,f);a=e.x-c.x;c=e.y-c.y;this.Zm=Math.sqrt(a*a+c*c);c=f.x-d.x;d=f.y-d.y;this.$m=Math.sqrt(c*c+d*d);this.Bd=g;g=this.Zm+this.Bd*this.$m;this.Jq=g-this.Bd*Bh;this.Kq=(g-Bh)/this.Bd};Ch.prototype.ee=function(){return new Ah(this)};
function Dh(a){Y.call(this,a);this.Oc=new je;this.vi=new je;this.wi=new je;this.xi=new je;this.Lb=new ne(0,0,0);this.Md=O(0,0);this.He=O(0,0);this.I=O(0,0);this.J=O(0,0);this.h=new ne(0,0,0);this.w=new me;this.I.m(a.ub);this.J.m(a.vb);this.qj=a.Zf;this.h.S();this.oa=0;this.Vk=a.zq;this.yn=a.Fr;this.Qu=a.Wu;this.nj=a.tj;this.Td=a.ph;this.Pf=a.Si;this.ca=0}N(Dh,Y);function uh(a){return a.D.b.q-a.B.b.q-a.qj}
Dh.prototype.md=function(a){var b=this.B,c=this.D,d,e=0;d=b.i.e;var f=this.I.x-b.b.r.x,g=this.I.y-b.b.r.y,e=d.c.x*f+d.d.x*g,g=d.c.y*f+d.d.y*g,f=e;d=c.i.e;var h=this.J.x-c.b.r.x,i=this.J.y-c.b.r.y,e=d.c.x*h+d.d.x*i,i=d.c.y*h+d.d.y*i,h=e;d=b.n;var e=c.n,j=b.z,k=c.z;this.w.c.x=d+e+g*g*j+i*i*k;this.w.d.x=-g*f*j-i*h*k;this.w.aa.x=-g*j-i*k;this.w.c.y=this.w.d.x;this.w.d.y=d+e+f*f*j+h*h*k;this.w.aa.y=f*j+h*k;this.w.c.o=this.w.aa.x;this.w.d.o=this.w.aa.y;this.w.aa.o=j+k;this.Ec=1/(j+k);this.Pf||(this.oa=
0);if(this.Td){var n=c.b.q-b.b.q-this.qj;Math.abs(this.yn-this.Vk)<2*$d?this.ca=3:n<=this.Vk?(1!=this.ca&&(this.h.o=0),this.ca=1):n>=this.yn?(2!=this.ca&&(this.h.o=0),this.ca=2):(this.ca=0,this.h.o=0)}else this.ca=0;a.yf?(this.h.x*=a.Ab,this.h.y*=a.Ab,this.oa*=a.Ab,a=this.h.x,n=this.h.y,b.f.x-=d*a,b.f.y-=d*n,b.j-=j*(f*n-g*a+this.oa+this.h.o),c.f.x+=e*a,c.f.y+=e*n,c.j+=k*(h*n-i*a+this.oa+this.h.o)):(this.h.S(),this.oa=0)};
Dh.prototype.Wc=function(a){var b=this.B,c=this.D,d=0,e=d=0,f=0,g=0,h=0,i=b.f,j=b.j,k=c.f,n=c.j,r=b.n,s=c.n,t=b.z,u=c.z;this.Pf&&3!=this.ca&&(e=this.Ec*-(n-j-this.nj),f=this.oa,g=a.fa*this.Qu,this.oa=S(this.oa+e,-g,g),e=this.oa-f,j-=t*e,n+=u*e);if(this.Td&&0!=this.ca){var a=b.i.e,e=this.I.x-b.b.r.x,f=this.I.y-b.b.r.y,d=a.c.x*e+a.d.x*f,f=a.c.y*e+a.d.y*f,e=d,a=c.i.e,g=this.J.x-c.b.r.x,h=this.J.y-c.b.r.y,d=a.c.x*g+a.d.x*h,h=a.c.y*g+a.d.y*h,g=d,a=k.x+-n*h-i.x- -j*f,w=k.y+n*g-i.y-j*e;pe(this.w,this.Lb,
-a,-w,-(n-j));3==this.ca?this.h.Af(this.Lb):1==this.ca?(d=this.h.o+this.Lb.o,0>d&&(oe(this.w,this.He,-a,-w),this.Lb.x=this.He.x,this.Lb.y=this.He.y,this.Lb.o=-this.h.o,this.h.x+=this.He.x,this.h.y+=this.He.y,this.h.o=0)):2==this.ca&&(d=this.h.o+this.Lb.o,0<d&&(oe(this.w,this.He,-a,-w),this.Lb.x=this.He.x,this.Lb.y=this.He.y,this.Lb.o=-this.h.o,this.h.x+=this.He.x,this.h.y+=this.He.y,this.h.o=0));i.x-=r*this.Lb.x;i.y-=r*this.Lb.y;j-=t*(e*this.Lb.y-f*this.Lb.x+this.Lb.o);k.x+=s*this.Lb.x;k.y+=s*this.Lb.y;
n+=u*(g*this.Lb.y-h*this.Lb.x+this.Lb.o)}else a=b.i.e,e=this.I.x-b.b.r.x,f=this.I.y-b.b.r.y,d=a.c.x*e+a.d.x*f,f=a.c.y*e+a.d.y*f,e=d,a=c.i.e,g=this.J.x-c.b.r.x,h=this.J.y-c.b.r.y,d=a.c.x*g+a.d.x*h,h=a.c.y*g+a.d.y*h,g=d,oe(this.w,this.Md,-(k.x+-n*h-i.x- -j*f),-(k.y+n*g-i.y-j*e)),this.h.x+=this.Md.x,this.h.y+=this.Md.y,i.x-=r*this.Md.x,i.y-=r*this.Md.y,j-=t*(e*this.Md.y-f*this.Md.x),k.x+=s*this.Md.x,k.y+=s*this.Md.y,n+=u*(g*this.Md.y-h*this.Md.x);b.f.m(i);b.j=j;c.f.m(k);c.j=n};
Dh.prototype.Vc=function(){var a=0,b,c=this.B,d=this.D,e=0,f=b=0,g=0,h=0;if(this.Td&&0!=this.ca){var a=d.b.q-c.b.q-this.qj,i=0;3==this.ca?(a=S(a-this.Vk,-ae,ae),i=-this.Ec*a,e=Math.abs(a)):1==this.ca?(a-=this.Vk,e=-a,a=S(a+$d,-ae,0),i=-this.Ec*a):2==this.ca&&(e=a-=this.yn,a=S(a-$d,0,ae),i=-this.Ec*a);c.b.q-=c.z*i;d.b.q+=d.z*i;W(c);W(d)}b=c.i.e;i=this.I.x-c.b.r.x;a=this.I.y-c.b.r.y;f=b.c.x*i+b.d.x*a;a=b.c.y*i+b.d.y*a;i=f;b=d.i.e;var j=this.J.x-d.b.r.x,k=this.J.y-d.b.r.y,f=b.c.x*j+b.d.x*k,k=b.c.y*j+
b.d.y*k,j=f,g=d.b.g.x+j-c.b.g.x-i,h=d.b.g.y+k-c.b.g.y-a,n=g*g+h*h;b=Math.sqrt(n);var f=c.n,r=d.n,s=c.z,t=d.z;n>0.05*0.05&&(n=1/(f+r),g=n*-g,h=n*-h,c.b.g.x-=0.5*f*g,c.b.g.y-=0.5*f*h,d.b.g.x+=0.5*r*g,d.b.g.y+=0.5*r*h,g=d.b.g.x+j-c.b.g.x-i,h=d.b.g.y+k-c.b.g.y-a);this.vi.c.x=f+r;this.vi.d.x=0;this.vi.c.y=0;this.vi.d.y=f+r;this.wi.c.x=s*a*a;this.wi.d.x=-s*i*a;this.wi.c.y=-s*i*a;this.wi.d.y=s*i*i;this.xi.c.x=t*k*k;this.xi.d.x=-t*j*k;this.xi.c.y=-t*j*k;this.xi.d.y=t*j*j;this.Oc.hh(this.vi);this.Oc.Dl(this.wi);
this.Oc.Dl(this.xi);this.Oc.lg(Eh,-g,-h);g=Eh.x;h=Eh.y;c.b.g.x-=c.n*g;c.b.g.y-=c.n*h;c.b.q-=c.z*(i*h-a*g);d.b.g.x+=d.n*g;d.b.g.y+=d.n*h;d.b.q+=d.z*(j*h-k*g);W(c);W(d);return 0.005>=b&&e<=$d};var Eh=O(0,0);function Fh(){Z.call(this);this.ub=O(0,0);this.vb=O(0,0);this.type=1;this.ub.S();this.vb.S();this.tj=this.Wu=this.Fr=this.zq=this.Zf=0;this.Si=this.ph=q}N(Fh,Z);Fh.prototype.Hb=function(a,b,c){this.t=a;this.u=b;this.ub=Bf(this.t,c);this.vb=Bf(this.u,c);this.Zf=this.u.Hd()-this.t.Hd()};
Fh.prototype.ee=function(){return new Dh(this)};function Gh(a){Y.call(this,a);this.ad=O(0,0);this.bd=O(0,0);this.h=new ne(0,0,0);this.w=new me;this.ad.m(a.ub);this.bd.m(a.vb);this.qj=a.Zf}N(Gh,Y);
Gh.prototype.md=function(a){var b,c=0,d=this.B,e=this.D;b=d.i.e;var f=this.ad.x-d.b.r.x,g=this.ad.y-d.b.r.y,c=b.c.x*f+b.d.x*g,g=b.c.y*f+b.d.y*g,f=c;b=e.i.e;var h=this.bd.x-e.b.r.x,i=this.bd.y-e.b.r.y,c=b.c.x*h+b.d.x*i,i=b.c.y*h+b.d.y*i,h=c;b=d.n;var c=e.n,j=d.z,k=e.z;this.w.c.x=b+c+g*g*j+i*i*k;this.w.d.x=-g*f*j-i*h*k;this.w.aa.x=-g*j-i*k;this.w.c.y=this.w.d.x;this.w.d.y=b+c+f*f*j+h*h*k;this.w.aa.y=f*j+h*k;this.w.c.o=this.w.aa.x;this.w.d.o=this.w.aa.y;this.w.aa.o=j+k;a.yf?(this.h.x*=a.Ab,this.h.y*=
a.Ab,this.h.o*=a.Ab,d.f.x-=b*this.h.x,d.f.y-=b*this.h.y,d.j-=j*(f*this.h.y-g*this.h.x+this.h.o),e.f.x+=c*this.h.x,e.f.y+=c*this.h.y,e.j+=k*(h*this.h.y-i*this.h.x+this.h.o)):this.h.S()};
Gh.prototype.Wc=function(){var a,b=0,c=this.B,d=this.D,e=c.f,f=c.j,g=d.f,h=d.j,i=c.n,j=d.n,k=c.z,n=d.z;a=c.i.e;var r=this.ad.x-c.b.r.x,s=this.ad.y-c.b.r.y,b=a.c.x*r+a.d.x*s,s=a.c.y*r+a.d.y*s,r=b;a=d.i.e;var t=this.bd.x-d.b.r.x,u=this.bd.y-d.b.r.y,b=a.c.x*t+a.d.x*u,u=a.c.y*t+a.d.y*u,t=b;a=new ne(0,0,0);pe(this.w,a,-(g.x-h*u-e.x+f*s),-(g.y+h*t-e.y-f*r),-(h-f));this.h.Af(a);e.x-=i*a.x;e.y-=i*a.y;f-=k*(r*a.y-s*a.x+a.o);g.x+=j*a.x;g.y+=j*a.y;h+=n*(t*a.y-u*a.x+a.o);c.j=f;d.j=h};
Gh.prototype.Vc=function(){var a,b=0,c=this.B,d=this.D;a=c.i.e;var e=this.ad.x-c.b.r.x,f=this.ad.y-c.b.r.y,b=a.c.x*e+a.d.x*f,f=a.c.y*e+a.d.y*f,e=b;a=d.i.e;var g=this.bd.x-d.b.r.x,h=this.bd.y-d.b.r.y,b=a.c.x*g+a.d.x*h,h=a.c.y*g+a.d.y*h,g=b;a=c.n;var b=d.n,i=c.z,j=d.z,k=d.b.g.x+g-c.b.g.x-e,n=d.b.g.y+h-c.b.g.y-f,r=d.b.q-c.b.q-this.qj,s=Math.sqrt(k*k+n*n),t=Math.abs(r);0.05<s&&(i*=1,j*=1);this.w.c.x=a+b+f*f*i+h*h*j;this.w.d.x=-f*e*i-h*g*j;this.w.aa.x=-f*i-h*j;this.w.c.y=this.w.d.x;this.w.d.y=a+b+e*e*
i+g*g*j;this.w.aa.y=e*i+g*j;this.w.c.o=this.w.aa.x;this.w.d.o=this.w.aa.y;this.w.aa.o=i+j;var u=new ne(0,0,0);pe(this.w,u,-k,-n,-r);c.b.g.x-=a*u.x;c.b.g.y-=a*u.y;c.b.q-=i*(e*u.y-f*u.x+u.o);d.b.g.x+=b*u.x;d.b.g.y+=b*u.y;d.b.q+=j*(g*u.y-h*u.x+u.o);W(c);W(d);return 0.005>=s&&t<=$d};function Hh(){Z.call(this);this.ub=O(0,0);this.vb=O(0,0);this.type=8;this.Zf=0}N(Hh,Z);Hh.prototype.Hb=function(a,b,c){this.t=a;this.u=b;this.ub.m(Bf(this.t,c));this.vb.m(Bf(this.u,c));this.Zf=this.u.Hd()-this.t.Hd()};
Hh.prototype.ee=function(){return new Gh(this)};var Vg=[new Ge,new Ge],dh=[new Ge,new Ge],eh=[new Ge,new Ge],Wg=O(0,0),Xg=O(0,0),Yg=O(0,0),ah=O(0,0),Zg=O(0,0),$g=O(0,0),bh=O(0,0),ch=O(0,0),pg=0,yg=0,zg=0,wg=0,xg=0,qg=new kf,rg=new Se,sg=new re,tg=new re,vg=new ef,ug=new Te,Ef=new re,Tf=new Rf;new function(){this.position=O(0,0);this.Jr=O(0,0);this.sc=O(0,0);this.id=new Ee};new re;var Ag=new qe,Bg=new qe,og=new lf,Sg=new mf,Ug=new Rg;
function Ih(a,b,c,d,e,f){return(c+0.1>=a&&a>=e-0.1||c-0.1<=a&&a<=e+0.1)&&(d+0.1>=b&&b>=f-0.1||d-0.1<=b&&b<=f+0.1)&&(0.1<Math.abs(e-c)?0.1>Math.abs((f-d)/(e-c)*(a-c)+d-b):0.1>Math.abs(a-c))}
function Jh(a){var b=[],c=0,d=0,e=0,f=0,g=0,h=g=0,i=0,j=0,k=0,f=0,n,r,s,t,u,w=f=c=0,x=0,e=[],i=[],C=q,B=[],z=[];for(z.push(a);z.length;){b=z[0];d=b.length;C=m;for(c=0;c<d;c++)if(j=c,k=c<d-1?c+1:c+1-d,f=c<d-2?c+2:c+2-d,a=b[j],n=b[k],f=b[f],f=a.x*n.y+n.x*f.y+f.x*a.y-a.y*n.x-n.y*f.x-f.y*a.x,0>f){C=q;i=1E9;for(e=0;e<d;e++)if(e!==j&&e!==k){c=e;f=e<d-1?e+1:0;r=b[c];s=b[f];h=a.x;t=a.y;var E=n.x,A=n.y,g=r.x;r=r.y;var I=s.x;s=s.y;var J=E-h,aa=A-t,G=I-g,xa=s-r,G=(G*(r-t)-xa*(g-h))/(aa*G-J*xa),J=h+G*J,aa=t+
G*aa,h=Ih(E,A,h,t,J,aa),g=Ih(J,aa,g,r,I,s);if(t=h&&g?O(J,aa):p)g=n.x-t.x,h=n.y-t.y,g=g*g+h*h,g<i&&(x=c,w=f,u=t,i=g)}if(1E9===i)return[];e=[];i=[];c=x;f=w;r=b[c];s=b[f];0.1>Math.abs(s.x-u.x)&&0.1>Math.abs(s.y-u.y)||e.push(u);0.1>Math.abs(r.x-u.x)&&0.1>Math.abs(r.y-u.y)||i.push(u);x=-1;for(w=j;;){if(w!==f)e.push(b[w]);else{if(0>x||x>=d)return[];Ih(s.x,s.y,b[x].x,b[x].y,a.x,a.y)||e.push(b[w]);break}x=w;0>w-1?w=d-1:w--}e.reverse();x=-1;for(w=k;;){if(w!==c)i.push(b[w]);else{if(0>x||x>=d)return[];w===c&&
!Ih(r.x,r.y,b[x].x,b[x].y,n.x,n.y)&&i.push(b[w]);break}x=w;w+1>d-1?w=0:w++}z.push(e,i);z.shift();break}C&&B.push(z.shift())}return B}
function Kh(a){for(var b=0;4E3>b;b++)te.push(new se(0,0));this.a=a;this.Mc=new cg(O(0,10),m);this.Lr=10;this.lq=-1;a=new Rf;a.O=this;a.Eo=function(a){this.O.a.yj(a.wb.sa().Ki.k,a.kb.sa().Ki.k)};this.Mc.Bc.kj=a;a=new Of;a.O=this;a.ih=function(a,b){if(this.O.zs)return m;var e=a.sa().Ki.k.type,f=b.sa().Ki.k.type,g=e.Ma.qs;return g&&g.contains(f)?q:(g=f.Ma.qs)&&g.contains(e)?q:m};this.Mc.Bc.nn=a;this.Hv=0;this.Jj=8;this.uj=3;this.zs=m}function Lh(){}var Mh=Kh.prototype;
Mh.ta=function(a,b){this.O=a;this.Wh=b;this.a=a.a};Mh.ta.prototype.X=v();Mh.la=function(a,b){this.type=a;this.O=a.O;this.k=b;this.a=a.a;this.Mc=this.O.Mc};var Nh=Mh.la.prototype;
Nh.X=function(){this.ku=0!==this.G[0];this.lp=this.G[1];this.nv=0!==this.G[2];this.oh=this.G[3];this.rh=this.G[4];this.Zh=this.G[5];this.Mk=this.G[6];this.Rj=this.G[7];this.$j=0!==this.G[8];this.body=p;this.k.gb();this.Um=this.k.x;this.Vm=this.k.y;this.hq=this.k.v;this.gq=this.mq=0;this.dr=this.Wm=q;this.Sm=p;this.Tm=-1;this.yd?(this.yd.length=0,this.of.length=0,this.Ik.clear()):(this.yd=[],this.of=[],this.Ik=new db);var a=this;this.Pq=function(b){a.cv(b)};this.a.Yo(this.Pq)};
Nh.$q=function(){this.k.gb();this.rp();this.Sm=this.k.Jb;this.Tm=this.k.T};Nh.Rg=function(){this.pm();this.of.length=0;this.Ik.clear();this.body&&(gg(this.Mc,this.body),this.body=p);this.a.uv(this.Pq)};Nh.cv=function(a){var b,c,d;d=b=0;for(c=this.of.length;b<c;b++)this.of[d]=this.of[b],this.yd[d]=this.yd[b],this.of[b].Zd[1]==a?hg(this.Mc,this.yd[b]):d++;this.of.length=d;this.yd.length=d;this.Ik.remove(a)};
Nh.pm=function(){var a,b;a=0;for(b=this.yd.length;a<b;a++)hg(this.Mc,this.yd[a]);this.yd.length=0};Nh.er=function(){var a,b,c;a=0;for(b=this.of.length;a<b;a++)switch(c=this.of[a],c.type){case 0:this.Ws(c.Zd[0],c.Zd[1],c.Zd[2],c.Zd[3],c.Zd[4]);break;case 1:this.Ys(c.Zd[0],c.Zd[1]);break;case 2:this.Xs(c.Zd[0],c.Zd[1],c.Zd[2],c.Zd[3])}};
Nh.rp=function(){var a=this.k,b=q,c=p,d=p,e,f,g,h,i,j;this.body&&(b=m,c=O(0,0),c.m(this.body.f),d=this.body.j,this.pm(),gg(this.Mc,this.body),this.body=p);var k=new Zf;k.oh=this.oh;k.rh=this.rh;k.Zh=this.Zh;j=new Ff;j.type=this.ku?0:2;a.gb();j.position.x=0.02*a.Ka.Pg();j.position.y=0.02*a.Ka.Qg();j.v=a.v;j.Dp=this.nv;j.Mk=this.Mk;j.Rj=this.Rj;j.$j=this.$j;var n=this.k.Da&&!this.k.Da.uh();this.body=eg(this.Mc,j);this.body.Ki=this;j=this.lp;!n&&0===this.lp&&(j=1);f=Math.max(Math.abs(a.width),1);g=Math.max(Math.abs(a.height),
1);n=0>a.width;i=0>a.height;if(0===j){j=a.v;a.v=0;a.ha();a.gb();var r=a.Ka.Pg()-a.x,s=a.Ka.Qg()-a.y;a.v=j;a.ha();a.Da.mh(n?-f:f,i?-g:g,0);var t=a.Da.ic;h=a.Da.Fe;j=[];j.length=h;for(e=0;e<h;e++)j[e]=O(t[2*e]-r,t[2*e+1]-s);n!==i&&j.reverse();e=f*g;i=Jh(j);var n=[],u,w,x,C,B,z;w=0;for(x=i.length;w<x;w++){s=i[w];r=[];r.length=s.length;C=z=0;for(B=s.length;C<B;C++)t=s[C],u=s[(C+1)%B],z+=t.x*u.y-t.y*u.x,r[C]=O(t.x,t.y);z=Math.abs(z/2);z>=0.001*e&&n.push(r)}for(e=0;e<h;e++)T(j[e]);if(n.length){e=0;for(f=
n.length;e<f;e++){j=n[e];g=0;for(h=j.length;g<h;g++)i=j[g],i.x*=0.02,i.y*=0.02;k.shape=new Be;i=k.shape;g=j;h=g.length;i.wa=h;Ce(i,h);for(h=h=0;h<i.wa;h++)i.s[h].m(g[h]);for(h=0;h<i.wa;++h)g=R(i.s[h+1<i.wa?h+1:0],i.s[h]),i.Ha[h].m(he(g)),we(i.Ha[h]);g=i;h=i.s;i=i.wa;r=O(0,0);s=0;t=1/3;for(u=0;u<i;++u)w=h[u],x=u+1<i?h[u+1]:h[0],C=0.5*((w.x-0)*(x.y-0)-(w.y-0)*(x.x-0)),s+=C,r.x+=C*t*(0+w.x+x.x),r.y+=C*t*(0+w.y+x.y);r.x*=1/s;r.y*=1/s;g.ud=r;sf(this.body,k);g=0;for(h=j.length;g<h;g++)T(j[g])}}else k.shape=
new Be,De(k.shape,0.01*f,0.01*g),sf(this.body,k)}else 1===j?(k.shape=new Be,De(k.shape,0.01*f,0.01*g)):k.shape=new ye(0.01*Math.min(f,g)),sf(this.body,k);a.Ma.Ii=this.body;this.mq=a.width;this.gq=a.height;if(b){zf(this.body,c);this.body.Ml(d);T(c);this.er();j=this.Ik.hg();e=0;for(f=j.length;e<f;e++)a=j[e].Ma.Ii.Ki,a.pm(),a.er()}};
Nh.Gc=function(){var a=this.k,b;b=0===this.O.Hv?this.a.fg/60:this.a.qk(this.k);if(this.a.eg>this.O.lq&&0<this.a.fg){this.Mc.Df(b,this.O.Jj,this.O.uj);for(b=this.Mc.Tb.ka(If);b;b=b.next)b.body.hf.S(),b.body.Og=0;this.O.lq=this.a.eg}if(this.dr||a.width!==this.mq||a.height!==this.gq||a.Jb!==this.Sm||a.T!==this.Tm)this.rp(),this.dr=q,this.Sm=a.Jb,this.Tm=a.T;b=a.v!==this.hq;if(a.x!==this.Um||a.y!==this.Vm){a.gb();var c=a.Ka.Pg(),d=a.Ka.Qg(),e=c-this.Um,f=d-this.Vm,g=this.body,c=O(0.02*c,0.02*d);wf(g,
c,g.Hd());zf(this.body,O(e,f));this.Wm=m;V(this.body,m)}else this.Wm&&(this.Wm=q,zf(this.body,O(0,0)),e=this.body,f=O(0.02*a.Ka.Pg(),0.02*a.Ka.Qg()),wf(e,f,e.Hd()));b&&(this.body.So(a.v),V(this.body,m));e=this.body.i.position;b=e.x/0.02;e=e.y/0.02;f=this.body.Hd();if(b!==a.x||e!==a.y||f!==a.v)if(a.x=b,a.y=e,a.v=f,a.ha(),a.gb(),b=a.Ka.Pg()-a.x,e=a.Ka.Qg()-a.y,0!==b||0!==e)a.x-=b,a.y-=e,a.ha();this.Um=a.x;this.Vm=a.y;this.hq=a.v};
Nh.rk=function(a){return-1===a||!this.k.pe?this.k.x:0===a?(this.body.i.position.x+this.body.b.r.x)/0.02:this.k.pe(a,m)};Nh.sk=function(a){return-1===a||!this.k.pe?this.k.y:0===a?(this.body.i.position.y+this.body.b.r.y)/0.02:this.k.pe(a,q)};Mh.C=new (v());Lh.prototype.Ne=function(a,b,c){var d=this.rk(c),c=this.sk(c);this.body.Ne(O(a,b),O(0.02*d,0.02*c))};Lh.prototype.El=function(a){this.body.El(K(a))};Lh.prototype.Ml=function(a){this.body.Ml(K(a));V(this.body,m)};
Nh.Ws=function(a,b,c,d,e){var f=this.rk(a),a=this.sk(a),g;b.pe?(g=b.pe(c,m),c=b.pe(c,q)):(g=b.x,c=b.y);var h=f-g,i=a-c,j=new ph;j.Hb(this.body,b.Ma.Ii,O(0.02*f,0.02*a),O(0.02*g,0.02*c));j.length=0.02*Math.sqrt(h*h+i*i);j.nm=d;j.Am=e;this.yd.push(ig(this.Mc,j))};Nh.Ys=function(a,b){var c=this.rk(a),d=this.sk(a),e=new Fh;e.Hb(this.body,b.Ma.Ii,O(0.02*c,0.02*d));this.yd.push(ig(this.Mc,e))};
Nh.Xs=function(a,b,c,d){var e=this.rk(a),a=this.sk(a),f=new Fh;f.Hb(this.body,b.Ma.Ii,O(0.02*e,0.02*a));f.ph=m;f.zq=K(c);f.Fr=K(d);this.yd.push(ig(this.Mc,f))};Lh.prototype.ss=function(a){if(a!==this.O.Lr){var b=O(0,a);this.Mc.qn=b;this.O.Lr=a;for(var c=this.O.Th.hg(),a=0,b=c.length;a<b;a++)V(c[a].Ma.Ii,m)}};Mh.L=new Lh;Mh.Fa=new (v());function Oh(a){this.a=a}function Ph(){}var Qh=Oh.prototype;Qh.ta=function(a,b){this.O=a;this.Wh=b;this.a=a.a};Qh.ta.prototype.X=v();
Qh.la=function(a,b){this.type=a;this.O=a.O;this.k=b;this.a=a.a;this.Ac=0};var Rh=Qh.la.prototype,Sh=2*Math.PI,Th=Math.PI/2,Uh=3*Math.PI/2;Rh.X=function(){this.ie=1===this.G[0];this.Dn=this.G[1];this.Tv=this.G[2];this.Sg=this.G[3];this.Sg+=Math.random()*this.G[4];0===this.Sg?this.Ac=0:(this.Ac=this.G[5]/this.Sg*Sh,this.Ac+=Math.random()*this.G[6]/this.Sg*Sh);this.Vd=this.G[7];this.Vd+=Math.random()*this.G[8];this.Bd=this.Ia=0;this.init()};
Rh.init=function(){switch(this.Dn){case 0:this.Ia=this.k.x;break;case 1:this.Ia=this.k.y;break;case 2:this.Ia=this.k.width;this.Bd=this.k.height/this.k.width;break;case 3:this.Ia=this.k.width;break;case 4:this.Ia=this.k.height;break;case 5:this.Ia=this.k.v;this.Vd=K(this.Vd);break;case 6:this.Ia=this.k.opacity;break;case 7:this.Ia=0}this.ef=this.Ia};
Rh.$g=function(a){a%=Sh;switch(this.Tv){case 0:return Math.sin(a);case 1:return a<=Th?a/Th:a<=Uh?1-2*(a-Th)/Math.PI:(a-Uh)/Th-1;case 2:return 2*a/Sh-1;case 3:return-2*a/Sh+1;case 4:return a<Math.PI?-1:1}return 0};Rh.Gc=v();
Rh.Fj=function(){var a=this.a.qk(this.k);if(this.ie&&0!==a){0===this.Sg?this.Ac=0:(this.Ac+=a/this.Sg*Sh,this.Ac%=Sh);switch(this.Dn){case 0:this.k.x!==this.ef&&(this.Ia+=this.k.x-this.ef);this.k.x=this.Ia+this.$g(this.Ac)*this.Vd;this.ef=this.k.x;break;case 1:this.k.y!==this.ef&&(this.Ia+=this.k.y-this.ef);this.k.y=this.Ia+this.$g(this.Ac)*this.Vd;this.ef=this.k.y;break;case 2:this.k.width=this.Ia+this.$g(this.Ac)*this.Vd;this.k.height=this.k.width*this.Bd;break;case 3:this.k.width=this.Ia+this.$g(this.Ac)*
this.Vd;break;case 4:this.k.height=this.Ia+this.$g(this.Ac)*this.Vd;break;case 5:this.k.v!==this.ef&&(this.Ia=ua(this.Ia+(this.k.v-this.ef)));this.k.v=ua(this.Ia+this.$g(this.Ac)*this.Vd);this.ef=this.k.v;break;case 6:this.k.opacity=this.Ia+this.$g(this.Ac)*this.Vd/100,0>this.k.opacity?this.k.opacity=0:1<this.k.opacity&&(this.k.opacity=1)}this.k.ha()}};
Rh.Tq=function(a,b){switch(this.Dn){case 2:this.Ia*=b.width/a.width;this.Bd=b.height/b.width;break;case 3:this.Ia*=b.width/a.width;break;case 4:this.Ia*=b.height/a.height}};Ph.prototype.kg=y("ie");Qh.C=new Ph;Qh.L=new (v());Qh.Fa=new (v());function Vh(a){this.a=a}var Wh=Vh.prototype;Wh.ta=function(a,b){this.O=a;this.Wh=b;this.a=a.a};Wh.ta.prototype.X=v();Wh.la=function(a,b){this.type=a;this.O=a.O;this.k=b;this.a=a.a;this.mode=0};var Xh=Wh.la.prototype;Xh.X=function(){this.mode=this.G[0]};Xh.Gc=v();
Xh.Fj=function(){this.k.gb();var a=this.k.ea,b=this.k.F.Ga,c=q;0===this.mode?(0>this.k.x&&(this.k.x=0,c=m),0>this.k.y&&(this.k.y=0,c=m),this.k.x>b.width&&(this.k.x=b.width,c=m),this.k.y>b.height&&(this.k.y=b.height,c=m)):(0>a.left&&(this.k.x-=a.left,c=m),0>a.top&&(this.k.y-=a.top,c=m),a.right>b.width&&(this.k.x-=a.right-b.width,c=m),a.bottom>b.height&&(this.k.y-=a.bottom-b.height,c=m));c&&this.k.ha()};function Yh(a){this.a=a}var Zh=Yh.prototype;Zh.ta=function(a,b){this.O=a;this.Wh=b;this.a=a.a};
Zh.ta.prototype.X=v();Zh.la=function(a,b){this.type=a;this.O=a.O;this.k=b;this.a=a.a};var $h=Zh.la.prototype;$h.X=v();$h.Gc=function(){this.k.gb();var a=this.k.ea,b=this.k.F.Ga;(0>a.right||0>a.bottom||a.left>b.width||a.top>b.height)&&this.a.eh(this.k)};function ai(a){this.a=a;this.Dv=this.mr=this.fo=this.Cv=0}var bi=ai.prototype;bi.ta=function(a,b){this.O=a;this.Wh=b;this.a=a.a};bi.ta.prototype.X=v();bi.la=function(a,b){this.type=a;this.O=a.O;this.k=b;this.a=a.a};var ci=bi.la.prototype;ci.X=v();
ci.Gc=v();ci.Fj=function(){var a=this.O.Th.Qv(),b=0,c=0,d,e;d=0;for(e=a.length;d<e;d++)b+=a[d].x,c+=a[d].y;d=this.k.F.Ga;var f=this.a.Nf.de,g=e=0;f>=this.O.fo&&f<this.O.mr&&(e=this.O.Cv*Math.min(this.a.fg,1),0===this.O.Dv&&(e*=1-(f-this.O.fo)/(this.O.mr-this.O.fo)),f=2*Math.random()*Math.PI,g=Math.random()*e,e=Math.cos(f)*g,g*=Math.sin(f));d.hr(b/a.length+e);d.ir(c/a.length+g)};bi.L=new (v());
function vb(){return[p,"Main",[[uc,m,q,q,q,q,q,q,q,q],[Qc,m,q,q,q,q,q,q,q,q],[Tc,q,m,m,m,q,q,q,q,q],[Bd,m,q,q,q,q,q,q,q,q],[Yc,m,q,q,q,q,q,q,q,q],[bd,m,q,q,q,q,q,q,q,q],[M,q,m,m,m,m,m,m,m,q],[qd,q,m,m,m,m,m,m,m,q],[xd,q,m,m,m,m,m,m,m,m]],[["t0",Bd,q,0,0,0,p,p,[],q,q,[],[25]],["t1",Yc,q,0,0,0,p,p,[],q,q,[],[]],["t2",bd,q,0,0,0,p,p,[],q,q,[],[]],["t3",uc,q,0,0,0,p,p,[],q,q,[],[0]],["t4",Qc,q,0,0,0,p,p,[],q,q,[],[]],["t5",M,q,2,4,0,p,[["Default",5,m,1,0,q,[["images/cat-sheet1.png",158,0,0,50,30,1,0.5,
0.5,[],[0.5,0.5,-0.5,0.5,-0.5,-0.5,0.5,-0.5],3],["images/cat-sheet0.png",187,0,0,51,32,1,0.509804,0.5,[],[],3]]]],[["Physics",Kh],["8Direction",Xd],["ScrollTo",ai],["BoundToLayout",Vh]],q,q,[]],["t6",xd,q,0,0,0,["images/sea.png",18331,1],p,[],q,q,[]],["t7",xd,q,0,0,0,["images/sky.png",92,1],p,[],q,q,[]],["t8",M,q,0,1,0,p,[["Default",5,m,1,0,q,[["images/enemy-sheet0.png",179,1,1,32,4,1,0.5,0.5,[],[],0],["images/enemy-sheet0.png",179,1,6,32,4,1,0.5,0.5,[],[],0],["images/enemy-sheet0.png",179,1,11,32,
4,1,0.5,0.5,[],[],0],["images/enemy-sheet0.png",179,1,16,32,4,1,0.5,0.5,[],[],0],["images/enemy-sheet0.png",179,1,21,32,4,1,0.5,0.5,[],[],0],["images/enemy-sheet0.png",179,1,26,32,4,1,0.5,0.5,[],[],0]]]],[["Sine",Oh]],q,q,[]],["t9",M,q,1,2,0,p,[["Default",1,m,1,0,q,[["images/fish-sheet0.png",142,1,1,16,12,1,0.5,0.5,[],[],0],["images/fish-sheet0.png",142,1,14,16,12,1,0.5625,0.416667,[],[-0.5,-0.416667,0.4375,-0.416667,0.4375,0.5,-0.5,0.5],0]]]],[["DestroyOutsideLayout",Yh],["Sine",Oh]],q,q,[]],["t10",
qd,q,0,1,0,p,p,[["Anchor",Ud]],q,q,[]],["t11",xd,q,0,1,0,["images/progressbar.png",638,0],p,[["Anchor",Ud]],q,q,[]],["t12",xd,q,0,1,0,["images/livesbar.png",131,3],p,[["Anchor",Ud]],q,q,[]],["t13",M,q,0,0,0,p,[["Default",2,q,1,0,q,[["images/sprite-sheet0.png",1456,0,0,256,256,1,0.503906,0.390625,[],[-0.503906,-0.390625,0.496094,-0.390625,0.496094,0.546875,-0.503906,0.546875],1],["images/sprite-sheet1.png",1703,0,0,256,256,1,0.503906,0.390625,[],[-0.503906,-0.390625,0.496094,-0.390625,0.496094,0.546875,
-0.503906,0.546875],1],["images/sprite-sheet2.png",1888,0,0,256,256,1,0.503906,0.390625,[],[-0.503906,-0.390625,0.496094,-0.390625,0.496094,0.546875,-0.503906,0.546875],1]]]],[],q,q,[]],["t14",Tc,q,0,0,0,p,p,[],q,q,[]],["t15",xd,q,0,0,0,["images/tiledbackground.png",5907,0],p,[],q,q,[]],["t16",M,q,0,0,0,p,[["Default",5,q,1,0,q,[["images/win-sheet0.png",3369,0,0,256,256,1,0.5,0.246094,[],[-0.496094,-0.242188,0.496094,-0.242188,0.496094,0.238281,-0.496094,0.238281],0]]]],[],q,q,[]]],[],[["Main",1280,
1024,q,"MainEvent",[["Background",0,m,[21,18,169],q,1,1,1,q,1,0,0,[[[0,0,0,1280,94,0,0,1,0,0,0,0,[]],7,[],[],[0,0]],[[0,987.454,0,1284.73,36.5456,0,0,1,0,0,0,0,[]],15,[],[],[0,0]]],[]],["Sprites",1,m,[255,255,255],m,1,1,1,q,1,0,0,[[[589,64,0,50,30,0,0,1,0.5,0.5,0,0,[]],5,[15,3],[[0,2,1,1,0.5,0.2,0,0.01,0],[200,600,500,3,0,1],[],[1]],[0,0,1]],[[0,94,0,1283,85,0,0,0.5,0,0,0,0,[]],6,[],[],[0,0]],[[612,391,0,16,12,0,0,1,0.5,0.5,0,0,[]],9,[0],[[],[1,0,0,100,0,0,100,600,0]],[0,0,1]],[[587,215,0,32,4,0,
0,1,0.5,0.5,0,0,[]],8,[],[[1,0,0,90,0,0,100,610,0]],[0,2,1]],[[0,0,0,200,30,0,0,1,0,0,0,0,[]],10,[],[[0,0,0,0]],["Fish:",0,"bold 12pt Arial","rgb(0,0,0)",0,0,0,0,0]],[[3,21,0,100,20,0,0,1,0,0,0,0,[]],11,[],[[0,0,0,0]],[0,0]],[[1,42,0,48,16,0,0,1,0,0,0,0,[]],12,[],[[0,0,0,0]],[0,0]]],[]],["O2Layer",2,m,[204,0,0],q,1,1,0,q,1,1,0,[],[["colorblend","Color",[]]]],["WaterEffect",3,m,[0,0,204],q,0.1,10,0.2,q,10,1,11,[],[["water","Water",[0.01,0.01,0,2,2,100,4,10,1]]]]],[],[]],["Dead",800,500,q,"DeadEvent",
[["Layer 0",0,m,[0,0,0],q,1,1,1,q,1,0,0,[[[401,219,0,256,256,0,0,1,0.503906,0.390625,0,0,[]],13,[],[],[0,0,0]],[[360,421,0,72,24,0,0,1,0,0,0,0,[]],14,[],[],["Again","",1,1,1,""]]],[]]],[],[]],["Win",800,500,q,"Event sheet 1",[["Layer 0",0,m,[0,0,0],q,1,1,1,q,1,0,0,[[[397,180,0,256,256,0,0,1,0.5,0.246094,0,0,[]],16,[],[],[0,0,0]],[[363,397,0,72,24,0,0,1,0,0,0,0,[]],14,[],[],["Again","",1,1,1,""]]],[]]],[],[]]],[["MainEvent",[[0,p,q,[[-1,L.prototype.C.No,p,1,q,q,q],[-1,L.prototype.C.Rr,p,0,m,q,q,[[1,
[2,"i"]],[0,[0,1]],[0,[0,19]]]]],[[5,Kh.prototype.L.ss,"Physics",[[0,[0,-1]]]],[-1,L.prototype.L.Fl,p,[[4,8],[5,[0,0]],[0,[0,623]],[0,[4,[19,L.prototype.Fa.random,[[0,700]]],[0,250]]]]],[-1,L.prototype.L.Fl,p,[[4,9],[5,[0,0]],[0,[0,623]],[0,[4,[19,L.prototype.Fa.random,[[0,700]]],[0,250]]]]],[10,qd.prototype.L.Pl,p,[[7,[10,[2,"Fish:"],[20,9,M.prototype.Fa.Go,q,p]]]]]]],[0,p,q,[[1,Yc.prototype.C.Jo,p,0,q,q,q,[[9,39]]]],[[5,M.prototype.L.Qj,p,[[3,0]]]]],[0,p,q,[[1,Yc.prototype.C.Jo,p,0,q,q,q,[[9,37]]]],
[[5,M.prototype.L.Qj,p,[[3,1]]]]],[0,p,q,[[5,M.prototype.C.Fo,p,0,q,q,q,[[8,2],[0,[0,90]]]]],[[5,M.prototype.L.Rl,p,[[0,[0,90]]]],[5,M.prototype.L.Ol,p,[[10,0],[7,[0,100]]]]]],[0,p,q,[[5,M.prototype.C.Mo,p,0,q,q,m,[[4,8]]]],[[5,M.prototype.L.Rl,p,[[0,[0,90]]]],[5,M.prototype.L.Ul,p,[[10,1],[7,[0,1]]]]]],[0,p,q,[[5,M.prototype.C.li,p,0,q,q,q,[[10,0],[8,3],[7,[0,0]]]]],[[5,M.prototype.L.Rl,p,[[0,[0,90]]]],[5,M.prototype.L.Ul,p,[[10,1],[7,[0,1]]]],[5,M.prototype.L.Ol,p,[[10,0],[7,[0,100]]]]]],[0,p,q,
[[5,M.prototype.C.Mo,p,0,q,q,m,[[4,9]]]],[[9,M.prototype.L.vc,p],[10,qd.prototype.L.Pl,p,[[7,[10,[2,"Fish:"],[5,[20,9,M.prototype.Fa.Go,q,p],[0,1]]]]]],[-1,L.prototype.L.Fl,p,[[4,8],[5,[0,0]],[0,[0,623]],[0,[4,[19,L.prototype.Fa.random,[[0,600]]],[0,250]]]]]],[[0,p,q,[[10,qd.prototype.C.Nr,p,0,q,q,q,[[1,[2,"Fish:0"]],[3,0]]]],[[16,M.prototype.L.To,p,[[3,1]]],[-1,L.prototype.L.Oj,p,[[6,"Win"]]]]]]],[0,p,q,[[9,M.prototype.C.li,p,0,q,q,q,[[10,0],[8,1],[7,[19,L.prototype.Fa.round,[[20,9,M.prototype.Fa.Ci,
q,p]]]]]]],[],[[0,p,q,[[9,M.prototype.C.li,p,0,q,q,q,[[10,0],[8,2],[7,[19,L.prototype.Fa.round,[[20,9,M.prototype.Fa.Ci,q,p]]]]]]],[[9,M.prototype.L.Qj,p,[[3,1]]]]],[0,p,q,[[9,M.prototype.C.li,p,0,q,q,q,[[10,0],[8,4],[7,[19,L.prototype.Fa.round,[[20,9,M.prototype.Fa.Ci,q,p]]]]]]],[[9,M.prototype.L.Qj,p,[[3,0]]]]],[0,p,q,[[-1,L.prototype.C.Mr,p,0,q,q,q,[[7,[0,0]],[8,0],[7,[0,0]]]]],[[9,M.prototype.L.Ol,p,[[10,0],[7,[19,L.prototype.Fa.round,[[20,9,M.prototype.Fa.Ci,q,p]]]]]]]]]],[0,p,q,[[-1,L.prototype.C.Pr,
p,0,q,q,q,[[0,[1,0.13]]]]],[[-1,L.prototype.L.rs,p,[[5,[0,2]],[0,[7,[5,[0,100],[21,5,q,p,0]],[0,2]]]]],[11,xd.prototype.L.Ql,p,[[0,[21,5,q,p,0]]]],[12,xd.prototype.L.Ql,p,[[0,[6,[21,5,q,p,1],[0,16]]]]]],[[0,p,q,[[5,M.prototype.C.Fo,p,0,q,q,q,[[8,4],[0,[0,91]]]]],[[5,M.prototype.L.Ul,p,[[10,0],[7,[0,1]]]]]]]],[0,p,q,[[5,M.prototype.C.li,p,0,q,q,q,[[10,1],[8,0],[7,[0,0]]]]],[[-1,L.prototype.L.Oj,p,[[6,"Dead"]]]]]]],["DeadEvent",[[0,p,q,[[14,Tc.prototype.C.Jl,p,1,q,q,q]],[[-1,L.prototype.L.Oj,p,[[6,
"Main"]]],[-1,L.prototype.L.Ro,p]]]]],["Event sheet 1",[[0,p,q,[[14,Tc.prototype.C.Jl,p,1,q,q,q]],[[-1,L.prototype.L.Oj,p,[[6,"Main"]]],[-1,L.prototype.L.Ro,p]]]]]],"media/",m,800,500,4,m,q,q,"1.1",1,q,0,q,[]]};