/*! * @license easeljs * visit http://createjs.com/ for documentation, updates and examples. * * copyright (c) 2011-2015 gskinner.com, inc. * * distributed under the terms of the mit license. * http://www.opensource.org/licenses/mit-license.html * * this notice shall be included in all copies or substantial portions of the software. */ this.createjs=this.createjs||{},createjs.extend=function(a,b){"use strict";function c(){this.constructor=a}return c.prototype=b.prototype,a.prototype=new c},this.createjs=this.createjs||{},createjs.promote=function(a,b){"use strict";var c=a.prototype,d=object.getprototypeof&&object.getprototypeof(c)||c.__proto__;if(d){c[(b+="_")+"constructor"]=d.constructor;for(var e in d)c.hasownproperty(e)&&"function"==typeof d[e]&&(c[b+e]=d[e])}return a},this.createjs=this.createjs||{},createjs.indexof=function(a,b){"use strict";for(var c=0,d=a.length;d>c;c++)if(b===a[c])return c;return-1},this.createjs=this.createjs||{},function(){"use strict";function a(a,b,c){this.type=a,this.target=null,this.currenttarget=null,this.eventphase=0,this.bubbles=!!b,this.cancelable=!!c,this.timestamp=(new date).gettime(),this.defaultprevented=!1,this.propagationstopped=!1,this.immediatepropagationstopped=!1,this.removed=!1}var b=a.prototype;b.preventdefault=function(){this.defaultprevented=this.cancelable&&!0},b.stoppropagation=function(){this.propagationstopped=!0},b.stopimmediatepropagation=function(){this.immediatepropagationstopped=this.propagationstopped=!0},b.remove=function(){this.removed=!0},b.clone=function(){return new a(this.type,this.bubbles,this.cancelable)},b.set=function(a){for(var b in a)this[b]=a[b];return this},b.tostring=function(){return"[event (type="+this.type+")]"},createjs.event=a}(),this.createjs=this.createjs||{},function(){"use strict";function a(){this._listeners=null,this._capturelisteners=null}var b=a.prototype;a.initialize=function(a){a.addeventlistener=b.addeventlistener,a.on=b.on,a.removeeventlistener=a.off=b.removeeventlistener,a.removealleventlisteners=b.removealleventlisteners,a.haseventlistener=b.haseventlistener,a.dispatchevent=b.dispatchevent,a._dispatchevent=b._dispatchevent,a.willtrigger=b.willtrigger},b.addeventlistener=function(a,b,c){var d;d=c?this._capturelisteners=this._capturelisteners||{}:this._listeners=this._listeners||{};var e=d[a];return e&&this.removeeventlistener(a,b,c),e=d[a],e?e.push(b):d[a]=[b],b},b.on=function(a,b,c,d,e,f){return b.handleevent&&(c=c||b,b=b.handleevent),c=c||this,this.addeventlistener(a,function(a){b.call(c,a,e),d&&a.remove()},f)},b.removeeventlistener=function(a,b,c){var d=c?this._capturelisteners:this._listeners;if(d){var e=d[a];if(e)for(var f=0,g=e.length;g>f;f++)if(e[f]==b){1==g?delete d[a]:e.splice(f,1);break}}},b.off=b.removeeventlistener,b.removealleventlisteners=function(a){a?(this._listeners&&delete this._listeners[a],this._capturelisteners&&delete this._capturelisteners[a]):this._listeners=this._capturelisteners=null},b.dispatchevent=function(a,b,c){if("string"==typeof a){var d=this._listeners;if(!(b||d&&d[a]))return!0;a=new createjs.event(a,b,c)}else a.target&&a.clone&&(a=a.clone());try{a.target=this}catch(e){}if(a.bubbles&&this.parent){for(var f=this,g=[f];f.parent;)g.push(f=f.parent);var h,i=g.length;for(h=i-1;h>=0&&!a.propagationstopped;h--)g[h]._dispatchevent(a,1+(0==h));for(h=1;i>h&&!a.propagationstopped;h++)g[h]._dispatchevent(a,3)}else this._dispatchevent(a,2);return!a.defaultprevented},b.haseventlistener=function(a){var b=this._listeners,c=this._capturelisteners;return!!(b&&b[a]||c&&c[a])},b.willtrigger=function(a){for(var b=this;b;){if(b.haseventlistener(a))return!0;b=b.parent}return!1},b.tostring=function(){return"[eventdispatcher]"},b._dispatchevent=function(a,b){var c,d=1==b?this._capturelisteners:this._listeners;if(a&&d){var e=d[a.type];if(!e||!(c=e.length))return;try{a.currenttarget=this}catch(f){}try{a.eventphase=b}catch(f){}a.removed=!1,e=e.slice();for(var g=0;c>g&&!a.immediatepropagationstopped;g++){var h=e[g];h.handleevent?h.handleevent(a):h(a),a.removed&&(this.off(a.type,h,1==b),a.removed=!1)}}},createjs.eventdispatcher=a}(),this.createjs=this.createjs||{},function(){"use strict";function a(){throw"ticker cannot be instantiated."}a.raf_synched="synched",a.raf="raf",a.timeout="timeout",a.useraf=!1,a.timingmode=null,a.maxdelta=0,a.paused=!1,a.removeeventlistener=null,a.removealleventlisteners=null,a.dispatchevent=null,a.haseventlistener=null,a._listeners=null,createjs.eventdispatcher.initialize(a),a._addeventlistener=a.addeventlistener,a.addeventlistener=function(){return!a._inited&&a.init(),a._addeventlistener.apply(a,arguments)},a._inited=!1,a._starttime=0,a._pausedtime=0,a._ticks=0,a._pausedticks=0,a._interval=50,a._lasttime=0,a._times=null,a._ticktimes=null,a._timerid=null,a._raf=!0,a.setinterval=function(b){a._interval=b,a._inited&&a._setuptick()},a.getinterval=function(){return a._interval},a.setfps=function(b){a.setinterval(1e3/b)},a.getfps=function(){return 1e3/a._interval};try{object.defineproperties(a,{interval:{get:a.getinterval,set:a.setinterval},framerate:{get:a.getfps,set:a.setfps}})}catch(b){console.log(b)}a.init=function(){a._inited||(a._inited=!0,a._times=[],a._ticktimes=[],a._starttime=a._gettime(),a._times.push(a._lasttime=0),a.interval=a._interval)},a.reset=function(){if(a._raf){var b=window.cancelanimationframe||window.webkitcancelanimationframe||window.mozcancelanimationframe||window.ocancelanimationframe||window.mscancelanimationframe;b&&b(a._timerid)}else cleartimeout(a._timerid);a.removealleventlisteners("tick"),a._timerid=a._times=a._ticktimes=null,a._starttime=a._lasttime=a._ticks=0,a._inited=!1},a.getmeasuredticktime=function(b){var c=0,d=a._ticktimes;if(!d||d.length<1)return-1;b=math.min(d.length,b||0|a.getfps());for(var e=0;b>e;e++)c+=d[e];return c/b},a.getmeasuredfps=function(b){var c=a._times;return!c||c.length<2?-1:(b=math.min(c.length-1,b||0|a.getfps()),1e3/((c[0]-c[b])/b))},a.setpaused=function(b){a.paused=b},a.getpaused=function(){return a.paused},a.gettime=function(b){return a._starttime?a._gettime()-(b?a._pausedtime:0):-1},a.geteventtime=function(b){return a._starttime?(a._lasttime||a._starttime)-(b?a._pausedtime:0):-1},a.getticks=function(b){return a._ticks-(b?a._pausedticks:0)},a._handlesynch=function(){a._timerid=null,a._setuptick(),a._gettime()-a._lasttime>=.97*(a._interval-1)&&a._tick()},a._handleraf=function(){a._timerid=null,a._setuptick(),a._tick()},a._handletimeout=function(){a._timerid=null,a._setuptick(),a._tick()},a._setuptick=function(){if(null==a._timerid){var b=a.timingmode||a.useraf&&a.raf_synched;if(b==a.raf_synched||b==a.raf){var c=window.requestanimationframe||window.webkitrequestanimationframe||window.mozrequestanimationframe||window.orequestanimationframe||window.msrequestanimationframe;if(c)return a._timerid=c(b==a.raf?a._handleraf:a._handlesynch),void(a._raf=!0)}a._raf=!1,a._timerid=settimeout(a._handletimeout,a._interval)}},a._tick=function(){var b=a.paused,c=a._gettime(),d=c-a._lasttime;if(a._lasttime=c,a._ticks++,b&&(a._pausedticks++,a._pausedtime+=d),a.haseventlistener("tick")){var e=new createjs.event("tick"),f=a.maxdelta;e.delta=f&&d>f?f:d,e.paused=b,e.time=c,e.runtime=c-a._pausedtime,a.dispatchevent(e)}for(a._ticktimes.unshift(a._gettime()-c);a._ticktimes.length>100;)a._ticktimes.pop();for(a._times.unshift(c);a._times.length>100;)a._times.pop()};var c=window.performance&&(performance.now||performance.moznow||performance.msnow||performance.onow||performance.webkitnow);a._gettime=function(){return(c&&c.call(performance)||(new date).gettime())-a._starttime},createjs.ticker=a}(),this.createjs=this.createjs||{},function(){"use strict";function a(){throw"uid cannot be instantiated"}a._nextid=0,a.get=function(){return a._nextid++},createjs.uid=a}(),this.createjs=this.createjs||{},function(){"use strict";function a(a,b,c,d,e,f,g,h,i,j,k){this.event_constructor(a,b,c),this.stagex=d,this.stagey=e,this.rawx=null==i?d:i,this.rawy=null==j?e:j,this.nativeevent=f,this.pointerid=g,this.primary=!!h,this.relatedtarget=k}var b=createjs.extend(a,createjs.event);b._get_localx=function(){return this.currenttarget.globaltolocal(this.rawx,this.rawy).x},b._get_localy=function(){return this.currenttarget.globaltolocal(this.rawx,this.rawy).y},b._get_istouch=function(){return-1!==this.pointerid};try{object.defineproperties(b,{localx:{get:b._get_localx},localy:{get:b._get_localy},istouch:{get:b._get_istouch}})}catch(c){}b.clone=function(){return new a(this.type,this.bubbles,this.cancelable,this.stagex,this.stagey,this.nativeevent,this.pointerid,this.primary,this.rawx,this.rawy)},b.tostring=function(){return"[mouseevent (type="+this.type+" stagex="+this.stagex+" stagey="+this.stagey+")]"},createjs.mouseevent=createjs.promote(a,"event")}(),this.createjs=this.createjs||{},function(){"use strict";function a(a,b,c,d,e,f){this.setvalues(a,b,c,d,e,f)}var b=a.prototype;a.deg_to_rad=math.pi/180,a.identity=null,b.setvalues=function(a,b,c,d,e,f){return this.a=null==a?1:a,this.b=b||0,this.c=c||0,this.d=null==d?1:d,this.tx=e||0,this.ty=f||0,this},b.append=function(a,b,c,d,e,f){var g=this.a,h=this.b,i=this.c,j=this.d;return(1!=a||0!=b||0!=c||1!=d)&&(this.a=g*a+i*b,this.b=h*a+j*b,this.c=g*c+i*d,this.d=h*c+j*d),this.tx=g*e+i*f+this.tx,this.ty=h*e+j*f+this.ty,this},b.prepend=function(a,b,c,d,e,f){var g=this.a,h=this.c,i=this.tx;return this.a=a*g+c*this.b,this.b=b*g+d*this.b,this.c=a*h+c*this.d,this.d=b*h+d*this.d,this.tx=a*i+c*this.ty+e,this.ty=b*i+d*this.ty+f,this},b.appendmatrix=function(a){return this.append(a.a,a.b,a.c,a.d,a.tx,a.ty)},b.prependmatrix=function(a){return this.prepend(a.a,a.b,a.c,a.d,a.tx,a.ty)},b.appendtransform=function(b,c,d,e,f,g,h,i,j){if(f%360)var k=f*a.deg_to_rad,l=math.cos(k),m=math.sin(k);else l=1,m=0;return g||h?(g*=a.deg_to_rad,h*=a.deg_to_rad,this.append(math.cos(h),math.sin(h),-math.sin(g),math.cos(g),b,c),this.append(l*d,m*d,-m*e,l*e,0,0)):this.append(l*d,m*d,-m*e,l*e,b,c),(i||j)&&(this.tx-=i*this.a+j*this.c,this.ty-=i*this.b+j*this.d),this},b.prependtransform=function(b,c,d,e,f,g,h,i,j){if(f%360)var k=f*a.deg_to_rad,l=math.cos(k),m=math.sin(k);else l=1,m=0;return(i||j)&&(this.tx-=i,this.ty-=j),g||h?(g*=a.deg_to_rad,h*=a.deg_to_rad,this.prepend(l*d,m*d,-m*e,l*e,0,0),this.prepend(math.cos(h),math.sin(h),-math.sin(g),math.cos(g),b,c)):this.prepend(l*d,m*d,-m*e,l*e,b,c),this},b.rotate=function(b){b*=a.deg_to_rad;var c=math.cos(b),d=math.sin(b),e=this.a,f=this.b;return this.a=e*c+this.c*d,this.b=f*c+this.d*d,this.c=-e*d+this.c*c,this.d=-f*d+this.d*c,this},b.skew=function(b,c){return b*=a.deg_to_rad,c*=a.deg_to_rad,this.append(math.cos(c),math.sin(c),-math.sin(b),math.cos(b),0,0),this},b.scale=function(a,b){return this.a*=a,this.b*=a,this.c*=b,this.d*=b,this},b.translate=function(a,b){return this.tx+=this.a*a+this.c*b,this.ty+=this.b*a+this.d*b,this},b.identity=function(){return this.a=this.d=1,this.b=this.c=this.tx=this.ty=0,this},b.invert=function(){var a=this.a,b=this.b,c=this.c,d=this.d,e=this.tx,f=a*d-b*c;return this.a=d/f,this.b=-b/f,this.c=-c/f,this.d=a/f,this.tx=(c*this.ty-d*e)/f,this.ty=-(a*this.ty-b*e)/f,this},b.isidentity=function(){return 0===this.tx&&0===this.ty&&1===this.a&&0===this.b&&0===this.c&&1===this.d},b.equals=function(a){return this.tx===a.tx&&this.ty===a.ty&&this.a===a.a&&this.b===a.b&&this.c===a.c&&this.d===a.d},b.transformpoint=function(a,b,c){return c=c||{},c.x=a*this.a+b*this.c+this.tx,c.y=a*this.b+b*this.d+this.ty,c},b.decompose=function(b){null==b&&(b={}),b.x=this.tx,b.y=this.ty,b.scalex=math.sqrt(this.a*this.a+this.b*this.b),b.scaley=math.sqrt(this.c*this.c+this.d*this.d);var c=math.atan2(-this.c,this.d),d=math.atan2(this.b,this.a),e=math.abs(1-c/d);return 1e-5>e?(b.rotation=d/a.deg_to_rad,this.a<0&&this.d>=0&&(b.rotation+=b.rotation<=0?180:-180),b.skewx=b.skewy=0):(b.skewx=c/a.deg_to_rad,b.skewy=d/a.deg_to_rad),b},b.copy=function(a){return this.setvalues(a.a,a.b,a.c,a.d,a.tx,a.ty)},b.clone=function(){return new a(this.a,this.b,this.c,this.d,this.tx,this.ty)},b.tostring=function(){return"[matrix2d (a="+this.a+" b="+this.b+" c="+this.c+" d="+this.d+" tx="+this.tx+" ty="+this.ty+")]"},a.identity=new a,createjs.matrix2d=a}(),this.createjs=this.createjs||{},function(){"use strict";function a(a,b,c,d,e){this.setvalues(a,b,c,d,e)}var b=a.prototype;b.setvalues=function(a,b,c,d,e){return this.visible=null==a?!0:!!a,this.alpha=null==b?1:b,this.shadow=c,this.compositeoperation=d,this.matrix=e||this.matrix&&this.matrix.identity()||new createjs.matrix2d,this},b.append=function(a,b,c,d,e){return this.alpha*=b,this.shadow=c||this.shadow,this.compositeoperation=d||this.compositeoperation,this.visible=this.visible&&a,e&&this.matrix.appendmatrix(e),this},b.prepend=function(a,b,c,d,e){return this.alpha*=b,this.shadow=this.shadow||c,this.compositeoperation=this.compositeoperation||d,this.visible=this.visible&&a,e&&this.matrix.prependmatrix(e),this},b.identity=function(){return this.visible=!0,this.alpha=1,this.shadow=this.compositeoperation=null,this.matrix.identity(),this},b.clone=function(){return new a(this.alpha,this.shadow,this.compositeoperation,this.visible,this.matrix.clone())},createjs.displayprops=a}(),this.createjs=this.createjs||{},function(){"use strict";function a(a,b){this.setvalues(a,b)}var b=a.prototype;b.setvalues=function(a,b){return this.x=a||0,this.y=b||0,this},b.copy=function(a){return this.x=a.x,this.y=a.y,this},b.clone=function(){return new a(this.x,this.y)},b.tostring=function(){return"[point (x="+this.x+" y="+this.y+")]"},createjs.point=a}(),this.createjs=this.createjs||{},function(){"use strict";function a(a,b,c,d){this.setvalues(a,b,c,d)}var b=a.prototype;b.setvalues=function(a,b,c,d){return this.x=a||0,this.y=b||0,this.width=c||0,this.height=d||0,this},b.extend=function(a,b,c,d){return c=c||0,d=d||0,a+c>this.x+this.width&&(this.width=a+c-this.x),b+d>this.y+this.height&&(this.height=b+d-this.y),a=this.x&&a+c<=this.x+this.width&&b>=this.y&&b+d<=this.y+this.height},b.union=function(a){return this.clone().extend(a.x,a.y,a.width,a.height)},b.intersection=function(b){var c=b.x,d=b.y,e=c+b.width,f=d+b.height;return this.x>c&&(c=this.x),this.y>d&&(d=this.y),this.x+this.width=e||d>=f?null:new a(c,d,e-c,f-d)},b.intersects=function(a){return a.x<=this.x+this.width&&this.x<=a.x+a.width&&a.y<=this.y+this.height&&this.y<=a.y+a.height},b.isempty=function(){return this.width<=0||this.height<=0},b.clone=function(){return new a(this.x,this.y,this.width,this.height)},b.tostring=function(){return"[rectangle (x="+this.x+" y="+this.y+" width="+this.width+" height="+this.height+")]"},createjs.rectangle=a}(),this.createjs=this.createjs||{},function(){"use strict";function a(a,b,c,d,e,f,g){a.addeventlistener&&(this.target=a,this.overlabel=null==c?"over":c,this.outlabel=null==b?"out":b,this.downlabel=null==d?"down":d,this.play=e,this._ispressed=!1,this._isover=!1,this._enabled=!1,a.mousechildren=!1,this.enabled=!0,this.handleevent({}),f&&(g&&(f.actionsenabled=!1,f.gotoandstop&&f.gotoandstop(g)),a.hitarea=f))}var b=a.prototype;b.setenabled=function(a){if(a!=this._enabled){var b=this.target;this._enabled=a,a?(b.cursor="pointer",b.addeventlistener("rollover",this),b.addeventlistener("rollout",this),b.addeventlistener("mousedown",this),b.addeventlistener("pressup",this),b._reset&&(b.__reset=b._reset,b._reset=this._reset)):(b.cursor=null,b.removeeventlistener("rollover",this),b.removeeventlistener("rollout",this),b.removeeventlistener("mousedown",this),b.removeeventlistener("pressup",this),b.__reset&&(b._reset=b.__reset,delete b.__reset))}},b.getenabled=function(){return this._enabled};try{object.defineproperties(b,{enabled:{get:b.getenabled,set:b.setenabled}})}catch(c){}b.tostring=function(){return"[buttonhelper]"},b.handleevent=function(a){var b,c=this.target,d=a.type;"mousedown"==d?(this._ispressed=!0,b=this.downlabel):"pressup"==d?(this._ispressed=!1,b=this._isover?this.overlabel:this.outlabel):"rollover"==d?(this._isover=!0,b=this._ispressed?this.downlabel:this.overlabel):(this._isover=!1,b=this._ispressed?this.overlabel:this.outlabel),this.play?c.gotoandplay&&c.gotoandplay(b):c.gotoandstop&&c.gotoandstop(b)},b._reset=function(){var a=this.paused;this.__reset(),this.paused=a},createjs.buttonhelper=a}(),this.createjs=this.createjs||{},function(){"use strict";function a(a,b,c,d){this.color=a||"black",this.offsetx=b||0,this.offsety=c||0,this.blur=d||0}var b=a.prototype;a.identity=new a("transparent",0,0,0),b.tostring=function(){return"[shadow]"},b.clone=function(){return new a(this.color,this.offsetx,this.offsety,this.blur)},createjs.shadow=a}(),this.createjs=this.createjs||{},function(){"use strict";function a(a){this.eventdispatcher_constructor(),this.complete=!0,this.framerate=0,this._animations=null,this._frames=null,this._images=null,this._data=null,this._loadcount=0,this._frameheight=0,this._framewidth=0,this._numframes=0,this._regx=0,this._regy=0,this._spacing=0,this._margin=0,this._parsedata(a)}var b=createjs.extend(a,createjs.eventdispatcher);b.getanimations=function(){return this._animations.slice()};try{object.defineproperties(b,{animations:{get:b.getanimations}})}catch(c){}b.getnumframes=function(a){if(null==a)return this._frames?this._frames.length:this._numframes||0;var b=this._data[a];return null==b?0:b.frames.length},b.getanimation=function(a){return this._data[a]},b.getframe=function(a){var b;return this._frames&&(b=this._frames[a])?b:null},b.getframebounds=function(a,b){var c=this.getframe(a);return c?(b||new createjs.rectangle).setvalues(-c.regx,-c.regy,c.rect.width,c.rect.height):null},b.tostring=function(){return"[spritesheet]"},b.clone=function(){throw"spritesheet cannot be cloned."},b._parsedata=function(a){var b,c,d,e;if(null!=a){if(this.framerate=a.framerate||0,a.images&&(c=a.images.length)>0)for(e=this._images=[],b=0;c>b;b++){var f=a.images[b];if("string"==typeof f){var g=f;f=document.createelement("img"),f.src=g}e.push(f),f.getcontext||f.naturalwidth||(this._loadcount++,this.complete=!1,function(a,b){f.onload=function(){a._handleimageload(b)}}(this,g),function(a,b){f.onerror=function(){a._handleimageerror(b)}}(this,g))}if(null==a.frames);else if(array.isarray(a.frames))for(this._frames=[],e=a.frames,b=0,c=e.length;c>b;b++){var h=e[b];this._frames.push({image:this._images[h[4]?h[4]:0],rect:new createjs.rectangle(h[0],h[1],h[2],h[3]),regx:h[5]||0,regy:h[6]||0})}else d=a.frames,this._framewidth=d.width,this._frameheight=d.height,this._regx=d.regx||0,this._regy=d.regy||0,this._spacing=d.spacing||0,this._margin=d.margin||0,this._numframes=d.count,0==this._loadcount&&this._calculateframes();if(this._animations=[],null!=(d=a.animations)){this._data={};var i;for(i in d){var j={name:i},k=d[i];if("number"==typeof k)e=j.frames=[k];else if(array.isarray(k))if(1==k.length)j.frames=[k[0]];else for(j.speed=k[3],j.next=k[2],e=j.frames=[],b=k[0];b<=k[1];b++)e.push(b);else{j.speed=k.speed,j.next=k.next;var l=k.frames;e=j.frames="number"==typeof l?[l]:l.slice(0)}(j.next===!0||void 0===j.next)&&(j.next=i),(j.next===!1||e.length<2&&j.next==i)&&(j.next=null),j.speed||(j.speed=1),this._animations.push(i),this._data[i]=j}}}},b._handleimageload=function(){0==--this._loadcount&&(this._calculateframes(),this.complete=!0,this.dispatchevent("complete"))},b._handleimageerror=function(a){var b=new createjs.event("error");b.src=a,this.dispatchevent(b),0==--this._loadcount&&this.dispatchevent("complete")},b._calculateframes=function(){if(!this._frames&&0!=this._framewidth){this._frames=[];var a=this._numframes||1e5,b=0,c=this._framewidth,d=this._frameheight,e=this._spacing,f=this._margin;a:for(var g=0,h=this._images;g=l;){for(var m=f;j-f-c>=m;){if(b>=a)break a;b++,this._frames.push({image:i,rect:new createjs.rectangle(m,l,c,d),regx:this._regx,regy:this._regy}),m+=c+e}l+=d+e}this._numframes=b}},createjs.spritesheet=createjs.promote(a,"eventdispatcher")}(),this.createjs=this.createjs||{},function(){"use strict";function a(){this.command=null,this._stroke=null,this._strokestyle=null,this._oldstrokestyle=null,this._strokedash=null,this._oldstrokedash=null,this._strokeignorescale=!1,this._fill=null,this._instructions=[],this._commitindex=0,this._activeinstructions=[],this._dirty=!1,this._storeindex=0,this.clear()}var b=a.prototype,c=a;a.getrgb=function(a,b,c,d){return null!=a&&null==c&&(d=b,c=255&a,b=a>>8&255,a=a>>16&255),null==d?"rgb("+a+","+b+","+c+")":"rgba("+a+","+b+","+c+","+d+")"},a.gethsl=function(a,b,c,d){return null==d?"hsl("+a%360+","+b+"%,"+c+"%)":"hsla("+a%360+","+b+"%,"+c+"%,"+d+")"},a.base_64={a:0,b:1,c:2,d:3,e:4,f:5,g:6,h:7,i:8,j:9,k:10,l:11,m:12,n:13,o:14,p:15,q:16,r:17,s:18,t:19,u:20,v:21,w:22,x:23,y:24,z:25,a:26,b:27,c:28,d:29,e:30,f:31,g:32,h:33,i:34,j:35,k:36,l:37,m:38,n:39,o:40,p:41,q:42,r:43,s:44,t:45,u:46,v:47,w:48,x:49,y:50,z:51,0:52,1:53,2:54,3:55,4:56,5:57,6:58,7:59,8:60,9:61,"+":62,"/":63},a.stroke_caps_map=["butt","round","square"],a.stroke_joints_map=["miter","round","bevel"];var d=createjs.createcanvas?createjs.createcanvas():document.createelement("canvas");d.getcontext&&(a._ctx=d.getcontext("2d"),d.width=d.height=1),b.getinstructions=function(){return this._updateinstructions(),this._instructions};try{object.defineproperties(b,{instructions:{get:b.getinstructions}})}catch(e){}b.isempty=function(){return!(this._instructions.length||this._activeinstructions.length)},b.draw=function(a,b){this._updateinstructions();for(var c=this._instructions,d=this._storeindex,e=c.length;e>d;d++)c[d].exec(a,b)},b.drawaspath=function(a){this._updateinstructions();for(var b,c=this._instructions,d=this._storeindex,e=c.length;e>d;d++)(b=c[d]).path!==!1&&b.exec(a)},b.moveto=function(a,b){return this.append(new c.moveto(a,b),!0)},b.lineto=function(a,b){return this.append(new c.lineto(a,b))},b.arcto=function(a,b,d,e,f){return this.append(new c.arcto(a,b,d,e,f))},b.arc=function(a,b,d,e,f,g){return this.append(new c.arc(a,b,d,e,f,g))},b.quadraticcurveto=function(a,b,d,e){return this.append(new c.quadraticcurveto(a,b,d,e))},b.beziercurveto=function(a,b,d,e,f,g){return this.append(new c.beziercurveto(a,b,d,e,f,g))},b.rect=function(a,b,d,e){return this.append(new c.rect(a,b,d,e))},b.closepath=function(){return this._activeinstructions.length?this.append(new c.closepath):this},b.clear=function(){return this._instructions.length=this._activeinstructions.length=this._commitindex=0,this._strokestyle=this._oldstrokestyle=this._stroke=this._fill=this._strokedash=this._oldstrokedash=null,this._dirty=this._strokeignorescale=!1,this},b.beginfill=function(a){return this._setfill(a?new c.fill(a):null)},b.beginlineargradientfill=function(a,b,d,e,f,g){return this._setfill((new c.fill).lineargradient(a,b,d,e,f,g))},b.beginradialgradientfill=function(a,b,d,e,f,g,h,i){return this._setfill((new c.fill).radialgradient(a,b,d,e,f,g,h,i))},b.beginbitmapfill=function(a,b,d){return this._setfill(new c.fill(null,d).bitmap(a,b))},b.endfill=function(){return this.beginfill()},b.setstrokestyle=function(a,b,d,e,f){return this._updateinstructions(!0),this._strokestyle=this.command=new c.strokestyle(a,b,d,e,f),this._stroke&&(this._stroke.ignorescale=f),this._strokeignorescale=f,this},b.setstrokedash=function(a,b){return this._updateinstructions(!0),this._strokedash=this.command=new c.strokedash(a,b),this},b.beginstroke=function(a){return this._setstroke(a?new c.stroke(a):null)},b.beginlineargradientstroke=function(a,b,d,e,f,g){return this._setstroke((new c.stroke).lineargradient(a,b,d,e,f,g))},b.beginradialgradientstroke=function(a,b,d,e,f,g,h,i){return this._setstroke((new c.stroke).radialgradient(a,b,d,e,f,g,h,i))},b.beginbitmapstroke=function(a,b){return this._setstroke((new c.stroke).bitmap(a,b))},b.endstroke=function(){return this.beginstroke()},b.curveto=b.quadraticcurveto,b.drawrect=b.rect,b.drawroundrect=function(a,b,c,d,e){return this.drawroundrectcomplex(a,b,c,d,e,e,e,e)},b.drawroundrectcomplex=function(a,b,d,e,f,g,h,i){return this.append(new c.roundrect(a,b,d,e,f,g,h,i))},b.drawcircle=function(a,b,d){return this.append(new c.circle(a,b,d))},b.drawellipse=function(a,b,d,e){return this.append(new c.ellipse(a,b,d,e))},b.drawpolystar=function(a,b,d,e,f,g){return this.append(new c.polystar(a,b,d,e,f,g))},b.append=function(a,b){return this._activeinstructions.push(a),this.command=a,b||(this._dirty=!0),this},b.decodepath=function(b){for(var c=[this.moveto,this.lineto,this.quadraticcurveto,this.beziercurveto,this.closepath],d=[2,2,4,6,0],e=0,f=b.length,g=[],h=0,i=0,j=a.base_64;f>e;){var k=b.charat(e),l=j[k],m=l>>3,n=c[m];if(!n||3&l)throw"bad path data (@"+e+"): "+k;var o=d[m];m||(h=i=0),g.length=0,e++;for(var p=(l>>2&1)+2,q=0;o>q;q++){var r=j[b.charat(e)],s=r>>5?-1:1;r=(31&r)<<6|j[b.charat(e+1)],3==p&&(r=r<<6|j[b.charat(e+2)]),r=s*r/10,q%2?h=r+=h:i=r+=i,g[q]=r,e+=p}n.apply(this,g)}return this},b.store=function(){return this._updateinstructions(!0),this._storeindex=this._instructions.length,this},b.unstore=function(){return this._storeindex=0,this},b.clone=function(){var b=new a;return b.command=this.command,b._stroke=this._stroke,b._strokestyle=this._strokestyle,b._strokedash=this._strokedash,b._strokeignorescale=this._strokeignorescale,b._fill=this._fill,b._instructions=this._instructions.slice(),b._commitindex=this._commitindex,b._activeinstructions=this._activeinstructions.slice(),b._dirty=this._dirty,b._storeindex=this._storeindex,b},b.tostring=function(){return"[graphics]"},b.mt=b.moveto,b.lt=b.lineto,b.at=b.arcto,b.bt=b.beziercurveto,b.qt=b.quadraticcurveto,b.a=b.arc,b.r=b.rect,b.cp=b.closepath,b.c=b.clear,b.f=b.beginfill,b.lf=b.beginlineargradientfill,b.rf=b.beginradialgradientfill,b.bf=b.beginbitmapfill,b.ef=b.endfill,b.ss=b.setstrokestyle,b.sd=b.setstrokedash,b.s=b.beginstroke,b.ls=b.beginlineargradientstroke,b.rs=b.beginradialgradientstroke,b.bs=b.beginbitmapstroke,b.es=b.endstroke,b.dr=b.drawrect,b.rr=b.drawroundrect,b.rc=b.drawroundrectcomplex,b.dc=b.drawcircle,b.de=b.drawellipse,b.dp=b.drawpolystar,b.p=b.decodepath,b._updateinstructions=function(b){var c=this._instructions,d=this._activeinstructions,e=this._commitindex;if(this._dirty&&d.length){c.length=e,c.push(a.begincmd);var f=d.length,g=c.length;c.length=g+f;for(var h=0;f>h;h++)c[h+g]=d[h];this._fill&&c.push(this._fill),this._stroke&&(this._strokedash!==this._oldstrokedash&&(this._oldstrokedash=this._strokedash,c.push(this._strokedash)),this._strokestyle!==this._oldstrokestyle&&(this._oldstrokestyle=this._strokestyle,c.push(this._strokestyle)),c.push(this._stroke)),this._dirty=!1}b&&(d.length=0,this._commitindex=c.length)},b._setfill=function(a){return this._updateinstructions(!0),this.command=this._fill=a,this},b._setstroke=function(a){return this._updateinstructions(!0),(this.command=this._stroke=a)&&(a.ignorescale=this._strokeignorescale),this},(c.lineto=function(a,b){this.x=a,this.y=b}).prototype.exec=function(a){a.lineto(this.x,this.y)},(c.moveto=function(a,b){this.x=a,this.y=b}).prototype.exec=function(a){a.moveto(this.x,this.y)},(c.arcto=function(a,b,c,d,e){this.x1=a,this.y1=b,this.x2=c,this.y2=d,this.radius=e}).prototype.exec=function(a){a.arcto(this.x1,this.y1,this.x2,this.y2,this.radius)},(c.arc=function(a,b,c,d,e,f){this.x=a,this.y=b,this.radius=c,this.startangle=d,this.endangle=e,this.anticlockwise=!!f}).prototype.exec=function(a){a.arc(this.x,this.y,this.radius,this.startangle,this.endangle,this.anticlockwise)},(c.quadraticcurveto=function(a,b,c,d){this.cpx=a,this.cpy=b,this.x=c,this.y=d}).prototype.exec=function(a){a.quadraticcurveto(this.cpx,this.cpy,this.x,this.y)},(c.beziercurveto=function(a,b,c,d,e,f){this.cp1x=a,this.cp1y=b,this.cp2x=c,this.cp2y=d,this.x=e,this.y=f}).prototype.exec=function(a){a.beziercurveto(this.cp1x,this.cp1y,this.cp2x,this.cp2y,this.x,this.y)},(c.rect=function(a,b,c,d){this.x=a,this.y=b,this.w=c,this.h=d}).prototype.exec=function(a){a.rect(this.x,this.y,this.w,this.h)},(c.closepath=function(){}).prototype.exec=function(a){a.closepath()},(c.beginpath=function(){}).prototype.exec=function(a){a.beginpath()},b=(c.fill=function(a,b){this.style=a,this.matrix=b}).prototype,b.exec=function(a){if(this.style){a.fillstyle=this.style;var b=this.matrix;b&&(a.save(),a.transform(b.a,b.b,b.c,b.d,b.tx,b.ty)),a.fill(),b&&a.restore()}},b.lineargradient=function(b,c,d,e,f,g){for(var h=this.style=a._ctx.createlineargradient(d,e,f,g),i=0,j=b.length;j>i;i++)h.addcolorstop(c[i],b[i]);return h.props={colors:b,ratios:c,x0:d,y0:e,x1:f,y1:g,type:"linear"},this},b.radialgradient=function(b,c,d,e,f,g,h,i){for(var j=this.style=a._ctx.createradialgradient(d,e,f,g,h,i),k=0,l=b.length;l>k;k++)j.addcolorstop(c[k],b[k]);return j.props={colors:b,ratios:c,x0:d,y0:e,r0:f,x1:g,y1:h,r1:i,type:"radial"},this},b.bitmap=function(b,c){if(b.naturalwidth||b.getcontext||b.readystate>=2){var d=this.style=a._ctx.createpattern(b,c||"");d.props={image:b,repetition:c,type:"bitmap"}}return this},b.path=!1,b=(c.stroke=function(a,b){this.style=a,this.ignorescale=b}).prototype,b.exec=function(a){this.style&&(a.strokestyle=this.style,this.ignorescale&&(a.save(),a.settransform(1,0,0,1,0,0)),a.stroke(),this.ignorescale&&a.restore())},b.lineargradient=c.fill.prototype.lineargradient,b.radialgradient=c.fill.prototype.radialgradient,b.bitmap=c.fill.prototype.bitmap,b.path=!1,b=(c.strokestyle=function(a,b,c,d,e){this.width=a,this.caps=b,this.joints=c,this.miterlimit=d,this.ignorescale=e}).prototype,b.exec=function(b){b.linewidth=null==this.width?"1":this.width,b.linecap=null==this.caps?"butt":isnan(this.caps)?this.caps:a.stroke_caps_map[this.caps],b.linejoin=null==this.joints?"miter":isnan(this.joints)?this.joints:a.stroke_joints_map[this.joints],b.miterlimit=null==this.miterlimit?"10":this.miterlimit,b.ignorescale=null==this.ignorescale?!1:this.ignorescale},b.path=!1,(c.strokedash=function(a,b){this.segments=a,this.offset=b||0}).prototype.exec=function(a){a.setlinedash&&(a.setlinedash(this.segments||c.strokedash.empty_segments),a.linedashoffset=this.offset||0)},c.strokedash.empty_segments=[],(c.roundrect=function(a,b,c,d,e,f,g,h){this.x=a,this.y=b,this.w=c,this.h=d,this.radiustl=e,this.radiustr=f,this.radiusbr=g,this.radiusbl=h}).prototype.exec=function(a){var b=(j>i?i:j)/2,c=0,d=0,e=0,f=0,g=this.x,h=this.y,i=this.w,j=this.h,k=this.radiustl,l=this.radiustr,m=this.radiusbr,n=this.radiusbl;0>k&&(k*=c=-1),k>b&&(k=b),0>l&&(l*=d=-1),l>b&&(l=b),0>m&&(m*=e=-1),m>b&&(m=b),0>n&&(n*=f=-1),n>b&&(n=b),a.moveto(g+i-l,h),a.arcto(g+i+l*d,h-l*d,g+i,h+l,l),a.lineto(g+i,h+j-m),a.arcto(g+i+m*e,h+j+m*e,g+i-m,h+j,m),a.lineto(g+n,h+j),a.arcto(g-n*f,h+j+n*f,g,h+j-n,n),a.lineto(g,h+k),a.arcto(g-k*c,h-k*c,g+k,h,k),a.closepath()},(c.circle=function(a,b,c){this.x=a,this.y=b,this.radius=c}).prototype.exec=function(a){a.arc(this.x,this.y,this.radius,0,2*math.pi)},(c.ellipse=function(a,b,c,d){this.x=a,this.y=b,this.w=c,this.h=d}).prototype.exec=function(a){var b=this.x,c=this.y,d=this.w,e=this.h,f=.5522848,g=d/2*f,h=e/2*f,i=b+d,j=c+e,k=b+d/2,l=c+e/2;a.moveto(b,l),a.beziercurveto(b,l-h,k-g,c,k,c),a.beziercurveto(k+g,c,i,l-h,i,l),a.beziercurveto(i,l+h,k+g,j,k,j),a.beziercurveto(k-g,j,b,l+h,b,l)},(c.polystar=function(a,b,c,d,e,f){this.x=a,this.y=b,this.radius=c,this.sides=d,this.pointsize=e,this.angle=f}).prototype.exec=function(a){var b=this.x,c=this.y,d=this.radius,e=(this.angle||0)/180*math.pi,f=this.sides,g=1-(this.pointsize||0),h=math.pi/f;a.moveto(b+math.cos(e)*d,c+math.sin(e)*d);for(var i=0;f>i;i++)e+=h,1!=g&&a.lineto(b+math.cos(e)*d*g,c+math.sin(e)*d*g),e+=h,a.lineto(b+math.cos(e)*d,c+math.sin(e)*d);a.closepath()},a.begincmd=new c.beginpath,createjs.graphics=a}(),this.createjs=this.createjs||{},function(){"use strict";function a(){this.eventdispatcher_constructor(),this.alpha=1,this.cachecanvas=null,this.cacheid=0,this.id=createjs.uid.get(),this.mouseenabled=!0,this.tickenabled=!0,this.name=null,this.parent=null,this.regx=0,this.regy=0,this.rotation=0,this.scalex=1,this.scaley=1,this.skewx=0,this.skewy=0,this.shadow=null,this.visible=!0,this.x=0,this.y=0,this.transformmatrix=null,this.compositeoperation=null,this.snaptopixel=!0,this.filters=null,this.mask=null,this.hitarea=null,this.cursor=null,this._cacheoffsetx=0,this._cacheoffsety=0,this._filteroffsetx=0,this._filteroffsety=0,this._cachescale=1,this._cachedataurlid=0,this._cachedataurl=null,this._props=new createjs.displayprops,this._rectangle=new createjs.rectangle,this._bounds=null }var b=createjs.extend(a,createjs.eventdispatcher);a._mouse_events=["click","dblclick","mousedown","mouseout","mouseover","pressmove","pressup","rollout","rollover"],a.suppresscrossdomainerrors=!1,a._snaptopixelenabled=!1;var c=createjs.createcanvas?createjs.createcanvas():document.createelement("canvas");c.getcontext&&(a._hittestcanvas=c,a._hittestcontext=c.getcontext("2d"),c.width=c.height=1),a._nextcacheid=1,b.getstage=function(){for(var a=this,b=createjs.stage;a.parent;)a=a.parent;return a instanceof b?a:null};try{object.defineproperties(b,{stage:{get:b.getstage}})}catch(d){}b.isvisible=function(){return!!(this.visible&&this.alpha>0&&0!=this.scalex&&0!=this.scaley)},b.draw=function(a,b){var c=this.cachecanvas;if(b||!c)return!1;var d=this._cachescale;return a.drawimage(c,this._cacheoffsetx+this._filteroffsetx,this._cacheoffsety+this._filteroffsety,c.width/d,c.height/d),!0},b.updatecontext=function(b){var c=this,d=c.mask,e=c._props.matrix;d&&d.graphics&&!d.graphics.isempty()&&(d.getmatrix(e),b.transform(e.a,e.b,e.c,e.d,e.tx,e.ty),d.graphics.drawaspath(b),b.clip(),e.invert(),b.transform(e.a,e.b,e.c,e.d,e.tx,e.ty)),this.getmatrix(e);var f=e.tx,g=e.ty;a._snaptopixelenabled&&c.snaptopixel&&(f=f+(0>f?-.5:.5)|0,g=g+(0>g?-.5:.5)|0),b.transform(e.a,e.b,e.c,e.d,f,g),b.globalalpha*=c.alpha,c.compositeoperation&&(b.globalcompositeoperation=c.compositeoperation),c.shadow&&this._applyshadow(b,c.shadow)},b.cache=function(a,b,c,d,e){e=e||1,this.cachecanvas||(this.cachecanvas=createjs.createcanvas?createjs.createcanvas():document.createelement("canvas")),this._cachewidth=c,this._cacheheight=d,this._cacheoffsetx=a,this._cacheoffsety=b,this._cachescale=e,this.updatecache()},b.updatecache=function(b){var c=this.cachecanvas;if(!c)throw"cache() must be called before updatecache()";var d=this._cachescale,e=this._cacheoffsetx*d,f=this._cacheoffsety*d,g=this._cachewidth,h=this._cacheheight,i=c.getcontext("2d"),j=this._getfilterbounds();e+=this._filteroffsetx=j.x,f+=this._filteroffsety=j.y,g=math.ceil(g*d)+j.width,h=math.ceil(h*d)+j.height,g!=c.width||h!=c.height?(c.width=g,c.height=h):b||i.clearrect(0,0,g+1,h+1),i.save(),i.globalcompositeoperation=b,i.settransform(d,0,0,d,-e,-f),this.draw(i,!0),this._applyfilters(),i.restore(),this.cacheid=a._nextcacheid++},b.uncache=function(){this._cachedataurl=this.cachecanvas=null,this.cacheid=this._cacheoffsetx=this._cacheoffsety=this._filteroffsetx=this._filteroffsety=0,this._cachescale=1},b.getcachedataurl=function(){return this.cachecanvas?(this.cacheid!=this._cachedataurlid&&(this._cachedataurl=this.cachecanvas.todataurl()),this._cachedataurl):null},b.localtoglobal=function(a,b,c){return this.getconcatenatedmatrix(this._props.matrix).transformpoint(a,b,c||new createjs.point)},b.globaltolocal=function(a,b,c){return this.getconcatenatedmatrix(this._props.matrix).invert().transformpoint(a,b,c||new createjs.point)},b.localtolocal=function(a,b,c,d){return d=this.localtoglobal(a,b,d),c.globaltolocal(d.x,d.y,d)},b.settransform=function(a,b,c,d,e,f,g,h,i){return this.x=a||0,this.y=b||0,this.scalex=null==c?1:c,this.scaley=null==d?1:d,this.rotation=e||0,this.skewx=f||0,this.skewy=g||0,this.regx=h||0,this.regy=i||0,this},b.getmatrix=function(a){var b=this,c=a&&a.identity()||new createjs.matrix2d;return b.transformmatrix?c.copy(b.transformmatrix):c.appendtransform(b.x,b.y,b.scalex,b.scaley,b.rotation,b.skewx,b.skewy,b.regx,b.regy)},b.getconcatenatedmatrix=function(a){for(var b=this,c=this.getmatrix(a);b=b.parent;)c.prependmatrix(b.getmatrix(b._props.matrix));return c},b.getconcatenateddisplayprops=function(a){a=a?a.identity():new createjs.displayprops;var b=this,c=b.getmatrix(a.matrix);do a.prepend(b.visible,b.alpha,b.shadow,b.compositeoperation),b!=this&&c.prependmatrix(b.getmatrix(b._props.matrix));while(b=b.parent);return a},b.hittest=function(b,c){var d=a._hittestcontext;d.settransform(1,0,0,1,-b,-c),this.draw(d);var e=this._testhit(d);return d.settransform(1,0,0,1,0,0),d.clearrect(0,0,2,2),e},b.set=function(a){for(var b in a)this[b]=a[b];return this},b.getbounds=function(){if(this._bounds)return this._rectangle.copy(this._bounds);var a=this.cachecanvas;if(a){var b=this._cachescale;return this._rectangle.setvalues(this._cacheoffsetx,this._cacheoffsety,a.width/b,a.height/b)}return null},b.gettransformedbounds=function(){return this._getbounds()},b.setbounds=function(a,b,c,d){null==a&&(this._bounds=a),this._bounds=(this._bounds||new createjs.rectangle).setvalues(a,b,c,d)},b.clone=function(){return this._cloneprops(new a)},b.tostring=function(){return"[displayobject (name="+this.name+")]"},b._cloneprops=function(a){return a.alpha=this.alpha,a.mouseenabled=this.mouseenabled,a.tickenabled=this.tickenabled,a.name=this.name,a.regx=this.regx,a.regy=this.regy,a.rotation=this.rotation,a.scalex=this.scalex,a.scaley=this.scaley,a.shadow=this.shadow,a.skewx=this.skewx,a.skewy=this.skewy,a.visible=this.visible,a.x=this.x,a.y=this.y,a.compositeoperation=this.compositeoperation,a.snaptopixel=this.snaptopixel,a.filters=null==this.filters?null:this.filters.slice(0),a.mask=this.mask,a.hitarea=this.hitarea,a.cursor=this.cursor,a._bounds=this._bounds,a},b._applyshadow=function(a,b){b=b||shadow.identity,a.shadowcolor=b.color,a.shadowoffsetx=b.offsetx,a.shadowoffsety=b.offsety,a.shadowblur=b.blur},b._tick=function(a){var b=this._listeners;b&&b.tick&&(a.target=null,a.propagationstopped=a.immediatepropagationstopped=!1,this.dispatchevent(a))},b._testhit=function(b){try{var c=b.getimagedata(0,0,1,1).data[3]>1}catch(d){if(!a.suppresscrossdomainerrors)throw"an error has occurred. this is most likely due to security restrictions on reading canvas pixel data with local or cross-domain images."}return c},b._applyfilters=function(){if(this.filters&&0!=this.filters.length&&this.cachecanvas)for(var a=this.filters.length,b=this.cachecanvas.getcontext("2d"),c=this.cachecanvas.width,d=this.cachecanvas.height,e=0;a>e;e++)this.filters[e].applyfilter(b,0,0,c,d)},b._getfilterbounds=function(){var a,b=this.filters,c=this._rectangle.setvalues(0,0,0,0);if(!b||!(a=b.length))return c;for(var d=0;a>d;d++){var e=this.filters[d];e.getbounds&&e.getbounds(c)}return c},b._getbounds=function(a,b){return this._transformbounds(this.getbounds(),a,b)},b._transformbounds=function(a,b,c){if(!a)return a;var d=a.x,e=a.y,f=a.width,g=a.height,h=this._props.matrix;h=c?h.identity():this.getmatrix(h),(d||e)&&h.appendtransform(0,0,1,1,0,0,0,-d,-e),b&&h.prependmatrix(b);var i=f*h.a,j=f*h.b,k=g*h.c,l=g*h.d,m=h.tx,n=h.ty,o=m,p=m,q=n,r=n;return(d=i+m)p&&(p=d),(d=i+k+m)p&&(p=d),(d=k+m)p&&(p=d),(e=j+n)r&&(r=e),(e=j+l+n)r&&(r=e),(e=l+n)r&&(r=e),a.setvalues(o,q,p-o,r-q)},b._hasmouseeventlistener=function(){for(var b=a._mouse_events,c=0,d=b.length;d>c;c++)if(this.haseventlistener(b[c]))return!0;return!!this.cursor},createjs.displayobject=createjs.promote(a,"eventdispatcher")}(),this.createjs=this.createjs||{},function(){"use strict";function a(){this.displayobject_constructor(),this.children=[],this.mousechildren=!0,this.tickchildren=!0}var b=createjs.extend(a,createjs.displayobject);b.getnumchildren=function(){return this.children.length};try{object.defineproperties(b,{numchildren:{get:b.getnumchildren}})}catch(c){}b.initialize=a,b.isvisible=function(){var a=this.cachecanvas||this.children.length;return!!(this.visible&&this.alpha>0&&0!=this.scalex&&0!=this.scaley&&a)},b.draw=function(a,b){if(this.displayobject_draw(a,b))return!0;for(var c=this.children.slice(),d=0,e=c.length;e>d;d++){var f=c[d];f.isvisible()&&(a.save(),f.updatecontext(a),f.draw(a),a.restore())}return!0},b.addchild=function(a){if(null==a)return a;var b=arguments.length;if(b>1){for(var c=0;b>c;c++)this.addchild(arguments[c]);return arguments[b-1]}return a.parent&&a.parent.removechild(a),a.parent=this,this.children.push(a),a.dispatchevent("added"),a},b.addchildat=function(a,b){var c=arguments.length,d=arguments[c-1];if(0>d||d>this.children.length)return arguments[c-2];if(c>2){for(var e=0;c-1>e;e++)this.addchildat(arguments[e],d+e);return arguments[c-2]}return a.parent&&a.parent.removechild(a),a.parent=this,this.children.splice(b,0,a),a.dispatchevent("added"),a},b.removechild=function(a){var b=arguments.length;if(b>1){for(var c=!0,d=0;b>d;d++)c=c&&this.removechild(arguments[d]);return c}return this.removechildat(createjs.indexof(this.children,a))},b.removechildat=function(a){var b=arguments.length;if(b>1){for(var c=[],d=0;b>d;d++)c[d]=arguments[d];c.sort(function(a,b){return b-a});for(var e=!0,d=0;b>d;d++)e=e&&this.removechildat(c[d]);return e}if(0>a||a>this.children.length-1)return!1;var f=this.children[a];return f&&(f.parent=null),this.children.splice(a,1),f.dispatchevent("removed"),!0},b.removeallchildren=function(){for(var a=this.children;a.length;)this.removechildat(0)},b.getchildat=function(a){return this.children[a]},b.getchildbyname=function(a){for(var b=this.children,c=0,d=b.length;d>c;c++)if(b[c].name==a)return b[c];return null},b.sortchildren=function(a){this.children.sort(a)},b.getchildindex=function(a){return createjs.indexof(this.children,a)},b.swapchildrenat=function(a,b){var c=this.children,d=c[a],e=c[b];d&&e&&(c[a]=e,c[b]=d)},b.swapchildren=function(a,b){for(var c,d,e=this.children,f=0,g=e.length;g>f&&(e[f]==a&&(c=f),e[f]==b&&(d=f),null==c||null==d);f++);f!=g&&(e[c]=b,e[d]=a)},b.setchildindex=function(a,b){var c=this.children,d=c.length;if(!(a.parent!=this||0>b||b>=d)){for(var e=0;d>e&&c[e]!=a;e++);e!=d&&e!=b&&(c.splice(e,1),c.splice(b,0,a))}},b.contains=function(a){for(;a;){if(a==this)return!0;a=a.parent}return!1},b.hittest=function(a,b){return null!=this.getobjectunderpoint(a,b)},b.getobjectsunderpoint=function(a,b,c){var d=[],e=this.localtoglobal(a,b);return this._getobjectsunderpoint(e.x,e.y,d,c>0,1==c),d},b.getobjectunderpoint=function(a,b,c){var d=this.localtoglobal(a,b);return this._getobjectsunderpoint(d.x,d.y,null,c>0,1==c)},b.getbounds=function(){return this._getbounds(null,!0)},b.gettransformedbounds=function(){return this._getbounds()},b.clone=function(b){var c=this._cloneprops(new a);return b&&this._clonechildren(c),c},b.tostring=function(){return"[container (name="+this.name+")]"},b._tick=function(a){if(this.tickchildren)for(var b=this.children.length-1;b>=0;b--){var c=this.children[b];c.tickenabled&&c._tick&&c._tick(a)}this.displayobject__tick(a)},b._clonechildren=function(a){a.children.length&&a.removeallchildren();for(var b=a.children,c=0,d=this.children.length;d>c;c++){var e=this.children[c].clone(!0);e.parent=a,b.push(e)}},b._getobjectsunderpoint=function(b,c,d,e,f,g){if(g=g||0,!g&&!this._testmask(this,b,c))return null;var h,i=createjs.displayobject._hittestcontext;f=f||e&&this._hasmouseeventlistener();for(var j=this.children,k=j.length,l=k-1;l>=0;l--){var m=j[l],n=m.hitarea;if(m.visible&&(n||m.isvisible())&&(!e||m.mouseenabled)&&(n||this._testmask(m,b,c)))if(!n&&m instanceof a){var o=m._getobjectsunderpoint(b,c,d,e,f,g+1);if(!d&&o)return e&&!this.mousechildren?this:o}else{if(e&&!f&&!m._hasmouseeventlistener())continue;var p=m.getconcatenateddisplayprops(m._props);if(h=p.matrix,n&&(h.appendmatrix(n.getmatrix(n._props.matrix)),p.alpha=n.alpha),i.globalalpha=p.alpha,i.settransform(h.a,h.b,h.c,h.d,h.tx-b,h.ty-c),(n||m).draw(i),!this._testhit(i))continue;if(i.settransform(1,0,0,1,0,0),i.clearrect(0,0,2,2),!d)return e&&!this.mousechildren?this:m;d.push(m)}}return null},b._testmask=function(a,b,c){var d=a.mask;if(!d||!d.graphics||d.graphics.isempty())return!0;var e=this._props.matrix,f=a.parent;e=f?f.getconcatenatedmatrix(e):e.identity(),e=d.getmatrix(d._props.matrix).prependmatrix(e);var g=createjs.displayobject._hittestcontext;return g.settransform(e.a,e.b,e.c,e.d,e.tx-b,e.ty-c),d.graphics.drawaspath(g),g.fillstyle="#000",g.fill(),this._testhit(g)?(g.settransform(1,0,0,1,0,0),g.clearrect(0,0,2,2),!0):!1},b._getbounds=function(a,b){var c=this.displayobject_getbounds();if(c)return this._transformbounds(c,a,b);var d=this._props.matrix;d=b?d.identity():this.getmatrix(d),a&&d.prependmatrix(a);for(var e=this.children.length,f=null,g=0;e>g;g++){var h=this.children[g];h.visible&&(c=h._getbounds(d))&&(f?f.extend(c.x,c.y,c.width,c.height):f=c.clone())}return f},createjs.container=createjs.promote(a,"displayobject")}(),this.createjs=this.createjs||{},function(){"use strict";function a(a){this.container_constructor(),this.autoclear=!0,this.canvas="string"==typeof a?document.getelementbyid(a):a,this.mousex=0,this.mousey=0,this.drawrect=null,this.snaptopixelenabled=!1,this.mouseinbounds=!1,this.tickonupdate=!0,this.mousemoveoutside=!1,this.preventselection=!0,this._pointerdata={},this._pointercount=0,this._primarypointerid=null,this._mouseoverintervalid=null,this._nextstage=null,this._prevstage=null,this.enabledomevents(!0)}var b=createjs.extend(a,createjs.container);b._get_nextstage=function(){return this._nextstage},b._set_nextstage=function(a){this._nextstage&&(this._nextstage._prevstage=null),a&&(a._prevstage=this),this._nextstage=a};try{object.defineproperties(b,{nextstage:{get:b._get_nextstage,set:b._set_nextstage}})}catch(c){}b.update=function(a){if(this.canvas&&(this.tickonupdate&&this.tick(a),this.dispatchevent("drawstart",!1,!0)!==!1)){createjs.displayobject._snaptopixelenabled=this.snaptopixelenabled;var b=this.drawrect,c=this.canvas.getcontext("2d");c.settransform(1,0,0,1,0,0),this.autoclear&&(b?c.clearrect(b.x,b.y,b.width,b.height):c.clearrect(0,0,this.canvas.width+1,this.canvas.height+1)),c.save(),this.drawrect&&(c.beginpath(),c.rect(b.x,b.y,b.width,b.height),c.clip()),this.updatecontext(c),this.draw(c,!1),c.restore(),this.dispatchevent("drawend")}},b.tick=function(a){if(this.tickenabled&&this.dispatchevent("tickstart",!1,!0)!==!1){var b=new createjs.event("tick");if(a)for(var c in a)a.hasownproperty(c)&&(b[c]=a[c]);this._tick(b),this.dispatchevent("tickend")}},b.handleevent=function(a){"tick"==a.type&&this.update(a)},b.clear=function(){if(this.canvas){var a=this.canvas.getcontext("2d");a.settransform(1,0,0,1,0,0),a.clearrect(0,0,this.canvas.width+1,this.canvas.height+1)}},b.todataurl=function(a,b){var c,d=this.canvas.getcontext("2d"),e=this.canvas.width,f=this.canvas.height;if(a){c=d.getimagedata(0,0,e,f);var g=d.globalcompositeoperation;d.globalcompositeoperation="destination-over",d.fillstyle=a,d.fillrect(0,0,e,f)}var h=this.canvas.todataurl(b||"image/png");return a&&(d.putimagedata(c,0,0),d.globalcompositeoperation=g),h},b.enablemouseover=function(a){if(this._mouseoverintervalid&&(clearinterval(this._mouseoverintervalid),this._mouseoverintervalid=null,0==a&&this._testmouseover(!0)),null==a)a=20;else if(0>=a)return;var b=this;this._mouseoverintervalid=setinterval(function(){b._testmouseover()},1e3/math.min(50,a))},b.enabledomevents=function(a){null==a&&(a=!0);var b,c,d=this._eventlisteners;if(!a&&d){for(b in d)c=d[b],c.t.removeeventlistener(b,c.f,!1);this._eventlisteners=null}else if(a&&!d&&this.canvas){var e=window.addeventlistener?window:document,f=this;d=this._eventlisteners={},d.mouseup={t:e,f:function(a){f._handlemouseup(a)}},d.mousemove={t:e,f:function(a){f._handlemousemove(a)}},d.dblclick={t:this.canvas,f:function(a){f._handledoubleclick(a)}},d.mousedown={t:this.canvas,f:function(a){f._handlemousedown(a)}};for(b in d)c=d[b],c.t.addeventlistener(b,c.f,!1)}},b.clone=function(){throw"stage cannot be cloned."},b.tostring=function(){return"[stage (name="+this.name+")]"},b._getelementrect=function(a){var b;try{b=a.getboundingclientrect()}catch(c){b={top:a.offsettop,left:a.offsetleft,width:a.offsetwidth,height:a.offsetheight}}var d=(window.pagexoffset||document.scrollleft||0)-(document.clientleft||document.body.clientleft||0),e=(window.pageyoffset||document.scrolltop||0)-(document.clienttop||document.body.clienttop||0),f=window.getcomputedstyle?getcomputedstyle(a,null):a.currentstyle,g=parseint(f.paddingleft)+parseint(f.borderleftwidth),h=parseint(f.paddingtop)+parseint(f.bordertopwidth),i=parseint(f.paddingright)+parseint(f.borderrightwidth),j=parseint(f.paddingbottom)+parseint(f.borderbottomwidth);return{left:b.left+d+g,right:b.right+d-i,top:b.top+e+h,bottom:b.bottom+e-j}},b._getpointerdata=function(a){var b=this._pointerdata[a];return b||(b=this._pointerdata[a]={x:0,y:0}),b},b._handlemousemove=function(a){a||(a=window.event),this._handlepointermove(-1,a,a.pagex,a.pagey)},b._handlepointermove=function(a,b,c,d,e){if((!this._prevstage||void 0!==e)&&this.canvas){var f=this._nextstage,g=this._getpointerdata(a),h=g.inbounds;this._updatepointerposition(a,b,c,d),(h||g.inbounds||this.mousemoveoutside)&&(-1===a&&g.inbounds==!h&&this._dispatchmouseevent(this,h?"mouseleave":"mouseenter",!1,a,g,b),this._dispatchmouseevent(this,"stagemousemove",!1,a,g,b),this._dispatchmouseevent(g.target,"pressmove",!0,a,g,b)),f&&f._handlepointermove(a,b,c,d,null)}},b._updatepointerposition=function(a,b,c,d){var e=this._getelementrect(this.canvas);c-=e.left,d-=e.top;var f=this.canvas.width,g=this.canvas.height;c/=(e.right-e.left)/f,d/=(e.bottom-e.top)/g;var h=this._getpointerdata(a);(h.inbounds=c>=0&&d>=0&&f-1>=c&&g-1>=d)?(h.x=c,h.y=d):this.mousemoveoutside&&(h.x=0>c?0:c>f-1?f-1:c,h.y=0>d?0:d>g-1?g-1:d),h.posevtobj=b,h.rawx=c,h.rawy=d,(a===this._primarypointerid||-1===a)&&(this.mousex=h.x,this.mousey=h.y,this.mouseinbounds=h.inbounds)},b._handlemouseup=function(a){this._handlepointerup(-1,a,!1)},b._handlepointerup=function(a,b,c,d){var e=this._nextstage,f=this._getpointerdata(a);if(!this._prevstage||void 0!==d){var g=null,h=f.target;d||!h&&!e||(g=this._getobjectsunderpoint(f.x,f.y,null,!0)),f.down&&(this._dispatchmouseevent(this,"stagemouseup",!1,a,f,b,g),f.down=!1),g==h&&this._dispatchmouseevent(h,"click",!0,a,f,b),this._dispatchmouseevent(h,"pressup",!0,a,f,b),c?(a==this._primarypointerid&&(this._primarypointerid=null),delete this._pointerdata[a]):f.target=null,e&&e._handlepointerup(a,b,c,d||g&&this)}},b._handlemousedown=function(a){this._handlepointerdown(-1,a,a.pagex,a.pagey)},b._handlepointerdown=function(a,b,c,d,e){this.preventselection&&b.preventdefault(),(null==this._primarypointerid||-1===a)&&(this._primarypointerid=a),null!=d&&this._updatepointerposition(a,b,c,d);var f=null,g=this._nextstage,h=this._getpointerdata(a);e||(f=h.target=this._getobjectsunderpoint(h.x,h.y,null,!0)),h.inbounds&&(this._dispatchmouseevent(this,"stagemousedown",!1,a,h,b,f),h.down=!0),this._dispatchmouseevent(f,"mousedown",!0,a,h,b),g&&g._handlepointerdown(a,b,c,d,e||f&&this)},b._testmouseover=function(a,b,c){if(!this._prevstage||void 0!==b){var d=this._nextstage;if(!this._mouseoverintervalid)return void(d&&d._testmouseover(a,b,c));var e=this._getpointerdata(-1);if(e&&(a||this.mousex!=this._mouseoverx||this.mousey!=this._mouseovery||!this.mouseinbounds)){var f,g,h,i=e.posevtobj,j=c||i&&i.target==this.canvas,k=null,l=-1,m="";!b&&(a||this.mouseinbounds&&j)&&(k=this._getobjectsunderpoint(this.mousex,this.mousey,null,!0),this._mouseoverx=this.mousex,this._mouseovery=this.mousey);var n=this._mouseovertarget||[],o=n[n.length-1],p=this._mouseovertarget=[];for(f=k;f;)p.unshift(f),m||(m=f.cursor),f=f.parent;for(this.canvas.style.cursor=m,!b&&c&&(c.canvas.style.cursor=m),g=0,h=p.length;h>g&&p[g]==n[g];g++)l=g;for(o!=k&&this._dispatchmouseevent(o,"mouseout",!0,-1,e,i,k),g=n.length-1;g>l;g--)this._dispatchmouseevent(n[g],"rollout",!1,-1,e,i,k);for(g=p.length-1;g>l;g--)this._dispatchmouseevent(p[g],"rollover",!1,-1,e,i,o);o!=k&&this._dispatchmouseevent(k,"mouseover",!0,-1,e,i,o),d&&d._testmouseover(a,b||k&&this,c||j&&this)}}},b._handledoubleclick=function(a,b){var c=null,d=this._nextstage,e=this._getpointerdata(-1);b||(c=this._getobjectsunderpoint(e.x,e.y,null,!0),this._dispatchmouseevent(c,"dblclick",!0,-1,e,a)),d&&d._handledoubleclick(a,b||c&&this)},b._dispatchmouseevent=function(a,b,c,d,e,f,g){if(a&&(c||a.haseventlistener(b))){var h=new createjs.mouseevent(b,c,!1,e.x,e.y,f,d,d===this._primarypointerid||-1===d,e.rawx,e.rawy,g);a.dispatchevent(h)}},createjs.stage=createjs.promote(a,"container")}(),this.createjs=this.createjs||{},function(){function a(a){this.displayobject_constructor(),"string"==typeof a?(this.image=document.createelement("img"),this.image.src=a):this.image=a,this.sourcerect=null}var b=createjs.extend(a,createjs.displayobject);b.initialize=a,b.isvisible=function(){var a=this.image,b=this.cachecanvas||a&&(a.naturalwidth||a.getcontext||a.readystate>=2);return!!(this.visible&&this.alpha>0&&0!=this.scalex&&0!=this.scaley&&b)},b.draw=function(a,b){if(this.displayobject_draw(a,b)||!this.image)return!0;var c=this.image,d=this.sourcerect;if(d){var e=d.x,f=d.y,g=e+d.width,h=f+d.height,i=0,j=0,k=c.width,l=c.height;0>e&&(i-=e,e=0),g>k&&(g=k),0>f&&(j-=f,f=0),h>l&&(h=l),a.drawimage(c,e,f,g-e,h-f,i,j,g-e,h-f)}else a.drawimage(c,0,0);return!0},b.getbounds=function(){var a=this.displayobject_getbounds();if(a)return a;var b=this.image,c=this.sourcerect||b,d=b&&(b.naturalwidth||b.getcontext||b.readystate>=2);return d?this._rectangle.setvalues(0,0,c.width,c.height):null},b.clone=function(){var b=new a(this.image);return this.sourcerect&&(b.sourcerect=this.sourcerect.clone()),this._cloneprops(b),b},b.tostring=function(){return"[bitmap (name="+this.name+")]"},createjs.bitmap=createjs.promote(a,"displayobject")}(),this.createjs=this.createjs||{},function(){"use strict";function a(a,b){this.displayobject_constructor(),this.currentframe=0,this.currentanimation=null,this.paused=!0,this.spritesheet=a,this.currentanimationframe=0,this.framerate=0,this._animation=null,this._currentframe=null,this._skipadvance=!1,null!=b&&this.gotoandplay(b)}var b=createjs.extend(a,createjs.displayobject);b.initialize=a,b.isvisible=function(){var a=this.cachecanvas||this.spritesheet.complete;return!!(this.visible&&this.alpha>0&&0!=this.scalex&&0!=this.scaley&&a)},b.draw=function(a,b){if(this.displayobject_draw(a,b))return!0;this._normalizeframe();var c=this.spritesheet.getframe(0|this._currentframe);if(!c)return!1;var d=c.rect;return d.width&&d.height&&a.drawimage(c.image,d.x,d.y,d.width,d.height,-c.regx,-c.regy,d.width,d.height),!0},b.play=function(){this.paused=!1},b.stop=function(){this.paused=!0},b.gotoandplay=function(a){this.paused=!1,this._skipadvance=!0,this._goto(a)},b.gotoandstop=function(a){this.paused=!0,this._goto(a)},b.advance=function(a){var b=this.framerate||this.spritesheet.framerate,c=b&&null!=a?a/(1e3/b):1;this._normalizeframe(c)},b.getbounds=function(){return this.displayobject_getbounds()||this.spritesheet.getframebounds(this.currentframe,this._rectangle)},b.clone=function(){return this._cloneprops(new a(this.spritesheet))},b.tostring=function(){return"[sprite (name="+this.name+")]"},b._cloneprops=function(a){return this.displayobject__cloneprops(a),a.currentframe=this.currentframe,a.currentanimation=this.currentanimation,a.paused=this.paused,a.currentanimationframe=this.currentanimationframe,a.framerate=this.framerate,a._animation=this._animation,a._currentframe=this._currentframe,a._skipadvance=this._skipadvance,a},b._tick=function(a){this.paused||(this._skipadvance||this.advance(a&&a.delta),this._skipadvance=!1),this.displayobject__tick(a)},b._normalizeframe=function(a){a=a||0;var b,c=this._animation,d=this.paused,e=this._currentframe;if(c){var f=c.speed||1,g=this.currentanimationframe;if(b=c.frames.length,g+a*f>=b){var h=c.next;if(this._dispatchanimationend(c,e,d,h,b-1))return;if(h)return this._goto(h,a-(b-g)/f);this.paused=!0,g=c.frames.length-1}else g+=a*f;this.currentanimationframe=g,this._currentframe=c.frames[0|g]}else if(e=this._currentframe+=a,b=this.spritesheet.getnumframes(),e>=b&&b>0&&!this._dispatchanimationend(c,e,d,b-1)&&(this._currentframe-=b)>=b)return this._normalizeframe();e=0|this._currentframe,this.currentframe!=e&&(this.currentframe=e,this.dispatchevent("change"))},b._dispatchanimationend=function(a,b,c,d,e){var f=a?a.name:null;if(this.haseventlistener("animationend")){var g=new createjs.event("animationend");g.name=f,g.next=d,this.dispatchevent(g)}var h=this._animation!=a||this._currentframe!=b;return h||c||!this.paused||(this.currentanimationframe=e,h=!0),h},b._goto=function(a,b){if(this.currentanimationframe=0,isnan(a)){var c=this.spritesheet.getanimation(a);c&&(this._animation=c,this.currentanimation=a,this._normalizeframe(b))}else this.currentanimation=this._animation=null,this._currentframe=a,this._normalizeframe()},createjs.sprite=createjs.promote(a,"displayobject")}(),this.createjs=this.createjs||{},function(){"use strict";function a(a){this.displayobject_constructor(),this.graphics=a?a:new createjs.graphics}var b=createjs.extend(a,createjs.displayobject);b.isvisible=function(){var a=this.cachecanvas||this.graphics&&!this.graphics.isempty();return!!(this.visible&&this.alpha>0&&0!=this.scalex&&0!=this.scaley&&a)},b.draw=function(a,b){return this.displayobject_draw(a,b)?!0:(this.graphics.draw(a,this),!0)},b.clone=function(b){var c=b&&this.graphics?this.graphics.clone():this.graphics;return this._cloneprops(new a(c))},b.tostring=function(){return"[shape (name="+this.name+")]"},createjs.shape=createjs.promote(a,"displayobject")}(),this.createjs=this.createjs||{},function(){"use strict";function a(a,b,c){this.displayobject_constructor(),this.text=a,this.font=b,this.color=c,this.textalign="left",this.textbaseline="top",this.maxwidth=null,this.outline=0,this.lineheight=0,this.linewidth=null}var b=createjs.extend(a,createjs.displayobject),c=createjs.createcanvas?createjs.createcanvas():document.createelement("canvas");c.getcontext&&(a._workingcontext=c.getcontext("2d"),c.width=c.height=1),a.h_offsets={start:0,left:0,center:-.5,end:-1,right:-1},a.v_offsets={top:0,hanging:-.01,middle:-.4,alphabetic:-.8,ideographic:-.85,bottom:-1},b.isvisible=function(){var a=this.cachecanvas||null!=this.text&&""!==this.text;return!!(this.visible&&this.alpha>0&&0!=this.scalex&&0!=this.scaley&&a)},b.draw=function(a,b){if(this.displayobject_draw(a,b))return!0;var c=this.color||"#000";return this.outline?(a.strokestyle=c,a.linewidth=1*this.outline):a.fillstyle=c,this._drawtext(this._prepcontext(a)),!0},b.getmeasuredwidth=function(){return this._getmeasuredwidth(this.text)},b.getmeasuredlineheight=function(){return 1.2*this._getmeasuredwidth("m")},b.getmeasuredheight=function(){return this._drawtext(null,{}).height},b.getbounds=function(){var b=this.displayobject_getbounds();if(b)return b;if(null==this.text||""===this.text)return null;var c=this._drawtext(null,{}),d=this.maxwidth&&this.maxwidthj;j++){var l=i[j],m=null;if(null!=this.linewidth&&(m=b.measuretext(l).width)>this.linewidth){var n=l.split(/(\s)/);l=n[0],m=b.measuretext(l).width;for(var o=1,p=n.length;p>o;o+=2){var q=b.measuretext(n[o]+n[o+1]).width;m+q>this.linewidth?(e&&this._drawtextline(b,l,h*f),d&&d.push(l),m>g&&(g=m),l=n[o+1],m=b.measuretext(l).width,h++):(l+=n[o]+n[o+1],m+=q)}}e&&this._drawtextline(b,l,h*f),d&&d.push(l),c&&null==m&&(m=b.measuretext(l).width),m>g&&(g=m),h++}return c&&(c.width=g,c.height=h*f),e||b.restore(),c},b._drawtextline=function(a,b,c){this.outline?a.stroketext(b,0,c,this.maxwidth||65535):a.filltext(b,0,c,this.maxwidth||65535)},b._getmeasuredwidth=function(b){var c=a._workingcontext;c.save();var d=this._prepcontext(c).measuretext(b).width;return c.restore(),d},createjs.text=createjs.promote(a,"displayobject")}(),this.createjs=this.createjs||{},function(){"use strict";function a(a,b){this.container_constructor(),this.text=a||"",this.spritesheet=b,this.lineheight=0,this.letterspacing=0,this.spacewidth=0,this._oldprops={text:0,spritesheet:0,lineheight:0,letterspacing:0,spacewidth:0}}var b=createjs.extend(a,createjs.container);a.maxpoolsize=100,a._spritepool=[],b.draw=function(a,b){this.displayobject_draw(a,b)||(this._updatetext(),this.container_draw(a,b))},b.getbounds=function(){return this._updatetext(),this.container_getbounds()},b.isvisible=function(){var a=this.cachecanvas||this.spritesheet&&this.spritesheet.complete&&this.text;return!!(this.visible&&this.alpha>0&&0!==this.scalex&&0!==this.scaley&&a)},b.clone=function(){return this._cloneprops(new a(this.text,this.spritesheet))},b.addchild=b.addchildat=b.removechild=b.removechildat=b.removeallchildren=function(){},b._cloneprops=function(a){return this.container__cloneprops(a),a.lineheight=this.lineheight,a.letterspacing=this.letterspacing,a.spacewidth=this.spacewidth,a},b._getframeindex=function(a,b){var c,d=b.getanimation(a);return d||(a!=(c=a.touppercase())||a!=(c=a.tolowercase())||(c=null),c&&(d=b.getanimation(c))),d&&d.frames[0]},b._getframe=function(a,b){var c=this._getframeindex(a,b);return null==c?c:b.getframe(c)},b._getlineheight=function(a){var b=this._getframe("1",a)||this._getframe("t",a)||this._getframe("l",a)||a.getframe(0);return b?b.rect.height:1},b._getspacewidth=function(a){var b=this._getframe("1",a)||this._getframe("l",a)||this._getframe("e",a)||this._getframe("a",a)||a.getframe(0);return b?b.rect.width:1},b._updatetext=function(){var b,c=0,d=0,e=this._oldprops,f=!1,g=this.spacewidth,h=this.lineheight,i=this.spritesheet,j=a._spritepool,k=this.children,l=0,m=k.length;for(var n in e)e[n]!=this[n]&&(e[n]=this[n],f=!0);if(f){var o=!!this._getframe(" ",i);o||g||(g=this._getspacewidth(i)),h||(h=this._getlineheight(i));for(var p=0,q=this.text.length;q>p;p++){var r=this.text.charat(p);if(" "!=r||o)if("\n"!=r&&"\r"!=r){var s=this._getframeindex(r,i);null!=s&&(m>l?b=k[l]:(k.push(b=j.length?j.pop():new createjs.sprite),b.parent=this,m++),b.spritesheet=i,b.gotoandstop(s),b.x=c,b.y=d,l++,c+=b.getbounds().width+this.letterspacing)}else"\r"==r&&"\n"==this.text.charat(p+1)&&p++,c=0,d+=h;else c+=g}for(;m>l;)j.push(b=k.pop()),b.parent=null,m--;j.length>a.maxpoolsize&&(j.length=a.maxpoolsize)}},createjs.bitmaptext=createjs.promote(a,"container")}(),this.createjs=this.createjs||{},function(){"use strict";function a(b,c,d,e){this.container_constructor(),!a.inited&&a.init(),this.mode=b||a.independent,this.startposition=c||0,this.loop=d,this.currentframe=0,this.timeline=new createjs.timeline(null,e,{paused:!0,position:c,useticks:!0}),this.paused=!1,this.actionsenabled=!0,this.autoreset=!0,this.framebounds=this.framebounds||null,this.framerate=null,this._synchoffset=0,this._prevpos=-1,this._prevposition=0,this._t=0,this._managed={}}function b(){throw"movieclipplugin cannot be instantiated."}var c=createjs.extend(a,createjs.container);a.independent="independent",a.single_frame="single",a.synched="synched",a.inited=!1,a.init=function(){a.inited||(b.install(),a.inited=!0)},c.getlabels=function(){return this.timeline.getlabels()},c.getcurrentlabel=function(){return this._updatetimeline(),this.timeline.getcurrentlabel()},c.getduration=function(){return this.timeline.duration};try{object.defineproperties(c,{labels:{get:c.getlabels},currentlabel:{get:c.getcurrentlabel},totalframes:{get:c.getduration},duration:{get:c.getduration}})}catch(d){}c.initialize=a,c.isvisible=function(){return!!(this.visible&&this.alpha>0&&0!=this.scalex&&0!=this.scaley)},c.draw=function(a,b){return this.displayobject_draw(a,b)?!0:(this._updatetimeline(),this.container_draw(a,b),!0) },c.play=function(){this.paused=!1},c.stop=function(){this.paused=!0},c.gotoandplay=function(a){this.paused=!1,this._goto(a)},c.gotoandstop=function(a){this.paused=!0,this._goto(a)},c.advance=function(b){var c=a.independent;if(this.mode==c){for(var d=this,e=d.framerate;(d=d.parent)&&null==e;)d.mode==c&&(e=d._framerate);this._framerate=e;var f=null!=e&&-1!=e&&null!=b?b/(1e3/e)+this._t:1,g=0|f;for(this._t=f-g;!this.paused&&g--;)this._prevposition=this._prevpos<0?0:this._prevposition+1,this._updatetimeline()}},c.clone=function(){throw"movieclip cannot be cloned."},c.tostring=function(){return"[movieclip (name="+this.name+")]"},c._tick=function(a){this.advance(a&&a.delta),this.container__tick(a)},c._goto=function(a){var b=this.timeline.resolve(a);null!=b&&(-1==this._prevpos&&(this._prevpos=0/0),this._prevposition=b,this._t=0,this._updatetimeline())},c._reset=function(){this._prevpos=-1,this._t=this.currentframe=0,this.paused=!1},c._updatetimeline=function(){var b=this.timeline,c=this.mode!=a.independent;b.loop=null==this.loop?!0:this.loop;var d=c?this.startposition+(this.mode==a.single_frame?0:this._synchoffset):this._prevpos<0?0:this._prevposition,e=c||!this.actionsenabled?createjs.tween.none:null;if(this.currentframe=b._calcposition(d),b.setposition(d,e),this._prevposition=b._prevposition,this._prevpos!=b._prevpos){this.currentframe=this._prevpos=b._prevpos;for(var f in this._managed)this._managed[f]=1;for(var g=b._tweens,h=0,i=g.length;i>h;h++){var j=g[h],k=j._target;if(k!=this&&!j.passive){var l=j._stepposition;k instanceof createjs.displayobject?this._addmanagedchild(k,l):this._setstate(k.state,l)}}var m=this.children;for(h=m.length-1;h>=0;h--){var n=m[h].id;1==this._managed[n]&&(this.removechildat(h),delete this._managed[n])}}},c._setstate=function(a,b){if(a)for(var c=a.length-1;c>=0;c--){var d=a[c],e=d.t,f=d.p;for(var g in f)e[g]=f[g];this._addmanagedchild(e,b)}},c._addmanagedchild=function(b,c){b._off||(this.addchildat(b,0),b instanceof a&&(b._synchoffset=c,b.mode==a.independent&&b.autoreset&&!this._managed[b.id]&&b._reset()),this._managed[b.id]=2)},c._getbounds=function(a,b){var c=this.displayobject_getbounds();return c||(this._updatetimeline(),this.framebounds&&(c=this._rectangle.copy(this.framebounds[this.currentframe]))),c?this._transformbounds(c,a,b):this.container__getbounds(a,b)},createjs.movieclip=createjs.promote(a,"container"),b.priority=100,b.install=function(){createjs.tween.installplugin(b,["startposition"])},b.init=function(a,b,c){return c},b.step=function(){},b.tween=function(b,c,d,e,f,g){return b.target instanceof a?1==g?f[c]:e[c]:d}}(),this.createjs=this.createjs||{},function(){"use strict";function a(){throw"spritesheetutils cannot be instantiated"}var b=createjs.createcanvas?createjs.createcanvas():document.createelement("canvas");b.getcontext&&(a._workingcanvas=b,a._workingcontext=b.getcontext("2d"),b.width=b.height=1),a.addflippedframes=function(b,c,d,e){if(c||d||e){var f=0;c&&a._flip(b,++f,!0,!1),d&&a._flip(b,++f,!1,!0),e&&a._flip(b,++f,!0,!0)}},a.extractframe=function(b,c){isnan(c)&&(c=b.getanimation(c).frames[0]);var d=b.getframe(c);if(!d)return null;var e=d.rect,f=a._workingcanvas;f.width=e.width,f.height=e.height,a._workingcontext.drawimage(d.image,e.x,e.y,e.width,e.height,0,0,e.width,e.height);var g=document.createelement("img");return g.src=f.todataurl("image/png"),g},a.mergealpha=function(a,b,c){c||(c=createjs.createcanvas?createjs.createcanvas():document.createelement("canvas")),c.width=math.max(b.width,a.width),c.height=math.max(b.height,a.height);var d=c.getcontext("2d");return d.save(),d.drawimage(a,0,0),d.globalcompositeoperation="destination-in",d.drawimage(b,0,0),d.restore(),c},a._flip=function(b,c,d,e){for(var f=b._images,g=a._workingcanvas,h=a._workingcontext,i=f.length/c,j=0;i>j;j++){var k=f[j];k.__tmp=j,h.settransform(1,0,0,1,0,0),h.clearrect(0,0,g.width+1,g.height+1),g.width=k.width,g.height=k.height,h.settransform(d?-1:1,0,0,e?-1:1,d?k.width:0,e?k.height:0),h.drawimage(k,0,0);var l=document.createelement("img");l.src=g.todataurl("image/png"),l.width=k.width,l.height=k.height,f.push(l)}var m=b._frames,n=m.length/c;for(j=0;n>j;j++){k=m[j];var o=k.rect.clone();l=f[k.image.__tmp+i*c];var p={image:l,rect:o,regx:k.regx,regy:k.regy};d&&(o.x=l.width-o.x-o.width,p.regx=o.width-k.regx),e&&(o.y=l.height-o.y-o.height,p.regy=o.height-k.regy),m.push(p)}var q="_"+(d?"h":"")+(e?"v":""),r=b._animations,s=b._data,t=r.length/c;for(j=0;t>j;j++){var u=r[j];k=s[u];var v={name:u+q,speed:k.speed,next:k.next,frames:[]};k.next&&(v.next+=q),m=k.frames;for(var w=0,x=m.length;x>w;w++)v.frames.push(m[w]+n*c);s[v.name]=v,r.push(v.name)}},createjs.spritesheetutils=a}(),this.createjs=this.createjs||{},function(){"use strict";function a(a){this.eventdispatcher_constructor(),this.maxwidth=2048,this.maxheight=2048,this.spritesheet=null,this.scale=1,this.padding=1,this.timeslice=.3,this.progress=-1,this.framerate=a||0,this._frames=[],this._animations={},this._data=null,this._nextframeindex=0,this._index=0,this._timerid=null,this._scale=1}var b=createjs.extend(a,createjs.eventdispatcher);a.err_dimensions="frame dimensions exceed max spritesheet dimensions",a.err_running="a build is already running",b.addframe=function(b,c,d,e,f){if(this._data)throw a.err_running;var g=c||b.bounds||b.nominalbounds;return!g&&b.getbounds&&(g=b.getbounds()),g?(d=d||1,this._frames.push({source:b,sourcerect:g,scale:d,funct:e,data:f,index:this._frames.length,height:g.height*d})-1):null},b.addanimation=function(b,c,d,e){if(this._data)throw a.err_running;this._animations[b]={frames:c,next:d,speed:e}},b.addmovieclip=function(b,c,d,e,f,g){if(this._data)throw a.err_running;var h=b.framebounds,i=c||b.bounds||b.nominalbounds;if(!i&&b.getbounds&&(i=b.getbounds()),i||h){var j,k,l=this._frames.length,m=b.timeline.duration;for(j=0;m>j;j++){var n=h&&h[j]?h[j]:i;this.addframe(b,n,d,this._setupmovieclipframe,{i:j,f:e,d:f})}var o=b.timeline._labels,p=[];for(var q in o)p.push({index:o[q],label:q});if(p.length)for(p.sort(function(a,b){return a.index-b.index}),j=0,k=p.length;k>j;j++){for(var r=p[j].label,s=l+p[j].index,t=l+(j==k-1?m:p[j+1].index),u=[],v=s;t>v;v++)u.push(v);(!g||(r=g(r,b,s,t)))&&this.addanimation(r,u,!0)}}},b.build=function(){if(this._data)throw a.err_running;for(this._startbuild();this._drawnext(););return this._endbuild(),this.spritesheet},b.buildasync=function(b){if(this._data)throw a.err_running;this.timeslice=b,this._startbuild();var c=this;this._timerid=settimeout(function(){c._run()},50-50*math.max(.01,math.min(.99,this.timeslice||.3)))},b.stopasync=function(){cleartimeout(this._timerid),this._data=null},b.clone=function(){throw"spritesheetbuilder cannot be cloned."},b.tostring=function(){return"[spritesheetbuilder]"},b._startbuild=function(){var b=this.padding||0;this.progress=0,this.spritesheet=null,this._index=0,this._scale=this.scale;var c=[];this._data={images:[],frames:c,framerate:this.framerate,animations:this._animations};var d=this._frames.slice();if(d.sort(function(a,b){return a.height<=b.height?-1:1}),d[d.length-1].height+2*b>this.maxheight)throw a.err_dimensions;for(var e=0,f=0,g=0;d.length;){var h=this._fillrow(d,e,g,c,b);if(h.w>f&&(f=h.w),e+=h.h,!h.h||!d.length){var i=createjs.createcanvas?createjs.createcanvas():document.createelement("canvas");i.width=this._getsize(f,this.maxwidth),i.height=this._getsize(e,this.maxheight),this._data.images[g]=i,h.h||(f=e=0,g++)}}},b._setupmovieclipframe=function(a,b){var c=a.actionsenabled;a.actionsenabled=!1,a.gotoandstop(b.i),a.actionsenabled=c,b.f&&b.f(a,b.d,b.i)},b._getsize=function(a,b){for(var c=4;math.pow(2,++c)=0;l--){var m=b[l],n=this._scale*m.scale,o=m.sourcerect,p=m.source,q=math.floor(n*o.x-f),r=math.floor(n*o.y-f),s=math.ceil(n*o.height+2*f),t=math.ceil(n*o.width+2*f);if(t>g)throw a.err_dimensions;s>i||j+t>g||(m.img=d,m.rect=new createjs.rectangle(j,c,t,s),k=k||s,b.splice(l,1),e[m.index]=[j,c,t,s,d,math.round(-q+n*p.regx-f),math.round(-r+n*p.regy-f)],j+=t)}return{w:j,h:k}},b._endbuild=function(){this.spritesheet=new createjs.spritesheet(this._data),this._data=null,this.progress=1,this.dispatchevent("complete")},b._run=function(){for(var a=50*math.max(.01,math.min(.99,this.timeslice||.3)),b=(new date).gettime()+a,c=!1;b>(new date).gettime();)if(!this._drawnext()){c=!0;break}if(c)this._endbuild();else{var d=this;this._timerid=settimeout(function(){d._run()},50-a)}var e=this.progress=this._index/this._frames.length;if(this.haseventlistener("progress")){var f=new createjs.event("progress");f.progress=e,this.dispatchevent(f)}},b._drawnext=function(){var a=this._frames[this._index],b=a.scale*this._scale,c=a.rect,d=a.sourcerect,e=this._data.images[a.img],f=e.getcontext("2d");return a.funct&&a.funct(a.source,a.data),f.save(),f.beginpath(),f.rect(c.x,c.y,c.width,c.height),f.clip(),f.translate(math.ceil(c.x-d.x*b),math.ceil(c.y-d.y*b)),f.scale(b,b),a.source.draw(f),f.restore(),++this._indexa)&&(a=0),(isnan(b)||0>b)&&(b=0),(isnan(c)||1>c)&&(c=1),this.blurx=0|a,this.blury=0|b,this.quality=0|c}var b=createjs.extend(a,createjs.filter);a.mul_table=[1,171,205,293,57,373,79,137,241,27,391,357,41,19,283,265,497,469,443,421,25,191,365,349,335,161,155,149,9,278,269,261,505,245,475,231,449,437,213,415,405,395,193,377,369,361,353,345,169,331,325,319,313,307,301,37,145,285,281,69,271,267,263,259,509,501,493,243,479,118,465,459,113,446,55,435,429,423,209,413,51,403,199,393,97,3,379,375,371,367,363,359,355,351,347,43,85,337,333,165,327,323,5,317,157,311,77,305,303,75,297,294,73,289,287,71,141,279,277,275,68,135,67,133,33,262,260,129,511,507,503,499,495,491,61,121,481,477,237,235,467,232,115,457,227,451,7,445,221,439,218,433,215,427,425,211,419,417,207,411,409,203,202,401,399,396,197,49,389,387,385,383,95,189,47,187,93,185,23,183,91,181,45,179,89,177,11,175,87,173,345,343,341,339,337,21,167,83,331,329,327,163,81,323,321,319,159,79,315,313,39,155,309,307,153,305,303,151,75,299,149,37,295,147,73,291,145,289,287,143,285,71,141,281,35,279,139,69,275,137,273,17,271,135,269,267,133,265,33,263,131,261,130,259,129,257,1],a.shg_table=[0,9,10,11,9,12,10,11,12,9,13,13,10,9,13,13,14,14,14,14,10,13,14,14,14,13,13,13,9,14,14,14,15,14,15,14,15,15,14,15,15,15,14,15,15,15,15,15,14,15,15,15,15,15,15,12,14,15,15,13,15,15,15,15,16,16,16,15,16,14,16,16,14,16,13,16,16,16,15,16,13,16,15,16,14,9,16,16,16,16,16,16,16,16,16,13,14,16,16,15,16,16,10,16,15,16,14,16,16,14,16,16,14,16,16,14,15,16,16,16,14,15,14,15,13,16,16,15,17,17,17,17,17,17,14,15,17,17,16,16,17,16,15,17,16,17,11,17,16,17,16,17,16,17,17,16,17,17,16,17,17,16,16,17,17,17,16,14,17,17,17,17,15,16,14,16,15,16,13,16,15,16,14,16,15,16,12,16,15,16,17,17,17,17,17,13,16,15,17,17,17,16,15,17,17,17,16,15,17,17,14,16,17,17,16,17,17,16,15,17,16,14,17,16,15,17,16,17,17,16,17,15,16,17,14,17,16,15,17,16,17,13,17,16,17,17,16,17,14,17,16,17,16,17,16,17,9],b.getbounds=function(a){var b=0|this.blurx,c=0|this.blury;if(0>=b&&0>=c)return a;var d=math.pow(this.quality,.2);return(a||new createjs.rectangle).pad(b*d+1,c*d+1,b*d+1,c*d+1)},b.clone=function(){return new a(this.blurx,this.blury,this.quality)},b.tostring=function(){return"[blurfilter]"},b._applyfilter=function(b){var c=this.blurx>>1;if(isnan(c)||0>c)return!1;var d=this.blury>>1;if(isnan(d)||0>d)return!1;if(0==c&&0==d)return!1;var e=this.quality;(isnan(e)||1>e)&&(e=1),e|=0,e>3&&(e=3),1>e&&(e=1);var f=b.data,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=c+c+1|0,w=d+d+1|0,x=0|b.width,y=0|b.height,z=x-1|0,a=y-1|0,b=c+1|0,c=d+1|0,d={r:0,b:0,g:0,a:0},e=d;for(i=1;v>i;i++)e=e.n={r:0,b:0,g:0,a:0};e.n=d;var f={r:0,b:0,g:0,a:0},g=f;for(i=1;w>i;i++)g=g.n={r:0,b:0,g:0,a:0};g.n=f;for(var h=null,i=0|a.mul_table[c],j=0|a.shg_table[c],k=0|a.mul_table[d],l=0|a.shg_table[d];e-->0;){m=l=0;var m=i,n=j;for(h=y;--h>-1;){for(n=b*(r=f[0|l]),o=b*(s=f[l+1|0]),p=b*(t=f[l+2|0]),q=b*(u=f[l+3|0]),e=d,i=b;--i>-1;)e.r=r,e.g=s,e.b=t,e.a=u,e=e.n;for(i=1;b>i;i++)j=l+((i>z?z:i)<<2)|0,n+=e.r=f[j],o+=e.g=f[j+1],p+=e.b=f[j+2],q+=e.a=f[j+3],e=e.n;for(h=d,g=0;x>g;g++)f[l++]=n*m>>>n,f[l++]=o*m>>>n,f[l++]=p*m>>>n,f[l++]=q*m>>>n,j=m+((j=g+c+1)g;g++){for(l=g<<2|0,n=c*(r=f[l])|0,o=c*(s=f[l+1|0])|0,p=c*(t=f[l+2|0])|0,q=c*(u=f[l+3|0])|0,g=f,i=0;c>i;i++)g.r=r,g.g=s,g.b=t,g.a=u,g=g.n;for(k=x,i=1;d>=i;i++)l=k+g<<2,n+=g.r=f[l],o+=g.g=f[l+1],p+=g.b=f[l+2],q+=g.a=f[l+3],g=g.n,a>i&&(k+=x);if(l=g,h=f,e>0)for(h=0;y>h;h++)j=l<<2,f[j+3]=u=q*m>>>n,u>0?(f[j]=n*m>>>n,f[j+1]=o*m>>>n,f[j+2]=p*m>>>n):f[j]=f[j+1]=f[j+2]=0,j=g+((j=h+c)h;h++)j=l<<2,f[j+3]=u=q*m>>>n,u>0?(u=255/u,f[j]=(n*m>>>n)*u,f[j+1]=(o*m>>>n)*u,f[j+2]=(p*m>>>n)*u):f[j]=f[j+1]=f[j+2]=0,j=g+((j=h+c)d;d+=4)b[d+3]=c[d]||0;return!0},b._prepalphamap=function(){if(!this.alphamap)return!1;if(this.alphamap==this._alphamap&&this._mapdata)return!0;this._mapdata=null;var a,b=this._alphamap=this.alphamap,c=b;b instanceof htmlcanvaselement?a=c.getcontext("2d"):(c=createjs.createcanvas?createjs.createcanvas():document.createelement("canvas"),c.width=b.width,c.height=b.height,a=c.getcontext("2d"),a.drawimage(b,0,0));try{var d=a.getimagedata(0,0,b.width,b.height)}catch(e){return!1}return this._mapdata=d.data,!0},createjs.alphamapfilter=createjs.promote(a,"filter")}(),this.createjs=this.createjs||{},function(){"use strict";function a(a){this.mask=a}var b=createjs.extend(a,createjs.filter);b.applyfilter=function(a,b,c,d,e,f,g,h){return this.mask?(f=f||a,null==g&&(g=b),null==h&&(h=c),f.save(),a!=f?!1:(f.globalcompositeoperation="destination-in",f.drawimage(this.mask,g,h),f.restore(),!0)):!0},b.clone=function(){return new a(this.mask)},b.tostring=function(){return"[alphamaskfilter]"},createjs.alphamaskfilter=createjs.promote(a,"filter")}(),this.createjs=this.createjs||{},function(){"use strict";function a(a,b,c,d,e,f,g,h){this.redmultiplier=null!=a?a:1,this.greenmultiplier=null!=b?b:1,this.bluemultiplier=null!=c?c:1,this.alphamultiplier=null!=d?d:1,this.redoffset=e||0,this.greenoffset=f||0,this.blueoffset=g||0,this.alphaoffset=h||0}var b=createjs.extend(a,createjs.filter);b.tostring=function(){return"[colorfilter]"},b.clone=function(){return new a(this.redmultiplier,this.greenmultiplier,this.bluemultiplier,this.alphamultiplier,this.redoffset,this.greenoffset,this.blueoffset,this.alphaoffset)},b._applyfilter=function(a){for(var b=a.data,c=b.length,d=0;c>d;d+=4)b[d]=b[d]*this.redmultiplier+this.redoffset,b[d+1]=b[d+1]*this.greenmultiplier+this.greenoffset,b[d+2]=b[d+2]*this.bluemultiplier+this.blueoffset,b[d+3]=b[d+3]*this.alphamultiplier+this.alphaoffset;return!0},createjs.colorfilter=createjs.promote(a,"filter")}(),this.createjs=this.createjs||{},function(){"use strict";function a(a,b,c,d){this.setcolor(a,b,c,d)}var b=a.prototype;a.delta_index=[0,.01,.02,.04,.05,.06,.07,.08,.1,.11,.12,.14,.15,.16,.17,.18,.2,.21,.22,.24,.25,.27,.28,.3,.32,.34,.36,.38,.4,.42,.44,.46,.48,.5,.53,.56,.59,.62,.65,.68,.71,.74,.77,.8,.83,.86,.89,.92,.95,.98,1,1.06,1.12,1.18,1.24,1.3,1.36,1.42,1.48,1.54,1.6,1.66,1.72,1.78,1.84,1.9,1.96,2,2.12,2.25,2.37,2.5,2.62,2.75,2.87,3,3.2,3.4,3.6,3.8,4,4.3,4.7,4.9,5,5.5,6,6.5,6.8,7,7.3,7.5,7.8,8,8.4,8.7,9,9.4,9.6,9.8,10],a.identity_matrix=[1,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,1],a.length=a.identity_matrix.length,b.setcolor=function(a,b,c,d){return this.reset().adjustcolor(a,b,c,d)},b.reset=function(){return this.copy(a.identity_matrix)},b.adjustcolor=function(a,b,c,d){return this.adjusthue(d),this.adjustcontrast(b),this.adjustbrightness(a),this.adjustsaturation(c)},b.adjustbrightness=function(a){return 0==a||isnan(a)?this:(a=this._cleanvalue(a,255),this._multiplymatrix([1,0,0,0,a,0,1,0,0,a,0,0,1,0,a,0,0,0,1,0,0,0,0,0,1]),this)},b.adjustcontrast=function(b){if(0==b||isnan(b))return this;b=this._cleanvalue(b,100);var c;return 0>b?c=127+b/100*127:(c=b%1,c=0==c?a.delta_index[b]:a.delta_index[b<<0]*(1-c)+a.delta_index[(b<<0)+1]*c,c=127*c+127),this._multiplymatrix([c/127,0,0,0,.5*(127-c),0,c/127,0,0,.5*(127-c),0,0,c/127,0,.5*(127-c),0,0,0,1,0,0,0,0,0,1]),this},b.adjustsaturation=function(a){if(0==a||isnan(a))return this;a=this._cleanvalue(a,100);var b=1+(a>0?3*a/100:a/100),c=.3086,d=.6094,e=.082;return this._multiplymatrix([c*(1-b)+b,d*(1-b),e*(1-b),0,0,c*(1-b),d*(1-b)+b,e*(1-b),0,0,c*(1-b),d*(1-b),e*(1-b)+b,0,0,0,0,0,1,0,0,0,0,0,1]),this},b.adjusthue=function(a){if(0==a||isnan(a))return this;a=this._cleanvalue(a,180)/180*math.pi;var b=math.cos(a),c=math.sin(a),d=.213,e=.715,f=.072;return this._multiplymatrix([d+b*(1-d)+c*-d,e+b*-e+c*-e,f+b*-f+c*(1-f),0,0,d+b*-d+.143*c,e+b*(1-e)+.14*c,f+b*-f+c*-.283,0,0,d+b*-d+c*-(1-d),e+b*-e+c*e,f+b*(1-f)+c*f,0,0,0,0,0,1,0,0,0,0,0,1]),this},b.concat=function(b){return b=this._fixmatrix(b),b.length!=a.length?this:(this._multiplymatrix(b),this)},b.clone=function(){return(new a).copy(this)},b.toarray=function(){for(var b=[],c=0,d=a.length;d>c;c++)b[c]=this[c];return b},b.copy=function(b){for(var c=a.length,d=0;c>d;d++)this[d]=b[d];return this},b.tostring=function(){return"[colormatrix]"},b._multiplymatrix=function(a){var b,c,d,e=[];for(b=0;5>b;b++){for(c=0;5>c;c++)e[c]=this[c+5*b];for(c=0;5>c;c++){var f=0;for(d=0;5>d;d++)f+=a[c+5*d]*e[d];this[c+5*b]=f}}},b._cleanvalue=function(a,b){return math.min(b,math.max(-b,a))},b._fixmatrix=function(b){return b instanceof a&&(b=b.toarray()),b.lengtha.length&&(b=b.slice(0,a.length)),b},createjs.colormatrix=a}(),this.createjs=this.createjs||{},function(){"use strict";function a(a){this.matrix=a}var b=createjs.extend(a,createjs.filter);b.tostring=function(){return"[colormatrixfilter]"},b.clone=function(){return new a(this.matrix)},b._applyfilter=function(a){for(var b,c,d,e,f=a.data,g=f.length,h=this.matrix,i=h[0],j=h[1],k=h[2],l=h[3],m=h[4],n=h[5],o=h[6],p=h[7],q=h[8],r=h[9],s=h[10],t=h[11],u=h[12],v=h[13],w=h[14],x=h[15],y=h[16],z=h[17],a=h[18],b=h[19],c=0;g>c;c+=4)b=f[c],c=f[c+1],d=f[c+2],e=f[c+3],f[c]=b*i+c*j+d*k+e*l+m,f[c+1]=b*n+c*o+d*p+e*q+r,f[c+2]=b*s+c*t+d*u+e*v+w,f[c+3]=b*x+c*y+d*z+e*a+b;return!0},createjs.colormatrixfilter=createjs.promote(a,"filter")}(),this.createjs=this.createjs||{},function(){"use strict";function a(){throw"touch cannot be instantiated"}a.issupported=function(){return!!("ontouchstart"in window||window.navigator.mspointerenabled&&window.navigator.msmaxtouchpoints>0||window.navigator.pointerenabled&&window.navigator.maxtouchpoints>0)},a.enable=function(b,c,d){return b&&b.canvas&&a.issupported()?b.__touch?!0:(b.__touch={pointers:{},multitouch:!c,preventdefault:!d,count:0},"ontouchstart"in window?a._ios_enable(b):(window.navigator.mspointerenabled||window.navigator.pointerenabled)&&a._ie_enable(b),!0):!1},a.disable=function(b){b&&("ontouchstart"in window?a._ios_disable(b):(window.navigator.mspointerenabled||window.navigator.pointerenabled)&&a._ie_disable(b),delete b.__touch)},a._ios_enable=function(b){var c=b.canvas,d=b.__touch.f=function(c){a._ios_handleevent(b,c)};c.addeventlistener("touchstart",d,!1),c.addeventlistener("touchmove",d,!1),c.addeventlistener("touchend",d,!1),c.addeventlistener("touchcancel",d,!1)},a._ios_disable=function(a){var b=a.canvas;if(b){var c=a.__touch.f;b.removeeventlistener("touchstart",c,!1),b.removeeventlistener("touchmove",c,!1),b.removeeventlistener("touchend",c,!1),b.removeeventlistener("touchcancel",c,!1)}},a._ios_handleevent=function(a,b){if(a){a.__touch.preventdefault&&b.preventdefault&&b.preventdefault();for(var c=b.changedtouches,d=b.type,e=0,f=c.length;f>e;e++){var g=c[e],h=g.identifier;g.target==a.canvas&&("touchstart"==d?this._handlestart(a,h,b,g.pagex,g.pagey):"touchmove"==d?this._handlemove(a,h,b,g.pagex,g.pagey):("touchend"==d||"touchcancel"==d)&&this._handleend(a,h,b))}}},a._ie_enable=function(b){var c=b.canvas,d=b.__touch.f=function(c){a._ie_handleevent(b,c)};void 0===window.navigator.pointerenabled?(c.addeventlistener("mspointerdown",d,!1),window.addeventlistener("mspointermove",d,!1),window.addeventlistener("mspointerup",d,!1),window.addeventlistener("mspointercancel",d,!1),b.__touch.preventdefault&&(c.style.mstouchaction="none")):(c.addeventlistener("pointerdown",d,!1),window.addeventlistener("pointermove",d,!1),window.addeventlistener("pointerup",d,!1),window.addeventlistener("pointercancel",d,!1),b.__touch.preventdefault&&(c.style.touchaction="none")),b.__touch.activeids={}},a._ie_disable=function(a){var b=a.__touch.f;void 0===window.navigator.pointerenabled?(window.removeeventlistener("mspointermove",b,!1),window.removeeventlistener("mspointerup",b,!1),window.removeeventlistener("mspointercancel",b,!1),a.canvas&&a.canvas.removeeventlistener("mspointerdown",b,!1)):(window.removeeventlistener("pointermove",b,!1),window.removeeventlistener("pointerup",b,!1),window.removeeventlistener("pointercancel",b,!1),a.canvas&&a.canvas.removeeventlistener("pointerdown",b,!1))},a._ie_handleevent=function(a,b){if(a){a.__touch.preventdefault&&b.preventdefault&&b.preventdefault();var c=b.type,d=b.pointerid,e=a.__touch.activeids;if("mspointerdown"==c||"pointerdown"==c){if(b.srcelement!=a.canvas)return;e[d]=!0,this._handlestart(a,d,b,b.pagex,b.pagey)}else e[d]&&("mspointermove"==c||"pointermove"==c?this._handlemove(a,d,b,b.pagex,b.pagey):("mspointerup"==c||"mspointercancel"==c||"pointerup"==c||"pointercancel"==c)&&(delete e[d],this._handleend(a,d,b)))}},a._handlestart=function(a,b,c,d,e){var f=a.__touch;if(f.multitouch||!f.count){var g=f.pointers;g[b]||(g[b]=!0,f.count++,a._handlepointerdown(b,c,d,e))}},a._handlemove=function(a,b,c,d,e){a.__touch.pointers[b]&&a._handlepointermove(b,c,d,e)},a._handleend=function(a,b,c){var d=a.__touch,e=d.pointers;e[b]&&(d.count--,a._handlepointerup(b,c,!0),delete e[b])},createjs.touch=a}(),this.createjs=this.createjs||{},function(){"use strict";var a=createjs.easeljs=createjs.easeljs||{};a.version="0.8.2",a.builddate="thu, 26 nov 2015 20:44:34 gmt"}();