1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1497],{4686:(e,t,l)=>{"use strict";l.r(t),l.d(t,{config:()=>I,default:()=>T});var i=l(37876),n=l(14232),r=l(39964),a=l(24879),o=l(54478),s=l(58036);let d=e=>400+(e-400)*.8,u=e=>560-(560-e)*.8,c={x:400,y:u(303),rx:40,ry:9.600000000000001},f={x0:d(154),y0:560,c1x:d(234),c1y:u(542),c2x:d(296),c2y:u(370),x1:c.x-c.rx-6.4,y1:c.y+4.800000000000001},h=[1,5,10,50,100,500,1e3,5e3,1e4,5e4],p=[20,24,31,37,44,52,61,72,83,96],g=1/60,y=[{x:112,y:176,w:176},{x:268,y:98,w:164},{x:532,y:98,w:164},{x:688,y:176,w:176}],m=[1,2,0,3],x=[["rose","\uD83C\uDF39"],["heart","\uD83D\uDC97"],["love","\uD83D\uDC96"],["cake","\uD83C\uDF82"],["donut","\uD83C\uDF69"],["doughnut","\uD83C\uDF69"],["ice cream","\uD83C\uDF66"],["car","\uD83C\uDFCEï¸"],["rocket","\uD83D\uDE80"],["lion","\uD83E\uDD81"],["whale","\uD83D\uDC0B"],["swan","\uD83E\uDDA2"],["corgi","\uD83D\uDC36"],["perfume","\uD83E\uDDF4"],["galaxy","\uD83C\uDF0C"],["planet","\uD83E\uDE90"],["star","â"],["crown","\uD83D\uDC51"],["money","\uD83D\uDCB8"],["coin","\uD83E\uDE99"],["finger","\uD83E\uDEF0"],["gg","\uD83C\uDFAE"],["tiktok","\uD83C\uDFB5"],["train","\uD83D\uDE82"]],v=(e,t,l)=>Math.max(t,Math.min(l,e));function b(e,t){return e>=Math.max(5e3,t)?"crown":e>=t?"pile":"cloud"}function M(e){return{c:Math.max(0,Number(e.d)||0),url:e.url||"",n:String(e.name||"").slice(0,40),z:"crown"===e.zone?"k":"cloud"===e.zone?"c":"p",s:e.side<0?-1:1}}let w=(e,t,l,i,n)=>{let r=1-n;return r*r*r*e+3*r*r*n*t+3*r*n*n*l+n*n*n*i},k=[];for(let e=0;e<=64;e++){let t=e/64;k.push([w(f.x0,f.c1x,f.c2x,f.x1,t),w(f.y0,f.c1y,f.c2y,f.y1,t)])}function C(e){let t=e<=400?e:800-e;if(t<=f.x0)return 560;if(t>=f.x1)return c.y+4;for(let e=1;e<k.length;e++)if(k[e][0]>=t){let[l,i]=k[e-1],[n,r]=k[e];return i+(r-i)*(t-l)/(n-l)}return 560}function S(e){e.beginPath(),e.moveTo(f.x0,f.y0),e.bezierCurveTo(f.c1x,f.c1y,f.c2x,f.c2y,f.x1,f.y1),e.quadraticCurveTo(f.x1+2,c.y-8,c.x-c.rx+6,c.y-6),e.lineTo(c.x+c.rx-6,c.y-6),e.quadraticCurveTo(800-f.x1-2,c.y-8,800-f.x1,f.y1),e.bezierCurveTo(800-f.c2x,f.c2y,800-f.c1x,f.c1y,800-f.x0,f.y0),e.closePath()}let z=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1.6;return 1+(t+1)*Math.pow(e-1,3)+t*Math.pow(e-1,2)},F=[{k:"bt",d:100,r:[10,5e3,10],L:"\uD83C\uDF0B à¸à¸à¸à¸à¸µà¹\uD83D\uDC8E à¸à¸¶à¹à¸à¹à¸à¸¥à¸à¸à¸à¸à¹à¸à¸´à¸à¹à¸à¸² (à¸à¹à¸³à¸à¸§à¹à¸² = à¸à¸¶à¹à¸à¹à¸¡à¸)"},{k:"mi",d:300,r:[10,300,5],L:"\uD83C\uDF81 à¸à¸à¸à¸à¸§à¸±à¸à¸à¸à¸à¸à¸ªà¸¹à¸à¸ªà¸¸à¸ (à¹à¸¡à¸ + à¸à¸à¸ + มà¸à¸à¸¸à¸)"},{k:"gs",d:100,r:[50,200,5],L:"\uD83D\uDCE6 à¸à¸à¸²à¸à¸à¸à¸à¸à¸§à¸±à¸ (%)"},{k:"vrain",d:60,r:[0,100,5],L:"\uD83C\uDF27 à¸à¸§à¸²à¸¡à¸«à¸à¸²à¸à¸à¸à¸à¸à¸à¸§à¸±à¸ (0 = à¹à¸¡à¹à¸¡à¸µà¸à¸)"},{k:"vface",d:1,r:[0,1,1],L:"\uD83D\uDE42 หà¸à¹à¸²à¸ ูà¹à¸à¸² (0/1)"},{k:"vlava",d:1,r:[0,2,1],L:"\uD83D\uDD25 à¸à¸à¸à¸¥à¸²à¸§à¸² (0 à¸à¸´à¸ \xb7 1 à¸à¸à¸à¹à¸à¸´à¸à¹à¸à¸² \xb7 2 à¸à¸¸à¸à¸à¸´à¹à¸)"},{k:"keep",d:30,r:[0,240,5],L:"\uD83D\uDCBE à¸à¸³à¸à¸²à¸à¸«à¸¥à¸±à¸ OBS refresh (à¸à¸²à¸à¸µ \xb7 0 = à¹à¸¡à¹à¸à¸³)"}],A={à¹à¸à¸£à¹à¸à¹à¸ª:null,หà¹à¸à¸à¸à¸£à¸´à¸:"linear-gradient(180deg,#8fa7b8 0%,#c9b59a 55%,#6e5a4c 100%)",à¸à¸²à¸§à¸ªà¸§à¹à¸²à¸:"linear-gradient(#f4f1ec,#dcd6cf)",มืà¸:"#141016"},P=[["Rose",1],["Heart Me",1],["TikTok",1],["Finger Heart",5],["Perfume",20],["Doughnut",30],["Hand Hearts",100],["Corgi",299],["Money Gun",500],["Rose",1],["Galaxy",1e3],["GG",1],["Swan",699],["Ice Cream Cone",1],["Rosa",10],["Sports Car",7e3]];function T(){let e=(0,n.useRef)(null),t=(0,n.useRef)(null),l=(0,n.useRef)(null),d=(0,n.useRef)(!1),[u,w]=(0,n.useState)({bg:"transparent",br:0}
1),[k,T]=(0,n.useState)(!1),[I,E]=(0,n.useState)(()=>Object.fromEntries(F.map(e=>[e.k,e.d]))),[j,R]=(0,n.useState)("à¹à¸à¸£à¹à¸à¹à¸ª"),[q,N]=(0,n.useState)(""),[_,D]=(0,n.useState)(null);(0,n.useEffect)(()=>{d.current=!0;let i=e.current;if(i)try{window.__gvBootError=null;let e=new URLSearchParams(window.location.search),E=e.get("cid")||e.get("wt")||e.get("vjId")||"",j="1"===e.get("preview"),R=null,q={bt:100,mi:300,giftScale:1,vrain:60,vface:1,vlava:1,keep:30,fpsCap:60,tierR:p.slice()};l.current=q;let N=e=>{if(!e||"object"!=typeof e)return;let t=(t,l,i)=>{let n=parseFloat(e[t]);return Number.isFinite(n)?v(n,l,i):void 0},l=(e,l,i,n,r)=>{let a=t(l,i,n);void 0!==a&&(q[e]=r?a/r:a)};l("bt","bt",10,5e3);let i=q.mi;if(l("mi","mi",10,300),l("giftScale","gs",50,200,100),l("vrain","vrain",0,100),void 0!==e.vface&&(q.vface=+("0"!==String(e.vface))),void 0!==e.vlava){let t=parseInt(e.vlava,10);q.vlava=[0,1,2].includes(t)?t:1}if(l("keep","keep",0,240),void 0!==e.keep&&R&&R.setKeep(q.keep),void 0!==e.fps){let t=parseInt(e.fps,10);q.fpsCap=[24,30,60].includes(t)?t:60}let r=!1;for(let e=0;e<10;e++){let l=t("r"+(e+1),3,200);void 0!==l&&l!==q.tierR[e]&&(q.tierR[e]=l,r=!0)}(r||void 0!==e.gs)&&function(){for(let e of Z)e.size=U(e.d),e.r=.5*e.size+2,e.sleep=0;el&&(el.size=U(el.d),el.y=c.y-.42*el.size)}(),q.mi<i&&n(),(e.bgRgba||void 0!==e.br)&&w({bg:e.bgRgba||"transparent",br:Number(e.br)||0})},_=i.getContext("2d"),L=1,O=()=>{let e=i.getBoundingClientRect().width||1100,t=v(e/1100*(window.devicePixelRatio||1),.5,2);.01>Math.abs(t-L)&&i.width===Math.round(1100*t)||(L=t,i.width=Math.round(1100*L),i.height=Math.round(600*L),W.clear(),er=null)},G="undefined"!=typeof ResizeObserver?new ResizeObserver(O):null,B=new Map,W=new Map,H=function(e,t,l,i){let n=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0,r=arguments.length>5&&void 0!==arguments[5]?arguments[5]:1,a=arguments.length>6&&void 0!==arguments[6]?arguments[6]:1,o=arguments.length>7&&void 0!==arguments[7]?arguments[7]:1,s=!(arguments.length>8)||void 0===arguments[8]||arguments[8],u=arguments.length>9&&void 0!==arguments[9]&&arguments[9],c=((e,t,l,i)=>{let n=Math.max(8,4*Math.round(t/4)),r=(e.url||"#"+e.emoji)+"|"+n+"|"+ +!!l+(i?"L":"")+"|"+L.toFixed(2),a=W.get(r);if(a)return W.delete(r),W.set(r,a),a;let o=e.url?(e=>{if(!e)return null;let t=B.get(e);if(t)return t;t={img:new Image,ok:!1,bad:!1,tries:0};let l=()=>{t.tries++,t.img=new Image,t.img.crossOrigin="anonymous";let l=setTimeout(()=>{t.ok||i()},4e3);t.img.onload=()=>{clearTimeout(l),t.ok=!0,t.bad=!1,(e=>{for(let t of W.keys())t.startsWith(e+"|")&&W.delete(t)})(e)},t.img.onerror=()=>{clearTimeout(l),i()},t.img.src=e},i=()=>{!t.ok&&(t.bad=!0,t.tries<2&&setTimeout(()=>{d.current&&l()},5e3))};if(l(),B.set(e,t),B.size>120){let e=B.keys().next().value;B.delete(e)}return t})(e.url):null,s=i?8:3*!!l,u=Math.max(2,Math.ceil((n+2*s)*L));(a=document.createElement("canvas")).width=a.height=u;let c=a.getContext("2d");c.scale(L,L);let f=document.createElement("canvas");f.width=f.height=u;let h=f.getContext("2d");if(h.scale(L,L),o&&o.ok&&o.img.naturalWidth){let e=o.img.naturalWidth,t=o.img.naturalHeight,l=Math.min(n/e,n/t);h.drawImage(o.img,s+(n-e*l)/2,s+(n-t*l)/2,e*l,t*l)}else h.font="".concat(Math.round(.82*n),'px "Segoe UI Emoji","Apple Color Emoji","Noto Color Emoji",sans-serif'),h.textAlign="center",h.textBaseline="middle",h.fillText(e.emoji||"\uD83C\uDF81",s+n/2,s+n/2+.04*n);let p=e=>{let t=document.createElement("canvas");t.width=t.height=u;let l=t.getContext("2d");return l.drawImage(f,0,0),l.globalCompositeOperation="source-in",l.fillStyle=e(l),l.fillRect(0,0,u,u),t},g=function(e,t,l){let i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1;c.globalAlpha=i;for(let i=0;i<l;i++){let r=2*i*Math.PI/l;c.drawImage(e,Math.cos(r)*t,Math.sin(r)*t,n+2*s,n+2*s)}c.globalAlpha=1};if(i){let e=p(()=>"#FF6A1F");g(e,7,16,.16),g(e,5,16,.22);let t=p(e=>{let t=e.createLinearGradient(0,0,0,u);return t.addColorStop(0,"#FFE27A"),t.addColorStop(.45,"#FF9A2E"),t.addColorStop(1,"#E8321A"),t});g(t,3.2,12),g(t,1.8,12)}else l&&g(p(()=>"#FFF6F0"),n>=60?3:2,8);return c.drawImage(f,0,0,n+2*s,n+2*s),a._d=n+2*s,W.set(r,a),W.size>300&&W.delete(W.keys().next().value),a})(e,i,s,u),f=c._d;_.save(),_.globalAlpha*=o,_.translate(t,l),_.rotate(n),_.scale(r,a),_.drawImage(c,-f/2,-f/2,f,f),_.restore(
1)},U=e=>q.tierR[(e=>{let t=0;for(let l=0;l<h.length;l++)e>=h[l]&&(t=l);return t})(e)]*q.giftScale,J=()=>38*q.giftScale,K=y.map((e,t)=>({...e,items:[],incoming:0,sq:0,sqv:0,ph:1.7*t,rainAcc:0,vis:0,want:!1})),V=e=>e.items.length+e.incoming,X=e=>3*Math.sin(ea*(2*Math.PI/(2.4+.2*e.ph))+e.ph),Z=[],Y=[],$=[],Q=[],ee=[],et=[],el=null,ei=0,en=-1,er=null,ea=0,eo=0,es=-9,ed=0,eu=0,ec=0,ef={sy:1,v:0},eh=0,ep={mode:"normal",until:0,blinkAt:2,look:0,lookT:0},eg=0,ey=60,em=null,ex="-",ev={n:0,t:0,fps:0,drawMs:0},eb=0,eM=[],ew=(e,t)=>{ep.mode=e,ep.until=ea+t},ek=function(e,t,l,i){let n=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"puff";ee.length>80&&ee.shift(),ee.push({x:e,y:t,r:l,vx:(Math.random()-.5)*20,vy:-30-30*Math.random(),life:i,t:0,kind:n})},eC=function(e,t,l){let i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return{id:++ed,d:e,url:t||"",name:l||"",emoji:(e=>{let t=String(e||"").toLowerCase();for(let[e,l]of x)if(t.includes(e))return l;return"\uD83C\uDF81"})(l),born:ea,test:!!i.test,zone:b(e,q.bt),side:1}},eS=()=>(function(e){let t=v(Math.round(e)||40,10,300);return{cloud:Math.min(4*y.length,Math.max(2,Math.round(.4*t)))}})(q.mi),ez=()=>{let e=null,t=null;for(let l of K)for(let i of l.items)(!e||i.d<e.d||i.d===e.d&&i.born<e.born)&&(e=i,t=l);return e?{it:e,c:t}:null},eF=(e,t)=>{e.items.splice(e.items.indexOf(t),1);let l=t.pos||{x:e.x,y:e.y};t.zone="pile";let i=U(t.d),n=eE(i);Y.push({p:t,size:i,side:n.side,cloud:null,x0:l.x,y0:l.y,tx:n.tx,ty:n.ty,u:0,dur:.9,arcH:18,rot:0,x:l.x,y:l.y,full:!0})},eA=()=>+!!el+Z.filter(e=>!e.leaving).length+K.reduce((e,t)=>e+t.items.length,0),eP=(e,t)=>{if(t){t.items.splice(t.items.indexOf(e),1);let l=e.pos||{x:t.x,y:t.y};e.x=l.x,e.y=l.y,e.size=U(e.d),e.r=.5*e.size+2,e.side=l.x<400?-1:1,e.rot=0,e.sq=0,e.alpha=1,Z.push(e)}e===el&&(el=null,e.side=1,e.r=.5*e.size+2,e.rot=0,e.sq=0,e.alpha=1,Z.push(e)),e.zone="pile",e.leaving=!0,e.sleep=0,e.vx=340*e.side,e.vy=t?0:-160,!e.test&&(eb++,eM.length<500&&eM.push(e.d))};function n(){let e=eS().cloud;for(;K.reduce((e,t)=>e+t.items.length,0)>e;){let e=ez();if(!e)break;eF(e.c,e.it)}let t=e=>e.reduce((e,t)=>t.d<e.d||t.d===e.d&&t.born<e.born?t:e);for(let e of K)for(;e.items.length>4;){let l=t(e.items),i=ez(),n=K.find(t=>t!==e&&t.items.length+t.incoming<4);n?(e.items.splice(e.items.indexOf(l),1),n.items.push(l)):i&&i.c!==e&&i.it.d<l.d?(eF(i.c,i.it),e.items.splice(e.items.indexOf(l),1),i.c.items.push(l)):eF(e,l)}for(;eA()>q.mi;){let e=null,t=null,l=(l,i)=>{(!e||l.d<e.d||l.d===e.d&&l.born<e.born)&&(e=l,t=i)};for(let e of Z)e.leaving||l(e,null);for(let e of K)for(let t of e.items)l(t,e);if(el&&l(el,null),!e)break;eP(e,t)}}let eT=function(e,t,l,i){let n=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{};e.zone="pile",e.side=i,e.size=U(e.d),e.r=.5*e.size+2,Object.assign(e,{x:t,y:l,vx:n.vx||0,vy:n.vy||0,rot:(Math.random()-.5)*.28,sleep:0,sq:0,leaving:!1,alpha:1}),Z.push(e)},eI=e=>{let t=C(e);for(let l of Z)l.leaving||Math.abs(l.x-e)>l.r+18||(t=Math.min(t,l.y-l.r));for(let l of Y)"pile"===l.p.zone&&40>Math.abs(l.tx-e)&&(t-=30);return t},eE=e=>{let t=ej(),l=f.x0+40,i=-110,n=-1,r=t<0?i:800-i;for(let e=0;e<7;e++){let a=i+(e+Math.random())/7*(l-i),o=t<0?a:800-a,s=eI(o);s>n&&(n=s,r=o)}return{side:t,tx:r,ty:Math.min(330+40*Math.random(),n-.5*e-10)}},ej=()=>{let e=e=>Z.filter(t=>t.side===e&&!t.leaving).length+Y.filter(t=>"pile"===t.p.zone&&t.side===e).length,t=e(-1),l=e(1);return t===l?.5>Math.random()?-1:1:t<l?-1:1},eR=(e,t,l)=>{let i=.72*e.w,n=e.x-i/2+(l<=1?i/2:i*t/(l-1)),r=12*Math.cos((n-e.x)/(.5*e.w)*1.2);return{x:n,y:e.y+X(e)-20-r}},eq=e=>{let t=e.p;if("cloud"===t.zone){let l=e.cloud;l.incoming=Math.max(0,l.incoming-1),t.born=ea,l.items.push(t),l.sqv+=7,n();return}if("crown"===t.zone){t.size=e.size,t.x=e.tx,t.y=e.ty;let l=null;if(el&&el.d>t.d?l=t:(l=el,el=t),l){l.zone="pile";let e=eE(l.size);Y.push({p:l,size:l.size,side:e.side,cloud:null,x0:l.x,y0:l.y,tx:e.tx,ty:e.ty,u:0,dur:.78,arcH:Math.max(0,Math.min(120,Math.min(l.y,e.ty)-24-.5*l.size)),rot:0,x:l.x,y:l.y,full:!0})}n();return}eT(t,e.x,e.y,e.side,{vx:30*e.side,vy:120}),n()},eN=function(e,t,l){let i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1,n=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{},r=v(Math.round(i)||1,1,99);for(let i=0;i<r;i++)$.push(eC(Math.max(0,Number(e)||0),t,l,n));if(!n.silent){let e=ea-eo;eo=ea,ey=60,e>300&&(ew("surprised",.6),ef.sy=1.06,ef.v=-3)}n.test||(ei+=(Number(e)||0)*r),!n.test&&R&&R.touch()};function u(e){ea+=e;let t=ec/e;ec=0,eu+=(t-eu)*(1-Math.exp(-e/3));let l=Math.min(1,eu/12);if($.length){let e=.12*Math.min(1,6/$.length);ea-es>=e&&(ea-es>.4&&"strain"!==ep.mode?(ew("strain",.09),es=ea-e+.09):((e=>{let t=b(e.d,q.bt);e.zone=t;let l="cloud"===t?J():U(e.d),i,n,r=1,a=null;if("crown"===t&&el&&el.d>e.d&&(e.zone="pile"),"crown"===e.zone){i=c.x+c.rx+6,n=c.y-.42*l,eh=.45,ew("surprised",.5);for(let e=0;e<10;e++)ek(c.x+(Math.random()-.5)*60,c.y-10,18+16*Math.random(),1.4)}else if("pile"===e.zone)({side:r,tx:i,ty:n}=eE(l));else{let e=eS().cloud,t=m.map(e=>K[e]);if((a=t.find(t=>4>V(t)&&K.reduce((e,t)=>
1e+V(t),0)<e)||(ez()||{}).c||t.filter(e=>V(e)>0).sort((e,t)=>V(e)-V(t))[0]||t[0]).vis<.05)for(let e=0;e<5;e++)ek(a.x+(Math.random()-.5)*a.w*.6,a.y,14+10*Math.random(),.9);let l=eR(a,Math.min(V(a),3),Math.min(4,V(a)+1));i=l.x,n=l.y,a.incoming++}let o=Math.min("pile"===e.zone?170:90,Math.min(c.y,n)-24-.5*l);Y.push({p:e,size:l,side:r,cloud:a,x0:c.x,y0:c.y-6,tx:i,ty:n,u:0,dur:"crown"===e.zone?1:.78,arcH:Math.max(0,o),rot:0,x:c.x,y:c.y}),ef.sy=.94,ef.v=2.4;for(let e=0;e<3;e++)ek(c.x+(Math.random()-.5)*40,c.y-6,10+8*Math.random(),1.1);for(let e=0;e<6;e++)et.push({k:"ember",x:c.x+(Math.random()-.5)*30,y:c.y-4,vx:(Math.random()-.5)*160,vy:-200-160*Math.random(),life:.7,t:0});et.length>120&&et.splice(0,et.length-120),ew("happy",.8)})($.shift()),es=ea)),$.length>2&&ew("strain",.2)}let i=Math.sqrt(120);ef.v+=(-(120*(ef.sy-1))-ef.v*i)*e,ef.sy+=ef.v*e,eh=Math.max(0,eh-e);for(let t=Y.length-1;t>=0;t--){let l=Y[t];l.u=Math.min(1,l.u+e/l.dur);let i=1-(1-l.u)*(1-l.u),n=l.tx,r=l.ty;if("cloud"===l.p.zone&&l.cloud){let e=eR(l.cloud,Math.min(l.cloud.items.length,3),Math.min(4,l.cloud.items.length+1));n=e.x,r=e.y}l.x=l.x0+(n-l.x0)*i,l.y=l.y0+(r-l.y0)*i-Math.sin(i*Math.PI)*l.arcH,l.rot=5*l.u*("pile"===l.p.zone?1:.5),l.u>=1&&(Y.splice(t,1),eq(l))}for(let t of(k(e),K))t.sqv+=(-(140*t.sq)-10*t.sqv)*e,t.sq+=t.sqv*e,t.want=V(t)>0,t.vis=t.want?Math.min(1,t.vis+e/.35):Math.max(0,t.vis-e/.8);let n=ea-eo,r=n>300?0:n>15?.35:1;
1for(let t of K){if(!t.items.length||t.vis<.9){t.rainAcc=0;continue}let i=q.vrain/100*Math.min(5,1.3*t.items.length)*r*(1+1.5*l);for(t.rainAcc+=i*e;t.rainAcc>=1&&Q.length<60;){t.rainAcc-=1;let e=t.items[Math.random()*t.items.length|0],l=t.y+X(t)+8;Q.push({p:e,x:t.x+(Math.random()-.5)*t.w*.6,y:l,y0:l,yEnd:470+30*Math.random(),vy:130+60*Math.random(),ph:6*Math.random()})}t.rainAcc>1&&(t.rainAcc=1)}for(let t of Q)t.y+=t.vy*e,t.vy+=40*e;for(let t of(Q.length&&(Q=Q.filter(e=>e.y<e.yEnd)),n<300&&Math.random()<e*(n>15?.8:2.2)&&ek(c.x+(Math.random()-.5)*30,c.y-8,7+6*Math.random(),1.6),n>300&&Math.random()<.35*e&&et.push({k:"z",x:c.x+20,y:c.y-20,vx:12,vy:-22,life:2.6,t:0}),ee))t.t+=e,t.x+=t.vx*e,t.y+=t.vy*e,t.r+=22*e,t.vy+=14*e;for(let t of(ee.length&&(ee=ee.filter(e=>e.t<e.life)),et))t.t+=e,t.x+=t.vx*e,t.y+=t.vy*e,"ember"===t.k&&(t.vy+=900*e);if(et.length&&(et=et.filter(e=>e.t<e.life)),n>ey&&n<300&&(ey+=60,F()),em&&ea>=em.at){let e=em.fn;em=null,e()}ei>=3e3&&en<0&&(en=0),en>=0&&(en+=e),ea>ep.blinkAt&&(ep.blinkAt=ea+3+3*Math.random()),ep.lookT>0?(ep.lookT-=e,ep.look=4*Math.sin((2.2-ep.lookT)*3)):ep.look=0}function k(e){for(let t of Z){if(t.sleep>.4&&!t.leaving)continue;if(t.vy+=1800*e,t.vx*=Math.pow(.35,e),t.x+=t.vx*e,t.y+=t.vy*e,t.rot+=t.vx*e*.004,t.leaving){t.vx/=Math.pow(.35,e),t.leaveT=(t.leaveT||0)+e,t.alpha=Math.max(0,1-Math.max(0,t.leaveT-.5)/.7),(t.x<-240||t.x>1040)&&(t.alpha=0),t.y>560-t.r&&(t.y=560-t.r,t.vy=-(.3*Math.abs(t.vy)));continue}let l=C(t.x);t.y+.92*t.r>l&&(t.vy>250&&(t.sq=1),t.y=l-.92*t.r,t.vy=-(.25*t.vy),l<560&&(t.vx+=(t.x<400?-1:1)*700*e),t.vx*=.9),t.x<t.r-150&&(t.x=t.r-150,t.vx=.3*Math.abs(t.vx)),t.x>950-t.r&&(t.x=950-t.r,t.vx=-(.3*Math.abs(t.vx)))}let t=Z.filter(e=>!e.leaving);for(let e=0;e<8;e++)for(let e=0;e<t.length;e++)for(let l=e+1;l<t.length;l++){let i=t[e],n=t[l],r=i.r+n.r,a=n.x-i.x,o=n.y-i.y;if(a>r||a<-r||o>r||o<-r)continue;let s=Math.hypot(a,o)||.01;if(s>=r)continue;let d=(r-s)/2,u=a/s,c=o/s,f=i.sleep>.4?.25:1,h=n.sleep>.4?.25:1,p=f+h;i.x-=u*d*2*f/p,i.y-=c*d*2*f/p,n.x+=u*d*2*h/p,n.y+=c*d*2*h/p,c>.3?i.vy=Math.min(i.vy,0):c<-.3&&(n.vy=Math.min(n.vy,0)),i.sleep>.4&&d>.5&&(i.sleep=0),n.sleep>.4&&d>.5&&(n.sleep=0)}for(let l of t){let i=C(l.x);if(l.y+.92*l.r>i&&(l.y=i-.92*l.r),i<558&&l.y+.92*l.r>=i-1&&!t.some(e=>e!==l&&Math.hypot(e.x-l.x,e.y-l.y)<(e.r+l.r)*1.02&&Math.abs(e.x-400)>Math.abs(l.x-400))){l.vx+=(l.x<400?-1:1)*900*e,l.sleep=0;continue}l.x=v(l.x,l.r-150,950-l.r),l.y=v(l.y,24+l.r,560-.5*l.r),6>Math.abs(l.vx)&&60>Math.abs(l.vy)?l.sleep+=e:l.sleep=0,l.sq=Math.max(0,l.sq-e/.18)}Z.some(e=>e.alpha<=0)&&(Z=Z.filter(e=>e.alpha>0))}let e_=["hiccup","look","sneeze","heart"];function F(e){let t=e||e_[eg++%e_.length];ex=t,"hiccup"===t&&(ef.sy=1.05,ef.v=-3,ek(c.x,c.y-10,10,1.4,"ring"),ew("surprised",.35)),"look"===t&&(ep.lookT=2.2,ew("happy",2.2)),"sneeze"===t&&(ew("strain",.35),em={at:ea+.35,fn:()=>{for(let e=0;e<12;e++)ek(c.x+(Math.random()-.5)*70,c.y-10,12+14*Math.random(),1.6);for(let e of K)e.sqv+=4;ew("surprised",.5)}}),"heart"===t&&(eD(),ew("happy",1.2))}let eD=()=>et.push({k:"heart",x:c.x,y:c.y-20,vx:0,vy:-38,life:1.5,t:0});function A(){let e=performance.now(),t=ea-eo,l=t>300,i=Math.min(1,eu/12);
1_.setTransform(L,0,0,L,150*L,0),_.clearRect(-150,0,1100,600),en>=0&&function(e){if(!er){let e=document.createElement("canvas");e.width=Math.round(1100*L),e.height=Math.round(600*L);let t=e.getContext("2d");t.scale(L,L),t.translate(150,0);let l=1.04*Math.PI,i=1.96*Math.PI,n=e=>e*e*(3-2*e);t.lineWidth=9.5,t.lineCap="butt",["#FFB3C1","#FFD3A5","#FFF1A8","#BDF0C4","#B5DBFF","#D5C2FF"].forEach((e,r)=>{t.strokeStyle=e;for(let e=0;e<72;e++){let a=(e+.5)/72;t.globalAlpha=.55*n(Math.min(1,Math.min(a,1-a)/.24)),t.beginPath(),t.arc(400,330,300-9*r,l+(i-l)*e/72,l+(i-l)*(e+1.04)/72),t.stroke()}}),er=e}_.save(),_.beginPath(),_.rect(-150,0,1100*e+.1,600),_.clip(),_.drawImage(er,-150,0,1100,600),_.restore()}(Math.min(1,en/1.2));let n=.55*J();for(let e of Q){let t=(e.y-e.y0)/(e.yEnd-e.y0),l=.62*(t<.7?1:1-(t-.7)/.3);H(e.p,e.x+4*Math.sin(2.2*ea+e.ph),e.y,n,.2*Math.sin(2*ea+e.ph),.9,1.15,l,!1,!1)}let r=_.createRadialGradient(400,566,20,400,566,420);r.addColorStop(0,"rgba(120,70,95,0.28)"),r.addColorStop(1,"rgba(120,70,95,0)"),_.fillStyle=r,_.beginPath(),_.ellipse(400,566,420,20,0,0,7),_.fill(),_.save();let a=eh>0?4*Math.sin(90*ea)*(eh/.45):0;for(let e of(_.translate(400+a,560),_.scale(1+(1-ef.sy)*.5,ef.sy),_.translate(-400,-560),function(e,t){_.save(),S(_),_.lineWidth=6,_.strokeStyle="#8E6479",_.lineJoin="round",_.stroke();let l=_.createLinearGradient(0,c.y,0,560);t?(l.addColorStop(0,"#907084"),l.addColorStop(.5,"#9F8190"),l.addColorStop(1,"#AC96A0")):(l.addColorStop(0,"#B98FA6"),l.addColorStop(.5,"#CBA6B8"),l.addColorStop(1,"#DCC0CC")),S(_),_.fillStyle=l,_.fill(),_.clip();let i=_.createLinearGradient(f.x0+90,0,420,0);i.addColorStop(0,"rgba(255,240,246,0.35)"),i.addColorStop(1,"rgba(255,240,246,0)"),_.fillStyle=i,_.fillRect(0,c.y-20,420,560-c.y+20);let n=_.createLinearGradient(430,0,800-f.x0,0);for(let[e,t]of(n.addColorStop(0,"rgba(120,70,100,0)"),n.addColorStop(1,"rgba(120,70,100,0.22)"),_.fillStyle=n,_.fillRect(400,c.y-20,400,560-c.y+20),[[-30,34],[-8,52],[18,30],[34,44]])){let l=c.x+e,i=c.y-4;_.fillStyle="#FF6B4A",_.beginPath(),_.moveTo(l-9,i),_.lineTo(l-5,i+t-6),_.arc(l,i+t-6,5,Math.PI,0,!0),_.lineTo(l+9,i),_.fill()}_.fillStyle="#FF6B4A",_.fillRect(c.x-c.rx-6,c.y-8,2*c.rx+12,16),_.restore();let r=60+40*e,a=_.createRadialGradient(c.x,c.y-4,4,c.x,c.y-4,r);a.addColorStop(0,"rgba(255,170,110,".concat((t?.15:.35)+.35*e,")")),a.addColorStop(1,"rgba(255,170,110,0)"),_.fillStyle=a,_.beginPath(),_.arc(c.x,c.y-4,r,0,7),_.fill(),_.fillStyle="#FF8A5C",_.strokeStyle="#C7482E",_.lineWidth=3,_.beginPath(),_.ellipse(c.x,c.y-4,c.rx,c.ry,0,0,7),_.fill(),_.stroke(),_.fillStyle=t?"#E0764E":"#FFD08A",_.beginPath(),_.ellipse(c.x-6,c.y-6,.55*c.rx,.45*c.ry,0,0,7),_.fill()}(i,l),q.vface&&function(e){let t=ep.until>ea?ep.mode:"normal";ep.until<=ea&&(e>300?t="sleep":e>15&&(t="sleepy"));let l=(400-f.x0)/224,i=26*l,n=c.y+.58*(560-c.y),r="#4A2F3A";_.fillStyle="rgba(255,140,160,0.45)",_.beginPath(),_.ellipse(400-50*l,n+22,14,8,0,0,7),_.fill(),_.beginPath(),_.ellipse(400+50*l,n+22,14,8,0,0,7),_.fill(),_.strokeStyle=r,_.fillStyle=r,_.lineWidth=3.5,_.lineCap="round";let a=ea>ep.blinkAt-.12;for(let e of[-1,1]){let l=400+e*i+ep.look;if("happy"===t)_.beginPath(),_.arc(l,n+3,8,1.1*Math.PI,1.9*Math.PI),_.stroke();else if("strain"===t)_.beginPath(),_.moveTo(l-7*e,n-7),_.lineTo(l+5*e,n),_.lineTo(l-7*e,n+7),_.stroke();else if("sleep"===t)_.beginPath(),_.arc(l,n-2,8,.15*Math.PI,.85*Math.PI),_.stroke();else if("surprised"===t)_.fillStyle="#FFF",_.beginPath(),_.arc(l,n,11,0,7),_.fill(),_.stroke(),_.fillStyle=r,_.beginPath(),_.arc(l,n,4.5,0,7),_.fill();else if(a)_.beginPath(),_.moveTo(l-8,n),_.lineTo(l+8,n),_.stroke();else{let e="sleepy"===t?4.05:10.35;_.fillStyle=r,_.beginPath(),_.ellipse(l,n+3*("sleepy"===t),7.6499999999999995,e,0,0,7),_.fill(),"sleepy"===t?(_.beginPath(),_.moveTo(l-10,n),_.lineTo(l+10,n),_.stroke()):(_.fillStyle="#FFF",_.beginPath(),_.arc(l-2.5,n-3.5,3,0,7),_.fill(),_.beginPath(),_.arc(l+2.5,n+3,1.4,0,7),_.fill())}_.fillStyle=r}let o=n+24;if(_.lineWidth=3,"happy"===t)_.fillStyle="#7A3A4E",_.beginPath(),_.moveTo(390,o-3),_.quadraticCurveTo(400,o+16,410,o-3),_.closePath(),_.fill(),_.fillStyle="#FF8FA8",_.beginPath(),_.arc(400,o+6,4.5,0,Math.PI),_.fill();
1else if("surprised"===t||"sleep"===t){let e="sleep"===t?3+Math.sin(2*ea):5;_.beginPath(),_.ellipse(400,o+2,e,"sleep"===t?e:7,0,0,7),_.stroke()}else if("strain"===t){_.beginPath(),_.moveTo(391,o);for(let e=0;e<4;e++)_.lineTo(391+(e+.5)*4.5,o+(e%2?-3:3));_.lineTo(409,o),_.stroke()}else _.beginPath(),_.arc(395,o-2,5,.1*Math.PI,.9*Math.PI),_.stroke(),_.beginPath(),_.arc(405,o-2,5,.1*Math.PI,.9*Math.PI),_.stroke()}(t),_.restore(),ee)){let t=.55*(1-e.t/e.life);if("ring"===e.kind){_.strokeStyle="rgba(240,232,246,".concat(t,")"),_.lineWidth=4,_.beginPath(),_.ellipse(e.x,e.y,e.r,.5*e.r,0,0,7),_.stroke();continue}_.fillStyle="rgba(236,228,244,".concat(t,")"),_.beginPath(),_.arc(e.x,e.y,e.r,0,7),_.fill()}let o=q.vlava>=1,s=2===q.vlava;for(let e of Z)H(e,e.x,e.y,e.size,e.rot,1+.18*e.sq,1-.15*e.sq,e.alpha*(e.leaving?.9:1),!0,o),e.d>=500&&!e.leaving&&function(e,t,l){let i=4+2*Math.sin((ea+l)*2.2);i<3||(_.fillStyle="rgba(255,248,220,0.95)",_.beginPath(),_.moveTo(e,t-1.6*i),_.quadraticCurveTo(e,t,e+1.6*i,t),_.quadraticCurveTo(e,t,e,t+1.6*i),_.quadraticCurveTo(e,t,e-1.6*i,t),_.quadraticCurveTo(e,t,e,t-1.6*i),_.fill())}(e.x+.7*e.r,e.y-.7*e.r,e.born);if(el){let e=2*Math.sin(2.3*ea),t=_.createRadialGradient(el.x,el.y+e,4,el.x,el.y+e,.9*el.size);t.addColorStop(0,"rgba(255,214,120,0.55)"),t.addColorStop(1,"rgba(255,214,120,0)"),_.fillStyle=t,_.beginPath(),_.arc(el.x,el.y+e,.9*el.size,0,7),_.fill(),H(el,el.x,el.y+e,el.size,0,1,1,1,!0,o),_.font='22px "Segoe UI Emoji","Apple Color Emoji","Noto Color Emoji",sans-serif',_.textAlign="center",_.textBaseline="alphabetic",_.fillText("\uD83D\uDC51",el.x,el.y+e-.52*el.size)}for(let e of K){if(e.vis<=.01)continue;!function(e,t){let l=e.want?z(Math.min(1,e.vis)):e.vis,i=(1+.12*e.sq)*(.55+.45*l),n=(1-.12*e.sq)*(.55+.45*l);_.save(),_.globalAlpha*=Math.min(1,1.4*e.vis),_.translate(e.x,e.y+X(e)+18),_.scale(i,n),_.translate(0,-18);let r=e.w,a=.42*r,o=[[-.36,.12,.26],[-.14,-.08,.32],[.14,-.12,.34],[.36,.08,.27],[0,.16,.3]];for(let[e,t,l]of(_.fillStyle="#B9A5D3",o))_.beginPath(),_.arc(e*r,t*a*1.4,l*r*.62+2.5,0,7),_.fill();let s=_.createLinearGradient(0,-a,0,.7*a);for(let[e,l,i]of(s.addColorStop(0,t?"#E9E4EF":"#FFFFFF"),s.addColorStop(1,t?"#CFC4DC":"#E4DAF2"),_.fillStyle=s,o))_.beginPath(),_.arc(e*r,l*a*1.4,i*r*.62,0,7),_.fill();_.restore()}(e,l);let t=e.items.length,i=Math.min(1,1.4*e.vis);e.items.forEach((l,n)=>{let r=eR(e,n,Math.max(t,1));l.pos=r,H(l,r.x,r.y,J(),.1*Math.sin(1.3*ea+n),1+.08*e.sq,1-.08*e.sq,i,!0,s)})}for(let e of Y)H(e.p,e.x,e.y,e.full?e.size:e.size*(.7+.3*e.u),e.rot,1,1,1,!0,"cloud"===e.p.zone?s:o);for(let e of et){var d,u,h;let t=1-e.t/e.life;"ember"===e.k&&(_.fillStyle="rgba(255,140,90,".concat(t,")"),_.beginPath(),_.arc(e.x,e.y,2.4,0,7),_.fill()),"heart"===e.k&&(_.save(),_.globalAlpha=t,_.translate(e.x,e.y),_.scale(1+.6*e.t,1+.6*e.t),d=0,u=0,h=16,_.beginPath(),_.moveTo(0,5.6),_.bezierCurveTo(d-h,u-.35*h,d-.45*h,u-h,d,u-.45*h),_.bezierCurveTo(d+.45*h,u-h,d+h,u-.35*h,d,u+.35*h),_.fillStyle="#FFD1DE",_.fill(),_.lineWidth=2,_.strokeStyle="#E58AA6",_.stroke(),_.restore()),"z"===e.k&&(_.globalAlpha=t,_.fillStyle="#EDE3F5",_.font="bold ".concat(14+6*e.t,"px system-ui, sans-serif"),_.fillText("z",e.x,e.y),_.globalAlpha=1)}ev.drawMs=.9*ev.drawMs+(performance.now()-e)*.1}let eL="ttp:giftvolcano:".concat(E||"preview");R=(0,s.dO)({key:eL,keepMinutes:q.keep,enabled:!!E&&!j,params:e,maxRows:340});let eO=()=>[...el?[el]:[],...Z.filter(e=>!e.leaving),...K.flatMap(e=>e.items),...Y.map(e=>e.p),...$],eG=()=>eO().filter(e=>!e.test).map(M),eB=()=>({keep:q.keep,mi:q.mi,totalCoins:ei});function I(e){let t=e=>{e.size=U(e.d);let t=eE(e.size);eT(e,t.tx,t.ty,t.side);for(let e=0;e<3;e++)k(g)};for(let l of e.slice(0,340)){if(!l||"object"!=typeof l)continue;let e={d:Math.max(0,Number(l&&(void 0!==l.c?l.c:l.d))||0),url:l&&"string"==typeof l.url?l.url:"",name:String(l&&l.n||"").slice(0,40),zone:l&&"k"===l.z?"crown":l&&"c"===l.z?"cloud":"pile",side:l&&0>Number(l.s)?-1:1},i=eC(e.d,(0,o.wh)(e.url)||"",e.name),n=b(i.d,q.bt);if("crown"===n&&(!el||el.d<i.d))el&&t(el),i.zone="crown",i.size=U(i.d),i.x=c.x+c.rx+6,i.y=c.y-.42*i.size,el=i;else if("cloud"===n){let e=m.map(e=>K[e]).find(e=>e.items.length<4);e?(i.zone="cloud",e.items.push(i),e.vis=1,e.want=!0):t(i)}else t(i)}n();for(let e=0;e<240;e++)k(g)}let eW=e=>{for(let e of($=[],Y=[],Q=[],K))e.items=[],e.incoming=0;for(let e of Z)e.leaving=!0,e.vx=(e.x<400?-1:1)*300,e.vy=-120,e.sleep=0;el&&(el.zone="pile",el.side=1,el.r=.5*el.size+2,Z.push(Object.assign(el,{leaving:!0,vx:300,vy:-200,alpha:1,sq:0,rot:0,sleep:0})),el=null),ei=0,en=-1,eb=0,eM.length=0,e&&R.clear()},eH=0,eU=performance.now(),eJ=0,eK=0,eV=e=>{if(!d.current)return;eH=requestAnimationFrame(eV);let t=Math.min(.12,Math.max(0,(e-eU)/1e3));eU=e,eJ+=t,eK+=t;let l=0;for(;eJ>=g&&l<4;)u(g),eJ-=g,l++;if(4===l&&(eJ=0),eK<1/q.fpsCap-.002)return;let i=eK;eK=0,A(),ev.n++,ev.t+=i,ev.t>=.5&&(ev.fps=Math.round(ev.n/ev.t),ev.n=0,ev.t=0)},eX=()=>({clouds:K.map(e=>e.items.length),cloudsVisible:K.filter(e=>e.vis>.01).length,pileL:Z.filter(e=>e.side<0&&!e.leaving).length,pileR:Z.filter(e=>e.side>
10&&!e.leaving).length,leaving:Z.filter(e=>e.leaving).length,crown:el?el.d:0,queue:$.length,flying:Y.length,rain:Q.length,totalCoins:ei,spawned:ed,evicted:eb,quiet:+(ea-eo).toFixed(1),gag:ex,fps:ev.fps,drawMs:+ev.drawMs.toFixed(2),imgs:B.size,bakes:W.size});t.current={trim:n,spawn:eN,read:eX,setKnob:(e,t)=>N({[e]:t}),setKeep:e=>{q.keep=e,R.setKeep(e)},reset:()=>eW(!0)},window.__gvFrame=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1;for(let t=0;t<e;t++)u(g);return A(),eX()},("1"===e.get("dbg")||"1"===e.get("sim")||"1"===e.get("tune"))&&(window.__gvDbg=()=>({...eX(),pieces:eO().map(e=>({d:e.d,zone:e.zone,side:e.side,x:void 0===e.x?null:+e.x.toFixed(1),y:void 0===e.y?null:+e.y.toFixed(1),r:void 0===e.r?null:+e.r.toFixed(1)})),leavingD:Z.filter(e=>e.leaving).map(e=>e.d),evictLog:eM.slice(),caps:eS(),cfg:{...q,tierR:q.tierR.slice()},stored:(0,s.s2)(eL)}),window.__gvSim={gift:function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"Rose",l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"";return eN(e,i||(0,r.i9)(t)||"",t,l)},like:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:15;ec+=e},follow:()=>eD(),quiet:e=>{eo=ea-e,ey=Math.max(60,60*Math.floor(e/60)+60)},gag:e=>F(e),reset:()=>eW(!0),style:e=>N(e),flush:()=>{R.touch(),R.flush(eG,eB())},snap:()=>(0,s.s2)(eL),restore:e=>{for(let e of(Z=[],el=null,K))e.items=[],e.incoming=0;I(e||[])}}),N((0,a.w4)(e,"giftvolcano")),G&&G.observe(i),O(),eH=requestAnimationFrame(eV),"1"===e.get("tune")&&T(!0);let eZ=null;("1"===e.get("tune")||"1"===e.get("dbg"))&&(eZ=setInterval(()=>{t.current&&D(t.current.read())},300));let eY=null,e$=null,eQ=!1,e0=(e,t)=>{let[l,i]=P[e%P.length];eN(i,(0,r.i9)(l)||"",l,1,{test:t})};if(E){j&&(0,r.CG)().catch(()=>{}).then(()=>{if(!eQ)for(let e=0;e<10;e++)e0(e,!0)});let t=(0,s.s2)(eL);q.keep=(0,s.am)(e,t,"keep",q.keep,0,240),R.setKeep(q.keep);let l=R.load();l&&(I(l.rows||[]),(ei=Math.max(ei,Number(l.totalCoins)||0))>=3e3&&(en=2)),(async()=>{try{let l=/^(\d{4,8}|[A-HJ-NP-Z2-9]{8})$/.test(E)?"cid=".concat(encodeURIComponent(E)):"wt=".concat(encodeURIComponent(E)),i=await fetch("".concat("https://api.ttsam.app","/api/widget-styles?").concat(l));if(i.ok){var t;let l=await i.json();N((0,a.JA)((null==l||null==(t=l.styles)?void 0:t.giftvolcano)||{},"giftvolcano")),N((0,a.ZU)(e,"giftvolcano"))}}catch(e){}eQ||(e$=(0,r.IV)(E,{gift:e=>{let t=(0,o.go)(e);if(!t||e.isStreakable&&!e.isRepeatEnd)return;let l=Math.max(0,Number(t.diamondCount)||0),i=v(Number(t.repeatCount)||1,1,99),n=(0,o.wh)(t.giftPictureUrl||t.giftImageUrl)||(0,o.wh)((0,r.i9)(t.giftName))||"";eN(l,n,t.giftName,i)},like:e=>{ec+=v(Number(null==e?void 0:e.likeCount)||1,1,500)},follow:()=>eD(),share:()=>eD(),leaderboard_reset:()=>eW(!0),style_update:e=>{(null==e?void 0:e.widgetId)==="giftvolcano"&&e.style&&N((0,a.JA)(e.style,"giftvolcano"))}}))})()}else(0,r.CG)().catch(()=>{}).then(()=>{if(eQ)return;for(let e=0;e<10;e++)e0(e,!0);let t=10;"1"!==e.get("sim")&&(eY=setInterval(()=>e0(t++,!0),1600))});return R.start(eG,eB),()=>{eQ=!0,d.current=!1,cancelAnimationFrame(eH),G&&G.disconnect(),eZ&&clearInterval(eZ),eY&&clearInterval(eY),e$&&e$.disconnect(),R.stop(),R.flush(eG,eB()),delete window.__gvFrame,delete window.__gvDbg,delete window.__gvSim,t.current=null}}catch(e){window.__gvBootError=e&&e.stack||String(e),console.error("[giftvolcano] boot failed",e);return}},[]);let L=function(e,l){let i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;t.current&&t.current.spawn(e,(0,r.i9)(l)||"",l,i,{test:!0})},O=e=>({background:e,color:"#e8e8ee",border:"none",borderRadius:7,padding:"4px 9px",font:"600 12px system-ui",cursor:"pointer"});return(0,i.jsxs)(i.Fragment,{children:[k&&A[j]&&(0,i.jsx)("div",{style:{position:"fixed",inset:0,zIndex:0,background:A[j]}}),(0,i.jsx)("div",{style:{position:"fixed",inset:0,margin:0,background:u.bg,borderRadius:u.br,overflow:"hidden",display:"flex",alignItems:"center",justifyContent:"center",zIndex:1},children:(0,i.jsx)("canvas",{ref:e,style:{width:"min(100vw, ".concat(183.33333333333334,"vh)"),height:"min(100vh, ".concat(54.54545454545455,"vw)"),display:"block",background:"transparent"}})}),k&&(0,i.jsxs)("div",{style:{position:"fixed",top:8,right:8,width:300,maxHeight:"calc(100vh - 16px)",zIndex:5,overflowY:"auto",padding:12,background:"rgba(18,16,24,.94)",color:"#e8e8ee",font:'12px/1.5 system-ui, "
1Segoe UI", sans-serif',border:"1px solid #2a3040",borderRadius:8},children:[(0,i.jsx)("b",{style:{fontSize:13},children:"หà¸à¹à¸²à¸à¸£à¸±à¸à¸à¸¹à¸ ภูà¹à¸à¸²à¹à¸"}),_&&(0,i.jsxs)("div",{style:{fontSize:11,margin:"6px 0",background:"#0e0c14",borderRadius:6,padding:"6px 8px"},children:["à¹à¸¡à¸ ",_.clouds.join("/")," \xb7 à¸à¸à¸ ",_.pileL,"/",_.pileR," \xb7 มà¸à¸à¸¸à¸ ",_.crown||"-"," \xb7 à¸à¸´à¸§ ",_.queue," \xb7 à¸à¸ ",_.rain," \xb7 fps ",_.fps," \xb7 วาภ",_.drawMs," ms"]}),(0,i.jsxs)("div",{style:{display:"flex",flexWrap:"wrap",gap:4,margin:"6px 0"},children:[(0,i.jsx)("button",{type:"button",style:O("#3a2f45"),onClick:()=>L(1,"Rose"),children:"\uD83C\uDF39 1\uD83D\uDC8E"}),(0,i.jsx)("button",{type:"button",style:O("#3a2f45"),onClick:()=>L(1,"Rose",10),children:"à¸à¸à¸¡à¹à¸ \xd710"}),(0,i.jsx)("button",{type:"button",style:O("#3a2f45"),onClick:()=>L(299,"Corgi"),children:"299\uD83D\uDC8E"}),(0,i.jsx)("button",{type:"button",style:O("#4a2a26"),onClick:()=>L(7e3,"Sports Car"),children:"7000\uD83D\uDC8E"})]}),F.map(e=>(0,i.jsxs)("label",{style:{display:"block",margin:"6px 0"},children:[e.L," ",(0,i.jsx)("b",{children:I[e.k]}),(0,i.jsx)("input",{type:"range",min:e.r[0],max:e.r[1],step:e.r[2],value:I[e.k],onChange:l=>{var i,n;return i=e.k,n=Number(l.target.value),void(E(e=>({...e,[i]:n})),t.current&&("keep"===i?t.current.setKeep(n):t.current.setKnob(i,n)))},style:{width:"100%"}})]},e.k)),(0,i.jsx)("div",{style:{display:"flex",flexWrap:"wrap",gap:4,margin:"6px 0"},children:Object.keys(A).map(e=>(0,i.jsx)("button",{type:"button",style:O(j===e?"#5b3d6e":"#2c2432"),onClick:()=>R(e),children:e},e))}),(0,i.jsx)("button",{type:"button",style:O("#2f5d3a"),onClick:()=>{let e=F.filter(e=>I[e.k]!==e.d).map(e=>"".concat(e.k,"=").concat(I[e.k]));N(e.length?e.join("&"):"(à¸à¸¸à¸à¸à¹à¸²à¹à¸à¹à¸ default â à¹à¸¡à¹à¸¡à¸µ param à¹à¸«à¹à¸à¹à¸à¸)"),e.length&&navigator.clipboard&&navigator.clipboard.writeText(e.join("&")).catch(()=>{})},children:"à¸à¸±à¸à¸¥à¸à¸ params"}),q&&(0,i.jsx)("div",{style:{marginTop:6,wordBreak:"break-all",color:"#b8f0c4"},children:q})]})]})}let I={unstable_runtimeJS:!0}},58036:(e,t,l)=>{"use strict";function i(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:window.localStorage;try{let l=t.getItem(e);if(!l)return null;let i=JSON.parse(l);if(!i||"object"!=typeof i||1!==i.v)return null;return i}catch(e){return null}}function n(e,t,l,i,n,r){if(e&&e.has(l))return i;let a=null==t?void 0:t[l];if(null==a||""===a)return i;let o=Number(a);return Number.isFinite(o)?Math.max(n,Math.min(r,o)):i}function r(e){let{key:t,keepMinutes:l,enabled:i,params:n,maxRows:r=200,now:a=Date.now,storage:o=window.localStorage}=e||{},s=Number(l)||0,d=0,u=!1,c=null,f=null,h=()=>{if(i){try{o.removeItem(t)}catch(e){}u=!1}},p=(e,l)=>{if(i){if(s<=0)return void h();try{o.setItem(t,JSON.stringify({v:1,lastGiftAt:d,rows:function(e,t){if(!Array.isArray(e))return[];if(e.length<=t)return e.slice();let l=new Set(e.map((e,t)=>[t,Number(e&&e.c)||0]).sort((e,t)=>t[1]-e[1]).slice(0,t).map(e=>{let[t]=e;return t}));return e.filter((e,t)=>l.has(t))}(e(),r),...l}))}catch(e){}}},g=(e,t)=>{u&&(u=!1,p(e,t))};return{touch:e=>{i&&(d=void 0===e?a():e,u=!0)},save:p,flush:g,load:()=>{if(!i)return null;if(n&&"1"===n.get("fresh")||s<=0)return h(),null;try{let e=o.getItem(t);if(!e)return null;let l=JSON.parse(e);if(!l||"object"!=typeof l||1!==l.v)return h(),null;let i=function(e,t,l){let i=Number(t)||0;if(i<=0||!e||"object"!=typeof e)return null;let n=Number(e.lastGiftAt)||0;return!n||n>l||l-n>6e4*i?null:Array.isArray(e.rows)?e.rows:null}(l,s,a());if(!i)return h(),null;d=Number(l.lastGiftAt)||0;let{v:n,rows:r,lastGiftAt:u,...c}=l;return{rows:i,lastGiftAt:d,...c}}catch(e){return h(),null}},clear:h,start:(e,t)=>{if(!i||c)return;let l=()=>g(e,t?t():void 0);c=setInterval(l,5e3),f=l;try{window.addEventListener("pagehide",l)}catch(e){}},stop:()=>{if(c&&(clearInterval(c),c=null),f){try{window.removeEventListener("pagehide",f)}catch(e){}f=null}},setKeep:e=>{let t=Number(e);(s=Number.isFinite(t)?Math.max(0,Math.min(240,t)):0)<=0&&h()},get lastGiftAt(){return d},get keep(){return s}}}l.d(t,{am:()=>n,dO:()=>r,s2:()=>i})},90680:(e,t,l)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/widget/giftvolcano",function(){return l(4686)}])}},e=>{e.O(0,[9964,4879,636,6593,8792],()=>
1e(e.s=90680)),_N_E=e.O()}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.