mirror of
https://github.com/gooba42/adventureland.git
synced 2026-10-14 18:39:27 -05:00
1 line
422 KiB
JavaScript
1 line
422 KiB
JavaScript
!function(t){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this).PIXI=t()}}(function(){return function o(s,a,u){function h(r,t){if(!a[r]){if(!s[r]){var e="function"==typeof require&&require;if(!t&&e)return e(r,!0);if(l)return l(r,!0);var i=new Error("Cannot find module '"+r+"'");throw i.code="MODULE_NOT_FOUND",i}var n=a[r]={exports:{}};s[r][0].call(n.exports,function(t){var e=s[r][1][t];return h(e||t)},n,n.exports,o,s,a,u)}return a[r].exports}for(var l="function"==typeof require&&require,t=0;t<u.length;t++)h(u[t]);return h}({1:[function(t,e,r){"use strict";function i(t){var e=32;return(t&=-t)&&e--,65535&t&&(e-=16),16711935&t&&(e-=8),252645135&t&&(e-=4),858993459&t&&(e-=2),1431655765&t&&--e,e}r.INT_BITS=32,r.INT_MAX=2147483647,r.INT_MIN=-1<<31,r.sign=function(t){return(0<t)-(t<0)},r.abs=function(t){var e=t>>31;return(t^e)-e},r.min=function(t,e){return e^(t^e)&-(t<e)},r.max=function(t,e){return t^(t^e)&-(t<e)},r.isPow2=function(t){return!(t&t-1||!t)},r.log2=function(t){var e,r;return e=(65535<t)<<4,e|=r=(255<(t>>>=e))<<3,e|=r=(15<(t>>>=r))<<2,(e|=r=(3<(t>>>=r))<<1)|(t>>>=r)>>1},r.log10=function(t){return 1e9<=t?9:1e8<=t?8:1e7<=t?7:1e6<=t?6:1e5<=t?5:1e4<=t?4:1e3<=t?3:100<=t?2:10<=t?1:0},r.popCount=function(t){return 16843009*((t=(858993459&(t-=t>>>1&1431655765))+(t>>>2&858993459))+(t>>>4)&252645135)>>>24},r.countTrailingZeros=i,r.nextPow2=function(t){return t+=0===t,--t,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,(t|=t>>>16)+1},r.prevPow2=function(t){return t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,(t|=t>>>16)-(t>>>1)},r.parity=function(t){return t^=t>>>16,t^=t>>>8,t^=t>>>4,27030>>>(t&=15)&1};var n=new Array(256);!function(t){for(var e=0;e<256;++e){var r=e,i=e,n=7;for(r>>>=1;r;r>>>=1)i<<=1,i|=1&r,--n;t[e]=i<<n&255}}(n),r.reverse=function(t){return n[255&t]<<24|n[t>>>8&255]<<16|n[t>>>16&255]<<8|n[t>>>24&255]},r.interleave2=function(t,e){return(t=1431655765&((t=858993459&((t=252645135&((t=16711935&((t&=65535)|t<<8))|t<<4))|t<<2))|t<<1))|(e=1431655765&((e=858993459&((e=252645135&((e=16711935&((e&=65535)|e<<8))|e<<4))|e<<2))|e<<1))<<1},r.deinterleave2=function(t,e){return(t=65535&((t=16711935&((t=252645135&((t=858993459&((t=t>>>e&1431655765)|t>>>1))|t>>>2))|t>>>4))|t>>>16))<<16>>16},r.interleave3=function(t,e,r){return t=1227133513&((t=3272356035&((t=251719695&((t=4278190335&((t&=1023)|t<<16))|t<<8))|t<<4))|t<<2),(t|=(e=1227133513&((e=3272356035&((e=251719695&((e=4278190335&((e&=1023)|e<<16))|e<<8))|e<<4))|e<<2))<<1)|(r=1227133513&((r=3272356035&((r=251719695&((r=4278190335&((r&=1023)|r<<16))|r<<8))|r<<4))|r<<2))<<2},r.deinterleave3=function(t,e){return(t=1023&((t=4278190335&((t=251719695&((t=3272356035&((t=t>>>e&1227133513)|t>>>2))|t>>>4))|t>>>8))|t>>>16))<<22>>22},r.nextCombination=function(t){var e=t|t-1;return 1+e|(~e&-~e)-1>>>i(t)+1}},{}],2:[function(t,e,r){"use strict";function i(t,e,r){r=r||2;var i,n,o,s,a,u,h,l=e&&e.length,c=l?e[0]*r:t.length,d=v(t,0,c,r,!0),f=[];if(!d||d.next===d.prev)return f;if(l&&(d=function(t,e,r,i){var n,o,s,a,u,h=[];for(n=0,o=e.length;n<o;n++)s=e[n]*i,a=n<o-1?e[n+1]*i:t.length,(u=v(t,s,a,i,!1))===u.next&&(u.steiner=!0),h.push(b(u));for(h.sort(m),n=0;n<h.length;n++)_(h[n],r),r=g(r,r.next);return r}(t,e,d,r)),t.length>80*r){i=o=t[0],n=s=t[1];for(var p=r;p<c;p+=r)(a=t[p])<i&&(i=a),(u=t[p+1])<n&&(n=u),o<a&&(o=a),s<u&&(s=u);h=0!==(h=Math.max(o-i,s-n))?1/h:0}return y(d,f,r,i,n,h),f}function v(t,e,r,i,n){var o,s;if(n===0<M(t,e,r,i))for(o=e;o<r;o+=i)s=u(o,t[o],t[o+1],s);else for(o=r-i;e<=o;o-=i)s=u(o,t[o],t[o+1],s);return s&&a(s,s.next)&&(O(s),s=s.next),s}function g(t,e){if(!t)return t;e=e||t;var r,i=t;do{if(r=!1,i.steiner||!a(i,i.next)&&0!==w(i.prev,i,i.next))i=i.next;else{if(O(i),(i=e=i.prev)===i.next)break;r=!0}}while(r||i!==e);return e}function y(t,e,r,i,n,o,s){if(t){!s&&o&&function(t,e,r,i){var n=t;for(;null===n.z&&(n.z=x(n.x,n.y,e,r,i)),n.prevZ=n.prev,n.nextZ=n.next,n=n.next,n!==t;);n.prevZ.nextZ=null,n.prevZ=null,function(t){var e,r,i,n,o,s,a,u,h=1;do{for(r=t,o=t=null,s=0;r;){for(s++,i=r,e=a=0;e<h&&(a++,i=i.nextZ);e++);for(u=h;0<a||0<u&&i;)0!==a&&(0===u||!i||r.z<=i.z)?(r=(n=r).nextZ,a--):(i=(n=i).nextZ,u--),o?o.nextZ=n:t=n,n.prevZ=o,o=n;r=i}o.nextZ=null,h*=2}while(1<s)}(n)}(t,i,n,o);for(var a,u,h=t;t.prev!==t.next;)if(a=t.prev,u=t.next,o?c(t,i,n,o):l(t))e.push(a.i/r),e.push(t.i/r),e.push(u.i/r),O(t),t=u.next,h=u.next;else if((t=u)===h){s?1===s?y(t=d(t,e,r),e,r,i,n,o,2):2===s&&f(t,e,r,i,n,o):y(g(t),e,r,i,n,o,1);break}}}function l(t){var e=t.prev,r=t,i=t.next;if(!(0<=w(e,r,i))){for(var n=t.next.next;n!==t.prev;){if(T(e.x,e.y,r.x,r.y,i.x,i.y,n.x,n.y)&&0<=w(n.prev,n,n.next))return;n=n.next}return 1}}function c(t,e,r,i){var n=t.prev,o=t,s=t.next;if(!(0<=w(n,o,s))){for(var a=n.x<o.x?n.x<s.x?n.x:s.x:o.x<s.x?o.x:s.x,u=n.y<o.y?n.y<s.y?n.y:s.y:o.y<s.y?o.y:s.y,h=n.x>o.x?n.x>s.x?n.x:s.x:o.x>s.x?o.x:s.x,l=n.y>o.y?n.y>s.y?n.y:s.y:o.y>s.y?o.y:s.y,c=x(a,u,e,r,i),d=x(h,l,e,r,i),f=t.prevZ,p=t.nextZ;f&&f.z>=c&&p&&p.z<=d;){if(f!==t.prev&&f!==t.next&&T(n.x,n.y,o.x,o.y,s.x,s.y,f.x,f.y)&&0<=w(f.prev,f,f.next))return;if(f=f.prevZ,p!==t.prev&&p!==t.next&&T(n.x,n.y,o.x,o.y,s.x,s.y,p.x,p.y)&&0<=w(p.prev,p,p.next))return;p=p.nextZ}for(;f&&f.z>=c;){if(f!==t.prev&&f!==t.next&&T(n.x,n.y,o.x,o.y,s.x,s.y,f.x,f.y)&&0<=w(f.prev,f,f.next))return;f=f.prevZ}for(;p&&p.z<=d;){if(p!==t.prev&&p!==t.next&&T(n.x,n.y,o.x,o.y,s.x,s.y,p.x,p.y)&&0<=w(p.prev,p,p.next))return;p=p.nextZ}return 1}}function d(t,e,r){var i=t;do{var n=i.prev,o=i.next.next;!a(n,o)&&p(n,i,i.next,o)&&E(n,o)&&E(o,n)&&(e.push(n.i/r),e.push(i.i/r),e.push(o.i/r),O(i),O(i.next),i=t=o),i=i.next}while(i!==t);return i}function f(t,e,r,i,n,o){var s,a,u=t;do{for(var h=u.next.next;h!==u.prev;){if(u.i!==h.i&&(a=h,(s=u).next.i!==a.i&&s.prev.i!==a.i&&!function(t,e){var r=t;do{if(r.i!==t.i&&r.next.i!==t.i&&r.i!==e.i&&r.next.i!==e.i&&p(r,r.next,t,e))return 1;r=r.next}while(r!==t);return}(s,a)&&E(s,a)&&E(a,s)&&function(t,e){var r=t,i=!1,n=(t.x+e.x)/2,o=(t.y+e.y)/2;for(;r.y>o!=r.next.y>o&&r.next.y!==r.y&&n<(r.next.x-r.x)*(o-r.y)/(r.next.y-r.y)+r.x&&(i=!i),r=r.next,r!==t;);return i}(s,a))){var l=S(u,h);return u=g(u,u.next),l=g(l,l.next),y(u,e,r,i,n,o),void y(l,e,r,i,n,o)}h=h.next}u=u.next}while(u!==t)}function m(t,e){return t.x-e.x}function _(t,e){if(e=function(t,e){var r,i=e,n=t.x,o=t.y,s=-1/0;do{if(o<=i.y&&o>=i.next.y&&i.next.y!==i.y){var a=i.x+(o-i.y)*(i.next.x-i.x)/(i.next.y-i.y);if(a<=n&&s<a){if((s=a)===n){if(o===i.y)return i;if(o===i.next.y)return i.next}r=i.x<i.next.x?i:i.next}}i=i.next}while(i!==e);if(!r)return null;if(n===s)return r.prev;var u,h=r,l=r.x,c=r.y,d=1/0;i=r.next;for(;i!==h;)n>=i.x&&i.x>=l&&n!==i.x&&T(o<c?n:s,o,l,c,o<c?s:n,o,i.x,i.y)&&((u=Math.abs(o-i.y)/(n-i.x))<d||u===d&&i.x>r.x)&&E(i,t)&&(r=i,d=u),i=i.next;return r}(t,e)){var r=S(e,t);g(r,r.next)}}function x(t,e,r,i,n){return(t=1431655765&((t=858993459&((t=252645135&((t=16711935&((t=32767*(t-r)*n)|t<<8))|t<<4))|t<<2))|t<<1))|(e=1431655765&((e=858993459&((e=252645135&((e=16711935&((e=32767*(e-i)*n)|e<<8))|e<<4))|e<<2))|e<<1))<<1}function b(t){for(var e=t,r=t;e.x<r.x&&(r=e),(e=e.next)!==t;);return r}function T(t,e,r,i,n,o,s,a){return 0<=(n-s)*(e-a)-(t-s)*(o-a)&&0<=(t-s)*(i-a)-(r-s)*(e-a)&&0<=(r-s)*(o-a)-(n-s)*(i-a)}function w(t,e,r){return(e.y-t.y)*(r.x-e.x)-(e.x-t.x)*(r.y-e.y)}function a(t,e){return t.x===e.x&&t.y===e.y}function p(t,e,r,i){return a(t,e)&&a(r,i)||a(t,i)&&a(r,e)||0<w(t,e,r)!=0<w(t,e,i)&&0<w(r,i,t)!=0<w(r,i,e)}function E(t,e){return w(t.prev,t,t.next)<0?0<=w(t,e,t.next)&&0<=w(t,t.prev,e):w(t,e,t.prev)<0||w(t,t.next,e)<0}function S(t,e){var r=new s(t.i,t.x,t.y),i=new s(e.i,e.x,e.y),n=t.next,o=e.prev;return(t.next=e).prev=t,(r.next=n).prev=r,(i.next=r).prev=i,(o.next=i).prev=o,i}function u(t,e,r,i){var n=new s(t,e,r);return i?(n.next=i.next,(n.prev=i).next.prev=n,i.next=n):(n.prev=n).next=n,n}function O(t){t.next.prev=t.prev,t.prev.next=t.next,t.prevZ&&(t.prevZ.nextZ=t.nextZ),t.nextZ&&(t.nextZ.prevZ=t.prevZ)}function s(t,e,r){this.i=t,this.x=e,this.y=r,this.prev=null,this.next=null,this.z=null,this.prevZ=null,this.nextZ=null,this.steiner=!1}function M(t,e,r,i){for(var n=0,o=e,s=r-i;o<r;o+=i)n+=(t[s]-t[o])*(t[o+1]+t[s+1]),s=o;return n}e.exports=i,(e.exports.default=i).deviation=function(t,e,r,i){var n=e&&e.length,o=n?e[0]*r:t.length,s=Math.abs(M(t,0,o,r));if(n)for(var a=0,u=e.length;a<u;a++){var h=e[a]*r,l=a<u-1?e[a+1]*r:t.length;s-=Math.abs(M(t,h,l,r))}var c=0;for(a=0;a<i.length;a+=3){var d=i[a]*r,f=i[a+1]*r,p=i[a+2]*r;c+=Math.abs((t[d]-t[p])*(t[1+f]-t[1+d])-(t[d]-t[f])*(t[1+p]-t[1+d]))}return 0===s&&0===c?0:Math.abs((c-s)/s)},i.flatten=function(t){for(var e=t[0][0].length,r={vertices:[],holes:[],dimensions:e},i=0,n=0;n<t.length;n++){for(var o=0;o<t[n].length;o++)for(var s=0;s<e;s++)r.vertices.push(t[n][o][s]);0<n&&(i+=t[n-1].length,r.holes.push(i))}return r}},{}],3:[function(t,e,r){"use strict";var i=Object.prototype.hasOwnProperty,f="~";function h(){}function o(t,e,r){this.fn=t,this.context=e,this.once=r||!1}function n(){this._events=new h,this._eventsCount=0}Object.create&&(h.prototype=Object.create(null),(new h).__proto__||(f=!1)),n.prototype.eventNames=function(){var t,e,r=[];if(0===this._eventsCount)return r;for(e in t=this._events)i.call(t,e)&&r.push(f?e.slice(1):e);return Object.getOwnPropertySymbols?r.concat(Object.getOwnPropertySymbols(t)):r},n.prototype.listeners=function(t,e){var r=f?f+t:t,i=this._events[r];if(e)return!!i;if(!i)return[];if(i.fn)return[i.fn];for(var n=0,o=i.length,s=new Array(o);n<o;n++)s[n]=i[n].fn;return s},n.prototype.emit=function(t,e,r,i,n,o){var s=f?f+t:t;if(!this._events[s])return!1;var a,u,h=this._events[s],l=arguments.length;if(h.fn){switch(h.once&&this.removeListener(t,h.fn,void 0,!0),l){case 1:return h.fn.call(h.context),!0;case 2:return h.fn.call(h.context,e),!0;case 3:return h.fn.call(h.context,e,r),!0;case 4:return h.fn.call(h.context,e,r,i),!0;case 5:return h.fn.call(h.context,e,r,i,n),!0;case 6:return h.fn.call(h.context,e,r,i,n,o),!0}for(u=1,a=new Array(l-1);u<l;u++)a[u-1]=arguments[u];h.fn.apply(h.context,a)}else{var c,d=h.length;for(u=0;u<d;u++)switch(h[u].once&&this.removeListener(t,h[u].fn,void 0,!0),l){case 1:h[u].fn.call(h[u].context);break;case 2:h[u].fn.call(h[u].context,e);break;case 3:h[u].fn.call(h[u].context,e,r);break;case 4:h[u].fn.call(h[u].context,e,r,i);break;default:if(!a)for(c=1,a=new Array(l-1);c<l;c++)a[c-1]=arguments[c];h[u].fn.apply(h[u].context,a)}}return!0},n.prototype.on=function(t,e,r){var i=new o(e,r||this),n=f?f+t:t;return this._events[n]?this._events[n].fn?this._events[n]=[this._events[n],i]:this._events[n].push(i):(this._events[n]=i,this._eventsCount++),this},n.prototype.once=function(t,e,r){var i=new o(e,r||this,!0),n=f?f+t:t;return this._events[n]?this._events[n].fn?this._events[n]=[this._events[n],i]:this._events[n].push(i):(this._events[n]=i,this._eventsCount++),this},n.prototype.removeListener=function(t,e,r,i){var n=f?f+t:t;if(!this._events[n])return this;if(!e)return 0==--this._eventsCount?this._events=new h:delete this._events[n],this;var o=this._events[n];if(o.fn)o.fn!==e||i&&!o.once||r&&o.context!==r||(0==--this._eventsCount?this._events=new h:delete this._events[n]);else{for(var s=0,a=[],u=o.length;s<u;s++)(o[s].fn!==e||i&&!o[s].once||r&&o[s].context!==r)&&a.push(o[s]);a.length?this._events[n]=1===a.length?a[0]:a:0==--this._eventsCount?this._events=new h:delete this._events[n]}return this},n.prototype.removeAllListeners=function(t){var e;return t?(e=f?f+t:t,this._events[e]&&(0==--this._eventsCount?this._events=new h:delete this._events[e])):(this._events=new h,this._eventsCount=0),this},n.prototype.off=n.prototype.removeListener,n.prototype.addListener=n.prototype.on,n.prototype.setMaxListeners=function(){return this},n.prefixed=f,n.EventEmitter=n,void 0!==e&&(e.exports=n)},{}],4:[function(t,e,r){function n(t,e){return t.test(e)}function i(t){var e=t||("undefined"!=typeof navigator?navigator.userAgent:""),r=e.split("[FBAN");void 0!==r[1]&&(e=r[0]),void 0!==(r=e.split("Twitter"))[1]&&(e=r[0]);var i={apple:{phone:n(s,e)&&!n(f,e),ipod:n(a,e),tablet:!n(s,e)&&n(u,e)&&!n(f,e),device:(n(s,e)||n(a,e)||n(u,e))&&!n(f,e)},amazon:{phone:n(c,e),tablet:!n(c,e)&&n(d,e),device:n(c,e)||n(d,e)},android:{phone:!n(f,e)&&n(c,e)||!n(f,e)&&n(h,e),tablet:!n(f,e)&&!n(c,e)&&!n(h,e)&&(n(d,e)||n(l,e)),device:!n(f,e)&&(n(c,e)||n(d,e)||n(h,e)||n(l,e))},windows:{phone:n(f,e),tablet:n(p,e),device:n(f,e)||n(p,e)},other:{blackberry:n(v,e),blackberry10:n(g,e),opera:n(y,e),firefox:n(_,e),chrome:n(m,e),device:n(v,e)||n(g,e)||n(y,e)||n(_,e)||n(m,e)}};return i.any=i.apple.device||i.android.device||i.windows.device||i.other.device,i.phone=i.apple.phone||i.android.phone||i.windows.phone,i.tablet=i.apple.tablet||i.android.tablet||i.windows.tablet,i}var o,s,a,u,h,l,c,d,f,p,v,g,y,m,_;o=this,s=/iPhone/i,a=/iPod/i,u=/iPad/i,h=/\bAndroid(?:.+)Mobile\b/i,l=/Android/i,c=/\bAndroid(?:.+)SD4930UR\b/i,d=/\bAndroid(?:.+)(?:KF[A-Z]{2,4})\b/i,f=/Windows Phone/i,p=/\bWindows(?:.+)ARM\b/i,v=/BlackBerry/i,g=/BB10/i,y=/Opera Mini/i,m=/\b(CriOS|Chrome)(?:.+)Mobile/i,_=/\Mobile(?:.+)Firefox\b/i,void 0!==e&&e.exports&&"undefined"==typeof window?e.exports=i:void 0!==e&&e.exports&&"undefined"!=typeof window?e.exports=i():o.isMobile=i()},{}],5:[function(t,e,r){"use strict";Object.defineProperty(r,"__esModule",{value:!0});var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}var s=(i(a,[{key:"detach",value:function(){return null!==this._owner&&(this._owner.detach(this),!0)}}]),a);function a(t,e,r){void 0===e&&(e=!1),o(this,a),this._fn=t,this._once=e,this._thisArg=r,this._next=this._prev=this._owner=null}function u(t,e){return t._head?(t._tail._next=e)._prev=t._tail:t._head=e,(t._tail=e)._owner=t,e}var h=(i(l,[{key:"handlers",value:function(t){var e=!(arguments.length<=0||void 0===t)&&t,r=this._head;if(e)return!!r;for(var i=[];r;)i.push(r),r=r._next;return i}},{key:"has",value:function(t){if(!(t instanceof s))throw new Error("MiniSignal#has(): First arg must be a MiniSignalBinding object.");return t._owner===this}},{key:"dispatch",value:function(){var t=this._head;if(!t)return!1;for(;t;)t._once&&this.detach(t),t._fn.apply(t._thisArg,arguments),t=t._next;return!0}},{key:"add",value:function(t,e){var r=arguments.length<=1||void 0===e?null:e;if("function"!=typeof t)throw new Error("MiniSignal#add(): First arg must be a Function.");return u(this,new s(t,!1,r))}},{key:"once",value:function(t,e){var r=arguments.length<=1||void 0===e?null:e;if("function"!=typeof t)throw new Error("MiniSignal#once(): First arg must be a Function.");return u(this,new s(t,!0,r))}},{key:"detach",value:function(t){if(!(t instanceof s))throw new Error("MiniSignal#detach(): First arg must be a MiniSignalBinding object.");return t._owner!==this||(t._prev&&(t._prev._next=t._next),t._next&&(t._next._prev=t._prev),t===this._head?(this._head=t._next,null===t._next&&(this._tail=null)):t===this._tail&&(this._tail=t._prev,this._tail._next=null),t._owner=null),this}},{key:"detachAll",value:function(){var t=this._head;if(!t)return this;for(this._head=this._tail=null;t;)t._owner=null,t=t._next;return this}}]),l);function l(){o(this,l),this._head=this._tail=void 0}h.MiniSignalBinding=s,r.default=h,e.exports=r.default},{}],6:[function(t,e,r){"use strict";var u=Object.getOwnPropertySymbols,h=Object.prototype.hasOwnProperty,l=Object.prototype.propertyIsEnumerable;e.exports=function(){try{if(!Object.assign)return;var t=new String("abc");if(t[5]="de","5"===Object.getOwnPropertyNames(t)[0])return;for(var e={},r=0;r<10;r++)e["_"+String.fromCharCode(r)]=r;if("0123456789"!==Object.getOwnPropertyNames(e).map(function(t){return e[t]}).join(""))return;var i={};return"abcdefghijklmnopqrst".split("").forEach(function(t){i[t]=t}),"abcdefghijklmnopqrst"!==Object.keys(Object.assign({},i)).join("")?void 0:1}catch(t){return}}()?Object.assign:function(t,e){for(var r,i,n=function(t){if(null==t)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(t)}(t),o=1;o<arguments.length;o++){for(var s in r=Object(arguments[o]))h.call(r,s)&&(n[s]=r[s]);if(u){i=u(r);for(var a=0;a<i.length;a++)l.call(r,i[a])&&(n[i[a]]=r[i[a]])}}return n}},{}],7:[function(t,e,r){"use strict";e.exports=function(t,e){e=e||{};for(var i={key:["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"],q:{name:"queryKey",parser:/(?:^|&)([^&=]*)=?([^&]*)/g},parser:{strict:/^(?:([^:\/?#]+):)?(?:\/\/((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\/?#]*)(?::(\d*))?))?((((?:[^?#\/]*\/)*)([^?#]*))(?:\?([^#]*))?(?:#(.*))?)/,loose:/^(?:(?![^:@]+:[^:@\/]*@)([^:\/?#.]+):)?(?:\/\/)?((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/}},r=i.parser[e.strictMode?"strict":"loose"].exec(t),n={},o=14;o--;)n[i.key[o]]=r[o]||"";return n[i.q.name]={},n[i.key[12]].replace(i.q.parser,function(t,e,r){e&&(n[i.q.name][e]=r)}),n}},{}],8:[function(t,e,h){(function(n){function o(t,e){for(var r=0,i=t.length-1;0<=i;i--){var n=t[i];"."===n?t.splice(i,1):".."===n?(t.splice(i,1),r++):r&&(t.splice(i,1),r--)}if(e)for(;r--;)t.unshift("..");return t}function s(t){return e.exec(t).slice(1)}var e=/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/;function a(t,e){if(t.filter)return t.filter(e);for(var r=[],i=0;i<t.length;i++)e(t[i],i,t)&&r.push(t[i]);return r}h.resolve=function(){for(var t="",e=!1,r=arguments.length-1;-1<=r&&!e;r--){var i=0<=r?arguments[r]:n.cwd();if("string"!=typeof i)throw new TypeError("Arguments to path.resolve must be strings");i&&(t=i+"/"+t,e="/"===i.charAt(0))}return(e?"/":"")+(t=o(a(t.split("/"),function(t){return!!t}),!e).join("/"))||"."},h.normalize=function(t){var e=h.isAbsolute(t),r="/"===i(t,-1);return(t=o(a(t.split("/"),function(t){return!!t}),!e).join("/"))||e||(t="."),t&&r&&(t+="/"),(e?"/":"")+t},h.isAbsolute=function(t){return"/"===t.charAt(0)},h.join=function(){var t=Array.prototype.slice.call(arguments,0);return h.normalize(a(t,function(t,e){if("string"!=typeof t)throw new TypeError("Arguments to path.join must be strings");return t}).join("/"))},h.relative=function(t,e){function r(t){for(var e=0;e<t.length&&""===t[e];e++);for(var r=t.length-1;0<=r&&""===t[r];r--);return r<e?[]:t.slice(e,r-e+1)}t=h.resolve(t).substr(1),e=h.resolve(e).substr(1);for(var i=r(t.split("/")),n=r(e.split("/")),o=Math.min(i.length,n.length),s=o,a=0;a<o;a++)if(i[a]!==n[a]){s=a;break}var u=[];for(a=s;a<i.length;a++)u.push("..");return(u=u.concat(n.slice(s))).join("/")},h.sep="/",h.delimiter=":",h.dirname=function(t){var e=s(t),r=e[0],i=e[1];return r||i?r+(i=i&&i.substr(0,i.length-1)):"."},h.basename=function(t,e){var r=s(t)[2];return e&&r.substr(-1*e.length)===e&&(r=r.substr(0,r.length-e.length)),r},h.extname=function(t){return s(t)[3]};var i="b"==="ab".substr(-1)?function(t,e,r){return t.substr(e,r)}:function(t,e,r){return e<0&&(e=t.length+e),t.substr(e,r)}}).call(this,t("_process"))},{_process:26}],9:[function(t,e,r){function n(t,e,r,i){this.gl=t,this.buffer=t.createBuffer(),this.type=e||t.ARRAY_BUFFER,this.drawType=i||t.STATIC_DRAW,this.data=o,r&&this.upload(r),this._updateID=0}var o=new ArrayBuffer(0);n.prototype.upload=function(t,e,r){r||this.bind();var i=this.gl;t=t||this.data,e=e||0,this.data.byteLength>=t.byteLength?i.bufferSubData(this.type,e,t):i.bufferData(this.type,t,this.drawType),this.data=t},n.prototype.bind=function(){this.gl.bindBuffer(this.type,this.buffer)},n.createVertexBuffer=function(t,e,r){return new n(t,t.ARRAY_BUFFER,e,r)},n.createIndexBuffer=function(t,e,r){return new n(t,t.ELEMENT_ARRAY_BUFFER,e,r)},n.create=function(t,e,r,i){return new n(t,e,r,i)},n.prototype.destroy=function(){this.gl.deleteBuffer(this.buffer)},e.exports=n},{}],10:[function(t,e,r){function s(t,e,r){this.gl=t,this.framebuffer=t.createFramebuffer(),this.stencil=null,this.texture=null,this.width=e||100,this.height=r||100}var a=t("./GLTexture");s.prototype.enableTexture=function(t){var e=this.gl;this.texture=t||new a(e),this.texture.bind(),this.bind(),e.framebufferTexture2D(e.FRAMEBUFFER,e.COLOR_ATTACHMENT0,e.TEXTURE_2D,this.texture.texture,0)},s.prototype.enableStencil=function(){if(!this.stencil){var t=this.gl;this.stencil=t.createRenderbuffer(),t.bindRenderbuffer(t.RENDERBUFFER,this.stencil),t.framebufferRenderbuffer(t.FRAMEBUFFER,t.DEPTH_STENCIL_ATTACHMENT,t.RENDERBUFFER,this.stencil),t.renderbufferStorage(t.RENDERBUFFER,t.DEPTH_STENCIL,this.width,this.height)}},s.prototype.clear=function(t,e,r,i){this.bind();var n=this.gl;n.clearColor(t,e,r,i),n.clear(n.COLOR_BUFFER_BIT|n.DEPTH_BUFFER_BIT)},s.prototype.bind=function(){var t=this.gl;t.bindFramebuffer(t.FRAMEBUFFER,this.framebuffer)},s.prototype.unbind=function(){var t=this.gl;t.bindFramebuffer(t.FRAMEBUFFER,null)},s.prototype.resize=function(t,e){var r=this.gl;this.width=t,this.height=e,this.texture&&this.texture.uploadData(null,t,e),this.stencil&&(r.bindRenderbuffer(r.RENDERBUFFER,this.stencil),r.renderbufferStorage(r.RENDERBUFFER,r.DEPTH_STENCIL,t,e))},s.prototype.destroy=function(){var t=this.gl;this.texture&&this.texture.destroy(),t.deleteFramebuffer(this.framebuffer),this.gl=null,this.stencil=null,this.texture=null},s.createRGBA=function(t,e,r,i){var n=a.fromData(t,null,e,r);n.enableNearestScaling(),n.enableWrapClamp();var o=new s(t,e,r);return o.enableTexture(n),o.unbind(),o},s.createFloat32=function(t,e,r,i){var n=new a.fromData(t,i,e,r);n.enableNearestScaling(),n.enableWrapClamp();var o=new s(t,e,r);return o.enableTexture(n),o.unbind(),o},e.exports=s},{"./GLTexture":12}],11:[function(t,e,r){function i(t,e,r,i,n){this.gl=t,i&&(e=u(e,i),r=u(r,i)),this.program=o(t,e,r,n),this.attributes=s(t,this.program),this.uniformData=a(t,this.program),this.uniforms=h(t,this.uniformData)}var o=t("./shader/compileProgram"),s=t("./shader/extractAttributes"),a=t("./shader/extractUniforms"),u=t("./shader/setPrecision"),h=t("./shader/generateUniformAccessObject");i.prototype.bind=function(){return this.gl.useProgram(this.program),this},i.prototype.destroy=function(){this.attributes=null,this.uniformData=null,this.uniforms=null,this.gl.deleteProgram(this.program)},e.exports=i},{"./shader/compileProgram":17,"./shader/extractAttributes":19,"./shader/extractUniforms":20,"./shader/generateUniformAccessObject":21,"./shader/setPrecision":25}],12:[function(t,e,r){function o(t,e,r,i,n){this.gl=t,this.texture=t.createTexture(),this.mipmap=!1,this.premultiplyAlpha=!1,this.width=e||-1,this.height=r||-1,this.format=i||t.RGBA,this.type=n||t.UNSIGNED_BYTE}var n=!(o.prototype.upload=function(t){this.bind();var e=this.gl;e.pixelStorei(e.UNPACK_PREMULTIPLY_ALPHA_WEBGL,this.premultiplyAlpha);var r=t.videoWidth||t.width,i=t.videoHeight||t.height;i!==this.height||r!==this.width?e.texImage2D(e.TEXTURE_2D,0,this.format,this.format,this.type,t):e.texSubImage2D(e.TEXTURE_2D,0,0,0,this.format,this.type,t),this.width=r,this.height=i});o.prototype.uploadData=function(t,e,r){this.bind();var i=this.gl;if(t instanceof Float32Array){if(!n){if(!i.getExtension("OES_texture_float"))throw new Error("floating point textures not available");n=!0}this.type=i.FLOAT}else this.type=this.type||i.UNSIGNED_BYTE;i.pixelStorei(i.UNPACK_PREMULTIPLY_ALPHA_WEBGL,this.premultiplyAlpha),e!==this.width||r!==this.height?i.texImage2D(i.TEXTURE_2D,0,this.format,e,r,0,this.format,this.type,t||null):i.texSubImage2D(i.TEXTURE_2D,0,0,0,e,r,this.format,this.type,t||null),this.width=e,this.height=r},o.prototype.bind=function(t){var e=this.gl;void 0!==t&&e.activeTexture(e.TEXTURE0+t),e.bindTexture(e.TEXTURE_2D,this.texture)},o.prototype.unbind=function(){var t=this.gl;t.bindTexture(t.TEXTURE_2D,null)},o.prototype.minFilter=function(t){var e=this.gl;this.bind(),this.mipmap?e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,t?e.LINEAR_MIPMAP_LINEAR:e.NEAREST_MIPMAP_NEAREST):e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,t?e.LINEAR:e.NEAREST)},o.prototype.magFilter=function(t){var e=this.gl;this.bind(),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MAG_FILTER,t?e.LINEAR:e.NEAREST)},o.prototype.enableMipmap=function(){var t=this.gl;this.bind(),this.mipmap=!0,t.generateMipmap(t.TEXTURE_2D)},o.prototype.enableLinearScaling=function(){this.minFilter(!0),this.magFilter(!0)},o.prototype.enableNearestScaling=function(){this.minFilter(!1),this.magFilter(!1)},o.prototype.enableWrapClamp=function(){var t=this.gl;this.bind(),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_S,t.CLAMP_TO_EDGE),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_T,t.CLAMP_TO_EDGE)},o.prototype.enableWrapRepeat=function(){var t=this.gl;this.bind(),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_S,t.REPEAT),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_T,t.REPEAT)},o.prototype.enableWrapMirrorRepeat=function(){var t=this.gl;this.bind(),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_S,t.MIRRORED_REPEAT),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_T,t.MIRRORED_REPEAT)},o.prototype.destroy=function(){this.gl.deleteTexture(this.texture)},o.fromSource=function(t,e,r){var i=new o(t);return i.premultiplyAlpha=r||!1,i.upload(e),i},o.fromData=function(t,e,r,i){var n=new o(t);return n.uploadData(e,r,i),n},e.exports=o},{}],13:[function(t,e,r){var n=t("./setVertexAttribArrays");function i(t,e){if(this.nativeVaoExtension=null,i.FORCE_NATIVE||(this.nativeVaoExtension=t.getExtension("OES_vertex_array_object")||t.getExtension("MOZ_OES_vertex_array_object")||t.getExtension("WEBKIT_OES_vertex_array_object")),this.nativeState=e,this.nativeVaoExtension){this.nativeVao=this.nativeVaoExtension.createVertexArrayOES();var r=t.getParameter(t.MAX_VERTEX_ATTRIBS);this.nativeState={tempAttribState:new Array(r),attribState:new Array(r)}}this.gl=t,this.attributes=[],this.indexBuffer=null,this.dirty=!1}i.prototype.constructor=i,(e.exports=i).FORCE_NATIVE=!1,i.prototype.bind=function(){if(this.nativeVao){if(this.nativeVaoExtension.bindVertexArrayOES(this.nativeVao),this.dirty)return this.dirty=!1,this.activate(),this;this.indexBuffer&&this.indexBuffer.bind()}else this.activate();return this},i.prototype.unbind=function(){return this.nativeVao&&this.nativeVaoExtension.bindVertexArrayOES(null),this},i.prototype.activate=function(){for(var t=this.gl,e=null,r=0;r<this.attributes.length;r++){var i=this.attributes[r];e!==i.buffer&&(i.buffer.bind(),e=i.buffer),t.vertexAttribPointer(i.attribute.location,i.attribute.size,i.type||t.FLOAT,i.normalized||!1,i.stride||0,i.start||0)}return n(t,this.attributes,this.nativeState),this.indexBuffer&&this.indexBuffer.bind(),this},i.prototype.addAttribute=function(t,e,r,i,n,o){return this.attributes.push({buffer:t,attribute:e,location:e.location,type:r||this.gl.FLOAT,normalized:i||!1,stride:n||0,start:o||0}),this.dirty=!0,this},i.prototype.addIndex=function(t){return this.indexBuffer=t,this.dirty=!0,this},i.prototype.clear=function(){return this.nativeVao&&this.nativeVaoExtension.bindVertexArrayOES(this.nativeVao),this.attributes.length=0,this.indexBuffer=null,this},i.prototype.draw=function(t,e,r){var i=this.gl;return this.indexBuffer?i.drawElements(t,e||this.indexBuffer.data.length,i.UNSIGNED_SHORT,2*(r||0)):i.drawArrays(t,r,e||this.getSize()),this},i.prototype.destroy=function(){this.gl=null,this.indexBuffer=null,this.attributes=null,this.nativeState=null,this.nativeVao&&this.nativeVaoExtension.deleteVertexArrayOES(this.nativeVao),this.nativeVaoExtension=null,this.nativeVao=null},i.prototype.getSize=function(){var t=this.attributes[0];return t.buffer.data.length/(t.stride/4||t.attribute.size)}},{"./setVertexAttribArrays":16}],14:[function(t,e,r){e.exports=function(t,e){var r=t.getContext("webgl",e)||t.getContext("experimental-webgl",e);if(!r)throw new Error("This browser does not support webGL. Try using the canvas renderer");return r}},{}],15:[function(t,e,r){var i={createContext:t("./createContext"),setVertexAttribArrays:t("./setVertexAttribArrays"),GLBuffer:t("./GLBuffer"),GLFramebuffer:t("./GLFramebuffer"),GLShader:t("./GLShader"),GLTexture:t("./GLTexture"),VertexArrayObject:t("./VertexArrayObject"),shader:t("./shader")};void 0!==e&&e.exports&&(e.exports=i),"undefined"!=typeof window&&(window.PIXI=window.PIXI||{},window.PIXI.glCore=i)},{"./GLBuffer":9,"./GLFramebuffer":10,"./GLShader":11,"./GLTexture":12,"./VertexArrayObject":13,"./createContext":14,"./setVertexAttribArrays":16,"./shader":22}],16:[function(t,e,r){e.exports=function(t,e,r){var i;if(r){var n=r.tempAttribState,o=r.attribState;for(i=0;i<n.length;i++)n[i]=!1;for(i=0;i<e.length;i++)n[e[i].attribute.location]=!0;for(i=0;i<o.length;i++)o[i]!==n[i]&&(o[i]=n[i],r.attribState[i]?t.enableVertexAttribArray(i):t.disableVertexAttribArray(i))}else for(i=0;i<e.length;i++){var s=e[i];t.enableVertexAttribArray(s.attribute.location)}}},{}],17:[function(t,e,r){var u=function(t,e,r){var i=t.createShader(e);return t.shaderSource(i,r),t.compileShader(i),t.getShaderParameter(i,t.COMPILE_STATUS)?i:(console.log(t.getShaderInfoLog(i)),null)};e.exports=function(t,e,r,i){var n=u(t,t.VERTEX_SHADER,e),o=u(t,t.FRAGMENT_SHADER,r),s=t.createProgram();if(t.attachShader(s,n),t.attachShader(s,o),i)for(var a in i)t.bindAttribLocation(s,i[a],a);return t.linkProgram(s),t.getProgramParameter(s,t.LINK_STATUS)||(console.error("Pixi.js Error: Could not initialize shader."),console.error("gl.VALIDATE_STATUS",t.getProgramParameter(s,t.VALIDATE_STATUS)),console.error("gl.getError()",t.getError()),""!==t.getProgramInfoLog(s)&&console.warn("Pixi.js Warning: gl.getProgramInfoLog()",t.getProgramInfoLog(s)),t.deleteProgram(s),s=null),t.deleteShader(n),t.deleteShader(o),s}},{}],18:[function(t,e,r){var i=function(t){for(var e=new Array(t),r=0;r<e.length;r++)e[r]=!1;return e};e.exports=function(t,e){switch(t){case"float":return 0;case"vec2":return new Float32Array(2*e);case"vec3":return new Float32Array(3*e);case"vec4":return new Float32Array(4*e);case"int":case"sampler2D":return 0;case"ivec2":return new Int32Array(2*e);case"ivec3":return new Int32Array(3*e);case"ivec4":return new Int32Array(4*e);case"bool":return!1;case"bvec2":return i(2*e);case"bvec3":return i(3*e);case"bvec4":return i(4*e);case"mat2":return new Float32Array([1,0,0,1]);case"mat3":return new Float32Array([1,0,0,0,1,0,0,0,1]);case"mat4":return new Float32Array([1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1])}}},{}],19:[function(t,e,r){var a=t("./mapType"),u=t("./mapSize"),h=function(t,e,r,i){gl.vertexAttribPointer(this.location,this.size,t||gl.FLOAT,e||!1,r||0,i||0)};e.exports=function(t,e){for(var r={},i=t.getProgramParameter(e,t.ACTIVE_ATTRIBUTES),n=0;n<i;n++){var o=t.getActiveAttrib(e,n),s=a(t,o.type);r[o.name]={type:s,size:u(s),location:t.getAttribLocation(e,o.name),pointer:h}}return r}},{"./mapSize":23,"./mapType":24}],20:[function(t,e,r){var u=t("./mapType"),h=t("./defaultValue");e.exports=function(t,e){for(var r={},i=t.getProgramParameter(e,t.ACTIVE_UNIFORMS),n=0;n<i;n++){var o=t.getActiveUniform(e,n),s=o.name.replace(/\[.*?\]/,""),a=u(t,o.type);r[s]={type:a,size:o.size,location:t.getUniformLocation(e,s),value:h(a,o.size)}}return r}},{"./defaultValue":18,"./mapType":24}],21:[function(t,e,r){var l=function(t){return function(){return this.data[t].value}},n={float:function(t,e,r){t.uniform1f(e,r)},vec2:function(t,e,r){t.uniform2f(e,r[0],r[1])},vec3:function(t,e,r){t.uniform3f(e,r[0],r[1],r[2])},vec4:function(t,e,r){t.uniform4f(e,r[0],r[1],r[2],r[3])},int:function(t,e,r){t.uniform1i(e,r)},ivec2:function(t,e,r){t.uniform2i(e,r[0],r[1])},ivec3:function(t,e,r){t.uniform3i(e,r[0],r[1],r[2])},ivec4:function(t,e,r){t.uniform4i(e,r[0],r[1],r[2],r[3])},bool:function(t,e,r){t.uniform1i(e,r)},bvec2:function(t,e,r){t.uniform2i(e,r[0],r[1])},bvec3:function(t,e,r){t.uniform3i(e,r[0],r[1],r[2])},bvec4:function(t,e,r){t.uniform4i(e,r[0],r[1],r[2],r[3])},mat2:function(t,e,r){t.uniformMatrix2fv(e,!1,r)},mat3:function(t,e,r){t.uniformMatrix3fv(e,!1,r)},mat4:function(t,e,r){t.uniformMatrix4fv(e,!1,r)},sampler2D:function(t,e,r){t.uniform1i(e,r)}},o={float:function(t,e,r){t.uniform1fv(e,r)},vec2:function(t,e,r){t.uniform2fv(e,r)},vec3:function(t,e,r){t.uniform3fv(e,r)},vec4:function(t,e,r){t.uniform4fv(e,r)},int:function(t,e,r){t.uniform1iv(e,r)},ivec2:function(t,e,r){t.uniform2iv(e,r)},ivec3:function(t,e,r){t.uniform3iv(e,r)},ivec4:function(t,e,r){t.uniform4iv(e,r)},bool:function(t,e,r){t.uniform1iv(e,r)},bvec2:function(t,e,r){t.uniform2iv(e,r)},bvec3:function(t,e,r){t.uniform3iv(e,r)},bvec4:function(t,e,r){t.uniform4iv(e,r)},sampler2D:function(t,e,r){t.uniform1iv(e,r)}};function c(r,i){return function(t){this.data[r].value=t;var e=this.data[r].location;1===i.size?n[i.type](this.gl,e,t):o[i.type](this.gl,e,t)}}function d(t,e){for(var r=e,i=0;i<t.length-1;i++){var n=r[t[i]]||{data:{}};r[t[i]]=n,r=n}return r}e.exports=function(t,e){var r={data:{}};r.gl=t;for(var i=Object.keys(e),n=0;n<i.length;n++){var o=i[n],s=o.split("."),a=s[s.length-1],u=d(s,r),h=e[o];u.data[a]=h,u.gl=t,Object.defineProperty(u,a,{get:l(a),set:c(a,h)})}return r}},{}],22:[function(t,e,r){e.exports={compileProgram:t("./compileProgram"),defaultValue:t("./defaultValue"),extractAttributes:t("./extractAttributes"),extractUniforms:t("./extractUniforms"),generateUniformAccessObject:t("./generateUniformAccessObject"),setPrecision:t("./setPrecision"),mapSize:t("./mapSize"),mapType:t("./mapType")}},{"./compileProgram":17,"./defaultValue":18,"./extractAttributes":19,"./extractUniforms":20,"./generateUniformAccessObject":21,"./mapSize":23,"./mapType":24,"./setPrecision":25}],23:[function(t,e,r){var i={float:1,vec2:2,vec3:3,vec4:4,int:1,ivec2:2,ivec3:3,ivec4:4,bool:1,bvec2:2,bvec3:3,bvec4:4,mat2:4,mat3:9,mat4:16,sampler2D:1};e.exports=function(t){return i[t]}},{}],24:[function(t,e,r){var o=null,s={FLOAT:"float",FLOAT_VEC2:"vec2",FLOAT_VEC3:"vec3",FLOAT_VEC4:"vec4",INT:"int",INT_VEC2:"ivec2",INT_VEC3:"ivec3",INT_VEC4:"ivec4",BOOL:"bool",BOOL_VEC2:"bvec2",BOOL_VEC3:"bvec3",BOOL_VEC4:"bvec4",FLOAT_MAT2:"mat2",FLOAT_MAT3:"mat3",FLOAT_MAT4:"mat4",SAMPLER_2D:"sampler2D"};e.exports=function(t,e){if(!o){var r=Object.keys(s);o={};for(var i=0;i<r.length;++i){var n=r[i];o[t[n]]=s[n]}}return o[e]}},{}],25:[function(t,e,r){e.exports=function(t,e){return"precision"!==t.substring(0,9)?"precision "+e+" float;\n"+t:t}},{}],26:[function(t,e,r){var i,n,o=e.exports={};function s(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function u(e){if(i===setTimeout)return setTimeout(e,0);if((i===s||!i)&&setTimeout)return i=setTimeout,setTimeout(e,0);try{return i(e,0)}catch(t){try{return i.call(null,e,0)}catch(t){return i.call(this,e,0)}}}!function(){try{i="function"==typeof setTimeout?setTimeout:s}catch(t){i=s}try{n="function"==typeof clearTimeout?clearTimeout:a}catch(t){n=a}}();var h,l=[],c=!1,d=-1;function f(){c&&h&&(c=!1,h.length?l=h.concat(l):d=-1,l.length&&p())}function p(){if(!c){var t=u(f);c=!0;for(var e=l.length;e;){for(h=l,l=[];++d<e;)h&&h[d].run();d=-1,e=l.length}h=null,c=!1,function(e){if(n===clearTimeout)return clearTimeout(e);if((n===a||!n)&&clearTimeout)return n=clearTimeout,clearTimeout(e);try{n(e)}catch(t){try{return n.call(null,e)}catch(t){return n.call(this,e)}}}(t)}}function v(t,e){this.fun=t,this.array=e}function g(){}o.nextTick=function(t){var e=new Array(arguments.length-1);if(1<arguments.length)for(var r=1;r<arguments.length;r++)e[r-1]=arguments[r];l.push(new v(t,e)),1!==l.length||c||u(p)},v.prototype.run=function(){this.fun.apply(null,this.array)},o.title="browser",o.browser=!0,o.env={},o.argv=[],o.version="",o.versions={},o.on=g,o.addListener=g,o.once=g,o.off=g,o.removeListener=g,o.removeAllListeners=g,o.emit=g,o.prependListener=g,o.prependOnceListener=g,o.listeners=function(t){return[]},o.binding=function(t){throw new Error("process.binding is not supported")},o.cwd=function(){return"/"},o.chdir=function(t){throw new Error("process.chdir is not supported")},o.umask=function(){return 0}},{}],27:[function(t,I,D){(function(A){!function(t){var e="object"==typeof D&&D&&!D.nodeType&&D,r="object"==typeof I&&I&&!I.nodeType&&I,i="object"==typeof A&&A;i.global!==i&&i.window!==i&&i.self!==i||(t=i);var n,o,y=2147483647,m=36,_=1,x=26,s=38,a=700,b=72,T=128,w="-",u=/^xn--/,h=/[^\x20-\x7E]/,l=/[\x2E\u3002\uFF0E\uFF61]/g,c={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},d=m-_,E=Math.floor,S=String.fromCharCode;function O(t){throw new RangeError(c[t])}function f(t,e){for(var r=t.length,i=[];r--;)i[r]=e(t[r]);return i}function p(t,e){var r=t.split("@"),i="";return 1<r.length&&(i=r[0]+"@",t=r[1]),i+f((t=t.replace(l,".")).split("."),e).join(".")}function M(t){for(var e,r,i=[],n=0,o=t.length;n<o;)55296<=(e=t.charCodeAt(n++))&&e<=56319&&n<o?56320==(64512&(r=t.charCodeAt(n++)))?i.push(((1023&e)<<10)+(1023&r)+65536):(i.push(e),n--):i.push(e);return i}function P(t){return f(t,function(t){var e="";return 65535<t&&(e+=S((t-=65536)>>>10&1023|55296),t=56320|1023&t),e+=S(t)}).join("")}function C(t,e){return t+22+75*(t<26)-((0!=e)<<5)}function R(t,e,r){var i=0;for(t=r?E(t/a):t>>1,t+=E(t/e);d*x>>1<t;i+=m)t=E(t/d);return E(i+(d+1)*t/(t+s))}function v(t){var e,r,i,n,o,s,a,u,h,l,c,d=[],f=t.length,p=0,v=T,g=b;for((r=t.lastIndexOf(w))<0&&(r=0),i=0;i<r;++i)128<=t.charCodeAt(i)&&O("not-basic"),d.push(t.charCodeAt(i));for(n=0<r?r+1:0;n<f;){for(o=p,s=1,a=m;f<=n&&O("invalid-input"),c=t.charCodeAt(n++),(m<=(u=c-48<10?c-22:c-65<26?c-65:c-97<26?c-97:m)||u>E((y-p)/s))&&O("overflow"),p+=u*s,!(u<(h=a<=g?_:g+x<=a?x:a-g));a+=m)s>E(y/(l=m-h))&&O("overflow"),s*=l;g=R(p-o,e=d.length+1,0==o),E(p/e)>y-v&&O("overflow"),v+=E(p/e),p%=e,d.splice(p++,0,v)}return P(d)}function g(t){var e,r,i,n,o,s,a,u,h,l,c,d,f,p,v,g=[];for(d=(t=M(t)).length,e=T,o=b,s=r=0;s<d;++s)(c=t[s])<128&&g.push(S(c));for(i=n=g.length,n&&g.push(w);i<d;){for(a=y,s=0;s<d;++s)e<=(c=t[s])&&c<a&&(a=c);for(a-e>E((y-r)/(f=i+1))&&O("overflow"),r+=(a-e)*f,e=a,s=0;s<d;++s)if((c=t[s])<e&&++r>y&&O("overflow"),c==e){for(u=r,h=m;!(u<(l=h<=o?_:o+x<=h?x:h-o));h+=m)v=u-l,p=m-l,g.push(S(C(l+v%p,0))),u=E(v/p);g.push(S(C(u,0))),o=R(r,f,i==n),r=0,++i}++r,++e}return g.join("")}if(n={version:"1.4.1",ucs2:{decode:M,encode:P},decode:v,encode:g,toASCII:function(t){return p(t,function(t){return h.test(t)?"xn--"+g(t):t})},toUnicode:function(t){return p(t,function(t){return u.test(t)?v(t.slice(4).toLowerCase()):t})}},0,e&&r)if(I.exports==e)r.exports=n;else for(o in n)n.hasOwnProperty(o)&&(e[o]=n[o]);else t.punycode=n}(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],28:[function(t,e,r){"use strict";e.exports=function(t,e,r,i){e=e||"&",r=r||"=";var n={};if("string"!=typeof t||0===t.length)return n;var o=/\+/g;t=t.split(e);var s=1e3;i&&"number"==typeof i.maxKeys&&(s=i.maxKeys);var a,u,h=t.length;0<s&&s<h&&(h=s);for(var l=0;l<h;++l){var c,d,f,p,v=t[l].replace(o,"%20"),g=v.indexOf(r);d=0<=g?(c=v.substr(0,g),v.substr(g+1)):(c=v,""),f=decodeURIComponent(c),p=decodeURIComponent(d),a=n,u=f,Object.prototype.hasOwnProperty.call(a,u)?y(n[f])?n[f].push(p):n[f]=[n[f],p]:n[f]=p}return n};var y=Array.isArray||function(t){return"[object Array]"===Object.prototype.toString.call(t)}},{}],29:[function(t,e,r){"use strict";function o(t){switch(typeof t){case"string":return t;case"boolean":return t?"true":"false";case"number":return isFinite(t)?t:"";default:return""}}e.exports=function(r,i,n,t){return i=i||"&",n=n||"=",null===r&&(r=void 0),"object"==typeof r?a(u(r),function(t){var e=encodeURIComponent(o(t))+n;return s(r[t])?a(r[t],function(t){return e+encodeURIComponent(o(t))}).join(i):e+encodeURIComponent(o(r[t]))}).join(i):t?encodeURIComponent(o(t))+n+encodeURIComponent(o(r)):""};var s=Array.isArray||function(t){return"[object Array]"===Object.prototype.toString.call(t)};function a(t,e){if(t.map)return t.map(e);for(var r=[],i=0;i<t.length;i++)r.push(e(t[i],i));return r}var u=Object.keys||function(t){var e=[];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.push(r);return e}},{}],30:[function(t,e,r){"use strict";r.decode=r.parse=t("./decode"),r.encode=r.stringify=t("./encode")},{"./decode":28,"./encode":29}],31:[function(t,e,r){"use strict";e.exports=function(t,e,r){var i,n=t.length;if(!(n<=e||0===r)){var o=n-(r=n<e+r?n-e:r);for(i=e;i<o;++i)t[i]=t[i+r];t.length=o}}},{}],32:[function(t,e,r){"use strict";r.__esModule=!0,r.Loader=void 0;var l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o=u(t("mini-signals")),s=u(t("parse-uri")),a=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("./async")),c=t("./Resource");function u(t){return t&&t.__esModule?t:{default:t}}var h=/(#[\w-]+)?$/,d=r.Loader=(f.prototype.add=function(t,e,r,i){if(Array.isArray(t)){for(var n=0;n<t.length;++n)this.add(t[n]);return this}if("object"===(void 0===t?"undefined":l(t))&&(i=e||t.callback||t.onComplete,e=(r=t).url,t=t.name||t.key||t.url),"string"!=typeof e&&(i=r,r=e,e=t),"string"!=typeof e)throw new Error("No url passed to add resource to loader.");if("function"==typeof r&&(i=r,r=null),this.loading&&(!r||!r.parentResource))throw new Error("Cannot add resources while the loader is running.");if(this.resources[t])throw new Error('Resource named "'+t+'" already exists.');if(e=this._prepareUrl(e),this.resources[t]=new c.Resource(t,e,r),"function"==typeof i&&this.resources[t].onAfterMiddleware.once(i),this.loading){for(var o=r.parentResource,s=[],a=0;a<o.children.length;++a)o.children[a].isComplete||s.push(o.children[a]);var u=o.progressChunk*(s.length+1)/(s.length+2);o.children.push(this.resources[t]),o.progressChunk=u;for(var h=0;h<s.length;++h)s[h].progressChunk=u;this.resources[t].progressChunk=u}return this._queue.push(this.resources[t]),this},f.prototype.pre=function(t){return this._beforeMiddleware.push(t),this},f.prototype.use=function(t){return this._afterMiddleware.push(t),this},f.prototype.reset=function(){for(var t in this.progress=0,this.loading=!1,this._queue.kill(),this._queue.pause(),this.resources){var e=this.resources[t];e._onLoadBinding&&e._onLoadBinding.detach(),e.isLoading&&e.abort()}return this.resources={},this},f.prototype.load=function(t){if("function"==typeof t&&this.onComplete.once(t),this.loading)return this;if(this._queue.idle())this._onStart(),this._onComplete();else{for(var e=100/this._queue._tasks.length,r=0;r<this._queue._tasks.length;++r)this._queue._tasks[r].data.progressChunk=e;this._onStart(),this._queue.resume()}return this},f.prototype._prepareUrl=function(t){var e=(0,s.default)(t,{strictMode:!0}),r=void 0;if(r=e.protocol||!e.path||0===t.indexOf("//")?t:this.baseUrl.length&&this.baseUrl.lastIndexOf("/")!==this.baseUrl.length-1&&"/"!==t.charAt(0)?this.baseUrl+"/"+t:this.baseUrl+t,this.defaultQueryString){var i=h.exec(r)[0];-1!==(r=r.substr(0,r.length-i.length)).indexOf("?")?r+="&"+this.defaultQueryString:r+="?"+this.defaultQueryString,r+=i}return r},f.prototype._loadResource=function(r,t){var i=this;r._dequeue=t,a.eachSeries(this._beforeMiddleware,function(t,e){t.call(i,r,function(){e(r.isComplete?{}:null)})},function(){r.isComplete?i._onLoad(r):(r._onLoadBinding=r.onComplete.once(i._onLoad,i),r.load())},!0)},f.prototype._onStart=function(){this.progress=0,this.loading=!0,this.onStart.dispatch(this)},f.prototype._onComplete=function(){this.progress=100,this.loading=!1,this.onComplete.dispatch(this,this.resources)},f.prototype._onLoad=function(r){var i=this;r._onLoadBinding=null,this._resourcesParsing.push(r),r._dequeue(),a.eachSeries(this._afterMiddleware,function(t,e){t.call(i,r,e)},function(){r.onAfterMiddleware.dispatch(r),i.progress=Math.min(100,i.progress+r.progressChunk),i.onProgress.dispatch(i,r),r.error?i.onError.dispatch(r.error,i,r):i.onLoad.dispatch(i,r),i._resourcesParsing.splice(i._resourcesParsing.indexOf(r),1),i._queue.idle()&&0===i._resourcesParsing.length&&i._onComplete()},!0)},i(f,[{key:"concurrency",get:function(){return this._queue.concurrency},set:function(t){this._queue.concurrency=t}}]),f);function f(){var r=this,t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:"",e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:10;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,f),this.baseUrl=t,this.progress=0,this.loading=!1,this.defaultQueryString="",this._beforeMiddleware=[],this._afterMiddleware=[],this._resourcesParsing=[],this._boundLoadResource=function(t,e){return r._loadResource(t,e)},this._queue=a.queue(this._boundLoadResource,e),this._queue.pause(),this.resources={},this.onProgress=new o.default,this.onError=new o.default,this.onLoad=new o.default,this.onStart=new o.default,this.onComplete=new o.default;for(var i=0;i<f._defaultBeforeMiddleware.length;++i)this.pre(f._defaultBeforeMiddleware[i]);for(var n=0;n<f._defaultAfterMiddleware.length;++n)this.use(f._defaultAfterMiddleware[n])}d._defaultBeforeMiddleware=[],d._defaultAfterMiddleware=[],d.pre=function(t){return d._defaultBeforeMiddleware.push(t),d},d.use=function(t){return d._defaultAfterMiddleware.push(t),d}},{"./Resource":33,"./async":34,"mini-signals":5,"parse-uri":7}],33:[function(t,e,r){"use strict";r.__esModule=!0,r.Resource=void 0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o=a(t("parse-uri")),s=a(t("mini-signals"));function a(t){return t&&t.__esModule?t:{default:t}}var u=!(!window.XDomainRequest||"withCredentials"in new XMLHttpRequest),h=null;function l(){}var c=r.Resource=(d.setExtensionLoadType=function(t,e){f(d._loadTypeMap,t,e)},d.setExtensionXhrType=function(t,e){f(d._xhrTypeMap,t,e)},d.prototype.complete=function(){this._clearEvents(),this._finish()},d.prototype.abort=function(t){if(!this.error){if(this.error=new Error(t),this._clearEvents(),this.xhr)this.xhr.abort();else if(this.xdr)this.xdr.abort();else if(this.data)if(this.data.src)this.data.src=d.EMPTY_GIF;else for(;this.data.firstChild;)this.data.removeChild(this.data.firstChild);this._finish()}},d.prototype.load=function(t){var e=this;if(!this.isLoading)if(this.isComplete)t&&setTimeout(function(){return t(e)},1);else switch(t&&this.onComplete.once(t),this._setFlag(d.STATUS_FLAGS.LOADING,!0),this.onStart.dispatch(this),!1!==this.crossOrigin&&"string"==typeof this.crossOrigin||(this.crossOrigin=this._determineCrossOrigin(this.url)),this.loadType){case d.LOAD_TYPE.IMAGE:this.type=d.TYPE.IMAGE,this._loadElement("image");break;case d.LOAD_TYPE.AUDIO:this.type=d.TYPE.AUDIO,this._loadSourceElement("audio");break;case d.LOAD_TYPE.VIDEO:this.type=d.TYPE.VIDEO,this._loadSourceElement("video");break;case d.LOAD_TYPE.XHR:default:u&&this.crossOrigin?this._loadXdr():this._loadXhr()}},d.prototype._hasFlag=function(t){return 0!=(this._flags&t)},d.prototype._setFlag=function(t,e){this._flags=e?this._flags|t:this._flags&~t},d.prototype._clearEvents=function(){clearTimeout(this._elementTimer),this.data&&this.data.removeEventListener&&(this.data.removeEventListener("error",this._boundOnError,!1),this.data.removeEventListener("load",this._boundComplete,!1),this.data.removeEventListener("progress",this._boundOnProgress,!1),this.data.removeEventListener("canplaythrough",this._boundComplete,!1)),this.xhr&&(this.xhr.removeEventListener?(this.xhr.removeEventListener("error",this._boundXhrOnError,!1),this.xhr.removeEventListener("timeout",this._boundXhrOnTimeout,!1),this.xhr.removeEventListener("abort",this._boundXhrOnAbort,!1),this.xhr.removeEventListener("progress",this._boundOnProgress,!1),this.xhr.removeEventListener("load",this._boundXhrOnLoad,!1)):(this.xhr.onerror=null,this.xhr.ontimeout=null,this.xhr.onprogress=null,this.xhr.onload=null))},d.prototype._finish=function(){if(this.isComplete)throw new Error("Complete called again for an already completed resource.");this._setFlag(d.STATUS_FLAGS.COMPLETE,!0),this._setFlag(d.STATUS_FLAGS.LOADING,!1),this.onComplete.dispatch(this)},d.prototype._loadElement=function(t){this.metadata.loadElement?this.data=this.metadata.loadElement:"image"===t&&void 0!==window.Image?this.data=new Image:this.data=document.createElement(t),this.crossOrigin&&(this.data.crossOrigin=this.crossOrigin),this.metadata.skipSource||(this.data.src=this.url),this.data.addEventListener("error",this._boundOnError,!1),this.data.addEventListener("load",this._boundComplete,!1),this.data.addEventListener("progress",this._boundOnProgress,!1),this.timeout&&(this._elementTimer=setTimeout(this._boundOnTimeout,this.timeout))},d.prototype._loadSourceElement=function(t){if(this.metadata.loadElement?this.data=this.metadata.loadElement:"audio"===t&&void 0!==window.Audio?this.data=new Audio:this.data=document.createElement(t),null!==this.data){if(this.crossOrigin&&(this.data.crossOrigin=this.crossOrigin),!this.metadata.skipSource)if(navigator.isCocoonJS)this.data.src=Array.isArray(this.url)?this.url[0]:this.url;else if(Array.isArray(this.url))for(var e=this.metadata.mimeType,r=0;r<this.url.length;++r)this.data.appendChild(this._createSource(t,this.url[r],Array.isArray(e)?e[r]:e));else{var i=this.metadata.mimeType;this.data.appendChild(this._createSource(t,this.url,Array.isArray(i)?i[0]:i))}this.data.addEventListener("error",this._boundOnError,!1),this.data.addEventListener("load",this._boundComplete,!1),this.data.addEventListener("progress",this._boundOnProgress,!1),this.data.addEventListener("canplaythrough",this._boundComplete,!1),this.data.load(),this.timeout&&(this._elementTimer=setTimeout(this._boundOnTimeout,this.timeout))}else this.abort("Unsupported element: "+t)},d.prototype._loadXhr=function(){"string"!=typeof this.xhrType&&(this.xhrType=this._determineXhrType());var t=this.xhr=new XMLHttpRequest;t.open("GET",this.url,!0),t.timeout=this.timeout,this.xhrType===d.XHR_RESPONSE_TYPE.JSON||this.xhrType===d.XHR_RESPONSE_TYPE.DOCUMENT?t.responseType=d.XHR_RESPONSE_TYPE.TEXT:t.responseType=this.xhrType,t.addEventListener("error",this._boundXhrOnError,!1),t.addEventListener("timeout",this._boundXhrOnTimeout,!1),t.addEventListener("abort",this._boundXhrOnAbort,!1),t.addEventListener("progress",this._boundOnProgress,!1),t.addEventListener("load",this._boundXhrOnLoad,!1),t.send()},d.prototype._loadXdr=function(){"string"!=typeof this.xhrType&&(this.xhrType=this._determineXhrType());var t=this.xhr=new XDomainRequest;t.timeout=this.timeout||5e3,t.onerror=this._boundXhrOnError,t.ontimeout=this._boundXhrOnTimeout,t.onprogress=this._boundOnProgress,t.onload=this._boundXhrOnLoad,t.open("GET",this.url,!0),setTimeout(function(){return t.send()},1)},d.prototype._createSource=function(t,e,r){r=r||t+"/"+this._getExtension(e);var i=document.createElement("source");return i.src=e,i.type=r,i},d.prototype._onError=function(t){this.abort("Failed to load element using: "+t.target.nodeName)},d.prototype._onProgress=function(t){t&&t.lengthComputable&&this.onProgress.dispatch(this,t.loaded/t.total)},d.prototype._onTimeout=function(){this.abort("Load timed out.")},d.prototype._xhrOnError=function(){var t=this.xhr;this.abort(p(t)+" Request failed. Status: "+t.status+', text: "'+t.statusText+'"')},d.prototype._xhrOnTimeout=function(){var t=this.xhr;this.abort(p(t)+" Request timed out.")},d.prototype._xhrOnAbort=function(){var t=this.xhr;this.abort(p(t)+" Request was aborted by the user.")},d.prototype._xhrOnLoad=function(){var t=this.xhr,e="",r=void 0===t.status?200:t.status;if(""!==t.responseType&&"text"!==t.responseType&&void 0!==t.responseType||(e=t.responseText),0===r&&(0<e.length||t.responseType===d.XHR_RESPONSE_TYPE.BUFFER)?r=200:1223===r&&(r=204),2==(r/100|0)){if(this.xhrType===d.XHR_RESPONSE_TYPE.TEXT)this.data=e,this.type=d.TYPE.TEXT;else if(this.xhrType===d.XHR_RESPONSE_TYPE.JSON)try{this.data=JSON.parse(e),this.type=d.TYPE.JSON}catch(t){return void this.abort("Error trying to parse loaded json: "+t)}else if(this.xhrType===d.XHR_RESPONSE_TYPE.DOCUMENT)try{if(window.DOMParser){var i=new DOMParser;this.data=i.parseFromString(e,"text/xml")}else{var n=document.createElement("div");n.innerHTML=e,this.data=n}this.type=d.TYPE.XML}catch(t){return void this.abort("Error trying to parse loaded xml: "+t)}else this.data=t.response||e;this.complete()}else this.abort("["+t.status+"] "+t.statusText+": "+t.responseURL)},d.prototype._determineCrossOrigin=function(t,e){if(0===t.indexOf("data:"))return"";if(window.origin!==window.location.origin)return"anonymous";e=e||window.location,(h=h||document.createElement("a")).href=t;var r=!(t=(0,o.default)(h.href,{strictMode:!0})).port&&""===e.port||t.port===e.port,i=t.protocol?t.protocol+":":"";return t.host===e.hostname&&r&&i===e.protocol?"":"anonymous"},d.prototype._determineXhrType=function(){return d._xhrTypeMap[this.extension]||d.XHR_RESPONSE_TYPE.TEXT},d.prototype._determineLoadType=function(){return d._loadTypeMap[this.extension]||d.LOAD_TYPE.XHR},d.prototype._getExtension=function(){var t=this.url,e="";if(this.isDataUrl){var r=t.indexOf("/");e=t.substring(r+1,t.indexOf(";",r))}else{var i=t.indexOf("?"),n=t.indexOf("#"),o=Math.min(-1<i?i:t.length,-1<n?n:t.length);e=(t=t.substring(0,o)).substring(t.lastIndexOf(".")+1)}return e.toLowerCase()},d.prototype._getMimeFromXhrType=function(t){switch(t){case d.XHR_RESPONSE_TYPE.BUFFER:return"application/octet-binary";case d.XHR_RESPONSE_TYPE.BLOB:return"application/blob";case d.XHR_RESPONSE_TYPE.DOCUMENT:return"application/xml";case d.XHR_RESPONSE_TYPE.JSON:return"application/json";case d.XHR_RESPONSE_TYPE.DEFAULT:case d.XHR_RESPONSE_TYPE.TEXT:default:return"text/plain"}},i(d,[{key:"isDataUrl",get:function(){return this._hasFlag(d.STATUS_FLAGS.DATA_URL)}},{key:"isComplete",get:function(){return this._hasFlag(d.STATUS_FLAGS.COMPLETE)}},{key:"isLoading",get:function(){return this._hasFlag(d.STATUS_FLAGS.LOADING)}}]),d);function d(t,e,r){if(!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,d),"string"!=typeof t||"string"!=typeof e)throw new Error("Both name and url are required for constructing a resource.");r=r||{},this._flags=0,this._setFlag(d.STATUS_FLAGS.DATA_URL,0===e.indexOf("data:")),this.name=t,this.url=e,this.extension=this._getExtension(),this.data=null,this.crossOrigin=!0===r.crossOrigin?"anonymous":r.crossOrigin,this.timeout=r.timeout||0,this.loadType=r.loadType||this._determineLoadType(),this.xhrType=r.xhrType,this.metadata=r.metadata||{},this.error=null,this.xhr=null,this.children=[],this.type=d.TYPE.UNKNOWN,this.progressChunk=0,this._dequeue=l,this._onLoadBinding=null,this._elementTimer=0,this._boundComplete=this.complete.bind(this),this._boundOnError=this._onError.bind(this),this._boundOnProgress=this._onProgress.bind(this),this._boundOnTimeout=this._onTimeout.bind(this),this._boundXhrOnError=this._xhrOnError.bind(this),this._boundXhrOnTimeout=this._xhrOnTimeout.bind(this),this._boundXhrOnAbort=this._xhrOnAbort.bind(this),this._boundXhrOnLoad=this._xhrOnLoad.bind(this),this.onStart=new s.default,this.onProgress=new s.default,this.onComplete=new s.default,this.onAfterMiddleware=new s.default}function f(t,e,r){e&&0===e.indexOf(".")&&(e=e.substring(1)),e&&(t[e]=r)}function p(t){return t.toString().replace("object ","")}c.STATUS_FLAGS={NONE:0,DATA_URL:1,COMPLETE:2,LOADING:4},c.TYPE={UNKNOWN:0,JSON:1,XML:2,IMAGE:3,AUDIO:4,VIDEO:5,TEXT:6},c.LOAD_TYPE={XHR:1,IMAGE:2,AUDIO:3,VIDEO:4},c.XHR_RESPONSE_TYPE={DEFAULT:"text",BUFFER:"arraybuffer",BLOB:"blob",DOCUMENT:"document",JSON:"json",TEXT:"text"},c._loadTypeMap={gif:c.LOAD_TYPE.IMAGE,png:c.LOAD_TYPE.IMAGE,bmp:c.LOAD_TYPE.IMAGE,jpg:c.LOAD_TYPE.IMAGE,jpeg:c.LOAD_TYPE.IMAGE,tif:c.LOAD_TYPE.IMAGE,tiff:c.LOAD_TYPE.IMAGE,webp:c.LOAD_TYPE.IMAGE,tga:c.LOAD_TYPE.IMAGE,svg:c.LOAD_TYPE.IMAGE,"svg+xml":c.LOAD_TYPE.IMAGE,mp3:c.LOAD_TYPE.AUDIO,ogg:c.LOAD_TYPE.AUDIO,wav:c.LOAD_TYPE.AUDIO,mp4:c.LOAD_TYPE.VIDEO,webm:c.LOAD_TYPE.VIDEO},c._xhrTypeMap={xhtml:c.XHR_RESPONSE_TYPE.DOCUMENT,html:c.XHR_RESPONSE_TYPE.DOCUMENT,htm:c.XHR_RESPONSE_TYPE.DOCUMENT,xml:c.XHR_RESPONSE_TYPE.DOCUMENT,tmx:c.XHR_RESPONSE_TYPE.DOCUMENT,svg:c.XHR_RESPONSE_TYPE.DOCUMENT,tsx:c.XHR_RESPONSE_TYPE.DOCUMENT,gif:c.XHR_RESPONSE_TYPE.BLOB,png:c.XHR_RESPONSE_TYPE.BLOB,bmp:c.XHR_RESPONSE_TYPE.BLOB,jpg:c.XHR_RESPONSE_TYPE.BLOB,jpeg:c.XHR_RESPONSE_TYPE.BLOB,tif:c.XHR_RESPONSE_TYPE.BLOB,tiff:c.XHR_RESPONSE_TYPE.BLOB,webp:c.XHR_RESPONSE_TYPE.BLOB,tga:c.XHR_RESPONSE_TYPE.BLOB,json:c.XHR_RESPONSE_TYPE.JSON,text:c.XHR_RESPONSE_TYPE.TEXT,txt:c.XHR_RESPONSE_TYPE.TEXT,ttf:c.XHR_RESPONSE_TYPE.BUFFER,otf:c.XHR_RESPONSE_TYPE.BUFFER},c.EMPTY_GIF="data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACH5BAEAAAAALAAAAAABAAEAAAICRAEAOw==",void 0!==e&&(e.exports.default=c)},{"mini-signals":5,"parse-uri":7}],34:[function(t,e,r){"use strict";function s(){}function a(e){return function(){if(null===e)throw new Error("Callback was already called.");var t=e;e=null,t.apply(this,arguments)}}r.__esModule=!0,r.eachSeries=function(r,i,n,o){var s=0,a=r.length;!function t(e){e||s===a?n&&n(e):o?setTimeout(function(){i(r[s++],t)},1):i(r[s++],t)}()},r.queue=function(e,t){if(null==t)t=1;else if(0===t)throw new Error("Concurrency must not be zero");var r=0,n={_tasks:[],concurrency:t,saturated:s,unsaturated:s,buffer:t/4,empty:s,drain:s,error:s,started:!1,paused:!1,push:function(t,e){i(t,!1,e)},kill:function(){r=0,n.drain=s,n.started=!1,n._tasks=[]},unshift:function(t,e){i(t,!0,e)},process:function(){for(;!n.paused&&r<n.concurrency&&n._tasks.length;){var t=n._tasks.shift();0===n._tasks.length&&n.empty(),(r+=1)===n.concurrency&&n.saturated(),e(t.data,a(o(t)))}},length:function(){return n._tasks.length},running:function(){return r},idle:function(){return n._tasks.length+r===0},pause:function(){!0!==n.paused&&(n.paused=!0)},resume:function(){if(!1!==n.paused){n.paused=!1;for(var t=1;t<=n.concurrency;t++)n.process()}}};function i(t,e,r){if(null!=r&&"function"!=typeof r)throw new Error("task callback must be a function");if(n.started=!0,null==t&&n.idle())setTimeout(function(){return n.drain()},1);else{var i={data:t,callback:"function"==typeof r?r:s};e?n._tasks.unshift(i):n._tasks.push(i),setTimeout(function(){return n.process()},1)}}function o(e){return function(t){--r,e.callback.apply(e,arguments),null!=t&&n.error(t,e.data),r<=n.concurrency-n.buffer&&n.unsaturated(),n.idle()&&n.drain(),n.process()}}return n}},{}],35:[function(t,e,r){"use strict";r.__esModule=!0,r.encodeBinary=i;var a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";function i(t){for(var e="",r=0;r<t.length;){for(var i=[0,0,0],n=[0,0,0,0],o=0;o<i.length;++o)r<t.length?i[o]=255&t.charCodeAt(r++):i[o]=0;switch(n[0]=i[0]>>2,n[1]=(3&i[0])<<4|i[1]>>4,n[2]=(15&i[1])<<2|i[2]>>6,n[3]=63&i[2],r-(t.length-1)){case 2:n[3]=64,n[2]=64;break;case 1:n[3]=64}for(var s=0;s<n.length;++s)e+=a.charAt(n[s])}return e}void 0!==e&&(e.exports.default=i)},{}],36:[function(t,e,r){"use strict";var i=t("./Loader").Loader,n=t("./Resource").Resource,o=t("./async"),s=t("./b64");i.Resource=n,i.async=o,i.encodeBinary=s,i.base64=s,e.exports=i,e.exports.Loader=i,e.exports.default=i},{"./Loader":32,"./Resource":33,"./async":34,"./b64":35}],37:[function(t,e,r){"use strict";r.__esModule=!0,r.blobMiddlewareFactory=function(){return function(t,e){if(t.data){if(t.xhr&&t.xhrType===n.Resource.XHR_RESPONSE_TYPE.BLOB)if(window.Blob&&"string"!=typeof t.data){if(0===t.data.type.indexOf("image")){var r=s.createObjectURL(t.data);return t.blob=t.data,t.data=new Image,t.data.src=r,t.type=n.Resource.TYPE.IMAGE,void(t.data.onload=function(){s.revokeObjectURL(r),t.data.onload=null,e()})}}else{var i=t.xhr.getResponseHeader("content-type");if(i&&0===i.indexOf("image"))return t.data=new Image,t.data.src="data:"+i+";base64,"+(0,o.encodeBinary)(t.xhr.responseText),t.type=n.Resource.TYPE.IMAGE,void(t.data.onload=function(){t.data.onload=null,e()})}e()}else e()}};var n=t("../../Resource"),o=t("../../b64"),s=window.URL||window.webkitURL},{"../../Resource":33,"../../b64":35}],38:[function(t,e,r){"use strict";var D=t("punycode"),L=t("./util");function M(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}r.parse=o,r.resolve=function(t,e){return o(t,!1,!0).resolve(e)},r.resolveObject=function(t,e){return t?o(t,!1,!0).resolveObject(e):e},r.format=function(t){L.isString(t)&&(t=o(t));return t instanceof M?t.format():M.prototype.format.call(t)},r.Url=M;var N=/^([a-z0-9.+-]+:)/i,i=/:[0-9]*$/,B=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,n=["{","}","|","\\","^","`"].concat(["<",">",'"',"`"," ","\r","\n","\t"]),k=["'"].concat(n),F=["%","/","?",";","#"].concat(k),j=["/","?","#"],U=/^[+a-z0-9A-Z_-]{0,63}$/,X=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,G={javascript:!0,"javascript:":!0},W={javascript:!0,"javascript:":!0},H={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},Y=t("querystring");function o(t,e,r){if(t&&L.isObject(t)&&t instanceof M)return t;var i=new M;return i.parse(t,e,r),i}M.prototype.parse=function(t,e,r){if(!L.isString(t))throw new TypeError("Parameter 'url' must be a string, not "+typeof t);var i=t.indexOf("?"),n=-1!==i&&i<t.indexOf("#")?"?":"#",o=t.split(n);o[0]=o[0].replace(/\\/g,"/");var s=t=o.join(n);if(s=s.trim(),!r&&1===t.split("#").length){var a=B.exec(s);if(a)return this.path=s,this.href=s,this.pathname=a[1],a[2]?(this.search=a[2],this.query=e?Y.parse(this.search.substr(1)):this.search.substr(1)):e&&(this.search="",this.query={}),this}var u=N.exec(s);if(u){var h=(u=u[0]).toLowerCase();this.protocol=h,s=s.substr(u.length)}if(r||u||s.match(/^\/\/[^@\/]+@[^@\/]+/)){var l="//"===s.substr(0,2);!l||u&&W[u]||(s=s.substr(2),this.slashes=!0)}if(!W[u]&&(l||u&&!H[u])){for(var c,d,f=-1,p=0;p<j.length;p++){-1!==(v=s.indexOf(j[p]))&&(-1===f||v<f)&&(f=v)}-1!==(d=-1===f?s.lastIndexOf("@"):s.lastIndexOf("@",f))&&(c=s.slice(0,d),s=s.slice(d+1),this.auth=decodeURIComponent(c)),f=-1;for(p=0;p<F.length;p++){var v;-1!==(v=s.indexOf(F[p]))&&(-1===f||v<f)&&(f=v)}-1===f&&(f=s.length),this.host=s.slice(0,f),s=s.slice(f),this.parseHost(),this.hostname=this.hostname||"";var g="["===this.hostname[0]&&"]"===this.hostname[this.hostname.length-1];if(!g)for(var y=this.hostname.split(/\./),m=(p=0,y.length);p<m;p++){var _=y[p];if(_&&!_.match(U)){for(var x="",b=0,T=_.length;b<T;b++)127<_.charCodeAt(b)?x+="x":x+=_[b];if(!x.match(U)){var w=y.slice(0,p),E=y.slice(p+1),S=_.match(X);S&&(w.push(S[1]),E.unshift(S[2])),E.length&&(s="/"+E.join(".")+s),this.hostname=w.join(".");break}}}255<this.hostname.length?this.hostname="":this.hostname=this.hostname.toLowerCase(),g||(this.hostname=D.toASCII(this.hostname));var O=this.port?":"+this.port:"",M=this.hostname||"";this.host=M+O,this.href+=this.host,g&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),"/"!==s[0]&&(s="/"+s))}if(!G[h])for(p=0,m=k.length;p<m;p++){var P=k[p];if(-1!==s.indexOf(P)){var C=encodeURIComponent(P);C===P&&(C=escape(P)),s=s.split(P).join(C)}}var R=s.indexOf("#");-1!==R&&(this.hash=s.substr(R),s=s.slice(0,R));var A=s.indexOf("?");if(-1!==A?(this.search=s.substr(A),this.query=s.substr(A+1),e&&(this.query=Y.parse(this.query)),s=s.slice(0,A)):e&&(this.search="",this.query={}),s&&(this.pathname=s),H[h]&&this.hostname&&!this.pathname&&(this.pathname="/"),this.pathname||this.search){O=this.pathname||"";var I=this.search||"";this.path=O+I}return this.href=this.format(),this},M.prototype.format=function(){var t=this.auth||"";t&&(t=(t=encodeURIComponent(t)).replace(/%3A/i,":"),t+="@");var e=this.protocol||"",r=this.pathname||"",i=this.hash||"",n=!1,o="";this.host?n=t+this.host:this.hostname&&(n=t+(-1===this.hostname.indexOf(":")?this.hostname:"["+this.hostname+"]"),this.port&&(n+=":"+this.port)),this.query&&L.isObject(this.query)&&Object.keys(this.query).length&&(o=Y.stringify(this.query));var s=this.search||o&&"?"+o||"";return e&&":"!==e.substr(-1)&&(e+=":"),this.slashes||(!e||H[e])&&!1!==n?(n="//"+(n||""),r&&"/"!==r.charAt(0)&&(r="/"+r)):n=n||"",i&&"#"!==i.charAt(0)&&(i="#"+i),s&&"?"!==s.charAt(0)&&(s="?"+s),e+n+(r=r.replace(/[?#]/g,function(t){return encodeURIComponent(t)}))+(s=s.replace("#","%23"))+i},M.prototype.resolve=function(t){return this.resolveObject(o(t,!1,!0)).format()},M.prototype.resolveObject=function(t){if(L.isString(t)){var e=new M;e.parse(t,!1,!0),t=e}for(var r=new M,i=Object.keys(this),n=0;n<i.length;n++){var o=i[n];r[o]=this[o]}if(r.hash=t.hash,""===t.href)return r.href=r.format(),r;if(t.slashes&&!t.protocol){for(var s=Object.keys(t),a=0;a<s.length;a++){var u=s[a];"protocol"!==u&&(r[u]=t[u])}return H[r.protocol]&&r.hostname&&!r.pathname&&(r.path=r.pathname="/"),r.href=r.format(),r}if(t.protocol&&t.protocol!==r.protocol){if(!H[t.protocol]){for(var h=Object.keys(t),l=0;l<h.length;l++){var c=h[l];r[c]=t[c]}return r.href=r.format(),r}if(r.protocol=t.protocol,t.host||W[t.protocol])r.pathname=t.pathname;else{for(var d=(t.pathname||"").split("/");d.length&&!(t.host=d.shift()););t.host||(t.host=""),t.hostname||(t.hostname=""),""!==d[0]&&d.unshift(""),d.length<2&&d.unshift(""),r.pathname=d.join("/")}if(r.search=t.search,r.query=t.query,r.host=t.host||"",r.auth=t.auth,r.hostname=t.hostname||t.host,r.port=t.port,r.pathname||r.search){var f=r.pathname||"",p=r.search||"";r.path=f+p}return r.slashes=r.slashes||t.slashes,r.href=r.format(),r}var v=r.pathname&&"/"===r.pathname.charAt(0),g=t.host||t.pathname&&"/"===t.pathname.charAt(0),y=g||v||r.host&&t.pathname,m=y,_=r.pathname&&r.pathname.split("/")||[],x=(d=t.pathname&&t.pathname.split("/")||[],r.protocol&&!H[r.protocol]);if(x&&(r.hostname="",r.port=null,r.host&&(""===_[0]?_[0]=r.host:_.unshift(r.host)),r.host="",t.protocol&&(t.hostname=null,t.port=null,t.host&&(""===d[0]?d[0]=t.host:d.unshift(t.host)),t.host=null),y=y&&(""===d[0]||""===_[0])),g)r.host=t.host||""===t.host?t.host:r.host,r.hostname=t.hostname||""===t.hostname?t.hostname:r.hostname,r.search=t.search,r.query=t.query,_=d;else if(d.length)(_=_||[]).pop(),_=_.concat(d),r.search=t.search,r.query=t.query;else if(!L.isNullOrUndefined(t.search)){if(x)r.hostname=r.host=_.shift(),(S=!!(r.host&&0<r.host.indexOf("@"))&&r.host.split("@"))&&(r.auth=S.shift(),r.host=r.hostname=S.shift());return r.search=t.search,r.query=t.query,L.isNull(r.pathname)&&L.isNull(r.search)||(r.path=(r.pathname?r.pathname:"")+(r.search?r.search:"")),r.href=r.format(),r}if(!_.length)return r.pathname=null,r.search?r.path="/"+r.search:r.path=null,r.href=r.format(),r;for(var b=_.slice(-1)[0],T=(r.host||t.host||1<_.length)&&("."===b||".."===b)||""===b,w=0,E=_.length;0<=E;E--)"."===(b=_[E])?_.splice(E,1):".."===b?(_.splice(E,1),w++):w&&(_.splice(E,1),w--);if(!y&&!m)for(;w--;)_.unshift("..");!y||""===_[0]||_[0]&&"/"===_[0].charAt(0)||_.unshift(""),T&&"/"!==_.join("/").substr(-1)&&_.push("");var S,O=""===_[0]||_[0]&&"/"===_[0].charAt(0);x&&(r.hostname=r.host=O?"":_.length?_.shift():"",(S=!!(r.host&&0<r.host.indexOf("@"))&&r.host.split("@"))&&(r.auth=S.shift(),r.host=r.hostname=S.shift()));return(y=y||r.host&&_.length)&&!O&&_.unshift(""),_.length?r.pathname=_.join("/"):(r.pathname=null,r.path=null),L.isNull(r.pathname)&&L.isNull(r.search)||(r.path=(r.pathname?r.pathname:"")+(r.search?r.search:"")),r.auth=t.auth||r.auth,r.slashes=r.slashes||t.slashes,r.href=r.format(),r},M.prototype.parseHost=function(){var t=this.host,e=i.exec(t);e&&(":"!==(e=e[0])&&(this.port=e.substr(1)),t=t.substr(0,t.length-e.length)),t&&(this.hostname=t)}},{"./util":39,punycode:27,querystring:30}],39:[function(t,e,r){"use strict";e.exports={isString:function(t){return"string"==typeof t},isObject:function(t){return"object"==typeof t&&null!==t},isNull:function(t){return null===t},isNullOrUndefined:function(t){return null==t}}},{}],40:[function(t,e,r){"use strict";r.__esModule=!0;var u=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../core")),i=o(t("ismobilejs")),n=o(t("./accessibleTarget"));function o(t){return t&&t.__esModule?t:{default:t}}u.utils.mixins.delayMixin(u.DisplayObject.prototype,n.default);var s=(a.prototype.createTouchHook=function(){var t=this,e=document.createElement("button");e.style.width="1px",e.style.height="1px",e.style.position="absolute",e.style.top="-1000px",e.style.left="-1000px",e.style.zIndex=2,e.style.backgroundColor="#FF0000",e.title="HOOK DIV",e.addEventListener("focus",function(){t.isMobileAccessabillity=!0,t.activate(),document.body.removeChild(e)}),document.body.appendChild(e)},a.prototype.activate=function(){this.isActive||(this.isActive=!0,window.document.addEventListener("mousemove",this._onMouseMove,!0),window.removeEventListener("keydown",this._onKeyDown,!1),this.renderer.on("postrender",this.update,this),this.renderer.view.parentNode&&this.renderer.view.parentNode.appendChild(this.div))},a.prototype.deactivate=function(){this.isActive&&!this.isMobileAccessabillity&&(this.isActive=!1,window.document.removeEventListener("mousemove",this._onMouseMove,!0),window.addEventListener("keydown",this._onKeyDown,!1),this.renderer.off("postrender",this.update),this.div.parentNode&&this.div.parentNode.removeChild(this.div))},a.prototype.updateAccessibleObjects=function(t){if(t.visible){t.accessible&&t.interactive&&(t._accessibleActive||this.addChild(t),t.renderId=this.renderId);for(var e=t.children,r=0;r<e.length;r++)this.updateAccessibleObjects(e[r])}},a.prototype.update=function(){if(this.renderer.renderingToScreen){this.updateAccessibleObjects(this.renderer._lastObjectRendered);var t=this.renderer.view.getBoundingClientRect(),e=t.width/this.renderer.width,r=t.height/this.renderer.height,i=this.div;i.style.left=t.left+"px",i.style.top=t.top+"px",i.style.width=this.renderer.width+"px",i.style.height=this.renderer.height+"px";for(var n=0;n<this.children.length;n++){var o=this.children[n];if(o.renderId!==this.renderId)o._accessibleActive=!1,u.utils.removeItems(this.children,n,1),this.div.removeChild(o._accessibleDiv),this.pool.push(o._accessibleDiv),o._accessibleDiv=null,n--,0===this.children.length&&this.deactivate();else{i=o._accessibleDiv;var s=o.hitArea,a=o.worldTransform;o.hitArea?(i.style.left=(a.tx+s.x*a.a)*e+"px",i.style.top=(a.ty+s.y*a.d)*r+"px",i.style.width=s.width*a.a*e+"px",i.style.height=s.height*a.d*r+"px"):(s=o.getBounds(),this.capHitArea(s),i.style.left=s.x*e+"px",i.style.top=s.y*r+"px",i.style.width=s.width*e+"px",i.style.height=s.height*r+"px",i.title!==o.accessibleTitle&&null!==o.accessibleTitle&&(i.title=o.accessibleTitle),i.getAttribute("aria-label")!==o.accessibleHint&&null!==o.accessibleHint&&i.setAttribute("aria-label",o.accessibleHint))}}this.renderId++}},a.prototype.capHitArea=function(t){t.x<0&&(t.width+=t.x,t.x=0),t.y<0&&(t.height+=t.y,t.y=0),t.x+t.width>this.renderer.width&&(t.width=this.renderer.width-t.x),t.y+t.height>this.renderer.height&&(t.height=this.renderer.height-t.y)},a.prototype.addChild=function(t){var e=this.pool.pop();e||((e=document.createElement("button")).style.width="100px",e.style.height="100px",e.style.backgroundColor=this.debug?"rgba(255,0,0,0.5)":"transparent",e.style.position="absolute",e.style.zIndex=2,e.style.borderStyle="none",-1<navigator.userAgent.toLowerCase().indexOf("chrome")?e.setAttribute("aria-live","off"):e.setAttribute("aria-live","polite"),navigator.userAgent.match(/rv:.*Gecko\//)?e.setAttribute("aria-relevant","additions"):e.setAttribute("aria-relevant","text"),e.addEventListener("click",this._onClick.bind(this)),e.addEventListener("focus",this._onFocus.bind(this)),e.addEventListener("focusout",this._onFocusOut.bind(this))),t.accessibleTitle&&null!==t.accessibleTitle?e.title=t.accessibleTitle:t.accessibleHint&&null!==t.accessibleHint||(e.title="displayObject "+t.tabIndex),t.accessibleHint&&null!==t.accessibleHint&&e.setAttribute("aria-label",t.accessibleHint),t._accessibleActive=!0,(t._accessibleDiv=e).displayObject=t,this.children.push(t),this.div.appendChild(t._accessibleDiv),t._accessibleDiv.tabIndex=t.tabIndex},a.prototype._onClick=function(t){var e=this.renderer.plugins.interaction;e.dispatchEvent(t.target.displayObject,"click",e.eventData)},a.prototype._onFocus=function(t){t.target.getAttribute("aria-live","off")||t.target.setAttribute("aria-live","assertive");var e=this.renderer.plugins.interaction;e.dispatchEvent(t.target.displayObject,"mouseover",e.eventData)},a.prototype._onFocusOut=function(t){t.target.getAttribute("aria-live","off")||t.target.setAttribute("aria-live","polite");var e=this.renderer.plugins.interaction;e.dispatchEvent(t.target.displayObject,"mouseout",e.eventData)},a.prototype._onKeyDown=function(t){9===t.keyCode&&this.activate()},a.prototype._onMouseMove=function(t){0===t.movementX&&0===t.movementY||this.deactivate()},a.prototype.destroy=function(){this.div=null;for(var t=0;t<this.children.length;t++)this.children[t].div=null;window.document.removeEventListener("mousemove",this._onMouseMove,!0),window.removeEventListener("keydown",this._onKeyDown),this.pool=null,this.children=null,this.renderer=null},a);function a(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,a),!i.default.tablet&&!i.default.phone||navigator.isCocoonJS||this.createTouchHook();var e=document.createElement("div");e.style.width="100px",e.style.height="100px",e.style.position="absolute",e.style.top="0px",e.style.left="0px",e.style.zIndex=2,this.div=e,this.pool=[],this.renderId=0,this.debug=!1,this.renderer=t,this.children=[],this._onKeyDown=this._onKeyDown.bind(this),this._onMouseMove=this._onMouseMove.bind(this),this.isActive=!1,this.isMobileAccessabillity=!1,window.addEventListener("keydown",this._onKeyDown,!1)}r.default=s,u.WebGLRenderer.registerPlugin("accessibility",s),u.CanvasRenderer.registerPlugin("accessibility",s)},{"../core":65,"./accessibleTarget":41,ismobilejs:4}],41:[function(t,e,r){"use strict";r.__esModule=!0,r.default={accessible:!1,accessibleTitle:null,accessibleHint:null,tabIndex:0,_accessibleActive:!1,_accessibleDiv:!1}},{}],42:[function(t,e,r){"use strict";r.__esModule=!0;var i=t("./accessibleTarget");Object.defineProperty(r,"accessibleTarget",{enumerable:!0,get:function(){return o(i).default}});var n=t("./AccessibilityManager");function o(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(r,"AccessibilityManager",{enumerable:!0,get:function(){return o(n).default}})},{"./AccessibilityManager":40,"./accessibleTarget":41}],43:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o=t("./autoDetectRenderer"),s=l(t("./display/Container")),a=t("./ticker"),u=l(t("./settings")),h=t("./const");function l(t){return t&&t.__esModule?t:{default:t}}var c=(d.prototype.render=function(){this.renderer.render(this.stage)},d.prototype.stop=function(){this._ticker.stop()},d.prototype.start=function(){this._ticker.start()},d.prototype.destroy=function(t,e){if(this._ticker){var r=this._ticker;this.ticker=null,r.destroy()}this.stage.destroy(e),this.stage=null,this.renderer.destroy(t),this.renderer=null,this._options=null},i(d,[{key:"ticker",set:function(t){this._ticker&&this._ticker.remove(this.render,this),(this._ticker=t)&&t.add(this.render,this,h.UPDATE_PRIORITY.LOW)},get:function(){return this._ticker}},{key:"view",get:function(){return this.renderer.view}},{key:"screen",get:function(){return this.renderer.screen}}]),d);function d(t,e,r,i,n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,d),"number"==typeof t&&(t=Object.assign({width:t,height:e||u.default.RENDER_OPTIONS.height,forceCanvas:!!i,sharedTicker:!!n},r)),this._options=t=Object.assign({autoStart:!0,sharedTicker:!1,forceCanvas:!1,sharedLoader:!1},t),this.renderer=(0,o.autoDetectRenderer)(t),this.stage=new s.default,this._ticker=null,this.ticker=t.sharedTicker?a.shared:new a.Ticker,t.autoStart&&this.start()}r.default=c},{"./autoDetectRenderer":45,"./const":46,"./display/Container":48,"./settings":101,"./ticker":121}],44:[function(t,e,r){"use strict";r.__esModule=!0;var i,n=t("pixi-gl-core"),o=t("./settings"),s=(i=o)&&i.__esModule?i:{default:i};function a(t,e){if(t instanceof Array){if("precision"!==t[0].substring(0,9)){var r=t.slice(0);return r.unshift("precision "+e+" float;"),r}}else if("precision"!==t.trim().substring(0,9))return"precision "+e+" float;\n"+t;return t}var u,h=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(l,u=n.GLShader),l);function l(t,e,r,i,n){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,u.call(this,t,a(e,n||s.default.PRECISION_VERTEX),a(r,n||s.default.PRECISION_FRAGMENT),void 0,i))}r.default=h},{"./settings":101,"pixi-gl-core":15}],45:[function(t,e,r){"use strict";r.__esModule=!0,r.autoDetectRenderer=function(t,e,r,i){var n=t&&t.forceCanvas;void 0!==i&&(n=i);return n||!o.isWebGLSupported()?new s.default(t,e,r):new a.default(t,e,r)};var o=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("./utils")),s=i(t("./renderers/canvas/CanvasRenderer")),a=i(t("./renderers/webgl/WebGLRenderer"));function i(t){return t&&t.__esModule?t:{default:t}}},{"./renderers/canvas/CanvasRenderer":77,"./renderers/webgl/WebGLRenderer":84,"./utils":125}],46:[function(t,e,r){"use strict";r.__esModule=!0;r.VERSION="4.8.9",r.PI_2=2*Math.PI,r.RAD_TO_DEG=180/Math.PI,r.DEG_TO_RAD=Math.PI/180,r.RENDERER_TYPE={UNKNOWN:0,WEBGL:1,CANVAS:2},r.BLEND_MODES={NORMAL:0,ADD:1,MULTIPLY:2,SCREEN:3,OVERLAY:4,DARKEN:5,LIGHTEN:6,COLOR_DODGE:7,COLOR_BURN:8,HARD_LIGHT:9,SOFT_LIGHT:10,DIFFERENCE:11,EXCLUSION:12,HUE:13,SATURATION:14,COLOR:15,LUMINOSITY:16,NORMAL_NPM:17,ADD_NPM:18,SCREEN_NPM:19},r.DRAW_MODES={POINTS:0,LINES:1,LINE_LOOP:2,LINE_STRIP:3,TRIANGLES:4,TRIANGLE_STRIP:5,TRIANGLE_FAN:6},r.SCALE_MODES={LINEAR:0,NEAREST:1},r.WRAP_MODES={CLAMP:0,REPEAT:1,MIRRORED_REPEAT:2},r.GC_MODES={AUTO:0,MANUAL:1},r.URL_FILE_EXTENSION=/\.(\w{3,4})(?:$|\?|#)/i,r.DATA_URI=/^\s*data:(?:([\w-]+)\/([\w+.-]+))?(?:;charset=([\w-]+))?(?:;(base64))?,(.*)/i,r.SVG_SIZE=/<svg[^>]*(?:\s(width|height)=('|")(\d*(?:\.\d+)?)(?:px)?('|"))[^>]*(?:\s(width|height)=('|")(\d*(?:\.\d+)?)(?:px)?('|"))[^>]*>/i,r.SHAPES={POLY:0,RECT:1,CIRC:2,ELIP:3,RREC:4},r.PRECISION={LOW:"lowp",MEDIUM:"mediump",HIGH:"highp"},r.TRANSFORM_MODE={STATIC:0,DYNAMIC:1},r.TEXT_GRADIENT={LINEAR_VERTICAL:0,LINEAR_HORIZONTAL:1},r.UPDATE_PRIORITY={INTERACTION:50,HIGH:25,NORMAL:0,LOW:-25,UTILITY:-50}},{}],47:[function(t,e,r){"use strict";r.__esModule=!0;var i=t("../math");var n=(o.prototype.isEmpty=function(){return this.minX>this.maxX||this.minY>this.maxY},o.prototype.clear=function(){this.updateID++,this.minX=1/0,this.minY=1/0,this.maxX=-1/0,this.maxY=-1/0},o.prototype.getRectangle=function(t){return this.minX>this.maxX||this.minY>this.maxY?i.Rectangle.EMPTY:((t=t||new i.Rectangle(0,0,1,1)).x=this.minX,t.y=this.minY,t.width=this.maxX-this.minX,t.height=this.maxY-this.minY,t)},o.prototype.addPoint=function(t){this.minX=Math.min(this.minX,t.x),this.maxX=Math.max(this.maxX,t.x),this.minY=Math.min(this.minY,t.y),this.maxY=Math.max(this.maxY,t.y)},o.prototype.addQuad=function(t){var e=this.minX,r=this.minY,i=this.maxX,n=this.maxY,o=t[0],s=t[1];e=o<e?o:e,r=s<r?s:r,i=i<o?o:i,n=n<s?s:n,e=(o=t[2])<e?o:e,r=(s=t[3])<r?s:r,i=i<o?o:i,n=n<s?s:n,e=(o=t[4])<e?o:e,r=(s=t[5])<r?s:r,i=i<o?o:i,n=n<s?s:n,e=(o=t[6])<e?o:e,r=(s=t[7])<r?s:r,i=i<o?o:i,n=n<s?s:n,this.minX=e,this.minY=r,this.maxX=i,this.maxY=n},o.prototype.addFrame=function(t,e,r,i,n){var o=t.worldTransform,s=o.a,a=o.b,u=o.c,h=o.d,l=o.tx,c=o.ty,d=this.minX,f=this.minY,p=this.maxX,v=this.maxY,g=s*e+u*r+l,y=a*e+h*r+c;d=g<d?g:d,f=y<f?y:f,p=p<g?g:p,v=v<y?y:v,d=(g=s*i+u*r+l)<d?g:d,f=(y=a*i+h*r+c)<f?y:f,p=p<g?g:p,v=v<y?y:v,d=(g=s*e+u*n+l)<d?g:d,f=(y=a*e+h*n+c)<f?y:f,p=p<g?g:p,v=v<y?y:v,d=(g=s*i+u*n+l)<d?g:d,f=(y=a*i+h*n+c)<f?y:f,p=p<g?g:p,v=v<y?y:v,this.minX=d,this.minY=f,this.maxX=p,this.maxY=v},o.prototype.addVertices=function(t,e,r,i){for(var n=t.worldTransform,o=n.a,s=n.b,a=n.c,u=n.d,h=n.tx,l=n.ty,c=this.minX,d=this.minY,f=this.maxX,p=this.maxY,v=r;v<i;v+=2){var g=e[v],y=e[v+1],m=o*g+a*y+h,_=u*y+s*g+l;c=m<c?m:c,d=_<d?_:d,f=f<m?m:f,p=p<_?_:p}this.minX=c,this.minY=d,this.maxX=f,this.maxY=p},o.prototype.addBounds=function(t){var e=this.minX,r=this.minY,i=this.maxX,n=this.maxY;this.minX=t.minX<e?t.minX:e,this.minY=t.minY<r?t.minY:r,this.maxX=t.maxX>i?t.maxX:i,this.maxY=t.maxY>n?t.maxY:n},o.prototype.addBoundsMask=function(t,e){var r=t.minX>e.minX?t.minX:e.minX,i=t.minY>e.minY?t.minY:e.minY,n=t.maxX<e.maxX?t.maxX:e.maxX,o=t.maxY<e.maxY?t.maxY:e.maxY;if(r<=n&&i<=o){var s=this.minX,a=this.minY,u=this.maxX,h=this.maxY;this.minX=r<s?r:s,this.minY=i<a?i:a,this.maxX=u<n?n:u,this.maxY=h<o?o:h}},o.prototype.addBoundsArea=function(t,e){var r=t.minX>e.x?t.minX:e.x,i=t.minY>e.y?t.minY:e.y,n=t.maxX<e.x+e.width?t.maxX:e.x+e.width,o=t.maxY<e.y+e.height?t.maxY:e.y+e.height;if(r<=n&&i<=o){var s=this.minX,a=this.minY,u=this.maxX,h=this.maxY;this.minX=r<s?r:s,this.minY=i<a?i:a,this.maxX=u<n?n:u,this.maxY=h<o?o:h}},o);function o(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,o),this.minX=1/0,this.minY=1/0,this.maxX=-1/0,this.maxY=-1/0,this.rect=null}r.default=n},{"../math":70}],48:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o,s=t("../utils"),a=t("./DisplayObject"),u=(o=a)&&o.__esModule?o:{default:o};var h,l=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(c,h=u.default),c.prototype.onChildrenChange=function(){},c.prototype.addChild=function(t){var e=arguments.length;if(1<e)for(var r=0;r<e;r++)this.addChild(arguments[r]);else t.parent&&t.parent.removeChild(t),t.parent=this,t.transform._parentID=-1,this.children.push(t),this._boundsID++,this.onChildrenChange(this.children.length-1),t.emit("added",this);return t},c.prototype.addChildAt=function(t,e){if(e<0||e>this.children.length)throw new Error(t+"addChildAt: The index "+e+" supplied is out of bounds "+this.children.length);return t.parent&&t.parent.removeChild(t),t.parent=this,t.transform._parentID=-1,this.children.splice(e,0,t),this._boundsID++,this.onChildrenChange(e),t.emit("added",this),t},c.prototype.swapChildren=function(t,e){if(t!==e){var r=this.getChildIndex(t),i=this.getChildIndex(e);this.children[r]=e,this.children[i]=t,this.onChildrenChange(r<i?r:i)}},c.prototype.getChildIndex=function(t){var e=this.children.indexOf(t);if(-1===e)throw new Error("The supplied DisplayObject must be a child of the caller");return e},c.prototype.setChildIndex=function(t,e){if(e<0||e>=this.children.length)throw new Error("The index "+e+" supplied is out of bounds "+this.children.length);var r=this.getChildIndex(t);(0,s.removeItems)(this.children,r,1),this.children.splice(e,0,t),this.onChildrenChange(e)},c.prototype.getChildAt=function(t){if(t<0||t>=this.children.length)throw new Error("getChildAt: Index ("+t+") does not exist.");return this.children[t]},c.prototype.removeChild=function(t){var e=arguments.length;if(1<e)for(var r=0;r<e;r++)this.removeChild(arguments[r]);else{var i=this.children.indexOf(t);if(-1===i)return null;t.parent=null,t.transform._parentID=-1,(0,s.removeItems)(this.children,i,1),this._boundsID++,this.onChildrenChange(i),t.emit("removed",this)}return t},c.prototype.removeChildAt=function(t){var e=this.getChildAt(t);return e.parent=null,e.transform._parentID=-1,(0,s.removeItems)(this.children,t,1),this._boundsID++,this.onChildrenChange(t),e.emit("removed",this),e},c.prototype.removeChildren=function(t,e){var r=0<arguments.length&&void 0!==t?t:0,i="number"==typeof e?e:this.children.length,n=i-r,o=void 0;if(0<n&&n<=i){o=this.children.splice(r,n);for(var s=0;s<o.length;++s)o[s].parent=null,o[s].transform&&(o[s].transform._parentID=-1);this._boundsID++,this.onChildrenChange(r);for(var a=0;a<o.length;++a)o[a].emit("removed",this);return o}if(0==n&&0===this.children.length)return[];throw new RangeError("removeChildren: numeric values are outside the acceptable range.")},c.prototype.updateTransform=function(){this._boundsID++,this.transform.updateTransform(this.parent.transform),this.worldAlpha=this.alpha*this.parent.worldAlpha;for(var t=0,e=this.children.length;t<e;++t){var r=this.children[t];r.visible&&r.updateTransform()}},c.prototype.calculateBounds=function(){this._bounds.clear(),this._calculateBounds();for(var t=0;t<this.children.length;t++){var e=this.children[t];e.visible&&e.renderable&&(e.calculateBounds(),e._mask?(e._mask.calculateBounds(),this._bounds.addBoundsMask(e._bounds,e._mask._bounds)):e.filterArea?this._bounds.addBoundsArea(e._bounds,e.filterArea):this._bounds.addBounds(e._bounds))}this._lastBoundsID=this._boundsID},c.prototype._calculateBounds=function(){},c.prototype.renderWebGL=function(t){if(this.visible&&!(this.worldAlpha<=0)&&this.renderable)if(this._mask||this.filters&&this.filters.length)this.renderAdvancedWebGL(t);else{this._renderWebGL(t);for(var e=0,r=this.children.length;e<r;++e)this.children[e].renderWebGL(t)}},c.prototype.renderAdvancedWebGL=function(t){t.flush();var e=this._filters,r=this._mask;if(e){this._enabledFilters||(this._enabledFilters=[]);for(var i=this._enabledFilters.length=0;i<e.length;i++)e[i].enabled&&this._enabledFilters.push(e[i]);this._enabledFilters.length&&t.filterManager.pushFilter(this,this._enabledFilters)}r&&t.maskManager.pushMask(this,this._mask),this._renderWebGL(t);for(var n=0,o=this.children.length;n<o;n++)this.children[n].renderWebGL(t);t.flush(),r&&t.maskManager.popMask(this,this._mask),e&&this._enabledFilters&&this._enabledFilters.length&&t.filterManager.popFilter()},c.prototype._renderWebGL=function(){},c.prototype._renderCanvas=function(){},c.prototype.renderCanvas=function(t){if(this.visible&&!(this.worldAlpha<=0)&&this.renderable){this._mask&&t.maskManager.pushMask(this._mask),this._renderCanvas(t);for(var e=0,r=this.children.length;e<r;++e)this.children[e].renderCanvas(t);this._mask&&t.maskManager.popMask(t)}},c.prototype.destroy=function(t){h.prototype.destroy.call(this);var e="boolean"==typeof t?t:t&&t.children,r=this.removeChildren(0,this.children.length);if(e)for(var i=0;i<r.length;++i)r[i].destroy(t)},i(c,[{key:"width",get:function(){return this.scale.x*this.getLocalBounds().width},set:function(t){var e=this.getLocalBounds().width;this.scale.x=0!==e?t/e:1,this._width=t}},{key:"height",get:function(){return this.scale.y*this.getLocalBounds().height},set:function(t){var e=this.getLocalBounds().height;this.scale.y=0!==e?t/e:1,this._height=t}}]),c);function c(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,c);var t=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,h.call(this));return t.children=[],t}(r.default=l).prototype.containerUpdateTransform=l.prototype.updateTransform},{"../utils":125,"./DisplayObject":49}],49:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o=d(t("eventemitter3")),s=t("../const"),a=d(t("../settings")),u=d(t("./TransformStatic")),h=d(t("./Transform")),l=d(t("./Bounds")),c=t("../math");function d(t){return t&&t.__esModule?t:{default:t}}var f,p=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(v,f=o.default),v.prototype.updateTransform=function(){this.transform.updateTransform(this.parent.transform),this.worldAlpha=this.alpha*this.parent.worldAlpha,this._bounds.updateID++},v.prototype._recursivePostUpdateTransform=function(){this.parent?(this.parent._recursivePostUpdateTransform(),this.transform.updateTransform(this.parent.transform)):this.transform.updateTransform(this._tempDisplayObjectParent.transform)},v.prototype.getBounds=function(t,e){return t||(this.parent?(this._recursivePostUpdateTransform(),this.updateTransform()):(this.parent=this._tempDisplayObjectParent,this.updateTransform(),this.parent=null)),this._boundsID!==this._lastBoundsID&&this.calculateBounds(),e||(this._boundsRect||(this._boundsRect=new c.Rectangle),e=this._boundsRect),this._bounds.getRectangle(e)},v.prototype.getLocalBounds=function(t){var e=this.transform,r=this.parent;this.parent=null,this.transform=this._tempDisplayObjectParent.transform,t||(this._localBoundsRect||(this._localBoundsRect=new c.Rectangle),t=this._localBoundsRect);var i=this.getBounds(!1,t);return this.parent=r,this.transform=e,i},v.prototype.toGlobal=function(t,e,r){return 2<arguments.length&&void 0!==r&&r||(this._recursivePostUpdateTransform(),this.parent?this.displayObjectUpdateTransform():(this.parent=this._tempDisplayObjectParent,this.displayObjectUpdateTransform(),this.parent=null)),this.worldTransform.apply(t,e)},v.prototype.toLocal=function(t,e,r,i){return e&&(t=e.toGlobal(t,r,i)),i||(this._recursivePostUpdateTransform(),this.parent?this.displayObjectUpdateTransform():(this.parent=this._tempDisplayObjectParent,this.displayObjectUpdateTransform(),this.parent=null)),this.worldTransform.applyInverse(t,r)},v.prototype.renderWebGL=function(){},v.prototype.renderCanvas=function(){},v.prototype.setParent=function(t){if(!t||!t.addChild)throw new Error("setParent: Argument must be a Container");return t.addChild(this),t},v.prototype.setTransform=function(t,e,r,i,n,o,s,a,u){var h=0<arguments.length&&void 0!==t?t:0,l=1<arguments.length&&void 0!==e?e:0,c=2<arguments.length&&void 0!==r?r:1,d=3<arguments.length&&void 0!==i?i:1,f=4<arguments.length&&void 0!==n?n:0,p=5<arguments.length&&void 0!==o?o:0,v=6<arguments.length&&void 0!==s?s:0,g=7<arguments.length&&void 0!==a?a:0,y=8<arguments.length&&void 0!==u?u:0;return this.position.x=h,this.position.y=l,this.scale.x=c||1,this.scale.y=d||1,this.rotation=f,this.skew.x=p,this.skew.y=v,this.pivot.x=g,this.pivot.y=y,this},v.prototype.destroy=function(){this.removeAllListeners(),this.parent&&this.parent.removeChild(this),this.transform=null,this.parent=null,this._bounds=null,this._currentBounds=null,this._mask=null,this.filterArea=null,this.interactive=!1,this.interactiveChildren=!1,this._destroyed=!0},i(v,[{key:"_tempDisplayObjectParent",get:function(){return null===this.tempDisplayObjectParent&&(this.tempDisplayObjectParent=new v),this.tempDisplayObjectParent}},{key:"x",get:function(){return this.position.x},set:function(t){this.transform.position.x=t}},{key:"y",get:function(){return this.position.y},set:function(t){this.transform.position.y=t}},{key:"worldTransform",get:function(){return this.transform.worldTransform}},{key:"localTransform",get:function(){return this.transform.localTransform}},{key:"position",get:function(){return this.transform.position},set:function(t){this.transform.position.copy(t)}},{key:"scale",get:function(){return this.transform.scale},set:function(t){this.transform.scale.copy(t)}},{key:"pivot",get:function(){return this.transform.pivot},set:function(t){this.transform.pivot.copy(t)}},{key:"skew",get:function(){return this.transform.skew},set:function(t){this.transform.skew.copy(t)}},{key:"rotation",get:function(){return this.transform.rotation},set:function(t){this.transform.rotation=t}},{key:"worldVisible",get:function(){var t=this;do{if(!t.visible)return!1;t=t.parent}while(t);return!0}},{key:"mask",get:function(){return this._mask},set:function(t){this._mask&&(this._mask.renderable=!0,this._mask.isMask=!1),this._mask=t,this._mask&&(this._mask.renderable=!1,this._mask.isMask=!0)}},{key:"filters",get:function(){return this._filters&&this._filters.slice()},set:function(t){this._filters=t&&t.slice()}}]),v);function v(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,v);var t=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,f.call(this)),e=a.default.TRANSFORM_MODE===s.TRANSFORM_MODE.STATIC?u.default:h.default;return t.tempDisplayObjectParent=null,t.transform=new e,t.alpha=1,t.visible=!0,t.renderable=!0,t.parent=null,t.worldAlpha=1,t.filterArea=null,t._filters=null,t._enabledFilters=null,t._bounds=new l.default,t._boundsID=0,t._lastBoundsID=-1,t._boundsRect=null,t._localBoundsRect=null,t._mask=null,t._destroyed=!1,t}(r.default=p).prototype.displayObjectUpdateTransform=p.prototype.updateTransform},{"../const":46,"../math":70,"../settings":101,"./Bounds":47,"./Transform":50,"./TransformStatic":52,eventemitter3:3}],50:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o,s=t("../math"),a=t("./TransformBase"),u=(o=a)&&o.__esModule?o:{default:o};var h,l=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(c,h=u.default),c.prototype.updateSkew=function(){this._cx=Math.cos(this._rotation+this.skew._y),this._sx=Math.sin(this._rotation+this.skew._y),this._cy=-Math.sin(this._rotation-this.skew._x),this._sy=Math.cos(this._rotation-this.skew._x)},c.prototype.updateLocalTransform=function(){var t=this.localTransform;t.a=this._cx*this.scale.x,t.b=this._sx*this.scale.x,t.c=this._cy*this.scale.y,t.d=this._sy*this.scale.y,t.tx=this.position.x-(this.pivot.x*t.a+this.pivot.y*t.c),t.ty=this.position.y-(this.pivot.x*t.b+this.pivot.y*t.d)},c.prototype.updateTransform=function(t){var e=this.localTransform;e.a=this._cx*this.scale.x,e.b=this._sx*this.scale.x,e.c=this._cy*this.scale.y,e.d=this._sy*this.scale.y,e.tx=this.position.x-(this.pivot.x*e.a+this.pivot.y*e.c),e.ty=this.position.y-(this.pivot.x*e.b+this.pivot.y*e.d);var r=t.worldTransform,i=this.worldTransform;i.a=e.a*r.a+e.b*r.c,i.b=e.a*r.b+e.b*r.d,i.c=e.c*r.a+e.d*r.c,i.d=e.c*r.b+e.d*r.d,i.tx=e.tx*r.a+e.ty*r.c+r.tx,i.ty=e.tx*r.b+e.ty*r.d+r.ty,this._worldID++},c.prototype.setFromMatrix=function(t){t.decompose(this)},i(c,[{key:"rotation",get:function(){return this._rotation},set:function(t){this._rotation=t,this.updateSkew()}}]),c);function c(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,c);var t=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,h.call(this));return t.position=new s.Point(0,0),t.scale=new s.Point(1,1),t.skew=new s.ObservablePoint(t.updateSkew,t,0,0),t.pivot=new s.Point(0,0),t._rotation=0,t._cx=1,t._sx=0,t._cy=0,t._sy=1,t}r.default=l},{"../math":70,"./TransformBase":51}],51:[function(t,e,r){"use strict";r.__esModule=!0;var i=t("../math");var n=(o.prototype.updateLocalTransform=function(){},o.prototype.updateTransform=function(t){var e=t.worldTransform,r=this.worldTransform,i=this.localTransform;r.a=i.a*e.a+i.b*e.c,r.b=i.a*e.b+i.b*e.d,r.c=i.c*e.a+i.d*e.c,r.d=i.c*e.b+i.d*e.d,r.tx=i.tx*e.a+i.ty*e.c+e.tx,r.ty=i.tx*e.b+i.ty*e.d+e.ty,this._worldID++},o);function o(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,o),this.worldTransform=new i.Matrix,this.localTransform=new i.Matrix,this._worldID=0,this._parentID=0}(r.default=n).prototype.updateWorldTransform=n.prototype.updateTransform,n.IDENTITY=new n},{"../math":70}],52:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o,s=t("../math"),a=t("./TransformBase"),u=(o=a)&&o.__esModule?o:{default:o};var h,l=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(c,h=u.default),c.prototype.onChange=function(){this._localID++},c.prototype.updateSkew=function(){this._cx=Math.cos(this._rotation+this.skew._y),this._sx=Math.sin(this._rotation+this.skew._y),this._cy=-Math.sin(this._rotation-this.skew._x),this._sy=Math.cos(this._rotation-this.skew._x),this._localID++},c.prototype.updateLocalTransform=function(){var t=this.localTransform;this._localID!==this._currentLocalID&&(t.a=this._cx*this.scale._x,t.b=this._sx*this.scale._x,t.c=this._cy*this.scale._y,t.d=this._sy*this.scale._y,t.tx=this.position._x-(this.pivot._x*t.a+this.pivot._y*t.c),t.ty=this.position._y-(this.pivot._x*t.b+this.pivot._y*t.d),this._currentLocalID=this._localID,this._parentID=-1)},c.prototype.updateTransform=function(t){var e=this.localTransform;if(this._localID!==this._currentLocalID&&(e.a=this._cx*this.scale._x,e.b=this._sx*this.scale._x,e.c=this._cy*this.scale._y,e.d=this._sy*this.scale._y,e.tx=this.position._x-(this.pivot._x*e.a+this.pivot._y*e.c),e.ty=this.position._y-(this.pivot._x*e.b+this.pivot._y*e.d),this._currentLocalID=this._localID,this._parentID=-1),this._parentID!==t._worldID){var r=t.worldTransform,i=this.worldTransform;i.a=e.a*r.a+e.b*r.c,i.b=e.a*r.b+e.b*r.d,i.c=e.c*r.a+e.d*r.c,i.d=e.c*r.b+e.d*r.d,i.tx=e.tx*r.a+e.ty*r.c+r.tx,i.ty=e.tx*r.b+e.ty*r.d+r.ty,this._parentID=t._worldID,this._worldID++}},c.prototype.setFromMatrix=function(t){t.decompose(this),this._localID++},i(c,[{key:"rotation",get:function(){return this._rotation},set:function(t){this._rotation!==t&&(this._rotation=t,this.updateSkew())}}]),c);function c(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,c);var t=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,h.call(this));return t.position=new s.ObservablePoint(t.onChange,t,0,0),t.scale=new s.ObservablePoint(t.onChange,t,1,1),t.pivot=new s.ObservablePoint(t.onChange,t,0,0),t.skew=new s.ObservablePoint(t.updateSkew,t,0,0),t._rotation=0,t._cx=1,t._sx=0,t._cy=0,t._sy=1,t._localID=0,t._currentLocalID=0,t}r.default=l},{"../math":70,"./TransformBase":51}],53:[function(t,e,r){"use strict";r.__esModule=!0;var i=f(t("../display/Container")),s=f(t("../textures/RenderTexture")),a=f(t("../textures/Texture")),n=f(t("./GraphicsData")),u=f(t("../sprites/Sprite")),h=t("../math"),l=t("../utils"),E=t("../const"),o=f(t("../display/Bounds")),c=f(t("./utils/bezierCurveTo")),d=f(t("../renderers/canvas/CanvasRenderer"));function f(t){return t&&t.__esModule?t:{default:t}}var p,v=void 0,g=new h.Matrix,y=new h.Point,m=new Float32Array(4),_=new Float32Array(4),x=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(S,p=i.default),S.prototype.clone=function(){var t=new S;t.renderable=this.renderable,t.fillAlpha=this.fillAlpha,t.lineWidth=this.lineWidth,t.lineColor=this.lineColor,t.lineAlignment=this.lineAlignment,t.tint=this.tint,t.blendMode=this.blendMode,t.isMask=this.isMask,t.boundsPadding=this.boundsPadding,t.dirty=0,t.cachedSpriteDirty=this.cachedSpriteDirty;for(var e=0;e<this.graphicsData.length;++e)t.graphicsData.push(this.graphicsData[e].clone());return t.currentPath=t.graphicsData[t.graphicsData.length-1],t.updateLocalBounds(),t},S.prototype._quadraticCurveLength=function(t,e,r,i,n,o){var s=t-2*r+n,a=e-2*i+o,u=2*r-2*t,h=2*i-2*e,l=4*(s*s+a*a),c=4*(s*u+a*h),d=u*u+h*h,f=2*Math.sqrt(l+c+d),p=Math.sqrt(l),v=2*l*p,g=2*Math.sqrt(d),y=c/p;return(v*f+p*c*(f-g)+(4*d*l-c*c)*Math.log((2*p+y+f)/(y+g)))/(4*v)},S.prototype._bezierCurveLength=function(t,e,r,i,n,o,s,a){for(var u=0,h=0,l=0,c=0,d=0,f=0,p=0,v=0,g=0,y=0,m=0,_=t,x=e,b=1;b<=10;++b)y=_-(v=(p=(f=(d=1-(h=b/10))*d)*d)*t+3*f*h*r+3*d*(l=h*h)*n+(c=l*h)*s),m=x-(g=p*e+3*f*h*i+3*d*l*o+c*a),_=v,x=g,u+=Math.sqrt(y*y+m*m);return u},S.prototype._segmentsCount=function(t){var e=Math.ceil(t/S.CURVES.maxLength);return e<S.CURVES.minSegments?e=S.CURVES.minSegments:e>S.CURVES.maxSegments&&(e=S.CURVES.maxSegments),e},S.prototype.lineStyle=function(t,e,r,i){var n=0<arguments.length&&void 0!==t?t:0,o=1<arguments.length&&void 0!==e?e:0,s=2<arguments.length&&void 0!==r?r:1,a=3<arguments.length&&void 0!==i?i:.5;if(this.lineWidth=n,this.lineColor=o,this.lineAlpha=s,this.lineAlignment=a,this.currentPath)if(this.currentPath.shape.points.length){var u=new h.Polygon(this.currentPath.shape.points.slice(-2));u.closed=!1,this.drawShape(u)}else this.currentPath.lineWidth=this.lineWidth,this.currentPath.lineColor=this.lineColor,this.currentPath.lineAlpha=this.lineAlpha,this.currentPath.lineAlignment=this.lineAlignment;return this},S.prototype.moveTo=function(t,e){var r=new h.Polygon([t,e]);return r.closed=!1,this.drawShape(r),this},S.prototype.lineTo=function(t,e){var r=this.currentPath.shape.points,i=r[r.length-2],n=r[r.length-1];return i===t&&n===e||(r.push(t,e),this.dirty++),this},S.prototype.quadraticCurveTo=function(t,e,r,i){this.currentPath?0===this.currentPath.shape.points.length&&(this.currentPath.shape.points=[0,0]):this.moveTo(0,0);var n=this.currentPath.shape.points,o=0,s=0;0===n.length&&this.moveTo(0,0);for(var a=n[n.length-2],u=n[n.length-1],h=S.CURVES.adaptive?this._segmentsCount(this._quadraticCurveLength(a,u,t,e,r,i)):20,l=1;l<=h;++l){var c=l/h;o=a+(t-a)*c,s=u+(e-u)*c,n.push(o+(t+(r-t)*c-o)*c,s+(e+(i-e)*c-s)*c)}return this.dirty++,this},S.prototype.bezierCurveTo=function(t,e,r,i,n,o){this.currentPath?0===this.currentPath.shape.points.length&&(this.currentPath.shape.points=[0,0]):this.moveTo(0,0);var s=this.currentPath.shape.points,a=s[s.length-2],u=s[s.length-1];s.length-=2;var h=S.CURVES.adaptive?this._segmentsCount(this._bezierCurveLength(a,u,t,e,r,i,n,o)):20;return(0,c.default)(a,u,t,e,r,i,n,o,h,s),this.dirty++,this},S.prototype.arcTo=function(t,e,r,i,n){this.currentPath?0===this.currentPath.shape.points.length&&this.currentPath.shape.points.push(t,e):this.moveTo(t,e);var o=this.currentPath.shape.points,s=o[o.length-2],a=o[o.length-1]-e,u=s-t,h=i-e,l=r-t,c=Math.abs(a*l-u*h);if(c<1e-8||0===n)o[o.length-2]===t&&o[o.length-1]===e||o.push(t,e);else{var d=a*a+u*u,f=h*h+l*l,p=a*h+u*l,v=n*Math.sqrt(d)/c,g=n*Math.sqrt(f)/c,y=v*p/d,m=g*p/f,_=v*l+g*u,x=v*h+g*a,b=u*(g+y),T=a*(g+y),w=l*(v+m),E=h*(v+m),S=Math.atan2(T-x,b-_),O=Math.atan2(E-x,w-_);this.arc(_+t,x+e,n,S,O,l*a<u*h)}return this.dirty++,this},S.prototype.arc=function(t,e,r,i,n,o){var s=5<arguments.length&&void 0!==o&&o;if(i===n)return this;!s&&n<=i?n+=E.PI_2:s&&i<=n&&(i+=E.PI_2);var a=n-i,u=S.CURVES.adaptive?this._segmentsCount(Math.abs(a)*r):40*Math.ceil(Math.abs(a)/E.PI_2);if(0==a)return this;var h=t+Math.cos(i)*r,l=e+Math.sin(i)*r,c=this.currentPath?this.currentPath.shape.points:null;if(c){var d=Math.abs(c[c.length-2]-h),f=Math.abs(c[c.length-1]-l);d<.001&&f<.001||c.push(h,l)}else this.moveTo(h,l),c=this.currentPath.shape.points;for(var p=a/(2*u),v=2*p,g=Math.cos(p),y=Math.sin(p),m=u-1,_=m%1/m,x=0;x<=m;++x){var b=p+i+v*(x+_*x),T=Math.cos(b),w=-Math.sin(b);c.push((g*T+y*w)*r+t,(g*-w+y*T)*r+e)}return this.dirty++,this},S.prototype.beginFill=function(t,e){var r=0<arguments.length&&void 0!==t?t:0,i=1<arguments.length&&void 0!==e?e:1;return this.filling=!0,this.fillColor=r,this.fillAlpha=i,this.currentPath&&this.currentPath.shape.points.length<=2&&(this.currentPath.fill=this.filling,this.currentPath.fillColor=this.fillColor,this.currentPath.fillAlpha=this.fillAlpha),this},S.prototype.endFill=function(){return this.filling=!1,this.fillColor=null,this.fillAlpha=1,this},S.prototype.drawRect=function(t,e,r,i){return this.drawShape(new h.Rectangle(t,e,r,i)),this},S.prototype.drawRoundedRect=function(t,e,r,i,n){return this.drawShape(new h.RoundedRectangle(t,e,r,i,n)),this},S.prototype.drawCircle=function(t,e,r){return this.drawShape(new h.Circle(t,e,r)),this},S.prototype.drawEllipse=function(t,e,r,i){return this.drawShape(new h.Ellipse(t,e,r,i)),this},S.prototype.drawPolygon=function(t){var e=t,r=!0;if(e instanceof h.Polygon&&(r=e.closed,e=e.points),!Array.isArray(e)){e=new Array(arguments.length);for(var i=0;i<e.length;++i)e[i]=arguments[i]}var n=new h.Polygon(e);return n.closed=r,this.drawShape(n),this},S.prototype.drawStar=function(t,e,r,i,n,o){var s=5<arguments.length&&void 0!==o?o:0;n=n||i/2;for(var a=-1*Math.PI/2+s,u=2*r,h=E.PI_2/u,l=[],c=0;c<u;c++){var d=c%2?n:i,f=c*h+a;l.push(t+d*Math.cos(f),e+d*Math.sin(f))}return this.drawPolygon(l)},S.prototype.clear=function(){return(this.lineWidth||this.filling||0<this.graphicsData.length)&&(this.lineWidth=0,this.lineAlignment=.5,this.filling=!1,this.boundsDirty=-1,this.canvasTintDirty=-1,this.dirty++,this.clearDirty++,this.graphicsData.length=0),this.currentPath=null,this._spriteRect=null,this},S.prototype.isFastRect=function(){return 1===this.graphicsData.length&&this.graphicsData[0].shape.type===E.SHAPES.RECT&&!this.graphicsData[0].lineWidth},S.prototype._renderWebGL=function(t){this.dirty!==this.fastRectDirty&&(this.fastRectDirty=this.dirty,this._fastRect=this.isFastRect()),this._fastRect?this._renderSpriteRect(t):(t.setObjectRenderer(t.plugins.graphics),t.plugins.graphics.render(this))},S.prototype._renderSpriteRect=function(t){var e=this.graphicsData[0].shape;this._spriteRect||(this._spriteRect=new u.default(new a.default(a.default.WHITE)));var r=this._spriteRect,i=this.graphicsData[0].fillColor;if(16777215===this.tint)r.tint=i;else if(this.tint!==this._prevRectTint||i!==this._prevRectFillColor){var n=m,o=_;(0,l.hex2rgb)(i,n),(0,l.hex2rgb)(this.tint,o),n[0]*=o[0],n[1]*=o[1],n[2]*=o[2],r.tint=(0,l.rgb2hex)(n),this._prevRectTint=this.tint,this._prevRectFillColor=i}r.alpha=this.graphicsData[0].fillAlpha,r.worldAlpha=this.worldAlpha*r.alpha,r.blendMode=this.blendMode,r._texture._frame.width=e.width,r._texture._frame.height=e.height,r.transform.worldTransform=this.transform.worldTransform,r.anchor.set(-e.x/e.width,-e.y/e.height),r._onAnchorUpdate(),r._renderWebGL(t)},S.prototype._renderCanvas=function(t){!0!==this.isMask&&t.plugins.graphics.render(this)},S.prototype._calculateBounds=function(){this.boundsDirty!==this.dirty&&(this.boundsDirty=this.dirty,this.updateLocalBounds(),this.cachedSpriteDirty=!0);var t=this._localBounds;this._bounds.addFrame(this.transform,t.minX,t.minY,t.maxX,t.maxY)},S.prototype.containsPoint=function(t){this.worldTransform.applyInverse(t,y);for(var e=this.graphicsData,r=0;r<e.length;++r){var i=e[r];if(i.fill&&i.shape&&i.shape.contains(y.x,y.y)){var n=!1;if(i.holes)for(var o=0;o<i.holes.length;o++)if(i.holes[o].contains(y.x,y.y)){n=!0;break}if(!n)return!0}}return!1},S.prototype.updateLocalBounds=function(){var t=1/0,e=-1/0,r=1/0,i=-1/0;if(this.graphicsData.length)for(var n=0,o=0,s=0,a=0,u=0,h=0;h<this.graphicsData.length;h++){var l=this.graphicsData[h],c=l.type,d=l.lineWidth*l.lineAlignment;if(n=l.shape,c===E.SHAPES.RECT||c===E.SHAPES.RREC)o=n.x-d,s=n.y-d,t=o<t?o:t,e=e<o+(a=n.width+2*d)?o+a:e,r=s<r?s:r,i=i<s+(u=n.height+2*d)?s+u:i;else if(c===E.SHAPES.CIRC)o=n.x,s=n.y,t=o-(a=n.radius+d)<t?o-a:t,e=e<o+a?o+a:e,r=s-(u=n.radius+d)<r?s-u:r,i=i<s+u?s+u:i;else if(c===E.SHAPES.ELIP)o=n.x,s=n.y,t=o-(a=n.width+d)<t?o-a:t,e=e<o+a?o+a:e,r=s-(u=n.height+d)<r?s-u:r,i=i<s+u?s+u:i;else for(var f=n.points,p=0,v=0,g=0,y=0,m=0,_=0,x=0,b=0,T=0;T+2<f.length;T+=2)o=f[T],s=f[T+1],p=f[T+2],v=f[T+3],g=Math.abs(p-o),y=Math.abs(v-s),u=2*d,(a=Math.sqrt(g*g+y*y))<1e-9||(t=(x=(p+o)/2)-(m=(u/a*y+g)/2)<t?x-m:t,e=e<x+m?x+m:e,r=(b=(v+s)/2)-(_=(u/a*g+y)/2)<r?b-_:r,i=i<b+_?b+_:i)}else i=r=e=t=0;var w=this.boundsPadding;this._localBounds.minX=t-w,this._localBounds.maxX=e+w,this._localBounds.minY=r-w,this._localBounds.maxY=i+w},S.prototype.drawShape=function(t){this.currentPath&&this.currentPath.shape.points.length<=2&&this.graphicsData.pop(),this.currentPath=null;var e=new n.default(this.lineWidth,this.lineColor,this.lineAlpha,this.fillColor,this.fillAlpha,this.filling,this.nativeLines,t,this.lineAlignment);return this.graphicsData.push(e),e.type===E.SHAPES.POLY&&(e.shape.closed=e.shape.closed,this.currentPath=e),this.dirty++,e},S.prototype.generateCanvasTexture=function(t,e){var r=1<arguments.length&&void 0!==e?e:1,i=this.getLocalBounds(),n=s.default.create(i.width,i.height,t,r);v=v||new d.default,this.transform.updateLocalTransform(),this.transform.localTransform.copy(g),g.invert(),g.tx-=i.x,g.ty-=i.y,v.render(this,n,!0,g);var o=a.default.fromCanvas(n.baseTexture._canvasRenderTarget.canvas,t,"graphics");return o.baseTexture.resolution=r,o.baseTexture.update(),o},S.prototype.closePath=function(){var t=this.currentPath;return t&&t.shape&&t.shape.close(),this},S.prototype.addHole=function(){var t=this.graphicsData.pop();return this.currentPath=this.graphicsData[this.graphicsData.length-1],this.currentPath.addHole(t.shape),this.currentPath=null,this},S.prototype.destroy=function(t){p.prototype.destroy.call(this,t);for(var e=0;e<this.graphicsData.length;++e)this.graphicsData[e].destroy();for(var r in this._webGL)for(var i=0;i<this._webGL[r].data.length;++i)this._webGL[r].data[i].destroy();this._spriteRect&&this._spriteRect.destroy(),this.graphicsData=null,this.currentPath=null,this._webGL=null,this._localBounds=null},S);function S(){var t=0<arguments.length&&void 0!==arguments[0]&&arguments[0];!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,S);var e=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,p.call(this));return e.fillAlpha=1,e.lineWidth=0,e.nativeLines=t,e.lineColor=0,e.lineAlignment=.5,e.graphicsData=[],e.tint=16777215,e._prevTint=16777215,e.blendMode=E.BLEND_MODES.NORMAL,e.currentPath=null,e._webGL={},e.isMask=!1,e.boundsPadding=0,e._localBounds=new o.default,e.dirty=0,e.fastRectDirty=-1,e.clearDirty=0,e.boundsDirty=-1,e.cachedSpriteDirty=!1,e._spriteRect=null,e._fastRect=!1,e._prevRectTint=null,e._prevRectFillColor=null,e}(r.default=x)._SPRITE_TEXTURE=null,x.CURVES={adaptive:!1,maxLength:10,minSegments:8,maxSegments:2048}},{"../const":46,"../display/Bounds":47,"../display/Container":48,"../math":70,"../renderers/canvas/CanvasRenderer":77,"../sprites/Sprite":102,"../textures/RenderTexture":113,"../textures/Texture":115,"../utils":125,"./GraphicsData":54,"./utils/bezierCurveTo":56}],54:[function(t,e,r){"use strict";r.__esModule=!0;var i=(h.prototype.clone=function(){return new h(this.lineWidth,this.lineColor,this.lineAlpha,this.fillColor,this.fillAlpha,this.fill,this.nativeLines,this.shape,this.lineAlignment)},h.prototype.addHole=function(t){this.holes.push(t)},h.prototype.destroy=function(){this.shape=null,this.holes=null},h);function h(t,e,r,i,n,o,s,a,u){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,h),this.lineWidth=t,this.lineAlignment=u,this.nativeLines=s,this.lineColor=e,this.lineAlpha=r,this._lineTint=e,this.fillColor=i,this.fillAlpha=n,this._fillTint=i,this.fill=o,this.holes=[],this.shape=a,this.type=a.type}r.default=i},{}],55:[function(t,e,r){"use strict";r.__esModule=!0;var i,n=t("../../renderers/canvas/CanvasRenderer"),o=(i=n)&&i.__esModule?i:{default:i},j=t("../../const");var s=(a.prototype.render=function(t){var e=this.renderer,r=e.context,i=t.worldAlpha,n=t.transform.worldTransform,o=e.resolution;r.setTransform(n.a*o,n.b*o,n.c*o,n.d*o,n.tx*o,n.ty*o),t.canvasTintDirty===t.dirty&&t._prevTint===t.tint||this.updateGraphicsTint(t),e.setBlendMode(t.blendMode);for(var s=0;s<t.graphicsData.length;s++){var a=t.graphicsData[s],u=a.shape,h=a._fillTint,l=a._lineTint;if(r.lineWidth=a.lineWidth,a.type===j.SHAPES.POLY){r.beginPath();var c=u.points,d=a.holes,f=void 0,p=void 0,v=void 0,g=void 0;r.moveTo(c[0],c[1]);for(var y=2;y<c.length;y+=2)r.lineTo(c[y],c[y+1]);if(u.closed&&r.closePath(),0<d.length){v=c[f=0],g=c[1];for(var m=2;m+2<c.length;m+=2)f+=(c[m]-v)*(c[m+3]-g)-(c[m+2]-v)*(c[m+1]-g);for(var _=0;_<d.length;_++)if(c=d[_].points){v=c[p=0],g=c[1];for(var x=2;x+2<c.length;x+=2)p+=(c[x]-v)*(c[x+3]-g)-(c[x+2]-v)*(c[x+1]-g);if(p*f<0){r.moveTo(c[0],c[1]);for(var b=2;b<c.length;b+=2)r.lineTo(c[b],c[b+1])}else{r.moveTo(c[c.length-2],c[c.length-1]);for(var T=c.length-4;0<=T;T-=2)r.lineTo(c[T],c[T+1])}d[_].close&&r.closePath()}}a.fill&&(r.globalAlpha=a.fillAlpha*i,r.fillStyle="#"+("00000"+(0|h).toString(16)).substr(-6),r.fill()),a.lineWidth&&(r.globalAlpha=a.lineAlpha*i,r.strokeStyle="#"+("00000"+(0|l).toString(16)).substr(-6),r.stroke())}else if(a.type===j.SHAPES.RECT)!a.fillColor&&0!==a.fillColor||(r.globalAlpha=a.fillAlpha*i,r.fillStyle="#"+("00000"+(0|h).toString(16)).substr(-6),r.fillRect(u.x,u.y,u.width,u.height)),a.lineWidth&&(r.globalAlpha=a.lineAlpha*i,r.strokeStyle="#"+("00000"+(0|l).toString(16)).substr(-6),r.strokeRect(u.x,u.y,u.width,u.height));else if(a.type===j.SHAPES.CIRC)r.beginPath(),r.arc(u.x,u.y,u.radius,0,2*Math.PI),r.closePath(),a.fill&&(r.globalAlpha=a.fillAlpha*i,r.fillStyle="#"+("00000"+(0|h).toString(16)).substr(-6),r.fill()),a.lineWidth&&(r.globalAlpha=a.lineAlpha*i,r.strokeStyle="#"+("00000"+(0|l).toString(16)).substr(-6),r.stroke());else if(a.type===j.SHAPES.ELIP){var w=2*u.width,E=2*u.height,S=u.x-w/2,O=u.y-E/2;r.beginPath();var M=w/2*.5522848,P=E/2*.5522848,C=S+w,R=O+E,A=S+w/2,I=O+E/2;r.moveTo(S,I),r.bezierCurveTo(S,I-P,A-M,O,A,O),r.bezierCurveTo(A+M,O,C,I-P,C,I),r.bezierCurveTo(C,I+P,A+M,R,A,R),r.bezierCurveTo(A-M,R,S,I+P,S,I),r.closePath(),a.fill&&(r.globalAlpha=a.fillAlpha*i,r.fillStyle="#"+("00000"+(0|h).toString(16)).substr(-6),r.fill()),a.lineWidth&&(r.globalAlpha=a.lineAlpha*i,r.strokeStyle="#"+("00000"+(0|l).toString(16)).substr(-6),r.stroke())}else if(a.type===j.SHAPES.RREC){var D=u.x,L=u.y,N=u.width,B=u.height,k=u.radius,F=Math.min(N,B)/2|0;k=F<k?F:k,r.beginPath(),r.moveTo(D,L+k),r.lineTo(D,L+B-k),r.quadraticCurveTo(D,L+B,D+k,L+B),r.lineTo(D+N-k,L+B),r.quadraticCurveTo(D+N,L+B,D+N,L+B-k),r.lineTo(D+N,L+k),r.quadraticCurveTo(D+N,L,D+N-k,L),r.lineTo(D+k,L),r.quadraticCurveTo(D,L,D,L+k),r.closePath(),!a.fillColor&&0!==a.fillColor||(r.globalAlpha=a.fillAlpha*i,r.fillStyle="#"+("00000"+(0|h).toString(16)).substr(-6),r.fill()),a.lineWidth&&(r.globalAlpha=a.lineAlpha*i,r.strokeStyle="#"+("00000"+(0|l).toString(16)).substr(-6),r.stroke())}}},a.prototype.updateGraphicsTint=function(t){t._prevTint=t.tint,t.canvasTintDirty=t.dirty;for(var e=(t.tint>>16&255)/255,r=(t.tint>>8&255)/255,i=(255&t.tint)/255,n=0;n<t.graphicsData.length;++n){var o=t.graphicsData[n],s=0|o.fillColor,a=0|o.lineColor;o._fillTint=((s>>16&255)/255*e*255<<16)+((s>>8&255)/255*r*255<<8)+(255&s)/255*i*255,o._lineTint=((a>>16&255)/255*e*255<<16)+((a>>8&255)/255*r*255<<8)+(255&a)/255*i*255}},a.prototype.renderPolygon=function(t,e,r){r.moveTo(t[0],t[1]);for(var i=1;i<t.length/2;++i)r.lineTo(t[2*i],t[2*i+1]);e&&r.closePath()},a.prototype.destroy=function(){this.renderer=null},a);function a(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,a),this.renderer=t}r.default=s,o.default.registerPlugin("graphics",s)},{"../../const":46,"../../renderers/canvas/CanvasRenderer":77}],56:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t,e,r,i,n,o,s,a,u){var h=9<arguments.length&&void 0!==arguments[9]?arguments[9]:[],l=0,c=0,d=0,f=0,p=0;h.push(t,e);for(var v=1,g=0;v<=u;++v)d=(c=(l=1-(g=v/u))*l)*l,p=(f=g*g)*g,h.push(d*t+3*c*g*r+3*l*f*n+p*s,d*e+3*c*g*i+3*l*f*o+p*a);return h}},{}],57:[function(t,e,r){"use strict";r.__esModule=!0;var h=t("../../utils"),l=t("../../const"),i=a(t("../../renderers/webgl/utils/ObjectRenderer")),n=a(t("../../renderers/webgl/WebGLRenderer")),o=a(t("./WebGLGraphicsData")),s=a(t("./shaders/PrimitiveShader")),c=a(t("./utils/buildPoly")),d=a(t("./utils/buildRectangle")),f=a(t("./utils/buildRoundedRectangle")),p=a(t("./utils/buildCircle"));function a(t){return t&&t.__esModule?t:{default:t}}var u,v=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(g,u=i.default),g.prototype.onContextChange=function(){this.gl=this.renderer.gl,this.CONTEXT_UID=this.renderer.CONTEXT_UID,this.primitiveShader=new s.default(this.gl)},g.prototype.destroy=function(){i.default.prototype.destroy.call(this);for(var t=0;t<this.graphicsDataPool.length;++t)this.graphicsDataPool[t].destroy();this.graphicsDataPool=null},g.prototype.render=function(t){var e=this.renderer,r=e.gl,i=void 0,n=t._webGL[this.CONTEXT_UID];n&&t.dirty===n.dirty||(this.updateGraphics(t),n=t._webGL[this.CONTEXT_UID]);var o=this.primitiveShader;e.bindShader(o),e.state.setBlendMode(t.blendMode);for(var s=0,a=n.data.length;s<a;s++){var u=(i=n.data[s]).shader;e.bindShader(u),u.uniforms.translationMatrix=t.transform.worldTransform.toArray(!0),u.uniforms.tint=(0,h.hex2rgb)(t.tint),u.uniforms.alpha=t.worldAlpha,e.bindVao(i.vao),i.nativeLines?r.drawArrays(r.LINES,0,i.points.length/6):i.vao.draw(r.TRIANGLE_STRIP,i.indices.length)}},g.prototype.updateGraphics=function(t){var e=this.renderer.gl,r=t._webGL[this.CONTEXT_UID];if((r=r||(t._webGL[this.CONTEXT_UID]={lastIndex:0,data:[],gl:e,clearDirty:-1,dirty:-1})).dirty=t.dirty,t.clearDirty!==r.clearDirty){r.clearDirty=t.clearDirty;for(var i=0;i<r.data.length;i++)this.graphicsDataPool.push(r.data[i]);r.data.length=0,r.lastIndex=0}for(var n=void 0,o=void 0,s=r.lastIndex;s<t.graphicsData.length;s++){var a=t.graphicsData[s];n=this.getWebGLData(r,0),a.nativeLines&&a.lineWidth&&(o=this.getWebGLData(r,0,!0),r.lastIndex++),a.type===l.SHAPES.POLY&&(0,c.default)(a,n,o),a.type===l.SHAPES.RECT?(0,d.default)(a,n,o):a.type===l.SHAPES.CIRC||a.type===l.SHAPES.ELIP?(0,p.default)(a,n,o):a.type===l.SHAPES.RREC&&(0,f.default)(a,n,o),r.lastIndex++}this.renderer.bindVao(null);for(var u=0;u<r.data.length;u++)(n=r.data[u]).dirty&&n.upload()},g.prototype.getWebGLData=function(t,e,r){var i=t.data[t.data.length-1];return(!i||i.nativeLines!==r||32e4<i.points.length)&&((i=this.graphicsDataPool.pop()||new o.default(this.renderer.gl,this.primitiveShader,this.renderer.state.attribsState)).nativeLines=r,i.reset(e),t.data.push(i)),i.dirty=!0,i},g);function g(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,g);var e=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,u.call(this,t));return e.graphicsDataPool=[],e.primitiveShader=null,e.gl=t.gl,e.CONTEXT_UID=0,e}r.default=v,n.default.registerPlugin("graphics",v)},{"../../const":46,"../../renderers/webgl/WebGLRenderer":84,"../../renderers/webgl/utils/ObjectRenderer":94,"../../utils":125,"./WebGLGraphicsData":58,"./shaders/PrimitiveShader":59,"./utils/buildCircle":60,"./utils/buildPoly":62,"./utils/buildRectangle":63,"./utils/buildRoundedRectangle":64}],58:[function(t,e,r){"use strict";r.__esModule=!0;var i,n=t("pixi-gl-core"),o=(i=n)&&i.__esModule?i:{default:i};var s=(a.prototype.reset=function(){this.points.length=0,this.indices.length=0},a.prototype.upload=function(){this.glPoints=new Float32Array(this.points),this.buffer.upload(this.glPoints),this.glIndices=new Uint16Array(this.indices),this.indexBuffer.upload(this.glIndices),this.dirty=!1},a.prototype.destroy=function(){this.color=null,this.points=null,this.indices=null,this.vao.destroy(),this.buffer.destroy(),this.indexBuffer.destroy(),this.gl=null,this.buffer=null,this.indexBuffer=null,this.glPoints=null,this.glIndices=null},a);function a(t,e,r){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,a),this.gl=t,this.color=[0,0,0],this.points=[],this.indices=[],this.buffer=o.default.GLBuffer.createVertexBuffer(t),this.indexBuffer=o.default.GLBuffer.createIndexBuffer(t),this.dirty=!0,this.nativeLines=!1,this.glPoints=null,this.glIndices=null,this.shader=e,this.vao=new o.default.VertexArrayObject(t,r).addIndex(this.indexBuffer).addAttribute(this.buffer,e.attributes.aVertexPosition,t.FLOAT,!1,24,0).addAttribute(this.buffer,e.attributes.aColor,t.FLOAT,!1,24,8)}r.default=s},{"pixi-gl-core":15}],59:[function(t,e,r){"use strict";r.__esModule=!0;var i,n=t("../../../Shader"),o=(i=n)&&i.__esModule?i:{default:i};var s,a=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(u,s=o.default),u);function u(t){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,u),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,s.call(this,t,["attribute vec2 aVertexPosition;","attribute vec4 aColor;","uniform mat3 translationMatrix;","uniform mat3 projectionMatrix;","uniform float alpha;","uniform vec3 tint;","varying vec4 vColor;","void main(void){"," gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);"," vColor = aColor * vec4(tint * alpha, alpha);","}"].join("\n"),["varying vec4 vColor;","void main(void){"," gl_FragColor = vColor;","}"].join("\n")))}r.default=a},{"../../../Shader":44}],60:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t,e,r){var i=t.shape,n=i.x,o=i.y,s=void 0,a=void 0;a=t.type===T.SHAPES.CIRC?(s=i.radius,i.radius):(s=i.width,i.height);if(0===s||0===a)return;var u=Math.floor(30*Math.sqrt(i.radius))||Math.floor(15*Math.sqrt(i.width+i.height)),h=2*Math.PI/u;if(t.fill){var l=(0,w.hex2rgb)(t.fillColor),c=t.fillAlpha,d=l[0]*c,f=l[1]*c,p=l[2]*c,v=e.points,g=e.indices,y=v.length/6;g.push(y);for(var m=0;m<u+1;m++)v.push(n,o,d,f,p,c),v.push(n+Math.sin(h*m)*s,o+Math.cos(h*m)*a,d,f,p,c),g.push(y++,y++);g.push(y-1)}if(t.lineWidth){var _=t.points;t.points=[];for(var x=0;x<u;x++)t.points.push(n+Math.sin(h*-x)*s,o+Math.cos(h*-x)*a);t.points.push(t.points[0],t.points[1]),(0,b.default)(t,e,r),t.points=_}};var i,n=t("./buildLine"),b=(i=n)&&i.__esModule?i:{default:i},T=t("../../../const"),w=t("../../../utils")},{"../../../const":46,"../../../utils":125,"./buildLine":61}],61:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t,e,r){t.nativeLines?function(t,e){var r=0,i=t.points;if(0===i.length)return;var n=e.points,o=i.length/2,s=(0,V.hex2rgb)(t.lineColor),a=t.lineAlpha,u=s[0]*a,h=s[1]*a,l=s[2]*a;for(r=1;r<o;r++){var c=i[2*(r-1)],d=i[2*(r-1)+1],f=i[2*r],p=i[2*r+1];n.push(c,d),n.push(u,h,l,a),n.push(f,p),n.push(u,h,l,a)}}(t,r):function(t,e){var r=t.points;if(0===r.length)return;var i=new Y.Point(r[0],r[1]),n=new Y.Point(r[r.length-2],r[r.length-1]);if(i.x===n.x&&i.y===n.y){(r=r.slice()).pop(),r.pop();var o=(n=new Y.Point(r[r.length-2],r[r.length-1])).x+.5*(i.x-n.x),s=n.y+.5*(i.y-n.y);r.unshift(o,s),r.push(o,s)}var a=e.points,u=e.indices,h=r.length/2,l=r.length,c=a.length/6,d=t.lineWidth/2,f=(0,V.hex2rgb)(t.lineColor),p=t.lineAlpha,v=f[0]*p,g=f[1]*p,y=f[2]*p,m=r[0],_=r[1],x=r[2],b=r[3],T=0,w=0,E=-(_-b),S=m-x,O=0,M=0,P=0,C=0,R=Math.sqrt(E*E+S*S);E/=R,S/=R,E*=d,S*=d;var A=t.lineAlignment,I=2*(1-A),D=2*A;a.push(m-E*I,_-S*I,v,g,y,p),a.push(m+E*D,_+S*D,v,g,y,p);for(var L=1;L<h-1;++L){m=r[2*(L-1)],_=r[2*(L-1)+1],x=r[2*L],b=r[2*L+1],T=r[2*(L+1)],w=r[2*(L+1)+1],E=-(_-b),S=m-x,R=Math.sqrt(E*E+S*S),E/=R,S/=R,E*=d,S*=d,O=-(b-w),M=x-T,R=Math.sqrt(O*O+M*M),O/=R,M/=R;var N=-S+_-(-S+b),B=-E+x-(-E+m),k=(-E+m)*(-S+b)-(-E+x)*(-S+_),F=-(M*=d)+w-(-M+b),j=-(O*=d)+x-(-O+T),U=(-O+T)*(-M+b)-(-O+x)*(-M+w),X=N*j-F*B;if(Math.abs(X)<.1)X+=10.1,a.push(x-E*I,b-S*I,v,g,y,p),a.push(x+E*D,b+S*D,v,g,y,p);else{var G=(B*U-j*k)/X,W=(F*k-N*U)/X;196*d*d<(G-x)*(G-x)+(W-b)*(W-b)?(P=E-O,C=S-M,R=Math.sqrt(P*P+C*C),P/=R,C/=R,P*=d,C*=d,a.push(x-P*I,b-C*I),a.push(v,g,y,p),a.push(x+P*D,b+C*D),a.push(v,g,y,p),a.push(x-P*D*I,b-C*I),a.push(v,g,y,p),l++):(a.push(x+(G-x)*I,b+(W-b)*I),a.push(v,g,y,p),a.push(x-(G-x)*D,b-(W-b)*D),a.push(v,g,y,p))}}m=r[2*(h-2)],_=r[2*(h-2)+1],x=r[2*(h-1)],b=r[2*(h-1)+1],E=-(_-b),S=m-x,R=Math.sqrt(E*E+S*S),E/=R,S/=R,E*=d,S*=d,a.push(x-E*I,b-S*I),a.push(v,g,y,p),a.push(x+E*D,b+S*D),a.push(v,g,y,p),u.push(c);for(var H=0;H<l;++H)u.push(c++);u.push(c-1)}(t,e)};var Y=t("../../../math"),V=t("../../../utils")},{"../../../math":70,"../../../utils":125}],62:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t,e,r){t.points=t.shape.points.slice();var i=t.points;if(t.fill&&6<=i.length){for(var n=[],o=t.holes,s=0;s<o.length;s++){var a=o[s];n.push(i.length/2),i=i.concat(a.points)}var u=e.points,h=e.indices,l=i.length/2,c=(0,b.hex2rgb)(t.fillColor),d=t.fillAlpha,f=c[0]*d,p=c[1]*d,v=c[2]*d,g=(0,T.default)(i,n,2);if(!g)return;for(var y=u.length/6,m=0;m<g.length;m+=3)h.push(g[m]+y),h.push(g[m]+y),h.push(g[m+1]+y),h.push(g[m+2]+y),h.push(g[m+2]+y);for(var _=0;_<l;_++)u.push(i[2*_],i[2*_+1],f,p,v,d)}0<t.lineWidth&&(0,x.default)(t,e,r)};var x=i(t("./buildLine")),b=t("../../../utils"),T=i(t("earcut"));function i(t){return t&&t.__esModule?t:{default:t}}},{"../../../utils":125,"./buildLine":61,earcut:2}],63:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t,e,r){var i=t.shape,n=i.x,o=i.y,s=i.width,a=i.height;if(t.fill){var u=(0,m.hex2rgb)(t.fillColor),h=t.fillAlpha,l=u[0]*h,c=u[1]*h,d=u[2]*h,f=e.points,p=e.indices,v=f.length/6;f.push(n,o),f.push(l,c,d,h),f.push(n+s,o),f.push(l,c,d,h),f.push(n,o+a),f.push(l,c,d,h),f.push(n+s,o+a),f.push(l,c,d,h),p.push(v,v,1+v,2+v,3+v,3+v)}if(t.lineWidth){var g=t.points;t.points=[n,o,n+s,o,n+s,o+a,n,o+a,n,o],(0,y.default)(t,e,r),t.points=g}};var i,n=t("./buildLine"),y=(i=n)&&i.__esModule?i:{default:i},m=t("../../../utils")},{"../../../utils":125,"./buildLine":61}],64:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t,e,r){var i=t.shape,n=i.x,o=i.y,s=i.width,a=i.height,u=i.radius,h=[];if(h.push(n+u,o),M(n+s-u,o,n+s,o,n+s,o+u,h),M(n+s,o+a-u,n+s,o+a,n+s-u,o+a,h),M(n+u,o+a,n,o+a,n,o+a-u,h),M(n,o+u,n,o,n+u+1e-10,o,h),t.fill){for(var l=(0,O.hex2rgb)(t.fillColor),c=t.fillAlpha,d=l[0]*c,f=l[1]*c,p=l[2]*c,v=e.points,g=e.indices,y=v.length/6,m=(0,E.default)(h,null,2),_=0,x=m.length;_<x;_+=3)g.push(m[_]+y),g.push(m[_]+y),g.push(m[_+1]+y),g.push(m[_+2]+y),g.push(m[_+2]+y);for(var b=0,T=h.length;b<T;b++)v.push(h[b],h[++b],d,f,p,c)}if(t.lineWidth){var w=t.points;t.points=h,(0,S.default)(t,e,r),t.points=w}};var E=i(t("earcut")),S=i(t("./buildLine")),O=t("../../../utils");function i(t){return t&&t.__esModule?t:{default:t}}function g(t,e,r){return t+(e-t)*r}function M(t,e,r,i,n,o,s){for(var a=6<arguments.length&&void 0!==s?s:[],u=0,h=0,l=0,c=0,d=0,f=0,p=0,v=0;p<=20;++p)u=g(t,r,v=p/20),h=g(e,i,v),l=g(r,n,v),c=g(i,o,v),d=g(u,l,v),f=g(h,c,v),a.push(d,f);return a}},{"../../../utils":125,"./buildLine":61,earcut:2}],65:[function(t,e,r){"use strict";r.__esModule=!0,r.autoDetectRenderer=r.Application=r.Filter=r.SpriteMaskFilter=r.Quad=r.RenderTarget=r.ObjectRenderer=r.WebGLManager=r.Shader=r.CanvasRenderTarget=r.TextureUvs=r.VideoBaseTexture=r.BaseRenderTexture=r.RenderTexture=r.BaseTexture=r.TextureMatrix=r.Texture=r.Spritesheet=r.CanvasGraphicsRenderer=r.GraphicsRenderer=r.GraphicsData=r.Graphics=r.TextMetrics=r.TextStyle=r.Text=r.SpriteRenderer=r.CanvasTinter=r.CanvasSpriteRenderer=r.Sprite=r.TransformBase=r.TransformStatic=r.Transform=r.Container=r.DisplayObject=r.Bounds=r.glCore=r.WebGLRenderer=r.CanvasRenderer=r.ticker=r.utils=r.settings=void 0;var i=t("./const");Object.keys(i).forEach(function(t){"default"!==t&&"__esModule"!==t&&Object.defineProperty(r,t,{enumerable:!0,get:function(){return i[t]}})});var n=t("./math");Object.keys(n).forEach(function(t){"default"!==t&&"__esModule"!==t&&Object.defineProperty(r,t,{enumerable:!0,get:function(){return n[t]}})});var o=t("pixi-gl-core");Object.defineProperty(r,"glCore",{enumerable:!0,get:function(){return z(o).default}});var s=t("./display/Bounds");Object.defineProperty(r,"Bounds",{enumerable:!0,get:function(){return z(s).default}});var a=t("./display/DisplayObject");Object.defineProperty(r,"DisplayObject",{enumerable:!0,get:function(){return z(a).default}});var u=t("./display/Container");Object.defineProperty(r,"Container",{enumerable:!0,get:function(){return z(u).default}});var h=t("./display/Transform");Object.defineProperty(r,"Transform",{enumerable:!0,get:function(){return z(h).default}});var l=t("./display/TransformStatic");Object.defineProperty(r,"TransformStatic",{enumerable:!0,get:function(){return z(l).default}});var c=t("./display/TransformBase");Object.defineProperty(r,"TransformBase",{enumerable:!0,get:function(){return z(c).default}});var d=t("./sprites/Sprite");Object.defineProperty(r,"Sprite",{enumerable:!0,get:function(){return z(d).default}});var f=t("./sprites/canvas/CanvasSpriteRenderer");Object.defineProperty(r,"CanvasSpriteRenderer",{enumerable:!0,get:function(){return z(f).default}});var p=t("./sprites/canvas/CanvasTinter");Object.defineProperty(r,"CanvasTinter",{enumerable:!0,get:function(){return z(p).default}});var v=t("./sprites/webgl/SpriteRenderer");Object.defineProperty(r,"SpriteRenderer",{enumerable:!0,get:function(){return z(v).default}});var g=t("./text/Text");Object.defineProperty(r,"Text",{enumerable:!0,get:function(){return z(g).default}});var y=t("./text/TextStyle");Object.defineProperty(r,"TextStyle",{enumerable:!0,get:function(){return z(y).default}});var m=t("./text/TextMetrics");Object.defineProperty(r,"TextMetrics",{enumerable:!0,get:function(){return z(m).default}});var _=t("./graphics/Graphics");Object.defineProperty(r,"Graphics",{enumerable:!0,get:function(){return z(_).default}});var x=t("./graphics/GraphicsData");Object.defineProperty(r,"GraphicsData",{enumerable:!0,get:function(){return z(x).default}});var b=t("./graphics/webgl/GraphicsRenderer");Object.defineProperty(r,"GraphicsRenderer",{enumerable:!0,get:function(){return z(b).default}});var T=t("./graphics/canvas/CanvasGraphicsRenderer");Object.defineProperty(r,"CanvasGraphicsRenderer",{enumerable:!0,get:function(){return z(T).default}});var w=t("./textures/Spritesheet");Object.defineProperty(r,"Spritesheet",{enumerable:!0,get:function(){return z(w).default}});var E=t("./textures/Texture");Object.defineProperty(r,"Texture",{enumerable:!0,get:function(){return z(E).default}});var S=t("./textures/TextureMatrix");Object.defineProperty(r,"TextureMatrix",{enumerable:!0,get:function(){return z(S).default}});var O=t("./textures/BaseTexture");Object.defineProperty(r,"BaseTexture",{enumerable:!0,get:function(){return z(O).default}});var M=t("./textures/RenderTexture");Object.defineProperty(r,"RenderTexture",{enumerable:!0,get:function(){return z(M).default}});var P=t("./textures/BaseRenderTexture");Object.defineProperty(r,"BaseRenderTexture",{enumerable:!0,get:function(){return z(P).default}});var C=t("./textures/VideoBaseTexture");Object.defineProperty(r,"VideoBaseTexture",{enumerable:!0,get:function(){return z(C).default}});var R=t("./textures/TextureUvs");Object.defineProperty(r,"TextureUvs",{enumerable:!0,get:function(){return z(R).default}});var A=t("./renderers/canvas/utils/CanvasRenderTarget");Object.defineProperty(r,"CanvasRenderTarget",{enumerable:!0,get:function(){return z(A).default}});var I=t("./Shader");Object.defineProperty(r,"Shader",{enumerable:!0,get:function(){return z(I).default}});var D=t("./renderers/webgl/managers/WebGLManager");Object.defineProperty(r,"WebGLManager",{enumerable:!0,get:function(){return z(D).default}});var L=t("./renderers/webgl/utils/ObjectRenderer");Object.defineProperty(r,"ObjectRenderer",{enumerable:!0,get:function(){return z(L).default}});var N=t("./renderers/webgl/utils/RenderTarget");Object.defineProperty(r,"RenderTarget",{enumerable:!0,get:function(){return z(N).default}});var B=t("./renderers/webgl/utils/Quad");Object.defineProperty(r,"Quad",{enumerable:!0,get:function(){return z(B).default}});var k=t("./renderers/webgl/filters/spriteMask/SpriteMaskFilter");Object.defineProperty(r,"SpriteMaskFilter",{enumerable:!0,get:function(){return z(k).default}});var F=t("./renderers/webgl/filters/Filter");Object.defineProperty(r,"Filter",{enumerable:!0,get:function(){return z(F).default}});var j=t("./Application");Object.defineProperty(r,"Application",{enumerable:!0,get:function(){return z(j).default}});var U=t("./autoDetectRenderer");Object.defineProperty(r,"autoDetectRenderer",{enumerable:!0,get:function(){return U.autoDetectRenderer}});var X=V(t("./utils")),G=V(t("./ticker")),W=z(t("./settings")),H=z(t("./renderers/canvas/CanvasRenderer")),Y=z(t("./renderers/webgl/WebGLRenderer"));function V(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}function z(t){return t&&t.__esModule?t:{default:t}}r.settings=W.default,r.utils=X,r.ticker=G,r.CanvasRenderer=H.default,r.WebGLRenderer=Y.default},{"./Application":43,"./Shader":44,"./autoDetectRenderer":45,"./const":46,"./display/Bounds":47,"./display/Container":48,"./display/DisplayObject":49,"./display/Transform":50,"./display/TransformBase":51,"./display/TransformStatic":52,"./graphics/Graphics":53,"./graphics/GraphicsData":54,"./graphics/canvas/CanvasGraphicsRenderer":55,"./graphics/webgl/GraphicsRenderer":57,"./math":70,"./renderers/canvas/CanvasRenderer":77,"./renderers/canvas/utils/CanvasRenderTarget":79,"./renderers/webgl/WebGLRenderer":84,"./renderers/webgl/filters/Filter":86,"./renderers/webgl/filters/spriteMask/SpriteMaskFilter":89,"./renderers/webgl/managers/WebGLManager":93,"./renderers/webgl/utils/ObjectRenderer":94,"./renderers/webgl/utils/Quad":95,"./renderers/webgl/utils/RenderTarget":96,"./settings":101,"./sprites/Sprite":102,"./sprites/canvas/CanvasSpriteRenderer":103,"./sprites/canvas/CanvasTinter":104,"./sprites/webgl/SpriteRenderer":106,"./text/Text":108,"./text/TextMetrics":109,"./text/TextStyle":110,"./textures/BaseRenderTexture":111,"./textures/BaseTexture":112,"./textures/RenderTexture":113,"./textures/Spritesheet":114,"./textures/Texture":115,"./textures/TextureMatrix":116,"./textures/TextureUvs":117,"./textures/VideoBaseTexture":118,"./ticker":121,"./utils":125,"pixi-gl-core":15}],66:[function(t,e,r){"use strict";r.__esModule=!0;var i,n=t("./Matrix"),l=(i=n)&&i.__esModule?i:{default:i};var c=[1,1,0,-1,-1,-1,0,1,1,1,0,-1,-1,-1,0,1],d=[0,1,1,1,0,-1,-1,-1,0,1,1,1,0,-1,-1,-1],f=[0,-1,-1,-1,0,1,1,1,0,1,1,1,0,-1,-1,-1],p=[1,1,0,-1,-1,-1,0,1,-1,-1,0,1,1,1,0,-1],v=[],g=[];function y(t){return t<0?-1:0<t?1:0}!function(){for(var t=0;t<16;t++){var e=[];g.push(e);for(var r=0;r<16;r++)for(var i=y(c[t]*c[r]+f[t]*d[r]),n=y(d[t]*c[r]+p[t]*d[r]),o=y(c[t]*f[r]+f[t]*p[r]),s=y(d[t]*f[r]+p[t]*p[r]),a=0;a<16;a++)if(c[a]===i&&d[a]===n&&f[a]===o&&p[a]===s){e.push(a);break}}for(var u=0;u<16;u++){var h=new l.default;h.set(c[u],d[u],f[u],p[u],0,0),v.push(h)}}();var a={E:0,SE:1,S:2,SW:3,W:4,NW:5,N:6,NE:7,MIRROR_VERTICAL:8,MIRROR_HORIZONTAL:12,uX:function(t){return c[t]},uY:function(t){return d[t]},vX:function(t){return f[t]},vY:function(t){return p[t]},inv:function(t){return 8&t?15&t:7&-t},add:function(t,e){return g[t][e]},sub:function(t,e){return g[t][a.inv(e)]},rotate180:function(t){return 4^t},isVertical:function(t){return 2==(3&t)},byDirection:function(t,e){return 2*Math.abs(t)<=Math.abs(e)?0<=e?a.S:a.N:2*Math.abs(e)<=Math.abs(t)?0<t?a.E:a.W:0<e?0<t?a.SE:a.SW:0<t?a.NE:a.NW},matrixAppendRotationInv:function(t,e,r,i){var n=2<arguments.length&&void 0!==r?r:0,o=3<arguments.length&&void 0!==i?i:0,s=v[a.inv(e)];s.tx=n,s.ty=o,t.append(s)}};r.default=a},{"./Matrix":67}],67:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o,s=t("./Point"),a=(o=s)&&o.__esModule?o:{default:o},u=t("../const");var h=(l.prototype.fromArray=function(t){this.a=t[0],this.b=t[1],this.c=t[3],this.d=t[4],this.tx=t[2],this.ty=t[5]},l.prototype.set=function(t,e,r,i,n,o){return this.a=t,this.b=e,this.c=r,this.d=i,this.tx=n,this.ty=o,this},l.prototype.toArray=function(t,e){this.array||(this.array=new Float32Array(9));var r=e||this.array;return t?(r[0]=this.a,r[1]=this.b,r[2]=0,r[3]=this.c,r[4]=this.d,r[5]=0,r[6]=this.tx,r[7]=this.ty):(r[0]=this.a,r[1]=this.c,r[2]=this.tx,r[3]=this.b,r[4]=this.d,r[5]=this.ty,r[6]=0,r[7]=0),r[8]=1,r},l.prototype.apply=function(t,e){e=e||new a.default;var r=t.x,i=t.y;return e.x=this.a*r+this.c*i+this.tx,e.y=this.b*r+this.d*i+this.ty,e},l.prototype.applyInverse=function(t,e){e=e||new a.default;var r=1/(this.a*this.d+this.c*-this.b),i=t.x,n=t.y;return e.x=this.d*r*i+-this.c*r*n+(this.ty*this.c-this.tx*this.d)*r,e.y=this.a*r*n+-this.b*r*i+(-this.ty*this.a+this.tx*this.b)*r,e},l.prototype.translate=function(t,e){return this.tx+=t,this.ty+=e,this},l.prototype.scale=function(t,e){return this.a*=t,this.d*=e,this.c*=t,this.b*=e,this.tx*=t,this.ty*=e,this},l.prototype.rotate=function(t){var e=Math.cos(t),r=Math.sin(t),i=this.a,n=this.c,o=this.tx;return this.a=i*e-this.b*r,this.b=i*r+this.b*e,this.c=n*e-this.d*r,this.d=n*r+this.d*e,this.tx=o*e-this.ty*r,this.ty=o*r+this.ty*e,this},l.prototype.append=function(t){var e=this.a,r=this.b,i=this.c,n=this.d;return this.a=t.a*e+t.b*i,this.b=t.a*r+t.b*n,this.c=t.c*e+t.d*i,this.d=t.c*r+t.d*n,this.tx=t.tx*e+t.ty*i+this.tx,this.ty=t.tx*r+t.ty*n+this.ty,this},l.prototype.setTransform=function(t,e,r,i,n,o,s,a,u){return this.a=Math.cos(s+u)*n,this.b=Math.sin(s+u)*n,this.c=-Math.sin(s-a)*o,this.d=Math.cos(s-a)*o,this.tx=t-(r*this.a+i*this.c),this.ty=e-(r*this.b+i*this.d),this},l.prototype.prepend=function(t){var e=this.tx;if(1!==t.a||0!==t.b||0!==t.c||1!==t.d){var r=this.a,i=this.c;this.a=r*t.a+this.b*t.c,this.b=r*t.b+this.b*t.d,this.c=i*t.a+this.d*t.c,this.d=i*t.b+this.d*t.d}return this.tx=e*t.a+this.ty*t.c+t.tx,this.ty=e*t.b+this.ty*t.d+t.ty,this},l.prototype.decompose=function(t){var e=this.a,r=this.b,i=this.c,n=this.d,o=-Math.atan2(-i,n),s=Math.atan2(r,e),a=Math.abs(o+s);return a<1e-5||Math.abs(u.PI_2-a)<1e-5?(t.rotation=s,t.skew.x=t.skew.y=0):(t.rotation=0,t.skew.x=o,t.skew.y=s),t.scale.x=Math.sqrt(e*e+r*r),t.scale.y=Math.sqrt(i*i+n*n),t.position.x=this.tx,t.position.y=this.ty,t},l.prototype.invert=function(){var t=this.a,e=this.b,r=this.c,i=this.d,n=this.tx,o=t*i-e*r;return this.a=i/o,this.b=-e/o,this.c=-r/o,this.d=t/o,this.tx=(r*this.ty-i*n)/o,this.ty=-(t*this.ty-e*n)/o,this},l.prototype.identity=function(){return this.a=1,this.b=0,this.c=0,this.d=1,this.tx=0,this.ty=0,this},l.prototype.clone=function(){var t=new l;return t.a=this.a,t.b=this.b,t.c=this.c,t.d=this.d,t.tx=this.tx,t.ty=this.ty,t},l.prototype.copy=function(t){return t.a=this.a,t.b=this.b,t.c=this.c,t.d=this.d,t.tx=this.tx,t.ty=this.ty,t},i(l,null,[{key:"IDENTITY",get:function(){return new l}},{key:"TEMP_MATRIX",get:function(){return new l}}]),l);function l(){var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:1,e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:0,r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:0,i=3<arguments.length&&void 0!==arguments[3]?arguments[3]:1,n=4<arguments.length&&void 0!==arguments[4]?arguments[4]:0,o=5<arguments.length&&void 0!==arguments[5]?arguments[5]:0;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),this.a=t,this.b=e,this.c=r,this.d=i,this.tx=n,this.ty=o,this.array=null}r.default=h},{"../const":46,"./Point":69}],68:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o=(s.prototype.clone=function(t,e){var r=1<arguments.length&&void 0!==e?e:null;return new s((0<arguments.length&&void 0!==t?t:null)||this.cb,r||this.scope,this._x,this._y)},s.prototype.set=function(t,e){var r=t||0,i=e||(0!==e?r:0);this._x===r&&this._y===i||(this._x=r,this._y=i,this.cb.call(this.scope))},s.prototype.copy=function(t){this._x===t.x&&this._y===t.y||(this._x=t.x,this._y=t.y,this.cb.call(this.scope))},s.prototype.equals=function(t){return t.x===this._x&&t.y===this._y},i(s,[{key:"x",get:function(){return this._x},set:function(t){this._x!==t&&(this._x=t,this.cb.call(this.scope))}},{key:"y",get:function(){return this._y},set:function(t){this._y!==t&&(this._y=t,this.cb.call(this.scope))}}]),s);function s(t,e){var r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:0,i=3<arguments.length&&void 0!==arguments[3]?arguments[3]:0;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,s),this._x=r,this._y=i,this.cb=t,this.scope=e}r.default=o},{}],69:[function(t,e,r){"use strict";r.__esModule=!0;var i=(n.prototype.clone=function(){return new n(this.x,this.y)},n.prototype.copy=function(t){this.set(t.x,t.y)},n.prototype.equals=function(t){return t.x===this.x&&t.y===this.y},n.prototype.set=function(t,e){this.x=t||0,this.y=e||(0!==e?this.x:0)},n);function n(){var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:0,e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:0;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,n),this.x=t,this.y=e}r.default=i},{}],70:[function(t,e,r){"use strict";r.__esModule=!0;var i=t("./Point");Object.defineProperty(r,"Point",{enumerable:!0,get:function(){return d(i).default}});var n=t("./ObservablePoint");Object.defineProperty(r,"ObservablePoint",{enumerable:!0,get:function(){return d(n).default}});var o=t("./Matrix");Object.defineProperty(r,"Matrix",{enumerable:!0,get:function(){return d(o).default}});var s=t("./GroupD8");Object.defineProperty(r,"GroupD8",{enumerable:!0,get:function(){return d(s).default}});var a=t("./shapes/Circle");Object.defineProperty(r,"Circle",{enumerable:!0,get:function(){return d(a).default}});var u=t("./shapes/Ellipse");Object.defineProperty(r,"Ellipse",{enumerable:!0,get:function(){return d(u).default}});var h=t("./shapes/Polygon");Object.defineProperty(r,"Polygon",{enumerable:!0,get:function(){return d(h).default}});var l=t("./shapes/Rectangle");Object.defineProperty(r,"Rectangle",{enumerable:!0,get:function(){return d(l).default}});var c=t("./shapes/RoundedRectangle");function d(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(r,"RoundedRectangle",{enumerable:!0,get:function(){return d(c).default}})},{"./GroupD8":66,"./Matrix":67,"./ObservablePoint":68,"./Point":69,"./shapes/Circle":71,"./shapes/Ellipse":72,"./shapes/Polygon":73,"./shapes/Rectangle":74,"./shapes/RoundedRectangle":75}],71:[function(t,e,r){"use strict";r.__esModule=!0;var i,n=t("./Rectangle"),o=(i=n)&&i.__esModule?i:{default:i},s=t("../../const");var a=(u.prototype.clone=function(){return new u(this.x,this.y,this.radius)},u.prototype.contains=function(t,e){if(this.radius<=0)return!1;var r=this.radius*this.radius,i=this.x-t,n=this.y-e;return(i*=i)+(n*=n)<=r},u.prototype.getBounds=function(){return new o.default(this.x-this.radius,this.y-this.radius,2*this.radius,2*this.radius)},u);function u(){var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:0,e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:0,r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:0;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,u),this.x=t,this.y=e,this.radius=r,this.type=s.SHAPES.CIRC}r.default=a},{"../../const":46,"./Rectangle":74}],72:[function(t,e,r){"use strict";r.__esModule=!0;var i,n=t("./Rectangle"),o=(i=n)&&i.__esModule?i:{default:i},s=t("../../const");var a=(u.prototype.clone=function(){return new u(this.x,this.y,this.width,this.height)},u.prototype.contains=function(t,e){if(this.width<=0||this.height<=0)return!1;var r=(t-this.x)/this.width,i=(e-this.y)/this.height;return(r*=r)+(i*=i)<=1},u.prototype.getBounds=function(){return new o.default(this.x-this.width,this.y-this.height,this.width,this.height)},u);function u(){var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:0,e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:0,r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:0,i=3<arguments.length&&void 0!==arguments[3]?arguments[3]:0;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,u),this.x=t,this.y=e,this.width=r,this.height=i,this.type=s.SHAPES.ELIP}r.default=a},{"../../const":46,"./Rectangle":74}],73:[function(t,e,r){"use strict";r.__esModule=!0;var i,n=t("../Point"),s=(i=n)&&i.__esModule?i:{default:i},a=t("../../const");var o=(u.prototype.clone=function(){return new u(this.points.slice())},u.prototype.close=function(){var t=this.points;t[0]===t[t.length-2]&&t[1]===t[t.length-1]||t.push(t[0],t[1])},u.prototype.contains=function(t,e){for(var r=!1,i=this.points.length/2,n=0,o=i-1;n<i;o=n++){var s=this.points[2*n],a=this.points[2*n+1],u=this.points[2*o],h=this.points[2*o+1];e<a!=e<h&&t<(e-a)/(h-a)*(u-s)+s&&(r=!r)}return r},u);function u(){for(var t=arguments.length,e=Array(t),r=0;r<t;r++)e[r]=arguments[r];if(!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,u),Array.isArray(e[0])&&(e=e[0]),e[0]instanceof s.default){for(var i=[],n=0,o=e.length;n<o;n++)i.push(e[n].x,e[n].y);e=i}this.closed=!0,this.points=e,this.type=a.SHAPES.POLY}r.default=o},{"../../const":46,"../Point":69}],74:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o=t("../../const");var s=(a.prototype.clone=function(){return new a(this.x,this.y,this.width,this.height)},a.prototype.copy=function(t){return this.x=t.x,this.y=t.y,this.width=t.width,this.height=t.height,this},a.prototype.contains=function(t,e){return!(this.width<=0||this.height<=0)&&t>=this.x&&t<this.x+this.width&&e>=this.y&&e<this.y+this.height},a.prototype.pad=function(t,e){t=t||0,e=e||(0!==e?t:0),this.x-=t,this.y-=e,this.width+=2*t,this.height+=2*e},a.prototype.fit=function(t){var e=Math.max(this.x,t.x),r=Math.min(this.x+this.width,t.x+t.width),i=Math.max(this.y,t.y),n=Math.min(this.y+this.height,t.y+t.height);this.x=e,this.width=Math.max(r-e,0),this.y=i,this.height=Math.max(n-i,0)},a.prototype.enlarge=function(t){var e=Math.min(this.x,t.x),r=Math.max(this.x+this.width,t.x+t.width),i=Math.min(this.y,t.y),n=Math.max(this.y+this.height,t.y+t.height);this.x=e,this.width=r-e,this.y=i,this.height=n-i},a.prototype.ceil=function(t,e){var r=0<arguments.length&&void 0!==t?t:1,i=1<arguments.length&&void 0!==e?e:.001,n=Math.ceil((this.x+this.width-i)*r)/r,o=Math.ceil((this.y+this.height-i)*r)/r;this.x=Math.floor((this.x+i)*r)/r,this.y=Math.floor((this.y+i)*r)/r,this.width=n-this.x,this.height=o-this.y},i(a,[{key:"left",get:function(){return this.x}},{key:"right",get:function(){return this.x+this.width}},{key:"top",get:function(){return this.y}},{key:"bottom",get:function(){return this.y+this.height}}],[{key:"EMPTY",get:function(){return new a(0,0,0,0)}}]),a);function a(){var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:0,e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:0,r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:0,i=3<arguments.length&&void 0!==arguments[3]?arguments[3]:0;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,a),this.x=Number(t),this.y=Number(e),this.width=Number(r),this.height=Number(i),this.type=o.SHAPES.RECT}r.default=s},{"../../const":46}],75:[function(t,e,r){"use strict";r.__esModule=!0;var o=t("../../const");var i=(s.prototype.clone=function(){return new s(this.x,this.y,this.width,this.height,this.radius)},s.prototype.contains=function(t,e){if(this.width<=0||this.height<=0)return!1;if(t>=this.x&&t<=this.x+this.width&&e>=this.y&&e<=this.y+this.height){if(e>=this.y+this.radius&&e<=this.y+this.height-this.radius||t>=this.x+this.radius&&t<=this.x+this.width-this.radius)return!0;var r=t-(this.x+this.radius),i=e-(this.y+this.radius),n=this.radius*this.radius;if(r*r+i*i<=n)return!0;if((r=t-(this.x+this.width-this.radius))*r+i*i<=n)return!0;if(r*r+(i=e-(this.y+this.height-this.radius))*i<=n)return!0;if((r=t-(this.x+this.radius))*r+i*i<=n)return!0}return!1},s);function s(){var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:0,e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:0,r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:0,i=3<arguments.length&&void 0!==arguments[3]?arguments[3]:0,n=4<arguments.length&&void 0!==arguments[4]?arguments[4]:20;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,s),this.x=t,this.y=e,this.width=r,this.height=i,this.radius=n,this.type=o.SHAPES.RREC}r.default=i},{"../../const":46}],76:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o=t("../utils"),s=t("../math"),a=t("../const"),u=d(t("../settings")),h=d(t("../display/Container")),l=d(t("../textures/RenderTexture")),c=d(t("eventemitter3"));function d(t){return t&&t.__esModule?t:{default:t}}var f,p=new s.Matrix,v=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(g,f=c.default),g.prototype.resize=function(t,e){this.screen.width=t,this.screen.height=e,this.view.width=t*this.resolution,this.view.height=e*this.resolution,this.autoResize&&(this.view.style.width=t+"px",this.view.style.height=e+"px")},g.prototype.generateTexture=function(t,e,r,i){i=i||t.getLocalBounds();var n=l.default.create(0|i.width,0|i.height,e,r);return p.tx=-i.x,p.ty=-i.y,this.render(t,n,!1,p,!!t.parent),n},g.prototype.destroy=function(t){t&&this.view.parentNode&&this.view.parentNode.removeChild(this.view),this.type=a.RENDERER_TYPE.UNKNOWN,this.view=null,this.screen=null,this.resolution=0,this.transparent=!1,this.autoResize=!1,this.blendModes=null,this.options=null,this.preserveDrawingBuffer=!1,this.clearBeforeRender=!1,this.roundPixels=!1,this._backgroundColor=0,this._backgroundColorRgba=null,this._backgroundColorString=null,this._tempDisplayObjectParent=null,this._lastObjectRendered=null},i(g,[{key:"width",get:function(){return this.view.width}},{key:"height",get:function(){return this.view.height}},{key:"backgroundColor",get:function(){return this._backgroundColor},set:function(t){this._backgroundColor=t,this._backgroundColorString=(0,o.hex2string)(t),(0,o.hex2rgb)(t,this._backgroundColorRgba)}}]),g);function g(t,e,r,i){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,g);var n=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,f.call(this));return(0,o.sayHello)(t),"number"==typeof e&&(e=Object.assign({width:e,height:r||u.default.RENDER_OPTIONS.height},i)),e=Object.assign({},u.default.RENDER_OPTIONS,e),n.options=e,n.type=a.RENDERER_TYPE.UNKNOWN,n.screen=new s.Rectangle(0,0,e.width,e.height),n.view=e.view||document.createElement("canvas"),n.resolution=e.resolution||u.default.RESOLUTION,n.transparent=e.transparent,n.autoResize=e.autoResize||!1,n.blendModes=null,n.preserveDrawingBuffer=e.preserveDrawingBuffer,n.clearBeforeRender=e.clearBeforeRender,n.roundPixels=e.roundPixels,n._backgroundColor=0,n._backgroundColorRgba=[0,0,0,0],n._backgroundColorString="#000000",n.backgroundColor=e.backgroundColor||n._backgroundColor,n._tempDisplayObjectParent=new h.default,n._lastObjectRendered=n._tempDisplayObjectParent,n}r.default=v},{"../const":46,"../display/Container":48,"../math":70,"../settings":101,"../textures/RenderTexture":113,"../utils":125,eventemitter3:3}],77:[function(t,e,r){"use strict";r.__esModule=!0;var i=u(t("../SystemRenderer")),n=u(t("./utils/CanvasMaskManager")),l=u(t("./utils/CanvasRenderTarget")),o=u(t("./utils/mapCanvasBlendModesToPixi")),s=t("../../utils"),c=t("../../const"),a=u(t("../../settings"));function u(t){return t&&t.__esModule?t:{default:t}}var h,d=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(f,h=i.default),f.prototype.render=function(t,e,r,i,n){if(this.view){this.renderingToScreen=!e,this.emit("prerender");var o=this.resolution;e?((e=e.baseTexture||e)._canvasRenderTarget||(e._canvasRenderTarget=new l.default(e.width,e.height,e.resolution),e.source=e._canvasRenderTarget.canvas,e.valid=!0),this.context=e._canvasRenderTarget.context,this.resolution=e._canvasRenderTarget.resolution):this.context=this.rootContext;var s=this.context;if(e||(this._lastObjectRendered=t),!n){var a=t.parent,u=this._tempDisplayObjectParent.transform.worldTransform;i?(i.copy(u),this._tempDisplayObjectParent.transform._worldID=-1):u.identity(),t.parent=this._tempDisplayObjectParent,t.updateTransform(),t.parent=a}s.save(),s.setTransform(1,0,0,1,0,0),s.globalAlpha=1,this._activeBlendMode=c.BLEND_MODES.NORMAL,s.globalCompositeOperation=this.blendModes[c.BLEND_MODES.NORMAL],navigator.isCocoonJS&&this.view.screencanvas&&(s.fillStyle="black",s.clear()),(void 0!==r?r:this.clearBeforeRender)&&this.renderingToScreen&&(this.transparent?s.clearRect(0,0,this.width,this.height):(s.fillStyle=this._backgroundColorString,s.fillRect(0,0,this.width,this.height)));var h=this.context;this.context=s,t.renderCanvas(this),this.context=h,s.restore(),this.resolution=o,this.emit("postrender")}},f.prototype.clear=function(t){var e=this.context;t=t||this._backgroundColorString,!this.transparent&&t?(e.fillStyle=t,e.fillRect(0,0,this.width,this.height)):e.clearRect(0,0,this.width,this.height)},f.prototype.setBlendMode=function(t){this._activeBlendMode!==t&&(this._activeBlendMode=t,this.context.globalCompositeOperation=this.blendModes[t])},f.prototype.destroy=function(t){this.destroyPlugins(),h.prototype.destroy.call(this,t),this.context=null,this.refresh=!0,this.maskManager.destroy(),this.maskManager=null,this.smoothProperty=null},f.prototype.resize=function(t,e){h.prototype.resize.call(this,t,e),this.smoothProperty&&(this.rootContext[this.smoothProperty]=a.default.SCALE_MODE===c.SCALE_MODES.LINEAR)},f.prototype.invalidateBlendMode=function(){this._activeBlendMode=this.blendModes.indexOf(this.context.globalCompositeOperation)},f);function f(t,e,r){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,f);var i=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,h.call(this,"Canvas",t,e,r));return i.type=c.RENDERER_TYPE.CANVAS,i.rootContext=i.view.getContext("2d",{alpha:i.transparent}),i.context=i.rootContext,i.refresh=!0,i.maskManager=new n.default(i),i.smoothProperty="imageSmoothingEnabled",i.rootContext.imageSmoothingEnabled||(i.rootContext.webkitImageSmoothingEnabled?i.smoothProperty="webkitImageSmoothingEnabled":i.rootContext.mozImageSmoothingEnabled?i.smoothProperty="mozImageSmoothingEnabled":i.rootContext.oImageSmoothingEnabled?i.smoothProperty="oImageSmoothingEnabled":i.rootContext.msImageSmoothingEnabled&&(i.smoothProperty="msImageSmoothingEnabled")),i.initPlugins(),i.blendModes=(0,o.default)(),i._activeBlendMode=null,i.renderingToScreen=!1,i.resize(i.options.width,i.options.height),i}r.default=d,s.pluginTarget.mixin(d)},{"../../const":46,"../../settings":101,"../../utils":125,"../SystemRenderer":76,"./utils/CanvasMaskManager":78,"./utils/CanvasRenderTarget":79,"./utils/mapCanvasBlendModesToPixi":81}],78:[function(t,e,r){"use strict";r.__esModule=!0;var I=t("../../../const");var i=(n.prototype.pushMask=function(t){var e=this.renderer;e.context.save();var r=t.alpha,i=t.transform.worldTransform,n=e.resolution;e.context.setTransform(i.a*n,i.b*n,i.c*n,i.d*n,i.tx*n,i.ty*n),t._texture||(this.renderGraphicsShape(t),e.context.clip()),t.worldAlpha=r},n.prototype.renderGraphicsShape=function(t){var e=this.renderer.context,r=t.graphicsData.length;if(0!==r){e.beginPath();for(var i=0;i<r;i++){var n=t.graphicsData[i],o=n.shape;if(n.type===I.SHAPES.POLY){var s=o.points,a=n.holes,u=void 0,h=void 0;e.moveTo(s[0],s[1]);for(var l=2;l<s.length;l+=2)e.lineTo(s[l],s[l+1]);if(s[0]===s[s.length-2]&&s[1]===s[s.length-1]&&e.closePath(),0<a.length){for(var c=u=0;c<s.length;c+=2)u+=s[c]*s[c+3]-s[c+1]*s[c+2];for(var d=0;d<a.length;d++){s=a[d].points;for(var f=h=0;f<s.length;f+=2)h+=s[f]*s[f+3]-s[f+1]*s[f+2];if(e.moveTo(s[0],s[1]),h*u<0)for(var p=2;p<s.length;p+=2)e.lineTo(s[p],s[p+1]);else for(var v=s.length-2;2<=v;v-=2)e.lineTo(s[v],s[v+1])}}}else if(n.type===I.SHAPES.RECT)e.rect(o.x,o.y,o.width,o.height),e.closePath();else if(n.type===I.SHAPES.CIRC)e.arc(o.x,o.y,o.radius,0,2*Math.PI),e.closePath();else if(n.type===I.SHAPES.ELIP){var g=2*o.width,y=2*o.height,m=o.x-g/2,_=o.y-y/2,x=g/2*.5522848,b=y/2*.5522848,T=m+g,w=_+y,E=m+g/2,S=_+y/2;e.moveTo(m,S),e.bezierCurveTo(m,S-b,E-x,_,E,_),e.bezierCurveTo(E+x,_,T,S-b,T,S),e.bezierCurveTo(T,S+b,E+x,w,E,w),e.bezierCurveTo(E-x,w,m,S+b,m,S),e.closePath()}else if(n.type===I.SHAPES.RREC){var O=o.x,M=o.y,P=o.width,C=o.height,R=o.radius,A=Math.min(P,C)/2|0;R=A<R?A:R,e.moveTo(O,M+R),e.lineTo(O,M+C-R),e.quadraticCurveTo(O,M+C,O+R,M+C),e.lineTo(O+P-R,M+C),e.quadraticCurveTo(O+P,M+C,O+P,M+C-R),e.lineTo(O+P,M+R),e.quadraticCurveTo(O+P,M,O+P-R,M),e.lineTo(O+R,M),e.quadraticCurveTo(O,M,O,M+R),e.closePath()}}}},n.prototype.popMask=function(t){t.context.restore(),t.invalidateBlendMode()},n.prototype.destroy=function(){},n);function n(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,n),this.renderer=t}r.default=i},{"../../../const":46}],79:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o,s=t("../../../settings"),a=(o=s)&&o.__esModule?o:{default:o};var u=(h.prototype.clear=function(){this.context.setTransform(1,0,0,1,0,0),this.context.clearRect(0,0,this.canvas.width,this.canvas.height)},h.prototype.resize=function(t,e){this.canvas.width=t*this.resolution,this.canvas.height=e*this.resolution},h.prototype.destroy=function(){this.context=null,this.canvas=null},i(h,[{key:"width",get:function(){return this.canvas.width},set:function(t){this.canvas.width=t}},{key:"height",get:function(){return this.canvas.height},set:function(t){this.canvas.height=t}}]),h);function h(t,e,r){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,h),this.canvas=document.createElement("canvas"),this.context=this.canvas.getContext("2d"),this.resolution=r||a.default.RESOLUTION,this.resize(t,e)}r.default=u},{"../../../settings":101}],80:[function(t,e,r){"use strict";function s(t){var e=document.createElement("canvas");e.width=6,e.height=1;var r=e.getContext("2d");return r.fillStyle=t,r.fillRect(0,0,6,1),e}r.__esModule=!0,r.default=function(){if("undefined"==typeof document)return!1;var t=s("#ff00ff"),e=s("#ffff00"),r=document.createElement("canvas");r.width=6,r.height=1;var i=r.getContext("2d");i.globalCompositeOperation="multiply",i.drawImage(t,0,0),i.drawImage(e,2,0);var n=i.getImageData(2,0,1,1);if(!n)return!1;var o=n.data;return 255===o[0]&&0===o[1]&&0===o[2]}},{}],81:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(){var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:[];(0,s.default)()?(t[n.BLEND_MODES.NORMAL]="source-over",t[n.BLEND_MODES.ADD]="lighter",t[n.BLEND_MODES.MULTIPLY]="multiply",t[n.BLEND_MODES.SCREEN]="screen",t[n.BLEND_MODES.OVERLAY]="overlay",t[n.BLEND_MODES.DARKEN]="darken",t[n.BLEND_MODES.LIGHTEN]="lighten",t[n.BLEND_MODES.COLOR_DODGE]="color-dodge",t[n.BLEND_MODES.COLOR_BURN]="color-burn",t[n.BLEND_MODES.HARD_LIGHT]="hard-light",t[n.BLEND_MODES.SOFT_LIGHT]="soft-light",t[n.BLEND_MODES.DIFFERENCE]="difference",t[n.BLEND_MODES.EXCLUSION]="exclusion",t[n.BLEND_MODES.HUE]="hue",t[n.BLEND_MODES.SATURATION]="saturate",t[n.BLEND_MODES.COLOR]="color",t[n.BLEND_MODES.LUMINOSITY]="luminosity"):(t[n.BLEND_MODES.NORMAL]="source-over",t[n.BLEND_MODES.ADD]="lighter",t[n.BLEND_MODES.MULTIPLY]="source-over",t[n.BLEND_MODES.SCREEN]="source-over",t[n.BLEND_MODES.OVERLAY]="source-over",t[n.BLEND_MODES.DARKEN]="source-over",t[n.BLEND_MODES.LIGHTEN]="source-over",t[n.BLEND_MODES.COLOR_DODGE]="source-over",t[n.BLEND_MODES.COLOR_BURN]="source-over",t[n.BLEND_MODES.HARD_LIGHT]="source-over",t[n.BLEND_MODES.SOFT_LIGHT]="source-over",t[n.BLEND_MODES.DIFFERENCE]="source-over",t[n.BLEND_MODES.EXCLUSION]="source-over",t[n.BLEND_MODES.HUE]="source-over",t[n.BLEND_MODES.SATURATION]="source-over",t[n.BLEND_MODES.COLOR]="source-over",t[n.BLEND_MODES.LUMINOSITY]="source-over");return t[n.BLEND_MODES.NORMAL_NPM]=t[n.BLEND_MODES.NORMAL],t[n.BLEND_MODES.ADD_NPM]=t[n.BLEND_MODES.ADD],t[n.BLEND_MODES.SCREEN_NPM]=t[n.BLEND_MODES.SCREEN],t};var i,n=t("../../../const"),o=t("./canUseNewCanvasBlendModes"),s=(i=o)&&i.__esModule?i:{default:i}},{"../../../const":46,"./canUseNewCanvasBlendModes":80}],82:[function(t,e,r){"use strict";r.__esModule=!0;var i,n=t("../../const"),o=t("../../settings"),s=(i=o)&&i.__esModule?i:{default:i};var a=(u.prototype.update=function(){this.count++,this.mode!==n.GC_MODES.MANUAL&&(this.checkCount++,this.checkCount>this.checkCountMax&&(this.checkCount=0,this.run()))},u.prototype.run=function(){for(var t=this.renderer.textureManager,e=t._managedTextures,r=!1,i=0;i<e.length;i++){var n=e[i];!n._glRenderTargets&&this.count-n.touched>this.maxIdle&&(t.destroyTexture(n,!0),r=!(e[i]=null))}if(r){for(var o=0,s=0;s<e.length;s++)null!==e[s]&&(e[o++]=e[s]);e.length=o}},u.prototype.unload=function(t){var e=this.renderer.textureManager;t._texture&&t._texture._glRenderTargets&&e.destroyTexture(t._texture,!0);for(var r=t.children.length-1;0<=r;r--)this.unload(t.children[r])},u);function u(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,u),this.renderer=t,this.count=0,this.checkCount=0,this.maxIdle=s.default.GC_MAX_IDLE,this.checkCountMax=s.default.GC_MAX_CHECK_COUNT,this.mode=s.default.GC_MODE}r.default=a},{"../../const":46,"../../settings":101}],83:[function(t,e,r){"use strict";r.__esModule=!0;var i,u=t("pixi-gl-core"),h=t("../../const"),n=t("./utils/RenderTarget"),l=(i=n)&&i.__esModule?i:{default:i},a=t("../../utils");var o=(s.prototype.bindTexture=function(){},s.prototype.getTexture=function(){},s.prototype.updateTexture=function(t,e){var r=this.gl,i=!!t._glRenderTargets;if(!t.hasLoaded)return null;var n=this.renderer.boundTextures;if(void 0===e)for(var o=e=0;o<n.length;++o)if(n[o]===t){e=o;break}n[e]=t,r.activeTexture(r.TEXTURE0+e);var s=t._glTextures[this.renderer.CONTEXT_UID];if(s)i?t._glRenderTargets[this.renderer.CONTEXT_UID].resize(t.width,t.height):s.upload(t.source);else{if(i){var a=new l.default(this.gl,t.width,t.height,t.scaleMode,t.resolution);a.resize(t.width,t.height),s=(t._glRenderTargets[this.renderer.CONTEXT_UID]=a).texture,this.renderer._activeRenderTarget.root||this.renderer._activeRenderTarget.frameBuffer.bind()}else(s=new u.GLTexture(this.gl,null,null,null,null)).bind(e),s.premultiplyAlpha=!0,s.upload(t.source);t._glTextures[this.renderer.CONTEXT_UID]=s,t.on("update",this.updateTexture,this),t.on("dispose",this.destroyTexture,this),this._managedTextures.push(t),t.isPowerOfTwo?(t.mipmap&&s.enableMipmap(),t.wrapMode===h.WRAP_MODES.CLAMP?s.enableWrapClamp():t.wrapMode===h.WRAP_MODES.REPEAT?s.enableWrapRepeat():s.enableWrapMirrorRepeat()):s.enableWrapClamp(),t.scaleMode===h.SCALE_MODES.NEAREST?s.enableNearestScaling():s.enableLinearScaling()}return s},s.prototype.destroyTexture=function(t,e){if((t=t.baseTexture||t).hasLoaded){var r=this.renderer,i=r.CONTEXT_UID,n=t._glTextures,o=t._glRenderTargets;if(n[i]&&(r.unbindTexture(t),n[i].destroy(),t.off("update",this.updateTexture,this),t.off("dispose",this.destroyTexture,this),delete n[i],!e)){var s=this._managedTextures.indexOf(t);-1!==s&&(0,a.removeItems)(this._managedTextures,s,1)}o&&o[i]&&(r._activeRenderTarget===o[i]&&r.bindRenderTarget(r.rootRenderTarget),o[i].destroy(),delete o[i])}},s.prototype.removeAll=function(){for(var t=0;t<this._managedTextures.length;++t){var e=this._managedTextures[t];e._glTextures[this.renderer.CONTEXT_UID]&&delete e._glTextures[this.renderer.CONTEXT_UID]}},s.prototype.destroy=function(){for(var t=0;t<this._managedTextures.length;++t){var e=this._managedTextures[t];this.destroyTexture(e,!0),e.off("update",this.updateTexture,this),e.off("dispose",this.destroyTexture,this)}this._managedTextures=null},s);function s(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,s),this.renderer=t,this.gl=t.gl,this._managedTextures=[]}r.default=o},{"../../const":46,"../../utils":125,"./utils/RenderTarget":96,"pixi-gl-core":15}],84:[function(t,e,r){"use strict";r.__esModule=!0;var i=m(t("../SystemRenderer")),n=m(t("./managers/MaskManager")),o=m(t("./managers/StencilManager")),s=m(t("./managers/FilterManager")),a=m(t("./utils/RenderTarget")),u=m(t("./utils/ObjectRenderer")),h=m(t("./TextureManager")),l=m(t("../../textures/BaseTexture")),c=m(t("./TextureGarbageCollector")),d=m(t("./WebGLState")),f=m(t("./utils/mapWebGLDrawModesToPixi")),p=m(t("./utils/validateContext")),v=t("../../utils"),g=m(t("pixi-gl-core")),y=t("../../const");function m(t){return t&&t.__esModule?t:{default:t}}var _,x=0,b=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(T,_=i.default),T.prototype._initContext=function(){var t=this.gl;t.isContextLost()&&t.getExtension("WEBGL_lose_context")&&t.getExtension("WEBGL_lose_context").restoreContext();var e=t.getParameter(t.MAX_TEXTURE_IMAGE_UNITS);this._activeShader=null,this._activeVao=null,this.boundTextures=new Array(e),this.emptyTextures=new Array(e),this._unknownBoundTextures=!1,this.textureManager=new h.default(this),this.filterManager=new s.default(this),this.textureGC=new c.default(this),this.state.resetToDefault(),this.rootRenderTarget=new a.default(t,this.width,this.height,null,this.resolution,!0),this.rootRenderTarget.clearColor=this._backgroundColorRgba,this.bindRenderTarget(this.rootRenderTarget);var r=new g.default.GLTexture.fromData(t,null,1,1),i={_glTextures:{}};i._glTextures[this.CONTEXT_UID]={};for(var n=0;n<e;n++){var o=new l.default;o._glTextures[this.CONTEXT_UID]=r,this.boundTextures[n]=i,this.emptyTextures[n]=o,this.bindTexture(null,n)}this.emit("context",t),this.resize(this.screen.width,this.screen.height)},T.prototype.render=function(t,e,r,i,n){if(this.renderingToScreen=!e,this.emit("prerender"),this.gl&&!this.gl.isContextLost()){if(this._nextTextureLocation=0,e||(this._lastObjectRendered=t),!n){var o=t.parent;t.parent=this._tempDisplayObjectParent,t.updateTransform(),t.parent=o}this.bindRenderTexture(e,i),this.currentRenderer.start(),(void 0!==r?r:this.clearBeforeRender)&&this._activeRenderTarget.clear(),t.renderWebGL(this),this.currentRenderer.flush(),this.textureGC.update(),this.emit("postrender")}},T.prototype.setObjectRenderer=function(t){this.currentRenderer!==t&&(this.currentRenderer.stop(),this.currentRenderer=t,this.currentRenderer.start())},T.prototype.flush=function(){this.setObjectRenderer(this.emptyRenderer)},T.prototype.resize=function(t,e){i.default.prototype.resize.call(this,t,e),this.rootRenderTarget.resize(t,e),this._activeRenderTarget===this.rootRenderTarget&&(this.rootRenderTarget.activate(),this._activeShader&&(this._activeShader.uniforms.projectionMatrix=this.rootRenderTarget.projectionMatrix.toArray(!0)))},T.prototype.setBlendMode=function(t){this.state.setBlendMode(t)},T.prototype.clear=function(t){this._activeRenderTarget.clear(t)},T.prototype.setTransform=function(t){this._activeRenderTarget.transform=t},T.prototype.clearRenderTexture=function(t,e){var r=t.baseTexture._glRenderTargets[this.CONTEXT_UID];return r&&r.clear(e),this},T.prototype.bindRenderTexture=function(t,e){var r=void 0;if(t){var i=t.baseTexture;i._glRenderTargets[this.CONTEXT_UID]||this.textureManager.updateTexture(i,0),this.unbindTexture(i),(r=i._glRenderTargets[this.CONTEXT_UID]).setFrame(t.frame)}else r=this.rootRenderTarget;return r.transform=e,this.bindRenderTarget(r),this},T.prototype.bindRenderTarget=function(t){return t!==this._activeRenderTarget&&((this._activeRenderTarget=t).activate(),this._activeShader&&(this._activeShader.uniforms.projectionMatrix=t.projectionMatrix.toArray(!0)),this.stencilManager.setMaskStack(t.stencilMaskStack)),this},T.prototype.bindShader=function(t,e){return this._activeShader!==t&&((this._activeShader=t).bind(),!1!==e&&(t.uniforms.projectionMatrix=this._activeRenderTarget.projectionMatrix.toArray(!0))),this},T.prototype.bindTexture=function(t,e,r){if((t=(t=t||this.emptyTextures[e]).baseTexture||t).touched=this.textureGC.count,r)e=e||0;else{for(var i=0;i<this.boundTextures.length;i++)if(this.boundTextures[i]===t)return i;void 0===e&&(this._nextTextureLocation++,this._nextTextureLocation%=this.boundTextures.length,e=this.boundTextures.length-this._nextTextureLocation-1)}var n=this.gl,o=t._glTextures[this.CONTEXT_UID];return o?(this.boundTextures[e]=t,n.activeTexture(n.TEXTURE0+e),n.bindTexture(n.TEXTURE_2D,o.texture)):this.textureManager.updateTexture(t,e),e},T.prototype.unbindTexture=function(t){var e=this.gl;if(t=t.baseTexture||t,this._unknownBoundTextures){this._unknownBoundTextures=!1;for(var r=0;r<this.boundTextures.length;r++)this.boundTextures[r]===this.emptyTextures[r]&&(e.activeTexture(e.TEXTURE0+r),e.bindTexture(e.TEXTURE_2D,this.emptyTextures[r]._glTextures[this.CONTEXT_UID].texture))}for(var i=0;i<this.boundTextures.length;i++)this.boundTextures[i]===t&&(this.boundTextures[i]=this.emptyTextures[i],e.activeTexture(e.TEXTURE0+i),e.bindTexture(e.TEXTURE_2D,this.emptyTextures[i]._glTextures[this.CONTEXT_UID].texture));return this},T.prototype.createVao=function(){return new g.default.VertexArrayObject(this.gl,this.state.attribState)},T.prototype.bindVao=function(t){return this._activeVao===t||(t?t.bind():this._activeVao&&this._activeVao.unbind(),this._activeVao=t),this},T.prototype.reset=function(){this.setObjectRenderer(this.emptyRenderer),this.bindVao(null),this._activeShader=null,this._activeRenderTarget=this.rootRenderTarget,this._unknownBoundTextures=!0;for(var t=0;t<this.boundTextures.length;t++)this.boundTextures[t]=this.emptyTextures[t];return this.rootRenderTarget.activate(),this.state.resetToDefault(),this},T.prototype.handleContextLost=function(t){t.preventDefault()},T.prototype.handleContextRestored=function(){this.textureManager.removeAll(),this.filterManager.destroy(!0),this._initContext()},T.prototype.destroy=function(t){this.destroyPlugins(),this.view.removeEventListener("webglcontextlost",this.handleContextLost),this.view.removeEventListener("webglcontextrestored",this.handleContextRestored),this.textureManager.destroy(),_.prototype.destroy.call(this,t),this.uid=0,this.maskManager.destroy(),this.stencilManager.destroy(),this.filterManager.destroy(),this.maskManager=null,this.filterManager=null,this.textureManager=null,this.currentRenderer=null,this.handleContextLost=null,this.handleContextRestored=null,this._contextOptions=null,this.gl.useProgram(null),this.gl.getExtension("WEBGL_lose_context")&&this.gl.getExtension("WEBGL_lose_context").loseContext(),this.gl=null},T);function T(t,e,r){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,T);var i=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,_.call(this,"WebGL",t,e,r));return i.legacy=i.options.legacy,i.legacy&&(g.default.VertexArrayObject.FORCE_NATIVE=!0),i.type=y.RENDERER_TYPE.WEBGL,i.handleContextLost=i.handleContextLost.bind(i),i.handleContextRestored=i.handleContextRestored.bind(i),i.view.addEventListener("webglcontextlost",i.handleContextLost,!1),i.view.addEventListener("webglcontextrestored",i.handleContextRestored,!1),i._contextOptions={alpha:i.transparent,antialias:i.options.antialias,premultipliedAlpha:i.transparent&&"notMultiplied"!==i.transparent,stencil:!0,preserveDrawingBuffer:i.options.preserveDrawingBuffer,powerPreference:i.options.powerPreference},i._backgroundColorRgba[3]=i.transparent?0:1,i.maskManager=new n.default(i),i.stencilManager=new o.default(i),i.emptyRenderer=new u.default(i),i.currentRenderer=i.emptyRenderer,i.textureManager=null,i.filterManager=null,i.initPlugins(),i.options.context&&(0,p.default)(i.options.context),i.gl=i.options.context||g.default.createContext(i.view,i._contextOptions),i.CONTEXT_UID=x++,i.state=new d.default(i.gl),i.renderingToScreen=!0,i.boundTextures=null,i._activeShader=null,i._activeVao=null,i._activeRenderTarget=null,i._initContext(),i.drawModes=(0,f.default)(i.gl),i._nextTextureLocation=0,i.setBlendMode(0),i}r.default=b,v.pluginTarget.mixin(b)},{"../../const":46,"../../textures/BaseTexture":112,"../../utils":125,"../SystemRenderer":76,"./TextureGarbageCollector":82,"./TextureManager":83,"./WebGLState":85,"./managers/FilterManager":90,"./managers/MaskManager":91,"./managers/StencilManager":92,"./utils/ObjectRenderer":94,"./utils/RenderTarget":96,"./utils/mapWebGLDrawModesToPixi":99,"./utils/validateContext":100,"pixi-gl-core":15}],85:[function(t,e,r){"use strict";r.__esModule=!0;var i,n=t("./utils/mapWebGLBlendModesToPixi"),o=(i=n)&&i.__esModule?i:{default:i};var s=(a.prototype.push=function(){var t=this.stack[this.stackIndex];t=t||(this.stack[this.stackIndex]=new Uint8Array(16)),++this.stackIndex;for(var e=0;e<this.activeState.length;e++)t[e]=this.activeState[e]},a.prototype.pop=function(){var t=this.stack[--this.stackIndex];this.setState(t)},a.prototype.setState=function(t){this.setBlend(t[0]),this.setDepthTest(t[1]),this.setFrontFace(t[2]),this.setCullFace(t[3]),this.setBlendMode(t[4])},a.prototype.setBlend=function(t){t=t?1:0,this.activeState[0]!==t&&(this.activeState[0]=t,this.gl[t?"enable":"disable"](this.gl.BLEND))},a.prototype.setBlendMode=function(t){if(t!==this.activeState[4]){this.activeState[4]=t;var e=this.blendModes[t];2===e.length?this.gl.blendFunc(e[0],e[1]):this.gl.blendFuncSeparate(e[0],e[1],e[2],e[3])}},a.prototype.setDepthTest=function(t){t=t?1:0,this.activeState[1]!==t&&(this.activeState[1]=t,this.gl[t?"enable":"disable"](this.gl.DEPTH_TEST))},a.prototype.setCullFace=function(t){t=t?1:0,this.activeState[3]!==t&&(this.activeState[3]=t,this.gl[t?"enable":"disable"](this.gl.CULL_FACE))},a.prototype.setFrontFace=function(t){t=t?1:0,this.activeState[2]!==t&&(this.activeState[2]=t,this.gl.frontFace(this.gl[t?"CW":"CCW"]))},a.prototype.resetAttributes=function(){for(var t=0;t<this.attribState.tempAttribState.length;t++)this.attribState.tempAttribState[t]=0;for(var e=0;e<this.attribState.attribState.length;e++)this.attribState.attribState[e]=0;for(var r=1;r<this.maxAttribs;r++)this.gl.disableVertexAttribArray(r)},a.prototype.resetToDefault=function(){this.nativeVaoExtension&&this.nativeVaoExtension.bindVertexArrayOES(null),this.resetAttributes();for(var t=0;t<this.activeState.length;++t)this.activeState[t]=32;this.gl.pixelStorei(this.gl.UNPACK_FLIP_Y_WEBGL,!1),this.setState(this.defaultState)},a);function a(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,a),this.activeState=new Uint8Array(16),this.defaultState=new Uint8Array(16),this.defaultState[0]=1,this.stackIndex=0,this.stack=[],this.gl=t,this.maxAttribs=t.getParameter(t.MAX_VERTEX_ATTRIBS),this.attribState={tempAttribState:new Array(this.maxAttribs),attribState:new Array(this.maxAttribs)},this.blendModes=(0,o.default)(t),this.nativeVaoExtension=t.getExtension("OES_vertex_array_object")||t.getExtension("MOZ_OES_vertex_array_object")||t.getExtension("WEBKIT_OES_vertex_array_object")}r.default=s},{"./utils/mapWebGLBlendModesToPixi":98}],86:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o=h(t("./extractUniformsFromSrc")),s=t("../../../utils"),a=t("../../../const"),u=h(t("../../../settings"));function h(t){return t&&t.__esModule?t:{default:t}}var l={},c=(d.prototype.apply=function(t,e,r,i){t.applyFilter(this,e,r,i)},i(d,[{key:"blendMode",get:function(){return this._blendMode},set:function(t){this._blendMode=t}}],[{key:"defaultVertexSrc",get:function(){return["attribute vec2 aVertexPosition;","attribute vec2 aTextureCoord;","uniform mat3 projectionMatrix;","uniform mat3 filterMatrix;","varying vec2 vTextureCoord;","varying vec2 vFilterCoord;","void main(void){"," gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);"," vFilterCoord = ( filterMatrix * vec3( aTextureCoord, 1.0) ).xy;"," vTextureCoord = aTextureCoord ;","}"].join("\n")}},{key:"defaultFragmentSrc",get:function(){return["varying vec2 vTextureCoord;","varying vec2 vFilterCoord;","uniform sampler2D uSampler;","uniform sampler2D filterSampler;","void main(void){"," vec4 masky = texture2D(filterSampler, vFilterCoord);"," vec4 sample = texture2D(uSampler, vTextureCoord);"," vec4 color;"," if(mod(vFilterCoord.x, 1.0) > 0.5)"," {"," color = vec4(1.0, 0.0, 0.0, 1.0);"," }"," else"," {"," color = vec4(0.0, 1.0, 0.0, 1.0);"," }"," gl_FragColor = mix(sample, masky, 0.5);"," gl_FragColor *= sample.a;","}"].join("\n")}}]),d);function d(t,e,r){for(var i in!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,d),this.vertexSrc=t||d.defaultVertexSrc,this.fragmentSrc=e||d.defaultFragmentSrc,this._blendMode=a.BLEND_MODES.NORMAL,this.uniformData=r||(0,o.default)(this.vertexSrc,this.fragmentSrc,"projectionMatrix|uSampler"),this.uniforms={},this.uniformData)this.uniforms[i]=this.uniformData[i].value,this.uniformData[i].type&&(this.uniformData[i].type=this.uniformData[i].type.toLowerCase());this.glShaders={},l[this.vertexSrc+this.fragmentSrc]||(l[this.vertexSrc+this.fragmentSrc]=(0,s.uid)()),this.glShaderKey=l[this.vertexSrc+this.fragmentSrc],this.padding=4,this.resolution=u.default.FILTER_RESOLUTION,this.enabled=!0,this.autoFit=!0}r.default=c},{"../../../const":46,"../../../settings":101,"../../../utils":125,"./extractUniformsFromSrc":87}],87:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t,e,r){var i=o(t),n=o(e);return Object.assign(i,n)};var i,n=t("pixi-gl-core");var c=((i=n)&&i.__esModule?i:{default:i}).default.shader.defaultValue;function o(t){for(var e=new RegExp("^(projectionMatrix|uSampler|filterArea|filterClamp)$"),r={},i=void 0,n=t.replace(/\s+/g," ").split(/\s*;\s*/),o=0;o<n.length;o++){var s=n[o].trim();if(-1<s.indexOf("uniform")){var a=s.split(" "),u=a[1],h=a[2],l=1;-1<h.indexOf("[")&&(h=(i=h.split(/\[|]/))[0],l*=Number(i[1])),h.match(e)||(r[h]={value:c(u,l),name:h,type:u})}}return r}},{"pixi-gl-core":15}],88:[function(t,e,r){"use strict";r.__esModule=!0,r.calculateScreenSpaceMatrix=function(t,e,r){var i=t.identity();return i.translate(e.x/r.width,e.y/r.height),i.scale(r.width,r.height),i},r.calculateNormalizedScreenSpaceMatrix=function(t,e,r){var i=t.identity();i.translate(e.x/r.width,e.y/r.height);var n=r.width/e.width,o=r.height/e.height;return i.scale(n,o),i},r.calculateSpriteMatrix=function(t,e,r,i){var n=i._texture.orig,o=t.set(r.width,0,0,r.height,e.x,e.y),s=i.worldTransform.copy(a.Matrix.TEMP_MATRIX);return s.invert(),o.prepend(s),o.scale(1/n.width,1/n.height),o.translate(i.anchor.x,i.anchor.y),o};var a=t("../../../math")},{"../../../math":70}],89:[function(t,e,r){"use strict";r.__esModule=!0;var i=o(t("../Filter")),n=t("../../../../math"),s=(t("path"),o(t("../../../../textures/TextureMatrix")));function o(t){return t&&t.__esModule?t:{default:t}}var a,u=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(h,a=i.default),h.prototype.apply=function(t,e,r,i){var n=this.maskSprite,o=this.maskSprite.texture;o.valid&&(o.transform||(o.transform=new s.default(o,0)),o.transform.update(),this.uniforms.mask=o,this.uniforms.otherMatrix=t.calculateSpriteMatrix(this.maskMatrix,n).prepend(o.transform.mapCoord),this.uniforms.alpha=n.worldAlpha,this.uniforms.maskClamp=o.transform.uClampFrame,t.applyFilter(this,e,r,i))},h);function h(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,h);var e=new n.Matrix,r=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,a.call(this,"attribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\n\nuniform mat3 projectionMatrix;\nuniform mat3 otherMatrix;\n\nvarying vec2 vMaskCoord;\nvarying vec2 vTextureCoord;\n\nvoid main(void)\n{\n gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n\n vTextureCoord = aTextureCoord;\n vMaskCoord = ( otherMatrix * vec3( aTextureCoord, 1.0) ).xy;\n}\n","varying vec2 vMaskCoord;\nvarying vec2 vTextureCoord;\n\nuniform sampler2D uSampler;\nuniform sampler2D mask;\nuniform float alpha;\nuniform vec4 maskClamp;\n\nvoid main(void)\n{\n float clip = step(3.5,\n step(maskClamp.x, vMaskCoord.x) +\n step(maskClamp.y, vMaskCoord.y) +\n step(vMaskCoord.x, maskClamp.z) +\n step(vMaskCoord.y, maskClamp.w));\n\n vec4 original = texture2D(uSampler, vTextureCoord);\n vec4 masky = texture2D(mask, vMaskCoord);\n\n original *= (masky.r * masky.a * alpha * clip);\n\n gl_FragColor = original;\n}\n"));return t.renderable=!1,r.maskSprite=t,r.maskMatrix=e,r}r.default=u},{"../../../../math":70,"../../../../textures/TextureMatrix":116,"../Filter":86,path:8}],90:[function(t,e,r){"use strict";r.__esModule=!0;var i=l(t("./WebGLManager")),a=l(t("../utils/RenderTarget")),n=l(t("../utils/Quad")),o=t("../../../math"),u=l(t("../../../Shader")),s=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../filters/filterTransforms")),h=l(t("bit-twiddle"));function l(t){return t&&t.__esModule?t:{default:t}}function c(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}var p=(d.prototype.clear=function(){this.filters=null,this.target=null,this.renderTarget=null},d);function d(){c(this,d),this.renderTarget=null,this.target=null,this.resolution=1,this.sourceFrame=new o.Rectangle,this.destinationFrame=new o.Rectangle,this.filters=[]}var f,v="screen",g=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(y,f=i.default),y.prototype.pushFilter=function(t,e){var r=this.renderer,i=this.filterData;if(!i){i=this.renderer._activeRenderTarget.filterStack;var n=new p;n.sourceFrame=n.destinationFrame=this.renderer._activeRenderTarget.size,n.renderTarget=r._activeRenderTarget,this.renderer._activeRenderTarget.filterData=i={index:0,stack:[n]},this.filterData=i}var o=i.stack[++i.index],s=i.stack[0].destinationFrame;o=o||(i.stack[i.index]=new p);var a=t.filterArea&&0===t.filterArea.x&&0===t.filterArea.y&&t.filterArea.width===r.screen.width&&t.filterArea.height===r.screen.height,u=e[0].resolution,h=0|e[0].padding,l=a?r.screen:t.filterArea||t.getBounds(!0),c=o.sourceFrame,d=o.destinationFrame;c.x=(l.x*u|0)/u,c.y=(l.y*u|0)/u,c.width=(l.width*u|0)/u,c.height=(l.height*u|0)/u,a||(i.stack[0].renderTarget.transform||e[0].autoFit&&c.fit(s),c.pad(h)),d.width=c.width,d.height=c.height;var f=this.getPotRenderTarget(r.gl,c.width,c.height,u);o.target=t,o.filters=e,o.resolution=u,(o.renderTarget=f).setFrame(d,c),r.bindRenderTarget(f),f.clear()},y.prototype.popFilter=function(){var t=this.filterData,e=t.stack[t.index-1],r=t.stack[t.index];this.quad.map(r.renderTarget.size,r.sourceFrame).upload();var i=r.filters;if(1===i.length)i[0].apply(this,r.renderTarget,e.renderTarget,!1,r),this.freePotRenderTarget(r.renderTarget);else{var n=r.renderTarget,o=this.getPotRenderTarget(this.renderer.gl,r.sourceFrame.width,r.sourceFrame.height,r.resolution);o.setFrame(r.destinationFrame,r.sourceFrame),o.clear();var s=0;for(s=0;s<i.length-1;++s){i[s].apply(this,n,o,!0,r);var a=n;n=o,o=a}i[s].apply(this,n,e.renderTarget,!1,r),this.freePotRenderTarget(n),this.freePotRenderTarget(o)}r.clear(),t.index--,0===t.index&&(this.filterData=null)},y.prototype.applyFilter=function(t,e,r,i){var n=this.renderer,o=n.gl,s=t.glShaders[n.CONTEXT_UID];s||(t.glShaderKey?(s=this.shaderCache[t.glShaderKey])||(s=new u.default(this.gl,t.vertexSrc,t.fragmentSrc),t.glShaders[n.CONTEXT_UID]=this.shaderCache[t.glShaderKey]=s,this.managedFilters.push(t)):(s=t.glShaders[n.CONTEXT_UID]=new u.default(this.gl,t.vertexSrc,t.fragmentSrc),this.managedFilters.push(t)),n.bindVao(null),this.quad.initVao(s)),n.bindVao(this.quad.vao),n.bindRenderTarget(r),i&&(o.disable(o.SCISSOR_TEST),n.clear(),o.enable(o.SCISSOR_TEST)),r===n.maskManager.scissorRenderTarget&&n.maskManager.pushScissorMask(null,n.maskManager.scissorData),n.bindShader(s);var a=this.renderer.emptyTextures[0];this.renderer.boundTextures[0]=a,this.syncUniforms(s,t),n.state.setBlendMode(t.blendMode),o.activeTexture(o.TEXTURE0),o.bindTexture(o.TEXTURE_2D,e.texture.texture),this.quad.vao.draw(this.renderer.gl.TRIANGLES,6,0),o.bindTexture(o.TEXTURE_2D,a._glTextures[this.renderer.CONTEXT_UID].texture)},y.prototype.syncUniforms=function(t,e){var r=e.uniformData,i=e.uniforms,n=1,o=void 0;if(t.uniforms.filterArea){o=this.filterData.stack[this.filterData.index];var s=t.uniforms.filterArea;s[0]=o.renderTarget.size.width,s[1]=o.renderTarget.size.height,s[2]=o.sourceFrame.x,s[3]=o.sourceFrame.y,t.uniforms.filterArea=s}if(t.uniforms.filterClamp){o=o||this.filterData.stack[this.filterData.index];var a=t.uniforms.filterClamp;a[0]=0,a[1]=0,a[2]=(o.sourceFrame.width-1)/o.renderTarget.size.width,a[3]=(o.sourceFrame.height-1)/o.renderTarget.size.height,t.uniforms.filterClamp=a}for(var u in r)if(t.uniforms.data[u]){var h=r[u].type;if("sampler2d"===h&&0!==i[u]){if(i[u].baseTexture)t.uniforms[u]=this.renderer.bindTexture(i[u].baseTexture,n);else{t.uniforms[u]=n;var l=this.renderer.gl;this.renderer.boundTextures[n]=this.renderer.emptyTextures[n],l.activeTexture(l.TEXTURE0+n),i[u].texture.bind()}n++}else if("mat3"===h)void 0!==i[u].a?t.uniforms[u]=i[u].toArray(!0):t.uniforms[u]=i[u];else if("vec2"===h)if(void 0!==i[u].x){var c=t.uniforms[u]||new Float32Array(2);c[0]=i[u].x,c[1]=i[u].y,t.uniforms[u]=c}else t.uniforms[u]=i[u];else"float"===h?t.uniforms.data[u].value!==r[u]&&(t.uniforms[u]=i[u]):t.uniforms[u]=i[u]}},y.prototype.getRenderTarget=function(t,e){var r=this.filterData.stack[this.filterData.index],i=this.getPotRenderTarget(this.renderer.gl,r.sourceFrame.width,r.sourceFrame.height,e||r.resolution);return i.setFrame(r.destinationFrame,r.sourceFrame),i},y.prototype.returnRenderTarget=function(t){this.freePotRenderTarget(t)},y.prototype.calculateScreenSpaceMatrix=function(t){var e=this.filterData.stack[this.filterData.index];return s.calculateScreenSpaceMatrix(t,e.sourceFrame,e.renderTarget.size)},y.prototype.calculateNormalizedScreenSpaceMatrix=function(t){var e=this.filterData.stack[this.filterData.index];return s.calculateNormalizedScreenSpaceMatrix(t,e.sourceFrame,e.renderTarget.size,e.destinationFrame)},y.prototype.calculateSpriteMatrix=function(t,e){var r=this.filterData.stack[this.filterData.index];return s.calculateSpriteMatrix(t,r.sourceFrame,r.renderTarget.size,e)},y.prototype.destroy=function(t){var e=0<arguments.length&&void 0!==t&&t,r=this.renderer,i=this.managedFilters;r.off("prerender",this.onPrerender,this);for(var n=0;n<i.length;n++)e||i[n].glShaders[r.CONTEXT_UID].destroy(),delete i[n].glShaders[r.CONTEXT_UID];this.shaderCache={},e?this.pool={}:this.emptyPool()},y.prototype.getPotRenderTarget=function(t,e,r,i){var n=v;r*=i,(e*=i)===this._screenWidth&&r===this._screenHeight||(n=(65535&(e=h.default.nextPow2(e)))<<16|65535&(r=h.default.nextPow2(r))),this.pool[n]||(this.pool[n]=[]);var o=this.pool[n].pop();if(!o){var s=this.renderer.boundTextures[0];t.activeTexture(t.TEXTURE0),o=new a.default(t,e,r,null,1),t.bindTexture(t.TEXTURE_2D,s._glTextures[this.renderer.CONTEXT_UID].texture)}return o.resolution=i,o.defaultFrame.width=o.size.width=e/i,o.defaultFrame.height=o.size.height=r/i,o.filterPoolKey=n,o},y.prototype.emptyPool=function(){for(var t in this.pool){var e=this.pool[t];if(e)for(var r=0;r<e.length;r++)e[r].destroy(!0)}this.pool={}},y.prototype.freePotRenderTarget=function(t){this.pool[t.filterPoolKey].push(t)},y.prototype.onPrerender=function(){if(this._screenWidth!==this.renderer.view.width||this._screenHeight!==this.renderer.view.height){this._screenWidth=this.renderer.view.width,this._screenHeight=this.renderer.view.height;var t=this.pool[v];if(t)for(var e=0;e<t.length;e++)t[e].destroy(!0);this.pool[v]=[]}},y);function y(t){c(this,y);var e=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,f.call(this,t));return e.gl=e.renderer.gl,e.quad=new n.default(e.gl,t.state.attribState),e.shaderCache={},e.pool={},e.filterData=null,e.managedFilters=[],e.renderer.on("prerender",e.onPrerender,e),e._screenWidth=t.view.width,e._screenHeight=t.view.height,e}r.default=g},{"../../../Shader":44,"../../../math":70,"../filters/filterTransforms":88,"../utils/Quad":95,"../utils/RenderTarget":96,"./WebGLManager":93,"bit-twiddle":1}],91:[function(t,e,r){"use strict";r.__esModule=!0;var i=o(t("./WebGLManager")),n=o(t("../filters/spriteMask/SpriteMaskFilter"));function o(t){return t&&t.__esModule?t:{default:t}}var s,a=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(u,s=i.default),u.prototype.pushMask=function(t,e){if(e.texture)this.pushSpriteMask(t,e);else if(this.enableScissor&&!this.scissor&&this.renderer._activeRenderTarget.root&&!this.renderer.stencilManager.stencilMaskStack.length&&e.isFastRect()){var r=e.worldTransform,i=Math.atan2(r.b,r.a);(i=Math.round(i*(180/Math.PI)))%90?this.pushStencilMask(e):this.pushScissorMask(t,e)}else this.pushStencilMask(e)},u.prototype.popMask=function(t,e){e.texture?this.popSpriteMask(t,e):this.enableScissor&&!this.renderer.stencilManager.stencilMaskStack.length?this.popScissorMask(t,e):this.popStencilMask(t,e)},u.prototype.pushSpriteMask=function(t,e){var r=this.alphaMaskPool[this.alphaMaskIndex];(r=r||(this.alphaMaskPool[this.alphaMaskIndex]=[new n.default(e)]))[0].resolution=this.renderer.resolution,r[0].maskSprite=e;var i=t.filterArea;t.filterArea=e.getBounds(!0),this.renderer.filterManager.pushFilter(t,r),t.filterArea=i,this.alphaMaskIndex++},u.prototype.popSpriteMask=function(){this.renderer.filterManager.popFilter(),this.alphaMaskIndex--},u.prototype.pushStencilMask=function(t){this.renderer.currentRenderer.stop(),this.renderer.stencilManager.pushStencil(t)},u.prototype.popStencilMask=function(){this.renderer.currentRenderer.stop(),this.renderer.stencilManager.popStencil()},u.prototype.pushScissorMask=function(t,e){e.renderable=!0;var r=this.renderer._activeRenderTarget,i=e.getBounds();i.fit(r.size),e.renderable=!1,this.renderer.gl.enable(this.renderer.gl.SCISSOR_TEST);var n=this.renderer.resolution;this.renderer.gl.scissor(i.x*n,(r.root?r.size.height-i.y-i.height:i.y)*n,i.width*n,i.height*n),this.scissorRenderTarget=r,this.scissorData=e,this.scissor=!0},u.prototype.popScissorMask=function(){this.scissorRenderTarget=null,this.scissorData=null,this.scissor=!1;var t=this.renderer.gl;t.disable(t.SCISSOR_TEST)},u);function u(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,u);var e=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,s.call(this,t));return e.scissor=!1,e.scissorData=null,e.scissorRenderTarget=null,e.enableScissor=!0,e.alphaMaskPool=[],e.alphaMaskIndex=0,e}r.default=a},{"../filters/spriteMask/SpriteMaskFilter":89,"./WebGLManager":93}],92:[function(t,e,r){"use strict";r.__esModule=!0;var i,n=t("./WebGLManager"),o=(i=n)&&i.__esModule?i:{default:i};var s,a=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(u,s=o.default),u.prototype.setMaskStack=function(t){this.stencilMaskStack=t;var e=this.renderer.gl;0===t.length?e.disable(e.STENCIL_TEST):e.enable(e.STENCIL_TEST)},u.prototype.pushStencil=function(t){this.renderer.setObjectRenderer(this.renderer.plugins.graphics),this.renderer._activeRenderTarget.attachStencilBuffer();var e=this.renderer.gl,r=this.stencilMaskStack.length;0===r&&e.enable(e.STENCIL_TEST),this.stencilMaskStack.push(t),e.colorMask(!1,!1,!1,!1),e.stencilFunc(e.EQUAL,r,this._getBitwiseMask()),e.stencilOp(e.KEEP,e.KEEP,e.INCR),this.renderer.plugins.graphics.render(t),this._useCurrent()},u.prototype.popStencil=function(){this.renderer.setObjectRenderer(this.renderer.plugins.graphics);var t=this.renderer.gl,e=this.stencilMaskStack.pop();0===this.stencilMaskStack.length?(t.disable(t.STENCIL_TEST),t.clear(t.STENCIL_BUFFER_BIT),t.clearStencil(0)):(t.colorMask(!1,!1,!1,!1),t.stencilOp(t.KEEP,t.KEEP,t.DECR),this.renderer.plugins.graphics.render(e),this._useCurrent())},u.prototype._useCurrent=function(){var t=this.renderer.gl;t.colorMask(!0,!0,!0,!0),t.stencilFunc(t.EQUAL,this.stencilMaskStack.length,this._getBitwiseMask()),t.stencilOp(t.KEEP,t.KEEP,t.KEEP)},u.prototype._getBitwiseMask=function(){return(1<<this.stencilMaskStack.length)-1},u.prototype.destroy=function(){o.default.prototype.destroy.call(this),this.stencilMaskStack.stencilStack=null},u);function u(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,u);var e=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,s.call(this,t));return e.stencilMaskStack=null,e}r.default=a},{"./WebGLManager":93}],93:[function(t,e,r){"use strict";r.__esModule=!0;var i=(n.prototype.onContextChange=function(){},n.prototype.destroy=function(){this.renderer.off("context",this.onContextChange,this),this.renderer=null},n);function n(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,n),this.renderer=t,this.renderer.on("context",this.onContextChange,this)}r.default=i},{}],94:[function(t,e,r){"use strict";r.__esModule=!0;var i,n=t("../managers/WebGLManager"),o=(i=n)&&i.__esModule?i:{default:i};var s,a=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(u,s=o.default),u.prototype.start=function(){},u.prototype.stop=function(){this.flush()},u.prototype.flush=function(){},u.prototype.render=function(){},u);function u(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,u),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,s.apply(this,arguments))}r.default=a},{"../managers/WebGLManager":93}],95:[function(t,e,r){"use strict";r.__esModule=!0;var i=o(t("pixi-gl-core")),n=o(t("../../../utils/createIndicesForQuads"));function o(t){return t&&t.__esModule?t:{default:t}}var s=(a.prototype.initVao=function(t){this.vao.clear().addIndex(this.indexBuffer).addAttribute(this.vertexBuffer,t.attributes.aVertexPosition,this.gl.FLOAT,!1,16,0).addAttribute(this.vertexBuffer,t.attributes.aTextureCoord,this.gl.FLOAT,!1,16,8)},a.prototype.map=function(t,e){var r=0,i=0;return this.uvs[0]=r,this.uvs[1]=i,this.uvs[2]=r+e.width/t.width,this.uvs[3]=i,this.uvs[4]=r+e.width/t.width,this.uvs[5]=i+e.height/t.height,this.uvs[6]=r,this.uvs[7]=i+e.height/t.height,r=e.x,i=e.y,this.vertices[0]=r,this.vertices[1]=i,this.vertices[2]=r+e.width,this.vertices[3]=i,this.vertices[4]=r+e.width,this.vertices[5]=i+e.height,this.vertices[6]=r,this.vertices[7]=i+e.height,this},a.prototype.upload=function(){for(var t=0;t<4;t++)this.interleaved[4*t]=this.vertices[2*t],this.interleaved[4*t+1]=this.vertices[2*t+1],this.interleaved[4*t+2]=this.uvs[2*t],this.interleaved[4*t+3]=this.uvs[2*t+1];return this.vertexBuffer.upload(this.interleaved),this},a.prototype.destroy=function(){var t=this.gl;t.deleteBuffer(this.vertexBuffer),t.deleteBuffer(this.indexBuffer)},a);function a(t,e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,a),this.gl=t,this.vertices=new Float32Array([-1,-1,1,-1,1,1,-1,1]),this.uvs=new Float32Array([0,0,1,0,1,1,0,1]),this.interleaved=new Float32Array(16);for(var r=0;r<4;r++)this.interleaved[4*r]=this.vertices[2*r],this.interleaved[4*r+1]=this.vertices[2*r+1],this.interleaved[4*r+2]=this.uvs[2*r],this.interleaved[4*r+3]=this.uvs[2*r+1];this.indices=(0,n.default)(1),this.vertexBuffer=i.default.GLBuffer.createVertexBuffer(t,this.interleaved,t.STATIC_DRAW),this.indexBuffer=i.default.GLBuffer.createIndexBuffer(t,this.indices,t.STATIC_DRAW),this.vao=new i.default.VertexArrayObject(t,e)}r.default=s},{"../../../utils/createIndicesForQuads":123,"pixi-gl-core":15}],96:[function(t,e,r){"use strict";r.__esModule=!0;var i,s=t("../../../math"),a=t("../../../const"),n=t("../../../settings"),u=(i=n)&&i.__esModule?i:{default:i},h=t("pixi-gl-core");var o=(l.prototype.clear=function(t){var e=t||this.clearColor;this.frameBuffer.clear(e[0],e[1],e[2],e[3])},l.prototype.attachStencilBuffer=function(){this.root||this.frameBuffer.enableStencil()},l.prototype.setFrame=function(t,e){this.destinationFrame=t||this.destinationFrame||this.defaultFrame,this.sourceFrame=e||this.sourceFrame||this.destinationFrame},l.prototype.activate=function(){var t=this.gl;this.frameBuffer.bind(),this.calculateProjection(this.destinationFrame,this.sourceFrame),this.transform&&this.projectionMatrix.append(this.transform),this.destinationFrame!==this.sourceFrame?(t.enable(t.SCISSOR_TEST),t.scissor(0|this.destinationFrame.x,0|this.destinationFrame.y,this.destinationFrame.width*this.resolution|0,this.destinationFrame.height*this.resolution|0)):t.disable(t.SCISSOR_TEST),t.viewport(0|this.destinationFrame.x,0|this.destinationFrame.y,this.destinationFrame.width*this.resolution|0,this.destinationFrame.height*this.resolution|0)},l.prototype.calculateProjection=function(t,e){var r=this.projectionMatrix;e=e||t,r.identity(),this.root?(r.a=1/t.width*2,r.d=-1/t.height*2,r.tx=-1-e.x*r.a,r.ty=1-e.y*r.d):(r.a=1/t.width*2,r.d=1/t.height*2,r.tx=-1-e.x*r.a,r.ty=-1-e.y*r.d)},l.prototype.resize=function(t,e){if(t|=0,e|=0,this.size.width!==t||this.size.height!==e){this.size.width=t,this.size.height=e,this.defaultFrame.width=t,this.defaultFrame.height=e,this.frameBuffer.resize(t*this.resolution,e*this.resolution);var r=this.frame||this.size;this.calculateProjection(r)}},l.prototype.destroy=function(){this.frameBuffer.stencil&&this.gl.deleteRenderbuffer(this.frameBuffer.stencil),this.frameBuffer.destroy(),this.frameBuffer=null,this.texture=null},l);function l(t,e,r,i,n,o){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),this.gl=t,this.frameBuffer=null,this.texture=null,this.clearColor=[0,0,0,0],this.size=new s.Rectangle(0,0,1,1),this.resolution=n||u.default.RESOLUTION,this.projectionMatrix=new s.Matrix,this.transform=null,this.frame=null,this.defaultFrame=new s.Rectangle,this.destinationFrame=null,this.sourceFrame=null,this.stencilBuffer=null,this.stencilMaskStack=[],this.filterData=null,this.filterPoolKey="",this.scaleMode=void 0!==i?i:u.default.SCALE_MODE,this.root=o||!1,this.root?(this.frameBuffer=new h.GLFramebuffer(t,100,100),this.frameBuffer.framebuffer=null):(this.frameBuffer=h.GLFramebuffer.createRGBA(t,100,100),this.scaleMode===a.SCALE_MODES.NEAREST?this.frameBuffer.texture.enableNearestScaling():this.frameBuffer.texture.enableLinearScaling(),this.texture=this.frameBuffer.texture),this.setFrame(),this.resize(e,r)}r.default=o},{"../../../const":46,"../../../math":70,"../../../settings":101,"pixi-gl-core":15}],97:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t,e){var r=!e;if(0===t)throw new Error("Invalid value of `0` passed to `checkMaxIfStatementsInShader`");if(r){var i=document.createElement("canvas");i.width=1,i.height=1,e=s.default.createContext(i)}var n=e.createShader(e.FRAGMENT_SHADER);for(;;){var o=a.replace(/%forloop%/gi,u(t));if(e.shaderSource(n,o),e.compileShader(n),e.getShaderParameter(n,e.COMPILE_STATUS))break;t=t/2|0}r&&e.getExtension("WEBGL_lose_context")&&e.getExtension("WEBGL_lose_context").loseContext();return t};var i,n=t("pixi-gl-core"),s=(i=n)&&i.__esModule?i:{default:i};var a=["precision mediump float;","void main(void){","float test = 0.1;","%forloop%","gl_FragColor = vec4(0.0);","}"].join("\n");function u(t){for(var e="",r=0;r<t;++r)0<r&&(e+="\nelse "),r<t-1&&(e+="if(test == "+r+".0){}");return e}},{"pixi-gl-core":15}],98:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t){var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:[];return e[i.BLEND_MODES.NORMAL]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.BLEND_MODES.ADD]=[t.ONE,t.ONE],e[i.BLEND_MODES.MULTIPLY]=[t.DST_COLOR,t.ONE_MINUS_SRC_ALPHA,t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.BLEND_MODES.SCREEN]=[t.ONE,t.ONE_MINUS_SRC_COLOR,t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.BLEND_MODES.OVERLAY]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.BLEND_MODES.DARKEN]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.BLEND_MODES.LIGHTEN]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.BLEND_MODES.COLOR_DODGE]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.BLEND_MODES.COLOR_BURN]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.BLEND_MODES.HARD_LIGHT]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.BLEND_MODES.SOFT_LIGHT]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.BLEND_MODES.DIFFERENCE]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.BLEND_MODES.EXCLUSION]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.BLEND_MODES.HUE]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.BLEND_MODES.SATURATION]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.BLEND_MODES.COLOR]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.BLEND_MODES.LUMINOSITY]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.BLEND_MODES.NORMAL_NPM]=[t.SRC_ALPHA,t.ONE_MINUS_SRC_ALPHA,t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.BLEND_MODES.ADD_NPM]=[t.SRC_ALPHA,t.ONE,t.ONE,t.ONE],e[i.BLEND_MODES.SCREEN_NPM]=[t.SRC_ALPHA,t.ONE_MINUS_SRC_COLOR,t.ONE,t.ONE_MINUS_SRC_ALPHA],e};var i=t("../../../const")},{"../../../const":46}],99:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t){var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};return e[i.DRAW_MODES.POINTS]=t.POINTS,e[i.DRAW_MODES.LINES]=t.LINES,e[i.DRAW_MODES.LINE_LOOP]=t.LINE_LOOP,e[i.DRAW_MODES.LINE_STRIP]=t.LINE_STRIP,e[i.DRAW_MODES.TRIANGLES]=t.TRIANGLES,e[i.DRAW_MODES.TRIANGLE_STRIP]=t.TRIANGLE_STRIP,e[i.DRAW_MODES.TRIANGLE_FAN]=t.TRIANGLE_FAN,e};var i=t("../../../const")},{"../../../const":46}],100:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t){t.getContextAttributes().stencil||console.warn("Provided WebGL context does not have a stencil buffer, masks may not render correctly")}},{}],101:[function(t,e,r){"use strict";r.__esModule=!0;var i=o(t("./utils/maxRecommendedTextures")),n=o(t("./utils/canUploadSameBuffer"));function o(t){return t&&t.__esModule?t:{default:t}}r.default={TARGET_FPMS:.06,MIPMAP_TEXTURES:!0,RESOLUTION:1,FILTER_RESOLUTION:1,SPRITE_MAX_TEXTURES:(0,i.default)(32),SPRITE_BATCH_SIZE:4096,RETINA_PREFIX:/@([0-9\.]+)x/,RENDER_OPTIONS:{view:null,antialias:!1,forceFXAA:!1,autoResize:!1,transparent:!1,backgroundColor:0,clearBeforeRender:!0,preserveDrawingBuffer:!1,roundPixels:!1,width:800,height:600,legacy:!1},TRANSFORM_MODE:0,GC_MODE:0,GC_MAX_IDLE:3600,GC_MAX_CHECK_COUNT:600,WRAP_MODE:0,SCALE_MODE:0,PRECISION_VERTEX:"highp",PRECISION_FRAGMENT:"mediump",CAN_UPLOAD_SAME_BUFFER:(0,n.default)(),MESH_CANVAS_PADDING:0}},{"./utils/canUploadSameBuffer":122,"./utils/maxRecommendedTextures":127}],102:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o=t("../math"),s=t("../utils"),a=t("../const"),u=l(t("../textures/Texture")),h=l(t("../display/Container"));function l(t){return t&&t.__esModule?t:{default:t}}var c,d=new o.Point,f=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(p,c=h.default),p.prototype._onTextureUpdate=function(){this._textureID=-1,this._textureTrimmedID=-1,this.cachedTint=16777215,this._width&&(this.scale.x=(0,s.sign)(this.scale.x)*this._width/this._texture.orig.width),this._height&&(this.scale.y=(0,s.sign)(this.scale.y)*this._height/this._texture.orig.height)},p.prototype._onAnchorUpdate=function(){this._transformID=-1,this._transformTrimmedID=-1},p.prototype.calculateVertices=function(){if(this._transformID!==this.transform._worldID||this._textureID!==this._texture._updateID){this._transformID=this.transform._worldID,this._textureID=this._texture._updateID;var t=this._texture,e=this.transform.worldTransform,r=e.a,i=e.b,n=e.c,o=e.d,s=e.tx,a=e.ty,u=this.vertexData,h=t.trim,l=t.orig,c=this._anchor,d=0,f=0,p=0,v=0;p=h?(d=(f=h.x-c._x*l.width)+h.width,(v=h.y-c._y*l.height)+h.height):(d=(f=-c._x*l.width)+l.width,(v=-c._y*l.height)+l.height),u[0]=r*f+n*v+s,u[1]=o*v+i*f+a,u[2]=r*d+n*v+s,u[3]=o*v+i*d+a,u[4]=r*d+n*p+s,u[5]=o*p+i*d+a,u[6]=r*f+n*p+s,u[7]=o*p+i*f+a}},p.prototype.calculateTrimmedVertices=function(){if(this.vertexTrimmedData){if(this._transformTrimmedID===this.transform._worldID&&this._textureTrimmedID===this._texture._updateID)return}else this.vertexTrimmedData=new Float32Array(8);this._transformTrimmedID=this.transform._worldID,this._textureTrimmedID=this._texture._updateID;var t=this._texture,e=this.vertexTrimmedData,r=t.orig,i=this._anchor,n=this.transform.worldTransform,o=n.a,s=n.b,a=n.c,u=n.d,h=n.tx,l=n.ty,c=-i._x*r.width,d=c+r.width,f=-i._y*r.height,p=f+r.height;e[0]=o*c+a*f+h,e[1]=u*f+s*c+l,e[2]=o*d+a*f+h,e[3]=u*f+s*d+l,e[4]=o*d+a*p+h,e[5]=u*p+s*d+l,e[6]=o*c+a*p+h,e[7]=u*p+s*c+l},p.prototype._renderWebGL=function(t){this.calculateVertices(),t.setObjectRenderer(t.plugins[this.pluginName]),t.plugins[this.pluginName].render(this)},p.prototype._renderCanvas=function(t){t.plugins[this.pluginName].render(this)},p.prototype._calculateBounds=function(){var t=this._texture.trim,e=this._texture.orig;!t||t.width===e.width&&t.height===e.height?(this.calculateVertices(),this._bounds.addQuad(this.vertexData)):(this.calculateTrimmedVertices(),this._bounds.addQuad(this.vertexTrimmedData))},p.prototype.getLocalBounds=function(t){return 0===this.children.length?(this._bounds.minX=this._texture.orig.width*-this._anchor._x,this._bounds.minY=this._texture.orig.height*-this._anchor._y,this._bounds.maxX=this._texture.orig.width*(1-this._anchor._x),this._bounds.maxY=this._texture.orig.height*(1-this._anchor._y),t||(this._localBoundsRect||(this._localBoundsRect=new o.Rectangle),t=this._localBoundsRect),this._bounds.getRectangle(t)):c.prototype.getLocalBounds.call(this,t)},p.prototype.containsPoint=function(t){this.worldTransform.applyInverse(t,d);var e=this._texture.orig.width,r=this._texture.orig.height,i=-e*this.anchor.x,n=0;return d.x>=i&&d.x<i+e&&(n=-r*this.anchor.y,d.y>=n&&d.y<n+r)},p.prototype.destroy=function(t){if(c.prototype.destroy.call(this,t),this._texture.off("update",this._onTextureUpdate,this),this._anchor=null,"boolean"==typeof t?t:t&&t.texture){var e="boolean"==typeof t?t:t&&t.baseTexture;this._texture.destroy(!!e)}this._texture=null,this.shader=null},p.from=function(t){return new p(u.default.from(t))},p.fromFrame=function(t){var e=s.TextureCache[t];if(!e)throw new Error('The frameId "'+t+'" does not exist in the texture cache');return new p(e)},p.fromImage=function(t,e,r){return new p(u.default.fromImage(t,e,r))},i(p,[{key:"width",get:function(){return Math.abs(this.scale.x)*this._texture.orig.width},set:function(t){var e=(0,s.sign)(this.scale.x)||1;this.scale.x=e*t/this._texture.orig.width,this._width=t}},{key:"height",get:function(){return Math.abs(this.scale.y)*this._texture.orig.height},set:function(t){var e=(0,s.sign)(this.scale.y)||1;this.scale.y=e*t/this._texture.orig.height,this._height=t}},{key:"anchor",get:function(){return this._anchor},set:function(t){this._anchor.copy(t)}},{key:"tint",get:function(){return this._tint},set:function(t){this._tint=t,this._tintRGB=(t>>16)+(65280&t)+((255&t)<<16)}},{key:"texture",get:function(){return this._texture},set:function(t){this._texture!==t&&(this._texture=t||u.default.EMPTY,this.cachedTint=16777215,this._textureID=-1,this._textureTrimmedID=-1,t&&(t.baseTexture.hasLoaded?this._onTextureUpdate():t.once("update",this._onTextureUpdate,this)))}}]),p);function p(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,p);var e=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,c.call(this));return e._anchor=new o.ObservablePoint(e._onAnchorUpdate,e,t?t.defaultAnchor.x:0,t?t.defaultAnchor.y:0),e._texture=null,e._width=0,e._height=0,e._tint=null,e._tintRGB=null,e.tint=16777215,e.blendMode=a.BLEND_MODES.NORMAL,e.shader=null,e.cachedTint=16777215,e.texture=t||u.default.EMPTY,e.vertexData=new Float32Array(8),e.vertexTrimmedData=null,e._transformID=-1,e._textureID=-1,e._transformTrimmedID=-1,e._textureTrimmedID=-1,e.pluginName="sprite",e}r.default=f},{"../const":46,"../display/Container":48,"../math":70,"../textures/Texture":115,"../utils":125}],103:[function(t,e,r){"use strict";r.__esModule=!0;var i=n(t("../../renderers/canvas/CanvasRenderer")),l=t("../../const"),c=t("../../math"),d=n(t("./CanvasTinter"));function n(t){return t&&t.__esModule?t:{default:t}}var f=new c.Matrix,o=(s.prototype.render=function(t){var e=t._texture,r=this.renderer,i=e._frame.width,n=e._frame.height,o=t.transform.worldTransform,s=0,a=0;if(!(e.orig.width<=0||e.orig.height<=0)&&e.baseTexture.source&&(r.setBlendMode(t.blendMode),e.valid)){r.context.globalAlpha=t.worldAlpha;var u=e.baseTexture.scaleMode===l.SCALE_MODES.LINEAR;r.smoothProperty&&r.context[r.smoothProperty]!==u&&(r.context[r.smoothProperty]=u),a=e.trim?(s=e.trim.width/2+e.trim.x-t.anchor.x*e.orig.width,e.trim.height/2+e.trim.y-t.anchor.y*e.orig.height):(s=(.5-t.anchor.x)*e.orig.width,(.5-t.anchor.y)*e.orig.height),e.rotate&&(o.copy(f),o=f,c.GroupD8.matrixAppendRotationInv(o,e.rotate,s,a),a=s=0),s-=i/2,a-=n/2,r.roundPixels||t.roundPixels?(r.context.setTransform(o.a,o.b,o.c,o.d,o.tx*r.resolution|0,o.ty*r.resolution|0),s|=0,a|=0):r.context.setTransform(o.a,o.b,o.c,o.d,o.tx*r.resolution,o.ty*r.resolution);var h=e.baseTexture.resolution;16777215!==t.tint?(t.cachedTint===t.tint&&t.tintedTexture.tintId===t._texture._updateID||(t.cachedTint=t.tint,t.tintedTexture=d.default.getTintedTexture(t,t.tint)),r.context.drawImage(t.tintedTexture,0,0,i*h,n*h,s*r.resolution,a*r.resolution,i*r.resolution,n*r.resolution)):r.context.drawImage(e.baseTexture.source,e._frame.x*h,e._frame.y*h,i*h,n*h,s*r.resolution,a*r.resolution,i*r.resolution,n*r.resolution)}},s.prototype.destroy=function(){this.renderer=null},s);function s(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,s),this.renderer=t}r.default=o,i.default.registerPlugin("sprite",o)},{"../../const":46,"../../math":70,"../../renderers/canvas/CanvasRenderer":77,"./CanvasTinter":104}],104:[function(t,e,r){"use strict";r.__esModule=!0;var i,f=t("../../utils"),n=t("../../renderers/canvas/utils/canUseNewCanvasBlendModes");var a={getTintedTexture:function(t,e){var r=t._texture,i="#"+("00000"+(0|(e=a.roundColor(e))).toString(16)).substr(-6);r.tintCache=r.tintCache||{};var n=r.tintCache[i],o=void 0;if(n){if(n.tintId===r._updateID)return r.tintCache[i];o=r.tintCache[i]}else o=a.canvas||document.createElement("canvas");if(a.tintMethod(r,e,o),o.tintId=r._updateID,a.convertTintToImage){var s=new Image;s.src=o.toDataURL(),r.tintCache[i]=s}else r.tintCache[i]=o,a.canvas=null;return o},tintWithMultiply:function(t,e,r){var i=r.getContext("2d"),n=t._frame.clone(),o=t.baseTexture.resolution;n.x*=o,n.y*=o,n.width*=o,n.height*=o,r.width=Math.ceil(n.width),r.height=Math.ceil(n.height),i.save(),i.fillStyle="#"+("00000"+(0|e).toString(16)).substr(-6),i.fillRect(0,0,n.width,n.height),i.globalCompositeOperation="multiply",i.drawImage(t.baseTexture.source,n.x,n.y,n.width,n.height,0,0,n.width,n.height),i.globalCompositeOperation="destination-atop",i.drawImage(t.baseTexture.source,n.x,n.y,n.width,n.height,0,0,n.width,n.height),i.restore()},tintWithOverlay:function(t,e,r){var i=r.getContext("2d"),n=t._frame.clone(),o=t.baseTexture.resolution;n.x*=o,n.y*=o,n.width*=o,n.height*=o,r.width=Math.ceil(n.width),r.height=Math.ceil(n.height),i.save(),i.globalCompositeOperation="copy",i.fillStyle="#"+("00000"+(0|e).toString(16)).substr(-6),i.fillRect(0,0,n.width,n.height),i.globalCompositeOperation="destination-atop",i.drawImage(t.baseTexture.source,n.x,n.y,n.width,n.height,0,0,n.width,n.height),i.restore()},tintWithPerPixel:function(t,e,r){var i=r.getContext("2d"),n=t._frame.clone(),o=t.baseTexture.resolution;n.x*=o,n.y*=o,n.width*=o,n.height*=o,r.width=Math.ceil(n.width),r.height=Math.ceil(n.height),i.save(),i.globalCompositeOperation="copy",i.drawImage(t.baseTexture.source,n.x,n.y,n.width,n.height,0,0,n.width,n.height),i.restore();for(var s=(0,f.hex2rgb)(e),a=s[0],u=s[1],h=s[2],l=i.getImageData(0,0,n.width,n.height),c=l.data,d=0;d<c.length;d+=4)c[d+0]*=a,c[d+1]*=u,c[d+2]*=h;i.putImageData(l,0,0)},roundColor:function(t){var e=a.cacheStepsPerColorChannel,r=(0,f.hex2rgb)(t);return r[0]=Math.min(255,r[0]/e*e),r[1]=Math.min(255,r[1]/e*e),r[2]=Math.min(255,r[2]/e*e),(0,f.rgb2hex)(r)},cacheStepsPerColorChannel:8,convertTintToImage:!1,canUseMultiply:(0,((i=n)&&i.__esModule?i:{default:i}).default)(),tintMethod:0};a.tintMethod=a.canUseMultiply?a.tintWithMultiply:a.tintWithPerPixel,r.default=a},{"../../renderers/canvas/utils/canUseNewCanvasBlendModes":80,"../../utils":125}],105:[function(t,e,r){"use strict";r.__esModule=!0;var i=(n.prototype.destroy=function(){this.vertices=null,this.positions=null,this.uvs=null,this.colors=null},n);function n(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,n),this.vertices=new ArrayBuffer(t),this.float32View=new Float32Array(this.vertices),this.uint32View=new Uint32Array(this.vertices)}r.default=i},{}],106:[function(t,e,r){"use strict";r.__esModule=!0;var i=h(t("../../renderers/webgl/utils/ObjectRenderer")),n=h(t("../../renderers/webgl/WebGLRenderer")),o=h(t("../../utils/createIndicesForQuads")),s=h(t("./generateMultiTextureShader")),a=h(t("../../renderers/webgl/utils/checkMaxIfStatmentsInShader")),u=h(t("./BatchBuffer")),k=h(t("../../settings")),F=t("../../utils"),j=h(t("pixi-gl-core")),U=h(t("bit-twiddle"));function h(t){return t&&t.__esModule?t:{default:t}}var l,X=0,G=0,c=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(d,l=i.default),d.prototype.onContextChange=function(){var t=this.renderer.gl;this.renderer.legacy?this.MAX_TEXTURES=1:(this.MAX_TEXTURES=Math.min(t.getParameter(t.MAX_TEXTURE_IMAGE_UNITS),k.default.SPRITE_MAX_TEXTURES),this.MAX_TEXTURES=(0,a.default)(this.MAX_TEXTURES,t)),this.shader=(0,s.default)(t,this.MAX_TEXTURES),this.indexBuffer=j.default.GLBuffer.createIndexBuffer(t,this.indices,t.STATIC_DRAW),this.renderer.bindVao(null);for(var e=this.shader.attributes,r=0;r<this.vaoMax;r++){var i=this.vertexBuffers[r]=j.default.GLBuffer.createVertexBuffer(t,null,t.STREAM_DRAW),n=this.renderer.createVao().addIndex(this.indexBuffer).addAttribute(i,e.aVertexPosition,t.FLOAT,!1,this.vertByteSize,0).addAttribute(i,e.aTextureCoord,t.UNSIGNED_SHORT,!0,this.vertByteSize,8).addAttribute(i,e.aColor,t.UNSIGNED_BYTE,!0,this.vertByteSize,12);e.aTextureId&&n.addAttribute(i,e.aTextureId,t.FLOAT,!1,this.vertByteSize,16),this.vaos[r]=n}this.vao=this.vaos[0],this.currentBlendMode=99999,this.boundTextures=new Array(this.MAX_TEXTURES)},d.prototype.onPrerender=function(){this.vertexCount=0},d.prototype.render=function(t){this.currentIndex>=this.size&&this.flush(),t._texture._uvs&&(this.sprites[this.currentIndex++]=t)},d.prototype.flush=function(){if(0!==this.currentIndex){var t=this.renderer.gl,e=this.MAX_TEXTURES,r=U.default.nextPow2(this.currentIndex),i=U.default.log2(r),n=this.buffers[i],o=this.sprites,s=this.groups,a=n.float32View,u=n.uint32View,h=this.boundTextures,l=this.renderer.boundTextures,c=this.renderer.textureGC.count,d=0,f=void 0,p=void 0,v=1,g=0,y=s[0],m=void 0,_=void 0,x=F.premultiplyBlendMode[o[0]._texture.baseTexture.premultipliedAlpha?1:0][o[0].blendMode];y.textureCount=0,y.start=0,y.blend=x,X++;var b=void 0;for(b=0;b<e;++b){var T=l[b];T._enabled!==X?((h[b]=T)._virtalBoundId=b,T._enabled=X):h[b]=this.renderer.emptyTextures[b]}for(X++,b=0;b<this.currentIndex;++b){var w=o[b];o[b]=null,f=w._texture.baseTexture;var E=F.premultiplyBlendMode[Number(f.premultipliedAlpha)][w.blendMode];if(x!==E&&(x=E,p=null,g=e,X++),p!==f&&(p=f)._enabled!==X){if(g===e&&(X++,y.size=b-y.start,g=0,(y=s[v++]).blend=x,y.textureCount=0,y.start=b),f.touched=c,-1===f._virtalBoundId)for(var S=0;S<e;++S){var O=(S+G)%e,M=h[O];if(M._enabled!==X){G++,M._virtalBoundId=-1,h[f._virtalBoundId=O]=f;break}}f._enabled=X,y.textureCount++,y.ids[g]=f._virtalBoundId,y.textures[g++]=f}if(m=w.vertexData,_=w._texture._uvs.uvsUint32,this.renderer.roundPixels||w.roundPixels){var P=this.renderer.resolution;a[d]=(m[0]*P|0)/P,a[d+1]=(m[1]*P|0)/P,a[d+5]=(m[2]*P|0)/P,a[d+6]=(m[3]*P|0)/P,a[d+10]=(m[4]*P|0)/P,a[d+11]=(m[5]*P|0)/P,a[d+15]=(m[6]*P|0)/P,a[d+16]=(m[7]*P|0)/P}else a[d]=m[0],a[d+1]=m[1],a[d+5]=m[2],a[d+6]=m[3],a[d+10]=m[4],a[d+11]=m[5],a[d+15]=m[6],a[d+16]=m[7];u[d+2]=_[0],u[d+7]=_[1],u[d+12]=_[2],u[d+17]=_[3];var C=Math.min(w.worldAlpha,1),R=C<1&&f.premultipliedAlpha?(0,F.premultiplyTint)(w._tintRGB,C):w._tintRGB+(255*C<<24);u[d+3]=u[d+8]=u[d+13]=u[d+18]=R,a[d+4]=a[d+9]=a[d+14]=a[d+19]=f._virtalBoundId,d+=20}if(y.size=b-y.start,k.default.CAN_UPLOAD_SAME_BUFFER)this.vertexBuffers[this.vertexCount].upload(n.vertices,0,!0);else{if(this.vaoMax<=this.vertexCount){this.vaoMax++;var A=this.shader.attributes,I=this.vertexBuffers[this.vertexCount]=j.default.GLBuffer.createVertexBuffer(t,null,t.STREAM_DRAW),D=this.renderer.createVao().addIndex(this.indexBuffer).addAttribute(I,A.aVertexPosition,t.FLOAT,!1,this.vertByteSize,0).addAttribute(I,A.aTextureCoord,t.UNSIGNED_SHORT,!0,this.vertByteSize,8).addAttribute(I,A.aColor,t.UNSIGNED_BYTE,!0,this.vertByteSize,12);A.aTextureId&&D.addAttribute(I,A.aTextureId,t.FLOAT,!1,this.vertByteSize,16),this.vaos[this.vertexCount]=D}this.renderer.bindVao(this.vaos[this.vertexCount]),this.vertexBuffers[this.vertexCount].upload(n.vertices,0,!1),this.vertexCount++}for(b=0;b<e;++b)l[b]._virtalBoundId=-1;for(b=0;b<v;++b){for(var L=s[b],N=L.textureCount,B=0;B<N;B++)p=L.textures[B],l[L.ids[B]]!==p&&this.renderer.bindTexture(p,L.ids[B],!0),p._virtalBoundId=-1;this.renderer.state.setBlendMode(L.blend),t.drawElements(t.TRIANGLES,6*L.size,t.UNSIGNED_SHORT,6*L.start*2)}this.currentIndex=0}},d.prototype.start=function(){this.renderer.bindShader(this.shader),k.default.CAN_UPLOAD_SAME_BUFFER&&(this.renderer.bindVao(this.vaos[this.vertexCount]),this.vertexBuffers[this.vertexCount].bind())},d.prototype.stop=function(){this.flush()},d.prototype.destroy=function(){for(var t=0;t<this.vaoMax;t++)this.vertexBuffers[t]&&this.vertexBuffers[t].destroy(),this.vaos[t]&&this.vaos[t].destroy();this.indexBuffer&&this.indexBuffer.destroy(),this.renderer.off("prerender",this.onPrerender,this),l.prototype.destroy.call(this),this.shader&&(this.shader.destroy(),this.shader=null),this.vertexBuffers=null,this.vaos=null,this.indexBuffer=null,this.indices=null,this.sprites=null;for(var e=0;e<this.buffers.length;++e)this.buffers[e].destroy()},d);function d(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,d);var e=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,l.call(this,t));e.vertSize=5,e.vertByteSize=4*e.vertSize,e.size=k.default.SPRITE_BATCH_SIZE,e.buffers=[];for(var r=1;r<=U.default.nextPow2(e.size);r*=2)e.buffers.push(new u.default(4*r*e.vertByteSize));e.indices=(0,o.default)(e.size),e.shader=null,e.currentIndex=0,e.groups=[];for(var i=0;i<e.size;i++)e.groups[i]={textures:[],textureCount:0,ids:[],size:0,start:0,blend:0};return e.sprites=[],e.vertexBuffers=[],e.vaos=[],e.vaoMax=2,e.vertexCount=0,e.renderer.on("prerender",e.onPrerender,e),e}r.default=c,n.default.registerPlugin("sprite",c)},{"../../renderers/webgl/WebGLRenderer":84,"../../renderers/webgl/utils/ObjectRenderer":94,"../../renderers/webgl/utils/checkMaxIfStatmentsInShader":97,"../../settings":101,"../../utils":125,"../../utils/createIndicesForQuads":123,"./BatchBuffer":105,"./generateMultiTextureShader":107,"bit-twiddle":1,"pixi-gl-core":15}],107:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t,e){var r=a;r=(r=r.replace(/%count%/gi,e)).replace(/%forloop%/gi,function(t){var e="";e+="\n",e+="\n";for(var r=0;r<t;r++)0<r&&(e+="\nelse "),r<t-1&&(e+="if(vTextureId < "+r+".5)"),e+="\n{",e+="\n\tcolor = texture2D(uSamplers["+r+"], vTextureCoord);",e+="\n}";return e+="\n",e+="\n"}(e));for(var i=new s.default(t,"precision highp float;\nattribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\nattribute vec4 aColor;\nattribute float aTextureId;\n\nuniform mat3 projectionMatrix;\n\nvarying vec2 vTextureCoord;\nvarying vec4 vColor;\nvarying float vTextureId;\n\nvoid main(void){\n gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n\n vTextureCoord = aTextureCoord;\n vTextureId = aTextureId;\n vColor = aColor;\n}\n",r),n=[],o=0;o<e;o++)n[o]=o;return i.bind(),i.uniforms.uSamplers=n,i};var i,n=t("../../Shader"),s=(i=n)&&i.__esModule?i:{default:i};t("path");var a=["varying vec2 vTextureCoord;","varying vec4 vColor;","varying float vTextureId;","uniform sampler2D uSamplers[%count%];","void main(void){","vec4 color;","%forloop%","gl_FragColor = color * vColor;","}"].join("\n")},{"../../Shader":44,path:8}],108:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o=d(t("../sprites/Sprite")),s=d(t("../textures/Texture")),a=t("../math"),u=t("../utils"),v=t("../const"),h=d(t("../settings")),l=d(t("./TextStyle")),y=d(t("./TextMetrics")),c=d(t("../utils/trimCanvas"));function d(t){return t&&t.__esModule?t:{default:t}}var f,p={texture:!0,children:!1,baseTexture:!0},g=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(m,f=o.default),m.prototype.updateText=function(t){var e=this._style;if(this.localStyleID!==e.styleID&&(this.dirty=!0,this.localStyleID=e.styleID),this.dirty||!t){this._font=this._style.toFontString();var r=this.context,i=y.default.measureText(this._text,this._style,this._style.wordWrap,this.canvas),n=i.width,o=i.height,s=i.lines,a=i.lineHeight,u=i.lineWidths,h=i.maxLineWidth,l=i.fontProperties;this.canvas.width=Math.ceil((Math.max(1,n)+2*e.padding)*this.resolution),this.canvas.height=Math.ceil((Math.max(1,o)+2*e.padding)*this.resolution),r.scale(this.resolution,this.resolution),r.clearRect(0,0,this.canvas.width,this.canvas.height),r.font=this._font,r.strokeStyle=e.stroke,r.lineWidth=e.strokeThickness,r.textBaseline=e.textBaseline,r.lineJoin=e.lineJoin,r.miterLimit=e.miterLimit;var c=void 0,d=void 0;if(e.dropShadow){r.fillStyle=e.dropShadowColor,r.globalAlpha=e.dropShadowAlpha,r.shadowBlur=e.dropShadowBlur,0<e.dropShadowBlur&&(r.shadowColor=e.dropShadowColor);for(var f=Math.cos(e.dropShadowAngle)*e.dropShadowDistance,p=Math.sin(e.dropShadowAngle)*e.dropShadowDistance,v=0;v<s.length;v++)c=e.strokeThickness/2,d=e.strokeThickness/2+v*a+l.ascent,"right"===e.align?c+=h-u[v]:"center"===e.align&&(c+=(h-u[v])/2),e.fill&&(this.drawLetterSpacing(s[v],c+f+e.padding,d+p+e.padding),e.stroke&&e.strokeThickness&&(r.strokeStyle=e.dropShadowColor,this.drawLetterSpacing(s[v],c+f+e.padding,d+p+e.padding,!0),r.strokeStyle=e.stroke))}r.shadowBlur=0,r.globalAlpha=1,r.fillStyle=this._generateFillStyle(e,s);for(var g=0;g<s.length;g++)c=e.strokeThickness/2,d=e.strokeThickness/2+g*a+l.ascent,"right"===e.align?c+=h-u[g]:"center"===e.align&&(c+=(h-u[g])/2),e.stroke&&e.strokeThickness&&this.drawLetterSpacing(s[g],c+e.padding,d+e.padding,!0),e.fill&&this.drawLetterSpacing(s[g],c+e.padding,d+e.padding);this.updateTexture()}},m.prototype.drawLetterSpacing=function(t,e,r,i){var n=3<arguments.length&&void 0!==i&&i,o=this._style.letterSpacing;if(0!==o)for(var s=String.prototype.split.call(t,""),a=e,u=0,h="",l=this.context.measureText(t).width,c=0;u<t.length;)h=s[u++],n?this.context.strokeText(h,a,r):this.context.fillText(h,a,r),a+=l-(c=this.context.measureText(t.substring(u)).width)+o,l=c;else n?this.context.strokeText(t,e,r):this.context.fillText(t,e,r)},m.prototype.updateTexture=function(){var t=this.canvas;if(this._style.trim){var e=(0,c.default)(t);e.data&&(t.width=e.width,t.height=e.height,this.context.putImageData(e.data,0,0))}var r=this._texture,i=this._style,n=i.trim?0:i.padding,o=r.baseTexture;o.hasLoaded=!0,o.resolution=this.resolution,o.realWidth=t.width,o.realHeight=t.height,o.width=t.width/this.resolution,o.height=t.height/this.resolution,r.trim.width=r._frame.width=t.width/this.resolution,r.trim.height=r._frame.height=t.height/this.resolution,r.trim.x=-n,r.trim.y=-n,r.orig.width=r._frame.width-2*n,r.orig.height=r._frame.height-2*n,this._onTextureUpdate(),o.emit("update",o),this.dirty=!1},m.prototype.renderWebGL=function(t){this.resolution!==t.resolution&&(this.resolution=t.resolution,this.dirty=!0),this.updateText(!0),f.prototype.renderWebGL.call(this,t)},m.prototype._renderCanvas=function(t){this.resolution!==t.resolution&&(this.resolution=t.resolution,this.dirty=!0),this.updateText(!0),f.prototype._renderCanvas.call(this,t)},m.prototype.getLocalBounds=function(t){return this.updateText(!0),f.prototype.getLocalBounds.call(this,t)},m.prototype._calculateBounds=function(){this.updateText(!0),this.calculateVertices(),this._bounds.addQuad(this.vertexData)},m.prototype._onStyleChange=function(){this.dirty=!0},m.prototype._generateFillStyle=function(t,e){if(!Array.isArray(t.fill))return t.fill;if(navigator.isCocoonJS)return t.fill[0];var r=void 0,i=void 0,n=void 0,o=void 0,s=this.canvas.width/this.resolution,a=this.canvas.height/this.resolution,u=t.fill.slice(),h=t.fillGradientStops.slice();if(!h.length)for(var l=u.length+1,c=1;c<l;++c)h.push(c/l);if(u.unshift(t.fill[0]),h.unshift(0),u.push(t.fill[t.fill.length-1]),h.push(1),t.fillGradientType===v.TEXT_GRADIENT.LINEAR_VERTICAL){r=this.context.createLinearGradient(s/2,0,s/2,a),i=(u.length+1)*e.length;for(var d=n=0;d<e.length;d++){n+=1;for(var f=0;f<u.length;f++)o="number"==typeof h[f]?h[f]/e.length+d/e.length:n/i,r.addColorStop(o,u[f]),n++}}else{r=this.context.createLinearGradient(0,a/2,s,a/2),i=u.length+1,n=1;for(var p=0;p<u.length;p++)o="number"==typeof h[p]?h[p]:n/i,r.addColorStop(o,u[p]),n++}return r},m.prototype.destroy=function(t){"boolean"==typeof t&&(t={children:t}),t=Object.assign({},p,t),f.prototype.destroy.call(this,t),this.context=null,this.canvas=null,this._style=null},i(m,[{key:"width",get:function(){return this.updateText(!0),Math.abs(this.scale.x)*this._texture.orig.width},set:function(t){this.updateText(!0);var e=(0,u.sign)(this.scale.x)||1;this.scale.x=e*t/this._texture.orig.width,this._width=t}},{key:"height",get:function(){return this.updateText(!0),Math.abs(this.scale.y)*this._texture.orig.height},set:function(t){this.updateText(!0);var e=(0,u.sign)(this.scale.y)||1;this.scale.y=e*t/this._texture.orig.height,this._height=t}},{key:"style",get:function(){return this._style},set:function(t){(t=t||{})instanceof l.default?this._style=t:this._style=new l.default(t),this.localStyleID=-1,this.dirty=!0}},{key:"text",get:function(){return this._text},set:function(t){t=String(""===t||null==t?" ":t),this._text!==t&&(this._text=t,this.dirty=!0)}}]),m);function m(t,e,r){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,m),(r=r||document.createElement("canvas")).width=3,r.height=3;var i=s.default.fromCanvas(r,h.default.SCALE_MODE,"text");i.orig=new a.Rectangle,i.trim=new a.Rectangle;var n=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,f.call(this,i));return s.default.addToCache(n._texture,n._texture.baseTexture.textureCacheIds[0]),n.canvas=r,n.context=n.canvas.getContext("2d"),n.resolution=h.default.RESOLUTION,n._text=null,n._style=null,n._styleListener=null,n._font="",n.text=t,n.style=e,n.localStyleID=-1,n}r.default=g},{"../const":46,"../math":70,"../settings":101,"../sprites/Sprite":102,"../textures/Texture":115,"../utils":125,"../utils/trimCanvas":130,"./TextMetrics":109,"./TextStyle":110}],109:[function(t,e,r){"use strict";r.__esModule=!0;var i=(P.measureText=function(t,e,r,i){var n=3<arguments.length&&void 0!==i?i:P._canvas;r=null==r?e.wordWrap:r;var o=e.toFontString(),s=P.measureFont(o),a=n.getContext("2d");a.font=o;for(var u=(r?P.wordWrap(t,e,n):t).split(/(?:\r\n|\r|\n)/),h=new Array(u.length),l=0,c=0;c<u.length;c++){var d=a.measureText(u[c]).width+(u[c].length-1)*e.letterSpacing;h[c]=d,l=Math.max(l,d)}var f=l+e.strokeThickness;e.dropShadow&&(f+=e.dropShadowDistance);var p=e.lineHeight||s.fontSize+e.strokeThickness,v=Math.max(p,s.fontSize+e.strokeThickness)+(u.length-1)*(p+e.leading);return e.dropShadow&&(v+=e.dropShadowDistance),new P(t,e,f,v,u,h,p+e.leading,l,s)},P.wordWrap=function(t,e,r){for(var i=(2<arguments.length&&void 0!==r?r:P._canvas).getContext("2d"),n=0,o="",s="",a={},u=e.letterSpacing,h=e.whiteSpace,l=P.collapseSpaces(h),c=P.collapseNewlines(h),d=!l,f=e.wordWrapWidth+u,p=P.tokenize(t),v=0;v<p.length;v++){var g=p[v];if(P.isNewline(g)){if(!c){s+=P.addLine(o),d=!l,o="",n=0;continue}g=" "}if(l){var y=P.isBreakingSpace(g),m=P.isBreakingSpace(o[o.length-1]);if(y&&m)continue}var _=P.getFromCache(g,u,a,i);if(f<_)if(""!==o&&(s+=P.addLine(o),o="",n=0),P.canBreakWords(g,e.breakWords))for(var x=g.split(""),b=0;b<x.length;b++){for(var T=x[b],w=1;x[b+w];){var E=x[b+w],S=T[T.length-1];if(P.canBreakChars(S,E,g,b,e.breakWords))break;T+=E,w++}b+=T.length-1;var O=P.getFromCache(T,u,a,i);f<O+n&&(s+=P.addLine(o),d=!1,o="",n=0),o+=T,n+=O}else{0<o.length&&(s+=P.addLine(o),o="",n=0);var M=v===p.length-1;s+=P.addLine(g,!M),d=!1,o="",n=0}else f<_+n&&(d=!1,s+=P.addLine(o),o="",n=0),(0<o.length||!P.isBreakingSpace(g)||d)&&(o+=g,n+=_)}return s+=P.addLine(o,!1)},P.addLine=function(t,e){var r=!(1<arguments.length&&void 0!==e)||e;return t=P.trimRight(t),t=r?t+"\n":t},P.getFromCache=function(t,e,r,i){var n=r[t];if(void 0===n){var o=t.length*e;n=i.measureText(t).width+o,r[t]=n}return n},P.collapseSpaces=function(t){return"normal"===t||"pre-line"===t},P.collapseNewlines=function(t){return"normal"===t},P.trimRight=function(t){if("string"!=typeof t)return"";for(var e=t.length-1;0<=e;e--){var r=t[e];if(!P.isBreakingSpace(r))break;t=t.slice(0,-1)}return t},P.isNewline=function(t){return"string"==typeof t&&0<=P._newlines.indexOf(t.charCodeAt(0))},P.isBreakingSpace=function(t){return"string"==typeof t&&0<=P._breakingSpaces.indexOf(t.charCodeAt(0))},P.tokenize=function(t){var e=[],r="";if("string"!=typeof t)return e;for(var i=0;i<t.length;i++){var n=t[i];P.isBreakingSpace(n)||P.isNewline(n)?(""!==r&&(e.push(r),r=""),e.push(n)):r+=n}return""!==r&&e.push(r),e},P.canBreakWords=function(t,e){return e},P.canBreakChars=function(){return!0},P.measureFont=function(t){if(P._fonts[t])return P._fonts[t];var e={},r=P._canvas,i=P._context;i.font=t;var n=P.METRICS_STRING+P.BASELINE_SYMBOL,o=Math.ceil(i.measureText(n).width),s=Math.ceil(i.measureText(P.BASELINE_SYMBOL).width),a=2*s;s=s*P.BASELINE_MULTIPLIER|0,r.width=o,r.height=a,i.fillStyle="#f00",i.fillRect(0,0,o,a),i.font=t,i.textBaseline="alphabetic",i.fillStyle="#000",i.fillText(n,0,s);var u=i.getImageData(0,0,o,a).data,h=u.length,l=4*o,c=0,d=0,f=!1;for(c=0;c<s;++c){for(var p=0;p<l;p+=4)if(255!==u[d+p]){f=!0;break}if(f)break;d+=l}for(e.ascent=s-c,d=h-l,f=!1,c=a;s<c;--c){for(var v=0;v<l;v+=4)if(255!==u[d+v]){f=!0;break}if(f)break;d-=l}return e.descent=c-s,e.fontSize=e.ascent+e.descent,P._fonts[t]=e},P.clearMetrics=function(t){var e=0<arguments.length&&void 0!==t?t:"";e?delete P._fonts[e]:P._fonts={}},P);function P(t,e,r,i,n,o,s,a,u){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,P),this.text=t,this.style=e,this.width=r,this.height=i,this.lines=n,this.lineWidths=o,this.lineHeight=s,this.maxLineWidth=a,this.fontProperties=u}r.default=i;var n=document.createElement("canvas");n.width=n.height=10,i._canvas=n,i._context=n.getContext("2d"),i._fonts={},i.METRICS_STRING="|Éq",i.BASELINE_SYMBOL="M",i.BASELINE_MULTIPLIER=1.4,i._newlines=[10,13],i._breakingSpaces=[9,32,8192,8193,8194,8195,8196,8197,8198,8200,8201,8202,8287,12288]},{}],110:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o=t("../const"),s=t("../utils");var a={align:"left",breakWords:!1,dropShadow:!1,dropShadowAlpha:1,dropShadowAngle:Math.PI/6,dropShadowBlur:0,dropShadowColor:"black",dropShadowDistance:5,fill:"black",fillGradientType:o.TEXT_GRADIENT.LINEAR_VERTICAL,fillGradientStops:[],fontFamily:"Arial",fontSize:26,fontStyle:"normal",fontVariant:"normal",fontWeight:"normal",letterSpacing:0,lineHeight:0,lineJoin:"miter",miterLimit:10,padding:0,stroke:"black",strokeThickness:0,textBaseline:"alphabetic",trim:!1,whiteSpace:"pre",wordWrap:!1,wordWrapWidth:100,leading:0},u=["serif","sans-serif","monospace","cursive","fantasy","system-ui"],h=(l.prototype.clone=function(){var t={};return f(t,this,a),new l(t)},l.prototype.reset=function(){f(this,a,a)},l.prototype.toFontString=function(){var t="number"==typeof this.fontSize?this.fontSize+"px":this.fontSize,e=this.fontFamily;Array.isArray(this.fontFamily)||(e=this.fontFamily.split(","));for(var r=e.length-1;0<=r;r--){var i=e[r].trim();!/([\"\'])[^\'\"]+\1/.test(i)&&u.indexOf(i)<0&&(i='"'+i+'"'),e[r]=i}return this.fontStyle+" "+this.fontVariant+" "+this.fontWeight+" "+t+" "+e.join(",")},i(l,[{key:"align",get:function(){return this._align},set:function(t){this._align!==t&&(this._align=t,this.styleID++)}},{key:"breakWords",get:function(){return this._breakWords},set:function(t){this._breakWords!==t&&(this._breakWords=t,this.styleID++)}},{key:"dropShadow",get:function(){return this._dropShadow},set:function(t){this._dropShadow!==t&&(this._dropShadow=t,this.styleID++)}},{key:"dropShadowAlpha",get:function(){return this._dropShadowAlpha},set:function(t){this._dropShadowAlpha!==t&&(this._dropShadowAlpha=t,this.styleID++)}},{key:"dropShadowAngle",get:function(){return this._dropShadowAngle},set:function(t){this._dropShadowAngle!==t&&(this._dropShadowAngle=t,this.styleID++)}},{key:"dropShadowBlur",get:function(){return this._dropShadowBlur},set:function(t){this._dropShadowBlur!==t&&(this._dropShadowBlur=t,this.styleID++)}},{key:"dropShadowColor",get:function(){return this._dropShadowColor},set:function(t){var e=d(t);this._dropShadowColor!==e&&(this._dropShadowColor=e,this.styleID++)}},{key:"dropShadowDistance",get:function(){return this._dropShadowDistance},set:function(t){this._dropShadowDistance!==t&&(this._dropShadowDistance=t,this.styleID++)}},{key:"fill",get:function(){return this._fill},set:function(t){var e=d(t);this._fill!==e&&(this._fill=e,this.styleID++)}},{key:"fillGradientType",get:function(){return this._fillGradientType},set:function(t){this._fillGradientType!==t&&(this._fillGradientType=t,this.styleID++)}},{key:"fillGradientStops",get:function(){return this._fillGradientStops},set:function(t){!function(t,e){if(Array.isArray(t)&&Array.isArray(e)&&t.length===e.length){for(var r=0;r<t.length;++r)if(t[r]!==e[r])return;return 1}}(this._fillGradientStops,t)&&(this._fillGradientStops=t,this.styleID++)}},{key:"fontFamily",get:function(){return this._fontFamily},set:function(t){this.fontFamily!==t&&(this._fontFamily=t,this.styleID++)}},{key:"fontSize",get:function(){return this._fontSize},set:function(t){this._fontSize!==t&&(this._fontSize=t,this.styleID++)}},{key:"fontStyle",get:function(){return this._fontStyle},set:function(t){this._fontStyle!==t&&(this._fontStyle=t,this.styleID++)}},{key:"fontVariant",get:function(){return this._fontVariant},set:function(t){this._fontVariant!==t&&(this._fontVariant=t,this.styleID++)}},{key:"fontWeight",get:function(){return this._fontWeight},set:function(t){this._fontWeight!==t&&(this._fontWeight=t,this.styleID++)}},{key:"letterSpacing",get:function(){return this._letterSpacing},set:function(t){this._letterSpacing!==t&&(this._letterSpacing=t,this.styleID++)}},{key:"lineHeight",get:function(){return this._lineHeight},set:function(t){this._lineHeight!==t&&(this._lineHeight=t,this.styleID++)}},{key:"leading",get:function(){return this._leading},set:function(t){this._leading!==t&&(this._leading=t,this.styleID++)}},{key:"lineJoin",get:function(){return this._lineJoin},set:function(t){this._lineJoin!==t&&(this._lineJoin=t,this.styleID++)}},{key:"miterLimit",get:function(){return this._miterLimit},set:function(t){this._miterLimit!==t&&(this._miterLimit=t,this.styleID++)}},{key:"padding",get:function(){return this._padding},set:function(t){this._padding!==t&&(this._padding=t,this.styleID++)}},{key:"stroke",get:function(){return this._stroke},set:function(t){var e=d(t);this._stroke!==e&&(this._stroke=e,this.styleID++)}},{key:"strokeThickness",get:function(){return this._strokeThickness},set:function(t){this._strokeThickness!==t&&(this._strokeThickness=t,this.styleID++)}},{key:"textBaseline",get:function(){return this._textBaseline},set:function(t){this._textBaseline!==t&&(this._textBaseline=t,this.styleID++)}},{key:"trim",get:function(){return this._trim},set:function(t){this._trim!==t&&(this._trim=t,this.styleID++)}},{key:"whiteSpace",get:function(){return this._whiteSpace},set:function(t){this._whiteSpace!==t&&(this._whiteSpace=t,this.styleID++)}},{key:"wordWrap",get:function(){return this._wordWrap},set:function(t){this._wordWrap!==t&&(this._wordWrap=t,this.styleID++)}},{key:"wordWrapWidth",get:function(){return this._wordWrapWidth},set:function(t){this._wordWrapWidth!==t&&(this._wordWrapWidth=t,this.styleID++)}}]),l);function l(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),this.styleID=0,this.reset(),f(this,t,t)}function c(t){return"number"==typeof t?(0,s.hex2string)(t):("string"==typeof t&&0===t.indexOf("0x")&&(t=t.replace("0x","#")),t)}function d(t){if(Array.isArray(t)){for(var e=0;e<t.length;++e)t[e]=c(t[e]);return t}return c(t)}function f(t,e,r){for(var i in r)Array.isArray(e[i])?t[i]=e[i].slice():t[i]=e[i]}r.default=h},{"../const":46,"../utils":125}],111:[function(t,e,r){"use strict";r.__esModule=!0;var i=n(t("./BaseTexture")),o=n(t("../settings"));function n(t){return t&&t.__esModule?t:{default:t}}var s,a=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(u,s=i.default),u.prototype.resize=function(t,e){t=Math.ceil(t),e=Math.ceil(e),t===this.width&&e===this.height||(this.valid=0<t&&0<e,this.width=t,this.height=e,this.realWidth=this.width*this.resolution,this.realHeight=this.height*this.resolution,this.valid&&this.emit("update",this))},u.prototype.destroy=function(){s.prototype.destroy.call(this,!0),this.renderer=null},u);function u(){var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:100,e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:100,r=arguments[2],i=arguments[3];!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,u);var n=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,s.call(this,null,r));return n.resolution=i||o.default.RESOLUTION,n.width=Math.ceil(t),n.height=Math.ceil(e),n.realWidth=n.width*n.resolution,n.realHeight=n.height*n.resolution,n.scaleMode=void 0!==r?r:o.default.SCALE_MODE,n.hasLoaded=!0,n._glRenderTargets={},n._canvasRenderTarget=null,n.valid=!1,n}r.default=a},{"../settings":101,"./BaseTexture":112}],112:[function(t,e,r){"use strict";r.__esModule=!0;var s=t("../utils"),n=u(t("../settings")),i=u(t("eventemitter3")),a=u(t("../utils/determineCrossOrigin")),o=u(t("bit-twiddle"));function u(t){return t&&t.__esModule?t:{default:t}}var h,l=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(c,h=i.default),c.prototype.update=function(){"svg"!==this.imageType&&(this.realWidth=this.source.naturalWidth||this.source.videoWidth||this.source.width,this.realHeight=this.source.naturalHeight||this.source.videoHeight||this.source.height,this._updateDimensions()),this.emit("update",this)},c.prototype._updateDimensions=function(){this.width=this.realWidth/this.resolution,this.height=this.realHeight/this.resolution,this.isPowerOfTwo=o.default.isPow2(this.realWidth)&&o.default.isPow2(this.realHeight)},c.prototype.loadSource=function(t){var e=this.isLoading;this.hasLoaded=!1,this.isLoading=!1,e&&this.source&&(this.source.onload=null,this.source.onerror=null);var r=!this.source;if(((this.source=t).src&&t.complete||t.getContext)&&t.width&&t.height)this._updateImageType(),"svg"===this.imageType?this._loadSvgSource():this._sourceLoaded(),r&&this.emit("loaded",this);else if(!t.getContext){this.isLoading=!0;var i=this;if(t.onload=function(){i._updateImageType(),t.onload=null,t.onerror=null,i.isLoading&&(i.isLoading=!1,i._sourceLoaded(),"svg"!==i.imageType?i.emit("loaded",i):i._loadSvgSource())},t.onerror=function(){t.onload=null,t.onerror=null,i.isLoading&&(i.isLoading=!1,i.emit("error",i))},t.complete&&t.src){if(t.onload=null,t.onerror=null,"svg"===i.imageType)return void i._loadSvgSource();this.isLoading=!1,t.width&&t.height?(this._sourceLoaded(),e&&this.emit("loaded",this)):e&&this.emit("error",this)}}},c.prototype._updateImageType=function(){if(this.imageUrl){var t=(0,s.decomposeDataUri)(this.imageUrl),e=void 0;if(t&&"image"===t.mediaType){var r=t.subType.split("+")[0];if(!(e=(0,s.getUrlFileExtension)("."+r)))throw new Error("Invalid image type in data URI.")}else e=(e=(0,s.getUrlFileExtension)(this.imageUrl))||"png";this.imageType=e}},c.prototype._loadSvgSource=function(){if("svg"===this.imageType){var t=(0,s.decomposeDataUri)(this.imageUrl);t?this._loadSvgSourceUsingDataUri(t):this._loadSvgSourceUsingXhr()}},c.prototype._loadSvgSourceUsingDataUri=function(t){var e=void 0;if("base64"===t.encoding){if(!atob)throw new Error("Your browser doesn't support base64 conversions.");e=atob(t.data)}else e=t.data;this._loadSvgSourceUsingString(e)},c.prototype._loadSvgSourceUsingXhr=function(){var t=this,e=new XMLHttpRequest;e.onload=function(){if(e.readyState!==e.DONE||200!==e.status)throw new Error("Failed to load SVG using XHR.");t._loadSvgSourceUsingString(e.response)},e.onerror=function(){return t.emit("error",t)},e.open("GET",this.imageUrl,!0),e.send()},c.prototype._loadSvgSourceUsingString=function(t){var e=(0,s.getSvgSize)(t),r=e.width,i=e.height;if(!r||!i)throw new Error("The SVG image must have width and height defined (in pixels), canvas API needs them.");this.realWidth=Math.round(r*this.sourceScale),this.realHeight=Math.round(i*this.sourceScale),this._updateDimensions();var n=document.createElement("canvas");n.width=this.realWidth,n.height=this.realHeight,n._pixiId="canvas_"+(0,s.uid)(),n.getContext("2d").drawImage(this.source,0,0,r,i,0,0,this.realWidth,this.realHeight),this.origSource=this.source,this.source=n,c.addToCache(this,n._pixiId),this.isLoading=!1,this._sourceLoaded(),this.emit("loaded",this)},c.prototype._sourceLoaded=function(){this.hasLoaded=!0,this.update()},c.prototype.destroy=function(){this.imageUrl&&(delete s.TextureCache[this.imageUrl],this.imageUrl=null,navigator.isCocoonJS||(this.source.src="")),this.source=null,this.dispose(),c.removeFromCache(this),this.textureCacheIds=null,this._destroyed=!0},c.prototype.dispose=function(){this.emit("dispose",this)},c.prototype.updateSourceImage=function(t){this.source.src=t,this.loadSource(this.source)},c.fromImage=function(t,e,r,i){var n=s.BaseTextureCache[t];if(!n){var o=new Image;void 0===e&&0!==t.indexOf("data:")?o.crossOrigin=(0,a.default)(t):e&&(o.crossOrigin="string"==typeof e?e:"anonymous"),(n=new c(o,r)).imageUrl=t,i&&(n.sourceScale=i),n.resolution=(0,s.getResolutionOfUrl)(t),o.src=t,c.addToCache(n,t)}return n},c.fromCanvas=function(t,e,r){var i=2<arguments.length&&void 0!==r?r:"canvas";t._pixiId||(t._pixiId=i+"_"+(0,s.uid)());var n=s.BaseTextureCache[t._pixiId];return n||(n=new c(t,e),c.addToCache(n,t._pixiId)),n},c.from=function(t,e,r){if("string"==typeof t)return c.fromImage(t,void 0,e,r);if(t instanceof HTMLImageElement){var i=t.src,n=s.BaseTextureCache[i];return n||((n=new c(t,e)).imageUrl=i,r&&(n.sourceScale=r),n.resolution=(0,s.getResolutionOfUrl)(i),c.addToCache(n,i)),n}return t instanceof HTMLCanvasElement?c.fromCanvas(t,e):t},c.addToCache=function(t,e){e&&(-1===t.textureCacheIds.indexOf(e)&&t.textureCacheIds.push(e),s.BaseTextureCache[e]&&console.warn("BaseTexture added to the cache with an id ["+e+"] that already had an entry"),s.BaseTextureCache[e]=t)},c.removeFromCache=function(t){if("string"==typeof t){var e=s.BaseTextureCache[t];if(e){var r=e.textureCacheIds.indexOf(t);return-1<r&&e.textureCacheIds.splice(r,1),delete s.BaseTextureCache[t],e}}else if(t&&t.textureCacheIds){for(var i=0;i<t.textureCacheIds.length;++i)delete s.BaseTextureCache[t.textureCacheIds[i]];return t.textureCacheIds.length=0,t}return null},c);function c(t,e,r){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,c);var i=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,h.call(this));return i.uid=(0,s.uid)(),i.touched=0,i.resolution=r||n.default.RESOLUTION,i.width=100,i.height=100,i.realWidth=100,i.realHeight=100,i.scaleMode=void 0!==e?e:n.default.SCALE_MODE,i.hasLoaded=!1,i.isLoading=!1,i.source=null,i.origSource=null,i.imageType=null,i.sourceScale=1,i.premultipliedAlpha=!0,i.imageUrl=null,i.isPowerOfTwo=!1,i.mipmap=n.default.MIPMAP_TEXTURES,i.wrapMode=n.default.WRAP_MODE,i._glTextures={},i._enabled=0,i._virtalBoundId=-1,i._destroyed=!1,i.textureCacheIds=[],t&&i.loadSource(t),i}r.default=l},{"../settings":101,"../utils":125,"../utils/determineCrossOrigin":124,"bit-twiddle":1,eventemitter3:3}],113:[function(t,e,r){"use strict";r.__esModule=!0;var u=n(t("./BaseRenderTexture")),i=n(t("./Texture"));function n(t){return t&&t.__esModule?t:{default:t}}var h,o=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(l,h=i.default),l.prototype.resize=function(t,e,r){t=Math.ceil(t),e=Math.ceil(e),this.valid=0<t&&0<e,this._frame.width=this.orig.width=t,this._frame.height=this.orig.height=e,r||this.baseTexture.resize(t,e),this._updateUvs()},l.create=function(t,e,r,i){return new l(new u.default(t,e,r,i))},l);function l(t,e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l);var r=null;if(!(t instanceof u.default)){var i=arguments[1],n=arguments[2],o=arguments[3],s=arguments[4];console.warn("Please use RenderTexture.create("+i+", "+n+") instead of the ctor directly."),r=arguments[0],e=null,t=new u.default(i,n,o,s)}var a=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,h.call(this,t,e));return a.legacyRenderer=r,a.valid=!0,a._updateUvs(),a}r.default=o},{"./BaseRenderTexture":111,"./Texture":115}],114:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var c=t("../"),o=t("../utils");var s=(i(d,null,[{key:"BATCH_SIZE",get:function(){return 1e3}}]),d.prototype._updateResolution=function(t){var e=this.data.meta.scale,r=(0,o.getResolutionOfUrl)(t,null);return null===r&&(r=void 0!==e?parseFloat(e):1),1!==r&&(this.baseTexture.resolution=r,this.baseTexture.update()),r},d.prototype.parse=function(t){this._batchIndex=0,this._callback=t,this._frameKeys.length<=d.BATCH_SIZE?(this._processFrames(0),this._processAnimations(),this._parseComplete()):this._nextBatch()},d.prototype._processFrames=function(t){for(var e=t,r=d.BATCH_SIZE,i=this.baseTexture.sourceScale;e-t<r&&e<this._frameKeys.length;){var n=this._frameKeys[e],o=this._frames[n],s=o.frame;if(s){var a=null,u=null,h=!1!==o.trimmed&&o.sourceSize?o.sourceSize:o.frame,l=new c.Rectangle(0,0,Math.floor(h.w*i)/this.resolution,Math.floor(h.h*i)/this.resolution);a=o.rotated?new c.Rectangle(Math.floor(s.x*i)/this.resolution,Math.floor(s.y*i)/this.resolution,Math.floor(s.h*i)/this.resolution,Math.floor(s.w*i)/this.resolution):new c.Rectangle(Math.floor(s.x*i)/this.resolution,Math.floor(s.y*i)/this.resolution,Math.floor(s.w*i)/this.resolution,Math.floor(s.h*i)/this.resolution),!1!==o.trimmed&&o.spriteSourceSize&&(u=new c.Rectangle(Math.floor(o.spriteSourceSize.x*i)/this.resolution,Math.floor(o.spriteSourceSize.y*i)/this.resolution,Math.floor(s.w*i)/this.resolution,Math.floor(s.h*i)/this.resolution)),this.textures[n]=new c.Texture(this.baseTexture,a,l,u,o.rotated?2:0,o.anchor),c.Texture.addToCache(this.textures[n],n)}e++}},d.prototype._processAnimations=function(){var t=this.data.animations||{};for(var e in t){this.animations[e]=[];var r=t[e],i=Array.isArray(r),n=0;for(r=i?r:r[Symbol.iterator]();;){var o;if(i){if(n>=r.length)break;o=r[n++]}else{if((n=r.next()).done)break;o=n.value}var s=o;this.animations[e].push(this.textures[s])}}},d.prototype._parseComplete=function(){var t=this._callback;this._callback=null,this._batchIndex=0,t.call(this,this.textures)},d.prototype._nextBatch=function(){var t=this;this._processFrames(this._batchIndex*d.BATCH_SIZE),this._batchIndex++,setTimeout(function(){t._batchIndex*d.BATCH_SIZE<t._frameKeys.length?t._nextBatch():(t._processAnimations(),t._parseComplete())},0)},d.prototype.destroy=function(t){var e=0<arguments.length&&void 0!==t&&t;for(var r in this.textures)this.textures[r].destroy();this._frames=null,this._frameKeys=null,this.data=null,this.textures=null,e&&this.baseTexture.destroy(),this.baseTexture=null},d);function d(t,e){var r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,d),this.baseTexture=t,this.textures={},this.animations={},this.data=e,this.resolution=this._updateResolution(r||this.baseTexture.imageUrl),this._frames=this.data.frames,this._frameKeys=Object.keys(this._frames),this._batchIndex=0,this._callback=null}r.default=s},{"../":65,"../utils":125}],115:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o=d(t("./BaseTexture")),s=d(t("./VideoBaseTexture")),a=d(t("./TextureUvs")),u=d(t("eventemitter3")),h=t("../math"),l=t("../utils"),c=d(t("../settings"));function d(t){return t&&t.__esModule?t:{default:t}}var f,p=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(v,f=u.default),v.prototype.update=function(){this.baseTexture.update()},v.prototype.onBaseTextureLoaded=function(t){this._updateID++,this.noFrame?this.frame=new h.Rectangle(0,0,t.width,t.height):this.frame=this._frame,this.baseTexture.on("update",this.onBaseTextureUpdated,this),this.emit("update",this)},v.prototype.onBaseTextureUpdated=function(t){this._updateID++,this._frame.width=t.width,this._frame.height=t.height,this.emit("update",this)},v.prototype.destroy=function(t){this.baseTexture&&(t&&(l.TextureCache[this.baseTexture.imageUrl]&&v.removeFromCache(this.baseTexture.imageUrl),this.baseTexture.destroy()),this.baseTexture.off("update",this.onBaseTextureUpdated,this),this.baseTexture.off("loaded",this.onBaseTextureLoaded,this),this.baseTexture=null),this._frame=null,this._uvs=null,this.trim=null,this.orig=null,this.valid=!1,v.removeFromCache(this),this.textureCacheIds=null},v.prototype.clone=function(){return new v(this.baseTexture,this.frame,this.orig,this.trim,this.rotate,this.defaultAnchor)},v.prototype._updateUvs=function(){this._uvs||(this._uvs=new a.default),this._uvs.set(this._frame,this.baseTexture,this.rotate),this._updateID++},v.fromImage=function(t,e,r,i){var n=l.TextureCache[t];return n||(n=new v(o.default.fromImage(t,e,r,i)),v.addToCache(n,t)),n},v.fromFrame=function(t){var e=l.TextureCache[t];if(!e)throw new Error('The frameId "'+t+'" does not exist in the texture cache');return e},v.fromCanvas=function(t,e,r){var i=2<arguments.length&&void 0!==r?r:"canvas";return new v(o.default.fromCanvas(t,e,i))},v.fromVideo=function(t,e,r,i){return"string"==typeof t?v.fromVideoUrl(t,e,r,i):new v(s.default.fromVideo(t,e,i))},v.fromVideoUrl=function(t,e,r,i){return new v(s.default.fromUrl(t,e,r,i))},v.from=function(t){if("string"!=typeof t)return t instanceof HTMLImageElement?new v(o.default.from(t)):t instanceof HTMLCanvasElement?v.fromCanvas(t,c.default.SCALE_MODE,"HTMLCanvasElement"):t instanceof HTMLVideoElement?v.fromVideo(t):t instanceof o.default?new v(t):t;var e=l.TextureCache[t];return e||(null!==t.match(/\.(mp4|webm|ogg|h264|avi|mov)$/)?v.fromVideoUrl(t):v.fromImage(t))},v.fromLoader=function(t,e,r){var i=new o.default(t,void 0,(0,l.getResolutionOfUrl)(e)),n=new v(i);return i.imageUrl=e,r=r||e,o.default.addToCache(n.baseTexture,r),v.addToCache(n,r),r!==e&&(o.default.addToCache(n.baseTexture,e),v.addToCache(n,e)),n},v.addToCache=function(t,e){e&&(-1===t.textureCacheIds.indexOf(e)&&t.textureCacheIds.push(e),l.TextureCache[e]&&console.warn("Texture added to the cache with an id ["+e+"] that already had an entry"),l.TextureCache[e]=t)},v.removeFromCache=function(t){if("string"==typeof t){var e=l.TextureCache[t];if(e){var r=e.textureCacheIds.indexOf(t);return-1<r&&e.textureCacheIds.splice(r,1),delete l.TextureCache[t],e}}else if(t&&t.textureCacheIds){for(var i=0;i<t.textureCacheIds.length;++i)l.TextureCache[t.textureCacheIds[i]]===t&&delete l.TextureCache[t.textureCacheIds[i]];return t.textureCacheIds.length=0,t}return null},i(v,[{key:"frame",get:function(){return this._frame},set:function(t){this._frame=t,this.noFrame=!1;var e=t.x,r=t.y,i=t.width,n=t.height,o=e+i>this.baseTexture.width,s=r+n>this.baseTexture.height;if(o||s){var a=o&&s?"and":"or",u="X: "+e+" + "+i+" = "+(e+i)+" > "+this.baseTexture.width,h="Y: "+r+" + "+n+" = "+(r+n)+" > "+this.baseTexture.height;throw new Error("Texture Error: frame does not fit inside the base Texture dimensions: "+u+" "+a+" "+h)}this.valid=i&&n&&this.baseTexture.hasLoaded,this.trim||this.rotate||(this.orig=t),this.valid&&this._updateUvs()}},{key:"rotate",get:function(){return this._rotate},set:function(t){this._rotate=t,this.valid&&this._updateUvs()}},{key:"width",get:function(){return this.orig.width}},{key:"height",get:function(){return this.orig.height}}]),v);function v(t,e,r,i,n,o){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,v);var s=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,f.call(this));if(s.noFrame=!1,e||(s.noFrame=!0,e=new h.Rectangle(0,0,1,1)),t instanceof v&&(t=t.baseTexture),s.baseTexture=t,s._frame=e,s.trim=i,s.valid=!1,s.requiresUpdate=!1,s._uvs=null,s.orig=r||e,s._rotate=Number(n||0),!0===n)s._rotate=2;else if(s._rotate%2!=0)throw new Error("attempt to use diamond-shaped UVs. If you are sure, set rotation manually");return t.hasLoaded?(s.noFrame&&(e=new h.Rectangle(0,0,t.width,t.height),t.on("update",s.onBaseTextureUpdated,s)),s.frame=e):t.once("loaded",s.onBaseTextureLoaded,s),s.defaultAnchor=o?new h.Point(o.x,o.y):new h.Point(0,0),s._updateID=0,s.transform=null,s.textureCacheIds=[],s}function g(t){t.destroy=function(){},t.on=function(){},t.once=function(){},t.emit=function(){}}(r.default=p).EMPTY=new p(new o.default),g(p.EMPTY),g(p.EMPTY.baseTexture),p.WHITE=function(){var t=document.createElement("canvas");t.width=10,t.height=10;var e=t.getContext("2d");return e.fillStyle="white",e.fillRect(0,0,10,10),new p(new o.default(t))}(),g(p.WHITE),g(p.WHITE.baseTexture)},{"../math":70,"../settings":101,"../utils":125,"./BaseTexture":112,"./TextureUvs":117,"./VideoBaseTexture":118,eventemitter3:3}],116:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o,s=t("../math/Matrix"),a=(o=s)&&o.__esModule?o:{default:o};var h=new a.default,u=(l.prototype.multiplyUvs=function(t,e){void 0===e&&(e=t);for(var r=this.mapCoord,i=0;i<t.length;i+=2){var n=t[i],o=t[i+1];e[i]=n*r.a+o*r.c+r.tx,e[i+1]=n*r.b+o*r.d+r.ty}return e},l.prototype.update=function(t){var e=this._texture;if(!e||!e.valid)return!1;if(!t&&this._lastTextureID===e._updateID)return!1;this._lastTextureID=e._updateID;var r=e._uvs;this.mapCoord.set(r.x1-r.x0,r.y1-r.y0,r.x3-r.x0,r.y3-r.y0,r.x0,r.y0);var i=e.orig,n=e.trim;n&&(h.set(i.width/n.width,0,0,i.height/n.height,-n.x/n.width,-n.y/n.height),this.mapCoord.append(h));var o=e.baseTexture,s=this.uClampFrame,a=this.clampMargin/o.resolution,u=this.clampOffset;return s[0]=(e._frame.x+a+u)/o.width,s[1]=(e._frame.y+a+u)/o.height,s[2]=(e._frame.x+e._frame.width-a+u)/o.width,s[3]=(e._frame.y+e._frame.height-a+u)/o.height,this.uClampOffset[0]=u/o.realWidth,this.uClampOffset[1]=u/o.realHeight,!0},i(l,[{key:"texture",get:function(){return this._texture},set:function(t){this._texture=t,this._lastTextureID=-1}}]),l);function l(t,e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),this._texture=t,this.mapCoord=new a.default,this.uClampFrame=new Float32Array(4),this.uClampOffset=new Float32Array(2),this._lastTextureID=-1,this.clampOffset=0,this.clampMargin=void 0===e?.5:e}r.default=u},{"../math/Matrix":67}],117:[function(t,e,r){"use strict";r.__esModule=!0;var i,n=t("../math/GroupD8"),h=(i=n)&&i.__esModule?i:{default:i};var o=(s.prototype.set=function(t,e,r){var i=e.width,n=e.height;if(r){var o=t.width/2/i,s=t.height/2/n,a=t.x/i+o,u=t.y/n+s;r=h.default.add(r,h.default.NW),this.x0=a+o*h.default.uX(r),this.y0=u+s*h.default.uY(r),r=h.default.add(r,2),this.x1=a+o*h.default.uX(r),this.y1=u+s*h.default.uY(r),r=h.default.add(r,2),this.x2=a+o*h.default.uX(r),this.y2=u+s*h.default.uY(r),r=h.default.add(r,2),this.x3=a+o*h.default.uX(r),this.y3=u+s*h.default.uY(r)}else this.x0=t.x/i,this.y0=t.y/n,this.x1=(t.x+t.width)/i,this.y1=t.y/n,this.x2=(t.x+t.width)/i,this.y2=(t.y+t.height)/n,this.x3=t.x/i,this.y3=(t.y+t.height)/n;this.uvsUint32[0]=(65535&Math.round(65535*this.y0))<<16|65535&Math.round(65535*this.x0),this.uvsUint32[1]=(65535&Math.round(65535*this.y1))<<16|65535&Math.round(65535*this.x1),this.uvsUint32[2]=(65535&Math.round(65535*this.y2))<<16|65535&Math.round(65535*this.x2),this.uvsUint32[3]=(65535&Math.round(65535*this.y3))<<16|65535&Math.round(65535*this.x3)},s);function s(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,s),this.x0=0,this.y0=0,this.x1=1,this.y1=0,this.x2=1,this.y2=1,this.x3=0,this.y3=1,this.uvsUint32=new Uint32Array(4)}r.default=o},{"../math/GroupD8":66}],118:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o=l(t("./BaseTexture")),s=t("../utils"),a=t("../ticker"),u=t("../const"),h=l(t("../utils/determineCrossOrigin"));function l(t){return t&&t.__esModule?t:{default:t}}var c,d=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(f,c=o.default),f.prototype._isSourcePlaying=function(){var t=this.source;return 0<t.currentTime&&!1===t.paused&&!1===t.ended&&2<t.readyState},f.prototype._isSourceReady=function(){return 3===this.source.readyState||4===this.source.readyState},f.prototype._onPlayStart=function(){this.hasLoaded||this._onCanPlay(),!this._isAutoUpdating&&this.autoUpdate&&(a.shared.add(this.update,this,u.UPDATE_PRIORITY.HIGH),this._isAutoUpdating=!0)},f.prototype._onPlayStop=function(){this._isAutoUpdating&&(a.shared.remove(this.update,this),this._isAutoUpdating=!1)},f.prototype._onCanPlay=function(){this.hasLoaded=!0,this.source&&(this.source.removeEventListener("canplay",this._onCanPlay),this.source.removeEventListener("canplaythrough",this._onCanPlay),this.width=this.source.videoWidth,this.height=this.source.videoHeight,this.__loaded||(this.__loaded=!0,this.emit("loaded",this)),this._isSourcePlaying()?this._onPlayStart():this.autoPlay&&this.source.play())},f.prototype.destroy=function(){this._isAutoUpdating&&a.shared.remove(this.update,this),this.source&&this.source._pixiId&&(o.default.removeFromCache(this.source._pixiId),delete this.source._pixiId,this.source.pause(),this.source.src="",this.source.load()),c.prototype.destroy.call(this)},f.fromVideo=function(t,e,r){t._pixiId||(t._pixiId="video_"+(0,s.uid)());var i=s.BaseTextureCache[t._pixiId];return i||(i=new f(t,e,r),o.default.addToCache(i,t._pixiId)),i},f.fromUrl=function(t,e,r,i){var n=document.createElement("video");n.setAttribute("webkit-playsinline",""),n.setAttribute("playsinline","");var o=Array.isArray(t)?t[0].src||t[0]:t.src||t;if(void 0===r&&0!==o.indexOf("data:")?n.crossOrigin=(0,h.default)(o):r&&(n.crossOrigin="string"==typeof r?r:"anonymous"),Array.isArray(t))for(var s=0;s<t.length;++s)n.appendChild(p(t[s].src||t[s],t[s].mime));else n.appendChild(p(o,t.mime));return n.load(),f.fromVideo(n,e,i)},i(f,[{key:"autoUpdate",get:function(){return this._autoUpdate},set:function(t){t!==this._autoUpdate&&(this._autoUpdate=t,!this._autoUpdate&&this._isAutoUpdating?(a.shared.remove(this.update,this),this._isAutoUpdating=!1):this._autoUpdate&&!this._isAutoUpdating&&(a.shared.add(this.update,this,u.UPDATE_PRIORITY.HIGH),this._isAutoUpdating=!0))}}]),f);function f(t,e){var r=!(2<arguments.length&&void 0!==arguments[2])||arguments[2];if(!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,f),!t)throw new Error("No video source element specified.");(t.readyState===t.HAVE_ENOUGH_DATA||t.readyState===t.HAVE_FUTURE_DATA)&&t.width&&t.height&&(t.complete=!0);var i=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,c.call(this,t,e));return i.width=t.videoWidth,i.height=t.videoHeight,i._autoUpdate=!0,i._isAutoUpdating=!1,i.autoPlay=r,i.update=i.update.bind(i),i._onCanPlay=i._onCanPlay.bind(i),t.addEventListener("play",i._onPlayStart.bind(i)),t.addEventListener("pause",i._onPlayStop.bind(i)),i.hasLoaded=!1,i.__loaded=!1,i._isSourceReady()?i._onCanPlay():(t.addEventListener("canplay",i._onCanPlay),t.addEventListener("canplaythrough",i._onCanPlay)),i}function p(t,e){if(!e){var r=t.split("?").shift().toLowerCase();e="video/"+r.substr(r.lastIndexOf(".")+1)}var i=document.createElement("source");return i.src=t,i.type=e,i}(r.default=d).fromUrls=d.fromUrl},{"../const":46,"../ticker":121,"../utils":125,"../utils/determineCrossOrigin":124,"./BaseTexture":112}],119:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o=u(t("../settings")),s=t("../const"),a=u(t("./TickerListener"));function u(t){return t&&t.__esModule?t:{default:t}}var h=(l.prototype._requestIfNeeded=function(){null===this._requestId&&this._head.next&&(this.lastTime=performance.now(),this._requestId=requestAnimationFrame(this._tick))},l.prototype._cancelIfNeeded=function(){null!==this._requestId&&(cancelAnimationFrame(this._requestId),this._requestId=null)},l.prototype._startIfPossible=function(){this.started?this._requestIfNeeded():this.autoStart&&this.start()},l.prototype.add=function(t,e,r){var i=2<arguments.length&&void 0!==r?r:s.UPDATE_PRIORITY.NORMAL;return this._addListener(new a.default(t,e,i))},l.prototype.addOnce=function(t,e,r){var i=2<arguments.length&&void 0!==r?r:s.UPDATE_PRIORITY.NORMAL;return this._addListener(new a.default(t,e,i,!0))},l.prototype._addListener=function(t){var e=this._head.next,r=this._head;if(e){for(;e;){if(t.priority>e.priority){t.connect(r);break}e=(r=e).next}t.previous||t.connect(r)}else t.connect(r);return this._startIfPossible(),this},l.prototype.remove=function(t,e){for(var r=this._head.next;r;)r=r.match(t,e)?r.destroy():r.next;return this._head.next||this._cancelIfNeeded(),this},l.prototype.start=function(){this.started||(this.started=!0,this._requestIfNeeded())},l.prototype.stop=function(){this.started&&(this.started=!1,this._cancelIfNeeded())},l.prototype.destroy=function(){this.stop();for(var t=this._head.next;t;)t=t.destroy(!0);this._head.destroy(),this._head=null},l.prototype.update=function(t){var e=0<arguments.length&&void 0!==t?t:performance.now(),r=void 0;if(e>this.lastTime){(r=this.elapsedMS=e-this.lastTime)>this._maxElapsedMS&&(r=this._maxElapsedMS),this.deltaTime=r*o.default.TARGET_FPMS*this.speed;for(var i=this._head,n=i.next;n;)n=n.emit(this.deltaTime);i.next||this._cancelIfNeeded()}else this.deltaTime=this.elapsedMS=0;this.lastTime=e},i(l,[{key:"FPS",get:function(){return 1e3/this.elapsedMS}},{key:"minFPS",get:function(){return 1e3/this._maxElapsedMS},set:function(t){var e=Math.min(Math.max(0,t)/1e3,o.default.TARGET_FPMS);this._maxElapsedMS=1/e}}]),l);function l(){var e=this;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),this._head=new a.default(null,null,1/0),this._requestId=null,this._maxElapsedMS=100,this.autoStart=!1,this.deltaTime=1,this.elapsedMS=1/o.default.TARGET_FPMS,this.lastTime=-1,this.speed=1,this.started=!1,this._tick=function(t){e._requestId=null,e.started&&(e.update(t),e.started&&null===e._requestId&&e._head.next&&(e._requestId=requestAnimationFrame(e._tick)))}}r.default=h},{"../const":46,"../settings":101,"./TickerListener":120}],120:[function(t,e,r){"use strict";r.__esModule=!0;var i=(n.prototype.match=function(t,e){return e=e||null,this.fn===t&&this.context===e},n.prototype.emit=function(t){this.fn&&(this.context?this.fn.call(this.context,t):this.fn(t));var e=this.next;return this.once&&this.destroy(!0),this._destroyed&&(this.next=null),e},n.prototype.connect=function(t){(this.previous=t).next&&(t.next.previous=this),this.next=t.next,t.next=this},n.prototype.destroy=function(t){var e=0<arguments.length&&void 0!==t&&t;this._destroyed=!0,this.fn=null,this.context=null,this.previous&&(this.previous.next=this.next),this.next&&(this.next.previous=this.previous);var r=this.next;return this.next=e?null:r,this.previous=null,r},n);function n(t){var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null,r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:0,i=3<arguments.length&&void 0!==arguments[3]&&arguments[3];!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,n),this.fn=t,this.context=e,this.priority=r,this.once=i,this.next=null,this.previous=null,this._destroyed=!1}r.default=i},{}],121:[function(t,e,r){"use strict";r.__esModule=!0,r.Ticker=r.shared=void 0;var i,n=t("./Ticker"),o=(i=n)&&i.__esModule?i:{default:i};var s=new o.default;s.autoStart=!0,s.destroy=function(){},r.shared=s,r.Ticker=o.default},{"./Ticker":119}],122:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(){return!(navigator.platform&&/iPad|iPhone|iPod/.test(navigator.platform))}},{}],123:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t){for(var e=6*t,r=new Uint16Array(e),i=0,n=0;i<e;i+=6,n+=4)r[i+0]=n+0,r[i+1]=n+1,r[i+2]=n+2,r[i+3]=n+0,r[i+4]=n+2,r[i+5]=n+3;return r}},{}],124:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t){var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:window.location;if(0===t.indexOf("data:"))return"";e=e||window.location,s=s||document.createElement("a");s.href=t;var r=!(t=o.default.parse(s.href)).port&&""===e.port||t.port===e.port;return t.hostname===e.hostname&&r&&t.protocol===e.protocol?"":"anonymous"};var i,n=t("url"),o=(i=n)&&i.__esModule?i:{default:i};var s=void 0},{url:38}],125:[function(t,e,r){"use strict";r.__esModule=!0,r.premultiplyBlendMode=r.BaseTextureCache=r.TextureCache=r.earcut=r.mixins=r.pluginTarget=r.EventEmitter=r.removeItems=r.isMobile=void 0,r.uid=function(){return++p},r.hex2rgb=function(t,e){return(e=e||[])[0]=(t>>16&255)/255,e[1]=(t>>8&255)/255,e[2]=(255&t)/255,e},r.hex2string=function(t){return t=t.toString(16),"#"+(t="000000".substr(0,6-t.length)+t)},r.rgb2hex=function(t){return(255*t[0]<<16)+(255*t[1]<<8)+(255*t[2]|0)},r.getResolutionOfUrl=function(t,e){var r=n.default.RETINA_PREFIX.exec(t);if(r)return parseFloat(r[1]);return void 0!==e?e:1},r.decomposeDataUri=function(t){var e=i.DATA_URI.exec(t);if(e)return{mediaType:e[1]?e[1].toLowerCase():void 0,subType:e[2]?e[2].toLowerCase():void 0,charset:e[3]?e[3].toLowerCase():void 0,encoding:e[4]?e[4].toLowerCase():void 0,data:e[5]};return},r.getUrlFileExtension=function(t){var e=i.URL_FILE_EXTENSION.exec(t);if(e)return e[1].toLowerCase();return},r.getSvgSize=function(t){var e=i.SVG_SIZE.exec(t),r={};e&&(r[e[1]]=Math.round(parseFloat(e[3])),r[e[5]]=Math.round(parseFloat(e[7])));return r},r.skipHello=function(){v=!0},r.sayHello=function(t){if(v)return;if(-1<navigator.userAgent.toLowerCase().indexOf("chrome")){var e=["\n %c %c %c PixiJS "+i.VERSION+" - ✰ "+t+" ✰ %c %c http://www.pixijs.com/ %c %c ♥%c♥%c♥ \n\n","background: #ff66a5; padding:5px 0;","background: #ff66a5; padding:5px 0;","color: #ff66a5; background: #030307; padding:5px 0;","background: #ff66a5; padding:5px 0;","background: #ffc3dc; padding:5px 0;","background: #ff66a5; padding:5px 0;","color: #ff2424; background: #fff; padding:5px 0;","color: #ff2424; background: #fff; padding:5px 0;","color: #ff2424; background: #fff; padding:5px 0;"];window.console.log.apply(console,e)}else window.console&&window.console.log("PixiJS "+i.VERSION+" - "+t+" - http://www.pixijs.com/");v=!0},r.isWebGLSupported=function(){var t={stencil:!0,failIfMajorPerformanceCaveat:!0};try{if(!window.WebGLRenderingContext)return!1;var e=document.createElement("canvas"),r=e.getContext("webgl",t)||e.getContext("experimental-webgl",t),i=!(!r||!r.getContextAttributes().stencil);if(r){var n=r.getExtension("WEBGL_lose_context");n&&n.loseContext()}return r=null,i}catch(t){return!1}},r.sign=function(t){return 0===t?0:t<0?-1:1},r.destroyTextureCache=function(){var t=void 0;for(t in g)g[t].destroy();for(t in y)y[t].destroy()},r.clearTextureCache=function(){var t=void 0;for(t in g)delete g[t];for(t in y)delete y[t]},r.correctBlendMode=function(t,e){return m[e?1:0][t]},r.premultiplyTint=function(t,e){if(1===e)return(255*e<<24)+t;if(0===e)return 0;var r=t>>16&255,i=t>>8&255,n=255&t;return(255*e<<24)+((r=r*e+.5|0)<<16)+((i=i*e+.5|0)<<8)+(n=n*e+.5|0)},r.premultiplyRgba=function(t,e,r,i){r=r||new Float32Array(4),i||void 0===i?(r[0]=t[0]*e,r[1]=t[1]*e,r[2]=t[2]*e):(r[0]=t[0],r[1]=t[1],r[2]=t[2]);return r[3]=e,r},r.premultiplyTintToRgba=function(t,e,r,i){(r=r||new Float32Array(4))[0]=(t>>16&255)/255,r[1]=(t>>8&255)/255,r[2]=(255&t)/255,!i&&void 0!==i||(r[0]*=e,r[1]*=e,r[2]*=e);return r[3]=e,r};var i=t("../const"),n=f(t("../settings")),o=f(t("eventemitter3")),s=f(t("./pluginTarget")),a=d(t("./mixin")),u=d(t("ismobilejs")),h=f(t("remove-array-items")),l=f(t("./mapPremultipliedBlendModes")),c=f(t("earcut"));function d(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}function f(t){return t&&t.__esModule?t:{default:t}}var p=0,v=!1;r.isMobile=u,r.removeItems=h.default,r.EventEmitter=o.default,r.pluginTarget=s.default,r.mixins=a,r.earcut=c.default;var g=r.TextureCache=Object.create(null),y=r.BaseTextureCache=Object.create(null);var m=r.premultiplyBlendMode=(0,l.default)()},{"../const":46,"../settings":101,"./mapPremultipliedBlendModes":126,"./mixin":128,"./pluginTarget":129,earcut:2,eventemitter3:3,ismobilejs:4,"remove-array-items":31}],126:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(){for(var t=[],e=[],r=0;r<32;r++)t[r]=r,e[r]=r;t[n.BLEND_MODES.NORMAL_NPM]=n.BLEND_MODES.NORMAL,t[n.BLEND_MODES.ADD_NPM]=n.BLEND_MODES.ADD,t[n.BLEND_MODES.SCREEN_NPM]=n.BLEND_MODES.SCREEN,e[n.BLEND_MODES.NORMAL]=n.BLEND_MODES.NORMAL_NPM,e[n.BLEND_MODES.ADD]=n.BLEND_MODES.ADD_NPM,e[n.BLEND_MODES.SCREEN]=n.BLEND_MODES.SCREEN_NPM;var i=[];return i.push(e),i.push(t),i};var n=t("../const")},{"../const":46}],127:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t){if(o.default.tablet||o.default.phone)return 4;return t};var i,n=t("ismobilejs"),o=(i=n)&&i.__esModule?i:{default:i}},{ismobilejs:4}],128:[function(t,e,r){"use strict";function i(t,e){if(t&&e)for(var r=Object.keys(e),i=0;i<r.length;++i){var n=r[i];Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(e,n))}}r.__esModule=!0,r.mixin=i,r.delayMixin=function(t,e){n.push(t,e)},r.performMixins=function(){for(var t=0;t<n.length;t+=2)i(n[t],n[t+1]);n.length=0};var n=[]},{}],129:[function(t,e,r){"use strict";r.__esModule=!0,r.default={mixin:function(t){var r;(r=t).__plugins={},r.registerPlugin=function(t,e){r.__plugins[t]=e},r.prototype.initPlugins=function(){for(var t in this.plugins=this.plugins||{},r.__plugins)this.plugins[t]=new r.__plugins[t](this)},r.prototype.destroyPlugins=function(){for(var t in this.plugins)this.plugins[t].destroy(),this.plugins[t]=null;this.plugins=null}}}},{}],130:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t){var e=t.width,r=t.height,i=t.getContext("2d"),n=i.getImageData(0,0,e,r).data,o=n.length,s={top:null,left:null,right:null,bottom:null},a=null,u=void 0,h=void 0,l=void 0;for(u=0;u<o;u+=4)0!==n[u+3]&&(h=u/4%e,l=~~(u/4/e),null===s.top&&(s.top=l),null===s.left?s.left=h:h<s.left&&(s.left=h),null===s.right?s.right=h+1:s.right<h&&(s.right=h+1),null===s.bottom?s.bottom=l:s.bottom<l&&(s.bottom=l));null!==s.top&&(e=s.right-s.left,r=s.bottom-s.top+1,a=i.getImageData(s.left,s.top,e,r));return{height:r,width:e,data:a}}},{}],131:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(r){var t=r.mesh,e=r.particles,i=r.extras,n=r.filters,o=r.prepare,s=r.loaders,a=r.interaction;Object.defineProperties(r,{SpriteBatch:{get:function(){throw new ReferenceError("SpriteBatch does not exist any more, please use the new ParticleContainer instead.")}},AssetLoader:{get:function(){throw new ReferenceError("The loader system was overhauled in PixiJS v3, please see the new PIXI.loaders.Loader class.")}},Stage:{get:function(){return p("You do not need to use a PIXI Stage any more, you can simply render any container."),r.Container}},DisplayObjectContainer:{get:function(){return p("DisplayObjectContainer has been shortened to Container, please use Container from now on."),r.Container}},Strip:{get:function(){return p("The Strip class has been renamed to Mesh and moved to mesh.Mesh, please use mesh.Mesh from now on."),t.Mesh}},Rope:{get:function(){return p("The Rope class has been moved to mesh.Rope, please use mesh.Rope from now on."),t.Rope}},ParticleContainer:{get:function(){return p("The ParticleContainer class has been moved to particles.ParticleContainer, please use particles.ParticleContainer from now on."),e.ParticleContainer}},MovieClip:{get:function(){return p("The MovieClip class has been moved to extras.AnimatedSprite, please use extras.AnimatedSprite."),i.AnimatedSprite}},TilingSprite:{get:function(){return p("The TilingSprite class has been moved to extras.TilingSprite, please use extras.TilingSprite from now on."),i.TilingSprite}},BitmapText:{get:function(){return p("The BitmapText class has been moved to extras.BitmapText, please use extras.BitmapText from now on."),i.BitmapText}},blendModes:{get:function(){return p("The blendModes has been moved to BLEND_MODES, please use BLEND_MODES from now on."),r.BLEND_MODES}},scaleModes:{get:function(){return p("The scaleModes has been moved to SCALE_MODES, please use SCALE_MODES from now on."),r.SCALE_MODES}},BaseTextureCache:{get:function(){return p("The BaseTextureCache class has been moved to utils.BaseTextureCache, please use utils.BaseTextureCache from now on."),r.utils.BaseTextureCache}},TextureCache:{get:function(){return p("The TextureCache class has been moved to utils.TextureCache, please use utils.TextureCache from now on."),r.utils.TextureCache}},math:{get:function(){return p("The math namespace is deprecated, please access members already accessible on PIXI."),r}},AbstractFilter:{get:function(){return p("AstractFilter has been renamed to Filter, please use PIXI.Filter"),r.Filter}},TransformManual:{get:function(){return p("TransformManual has been renamed to TransformBase, please update your pixi-spine"),r.TransformBase}},TARGET_FPMS:{get:function(){return p("PIXI.TARGET_FPMS has been deprecated, please use PIXI.settings.TARGET_FPMS"),r.settings.TARGET_FPMS},set:function(t){p("PIXI.TARGET_FPMS has been deprecated, please use PIXI.settings.TARGET_FPMS"),r.settings.TARGET_FPMS=t}},FILTER_RESOLUTION:{get:function(){return p("PIXI.FILTER_RESOLUTION has been deprecated, please use PIXI.settings.FILTER_RESOLUTION"),r.settings.FILTER_RESOLUTION},set:function(t){p("PIXI.FILTER_RESOLUTION has been deprecated, please use PIXI.settings.FILTER_RESOLUTION"),r.settings.FILTER_RESOLUTION=t}},RESOLUTION:{get:function(){return p("PIXI.RESOLUTION has been deprecated, please use PIXI.settings.RESOLUTION"),r.settings.RESOLUTION},set:function(t){p("PIXI.RESOLUTION has been deprecated, please use PIXI.settings.RESOLUTION"),r.settings.RESOLUTION=t}},MIPMAP_TEXTURES:{get:function(){return p("PIXI.MIPMAP_TEXTURES has been deprecated, please use PIXI.settings.MIPMAP_TEXTURES"),r.settings.MIPMAP_TEXTURES},set:function(t){p("PIXI.MIPMAP_TEXTURES has been deprecated, please use PIXI.settings.MIPMAP_TEXTURES"),r.settings.MIPMAP_TEXTURES=t}},SPRITE_BATCH_SIZE:{get:function(){return p("PIXI.SPRITE_BATCH_SIZE has been deprecated, please use PIXI.settings.SPRITE_BATCH_SIZE"),r.settings.SPRITE_BATCH_SIZE},set:function(t){p("PIXI.SPRITE_BATCH_SIZE has been deprecated, please use PIXI.settings.SPRITE_BATCH_SIZE"),r.settings.SPRITE_BATCH_SIZE=t}},SPRITE_MAX_TEXTURES:{get:function(){return p("PIXI.SPRITE_MAX_TEXTURES has been deprecated, please use PIXI.settings.SPRITE_MAX_TEXTURES"),r.settings.SPRITE_MAX_TEXTURES},set:function(t){p("PIXI.SPRITE_MAX_TEXTURES has been deprecated, please use PIXI.settings.SPRITE_MAX_TEXTURES"),r.settings.SPRITE_MAX_TEXTURES=t}},RETINA_PREFIX:{get:function(){return p("PIXI.RETINA_PREFIX has been deprecated, please use PIXI.settings.RETINA_PREFIX"),r.settings.RETINA_PREFIX},set:function(t){p("PIXI.RETINA_PREFIX has been deprecated, please use PIXI.settings.RETINA_PREFIX"),r.settings.RETINA_PREFIX=t}},DEFAULT_RENDER_OPTIONS:{get:function(){return p("PIXI.DEFAULT_RENDER_OPTIONS has been deprecated, please use PIXI.settings.DEFAULT_RENDER_OPTIONS"),r.settings.RENDER_OPTIONS}}});for(var u=[{parent:"TRANSFORM_MODE",target:"TRANSFORM_MODE"},{parent:"GC_MODES",target:"GC_MODE"},{parent:"WRAP_MODES",target:"WRAP_MODE"},{parent:"SCALE_MODES",target:"SCALE_MODE"},{parent:"PRECISION",target:"PRECISION_FRAGMENT"}],h=function(t){var e=u[t];Object.defineProperty(r[e.parent],"DEFAULT",{get:function(){return p("PIXI."+e.parent+".DEFAULT has been deprecated, please use PIXI.settings."+e.target),r.settings[e.target]},set:function(t){p("PIXI."+e.parent+".DEFAULT has been deprecated, please use PIXI.settings."+e.target),r.settings[e.target]=t}})},l=0;l<u.length;l++)h(l);Object.defineProperties(r.settings,{PRECISION:{get:function(){return p("PIXI.settings.PRECISION has been deprecated, please use PIXI.settings.PRECISION_FRAGMENT"),r.settings.PRECISION_FRAGMENT},set:function(t){p("PIXI.settings.PRECISION has been deprecated, please use PIXI.settings.PRECISION_FRAGMENT"),r.settings.PRECISION_FRAGMENT=t}}}),i.AnimatedSprite&&Object.defineProperties(i,{MovieClip:{get:function(){return p("The MovieClip class has been renamed to AnimatedSprite, please use AnimatedSprite from now on."),i.AnimatedSprite}}});i&&Object.defineProperties(i,{TextureTransform:{get:function(){return p("The TextureTransform class has been renamed to TextureMatrix, please use PIXI.TextureMatrix from now on."),r.TextureMatrix}}});r.DisplayObject.prototype.generateTexture=function(t,e,r){return p("generateTexture has moved to the renderer, please use renderer.generateTexture(displayObject)"),t.generateTexture(this,e,r)},r.Graphics.prototype.generateTexture=function(t,e){return p("graphics generate texture has moved to the renderer. Or to render a graphics to a texture using canvas please use generateCanvasTexture"),this.generateCanvasTexture(t,e)},r.GroupD8.isSwapWidthHeight=function(t){return p("GroupD8.isSwapWidthHeight was renamed to GroupD8.isVertical"),r.GroupD8.isVertical(t)},r.RenderTexture.prototype.render=function(t,e,r,i){this.legacyRenderer.render(t,this,r,e,!i),p("RenderTexture.render is now deprecated, please use renderer.render(displayObject, renderTexture)")},r.RenderTexture.prototype.getImage=function(t){return p("RenderTexture.getImage is now deprecated, please use renderer.extract.image(target)"),this.legacyRenderer.extract.image(t)},r.RenderTexture.prototype.getBase64=function(t){return p("RenderTexture.getBase64 is now deprecated, please use renderer.extract.base64(target)"),this.legacyRenderer.extract.base64(t)},r.RenderTexture.prototype.getCanvas=function(t){return p("RenderTexture.getCanvas is now deprecated, please use renderer.extract.canvas(target)"),this.legacyRenderer.extract.canvas(t)},r.RenderTexture.prototype.getPixels=function(t){return p("RenderTexture.getPixels is now deprecated, please use renderer.extract.pixels(target)"),this.legacyRenderer.pixels(t)},r.Sprite.prototype.setTexture=function(t){this.texture=t,p("setTexture is now deprecated, please use the texture property, e.g : sprite.texture = texture;")},i.BitmapText&&(i.BitmapText.prototype.setText=function(t){this.text=t,p("setText is now deprecated, please use the text property, e.g : myBitmapText.text = 'my text';")});r.Text.prototype.setText=function(t){this.text=t,p("setText is now deprecated, please use the text property, e.g : myText.text = 'my text';")},r.Text.calculateFontProperties=function(t){return p("Text.calculateFontProperties is now deprecated, please use the TextMetrics.measureFont"),r.TextMetrics.measureFont(t)},Object.defineProperties(r.Text,{fontPropertiesCache:{get:function(){return p("Text.fontPropertiesCache is deprecated"),r.TextMetrics._fonts}},fontPropertiesCanvas:{get:function(){return p("Text.fontPropertiesCanvas is deprecated"),r.TextMetrics._canvas}},fontPropertiesContext:{get:function(){return p("Text.fontPropertiesContext is deprecated"),r.TextMetrics._context}}}),r.Text.prototype.setStyle=function(t){this.style=t,p("setStyle is now deprecated, please use the style property, e.g : myText.style = style;")},r.Text.prototype.determineFontProperties=function(t){return p("determineFontProperties is now deprecated, please use TextMetrics.measureFont method"),r.TextMetrics.measureFont(t)},r.Text.getFontStyle=function(t){return p("getFontStyle is now deprecated, please use TextStyle.toFontString() instead"),(t=t||{})instanceof r.TextStyle||(t=new r.TextStyle(t)),t.toFontString()},Object.defineProperties(r.TextStyle.prototype,{font:{get:function(){p("text style property 'font' is now deprecated, please use the 'fontFamily', 'fontSize', 'fontStyle', 'fontVariant' and 'fontWeight' properties from now on");var t="number"==typeof this._fontSize?this._fontSize+"px":this._fontSize;return this._fontStyle+" "+this._fontVariant+" "+this._fontWeight+" "+t+" "+this._fontFamily},set:function(t){p("text style property 'font' is now deprecated, please use the 'fontFamily','fontSize',fontStyle','fontVariant' and 'fontWeight' properties from now on"),1<t.indexOf("italic")?this._fontStyle="italic":-1<t.indexOf("oblique")?this._fontStyle="oblique":this._fontStyle="normal",-1<t.indexOf("small-caps")?this._fontVariant="small-caps":this._fontVariant="normal";var e=t.split(" "),r=-1;this._fontSize=26;for(var i=0;i<e.length;++i)if(e[i].match(/(px|pt|em|%)/)){r=i,this._fontSize=e[i];break}this._fontWeight="normal";for(var n=0;n<r;++n)if(e[n].match(/(bold|bolder|lighter|100|200|300|400|500|600|700|800|900)/)){this._fontWeight=e[n];break}if(-1<r&&r<e.length-1){this._fontFamily="";for(var o=r+1;o<e.length;++o)this._fontFamily+=e[o]+" ";this._fontFamily=this._fontFamily.slice(0,-1)}else this._fontFamily="Arial";this.styleID++}}}),r.Texture.prototype.setFrame=function(t){this.frame=t,p("setFrame is now deprecated, please use the frame property, e.g: myTexture.frame = frame;")},r.Texture.addTextureToCache=function(t,e){r.Texture.addToCache(t,e),p("Texture.addTextureToCache is deprecated, please use Texture.addToCache from now on.")},r.Texture.removeTextureFromCache=function(t){return p("Texture.removeTextureFromCache is deprecated, please use Texture.removeFromCache from now on. Be aware that Texture.removeFromCache does not automatically its BaseTexture from the BaseTextureCache. For that, use BaseTexture.removeFromCache"),r.BaseTexture.removeFromCache(t),r.Texture.removeFromCache(t)},Object.defineProperties(n,{AbstractFilter:{get:function(){return p("AstractFilter has been renamed to Filter, please use PIXI.Filter"),r.AbstractFilter}},SpriteMaskFilter:{get:function(){return p("filters.SpriteMaskFilter is an undocumented alias, please use SpriteMaskFilter from now on."),r.SpriteMaskFilter}},VoidFilter:{get:function(){return p("VoidFilter has been renamed to AlphaFilter, please use PIXI.filters.AlphaFilter"),n.AlphaFilter}}}),r.utils.uuid=function(){return p("utils.uuid() is deprecated, please use utils.uid() from now on."),r.utils.uid()},r.utils.canUseNewCanvasBlendModes=function(){return p("utils.canUseNewCanvasBlendModes() is deprecated, please use CanvasTinter.canUseMultiply from now on"),r.CanvasTinter.canUseMultiply};var c=!0;Object.defineProperty(r.utils,"_saidHello",{set:function(t){t&&(p("PIXI.utils._saidHello is deprecated, please use PIXI.utils.skipHello()"),this.skipHello()),c=t},get:function(){return c}}),o.BasePrepare&&(o.BasePrepare.prototype.register=function(t,e){return p("renderer.plugins.prepare.register is now deprecated, please use renderer.plugins.prepare.registerFindHook & renderer.plugins.prepare.registerUploadHook"),t&&this.registerFindHook(t),e&&this.registerUploadHook(e),this});o.canvas&&Object.defineProperty(o.canvas,"UPLOADS_PER_FRAME",{set:function(){p("PIXI.CanvasPrepare.UPLOADS_PER_FRAME has been removed. Please set renderer.plugins.prepare.limiter.maxItemsPerFrame on your renderer")},get:function(){return p("PIXI.CanvasPrepare.UPLOADS_PER_FRAME has been removed. Please use renderer.plugins.prepare.limiter"),NaN}});o.webgl&&Object.defineProperty(o.webgl,"UPLOADS_PER_FRAME",{set:function(){p("PIXI.WebGLPrepare.UPLOADS_PER_FRAME has been removed. Please set renderer.plugins.prepare.limiter.maxItemsPerFrame on your renderer")},get:function(){return p("PIXI.WebGLPrepare.UPLOADS_PER_FRAME has been removed. Please use renderer.plugins.prepare.limiter"),NaN}});if(s.Loader){var d=s.Resource,f=s.Loader;Object.defineProperties(d.prototype,{isJson:{get:function(){return p("The isJson property is deprecated, please use `resource.type === Resource.TYPE.JSON`."),this.type===d.TYPE.JSON}},isXml:{get:function(){return p("The isXml property is deprecated, please use `resource.type === Resource.TYPE.XML`."),this.type===d.TYPE.XML}},isImage:{get:function(){return p("The isImage property is deprecated, please use `resource.type === Resource.TYPE.IMAGE`."),this.type===d.TYPE.IMAGE}},isAudio:{get:function(){return p("The isAudio property is deprecated, please use `resource.type === Resource.TYPE.AUDIO`."),this.type===d.TYPE.AUDIO}},isVideo:{get:function(){return p("The isVideo property is deprecated, please use `resource.type === Resource.TYPE.VIDEO`."),this.type===d.TYPE.VIDEO}}}),Object.defineProperties(f.prototype,{before:{get:function(){return p("The before() method is deprecated, please use pre()."),this.pre}},after:{get:function(){return p("The after() method is deprecated, please use use()."),this.use}}})}a.interactiveTarget&&Object.defineProperty(a.interactiveTarget,"defaultCursor",{set:function(t){p("Property defaultCursor has been replaced with 'cursor'. "),this.cursor=t},get:function(){return p("Property defaultCursor has been replaced with 'cursor'. "),this.cursor}});a.InteractionManager&&(Object.defineProperty(a.InteractionManager,"defaultCursorStyle",{set:function(t){p("Property defaultCursorStyle has been replaced with 'cursorStyles.default'. "),this.cursorStyles.default=t},get:function(){return p("Property defaultCursorStyle has been replaced with 'cursorStyles.default'. "),this.cursorStyles.default}}),Object.defineProperty(a.InteractionManager,"currentCursorStyle",{set:function(t){p("Property currentCursorStyle has been removed.See the currentCursorMode property, which works differently."),this.currentCursorMode=t},get:function(){return p("Property currentCursorStyle has been removed.See the currentCursorMode property, which works differently."),this.currentCursorMode}}))};var i={};function p(t){if(!i[t]){var e=(new Error).stack;void 0===e?console.warn("Deprecation Warning: ",t):(e=e.split("\n").splice(3).join("\n"),console.groupCollapsed?(console.groupCollapsed("%cDeprecation Warning: %c%s","color:#614108;background:#fffbe6","font-weight:normal;color:#614108;background:#fffbe6",t),console.warn(e),console.groupEnd()):(console.warn("Deprecation Warning: ",t),console.warn(e))),i[t]=!0}}},{}],132:[function(t,e,r){"use strict";r.__esModule=!0;var l=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../../core"));var c=new l.Rectangle,i=(n.prototype.image=function(t){var e=new Image;return e.src=this.base64(t),e},n.prototype.base64=function(t){return this.canvas(t).toDataURL()},n.prototype.canvas=function(t){var e=this.renderer,r=void 0,i=void 0,n=void 0,o=void 0;t&&(o=t instanceof l.RenderTexture?t:e.generateTexture(t)),o?(r=o.baseTexture._canvasRenderTarget.context,i=o.baseTexture._canvasRenderTarget.resolution,n=o.frame):(r=e.rootContext,i=e.resolution,(n=c).width=this.renderer.width,n.height=this.renderer.height);var s=Math.floor(n.width*i+1e-4),a=Math.floor(n.height*i+1e-4),u=new l.CanvasRenderTarget(s,a,1),h=r.getImageData(n.x*i,n.y*i,s,a);return u.context.putImageData(h,0,0),u.canvas},n.prototype.pixels=function(t){var e=this.renderer,r=void 0,i=void 0,n=void 0,o=void 0;return t&&(o=t instanceof l.RenderTexture?t:e.generateTexture(t)),o?(r=o.baseTexture._canvasRenderTarget.context,i=o.baseTexture._canvasRenderTarget.resolution,n=o.frame):(r=e.rootContext,(n=c).width=e.width,n.height=e.height),r.getImageData(0,0,n.width*i,n.height*i).data},n.prototype.destroy=function(){this.renderer.extract=null,this.renderer=null},n);function n(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,n),(this.renderer=t).extract=this}r.default=i,l.CanvasRenderer.registerPlugin("extract",i)},{"../../core":65}],133:[function(t,e,r){"use strict";r.__esModule=!0;var i=t("./webgl/WebGLExtract");Object.defineProperty(r,"webgl",{enumerable:!0,get:function(){return o(i).default}});var n=t("./canvas/CanvasExtract");function o(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(r,"canvas",{enumerable:!0,get:function(){return o(n).default}})},{"./canvas/CanvasExtract":132,"./webgl/WebGLExtract":134}],134:[function(t,e,r){"use strict";r.__esModule=!0;var p=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../../core"));var v=new p.Rectangle,i=(n.prototype.image=function(t){var e=new Image;return e.src=this.base64(t),e},n.prototype.base64=function(t){return this.canvas(t).toDataURL()},n.prototype.canvas=function(t){var e=this.renderer,r=void 0,i=void 0,n=void 0,o=!1,s=void 0,a=!1;t&&(t instanceof p.RenderTexture?s=t:(s=this.renderer.generateTexture(t),a=!0)),s?(i=(r=s.baseTexture._glRenderTargets[this.renderer.CONTEXT_UID]).resolution,n=s.frame,o=!1):(i=(r=this.renderer.rootRenderTarget).resolution,o=!0,(n=v).width=r.size.width,n.height=r.size.height);var u=Math.floor(n.width*i+1e-4),h=Math.floor(n.height*i+1e-4),l=new p.CanvasRenderTarget(u,h,1);if(r){e.bindRenderTarget(r);var c=new Uint8Array(4*u*h),d=e.gl;d.readPixels(n.x*i,n.y*i,u,h,d.RGBA,d.UNSIGNED_BYTE,c);var f=l.context.getImageData(0,0,u,h);f.data.set(c),l.context.putImageData(f,0,0),o&&(l.context.scale(1,-1),l.context.drawImage(l.canvas,0,-h))}return a&&s.destroy(!0),l.canvas},n.prototype.pixels=function(t){var e=this.renderer,r=void 0,i=void 0,n=void 0,o=void 0,s=!1;t&&(t instanceof p.RenderTexture?o=t:(o=this.renderer.generateTexture(t),s=!0)),o?(i=(r=o.baseTexture._glRenderTargets[this.renderer.CONTEXT_UID]).resolution,n=o.frame):(i=(r=this.renderer.rootRenderTarget).resolution,(n=v).width=r.size.width,n.height=r.size.height);var a=n.width*i,u=n.height*i,h=new Uint8Array(4*a*u);if(r){e.bindRenderTarget(r);var l=e.gl;l.readPixels(n.x*i,n.y*i,a,u,l.RGBA,l.UNSIGNED_BYTE,h)}return s&&o.destroy(!0),h},n.prototype.destroy=function(){this.renderer.extract=null,this.renderer=null},n);function n(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,n),(this.renderer=t).extract=this}r.default=i,p.WebGLRenderer.registerPlugin("extract",i)},{"../../core":65}],135:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../core"));var s,a=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(u,s=o.Sprite),u.prototype.stop=function(){this.playing&&(this.playing=!1,this._autoUpdate&&o.ticker.shared.remove(this.update,this))},u.prototype.play=function(){this.playing||(this.playing=!0,this._autoUpdate&&o.ticker.shared.add(this.update,this,o.UPDATE_PRIORITY.HIGH))},u.prototype.gotoAndStop=function(t){this.stop();var e=this.currentFrame;this._currentTime=t,e!==this.currentFrame&&this.updateTexture()},u.prototype.gotoAndPlay=function(t){var e=this.currentFrame;this._currentTime=t,e!==this.currentFrame&&this.updateTexture(),this.play()},u.prototype.update=function(t){var e=this.animationSpeed*t,r=this.currentFrame;if(null!==this._durations){var i=this._currentTime%1*this._durations[this.currentFrame];for(i+=e/60*1e3;i<0;)this._currentTime--,i+=this._durations[this.currentFrame];var n=Math.sign(this.animationSpeed*t);for(this._currentTime=Math.floor(this._currentTime);i>=this._durations[this.currentFrame];)i-=this._durations[this.currentFrame]*n,this._currentTime+=n;this._currentTime+=i/this._durations[this.currentFrame]}else this._currentTime+=e;this._currentTime<0&&!this.loop?(this.gotoAndStop(0),this.onComplete&&this.onComplete()):this._currentTime>=this._textures.length&&!this.loop?(this.gotoAndStop(this._textures.length-1),this.onComplete&&this.onComplete()):r!==this.currentFrame&&(this.loop&&this.onLoop&&(0<this.animationSpeed&&this.currentFrame<r?this.onLoop():this.animationSpeed<0&&this.currentFrame>r&&this.onLoop()),this.updateTexture())},u.prototype.updateTexture=function(){this._texture=this._textures[this.currentFrame],this._textureID=-1,this.cachedTint=16777215,this.updateAnchor&&this._anchor.copy(this._texture.defaultAnchor),this.onFrameChange&&this.onFrameChange(this.currentFrame)},u.prototype.destroy=function(t){this.stop(),s.prototype.destroy.call(this,t)},u.fromFrames=function(t){for(var e=[],r=0;r<t.length;++r)e.push(o.Texture.fromFrame(t[r]));return new u(e)},u.fromImages=function(t){for(var e=[],r=0;r<t.length;++r)e.push(o.Texture.fromImage(t[r]));return new u(e)},i(u,[{key:"totalFrames",get:function(){return this._textures.length}},{key:"textures",get:function(){return this._textures},set:function(t){if(t[0]instanceof o.Texture)this._textures=t,this._durations=null;else{this._textures=[],this._durations=[];for(var e=0;e<t.length;e++)this._textures.push(t[e].texture),this._durations.push(t[e].time)}this.gotoAndStop(0),this.updateTexture()}},{key:"currentFrame",get:function(){var t=Math.floor(this._currentTime)%this._textures.length;return t<0&&(t+=this._textures.length),t}}]),u);function u(t,e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,u);var r=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,s.call(this,t[0]instanceof o.Texture?t[0]:t[0].texture));return r._textures=null,r._durations=null,r.textures=t,r._autoUpdate=!1!==e,r.animationSpeed=1,r.loop=!0,r.updateAnchor=!1,r.onComplete=null,r.onFrameChange=null,r.onLoop=null,r._currentTime=0,r.playing=!1,r}r.default=a},{"../core":65}],136:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var R=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../core")),o=s(t("../core/math/ObservablePoint")),w=t("../core/utils"),E=s(t("../core/settings"));function s(t){return t&&t.__esModule?t:{default:t}}var a,u=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(A,a=R.Container),A.prototype.updateText=function(){for(var t=A.fonts[this._font.name],e=this._font.size/t.size,r=new R.Point,i=[],n=[],o=this.text.replace(/(?:\r\n|\r)/g,"\n"),s=o.length,a=this._maxWidth*t.size/this._font.size,u=null,h=0,l=0,c=0,d=-1,f=0,p=0,v=0,g=0;g<s;g++){var y=o.charCodeAt(g),m=o.charAt(g);if(/(?:\s)/.test(m)&&(d=g,f=h),"\r"!==m&&"\n"!==m){var _=t.chars[y];_&&(u&&_.kerning[u]&&(r.x+=_.kerning[u]),i.push({texture:_.texture,line:c,charCode:y,position:new R.Point(r.x+_.xOffset+this._letterSpacing/2,r.y+_.yOffset)}),r.x+=_.xAdvance+this._letterSpacing,h=r.x,v=Math.max(v,_.yOffset+_.texture.height),u=y,-1!==d&&0<a&&r.x>a&&(++p,R.utils.removeItems(i,1+d-p,1+g-d),g=d,d=-1,n.push(f),l=Math.max(l,f),c++,r.x=0,r.y+=t.lineHeight,u=null))}else n.push(h),l=Math.max(l,h),++c,++p,r.x=0,r.y+=t.lineHeight,u=null}var x=o.charAt(o.length-1);"\r"!==x&&"\n"!==x&&(/(?:\s)/.test(x)&&(h=f),n.push(h),l=Math.max(l,h));for(var b=[],T=0;T<=c;T++){var w=0;"right"===this._font.align?w=l-n[T]:"center"===this._font.align&&(w=(l-n[T])/2),b.push(w)}for(var E=i.length,S=this.tint,O=0;O<E;O++){var M=this._glyphs[O];M?M.texture=i[O].texture:(M=new R.Sprite(i[O].texture),this._glyphs.push(M)),M.position.x=(i[O].position.x+b[i[O].line])*e,M.position.y=i[O].position.y*e,M.scale.x=M.scale.y=e,M.tint=S,M.parent||this.addChild(M)}for(var P=E;P<this._glyphs.length;++P)this.removeChild(this._glyphs[P]);if(this._textWidth=l*e,this._textHeight=(r.y+t.lineHeight)*e,0!==this.anchor.x||0!==this.anchor.y)for(var C=0;C<E;C++)this._glyphs[C].x-=this._textWidth*this.anchor.x,this._glyphs[C].y-=this._textHeight*this.anchor.y;this._maxLineHeight=v*e},A.prototype.updateTransform=function(){this.validate(),this.containerUpdateTransform()},A.prototype.getLocalBounds=function(){return this.validate(),a.prototype.getLocalBounds.call(this)},A.prototype.validate=function(){this.dirty&&(this.updateText(),this.dirty=!1)},A.registerFont=function(t,e){var r={},i=t.getElementsByTagName("info")[0],n=t.getElementsByTagName("common")[0],o=t.getElementsByTagName("page"),s=(0,w.getResolutionOfUrl)(o[0].getAttribute("file"),E.default.RESOLUTION),a={};r.font=i.getAttribute("face"),r.size=parseInt(i.getAttribute("size"),10),r.lineHeight=parseInt(n.getAttribute("lineHeight"),10)/s,r.chars={},e instanceof R.Texture&&(e=[e]);for(var u=0;u<o.length;u++){var h=o[u].getAttribute("id"),l=o[u].getAttribute("file");a[h]=e instanceof Array?e[u]:e[l]}for(var c=t.getElementsByTagName("char"),d=0;d<c.length;d++){var f=c[d],p=parseInt(f.getAttribute("id"),10),v=f.getAttribute("page")||0,g=new R.Rectangle(parseInt(f.getAttribute("x"),10)/s+a[v].frame.x/s,parseInt(f.getAttribute("y"),10)/s+a[v].frame.y/s,parseInt(f.getAttribute("width"),10)/s,parseInt(f.getAttribute("height"),10)/s);r.chars[p]={xOffset:parseInt(f.getAttribute("xoffset"),10)/s,yOffset:parseInt(f.getAttribute("yoffset"),10)/s,xAdvance:parseInt(f.getAttribute("xadvance"),10)/s,kerning:{},texture:new R.Texture(a[v].baseTexture,g),page:v}}for(var y=t.getElementsByTagName("kerning"),m=0;m<y.length;m++){var _=y[m],x=parseInt(_.getAttribute("first"),10)/s,b=parseInt(_.getAttribute("second"),10)/s,T=parseInt(_.getAttribute("amount"),10)/s;r.chars[b]&&(r.chars[b].kerning[x]=T)}return A.fonts[r.font]=r},i(A,[{key:"tint",get:function(){return this._font.tint},set:function(t){this._font.tint="number"==typeof t&&0<=t?t:16777215,this.dirty=!0}},{key:"align",get:function(){return this._font.align},set:function(t){this._font.align=t||"left",this.dirty=!0}},{key:"anchor",get:function(){return this._anchor},set:function(t){"number"==typeof t?this._anchor.set(t):this._anchor.copy(t)}},{key:"font",get:function(){return this._font},set:function(t){t&&("string"==typeof t?(t=t.split(" "),this._font.name=1===t.length?t[0]:t.slice(1).join(" "),this._font.size=2<=t.length?parseInt(t[0],10):A.fonts[this._font.name].size):(this._font.name=t.name,this._font.size="number"==typeof t.size?t.size:parseInt(t.size,10)),this.dirty=!0)}},{key:"text",get:function(){return this._text},set:function(t){t=t.toString()||" ",this._text!==t&&(this._text=t,this.dirty=!0)}},{key:"maxWidth",get:function(){return this._maxWidth},set:function(t){this._maxWidth!==t&&(this._maxWidth=t,this.dirty=!0)}},{key:"maxLineHeight",get:function(){return this.validate(),this._maxLineHeight}},{key:"textWidth",get:function(){return this.validate(),this._textWidth}},{key:"letterSpacing",get:function(){return this._letterSpacing},set:function(t){this._letterSpacing!==t&&(this._letterSpacing=t,this.dirty=!0)}},{key:"textHeight",get:function(){return this.validate(),this._textHeight}}]),A);function A(t){var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,A);var r=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,a.call(this));return r._textWidth=0,r._textHeight=0,r._glyphs=[],r._font={tint:void 0!==e.tint?e.tint:16777215,align:e.align||"left",name:null,size:0},r.font=e.font,r._text=t,r._maxWidth=0,r._maxLineHeight=0,r._letterSpacing=0,r._anchor=new o.default(function(){r.dirty=!0},r,0,0),r.dirty=!1,r.updateText(),r}(r.default=u).fonts={}},{"../core":65,"../core/math/ObservablePoint":68,"../core/settings":101,"../core/utils":125}],137:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o,b=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../core")),s=t("../core/sprites/canvas/CanvasTinter"),T=(o=s)&&o.__esModule?o:{default:o};var a,u=new b.Point,h=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(l,a=b.Sprite),l.prototype._onTextureUpdate=function(){this.uvTransform&&(this.uvTransform.texture=this._texture),this.cachedTint=16777215},l.prototype._renderWebGL=function(t){var e=this._texture;e&&e.valid&&(this.tileTransform.updateLocalTransform(),this.uvTransform.update(),t.setObjectRenderer(t.plugins[this.pluginName]),t.plugins[this.pluginName].render(this))},l.prototype._renderCanvas=function(t){var e=this._texture;if(e.baseTexture.hasLoaded){var r=t.context,i=this.worldTransform,n=t.resolution,o=2===e.rotate,s=e.baseTexture,a=s.resolution,u=this.tilePosition.x/this.tileScale.x%e.orig.width*a,h=this.tilePosition.y/this.tileScale.y%e.orig.height*a;if(this._textureID!==this._texture._updateID||this.cachedTint!==this.tint){this._textureID=this._texture._updateID;var l=new b.CanvasRenderTarget(e.orig.width,e.orig.height,a);if(16777215!==this.tint)this.tintedTexture=T.default.getTintedTexture(this,this.tint),l.context.drawImage(this.tintedTexture,0,0);else{var c=e._frame.x*a,d=e._frame.y*a,f=e._frame.width*a,p=e._frame.height*a,v=(e.trim?e.trim.width:e.orig.width)*a,g=(e.trim?e.trim.height:e.orig.height)*a,y=(e.trim?e.trim.x:0)*a,m=(e.trim?e.trim.y:0)*a;o?(l.context.rotate(-Math.PI/2),l.context.translate(-g,0),l.context.drawImage(s.source,c,d,f,p,-m,y,g,v)):l.context.drawImage(s.source,c,d,f,p,y,m,v,g)}this.cachedTint=this.tint,this._canvasPattern=l.context.createPattern(l.canvas,"repeat")}r.globalAlpha=this.worldAlpha,r.setTransform(i.a*n,i.b*n,i.c*n,i.d*n,i.tx*n,i.ty*n),t.setBlendMode(this.blendMode),r.fillStyle=this._canvasPattern,r.scale(this.tileScale.x/a,this.tileScale.y/a);var _=this.anchor.x*-this._width*a,x=this.anchor.y*-this._height*a;this.uvRespectAnchor?(r.translate(u,h),r.fillRect(_-u,x-h,this._width/this.tileScale.x*a,this._height/this.tileScale.y*a)):(r.translate(u+_,h+x),r.fillRect(-u,-h,this._width/this.tileScale.x*a,this._height/this.tileScale.y*a))}},l.prototype._calculateBounds=function(){var t=this._width*-this._anchor._x,e=this._height*-this._anchor._y,r=this._width*(1-this._anchor._x),i=this._height*(1-this._anchor._y);this._bounds.addFrame(this.transform,t,e,r,i)},l.prototype.getLocalBounds=function(t){return 0===this.children.length?(this._bounds.minX=this._width*-this._anchor._x,this._bounds.minY=this._height*-this._anchor._y,this._bounds.maxX=this._width*(1-this._anchor._x),this._bounds.maxY=this._height*(1-this._anchor._y),t||(this._localBoundsRect||(this._localBoundsRect=new b.Rectangle),t=this._localBoundsRect),this._bounds.getRectangle(t)):a.prototype.getLocalBounds.call(this,t)},l.prototype.containsPoint=function(t){this.worldTransform.applyInverse(t,u);var e=this._width,r=this._height,i=-e*this.anchor._x;if(u.x>=i&&u.x<i+e){var n=-r*this.anchor._y;if(u.y>=n&&u.y<n+r)return!0}return!1},l.prototype.destroy=function(t){a.prototype.destroy.call(this,t),this.tileTransform=null,this.uvTransform=null},l.from=function(t,e,r){return new l(b.Texture.from(t),e,r)},l.fromFrame=function(t,e,r){var i=b.utils.TextureCache[t];if(!i)throw new Error('The frameId "'+t+'" does not exist in the texture cache '+this);return new l(i,e,r)},l.fromImage=function(t,e,r,i,n){return new l(b.Texture.fromImage(t,i,n),e,r)},i(l,[{key:"clampMargin",get:function(){return this.uvTransform.clampMargin},set:function(t){this.uvTransform.clampMargin=t,this.uvTransform.update(!0)}},{key:"tileScale",get:function(){return this.tileTransform.scale},set:function(t){this.tileTransform.scale.copy(t)}},{key:"tilePosition",get:function(){return this.tileTransform.position},set:function(t){this.tileTransform.position.copy(t)}},{key:"width",get:function(){return this._width},set:function(t){this._width=t}},{key:"height",get:function(){return this._height},set:function(t){this._height=t}}]),l);function l(t){var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:100,r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:100;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l);var i=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,a.call(this,t));return i.tileTransform=new b.TransformStatic,i._width=e,i._height=r,i._canvasPattern=null,i.uvTransform=t.transform||new b.TextureMatrix(t),i.pluginName="tilingSprite",i.uvRespectAnchor=!1,i}r.default=h},{"../core":65,"../core/sprites/canvas/CanvasTinter":104}],138:[function(t,e,r){"use strict";var l=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../core")),c=i(t("../core/textures/Texture")),d=i(t("../core/textures/BaseTexture")),f=t("../core/utils");function i(t){return t&&t.__esModule?t:{default:t}}var n=l.DisplayObject,p=new l.Matrix;n.prototype._cacheAsBitmap=!1,n.prototype._cacheData=!1;function o(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,o),this.textureCacheId=null,this.originalRenderWebGL=null,this.originalRenderCanvas=null,this.originalCalculateBounds=null,this.originalGetLocalBounds=null,this.originalUpdateTransform=null,this.originalHitTest=null,this.originalDestroy=null,this.originalMask=null,this.originalFilterArea=null,this.sprite=null}Object.defineProperties(n.prototype,{cacheAsBitmap:{get:function(){return this._cacheAsBitmap},set:function(t){if(this._cacheAsBitmap!==t){var e=void 0;(this._cacheAsBitmap=t)?(this._cacheData||(this._cacheData=new o),(e=this._cacheData).originalRenderWebGL=this.renderWebGL,e.originalRenderCanvas=this.renderCanvas,e.originalUpdateTransform=this.updateTransform,e.originalCalculateBounds=this.calculateBounds,e.originalGetLocalBounds=this.getLocalBounds,e.originalDestroy=this.destroy,e.originalContainsPoint=this.containsPoint,e.originalMask=this._mask,e.originalFilterArea=this.filterArea,this.renderWebGL=this._renderCachedWebGL,this.renderCanvas=this._renderCachedCanvas,this.destroy=this._cacheAsBitmapDestroy):((e=this._cacheData).sprite&&this._destroyCachedDisplayObject(),this.renderWebGL=e.originalRenderWebGL,this.renderCanvas=e.originalRenderCanvas,this.calculateBounds=e.originalCalculateBounds,this.getLocalBounds=e.originalGetLocalBounds,this.destroy=e.originalDestroy,this.updateTransform=e.originalUpdateTransform,this.containsPoint=e.originalContainsPoint,this._mask=e.originalMask,this.filterArea=e.originalFilterArea)}}}}),n.prototype._renderCachedWebGL=function(t){!this.visible||this.worldAlpha<=0||!this.renderable||(this._initCachedDisplayObject(t),this._cacheData.sprite.transform._worldID=this.transform._worldID,this._cacheData.sprite.worldAlpha=this.worldAlpha,this._cacheData.sprite._renderWebGL(t))},n.prototype._initCachedDisplayObject=function(t){if(!this._cacheData||!this._cacheData.sprite){var e=this.alpha;this.alpha=1,t.currentRenderer.flush();var r=this.getLocalBounds().clone();if(this._filters&&this._filters.length){var i=this._filters[0].padding;r.pad(i)}r.ceil(l.settings.RESOLUTION);var n=t._activeRenderTarget,o=t.filterManager.filterStack,s=l.RenderTexture.create(r.width,r.height),a="cacheAsBitmap_"+(0,f.uid)();this._cacheData.textureCacheId=a,d.default.addToCache(s.baseTexture,a),c.default.addToCache(s,a);var u=p;u.tx=-r.x,u.ty=-r.y,this.transform.worldTransform.identity(),this.renderWebGL=this._cacheData.originalRenderWebGL,t.render(this,s,!0,u,!0),t.bindRenderTarget(n),t.filterManager.filterStack=o,this.renderWebGL=this._renderCachedWebGL,this.updateTransform=this.displayObjectUpdateTransform,this.calculateBounds=this._calculateCachedBounds,this.getLocalBounds=this._getCachedLocalBounds,this._mask=null,this.filterArea=null;var h=new l.Sprite(s);h.transform.worldTransform=this.transform.worldTransform,h.anchor.x=-r.x/r.width,h.anchor.y=-r.y/r.height,h.alpha=e,h._bounds=this._bounds,this._cacheData.sprite=h,this.transform._parentID=-1,this.parent?this.updateTransform():(this.parent=t._tempDisplayObjectParent,this.updateTransform(),this.parent=null),this.containsPoint=h.containsPoint.bind(h)}},n.prototype._renderCachedCanvas=function(t){!this.visible||this.worldAlpha<=0||!this.renderable||(this._initCachedDisplayObjectCanvas(t),this._cacheData.sprite.worldAlpha=this.worldAlpha,this._cacheData.sprite._renderCanvas(t))},n.prototype._initCachedDisplayObjectCanvas=function(t){if(!this._cacheData||!this._cacheData.sprite){var e=this.getLocalBounds(),r=this.alpha;this.alpha=1;var i=t.context;e.ceil(l.settings.RESOLUTION);var n=l.RenderTexture.create(e.width,e.height),o="cacheAsBitmap_"+(0,f.uid)();this._cacheData.textureCacheId=o,d.default.addToCache(n.baseTexture,o),c.default.addToCache(n,o);var s=p;this.transform.localTransform.copy(s),s.invert(),s.tx-=e.x,s.ty-=e.y,this.renderCanvas=this._cacheData.originalRenderCanvas,t.render(this,n,!0,s,!1),t.context=i,this.renderCanvas=this._renderCachedCanvas,this.updateTransform=this.displayObjectUpdateTransform,this.calculateBounds=this._calculateCachedBounds,this.getLocalBounds=this._getCachedLocalBounds,this._mask=null,this.filterArea=null;var a=new l.Sprite(n);a.transform.worldTransform=this.transform.worldTransform,a.anchor.x=-e.x/e.width,a.anchor.y=-e.y/e.height,a.alpha=r,a._bounds=this._bounds,this._cacheData.sprite=a,this.transform._parentID=-1,this.parent?this.updateTransform():(this.parent=t._tempDisplayObjectParent,this.updateTransform(),this.parent=null),this.containsPoint=a.containsPoint.bind(a)}},n.prototype._calculateCachedBounds=function(){this._bounds.clear(),this._cacheData.sprite.transform._worldID=this.transform._worldID,this._cacheData.sprite._calculateBounds(),this._lastBoundsID=this._boundsID},n.prototype._getCachedLocalBounds=function(){return this._cacheData.sprite.getLocalBounds()},n.prototype._destroyCachedDisplayObject=function(){this._cacheData.sprite._texture.destroy(!0),this._cacheData.sprite=null,d.default.removeFromCache(this._cacheData.textureCacheId),c.default.removeFromCache(this._cacheData.textureCacheId),this._cacheData.textureCacheId=null},n.prototype._cacheAsBitmapDestroy=function(t){this.cacheAsBitmap=!1,this.destroy(t)}},{"../core":65,"../core/textures/BaseTexture":112,"../core/textures/Texture":115,"../core/utils":125}],139:[function(t,e,r){"use strict";var i=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../core"));i.DisplayObject.prototype.name=null,i.Container.prototype.getChildByName=function(t){for(var e=0;e<this.children.length;e++)if(this.children[e].name===t)return this.children[e];return null}},{"../core":65}],140:[function(t,e,r){"use strict";var n=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../core"));n.DisplayObject.prototype.getGlobalPosition=function(t,e){var r=0<arguments.length&&void 0!==t?t:new n.Point,i=1<arguments.length&&void 0!==e&&e;return this.parent?this.parent.toGlobal(this.position,r,i):(r.x=this.position.x,r.y=this.position.y),r}},{"../core":65}],141:[function(t,e,r){"use strict";r.__esModule=!0,r.BitmapText=r.TilingSpriteRenderer=r.TilingSprite=r.AnimatedSprite=void 0;var i=t("./AnimatedSprite");Object.defineProperty(r,"AnimatedSprite",{enumerable:!0,get:function(){return a(i).default}});var n=t("./TilingSprite");Object.defineProperty(r,"TilingSprite",{enumerable:!0,get:function(){return a(n).default}});var o=t("./webgl/TilingSpriteRenderer");Object.defineProperty(r,"TilingSpriteRenderer",{enumerable:!0,get:function(){return a(o).default}});var s=t("./BitmapText");function a(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(r,"BitmapText",{enumerable:!0,get:function(){return a(s).default}}),t("./cacheAsBitmap"),t("./getChildByName"),t("./getGlobalPosition")},{"./AnimatedSprite":135,"./BitmapText":136,"./TilingSprite":137,"./cacheAsBitmap":138,"./getChildByName":139,"./getGlobalPosition":140,"./webgl/TilingSpriteRenderer":142}],142:[function(t,e,r){"use strict";r.__esModule=!0;var p=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../../core")),v=t("../../core/const");t("path");var i,g=new p.Matrix,n=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(o,i=p.ObjectRenderer),o.prototype.onContextChange=function(){var t=this.renderer.gl;this.shader=new p.Shader(t,"attribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\n\nuniform mat3 projectionMatrix;\nuniform mat3 translationMatrix;\nuniform mat3 uTransform;\n\nvarying vec2 vTextureCoord;\n\nvoid main(void)\n{\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n\n vTextureCoord = (uTransform * vec3(aTextureCoord, 1.0)).xy;\n}\n","varying vec2 vTextureCoord;\n\nuniform sampler2D uSampler;\nuniform vec4 uColor;\nuniform mat3 uMapCoord;\nuniform vec4 uClampFrame;\nuniform vec2 uClampOffset;\n\nvoid main(void)\n{\n vec2 coord = mod(vTextureCoord - uClampOffset, vec2(1.0, 1.0)) + uClampOffset;\n coord = (uMapCoord * vec3(coord, 1.0)).xy;\n coord = clamp(coord, uClampFrame.xy, uClampFrame.zw);\n\n vec4 sample = texture2D(uSampler, coord);\n gl_FragColor = sample * uColor;\n}\n"),this.simpleShader=new p.Shader(t,"attribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\n\nuniform mat3 projectionMatrix;\nuniform mat3 translationMatrix;\nuniform mat3 uTransform;\n\nvarying vec2 vTextureCoord;\n\nvoid main(void)\n{\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n\n vTextureCoord = (uTransform * vec3(aTextureCoord, 1.0)).xy;\n}\n","varying vec2 vTextureCoord;\n\nuniform sampler2D uSampler;\nuniform vec4 uColor;\n\nvoid main(void)\n{\n vec4 sample = texture2D(uSampler, vTextureCoord);\n gl_FragColor = sample * uColor;\n}\n"),this.renderer.bindVao(null),this.quad=new p.Quad(t,this.renderer.state.attribState),this.quad.initVao(this.shader)},o.prototype.render=function(t){var e=this.renderer,r=this.quad;e.bindVao(r.vao);var i=r.vertices;i[0]=i[6]=t._width*-t.anchor.x,i[1]=i[3]=t._height*-t.anchor.y,i[2]=i[4]=t._width*(1-t.anchor.x),i[5]=i[7]=t._height*(1-t.anchor.y),t.uvRespectAnchor&&((i=r.uvs)[0]=i[6]=-t.anchor.x,i[1]=i[3]=-t.anchor.y,i[2]=i[4]=1-t.anchor.x,i[5]=i[7]=1-t.anchor.y),r.upload();var n=t._texture,o=n.baseTexture,s=t.tileTransform.localTransform,a=t.uvTransform,u=o.isPowerOfTwo&&n.frame.width===o.width&&n.frame.height===o.height;u&&(o._glTextures[e.CONTEXT_UID]?u=o.wrapMode!==v.WRAP_MODES.CLAMP:o.wrapMode===v.WRAP_MODES.CLAMP&&(o.wrapMode=v.WRAP_MODES.REPEAT));var h=u?this.simpleShader:this.shader;e.bindShader(h);var l=n.width,c=n.height,d=t._width,f=t._height;g.set(s.a*l/d,s.b*l/f,s.c*c/d,s.d*c/f,s.tx/d,s.ty/f),g.invert(),u?g.prepend(a.mapCoord):(h.uniforms.uMapCoord=a.mapCoord.toArray(!0),h.uniforms.uClampFrame=a.uClampFrame,h.uniforms.uClampOffset=a.uClampOffset),h.uniforms.uTransform=g.toArray(!0),h.uniforms.uColor=p.utils.premultiplyTintToRgba(t.tint,t.worldAlpha,h.uniforms.uColor,o.premultipliedAlpha),h.uniforms.translationMatrix=t.transform.worldTransform.toArray(!0),h.uniforms.uSampler=e.bindTexture(n),e.setBlendMode(p.utils.correctBlendMode(t.blendMode,o.premultipliedAlpha)),r.vao.draw(this.renderer.gl.TRIANGLES,6,0)},o);function o(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,o);var e=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,i.call(this,t));return e.shader=null,e.simpleShader=null,e.quad=null,e}r.default=n,p.WebGLRenderer.registerPlugin("tilingSprite",n)},{"../../core":65,"../../core/const":46,path:8}],143:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../../core"));t("path");var s,a=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(u,s=o.Filter),i(u,[{key:"alpha",get:function(){return this.uniforms.uAlpha},set:function(t){this.uniforms.uAlpha=t}}]),u);function u(){var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:1;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,u);var e=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,s.call(this,"attribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\n\nuniform mat3 projectionMatrix;\n\nvarying vec2 vTextureCoord;\n\nvoid main(void)\n{\n gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n vTextureCoord = aTextureCoord;\n}","varying vec2 vTextureCoord;\n\nuniform sampler2D uSampler;\nuniform float uAlpha;\n\nvoid main(void)\n{\n gl_FragColor = texture2D(uSampler, vTextureCoord) * uAlpha;\n}\n"));return e.alpha=t,e.glShaderKey="alpha",e}r.default=a},{"../../core":65,path:8}],144:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../../core")),s=u(t("./BlurXFilter")),a=u(t("./BlurYFilter"));function u(t){return t&&t.__esModule?t:{default:t}}var h,l=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(c,h=o.Filter),c.prototype.apply=function(t,e,r){var i=t.getRenderTarget(!0);this.blurXFilter.apply(t,e,i,!0),this.blurYFilter.apply(t,i,r,!1),t.returnRenderTarget(i)},i(c,[{key:"blur",get:function(){return this.blurXFilter.blur},set:function(t){this.blurXFilter.blur=this.blurYFilter.blur=t,this.padding=2*Math.max(Math.abs(this.blurXFilter.strength),Math.abs(this.blurYFilter.strength))}},{key:"quality",get:function(){return this.blurXFilter.quality},set:function(t){this.blurXFilter.quality=this.blurYFilter.quality=t}},{key:"blurX",get:function(){return this.blurXFilter.blur},set:function(t){this.blurXFilter.blur=t,this.padding=2*Math.max(Math.abs(this.blurXFilter.strength),Math.abs(this.blurYFilter.strength))}},{key:"blurY",get:function(){return this.blurYFilter.blur},set:function(t){this.blurYFilter.blur=t,this.padding=2*Math.max(Math.abs(this.blurXFilter.strength),Math.abs(this.blurYFilter.strength))}},{key:"blendMode",get:function(){return this.blurYFilter._blendMode},set:function(t){this.blurYFilter._blendMode=t}}]),c);function c(t,e,r,i){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,c);var n=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,h.call(this));return n.blurXFilter=new s.default(t,e,r,i),n.blurYFilter=new a.default(t,e,r,i),n.padding=0,n.resolution=r||o.settings.RESOLUTION,n.quality=e||4,n.blur=t||8,n}r.default=l},{"../../core":65,"./BlurXFilter":145,"./BlurYFilter":146}],145:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var a=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../../core")),c=o(t("./generateBlurVertSource")),d=o(t("./generateBlurFragSource")),f=o(t("./getMaxBlurKernelSize"));function o(t){return t&&t.__esModule?t:{default:t}}var u,s=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(h,u=a.Filter),h.prototype.apply=function(t,e,r,i){if(this.firstRun){var n=t.renderer.gl,o=(0,f.default)(n);this.vertexSrc=(0,c.default)(o,!0),this.fragmentSrc=(0,d.default)(o),this.firstRun=!1}if(this.uniforms.strength=1/r.size.width*(r.size.width/e.size.width),this.uniforms.strength*=this.strength,this.uniforms.strength/=this.passes,1===this.passes)t.applyFilter(this,e,r,i);else{for(var s=t.getRenderTarget(!0),a=e,u=s,h=0;h<this.passes-1;h++){t.applyFilter(this,a,u,!0);var l=u;u=a,a=l}t.applyFilter(this,a,r,i),t.returnRenderTarget(s)}},i(h,[{key:"blur",get:function(){return this.strength},set:function(t){this.padding=2*Math.abs(t),this.strength=t}},{key:"quality",get:function(){return this._quality},set:function(t){this._quality=t,this.passes=t}}]),h);function h(t,e,r,i){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,h),i=i||5;var n=(0,c.default)(i,!0),o=(0,d.default)(i),s=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,u.call(this,n,o));return s.resolution=r||a.settings.RESOLUTION,s._quality=0,s.quality=e||4,s.strength=t||8,s.firstRun=!0,s}r.default=s},{"../../core":65,"./generateBlurFragSource":147,"./generateBlurVertSource":148,"./getMaxBlurKernelSize":149}],146:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var a=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../../core")),c=o(t("./generateBlurVertSource")),d=o(t("./generateBlurFragSource")),f=o(t("./getMaxBlurKernelSize"));function o(t){return t&&t.__esModule?t:{default:t}}var u,s=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(h,u=a.Filter),h.prototype.apply=function(t,e,r,i){if(this.firstRun){var n=t.renderer.gl,o=(0,f.default)(n);this.vertexSrc=(0,c.default)(o,!1),this.fragmentSrc=(0,d.default)(o),this.firstRun=!1}if(this.uniforms.strength=1/r.size.height*(r.size.height/e.size.height),this.uniforms.strength*=this.strength,this.uniforms.strength/=this.passes,1===this.passes)t.applyFilter(this,e,r,i);else{for(var s=t.getRenderTarget(!0),a=e,u=s,h=0;h<this.passes-1;h++){t.applyFilter(this,a,u,!0);var l=u;u=a,a=l}t.applyFilter(this,a,r,i),t.returnRenderTarget(s)}},i(h,[{key:"blur",get:function(){return this.strength},set:function(t){this.padding=2*Math.abs(t),this.strength=t}},{key:"quality",get:function(){return this._quality},set:function(t){this._quality=t,this.passes=t}}]),h);function h(t,e,r,i){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,h),i=i||5;var n=(0,c.default)(i,!1),o=(0,d.default)(i),s=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,u.call(this,n,o));return s.resolution=r||a.settings.RESOLUTION,s._quality=0,s.quality=e||4,s.strength=t||8,s.firstRun=!0,s}r.default=s},{"../../core":65,"./generateBlurFragSource":147,"./generateBlurVertSource":148,"./getMaxBlurKernelSize":149}],147:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t){for(var e=u[t],r=e.length,i=h,n="",o=void 0,s=0;s<t;s++){var a="gl_FragColor += texture2D(uSampler, vBlurTexCoords[%index%]) * %value%;".replace("%index%",s);r<=(o=s)&&(o=t-s-1),a=a.replace("%value%",e[o]),n+=a,n+="\n"}return i=(i=i.replace("%blur%",n)).replace("%size%",t)};var u={5:[.153388,.221461,.250301],7:[.071303,.131514,.189879,.214607],9:[.028532,.067234,.124009,.179044,.20236],11:[.0093,.028002,.065984,.121703,.175713,.198596],13:[.002406,.009255,.027867,.065666,.121117,.174868,.197641],15:[489e-6,.002403,.009246,.02784,.065602,.120999,.174697,.197448]},h=["varying vec2 vBlurTexCoords[%size%];","uniform sampler2D uSampler;","void main(void)","{"," gl_FragColor = vec4(0.0);"," %blur%","}"].join("\n")},{}],148:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t,e){var r=Math.ceil(t/2),i=u,n="",o=void 0;o=e?"vBlurTexCoords[%index%] = aTextureCoord + vec2(%sampleIndex% * strength, 0.0);":"vBlurTexCoords[%index%] = aTextureCoord + vec2(0.0, %sampleIndex% * strength);";for(var s=0;s<t;s++){var a=o.replace("%index%",s);a=a.replace("%sampleIndex%",s-(r-1)+".0"),n+=a,n+="\n"}return i=(i=i.replace("%blur%",n)).replace("%size%",t)};var u=["attribute vec2 aVertexPosition;","attribute vec2 aTextureCoord;","uniform float strength;","uniform mat3 projectionMatrix;","varying vec2 vBlurTexCoords[%size%];","void main(void)","{","gl_Position = vec4((projectionMatrix * vec3((aVertexPosition), 1.0)).xy, 0.0, 1.0);","%blur%","}"].join("\n")},{}],149:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t){var e=t.getParameter(t.MAX_VARYING_VECTORS),r=15;for(;e<r;)r-=2;return r}},{}],150:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../../core"));t("path");var s,a=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(u,s=o.Filter),u.prototype._loadMatrix=function(t,e){var r=t;1<arguments.length&&void 0!==e&&e&&(this._multiply(r,this.uniforms.m,t),r=this._colorMatrix(r)),this.uniforms.m=r},u.prototype._multiply=function(t,e,r){return t[0]=e[0]*r[0]+e[1]*r[5]+e[2]*r[10]+e[3]*r[15],t[1]=e[0]*r[1]+e[1]*r[6]+e[2]*r[11]+e[3]*r[16],t[2]=e[0]*r[2]+e[1]*r[7]+e[2]*r[12]+e[3]*r[17],t[3]=e[0]*r[3]+e[1]*r[8]+e[2]*r[13]+e[3]*r[18],t[4]=e[0]*r[4]+e[1]*r[9]+e[2]*r[14]+e[3]*r[19]+e[4],t[5]=e[5]*r[0]+e[6]*r[5]+e[7]*r[10]+e[8]*r[15],t[6]=e[5]*r[1]+e[6]*r[6]+e[7]*r[11]+e[8]*r[16],t[7]=e[5]*r[2]+e[6]*r[7]+e[7]*r[12]+e[8]*r[17],t[8]=e[5]*r[3]+e[6]*r[8]+e[7]*r[13]+e[8]*r[18],t[9]=e[5]*r[4]+e[6]*r[9]+e[7]*r[14]+e[8]*r[19]+e[9],t[10]=e[10]*r[0]+e[11]*r[5]+e[12]*r[10]+e[13]*r[15],t[11]=e[10]*r[1]+e[11]*r[6]+e[12]*r[11]+e[13]*r[16],t[12]=e[10]*r[2]+e[11]*r[7]+e[12]*r[12]+e[13]*r[17],t[13]=e[10]*r[3]+e[11]*r[8]+e[12]*r[13]+e[13]*r[18],t[14]=e[10]*r[4]+e[11]*r[9]+e[12]*r[14]+e[13]*r[19]+e[14],t[15]=e[15]*r[0]+e[16]*r[5]+e[17]*r[10]+e[18]*r[15],t[16]=e[15]*r[1]+e[16]*r[6]+e[17]*r[11]+e[18]*r[16],t[17]=e[15]*r[2]+e[16]*r[7]+e[17]*r[12]+e[18]*r[17],t[18]=e[15]*r[3]+e[16]*r[8]+e[17]*r[13]+e[18]*r[18],t[19]=e[15]*r[4]+e[16]*r[9]+e[17]*r[14]+e[18]*r[19]+e[19],t},u.prototype._colorMatrix=function(t){var e=new Float32Array(t);return e[4]/=255,e[9]/=255,e[14]/=255,e[19]/=255,e},u.prototype.brightness=function(t,e){var r=[t,0,0,0,0,0,t,0,0,0,0,0,t,0,0,0,0,0,1,0];this._loadMatrix(r,e)},u.prototype.greyscale=function(t,e){var r=[t,t,t,0,0,t,t,t,0,0,t,t,t,0,0,0,0,0,1,0];this._loadMatrix(r,e)},u.prototype.blackAndWhite=function(t){this._loadMatrix([.3,.6,.1,0,0,.3,.6,.1,0,0,.3,.6,.1,0,0,0,0,0,1,0],t)},u.prototype.hue=function(t,e){t=(t||0)/180*Math.PI;var r=Math.cos(t),i=Math.sin(t),n=(0,Math.sqrt)(1/3),o=[r+1/3*(1-r),1/3*(1-r)-n*i,1/3*(1-r)+n*i,0,0,1/3*(1-r)+n*i,r+1/3*(1-r),1/3*(1-r)-n*i,0,0,1/3*(1-r)-n*i,1/3*(1-r)+n*i,r+1/3*(1-r),0,0,0,0,0,1,0];this._loadMatrix(o,e)},u.prototype.contrast=function(t,e){var r=(t||0)+1,i=-.5*(r-1),n=[r,0,0,0,i,0,r,0,0,i,0,0,r,0,i,0,0,0,1,0];this._loadMatrix(n,e)},u.prototype.saturate=function(t,e){var r=e,i=2*(0<arguments.length&&void 0!==t?t:0)/3+1,n=-.5*(i-1),o=[i,n,n,0,0,n,i,n,0,0,n,n,i,0,0,0,0,0,1,0];this._loadMatrix(o,r)},u.prototype.desaturate=function(){this.saturate(-1)},u.prototype.negative=function(t){this._loadMatrix([-1,0,0,1,0,0,-1,0,1,0,0,0,-1,1,0,0,0,0,1,0],t)},u.prototype.sepia=function(t){this._loadMatrix([.393,.7689999,.18899999,0,0,.349,.6859999,.16799999,0,0,.272,.5339999,.13099999,0,0,0,0,0,1,0],t)},u.prototype.technicolor=function(t){this._loadMatrix([1.9125277891456083,-.8545344976951645,-.09155508482755585,0,11.793603434377337,-.3087833385928097,1.7658908555458428,-.10601743074722245,0,-70.35205161461398,-.231103377548616,-.7501899197440212,1.847597816108189,0,30.950940869491138,0,0,0,1,0],t)},u.prototype.polaroid=function(t){this._loadMatrix([1.438,-.062,-.062,0,0,-.122,1.378,-.122,0,0,-.016,-.016,1.483,0,0,0,0,0,1,0],t)},u.prototype.toBGR=function(t){this._loadMatrix([0,0,1,0,0,0,1,0,0,0,1,0,0,0,0,0,0,0,1,0],t)},u.prototype.kodachrome=function(t){this._loadMatrix([1.1285582396593525,-.3967382283601348,-.03992559172921793,0,63.72958762196502,-.16404339962244616,1.0835251566291304,-.05498805115633132,0,24.732407896706203,-.16786010706155763,-.5603416277695248,1.6014850761964943,0,35.62982807460946,0,0,0,1,0],t)},u.prototype.browni=function(t){this._loadMatrix([.5997023498159715,.34553243048391263,-.2708298674538042,0,47.43192855600873,-.037703249837783157,.8609577587992641,.15059552388459913,0,-36.96841498319127,.24113635128153335,-.07441037908422492,.44972182064877153,0,-7.562075277591283,0,0,0,1,0],t)},u.prototype.vintage=function(t){this._loadMatrix([.6279345635605994,.3202183420819367,-.03965408211312453,0,9.651285835294123,.02578397704808868,.6441188644374771,.03259127616149294,0,7.462829176470591,.0466055556782719,-.0851232987247891,.5241648018700465,0,5.159190588235296,0,0,0,1,0],t)},u.prototype.colorTone=function(t,e,r,i,n){var o=((r=r||16770432)>>16&255)/255,s=(r>>8&255)/255,a=(255&r)/255,u=((i=i||3375104)>>16&255)/255,h=(i>>8&255)/255,l=(255&i)/255,c=[.3,.59,.11,0,0,o,s,a,t=t||.2,0,u,h,l,e=e||.15,0,o-u,s-h,a-l,0,0];this._loadMatrix(c,n)},u.prototype.night=function(t,e){var r=[-2*(t=t||.1),-t,0,0,0,-t,0,t,0,0,0,t,2*t,0,0,0,0,0,1,0];this._loadMatrix(r,e)},u.prototype.predator=function(t,e){var r=[11.224130630493164*t,-4.794486999511719*t,-2.8746118545532227*t,0*t,.40342438220977783*t,-3.6330697536468506*t,9.193157196044922*t,-2.951810836791992*t,0*t,-1.316135048866272*t,-3.2184197902679443*t,-4.2375030517578125*t,7.476448059082031*t,0*t,.8044459223747253*t,0,0,0,1,0];this._loadMatrix(r,e)},u.prototype.lsd=function(t){this._loadMatrix([2,-.4,.5,0,0,-.5,2,-.4,0,0,-.4,-.5,3,0,0,0,0,0,1,0],t)},u.prototype.reset=function(){this._loadMatrix([1,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,1,0],!1)},i(u,[{key:"matrix",get:function(){return this.uniforms.m},set:function(t){this.uniforms.m=t}},{key:"alpha",get:function(){return this.uniforms.uAlpha},set:function(t){this.uniforms.uAlpha=t}}]),u);function u(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,u);var t=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,s.call(this,"attribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\n\nuniform mat3 projectionMatrix;\n\nvarying vec2 vTextureCoord;\n\nvoid main(void)\n{\n gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n vTextureCoord = aTextureCoord;\n}","varying vec2 vTextureCoord;\nuniform sampler2D uSampler;\nuniform float m[20];\nuniform float uAlpha;\n\nvoid main(void)\n{\n vec4 c = texture2D(uSampler, vTextureCoord);\n\n if (uAlpha == 0.0) {\n gl_FragColor = c;\n return;\n }\n\n // Un-premultiply alpha before applying the color matrix. See issue #3539.\n if (c.a > 0.0) {\n c.rgb /= c.a;\n }\n\n vec4 result;\n\n result.r = (m[0] * c.r);\n result.r += (m[1] * c.g);\n result.r += (m[2] * c.b);\n result.r += (m[3] * c.a);\n result.r += m[4];\n\n result.g = (m[5] * c.r);\n result.g += (m[6] * c.g);\n result.g += (m[7] * c.b);\n result.g += (m[8] * c.a);\n result.g += m[9];\n\n result.b = (m[10] * c.r);\n result.b += (m[11] * c.g);\n result.b += (m[12] * c.b);\n result.b += (m[13] * c.a);\n result.b += m[14];\n\n result.a = (m[15] * c.r);\n result.a += (m[16] * c.g);\n result.a += (m[17] * c.b);\n result.a += (m[18] * c.a);\n result.a += m[19];\n\n vec3 rgb = mix(c.rgb, result.rgb, uAlpha);\n\n // Premultiply alpha again.\n rgb *= result.a;\n\n gl_FragColor = vec4(rgb, result.a);\n}\n"));return t.uniforms.m=[1,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,1,0],t.alpha=1,t}(r.default=a).prototype.grayscale=a.prototype.greyscale},{"../../core":65,path:8}],151:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../../core"));t("path");var s,a=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(u,s=o.Filter),u.prototype.apply=function(t,e,r){this.uniforms.filterMatrix=t.calculateSpriteMatrix(this.maskMatrix,this.maskSprite),this.uniforms.scale.x=this.scale.x,this.uniforms.scale.y=this.scale.y,t.applyFilter(this,e,r)},i(u,[{key:"map",get:function(){return this.uniforms.mapSampler},set:function(t){this.uniforms.mapSampler=t}}]),u);function u(t,e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,u);var r=new o.Matrix;t.renderable=!1;var i=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,s.call(this,"attribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\n\nuniform mat3 projectionMatrix;\nuniform mat3 filterMatrix;\n\nvarying vec2 vTextureCoord;\nvarying vec2 vFilterCoord;\n\nvoid main(void)\n{\n gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n vFilterCoord = ( filterMatrix * vec3( aTextureCoord, 1.0) ).xy;\n vTextureCoord = aTextureCoord;\n}","varying vec2 vFilterCoord;\nvarying vec2 vTextureCoord;\n\nuniform vec2 scale;\n\nuniform sampler2D uSampler;\nuniform sampler2D mapSampler;\n\nuniform vec4 filterArea;\nuniform vec4 filterClamp;\n\nvoid main(void)\n{\n vec4 map = texture2D(mapSampler, vFilterCoord);\n\n map -= 0.5;\n map.xy *= scale / filterArea.xy;\n\n gl_FragColor = texture2D(uSampler, clamp(vec2(vTextureCoord.x + map.x, vTextureCoord.y + map.y), filterClamp.xy, filterClamp.zw));\n}\n"));return i.maskSprite=t,i.maskMatrix=r,i.uniforms.mapSampler=t._texture,i.uniforms.filterMatrix=r,i.uniforms.scale={x:1,y:1},null==e&&(e=20),i.scale=new o.Point(e,e),i}r.default=a},{"../../core":65,path:8}],152:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../../core"));t("path");var n,o=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(s,n=i.Filter),s);function s(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,s),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,n.call(this,"\nattribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\n\nuniform mat3 projectionMatrix;\n\nvarying vec2 v_rgbNW;\nvarying vec2 v_rgbNE;\nvarying vec2 v_rgbSW;\nvarying vec2 v_rgbSE;\nvarying vec2 v_rgbM;\n\nuniform vec4 filterArea;\n\nvarying vec2 vTextureCoord;\n\nvec2 mapCoord( vec2 coord )\n{\n coord *= filterArea.xy;\n coord += filterArea.zw;\n\n return coord;\n}\n\nvec2 unmapCoord( vec2 coord )\n{\n coord -= filterArea.zw;\n coord /= filterArea.xy;\n\n return coord;\n}\n\nvoid texcoords(vec2 fragCoord, vec2 resolution,\n out vec2 v_rgbNW, out vec2 v_rgbNE,\n out vec2 v_rgbSW, out vec2 v_rgbSE,\n out vec2 v_rgbM) {\n vec2 inverseVP = 1.0 / resolution.xy;\n v_rgbNW = (fragCoord + vec2(-1.0, -1.0)) * inverseVP;\n v_rgbNE = (fragCoord + vec2(1.0, -1.0)) * inverseVP;\n v_rgbSW = (fragCoord + vec2(-1.0, 1.0)) * inverseVP;\n v_rgbSE = (fragCoord + vec2(1.0, 1.0)) * inverseVP;\n v_rgbM = vec2(fragCoord * inverseVP);\n}\n\nvoid main(void) {\n\n gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n\n vTextureCoord = aTextureCoord;\n\n vec2 fragCoord = vTextureCoord * filterArea.xy;\n\n texcoords(fragCoord, filterArea.xy, v_rgbNW, v_rgbNE, v_rgbSW, v_rgbSE, v_rgbM);\n}",'varying vec2 v_rgbNW;\nvarying vec2 v_rgbNE;\nvarying vec2 v_rgbSW;\nvarying vec2 v_rgbSE;\nvarying vec2 v_rgbM;\n\nvarying vec2 vTextureCoord;\nuniform sampler2D uSampler;\nuniform vec4 filterArea;\n\n/**\n Basic FXAA implementation based on the code on geeks3d.com with the\n modification that the texture2DLod stuff was removed since it\'s\n unsupported by WebGL.\n \n --\n \n From:\n https://github.com/mitsuhiko/webgl-meincraft\n \n Copyright (c) 2011 by Armin Ronacher.\n \n Some rights reserved.\n \n Redistribution and use in source and binary forms, with or without\n modification, are permitted provided that the following conditions are\n met:\n \n * Redistributions of source code must retain the above copyright\n notice, this list of conditions and the following disclaimer.\n \n * Redistributions in binary form must reproduce the above\n copyright notice, this list of conditions and the following\n disclaimer in the documentation and/or other materials provided\n with the distribution.\n \n * The names of the contributors may not be used to endorse or\n promote products derived from this software without specific\n prior written permission.\n \n THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS\n "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT\n LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR\n A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT\n OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,\n SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,\n DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY\n THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT\n (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\n OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n */\n\n#ifndef FXAA_REDUCE_MIN\n#define FXAA_REDUCE_MIN (1.0/ 128.0)\n#endif\n#ifndef FXAA_REDUCE_MUL\n#define FXAA_REDUCE_MUL (1.0 / 8.0)\n#endif\n#ifndef FXAA_SPAN_MAX\n#define FXAA_SPAN_MAX 8.0\n#endif\n\n//optimized version for mobile, where dependent\n//texture reads can be a bottleneck\nvec4 fxaa(sampler2D tex, vec2 fragCoord, vec2 resolution,\n vec2 v_rgbNW, vec2 v_rgbNE,\n vec2 v_rgbSW, vec2 v_rgbSE,\n vec2 v_rgbM) {\n vec4 color;\n mediump vec2 inverseVP = vec2(1.0 / resolution.x, 1.0 / resolution.y);\n vec3 rgbNW = texture2D(tex, v_rgbNW).xyz;\n vec3 rgbNE = texture2D(tex, v_rgbNE).xyz;\n vec3 rgbSW = texture2D(tex, v_rgbSW).xyz;\n vec3 rgbSE = texture2D(tex, v_rgbSE).xyz;\n vec4 texColor = texture2D(tex, v_rgbM);\n vec3 rgbM = texColor.xyz;\n vec3 luma = vec3(0.299, 0.587, 0.114);\n float lumaNW = dot(rgbNW, luma);\n float lumaNE = dot(rgbNE, luma);\n float lumaSW = dot(rgbSW, luma);\n float lumaSE = dot(rgbSE, luma);\n float lumaM = dot(rgbM, luma);\n float lumaMin = min(lumaM, min(min(lumaNW, lumaNE), min(lumaSW, lumaSE)));\n float lumaMax = max(lumaM, max(max(lumaNW, lumaNE), max(lumaSW, lumaSE)));\n \n mediump vec2 dir;\n dir.x = -((lumaNW + lumaNE) - (lumaSW + lumaSE));\n dir.y = ((lumaNW + lumaSW) - (lumaNE + lumaSE));\n \n float dirReduce = max((lumaNW + lumaNE + lumaSW + lumaSE) *\n (0.25 * FXAA_REDUCE_MUL), FXAA_REDUCE_MIN);\n \n float rcpDirMin = 1.0 / (min(abs(dir.x), abs(dir.y)) + dirReduce);\n dir = min(vec2(FXAA_SPAN_MAX, FXAA_SPAN_MAX),\n max(vec2(-FXAA_SPAN_MAX, -FXAA_SPAN_MAX),\n dir * rcpDirMin)) * inverseVP;\n \n vec3 rgbA = 0.5 * (\n texture2D(tex, fragCoord * inverseVP + dir * (1.0 / 3.0 - 0.5)).xyz +\n texture2D(tex, fragCoord * inverseVP + dir * (2.0 / 3.0 - 0.5)).xyz);\n vec3 rgbB = rgbA * 0.5 + 0.25 * (\n texture2D(tex, fragCoord * inverseVP + dir * -0.5).xyz +\n texture2D(tex, fragCoord * inverseVP + dir * 0.5).xyz);\n \n float lumaB = dot(rgbB, luma);\n if ((lumaB < lumaMin) || (lumaB > lumaMax))\n color = vec4(rgbA, texColor.a);\n else\n color = vec4(rgbB, texColor.a);\n return color;\n}\n\nvoid main() {\n\n vec2 fragCoord = vTextureCoord * filterArea.xy;\n\n vec4 color;\n\n color = fxaa(uSampler, fragCoord, filterArea.xy, v_rgbNW, v_rgbNE, v_rgbSW, v_rgbSE, v_rgbM);\n\n gl_FragColor = color;\n}\n'))}r.default=o},{"../../core":65,path:8}],153:[function(t,e,r){"use strict";r.__esModule=!0;var i=t("./fxaa/FXAAFilter");Object.defineProperty(r,"FXAAFilter",{enumerable:!0,get:function(){return c(i).default}});var n=t("./noise/NoiseFilter");Object.defineProperty(r,"NoiseFilter",{enumerable:!0,get:function(){return c(n).default}});var o=t("./displacement/DisplacementFilter");Object.defineProperty(r,"DisplacementFilter",{enumerable:!0,get:function(){return c(o).default}});var s=t("./blur/BlurFilter");Object.defineProperty(r,"BlurFilter",{enumerable:!0,get:function(){return c(s).default}});var a=t("./blur/BlurXFilter");Object.defineProperty(r,"BlurXFilter",{enumerable:!0,get:function(){return c(a).default}});var u=t("./blur/BlurYFilter");Object.defineProperty(r,"BlurYFilter",{enumerable:!0,get:function(){return c(u).default}});var h=t("./colormatrix/ColorMatrixFilter");Object.defineProperty(r,"ColorMatrixFilter",{enumerable:!0,get:function(){return c(h).default}});var l=t("./alpha/AlphaFilter");function c(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(r,"AlphaFilter",{enumerable:!0,get:function(){return c(l).default}})},{"./alpha/AlphaFilter":143,"./blur/BlurFilter":144,"./blur/BlurXFilter":145,"./blur/BlurYFilter":146,"./colormatrix/ColorMatrixFilter":150,"./displacement/DisplacementFilter":151,"./fxaa/FXAAFilter":152,"./noise/NoiseFilter":154}],154:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../../core"));t("path");var s,a=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(u,s=o.Filter),i(u,[{key:"noise",get:function(){return this.uniforms.uNoise},set:function(t){this.uniforms.uNoise=t}},{key:"seed",get:function(){return this.uniforms.uSeed},set:function(t){this.uniforms.uSeed=t}}]),u);function u(){var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:.5,e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:Math.random();!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,u);var r=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,s.call(this,"attribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\n\nuniform mat3 projectionMatrix;\n\nvarying vec2 vTextureCoord;\n\nvoid main(void)\n{\n gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n vTextureCoord = aTextureCoord;\n}","precision highp float;\n\nvarying vec2 vTextureCoord;\nvarying vec4 vColor;\n\nuniform float uNoise;\nuniform float uSeed;\nuniform sampler2D uSampler;\n\nfloat rand(vec2 co)\n{\n return fract(sin(dot(co.xy, vec2(12.9898, 78.233))) * 43758.5453);\n}\n\nvoid main()\n{\n vec4 color = texture2D(uSampler, vTextureCoord);\n float randomValue = rand(gl_FragCoord.xy * uSeed);\n float diff = (randomValue - 0.5) * uNoise;\n\n // Un-premultiply alpha before applying the color matrix. See issue #3539.\n if (color.a > 0.0) {\n color.rgb /= color.a;\n }\n\n color.r += diff;\n color.g += diff;\n color.b += diff;\n\n // Premultiply alpha again.\n color.rgb *= color.a;\n\n gl_FragColor = color;\n}\n"));return r.noise=t,r.seed=e,r}r.default=a},{"../../core":65,path:8}],155:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../core"));var s=(a.prototype.getLocalPosition=function(t,e,r){return t.worldTransform.applyInverse(r||this.global,e)},a.prototype.copyEvent=function(t){t.isPrimary&&(this.isPrimary=!0),this.button=t.button,this.buttons=Number.isInteger(t.buttons)?t.buttons:t.which,this.width=t.width,this.height=t.height,this.tiltX=t.tiltX,this.tiltY=t.tiltY,this.pointerType=t.pointerType,this.pressure=t.pressure,this.rotationAngle=t.rotationAngle,this.twist=t.twist||0,this.tangentialPressure=t.tangentialPressure||0},a.prototype.reset=function(){this.isPrimary=!1},i(a,[{key:"pointerId",get:function(){return this.identifier}}]),a);function a(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,a),this.global=new o.Point,this.target=null,this.originalEvent=null,this.identifier=null,this.isPrimary=!1,this.button=0,this.buttons=0,this.width=0,this.height=0,this.tiltX=0,this.tiltY=0,this.pointerType=null,this.pressure=0,this.rotationAngle=0,this.twist=0,this.tangentialPressure=0}r.default=s},{"../core":65}],156:[function(t,e,r){"use strict";r.__esModule=!0;var i=(n.prototype.stopPropagation=function(){this.stopped=!0},n.prototype.reset=function(){this.stopped=!1,this.currentTarget=null,this.target=null},n);function n(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,n),this.stopped=!1,this.target=null,this.currentTarget=null,this.type=null,this.data=null}r.default=i},{}],157:[function(t,e,r){"use strict";r.__esModule=!0;var i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},n=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../core")),o=h(t("./InteractionData")),s=h(t("./InteractionEvent")),f=h(t("./InteractionTrackingData")),a=h(t("eventemitter3")),u=h(t("./interactiveTarget"));function h(t){return t&&t.__esModule?t:{default:t}}n.utils.mixins.delayMixin(n.DisplayObject.prototype,u.default);var l,c={target:null,data:{global:null}},d=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(p,l=a.default),p.prototype.hitTest=function(t,e){return c.target=null,c.data.global=t,e=e||this.renderer._lastObjectRendered,this.processInteractive(c,e,null,!0),c.target},p.prototype.setTargetElement=function(t,e){var r=1<arguments.length&&void 0!==e?e:1;this.removeEvents(),this.interactionDOMElement=t,this.resolution=r,this.addEvents()},p.prototype.addEvents=function(){this.interactionDOMElement&&(n.ticker.shared.add(this.update,this,n.UPDATE_PRIORITY.INTERACTION),window.navigator.msPointerEnabled?(this.interactionDOMElement.style["-ms-content-zooming"]="none",this.interactionDOMElement.style["-ms-touch-action"]="none"):this.supportsPointerEvents&&(this.interactionDOMElement.style["touch-action"]="none"),this.supportsPointerEvents?(window.document.addEventListener("pointermove",this.onPointerMove,!0),this.interactionDOMElement.addEventListener("pointerdown",this.onPointerDown,!0),this.interactionDOMElement.addEventListener("pointerleave",this.onPointerOut,!0),this.interactionDOMElement.addEventListener("pointerover",this.onPointerOver,!0),window.addEventListener("pointercancel",this.onPointerCancel,!0),window.addEventListener("pointerup",this.onPointerUp,!0)):(window.document.addEventListener("mousemove",this.onPointerMove,!0),this.interactionDOMElement.addEventListener("mousedown",this.onPointerDown,!0),this.interactionDOMElement.addEventListener("mouseout",this.onPointerOut,!0),this.interactionDOMElement.addEventListener("mouseover",this.onPointerOver,!0),window.addEventListener("mouseup",this.onPointerUp,!0)),this.supportsTouchEvents&&(this.interactionDOMElement.addEventListener("touchstart",this.onPointerDown,!0),this.interactionDOMElement.addEventListener("touchcancel",this.onPointerCancel,!0),this.interactionDOMElement.addEventListener("touchend",this.onPointerUp,!0),this.interactionDOMElement.addEventListener("touchmove",this.onPointerMove,!0)),this.eventsAdded=!0)},p.prototype.removeEvents=function(){this.interactionDOMElement&&(n.ticker.shared.remove(this.update,this),window.navigator.msPointerEnabled?(this.interactionDOMElement.style["-ms-content-zooming"]="",this.interactionDOMElement.style["-ms-touch-action"]=""):this.supportsPointerEvents&&(this.interactionDOMElement.style["touch-action"]=""),this.supportsPointerEvents?(window.document.removeEventListener("pointermove",this.onPointerMove,!0),this.interactionDOMElement.removeEventListener("pointerdown",this.onPointerDown,!0),this.interactionDOMElement.removeEventListener("pointerleave",this.onPointerOut,!0),this.interactionDOMElement.removeEventListener("pointerover",this.onPointerOver,!0),window.removeEventListener("pointercancel",this.onPointerCancel,!0),window.removeEventListener("pointerup",this.onPointerUp,!0)):(window.document.removeEventListener("mousemove",this.onPointerMove,!0),this.interactionDOMElement.removeEventListener("mousedown",this.onPointerDown,!0),this.interactionDOMElement.removeEventListener("mouseout",this.onPointerOut,!0),this.interactionDOMElement.removeEventListener("mouseover",this.onPointerOver,!0),window.removeEventListener("mouseup",this.onPointerUp,!0)),this.supportsTouchEvents&&(this.interactionDOMElement.removeEventListener("touchstart",this.onPointerDown,!0),this.interactionDOMElement.removeEventListener("touchcancel",this.onPointerCancel,!0),this.interactionDOMElement.removeEventListener("touchend",this.onPointerUp,!0),this.interactionDOMElement.removeEventListener("touchmove",this.onPointerMove,!0)),this.interactionDOMElement=null,this.eventsAdded=!1)},p.prototype.update=function(t){if(this._deltaTime+=t,!(this._deltaTime<this.interactionFrequency)&&(this._deltaTime=0,this.interactionDOMElement))if(this.didMove)this.didMove=!1;else{for(var e in this.cursor=null,this.activeInteractionData)if(this.activeInteractionData.hasOwnProperty(e)){var r=this.activeInteractionData[e];if(r.originalEvent&&"touch"!==r.pointerType){var i=this.configureInteractionEventForDOMEvent(this.eventData,r.originalEvent,r);this.processInteractive(i,this.renderer._lastObjectRendered,this.processPointerOverOut,!0)}}this.setCursorMode(this.cursor)}},p.prototype.setCursorMode=function(t){if(t=t||"default",this.currentCursorMode!==t){this.currentCursorMode=t;var e=this.cursorStyles[t];if(e)switch(void 0===e?"undefined":i(e)){case"string":this.interactionDOMElement.style.cursor=e;break;case"function":e(t);break;case"object":Object.assign(this.interactionDOMElement.style,e)}else"string"!=typeof t||Object.prototype.hasOwnProperty.call(this.cursorStyles,t)||(this.interactionDOMElement.style.cursor=t)}},p.prototype.dispatchEvent=function(t,e,r){r.stopped||(r.currentTarget=t,r.type=e,t.emit(e,r),t[e]&&t[e](r))},p.prototype.mapPositionToPoint=function(t,e,r){var i=void 0;i=this.interactionDOMElement.parentElement?this.interactionDOMElement.getBoundingClientRect():{x:0,y:0,width:0,height:0};var n=navigator.isCocoonJS?this.resolution:1/this.resolution;t.x=(e-i.left)*(this.interactionDOMElement.width/i.width)*n,t.y=(r-i.top)*(this.interactionDOMElement.height/i.height)*n},p.prototype.processInteractive=function(t,e,r,i,n){if(!e||!e.visible)return!1;var o=t.data.global,s=!1,a=n=e.interactive||n,u=!0;if(e.hitArea?(i&&(e.worldTransform.applyInverse(o,this._tempPoint),e.hitArea.contains(this._tempPoint.x,this._tempPoint.y)?s=!0:u=i=!1),a=!1):e._mask&&i&&(e._mask.containsPoint(o)||(u=i=!1)),u&&e.interactiveChildren&&e.children)for(var h=e.children,l=h.length-1;0<=l;l--){var c=h[l],d=this.processInteractive(t,c,r,i,a);if(d){if(!c.parent)continue;a=!1,d&&(t.target&&(i=!1),s=!0)}}return n&&(i&&!t.target&&!e.hitArea&&e.containsPoint&&e.containsPoint(o)&&(s=!0),e.interactive&&(s&&!t.target&&(t.target=e),r&&r(t,e,!!s))),s},p.prototype.onPointerDown=function(t){if(!this.supportsTouchEvents||"touch"!==t.pointerType){var e=this.normalizeToPointerData(t);this.autoPreventDefault&&e[0].isNormalized&&t.preventDefault();for(var r=e.length,i=0;i<r;i++){var n=e[i],o=this.getInteractionDataForPointerId(n),s=this.configureInteractionEventForDOMEvent(this.eventData,n,o);if(s.data.originalEvent=t,this.processInteractive(s,this.renderer._lastObjectRendered,this.processPointerDown,!0),this.emit("pointerdown",s),"touch"===n.pointerType)this.emit("touchstart",s);else if("mouse"===n.pointerType||"pen"===n.pointerType){var a=2===n.button;this.emit(a?"rightdown":"mousedown",this.eventData)}}}},p.prototype.processPointerDown=function(t,e,r){var i=t.data,n=t.data.identifier;if(r)if(e.trackedPointers[n]||(e.trackedPointers[n]=new f.default(n)),this.dispatchEvent(e,"pointerdown",t),"touch"===i.pointerType)this.dispatchEvent(e,"touchstart",t);else if("mouse"===i.pointerType||"pen"===i.pointerType){var o=2===i.button;o?e.trackedPointers[n].rightDown=!0:e.trackedPointers[n].leftDown=!0,this.dispatchEvent(e,o?"rightdown":"mousedown",t)}},p.prototype.onPointerComplete=function(t,e,r){for(var i=this.normalizeToPointerData(t),n=i.length,o=t.target!==this.interactionDOMElement?"outside":"",s=0;s<n;s++){var a=i[s],u=this.getInteractionDataForPointerId(a),h=this.configureInteractionEventForDOMEvent(this.eventData,a,u);if(h.data.originalEvent=t,this.processInteractive(h,this.renderer._lastObjectRendered,r,e||!o),this.emit(e?"pointercancel":"pointerup"+o,h),"mouse"===a.pointerType||"pen"===a.pointerType){var l=2===a.button;this.emit(l?"rightup"+o:"mouseup"+o,h)}else"touch"===a.pointerType&&(this.emit(e?"touchcancel":"touchend"+o,h),this.releaseInteractionDataForPointerId(a.pointerId,u))}},p.prototype.onPointerCancel=function(t){this.supportsTouchEvents&&"touch"===t.pointerType||this.onPointerComplete(t,!0,this.processPointerCancel)},p.prototype.processPointerCancel=function(t,e){var r=t.data,i=t.data.identifier;void 0!==e.trackedPointers[i]&&(delete e.trackedPointers[i],this.dispatchEvent(e,"pointercancel",t),"touch"===r.pointerType&&this.dispatchEvent(e,"touchcancel",t))},p.prototype.onPointerUp=function(t){this.supportsTouchEvents&&"touch"===t.pointerType||this.onPointerComplete(t,!1,this.processPointerUp)},p.prototype.processPointerUp=function(t,e,r){var i=t.data,n=t.data.identifier,o=e.trackedPointers[n],s="touch"===i.pointerType,a="mouse"===i.pointerType||"pen"===i.pointerType,u=!1;if(a){var h=2===i.button,l=f.default.FLAGS,c=h?l.RIGHT_DOWN:l.LEFT_DOWN,d=void 0!==o&&o.flags&c;r?(this.dispatchEvent(e,h?"rightup":"mouseup",t),d&&(this.dispatchEvent(e,h?"rightclick":"click",t),u=!0)):d&&this.dispatchEvent(e,h?"rightupoutside":"mouseupoutside",t),o&&(h?o.rightDown=!1:o.leftDown=!1)}r?(this.dispatchEvent(e,"pointerup",t),s&&this.dispatchEvent(e,"touchend",t),o&&(a&&!u||this.dispatchEvent(e,"pointertap",t),s&&(this.dispatchEvent(e,"tap",t),o.over=!1))):o&&(this.dispatchEvent(e,"pointerupoutside",t),s&&this.dispatchEvent(e,"touchendoutside",t)),o&&o.none&&delete e.trackedPointers[n]},p.prototype.onPointerMove=function(t){if(!this.supportsTouchEvents||"touch"!==t.pointerType){var e=this.normalizeToPointerData(t);"mouse"!==e[0].pointerType&&"pen"!==e[0].pointerType||(this.didMove=!0,this.cursor=null);for(var r=e.length,i=0;i<r;i++){var n=e[i],o=this.getInteractionDataForPointerId(n),s=this.configureInteractionEventForDOMEvent(this.eventData,n,o);s.data.originalEvent=t;var a="touch"!==n.pointerType||this.moveWhenInside;this.processInteractive(s,this.renderer._lastObjectRendered,this.processPointerMove,a),this.emit("pointermove",s),"touch"===n.pointerType&&this.emit("touchmove",s),"mouse"!==n.pointerType&&"pen"!==n.pointerType||this.emit("mousemove",s)}"mouse"===e[0].pointerType&&this.setCursorMode(this.cursor)}},p.prototype.processPointerMove=function(t,e,r){var i=t.data,n="touch"===i.pointerType,o="mouse"===i.pointerType||"pen"===i.pointerType;o&&this.processPointerOverOut(t,e,r),this.moveWhenInside&&!r||(this.dispatchEvent(e,"pointermove",t),n&&this.dispatchEvent(e,"touchmove",t),o&&this.dispatchEvent(e,"mousemove",t))},p.prototype.onPointerOut=function(t){if(!this.supportsTouchEvents||"touch"!==t.pointerType){var e=this.normalizeToPointerData(t)[0];"mouse"===e.pointerType&&(this.mouseOverRenderer=!1,this.setCursorMode(null));var r=this.getInteractionDataForPointerId(e),i=this.configureInteractionEventForDOMEvent(this.eventData,e,r);i.data.originalEvent=e,this.processInteractive(i,this.renderer._lastObjectRendered,this.processPointerOverOut,!1),this.emit("pointerout",i),"mouse"===e.pointerType||"pen"===e.pointerType?this.emit("mouseout",i):this.releaseInteractionDataForPointerId(r.identifier)}},p.prototype.processPointerOverOut=function(t,e,r){var i=t.data,n=t.data.identifier,o="mouse"===i.pointerType||"pen"===i.pointerType,s=e.trackedPointers[n];r&&!s&&(s=e.trackedPointers[n]=new f.default(n)),void 0!==s&&(r&&this.mouseOverRenderer?(s.over||(s.over=!0,this.dispatchEvent(e,"pointerover",t),o&&this.dispatchEvent(e,"mouseover",t)),o&&null===this.cursor&&(this.cursor=e.cursor)):s.over&&(s.over=!1,this.dispatchEvent(e,"pointerout",this.eventData),o&&this.dispatchEvent(e,"mouseout",t),s.none&&delete e.trackedPointers[n]))},p.prototype.onPointerOver=function(t){var e=this.normalizeToPointerData(t)[0],r=this.getInteractionDataForPointerId(e),i=this.configureInteractionEventForDOMEvent(this.eventData,e,r);"mouse"===(i.data.originalEvent=e).pointerType&&(this.mouseOverRenderer=!0),this.emit("pointerover",i),"mouse"!==e.pointerType&&"pen"!==e.pointerType||this.emit("mouseover",i)},p.prototype.getInteractionDataForPointerId=function(t){var e=t.pointerId,r=void 0;return 1===e||"mouse"===t.pointerType?r=this.mouse:this.activeInteractionData[e]?r=this.activeInteractionData[e]:((r=this.interactionDataPool.pop()||new o.default).identifier=e,this.activeInteractionData[e]=r),r.copyEvent(t),r},p.prototype.releaseInteractionDataForPointerId=function(t){var e=this.activeInteractionData[t];e&&(delete this.activeInteractionData[t],e.reset(),this.interactionDataPool.push(e))},p.prototype.configureInteractionEventForDOMEvent=function(t,e,r){return t.data=r,this.mapPositionToPoint(r.global,e.clientX,e.clientY),navigator.isCocoonJS&&"touch"===e.pointerType&&(r.global.x=r.global.x/this.resolution,r.global.y=r.global.y/this.resolution),"touch"===e.pointerType&&(e.globalX=r.global.x,e.globalY=r.global.y),r.originalEvent=e,t.reset(),t},p.prototype.normalizeToPointerData=function(t){var e=[];if(this.supportsTouchEvents&&t instanceof TouchEvent)for(var r=0,i=t.changedTouches.length;r<i;r++){var n=t.changedTouches[r];void 0===n.button&&(n.button=t.touches.length?1:0),void 0===n.buttons&&(n.buttons=t.touches.length?1:0),void 0===n.isPrimary&&(n.isPrimary=1===t.touches.length&&"touchstart"===t.type),void 0===n.width&&(n.width=n.radiusX||1),void 0===n.height&&(n.height=n.radiusY||1),void 0===n.tiltX&&(n.tiltX=0),void 0===n.tiltY&&(n.tiltY=0),void 0===n.pointerType&&(n.pointerType="touch"),void 0===n.pointerId&&(n.pointerId=n.identifier||0),void 0===n.pressure&&(n.pressure=n.force||.5),void 0===n.twist&&(n.twist=0),void 0===n.tangentialPressure&&(n.tangentialPressure=0),void 0===n.layerX&&(n.layerX=n.offsetX=n.clientX),void 0===n.layerY&&(n.layerY=n.offsetY=n.clientY),n.isNormalized=!0,e.push(n)}else!(t instanceof MouseEvent)||this.supportsPointerEvents&&t instanceof window.PointerEvent||(void 0===t.isPrimary&&(t.isPrimary=!0),void 0===t.width&&(t.width=1),void 0===t.height&&(t.height=1),void 0===t.tiltX&&(t.tiltX=0),void 0===t.tiltY&&(t.tiltY=0),void 0===t.pointerType&&(t.pointerType="mouse"),void 0===t.pointerId&&(t.pointerId=1),void 0===t.pressure&&(t.pressure=.5),void 0===t.twist&&(t.twist=0),void 0===t.tangentialPressure&&(t.tangentialPressure=0),t.isNormalized=!0),e.push(t);return e},p.prototype.destroy=function(){this.removeEvents(),this.removeAllListeners(),this.renderer=null,this.mouse=null,this.eventData=null,this.interactionDOMElement=null,this.onPointerDown=null,this.processPointerDown=null,this.onPointerUp=null,this.processPointerUp=null,this.onPointerCancel=null,this.processPointerCancel=null,this.onPointerMove=null,this.processPointerMove=null,this.onPointerOut=null,this.processPointerOverOut=null,this.onPointerOver=null,this._tempPoint=null},p);function p(t,e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,p);var r=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,l.call(this));return e=e||{},r.renderer=t,r.autoPreventDefault=void 0===e.autoPreventDefault||e.autoPreventDefault,r.interactionFrequency=e.interactionFrequency||10,r.mouse=new o.default,r.mouse.identifier=1,r.mouse.global.set(-999999),r.activeInteractionData={},r.activeInteractionData[1]=r.mouse,r.interactionDataPool=[],r.eventData=new s.default,r.interactionDOMElement=null,r.moveWhenInside=!1,r.eventsAdded=!1,r.mouseOverRenderer=!1,r.supportsTouchEvents="ontouchstart"in window,r.supportsPointerEvents=!!window.PointerEvent,r.onPointerUp=r.onPointerUp.bind(r),r.processPointerUp=r.processPointerUp.bind(r),r.onPointerCancel=r.onPointerCancel.bind(r),r.processPointerCancel=r.processPointerCancel.bind(r),r.onPointerDown=r.onPointerDown.bind(r),r.processPointerDown=r.processPointerDown.bind(r),r.onPointerMove=r.onPointerMove.bind(r),r.processPointerMove=r.processPointerMove.bind(r),r.onPointerOut=r.onPointerOut.bind(r),r.processPointerOverOut=r.processPointerOverOut.bind(r),r.onPointerOver=r.onPointerOver.bind(r),r.cursorStyles={default:"inherit",pointer:"pointer"},r.currentCursorMode=null,r.cursor=null,r._tempPoint=new n.Point,r.resolution=1,r.setTargetElement(r.renderer.view,r.renderer.resolution),r}r.default=d,n.WebGLRenderer.registerPlugin("interaction",d),n.CanvasRenderer.registerPlugin("interaction",d)},{"../core":65,"./InteractionData":155,"./InteractionEvent":156,"./InteractionTrackingData":158,"./interactiveTarget":160,eventemitter3:3}],158:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o=(s.prototype._doSet=function(t,e){this._flags=e?this._flags|t:this._flags&~t},i(s,[{key:"pointerId",get:function(){return this._pointerId}},{key:"flags",get:function(){return this._flags},set:function(t){this._flags=t}},{key:"none",get:function(){return this._flags===this.constructor.FLAGS.NONE}},{key:"over",get:function(){return 0!=(this._flags&this.constructor.FLAGS.OVER)},set:function(t){this._doSet(this.constructor.FLAGS.OVER,t)}},{key:"rightDown",get:function(){return 0!=(this._flags&this.constructor.FLAGS.RIGHT_DOWN)},set:function(t){this._doSet(this.constructor.FLAGS.RIGHT_DOWN,t)}},{key:"leftDown",get:function(){return 0!=(this._flags&this.constructor.FLAGS.LEFT_DOWN)},set:function(t){this._doSet(this.constructor.FLAGS.LEFT_DOWN,t)}}]),s);function s(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,s),this._pointerId=t,this._flags=s.FLAGS.NONE}(r.default=o).FLAGS=Object.freeze({NONE:0,OVER:1,LEFT_DOWN:2,RIGHT_DOWN:4})},{}],159:[function(t,e,r){"use strict";r.__esModule=!0;var i=t("./InteractionData");Object.defineProperty(r,"InteractionData",{enumerable:!0,get:function(){return u(i).default}});var n=t("./InteractionManager");Object.defineProperty(r,"InteractionManager",{enumerable:!0,get:function(){return u(n).default}});var o=t("./interactiveTarget");Object.defineProperty(r,"interactiveTarget",{enumerable:!0,get:function(){return u(o).default}});var s=t("./InteractionTrackingData");Object.defineProperty(r,"InteractionTrackingData",{enumerable:!0,get:function(){return u(s).default}});var a=t("./InteractionEvent");function u(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(r,"InteractionEvent",{enumerable:!0,get:function(){return u(a).default}})},{"./InteractionData":155,"./InteractionEvent":156,"./InteractionManager":157,"./InteractionTrackingData":158,"./interactiveTarget":160}],160:[function(t,e,r){"use strict";r.__esModule=!0,r.default={interactive:!1,interactiveChildren:!0,hitArea:null,get buttonMode(){return"pointer"===this.cursor},set buttonMode(t){t?this.cursor="pointer":"pointer"===this.cursor&&(this.cursor=null)},cursor:null,get trackedPointers(){return void 0===this._trackedPointers&&(this._trackedPointers={}),this._trackedPointers},_trackedPointers:void 0}},{}],161:[function(t,e,r){"use strict";r.__esModule=!0,r.parse=v,r.default=function(){return function(e,r){if(e.data&&e.type===p.Resource.TYPE.XML)if(0!==e.data.getElementsByTagName("page").length&&0!==e.data.getElementsByTagName("info").length&&null!==e.data.getElementsByTagName("info")[0].getAttribute("face")){var t=e.isDataUrl?"":f.dirname(e.url);e.isDataUrl&&("."===t&&(t=""),this.baseUrl&&t&&"/"===this.baseUrl.charAt(this.baseUrl.length-1)&&(t+="/")),(t=t.replace(this.baseUrl,""))&&"/"!==t.charAt(t.length-1)&&(t+="/");for(var i=e.data.getElementsByTagName("page"),n={},o=function(t){n[t.metadata.pageFile]=t.texture,Object.keys(n).length===i.length&&(v(e,n),r())},s=0;s<i.length;++s){var a=i[s].getAttribute("file"),u=t+a,h=!1;for(var l in this.resources){var c=this.resources[l];if(c.url===u){c.metadata.pageFile=a,c.texture?o(c):c.onAfterMiddleware.add(o),h=!0;break}}if(!h){var d={crossOrigin:e.crossOrigin,loadType:p.Resource.LOAD_TYPE.IMAGE,metadata:Object.assign({pageFile:a},e.metadata.imageMetadata),parentResource:e};this.add(u,d,o)}}}else r();else r()}};var f=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("path")),p=t("resource-loader"),i=t("../extras");function v(t,e){t.bitmapFont=i.BitmapText.registerFont(t.data,e)}},{"../extras":141,path:8,"resource-loader":36}],162:[function(t,e,r){"use strict";r.__esModule=!0,r.shared=r.Resource=r.textureParser=r.getResourcePath=r.spritesheetParser=r.parseBitmapFontData=r.bitmapFontParser=r.Loader=void 0;var i=t("./bitmapFontParser");Object.defineProperty(r,"bitmapFontParser",{enumerable:!0,get:function(){return h(i).default}}),Object.defineProperty(r,"parseBitmapFontData",{enumerable:!0,get:function(){return i.parse}});var n=t("./spritesheetParser");Object.defineProperty(r,"spritesheetParser",{enumerable:!0,get:function(){return h(n).default}}),Object.defineProperty(r,"getResourcePath",{enumerable:!0,get:function(){return n.getResourcePath}});var o=t("./textureParser");Object.defineProperty(r,"textureParser",{enumerable:!0,get:function(){return h(o).default}});var s=t("resource-loader");Object.defineProperty(r,"Resource",{enumerable:!0,get:function(){return s.Resource}});var a=h(t("../core/Application")),u=h(t("./loader"));function h(t){return t&&t.__esModule?t:{default:t}}r.Loader=u.default;var l=new u.default;l.destroy=function(){},r.shared=l;var c=a.default.prototype;c._loader=null,Object.defineProperty(c,"loader",{get:function(){if(!this._loader){var t=this._options.sharedLoader;this._loader=t?l:new u.default}return this._loader}}),c._parentDestroy=c.destroy,c.destroy=function(t,e){this._loader&&(this._loader.destroy(),this._loader=null),this._parentDestroy(t,e)}},{"../core/Application":43,"./bitmapFontParser":161,"./loader":163,"./spritesheetParser":164,"./textureParser":165,"resource-loader":36}],163:[function(t,e,r){"use strict";r.__esModule=!0;var i=h(t("resource-loader")),n=t("resource-loader/lib/middlewares/parsing/blob"),o=h(t("eventemitter3")),s=h(t("./textureParser")),a=h(t("./spritesheetParser")),u=h(t("./bitmapFontParser"));function h(t){return t&&t.__esModule?t:{default:t}}var l,c=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(d,l=i.default),d.addPixiMiddleware=function(t){d._pixiMiddleware.push(t)},d.prototype.destroy=function(){this.removeAllListeners(),this.reset()},d);function d(t,e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,d);var i=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,l.call(this,t,e));o.default.call(i);for(var r=0;r<d._pixiMiddleware.length;++r)i.use(d._pixiMiddleware[r]());return i.onStart.add(function(t){return i.emit("start",t)}),i.onProgress.add(function(t,e){return i.emit("progress",t,e)}),i.onError.add(function(t,e,r){return i.emit("error",t,e,r)}),i.onLoad.add(function(t,e){return i.emit("load",t,e)}),i.onComplete.add(function(t,e){return i.emit("complete",t,e)}),i}for(var f in r.default=c,o.default.prototype)c.prototype[f]=o.default.prototype[f];c._pixiMiddleware=[n.blobMiddlewareFactory,s.default,a.default,u.default];var p=i.default.Resource;p.setExtensionXhrType("fnt",p.XHR_RESPONSE_TYPE.DOCUMENT)},{"./bitmapFontParser":161,"./spritesheetParser":164,"./textureParser":165,eventemitter3:3,"resource-loader":36,"resource-loader/lib/middlewares/parsing/blob":37}],164:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(){return function(r,i){var t=r.name+"_image";if(r.data&&r.type===o.Resource.TYPE.JSON&&r.data.frames&&!this.resources[t]){var e={crossOrigin:r.crossOrigin,metadata:r.metadata.imageMetadata,parentResource:r},n=u(r,this.baseUrl);this.add(t,n,e,function(t){if(t.error)i(t.error);else{var e=new a.Spritesheet(t.texture.baseTexture,r.data,r.url);e.parse(function(){r.spritesheet=e,r.textures=e.textures,i()})}})}else i()}},r.getResourcePath=u;var i,o=t("resource-loader"),n=t("url"),s=(i=n)&&i.__esModule?i:{default:i},a=t("../core");function u(t,e){return t.isDataUrl?t.data.meta.image:s.default.resolve(t.url.replace(e,""),t.data.meta.image)}},{"../core":65,"resource-loader":36,url:38}],165:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(){return function(t,e){t.data&&t.type===n.Resource.TYPE.IMAGE&&(t.texture=s.default.fromLoader(t.data,t.url,t.name)),e()}};var i,n=t("resource-loader"),o=t("../core/textures/Texture"),s=(i=o)&&i.__esModule?i:{default:i}},{"../core/textures/Texture":115,"resource-loader":36}],166:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o,s=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../core")),a=t("../core/textures/Texture"),u=(o=a)&&o.__esModule?o:{default:o};var h,l=new s.Point,c=new s.Polygon,d=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(f,h=s.Container),f.prototype._renderWebGL=function(t){this.refresh(),t.setObjectRenderer(t.plugins[this.pluginName]),t.plugins[this.pluginName].render(this)},f.prototype._renderCanvas=function(t){this.refresh(),t.plugins[this.pluginName].render(this)},f.prototype._onTextureUpdate=function(){this._uvTransform.texture=this._texture,this.refresh()},f.prototype.multiplyUvs=function(){this.uploadUvTransform||this._uvTransform.multiplyUvs(this.uvs)},f.prototype.refresh=function(t){this.autoUpdate&&this.vertexDirty++,this._uvTransform.update(t)&&this._refresh()},f.prototype._refresh=function(){},f.prototype._calculateBounds=function(){this._bounds.addVertices(this.transform,this.vertices,0,this.vertices.length)},f.prototype.containsPoint=function(t){if(!this.getBounds().contains(t.x,t.y))return!1;this.worldTransform.applyInverse(t,l);for(var e=this.vertices,r=c.points,i=this.indices,n=this.indices.length,o=this.drawMode===f.DRAW_MODES.TRIANGLES?3:1,s=0;s+2<n;s+=o){var a=2*i[s],u=2*i[s+1],h=2*i[s+2];if(r[0]=e[a],r[1]=e[1+a],r[2]=e[u],r[3]=e[1+u],r[4]=e[h],r[5]=e[1+h],c.contains(l.x,l.y))return!0}return!1},f.prototype.destroy=function(t){for(var e in this._glDatas){var r=this._glDatas[e];r.destroy?r.destroy():(r.vertexBuffer&&(r.vertexBuffer.destroy(),r.vertexBuffer=null),r.indexBuffer&&(r.indexBuffer.destroy(),r.indexBuffer=null),r.uvBuffer&&(r.uvBuffer.destroy(),r.uvBuffer=null),r.vao&&(r.vao.destroy(),r.vao=null))}this._glDatas=null,h.prototype.destroy.call(this,t)},i(f,[{key:"texture",get:function(){return this._texture},set:function(t){this._texture!==t&&(this._texture=t)&&(t.baseTexture.hasLoaded?this._onTextureUpdate():t.once("update",this._onTextureUpdate,this))}},{key:"tint",get:function(){return s.utils.rgb2hex(this.tintRgb)},set:function(t){this.tintRgb=s.utils.hex2rgb(t,this.tintRgb)}}]),f);function f(t,e,r,i,n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,f);var o=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,h.call(this));return o._texture=t||u.default.EMPTY,o.uvs=r||new Float32Array([0,0,1,0,1,1,0,1]),o.vertices=e||new Float32Array([0,0,100,0,100,100,0,100]),o.indices=i||new Uint16Array([0,1,3,2]),o.dirty=0,o.indexDirty=0,o.vertexDirty=0,o.autoUpdate=!0,o.blendMode=s.BLEND_MODES.NORMAL,o.canvasPadding=s.settings.MESH_CANVAS_PADDING,o.drawMode=n||f.DRAW_MODES.TRIANGLE_MESH,o.shader=null,o.tintRgb=new Float32Array([1,1,1]),o._glDatas={},o._uvTransform=new s.TextureMatrix(o._texture),o.uploadUvTransform=!1,o.pluginName="mesh",o}(r.default=d).DRAW_MODES={TRIANGLE_MESH:0,TRIANGLES:1}},{"../core":65,"../core/textures/Texture":115}],167:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o=s(t("./Plane")),b=s(t("../core/sprites/canvas/CanvasTinter"));function s(t){return t&&t.__esModule?t:{default:t}}var a,u=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(h,a=o.default),h.prototype.updateHorizontalVertices=function(){var t=this.vertices,e=this._topHeight+this._bottomHeight,r=this._height>e?1:this._height/e;t[9]=t[11]=t[13]=t[15]=this._topHeight*r,t[17]=t[19]=t[21]=t[23]=this._height-this._bottomHeight*r,t[25]=t[27]=t[29]=t[31]=this._height},h.prototype.updateVerticalVertices=function(){var t=this.vertices,e=this._leftWidth+this._rightWidth,r=this._width>e?1:this._width/e;t[2]=t[10]=t[18]=t[26]=this._leftWidth*r,t[4]=t[12]=t[20]=t[28]=this._width-this._rightWidth*r,t[6]=t[14]=t[22]=t[30]=this._width},h.prototype._renderCanvas=function(t){var e=t.context,r=this.worldTransform,i=t.resolution,n=16777215!==this.tint,o=this._texture;n&&this._cachedTint!==this.tint&&(this._cachedTint=this.tint,this._tintedTexture=b.default.getTintedTexture(this,this.tint));var s=n?this._tintedTexture:o.baseTexture.source;this._canvasUvs||(this._canvasUvs=[0,0,0,0,0,0,0,0]);var a=this.vertices,u=this._canvasUvs,h=n?0:o.frame.x,l=n?0:o.frame.y,c=h+o.frame.width,d=l+o.frame.height;u[0]=h,u[1]=h+this._leftWidth,u[2]=c-this._rightWidth,u[3]=c,u[4]=l,u[5]=l+this._topHeight,u[6]=d-this._bottomHeight,u[7]=d;for(var f=0;f<8;f++)u[f]*=o.baseTexture.resolution;e.globalAlpha=this.worldAlpha,t.setBlendMode(this.blendMode),t.roundPixels||this.roundPixels?e.setTransform(r.a*i,r.b*i,r.c*i,r.d*i,r.tx*i|0,r.ty*i|0):e.setTransform(r.a*i,r.b*i,r.c*i,r.d*i,r.tx*i,r.ty*i);for(var p=0;p<3;p++)for(var v=0;v<3;v++){var g=2*v+8*p,y=Math.max(1,u[v+1]-u[v]),m=Math.max(1,u[p+5]-u[p+4]),_=Math.max(1,a[10+g]-a[g]),x=Math.max(1,a[11+g]-a[1+g]);e.drawImage(s,u[v],u[p+4],y,m,a[g],a[1+g],_,x)}},h.prototype._refresh=function(){a.prototype._refresh.call(this);var t=this.uvs,e=this._texture;this._origWidth=e.orig.width,this._origHeight=e.orig.height;var r=1/this._origWidth,i=1/this._origHeight;t[0]=t[8]=t[16]=t[24]=0,t[1]=t[3]=t[5]=t[7]=0,t[6]=t[14]=t[22]=t[30]=1,t[25]=t[27]=t[29]=t[31]=1,t[2]=t[10]=t[18]=t[26]=r*this._leftWidth,t[4]=t[12]=t[20]=t[28]=1-r*this._rightWidth,t[9]=t[11]=t[13]=t[15]=i*this._topHeight,t[17]=t[19]=t[21]=t[23]=1-i*this._bottomHeight,this.updateHorizontalVertices(),this.updateVerticalVertices(),this.dirty++,this.multiplyUvs()},i(h,[{key:"width",get:function(){return this._width},set:function(t){this._width=t,this._refresh()}},{key:"height",get:function(){return this._height},set:function(t){this._height=t,this._refresh()}},{key:"leftWidth",get:function(){return this._leftWidth},set:function(t){this._leftWidth=t,this._refresh()}},{key:"rightWidth",get:function(){return this._rightWidth},set:function(t){this._rightWidth=t,this._refresh()}},{key:"topHeight",get:function(){return this._topHeight},set:function(t){this._topHeight=t,this._refresh()}},{key:"bottomHeight",get:function(){return this._bottomHeight},set:function(t){this._bottomHeight=t,this._refresh()}}]),h);function h(t,e,r,i,n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,h);var o=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,a.call(this,t,4,4));return o._origWidth=t.orig.width,o._origHeight=t.orig.height,o._width=o._origWidth,o._height=o._origHeight,o._leftWidth=void 0!==e?e:10,o._rightWidth=void 0!==i?i:10,o._topHeight=void 0!==r?r:10,o._bottomHeight=void 0!==n?n:10,o._cachedTint=16777215,o._tintedTexture=null,o._canvasUvs=null,o.refresh(!0),o}r.default=u},{"../core/sprites/canvas/CanvasTinter":104,"./Plane":168}],168:[function(t,e,r){"use strict";r.__esModule=!0;var i,n=t("./Mesh"),o=(i=n)&&i.__esModule?i:{default:i};var s,a=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(u,s=o.default),u.prototype._refresh=function(){for(var t=this._texture,e=this.verticesX*this.verticesY,r=[],i=[],n=[],o=this.verticesX-1,s=this.verticesY-1,a=t.width/o,u=t.height/s,h=0;h<e;h++){var l=h%this.verticesX,c=h/this.verticesX|0;r.push(l*a,c*u),i.push(l/o,c/s)}for(var d=o*s,f=0;f<d;f++){var p=f%o,v=f/o|0,g=v*this.verticesX+p,y=v*this.verticesX+p+1,m=(1+v)*this.verticesX+p,_=(1+v)*this.verticesX+p+1;n.push(g,y,m),n.push(y,_,m)}this.vertices=new Float32Array(r),this.uvs=new Float32Array(i),this.colors=new Float32Array([]),this.indices=new Uint16Array(n),this.dirty++,this.indexDirty++,this.multiplyUvs()},u.prototype._onTextureUpdate=function(){o.default.prototype._onTextureUpdate.call(this),this._ready&&this.refresh()},u);function u(t,e,r){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,u);var i=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,s.call(this,t));return i._ready=!0,i.verticesX=e||10,i.verticesY=r||10,i.drawMode=o.default.DRAW_MODES.TRIANGLES,i.refresh(),i}r.default=a},{"./Mesh":166}],169:[function(t,e,r){"use strict";r.__esModule=!0;var i,n=t("./Mesh"),o=(i=n)&&i.__esModule?i:{default:i};var s,a=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(u,s=o.default),u.prototype._refresh=function(){var t=this.points;if(!(t.length<1)&&this._texture._uvs){this.vertices.length/4!==t.length&&(this.vertices=new Float32Array(4*t.length),this.uvs=new Float32Array(4*t.length),this.colors=new Float32Array(2*t.length),this.indices=new Uint16Array(2*t.length));var e=this.uvs,r=this.indices,i=this.colors;e[0]=0,e[1]=0,e[2]=0,e[3]=1,i[0]=1,i[1]=1,r[0]=0,r[1]=1;for(var n=t.length,o=1;o<n;o++){var s=4*o,a=o/(n-1);e[s]=a,e[s+1]=0,e[s+2]=a,e[s+3]=1,i[s=2*o]=1,i[s+1]=1,r[s=2*o]=s,r[s+1]=s+1}this.dirty++,this.indexDirty++,this.multiplyUvs(),this.refreshVertices()}},u.prototype.refreshVertices=function(){var t=this.points;if(!(t.length<1))for(var e=t[0],r=void 0,i=0,n=0,o=this.vertices,s=t.length,a=0;a<s;a++){var u=t[a],h=4*a;n=-((r=a<t.length-1?t[a+1]:u).x-e.x),i=r.y-e.y;var l=10*(1-a/(s-1));1<l&&(l=1);var c=Math.sqrt(i*i+n*n),d=this._texture.height/2;i/=c,n/=c,i*=d,n*=d,o[h]=u.x+i,o[1+h]=u.y+n,o[2+h]=u.x-i,o[3+h]=u.y-n,e=u}},u.prototype.updateTransform=function(){this.autoUpdate&&this.refreshVertices(),this.containerUpdateTransform()},u);function u(t,e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,u);var r=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,s.call(this,t));return r.points=e,r.vertices=new Float32Array(4*e.length),r.uvs=new Float32Array(4*e.length),r.colors=new Float32Array(2*e.length),r.indices=new Uint16Array(2*e.length),r.autoUpdate=!0,r.refresh(),r}r.default=a},{"./Mesh":166}],170:[function(t,e,r){"use strict";r.__esModule=!0;var i,n=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../../core")),o=t("../Mesh"),s=(i=o)&&i.__esModule?i:{default:i};var a=(u.prototype.render=function(t){var e=this.renderer,r=e.context,i=t.worldTransform,n=e.resolution;e.roundPixels||this.roundPixels?r.setTransform(i.a*n,i.b*n,i.c*n,i.d*n,i.tx*n|0,i.ty*n|0):r.setTransform(i.a*n,i.b*n,i.c*n,i.d*n,i.tx*n,i.ty*n),e.context.globalAlpha=t.worldAlpha,e.setBlendMode(t.blendMode),t.drawMode===s.default.DRAW_MODES.TRIANGLE_MESH?this._renderTriangleMesh(t):this._renderTriangles(t)},u.prototype._renderTriangleMesh=function(t){for(var e=t.vertices.length/2,r=0;r<e-2;r++){var i=2*r;this._renderDrawTriangle(t,i,2+i,4+i)}},u.prototype._renderTriangles=function(t){for(var e=t.indices,r=e.length,i=0;i<r;i+=3){var n=2*e[i],o=2*e[i+1],s=2*e[i+2];this._renderDrawTriangle(t,n,o,s)}},u.prototype._renderDrawTriangle=function(t,e,r,i){var n=this.renderer.context,o=t.uvs,s=t.vertices,a=t._texture;if(a.valid){var u=a.baseTexture,h=u.source,l=u.width,c=u.height,d=void 0,f=void 0,p=void 0,v=void 0,g=void 0,y=void 0;if(t.uploadUvTransform){var m=t._uvTransform.mapCoord;d=(o[e]*m.a+o[e+1]*m.c+m.tx)*u.width,f=(o[r]*m.a+o[r+1]*m.c+m.tx)*u.width,p=(o[i]*m.a+o[i+1]*m.c+m.tx)*u.width,v=(o[e]*m.b+o[e+1]*m.d+m.ty)*u.height,g=(o[r]*m.b+o[r+1]*m.d+m.ty)*u.height,y=(o[i]*m.b+o[i+1]*m.d+m.ty)*u.height}else d=o[e]*u.width,f=o[r]*u.width,p=o[i]*u.width,v=o[e+1]*u.height,g=o[r+1]*u.height,y=o[i+1]*u.height;var _=s[e],x=s[r],b=s[i],T=s[e+1],w=s[r+1],E=s[i+1],S=t.canvasPadding/this.renderer.resolution;if(0<S){var O=S/Math.abs(t.worldTransform.a),M=S/Math.abs(t.worldTransform.d),P=(_+x+b)/3,C=(T+w+E)/3,R=_-P,A=T-C,I=Math.sqrt(R*R+A*A);_=P+R/I*(I+O),T=C+A/I*(I+M),A=w-C,x=P+(R=x-P)/(I=Math.sqrt(R*R+A*A))*(I+O),w=C+A/I*(I+M),A=E-C,b=P+(R=b-P)/(I=Math.sqrt(R*R+A*A))*(I+O),E=C+A/I*(I+M)}n.save(),n.beginPath(),n.moveTo(_,T),n.lineTo(x,w),n.lineTo(b,E),n.closePath(),n.clip();var D=d*g+v*p+f*y-g*p-v*f-d*y,L=_*g+v*b+x*y-g*b-v*x-_*y,N=d*x+_*p+f*b-x*p-_*f-d*b,B=d*g*b+v*x*p+_*f*y-_*g*p-v*f*b-d*x*y,k=T*g+v*E+w*y-g*E-v*w-T*y,F=d*w+T*p+f*E-w*p-T*f-d*E,j=d*g*E+v*w*p+T*f*y-T*g*p-v*f*E-d*w*y;n.transform(L/D,k/D,N/D,F/D,B/D,j/D),n.drawImage(h,0,0,l*u.resolution,c*u.resolution,0,0,l,c),n.restore(),this.renderer.invalidateBlendMode()}},u.prototype.renderMeshFlat=function(t){var e=this.renderer.context,r=t.vertices,i=r.length/2;e.beginPath();for(var n=1;n<i-2;++n){var o=2*n,s=r[o],a=r[1+o],u=r[2+o],h=r[3+o],l=r[4+o],c=r[5+o];e.moveTo(s,a),e.lineTo(u,h),e.lineTo(l,c)}e.fillStyle="#FF0000",e.fill(),e.closePath()},u.prototype.destroy=function(){this.renderer=null},u);function u(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,u),this.renderer=t}r.default=a,n.CanvasRenderer.registerPlugin("mesh",a)},{"../../core":65,"../Mesh":166}],171:[function(t,e,r){"use strict";r.__esModule=!0;var i=t("./Mesh");Object.defineProperty(r,"Mesh",{enumerable:!0,get:function(){return h(i).default}});var n=t("./webgl/MeshRenderer");Object.defineProperty(r,"MeshRenderer",{enumerable:!0,get:function(){return h(n).default}});var o=t("./canvas/CanvasMeshRenderer");Object.defineProperty(r,"CanvasMeshRenderer",{enumerable:!0,get:function(){return h(o).default}});var s=t("./Plane");Object.defineProperty(r,"Plane",{enumerable:!0,get:function(){return h(s).default}});var a=t("./NineSlicePlane");Object.defineProperty(r,"NineSlicePlane",{enumerable:!0,get:function(){return h(a).default}});var u=t("./Rope");function h(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(r,"Rope",{enumerable:!0,get:function(){return h(u).default}})},{"./Mesh":166,"./NineSlicePlane":167,"./Plane":168,"./Rope":169,"./canvas/CanvasMeshRenderer":170,"./webgl/MeshRenderer":172}],172:[function(t,e,r){"use strict";r.__esModule=!0;var s=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../../core")),a=i(t("pixi-gl-core")),u=i(t("../Mesh"));t("path");function i(t){return t&&t.__esModule?t:{default:t}}var n,h=s.Matrix.IDENTITY,o=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(l,n=s.ObjectRenderer),l.prototype.onContextChange=function(){var t=this.renderer.gl;this.shader=new s.Shader(t,"attribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\n\nuniform mat3 projectionMatrix;\nuniform mat3 translationMatrix;\nuniform mat3 uTransform;\n\nvarying vec2 vTextureCoord;\n\nvoid main(void)\n{\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n\n vTextureCoord = (uTransform * vec3(aTextureCoord, 1.0)).xy;\n}\n","varying vec2 vTextureCoord;\nuniform vec4 uColor;\n\nuniform sampler2D uSampler;\n\nvoid main(void)\n{\n gl_FragColor = texture2D(uSampler, vTextureCoord) * uColor;\n}\n")},l.prototype.render=function(t){var e=this.renderer,r=e.gl,i=t._texture;if(i.valid){var n=t._glDatas[e.CONTEXT_UID];n||(e.bindVao(null),(n={shader:this.shader,vertexBuffer:a.default.GLBuffer.createVertexBuffer(r,t.vertices,r.STREAM_DRAW),uvBuffer:a.default.GLBuffer.createVertexBuffer(r,t.uvs,r.STREAM_DRAW),indexBuffer:a.default.GLBuffer.createIndexBuffer(r,t.indices,r.STATIC_DRAW),vao:null,dirty:t.dirty,indexDirty:t.indexDirty,vertexDirty:t.vertexDirty}).vao=new a.default.VertexArrayObject(r).addIndex(n.indexBuffer).addAttribute(n.vertexBuffer,n.shader.attributes.aVertexPosition,r.FLOAT,!1,8,0).addAttribute(n.uvBuffer,n.shader.attributes.aTextureCoord,r.FLOAT,!1,8,0),t._glDatas[e.CONTEXT_UID]=n),e.bindVao(n.vao),t.dirty!==n.dirty&&(n.dirty=t.dirty,n.uvBuffer.upload(t.uvs)),t.indexDirty!==n.indexDirty&&(n.indexDirty=t.indexDirty,n.indexBuffer.upload(t.indices)),t.vertexDirty!==n.vertexDirty&&(n.vertexDirty=t.vertexDirty,n.vertexBuffer.upload(t.vertices)),e.bindShader(n.shader),n.shader.uniforms.uSampler=e.bindTexture(i),e.state.setBlendMode(s.utils.correctBlendMode(t.blendMode,i.baseTexture.premultipliedAlpha)),n.shader.uniforms.uTransform&&(t.uploadUvTransform?n.shader.uniforms.uTransform=t._uvTransform.mapCoord.toArray(!0):n.shader.uniforms.uTransform=h.toArray(!0)),n.shader.uniforms.translationMatrix=t.worldTransform.toArray(!0),n.shader.uniforms.uColor=s.utils.premultiplyRgba(t.tintRgb,t.worldAlpha,n.shader.uniforms.uColor,i.baseTexture.premultipliedAlpha);var o=t.drawMode===u.default.DRAW_MODES.TRIANGLE_MESH?r.TRIANGLE_STRIP:r.TRIANGLES;n.vao.draw(o,t.indices.length,0)}},l);function l(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l);var e=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,n.call(this,t));return e.shader=null,e}r.default=o,s.WebGLRenderer.registerPlugin("mesh",o)},{"../../core":65,"../Mesh":166,path:8,"pixi-gl-core":15}],173:[function(t,e,r){"use strict";r.__esModule=!0;var i=function(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t};function n(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var o=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../core")),s=t("../core/utils");var a,u=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(h,a=o.Container),h.prototype.setProperties=function(t){t&&(this._properties[0]="vertices"in t||"scale"in t?!!t.vertices||!!t.scale:this._properties[0],this._properties[1]="position"in t?!!t.position:this._properties[1],this._properties[2]="rotation"in t?!!t.rotation:this._properties[2],this._properties[3]="uvs"in t?!!t.uvs:this._properties[3],this._properties[4]="tint"in t||"alpha"in t?!!t.tint||!!t.alpha:this._properties[4])},h.prototype.updateTransform=function(){this.displayObjectUpdateTransform()},h.prototype.renderWebGL=function(t){var e=this;this.visible&&!(this.worldAlpha<=0)&&this.children.length&&this.renderable&&(this.baseTexture||(this.baseTexture=this.children[0]._texture.baseTexture,this.baseTexture.hasLoaded||this.baseTexture.once("update",function(){return e.onChildrenChange(0)})),t.setObjectRenderer(t.plugins.particle),t.plugins.particle.render(this))},h.prototype.onChildrenChange=function(t){for(var e=Math.floor(t/this._batchSize);this._bufferUpdateIDs.length<e;)this._bufferUpdateIDs.push(0);this._bufferUpdateIDs[e]=++this._updateID},h.prototype.renderCanvas=function(t){if(this.visible&&!(this.worldAlpha<=0)&&this.children.length&&this.renderable){var e=t.context,r=this.worldTransform,i=!0,n=0,o=0,s=0,a=0;t.setBlendMode(this.blendMode),e.globalAlpha=this.worldAlpha,this.displayObjectUpdateTransform();for(var u=0;u<this.children.length;++u){var h=this.children[u];if(h.visible){var l=h._texture.frame;if(e.globalAlpha=this.worldAlpha*h.alpha,h.rotation%(2*Math.PI)==0)i&&(e.setTransform(r.a,r.b,r.c,r.d,r.tx*t.resolution,r.ty*t.resolution),i=!1),n=h.anchor.x*(-l.width*h.scale.x)+h.position.x+.5,o=h.anchor.y*(-l.height*h.scale.y)+h.position.y+.5,s=l.width*h.scale.x,a=l.height*h.scale.y;else{i=i||!0,h.displayObjectUpdateTransform();var c=h.worldTransform;t.roundPixels||this.roundPixels?e.setTransform(c.a,c.b,c.c,c.d,c.tx*t.resolution|0,c.ty*t.resolution|0):e.setTransform(c.a,c.b,c.c,c.d,c.tx*t.resolution,c.ty*t.resolution),n=h.anchor.x*-l.width+.5,o=h.anchor.y*-l.height+.5,s=l.width,a=l.height}var d=h._texture.baseTexture.resolution;e.drawImage(h._texture.baseTexture.source,l.x*d,l.y*d,l.width*d,l.height*d,n*t.resolution,o*t.resolution,s*t.resolution,a*t.resolution)}}}},h.prototype.destroy=function(t){if(a.prototype.destroy.call(this,t),this._buffers)for(var e=0;e<this._buffers.length;++e)this._buffers[e].destroy();this._properties=null,this._buffers=null,this._bufferUpdateIDs=null},i(h,[{key:"tint",get:function(){return this._tint},set:function(t){this._tint=t,(0,s.hex2rgb)(t,this.tintRgb)}}]),h);function h(){var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:1500,e=arguments[1],r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:16384,i=3<arguments.length&&void 0!==arguments[3]&&arguments[3];!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,h);var n=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,a.call(this));return 16384<r&&(r=16384),t<r&&(r=t),n._properties=[!1,!0,!1,!1,!1],n._maxSize=t,n._batchSize=r,n._glBuffers={},n._bufferUpdateIDs=[],n._updateID=0,n.interactiveChildren=!1,n.blendMode=o.BLEND_MODES.NORMAL,n.autoResize=i,n.roundPixels=!0,n.baseTexture=null,n.setProperties(e),n._tint=0,n.tintRgb=new Float32Array(4),n.tint=16777215,n}r.default=u},{"../core":65,"../core/utils":125}],174:[function(t,e,r){"use strict";r.__esModule=!0;var i=t("./ParticleContainer");Object.defineProperty(r,"ParticleContainer",{enumerable:!0,get:function(){return o(i).default}});var n=t("./webgl/ParticleRenderer");function o(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(r,"ParticleRenderer",{enumerable:!0,get:function(){return o(n).default}})},{"./ParticleContainer":173,"./webgl/ParticleRenderer":176}],175:[function(t,e,r){"use strict";r.__esModule=!0;var f=i(t("pixi-gl-core")),p=i(t("../../core/utils/createIndicesForQuads"));function i(t){return t&&t.__esModule?t:{default:t}}var n=(s.prototype.initBuffers=function(){var t=this.gl,e=0;this.indices=(0,p.default)(this.size),this.indexBuffer=f.default.GLBuffer.createIndexBuffer(t,this.indices,t.STATIC_DRAW);for(var r=this.dynamicStride=0;r<this.dynamicProperties.length;++r){var i=this.dynamicProperties[r];i.offset=e,e+=i.size,this.dynamicStride+=i.size}var n=new ArrayBuffer(this.size*this.dynamicStride*4*4);this.dynamicData=new Float32Array(n),this.dynamicDataUint32=new Uint32Array(n),this.dynamicBuffer=f.default.GLBuffer.createVertexBuffer(t,n,t.STREAM_DRAW);for(var o=0,s=this.staticStride=0;s<this.staticProperties.length;++s){var a=this.staticProperties[s];a.offset=o,o+=a.size,this.staticStride+=a.size}var u=new ArrayBuffer(this.size*this.staticStride*4*4);this.staticData=new Float32Array(u),this.staticDataUint32=new Uint32Array(u),this.staticBuffer=f.default.GLBuffer.createVertexBuffer(t,u,t.STATIC_DRAW),this.vao=new f.default.VertexArrayObject(t).addIndex(this.indexBuffer);for(var h=0;h<this.dynamicProperties.length;++h){var l=this.dynamicProperties[h];l.unsignedByte?this.vao.addAttribute(this.dynamicBuffer,l.attribute,t.UNSIGNED_BYTE,!0,4*this.dynamicStride,4*l.offset):this.vao.addAttribute(this.dynamicBuffer,l.attribute,t.FLOAT,!1,4*this.dynamicStride,4*l.offset)}for(var c=0;c<this.staticProperties.length;++c){var d=this.staticProperties[c];d.unsignedByte?this.vao.addAttribute(this.staticBuffer,d.attribute,t.UNSIGNED_BYTE,!0,4*this.staticStride,4*d.offset):this.vao.addAttribute(this.staticBuffer,d.attribute,t.FLOAT,!1,4*this.staticStride,4*d.offset)}},s.prototype.uploadDynamic=function(t,e,r){for(var i=0;i<this.dynamicProperties.length;i++){var n=this.dynamicProperties[i];n.uploadFunction(t,e,r,n.unsignedByte?this.dynamicDataUint32:this.dynamicData,this.dynamicStride,n.offset)}this.dynamicBuffer.upload()},s.prototype.uploadStatic=function(t,e,r){for(var i=0;i<this.staticProperties.length;i++){var n=this.staticProperties[i];n.uploadFunction(t,e,r,n.unsignedByte?this.staticDataUint32:this.staticData,this.staticStride,n.offset)}this.staticBuffer.upload()},s.prototype.destroy=function(){this.dynamicProperties=null,this.dynamicBuffer.destroy(),this.dynamicBuffer=null,this.dynamicData=null,this.dynamicDataUint32=null,this.staticProperties=null,this.staticBuffer.destroy(),this.staticBuffer=null,this.staticData=null,this.staticDataUint32=null},s);function s(t,e,r,i){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,s),this.gl=t,this.size=i,this.dynamicProperties=[],this.staticProperties=[];for(var n=0;n<e.length;++n){var o=e[n];o={attribute:o.attribute,size:o.size,uploadFunction:o.uploadFunction,unsignedByte:o.unsignedByte,offset:o.offset},r[n]?this.dynamicProperties.push(o):this.staticProperties.push(o)}this.staticStride=0,this.staticBuffer=null,this.staticData=null,this.staticDataUint32=null,this.dynamicStride=0,this.dynamicBuffer=null,this.dynamicData=null,this.dynamicDataUint32=null,this._updateID=0,this.initBuffers()}r.default=n},{"../../core/utils/createIndicesForQuads":123,"pixi-gl-core":15}],176:[function(t,e,r){"use strict";r.__esModule=!0;var g=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../../core")),i=n(t("./ParticleShader")),a=n(t("./ParticleBuffer")),c=t("../../core/utils");function n(t){return t&&t.__esModule?t:{default:t}}var o,s=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(u,o=g.ObjectRenderer),u.prototype.onContextChange=function(){var t=this.renderer.gl;this.CONTEXT_UID=this.renderer.CONTEXT_UID,this.shader=new i.default(t),this.properties=[{attribute:this.shader.attributes.aVertexPosition,size:2,uploadFunction:this.uploadVertices,offset:0},{attribute:this.shader.attributes.aPositionCoord,size:2,uploadFunction:this.uploadPosition,offset:0},{attribute:this.shader.attributes.aRotation,size:1,uploadFunction:this.uploadRotation,offset:0},{attribute:this.shader.attributes.aTextureCoord,size:2,uploadFunction:this.uploadUvs,offset:0},{attribute:this.shader.attributes.aColor,size:1,unsignedByte:!0,uploadFunction:this.uploadTint,offset:0}]},u.prototype.start=function(){this.renderer.bindShader(this.shader)},u.prototype.render=function(t){var e=t.children,r=t._maxSize,i=t._batchSize,n=this.renderer,o=e.length;if(0!==o){r<o&&(o=r);var s=t._glBuffers[n.CONTEXT_UID];s=s||(t._glBuffers[n.CONTEXT_UID]=this.generateBuffers(t));var a=e[0]._texture.baseTexture;this.renderer.setBlendMode(g.utils.correctBlendMode(t.blendMode,a.premultipliedAlpha));var u=n.gl,h=t.worldTransform.copy(this.tempMatrix);h.prepend(n._activeRenderTarget.projectionMatrix),this.shader.uniforms.projectionMatrix=h.toArray(!0),this.shader.uniforms.uColor=g.utils.premultiplyRgba(t.tintRgb,t.worldAlpha,this.shader.uniforms.uColor,a.premultipliedAlpha),this.shader.uniforms.uSampler=n.bindTexture(a);for(var l=!1,c=0,d=0;c<o;c+=i,d+=1){var f=o-c;if(i<f&&(f=i),d>=s.length){if(!t.autoResize)break;s.push(this._generateOneMoreBuffer(t))}var p=s[d];p.uploadDynamic(e,c,f);var v=t._bufferUpdateIDs[d]||0;(l=l||p._updateID<v)&&(p._updateID=t._updateID,p.uploadStatic(e,c,f)),n.bindVao(p.vao),p.vao.draw(u.TRIANGLES,6*f)}}},u.prototype.generateBuffers=function(t){for(var e=this.renderer.gl,r=[],i=t._maxSize,n=t._batchSize,o=t._properties,s=0;s<i;s+=n)r.push(new a.default(e,this.properties,o,n));return r},u.prototype._generateOneMoreBuffer=function(t){var e=this.renderer.gl,r=t._batchSize,i=t._properties;return new a.default(e,this.properties,i,r)},u.prototype.uploadVertices=function(t,e,r,i,n,o){for(var s=0,a=0,u=0,h=0,l=0;l<r;++l){var c=t[e+l],d=c._texture,f=c.scale.x,p=c.scale.y,v=d.trim,g=d.orig;v?(s=(a=v.x-c.anchor.x*g.width)+v.width,u=(h=v.y-c.anchor.y*g.height)+v.height):(s=g.width*(1-c.anchor.x),a=g.width*-c.anchor.x,u=g.height*(1-c.anchor.y),h=g.height*-c.anchor.y),i[o]=a*f,i[o+1]=h*p,i[o+n]=s*f,i[o+n+1]=h*p,i[o+2*n]=s*f,i[o+2*n+1]=u*p,i[o+3*n]=a*f,i[o+3*n+1]=u*p,o+=4*n}},u.prototype.uploadPosition=function(t,e,r,i,n,o){for(var s=0;s<r;s++){var a=t[e+s].position;i[o]=a.x,i[o+1]=a.y,i[o+n]=a.x,i[o+n+1]=a.y,i[o+2*n]=a.x,i[o+2*n+1]=a.y,i[o+3*n]=a.x,i[o+3*n+1]=a.y,o+=4*n}},u.prototype.uploadRotation=function(t,e,r,i,n,o){for(var s=0;s<r;s++){var a=t[e+s].rotation;i[o]=a,i[o+n]=a,i[o+2*n]=a,i[o+3*n]=a,o+=4*n}},u.prototype.uploadUvs=function(t,e,r,i,n,o){for(var s=0;s<r;++s){var a=t[e+s]._texture._uvs;a?(i[o]=a.x0,i[o+1]=a.y0,i[o+n]=a.x1,i[o+n+1]=a.y1,i[o+2*n]=a.x2,i[o+2*n+1]=a.y2,i[o+3*n]=a.x3,i[o+3*n+1]=a.y3):(i[o]=0,i[o+1]=0,i[o+n]=0,i[o+n+1]=0,i[o+2*n]=0,i[o+2*n+1]=0,i[o+3*n]=0,i[o+3*n+1]=0),o+=4*n}},u.prototype.uploadTint=function(t,e,r,i,n,o){for(var s=0;s<r;++s){var a=t[e+s],u=a._texture.baseTexture.premultipliedAlpha,h=a.alpha,l=h<1&&u?(0,c.premultiplyTint)(a._tintRGB,h):a._tintRGB+(255*h<<24);i[o]=l,i[o+n]=l,i[o+2*n]=l,i[o+3*n]=l,o+=4*n}},u.prototype.destroy=function(){this.renderer.gl&&this.renderer.gl.deleteBuffer(this.indexBuffer),o.prototype.destroy.call(this),this.shader.destroy(),this.indices=null,this.tempMatrix=null},u);function u(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,u);var e=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,o.call(this,t));return e.shader=null,e.indexBuffer=null,e.properties=null,e.tempMatrix=new g.Matrix,e.CONTEXT_UID=0,e}r.default=s,g.WebGLRenderer.registerPlugin("particle",s)},{"../../core":65,"../../core/utils":125,"./ParticleBuffer":175,"./ParticleShader":177}],177:[function(t,e,r){"use strict";r.__esModule=!0;var i,n=t("../../core/Shader"),o=(i=n)&&i.__esModule?i:{default:i};var s,a=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(u,s=o.default),u);function u(t){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,u),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,s.call(this,t,["attribute vec2 aVertexPosition;","attribute vec2 aTextureCoord;","attribute vec4 aColor;","attribute vec2 aPositionCoord;","attribute float aRotation;","uniform mat3 projectionMatrix;","uniform vec4 uColor;","varying vec2 vTextureCoord;","varying vec4 vColor;","void main(void){"," float x = (aVertexPosition.x) * cos(aRotation) - (aVertexPosition.y) * sin(aRotation);"," float y = (aVertexPosition.x) * sin(aRotation) + (aVertexPosition.y) * cos(aRotation);"," vec2 v = vec2(x, y);"," v = v + aPositionCoord;"," gl_Position = vec4((projectionMatrix * vec3(v, 1.0)).xy, 0.0, 1.0);"," vTextureCoord = aTextureCoord;"," vColor = aColor * uColor;","}"].join("\n"),["varying vec2 vTextureCoord;","varying vec4 vColor;","uniform sampler2D uSampler;","void main(void){"," vec4 color = texture2D(uSampler, vTextureCoord) * vColor;"," gl_FragColor = color;","}"].join("\n")))}r.default=a},{"../../core/Shader":44}],178:[function(t,e,r){"use strict";Math.sign||(Math.sign=function(t){return 0===(t=Number(t))||isNaN(t)?t:0<t?1:-1})},{}],179:[function(t,e,r){"use strict";Number.isInteger||(Number.isInteger=function(t){return"number"==typeof t&&isFinite(t)&&Math.floor(t)===t})},{}],180:[function(t,e,r){"use strict";var i,n=t("object-assign"),o=(i=n)&&i.__esModule?i:{default:i};Object.assign||(Object.assign=o.default)},{"object-assign":6}],181:[function(t,e,r){"use strict";t("./Object.assign"),t("./requestAnimationFrame"),t("./Math.sign"),t("./Number.isInteger"),window.ArrayBuffer||(window.ArrayBuffer=Array),window.Float32Array||(window.Float32Array=Array),window.Uint32Array||(window.Uint32Array=Array),window.Uint16Array||(window.Uint16Array=Array)},{"./Math.sign":178,"./Number.isInteger":179,"./Object.assign":180,"./requestAnimationFrame":182}],182:[function(t,e,r){(function(t){"use strict";if(Date.now&&Date.prototype.getTime||(Date.now=function(){return(new Date).getTime()}),!t.performance||!t.performance.now){var e=Date.now();t.performance||(t.performance={}),t.performance.now=function(){return Date.now()-e}}for(var i=Date.now(),r=["ms","moz","webkit","o"],n=0;n<r.length&&!t.requestAnimationFrame;++n){var o=r[n];t.requestAnimationFrame=t[o+"RequestAnimationFrame"],t.cancelAnimationFrame=t[o+"CancelAnimationFrame"]||t[o+"CancelRequestAnimationFrame"]}t.requestAnimationFrame||(t.requestAnimationFrame=function(t){if("function"!=typeof t)throw new TypeError(t+"is not a function");var e=Date.now(),r=16+i-e;return r<0&&(r=0),i=e,setTimeout(function(){i=Date.now(),t(performance.now())},r)}),t.cancelAnimationFrame||(t.cancelAnimationFrame=function(t){return clearTimeout(t)})}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],183:[function(t,e,r){"use strict";r.__esModule=!0;var i,a=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../core")),n=t("./limiters/CountLimiter"),o=(i=n)&&i.__esModule?i:{default:i};var u=a.ticker.shared;a.settings.UPLOADS_PER_FRAME=4;var s=(h.prototype.upload=function(t,e){"function"==typeof t&&(e=t,t=null),t&&this.add(t),this.queue.length?(e&&this.completes.push(e),this.ticking||(this.ticking=!0,u.addOnce(this.tick,this,a.UPDATE_PRIORITY.UTILITY))):e&&e()},h.prototype.tick=function(){setTimeout(this.delayedTick,0)},h.prototype.prepareItems=function(){for(this.limiter.beginFrame();this.queue.length&&this.limiter.allowedToUpload();){var t=this.queue[0],e=!1;if(t&&!t._destroyed)for(var r=0,i=this.uploadHooks.length;r<i;r++)if(this.uploadHooks[r](this.uploadHookHelper,t)){this.queue.shift(),e=!0;break}e||this.queue.shift()}if(this.queue.length)u.addOnce(this.tick,this,a.UPDATE_PRIORITY.UTILITY);else{this.ticking=!1;for(var n=this.completes.slice(0),o=this.completes.length=0,s=n.length;o<s;o++)n[o]()}},h.prototype.registerFindHook=function(t){return t&&this.addHooks.push(t),this},h.prototype.registerUploadHook=function(t){return t&&this.uploadHooks.push(t),this},h.prototype.add=function(t){for(var e=0,r=this.addHooks.length;e<r&&!this.addHooks[e](t,this.queue);e++);if(t instanceof a.Container)for(var i=t.children.length-1;0<=i;i--)this.add(t.children[i]);return this},h.prototype.destroy=function(){this.ticking&&u.remove(this.tick,this),this.ticking=!1,this.addHooks=null,this.uploadHooks=null,this.renderer=null,this.completes=null,this.queue=null,this.limiter=null,this.uploadHookHelper=null},h);function h(t){var e=this;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,h),this.limiter=new o.default(a.settings.UPLOADS_PER_FRAME),this.renderer=t,this.uploadHookHelper=null,this.queue=[],this.addHooks=[],this.uploadHooks=[],this.completes=[],this.ticking=!1,this.delayedTick=function(){e.queue&&e.prepareItems()},this.registerFindHook(v),this.registerFindHook(g),this.registerFindHook(l),this.registerFindHook(c),this.registerFindHook(d),this.registerUploadHook(f),this.registerUploadHook(p)}function l(t,e){var r=!1;if(t&&t._textures&&t._textures.length)for(var i=0;i<t._textures.length;i++)if(t._textures[i]instanceof a.Texture){var n=t._textures[i].baseTexture;-1===e.indexOf(n)&&(e.push(n),r=!0)}return r}function c(t,e){return t instanceof a.BaseTexture&&(-1===e.indexOf(t)&&e.push(t),!0)}function d(t,e){if(t._texture&&t._texture instanceof a.Texture){var r=t._texture.baseTexture;return-1===e.indexOf(r)&&e.push(r),!0}return!1}function f(t,e){return e instanceof a.Text&&(e.updateText(!0),!0)}function p(t,e){if(e instanceof a.TextStyle){var r=e.toFontString();return a.TextMetrics.measureFont(r),!0}return!1}function v(t,e){if(t instanceof a.Text){-1===e.indexOf(t.style)&&e.push(t.style),-1===e.indexOf(t)&&e.push(t);var r=t._texture.baseTexture;return-1===e.indexOf(r)&&e.push(r),!0}return!1}function g(t,e){return t instanceof a.TextStyle&&(-1===e.indexOf(t)&&e.push(t),!0)}r.default=s},{"../core":65,"./limiters/CountLimiter":186}],184:[function(t,e,r){"use strict";r.__esModule=!0;var i,o=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../../core")),n=t("../BasePrepare"),s=(i=n)&&i.__esModule?i:{default:i};var a,u=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(h,a=s.default),h.prototype.destroy=function(){a.prototype.destroy.call(this),this.ctx=null,this.canvas=null},h);function h(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,h);var e=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,a.call(this,t));return(e.uploadHookHelper=e).canvas=document.createElement("canvas"),e.canvas.width=16,e.canvas.height=16,e.ctx=e.canvas.getContext("2d"),e.registerUploadHook(l),e}function l(t,e){if(e instanceof o.BaseTexture){var r=e.source,i=0===r.width?t.canvas.width:Math.min(t.canvas.width,r.width),n=0===r.height?t.canvas.height:Math.min(t.canvas.height,r.height);return t.ctx.drawImage(r,0,0,i,n,0,0,t.canvas.width,t.canvas.height),!0}return!1}r.default=u,o.CanvasRenderer.registerPlugin("prepare",u)},{"../../core":65,"../BasePrepare":183}],185:[function(t,e,r){"use strict";r.__esModule=!0;var i=t("./webgl/WebGLPrepare");Object.defineProperty(r,"webgl",{enumerable:!0,get:function(){return u(i).default}});var n=t("./canvas/CanvasPrepare");Object.defineProperty(r,"canvas",{enumerable:!0,get:function(){return u(n).default}});var o=t("./BasePrepare");Object.defineProperty(r,"BasePrepare",{enumerable:!0,get:function(){return u(o).default}});var s=t("./limiters/CountLimiter");Object.defineProperty(r,"CountLimiter",{enumerable:!0,get:function(){return u(s).default}});var a=t("./limiters/TimeLimiter");function u(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(r,"TimeLimiter",{enumerable:!0,get:function(){return u(a).default}})},{"./BasePrepare":183,"./canvas/CanvasPrepare":184,"./limiters/CountLimiter":186,"./limiters/TimeLimiter":187,"./webgl/WebGLPrepare":188}],186:[function(t,e,r){"use strict";r.__esModule=!0;var i=(n.prototype.beginFrame=function(){this.itemsLeft=this.maxItemsPerFrame},n.prototype.allowedToUpload=function(){return 0<this.itemsLeft--},n);function n(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,n),this.maxItemsPerFrame=t,this.itemsLeft=0}r.default=i},{}],187:[function(t,e,r){"use strict";r.__esModule=!0;var i=(n.prototype.beginFrame=function(){this.frameStart=Date.now()},n.prototype.allowedToUpload=function(){return Date.now()-this.frameStart<this.maxMilliseconds},n);function n(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,n),this.maxMilliseconds=t,this.frameStart=0}r.default=i},{}],188:[function(t,e,r){"use strict";r.__esModule=!0;var i,n=function(t){{if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}}(t("../../core")),o=t("../BasePrepare"),s=(i=o)&&i.__esModule?i:{default:i};var a,u=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(h,a=s.default),h);function h(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,h);var e=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,a.call(this,t));return e.uploadHookHelper=e.renderer,e.registerFindHook(d),e.registerUploadHook(l),e.registerUploadHook(c),e}function l(t,e){return e instanceof n.BaseTexture&&(e._glTextures[t.CONTEXT_UID]||t.textureManager.updateTexture(e),!0)}function c(t,e){return e instanceof n.Graphics&&(!e.dirty&&!e.clearDirty&&e._webGL[t.plugins.graphics.CONTEXT_UID]||t.plugins.graphics.updateGraphics(e),!0)}function d(t,e){return t instanceof n.Graphics&&(e.push(t),!0)}r.default=u,n.WebGLRenderer.registerPlugin("prepare",u)},{"../../core":65,"../BasePrepare":183}],189:[function(y,t,m){(function(t){"use strict";m.__esModule=!0,m.loader=m.prepare=m.particles=m.mesh=m.loaders=m.interaction=m.filters=m.extras=m.extract=m.accessibility=void 0;var e=y("./polyfill");Object.keys(e).forEach(function(t){"default"!==t&&"__esModule"!==t&&Object.defineProperty(m,t,{enumerable:!0,get:function(){return e[t]}})});var r=y("./core");Object.keys(r).forEach(function(t){"default"!==t&&"__esModule"!==t&&Object.defineProperty(m,t,{enumerable:!0,get:function(){return r[t]}})});var i,n=y("./deprecation"),o=(i=n)&&i.__esModule?i:{default:i},s=v(y("./accessibility")),a=v(y("./extract")),u=v(y("./extras")),h=v(y("./filters")),l=v(y("./interaction")),c=v(y("./loaders")),d=v(y("./mesh")),f=v(y("./particles")),p=v(y("./prepare"));function v(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}r.utils.mixins.performMixins();var g=c.shared||null;m.accessibility=s,m.extract=a,m.extras=u,m.filters=h,m.interaction=l,m.loaders=c,m.mesh=d,m.particles=f,m.prepare=p,m.loader=g,"function"==typeof o.default&&(0,o.default)(m),t.PIXI=m}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./accessibility":42,"./core":65,"./deprecation":131,"./extract":133,"./extras":141,"./filters":153,"./interaction":159,"./loaders":162,"./mesh":171,"./particles":174,"./polyfill":181,"./prepare":185}]},{},[189])(189)}); |