memoscan
← all memos

Memo 0xce8be376…d76233 on Ethereum

(()=>{"use strict";var r={d:(e,n)=>{for(var o in n)r.o(n,o)&&!r.o(e,o)&&Object.defineProperty(e,o,{enumerable:!0,get:n[o]})},o:(r,e)=>Object.prototype.hasOwnProperty.call(r,e)};r.d({},{cQ:()=>ke,X4:()=>de,HX:()=>ae,zJ:()=>te,_1:()=>we,LW:()=>ve,j9:()=>ue,f8:()=>he,ai:()=>me});function e(r,e,o,i,a,t=!1){let s=a.length,l=[];for(let h=0;h<a.length;h++){let m=a[h],d=a[(h+1)%s],c=n(r,e,o,i,m.x,m.y,d.x,d.y,t);c&&l.push(c)}return l.sort(((r,e)=>r.t-e.t)),l}function n(r,e,n,o,i,a,t,s,l=!1){let h=n-r,m=o-e,d=t-i,c=s-a,y=h*c-m*d;if(0==y)return null;let g=i-r,p=a-e,u=y/(y*y),x=(g*c-p*d)*u,f=(g*m-p*h)*u;if(0<=x&&(l||x<1)&&0<=f&&f<1){let t={t:x,s:f,side:null,other:null,xy:null};return t.xy=[n*x+r*(1-x),o*x+e*(1-x)],t.side=(r-(w=n))*(a-(k=o))-(e-k)*(i-w)<0?1:-1,t}var w,k;return null}const o=(r,e)=>{for(var n=r[0],o=r[1],i=!1,a=0,t=e.length-1;a<e.length;t=a++){var s=e[a].x,l=e[a].y,h=e[t].x,m=e[t].y;l>o!=m>o&&n<(h-s)*(o-l)/(m-l)+s&&(i=!i)}return i};function i(r,e,n,o,i,a,t,s){let l,h;return r===n?(l=r,h=a+(s-a)/(t-i)*(r-i)):i===t?(l=i,h=e+(o-e)/(n-r)*(i-r)):(l=(e-a+i*(s-a)/(t-i)-r*(o-e)/(n-r))/((s-a)/(t-i)-(o-e)/(n-r)),h=e+(o-e)*(l-r)/(n-r)),(r<=l&&l<=n||n<=l&&l<=r)&&(e<=h&&h<=o||o<=h&&h<=e)&&(i<=l&&l<=t||t<=l&&l<=i)&&(a<=h&&h<=s||s<=h&&h<=a)&&[l,h]}const a=r=>{var e=r[0],n=r[r.length-1];e.x==n.x&&e.y==n.y||r.push(e);for(var o,i,a,t=0,s=0,l=0,h=r.length,m=0,d=h-1;m<h;d=m++)o=r[m],i=r[d],t+=a=o.x*i.y-i.x*o.y,s+=(o.x+i.x)*a,l+=(o.y+i.y)*a;return{x:s/(a=3*t),y:l/a}},t=(r,e,n)=>{const o=[];for(let i=0;i<r.length;i++)o.push({x:r[i].x+e,y:r[i].y+n});return o},s=(r,e,n,o)=>r=r.map((r=>{const i=r.x-n,a=r.y-o;return{x:i*cos(e)-a*sin(e)+n,y:a*cos(e)+i*sin(e)+o}})),l=(r,e,n,o)=>r=r.map((r=>{const i=atan2(r.y-o,r.x-n);return{x:r.x+cos(i)*e*100,y:r.y+sin(i)*e*100}})),h=(r,e=1)=>{let n=r[0].x,o=r[0].x,i=r[0].y,a=r[0].y;r.forEach((r=>{r.x<n?n=r.x:r.x>o&&(o=r.x),r.y<i?i=r.y:r.y>a&&(a=r.y)}));let t=n+(o-n)/2,s=i+(a-i)/2,l=o-n,h=a-i;return n*=e,i*=e,o*=e,a*=e,t*=e,s*=e,l*=e,h*=e,n=round(n),i=round(i),o=round(o),a=round(a),t=round(t),s=round(s),l=round(l),h=round(h),{minX:n,minY:i,b6:o,b7:a,centerX:t,centerY:s,width:l,height:h}},m=r=>{let e=r[0][0].x,n=r[0][0].x,o=r[0][0].y,i=r[0][0].y;r.forEach((r=>{const a=h(r);a.minX<e?e=a.minX:a.b6>n&&(n=a.b6),a.minY<o?o=a.minY:a.b7>i&&(i=a.b7)}));return{minX:e,minY:o,b6:n,b7:i,centerX:e+(n-e)/2,centerY:o+(i-o)/2,width:n-e,height:i-o}},d=r=>{for(var e=0,n=0,o=r.length;n<o;n++){e+=r[n].x*r[n==r.length-1?0:n+1].y*.5,e-=r[n==r.length-1?0:n+1].x*r[n].y*.5}return Math.abs(e)},c=r=>{let e=r[0],n=r[r.length-1];e.x!==n.x&&e.y!==n.y&&r.push(e);let o=0;for(let e=0;e<r.length-1;e++){const n=r[e],i=r[e+1];o+=dist(n.x,n.y,i.x,i.y)}return o};function y(r,e,n,o){var i=o-e,a=n-r;return Math.atan2(i,a)}const g=(r,e,n)=>{let o=atan2(e[1].y-e[0].y,e[1].x-e[0].x)+PI/2;const i=[];return r.forEach((r=>{const a=(t=r,s=e[0],l=e[1],Math.sqrt(function(r,e,n){var o=u(e,n);if(0==o)return u(r,e);var i=((r.x-e.x)*(n.x-e.x)+(r.y-e.y)*(n.y-e.y))/o;return i=Math.max(0,Math.min(1,i)),u(r,{x:e.x+i*(n.x-e.x),y:e.y+i*(n.y-e.y)})}(t,s,l)));var t,s,l;const h=r.x-cos(o)*a,m=r.y-sin(o)*a,d={x:h+cos(o+n)*a,y:m+sin(o+n)*a};i.push(d)})),{vertices:i}};function p(r){return r*r}function u(r,e){return p(r.x-e.x)+p(r.y-e.y)}const x=(r,e,n)=>{let o=atan2(e[1].y-e[0].y,e[1].x-e[0].x);return t(r,cos(o)*n,sin(o)*n)},f=(r,e,n,o,i)=>{for(var a=new S(e,n),t=new S(o,i),s=[],l=[],h=0;h<r.length;h+=2)l.push(new S(r[h],r[h+1]));for(h=0;h<l.length;h++){var m=new S(0,0);m=v(a,t,l[h],l[(h+1)%l.length],m);var d=s[0],c=s[s.length-1];m&&(null==d||S.dist(m,d)>1e-10)&&(null==c||S.dist(m,c)>1e-10)&&(m.flag=!0,s.push(m),l.splice(h+1,0,m),h++)}if(s.length<2)return[r.slice(0)];s.sort((function(r,e){return S.dist(a,r)-S.dist(a,e)}));for(var y=[],g=0;s.length>0;){l.length;var p=s[0],u=s[1],x=l.indexOf(p),f=l.indexOf(u),L=!1;if(k(l,x)==f?L=!0:(p=s[1],u=s[0],x=l.indexOf(p),f=l.indexOf(u),k(l,x)==f&&(L=!0)),L&&p&&u){g--;var b=w(l,x,f);y.push(b),l=w(l,f,x),p.flag=u.flag=!1,s.splice(0,2),0==s.length&&y.push(l)}else g++,s.reverse();if(g>1)break}var C=[];for(h=0;h<y.length;h++){for(var P=y[h],H=[],Y=0;Y<P.length;Y++)H.push(P[Y].x,P[Y].y);C.push(H)}return C},w=(r,e,n)=>{var o=r.length,i=[];n<e&&(n+=o);for(var a=e;a<=n;a++)i.push(r[a%o]);return i},k=(r,e)=>{for(var n=r.length;;)if(r[e=(e+1)%n].flag)return e},v=(r,e,n,o,i)=>{var a=r.x-e.x,t=n.x-o.x,s=r.y-e.y,l=n.y-o.y,h=a*l-s*t;if(0==h)return null;var m=r.x*e.y-r.y*e.x,d=n.x*o.y-n.y*o.x,c=i;return c.x=(m*t-a*d)/h,c.y=(m*l-s*d)/h,L(c,r,e)&&L(c,n,o)?c:null},L=(r,e,n)=>{var o=min(e.x,n.x),i=max(e.x,n.x),a=min(e.y,n.y),t=max(e.y,n.y);return o==i?a<=r.y&&r.y<=t:a==t?o<=r.x&&r.x<=i:o<=r.x+1e-10&&r.x-1e-10<=i&&a<=r.y+1e-10&&r.y-1e-10<=t};function S(r,e){this.x=r,this.y=e,this.flag=!1}S.dist=function(r,e){var n=e.x-r.x,o=e.y-r.y;return sqrt(n*n+o*o)};const b=(r,e)=>{if(o([e[0].x,e[0].y],r)||o([e[1].x,e[1].y],r))return[r];const n=r.reduce(((r,e)=>r.concat([e.x,e.y])),[]);let i=f(n,e[0].x,e[0].y,e[1].x,e[1].y);return i=i.map((r=>{const e=[];for(let n=0;n<r.length;n+=2)e.push({x:r[n],y:r[n+1]});return e})),i.length>0?i:[r]},C=r=>r.map((r=>r.vertices?r.vertices:r)),P=r=>{const e=random();let n=!1,o=1;const i=r.reduce(((r,e,n)=>n%2==1?r+e:r),0),a=i*e;let t=0;for(;!n&&o<r.length;)a-r[o]<t&&(n=r[o-1]),t+=r[o],o+=2;return n},H=r=>3===r.length?`hsl(${r[0]},${r[1]}%,${r[2]}%)`:4===r.length?`hsl(${r[0]},${r[1]}%,${r[2]}%, ${r[3]})`:void 0,Y=r=>{let e,n=r.length;for(;0!=n;)e=floor(random()*n),n--,[r[n],r[e]]=[r[e],r[n]];return r},E=(r,e)=>{const n=r;n.sort(((r,e)=>dist(e[0].x,e[0].y,e[1].x,e[1].y)-dist(r[0].x,r[0].y,r[1].x,r[1].y)));let o=[[{x:0,y:0},{x:me,y:0},{x:me,y:he},{x:0,y:he}]];for(let r=0;r<n.length;r++){const e=[],i=n[r];o.forEach(((r,n)=>{const o=b(r,i);o?e.push(...C(o)):e.push(r)})),o=e}return e.length>0&&(o=o.map((r=>[r]))),o};let X=!1,I={},G={e:!0};I.gum={b5:[{a4:{l:[337,67,52],h:[350,67,55]},a0:[337,67,75],a1:[337,67,35],stroke:[350,67,60],a8:{c:.09,fill:[350,67,55]},e:G},90,{a4:{l:[246,30,30],h:[246,50,40]},a0:[227,67,50],a1:[337,67,20],stroke:[246,30,20],a8:{c:.2,fill:[246,50,40]},e:G},70,{a4:{l:[209,86,30],h:[209,86,40]},a0:[209,86,55],a1:[209,86,20],stroke:[209,94,30]},10],a3:[],c2:[{a4:[246,30,10],a0:[246,30,20],a1:[246,50,7],stroke:[246,30,35]},90,{a4:[230,30,8],a0:[230,30,20],a1:[230,50,5],stroke:[230,30,5]},30,{a4:[200,30,6],a0:[200,30,30],a1:[200,50,5],stroke:[200,30,5]},30,{a4:[246,80,10],a0:[246,5,15],a1:[246,0,5],stroke:[246,5,5]},90],c7:[{a4:[246,30,30]},1,{a4:[338,30,30]},1,{a4:[212,30,30]},1],c3:[{a4:[0,50,0,.25]},1],c0:[{l:[337,67,55],h:[337,67,40],mode:"none"},10,{l:[209,86,40],h:[246,86,40],mode:"none"},10],a2:[{l:[246,35,5,.15],h:[246,35,4,0],c5:[246,35,2]},10],c8:[{p:[246,30,2]},5,{p:[337,67,40]},1]},I.cloud={b5:[{a4:{l:[351,92,50],h:[351,92,60]},a0:[351,99,75],a1:[351,100,30],stroke:[351,92,40],a8:{c:.2,fill:[351,92,60]},e:G},60,{a4:{l:[52,92,60],h:[52,92,80]},a0:[52,99,90],a1:[52,92,50],stroke:[52,92,55],a8:{c:.1,fill:[52,92,80]}},20,{a4:{l:[180,28,5],h:[180,28,10]},a0:[180,5,20],a1:[180,28,2],stroke:[180,28,10]},100,{a4:{l:[38,48,70],h:[38,48,80]},a0:[38,48,90],a1:[38,48,70],stroke:[38,48,75]},30,{a4:{l:[311,22,23],h:[311,22,30]},a0:[311,30,45],a1:[311,30,10],stroke:[311,22,20]},40,{a4:{l:[183,86,70],h:[150,87,60]},a0:[150,87,85],a1:[183,86,40],stroke:[183,80,45]},10],a3:[],c2:[{a4:[214,45,59],a0:[214,45,80],a1:[214,45,30],stroke:[214,45,30]},90,{a4:[214,55,59],a0:[351,92,50],a1:[214,35,35],stroke:[214,35,30]},90,{a4:[214,45,90],a0:[214,45,95],a1:[214,50,50],stroke:[214,35,70]},90],c7:[{a4:[52,92,55]},40,{a4:[214,35,50]},90,{a4:[351,92,60]},30],c3:[{a4:[214,90,20,.25]},1],c0:[{l:[214,35,70],h:[351,92,60],mode:"none"},10,{h:[52,92,80],l:[311,22,30],mode:"none"},10],a2:[{l:[214,35,5,.05],h:[214,35,4,0],c5:[214,35,15]},10],c8:[{p:[214,35,95]},5,{p:[214,35,40]},5,{p:[351,92,60]},1]},I.montana={b5:[{a4:{l:[24,100,75],h:[24,100,86]},a0:[24,100,95],a1:[24,100,65],stroke:[24,100,72],a8:{c:.1,fill:[24,100,86]}},5,{a4:{l:[22,66,60],h:[22,66,72]},a0:[22,66,80],a1:[22,66,50],stroke:[22,66,54]},5,{a4:{l:[18,51,45],h:[18,51,60]},a0:[18,51,72],a1:[18,51,35],stroke:[18,51,45]},5,{a4:{l:[12,55,96],h:[12,55,90]},a0:[12,55,98],a1:[12,55,84],stroke:[12,55,84]},25,{a4:{l:[230,20,55],h:[215,20,45]},a0:[215,20,70],a1:[215,20,35],stroke:[215,20,40]},25,{a4:{l:[251,8,10],h:[251,8,15]},a0:[251,8,30],a1:[251,8,5],stroke:[251,8,5],e:G},150],a3:[],c2:[{a4:[210,34,40],a0:[210,34,50],a1:[210,34,30],stroke:[210,34,30]},9,{a4:[220,9,93],a0:[220,9,98],a1:[220,9,70],stroke:[220,9,80]},25,{a4:[208,35,30],a0:[208,35,50],a1:[208,22,10],stroke:[208,22,30]},5,{a4:[251,8,8],a0:[251,8,25],a1:[251,8,5],stroke:[251,8,10]},2],c7:[{a4:[24,100,83]},40,{a4:[24,100,40]},10,{a4:[250,8,24]},40],c3:[{a4:[220,47,5,.025]},1],c0:[{l:[22,66,60],h:[215,20,60],mode:"none"},15],a2:[{l:[215,20,5,.09],h:[215,20,4,0],c5:[215,20,2,.2]},10],c8:[{p:[220,9,90]},3,{p:[251,8,10]},5]},I.briss={b5:[{a4:{l:[54,100,54],h:[54,100,65]},a0:[54,100,72],a1:[54,100,49],stroke:[54,100,54]},3,{a4:{l:[2,100,54],h:[2,100,65]},a0:[2,100,72],a1:[2,100,45],stroke:[2,100,54],e:G},10,{a4:{l:[191,100,54],h:[191,100,65]},a0:[191,100,72],a1:[191,100,45],stroke:[191,100,54]},10,{a4:{l:[0,0,95],h:[0,0,100]},a0:[0,0,100],a1:[0,0,90],stroke:[0,0,90]},30,{a4:{l:[0,0,0],h:[0,0,0]},a0:[0,0,9],a1:[0,0,0],stroke:[0,0,100]},15],c2:[{a4:[0,0,0],a0:[60,4,7],a1:[60,4,0],stroke:[60,5,2]},10],c7:[{a4:[200,0,50]},40,{a4:[200,0,100]},10,{a4:[200,0,0]},10],c3:[{a4:[220,47,5,.1]},1],c0:[{l:[0,0,0],h:[10,50,100],mode:"none"},10],a2:[{l:[0,0,0,.2],h:[0,0,0,0],c5:[54,100,20]},10,{l:[0,0,0,.2],h:[0,0,0,0],c5:[2,100,20]},10,{l:[0,0,0,.2],h:[0,0,0,0],c5:[191,100,20]},10],c8:[{p:[0,0,95]},3,{p:[191,8,50]},5,{p:[191,95,65]},1]},I.skull={b5:[{a4:{l:[9,65,60],h:[40,88,70]},a0:[40,88,80],a1:[9,69,55],stroke:[9,65,70]},10,{a4:{l:[212,40,0],h:[212,40,3]},a0:[212,40,15],a1:[0,0,0],stroke:[0,0,5]},100,{a4:{l:[203,15,50],h:[203,15,60]},a0:[203,15,65],a1:[203,15,45],stroke:[203,15,75]},20,{a4:{l:[212,47,16],h:[212,47,25]},a0:[212,47,30],a1:[212,47,10],stroke:[212,47,15],e:G},200,{a4:{l:[351,59,45],h:[351,59,50]},a0:[351,59,65],a1:[351,80,30],stroke:[351,59,35],a8:{c:.1,fill:[351,59,50]},e:G},100,{a4:{l:[256,59,35],h:[256,59,40]},a0:[256,59,50],a1:[256,59,30],stroke:[256,59,35],a