diff --git a/assets/index.32e0a20e.js b/assets/index.32e0a20e.js deleted file mode 100644 index 13117f0..0000000 --- a/assets/index.32e0a20e.js +++ /dev/null @@ -1,15 +0,0 @@ -/* empty css */import"./vue.92681fcb.js";import{Z as S,l as be,u as vn,q as nn,C as r,b1 as ze,aa as L,aE as _,a0 as M,a1 as m,aK as Je,G as ce,t as T,aC as si,w as Le,b2 as Fe,a8 as u,O as D,ao as ji,I as me,ay as yn,ar as Mt,aG as on,A as we,_ as j,b6 as R,b8 as Tn,bs as zi,aq as It,bu as Xt,bb as bn,T as Wi,a7 as v,j as Qi,bv as Jn,J as H,$,aH as nt,aF as it,al as fn,aL as pt,aN as ke,z as tt,H as Ki,aJ as ai,bn as Ji,br as Xi,be as Zi}from"./@vue.4ce677c2.js";import{i as Yi}from"./is-plain-object.906d88e8.js";import{c as li}from"./nanoevents.1080beb7.js";import{L as mt}from"./lz-string.731cedc5.js";import{Y as es}from"./vue-next-select.a2bfab1d.js";import{s as ts,u as ri}from"./vue-toastification.6f567382.js";import{D as ns}from"./vuedraggable.7949458c.js";import{p as is}from"./vue-textarea-autosize.35804eaf.js";import{v as ss,n as as}from"./workbox-window.8d14e8b7.js";import"./sortablejs.29100d8a.js";const ls=function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const s of document.querySelectorAll('link[rel="modulepreload"]'))i(s);new MutationObserver(s=>{for(const l of s)if(l.type==="childList")for(const o of l.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&i(o)}).observe(document,{childList:!0,subtree:!0});function n(s){const l={};return s.integrity&&(l.integrity=s.integrity),s.referrerpolicy&&(l.referrerPolicy=s.referrerpolicy),s.crossorigin==="use-credentials"?l.credentials="include":s.crossorigin==="anonymous"?l.credentials="omit":l.credentials="same-origin",l}function i(s){if(s.ep)return;s.ep=!0;const l=n(s);fetch(s.href,l)}};ls();const rs="modulepreload",Xn={},os="./",mn=function(t,n){return!n||n.length===0?t():Promise.all(n.map(i=>{if(i=`${os}${i}`,i in Xn)return;Xn[i]=!0;const s=i.endsWith(".css"),l=s?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${i}"]${l}`))return;const o=document.createElement("link");if(o.rel=s?"stylesheet":rs,s||(o.as="script",o.crossOrigin=""),o.href=i,document.head.appendChild(o),s)return new Promise((c,f)=>{o.addEventListener("load",c),o.addEventListener("error",()=>f(new Error(`Unable to preload CSS for ${i}`)))})})).then(()=>t())},us="./projInfo-schema.json",cs="Advent Incremental",ds="An incremental game you play a day at a time, leading up to Christmas!",fs="advent-incremental",ms="thepaperpilot",hs="",ps="",gs="0.3",vs="Initial Commit",ys=!0,bs=!1,_s=2,ws=!0,Ns=null,ks="",Cs=["main"],Ss=3600,Ms=0,Is=!0,As="base64";var W={$schema:us,title:cs,description:ds,id:fs,author:ms,discordName:hs,discordLink:ps,versionNumber:gs,versionTitle:vs,allowGoBack:ys,defaultShowSmall:bs,defaultDecimalsShown:_s,useHeader:ws,banner:Ns,logo:ks,initialTabs:Cs,maxTickLength:Ss,offlineLimit:Ms,enablePausing:Is,exportEncoding:As};const En=17,Es=9e15,Ps=Math.log10(9e15),$s=1/9e15,Ts=308,xs=-324,Zn=5,Fs=function(){const e=[];for(let n=xs+1;n<=Ts;n++)e.push(Number("1e"+n));const t=323;return function(n){return e[n+t]}}(),Nt=[2,Math.E,3,4,5,6,7,8,9,10],Bs=[[1,1.0891168053867777,1.1789745164521264,1.2701428397304229,1.3632066654400328,1.4587804913784246,1.557523817412741,1.660158301473385,1.767487542936873,1.8804205225512542,2],[1,1.1121114330934,1.23103892493161,1.35838369631113,1.49605193039935,1.64635423375119,1.81213853570186,1.99697132461829,2.20538955455724,2.44325744833852,Math.E],[1,1.1187738849693603,1.2464963939368214,1.38527004705667,1.5376664685821402,1.7068895236551784,1.897001227148399,2.1132403089001035,2.362480153784171,2.6539010333870774,3],[1,1.1367350847096405,1.2889510672956703,1.4606478703324786,1.6570295196661111,1.8850062585672889,2.1539465047453485,2.476829779693097,2.872061932789197,3.3664204535587183,4],[1,1.1494592900767588,1.319708228183931,1.5166291280087583,1.748171114438024,2.0253263297298045,2.3636668498288547,2.7858359149579424,3.3257226212448145,4.035730287722532,5],[1,1.159225940787673,1.343712473580932,1.5611293155111927,1.8221199554561318,2.14183924486326,2.542468319282638,3.0574682501653316,3.7390572020926873,4.6719550537360774,6],[1,1.1670905356972596,1.3632807444991446,1.5979222279405536,1.8842640123816674,2.2416069644878687,2.69893426559423,3.3012632110403577,4.121250340630164,5.281493033448316,7],[1,1.1736630594087796,1.379783782386201,1.6292821855668218,1.9378971836180754,2.3289975651071977,2.8384347394720835,3.5232708454565906,4.478242031114584,5.868592169644505,8],[1,1.1793017514670474,1.394054150657457,1.65664127441059,1.985170999970283,2.4069682290577457,2.9647310119960752,3.7278665320924946,4.814462547283592,6.436522247411611,9],[1,1.18422737399915,1.4066113788546144,1.680911177655277,2.027492094355525,2.4775152854601967,3.080455730250329,3.918234505962507,5.1332705696484595,6.9878696918072905,10]],Ds=[[-1,-.9194161097107025,-.8335625019330468,-.7425599821143978,-.6466611521029437,-.5462617907227869,-.4419033816638769,-.3342645487554494,-.224140440909962,-.11241087890006762,0],[-1,-.90603157029014,-.80786507256596,-.7064666939634,-.60294836853664,-.49849837513117,-.39430303318768,-.29147201034755,-.19097820800866,-.09361896280296,0],[-1,-.9021579584316141,-.8005762598234203,-.6964780623319391,-.5911906810998454,-.486050182576545,-.3823089430815083,-.28106046722897615,-.1831906535795894,-.08935809204418144,0],[-1,-.8917227442365535,-.781258746326964,-.6705130326902455,-.5612813129406509,-.4551067709033134,-.35319256652135966,-.2563741554088552,-.1651412821106526,-.0796919581982668,0],[-1,-.8843387974366064,-.7678744063886243,-.6529563724510552,-.5415870994657841,-.4352842206588936,-.33504449124791424,-.24138853420685147,-.15445285440944467,-.07409659641336663,0],[-1,-.8786709358426346,-.7577735191184886,-.6399546189952064,-.527284921869926,-.4211627631006314,-.3223479611761232,-.23107655627789858,-.1472057700818259,-.07035171210706326,0],[-1,-.8740862815291583,-.7497032990976209,-.6297119746181752,-.5161838335958787,-.41036238255751956,-.31277212146489963,-.2233976621705518,-.1418697367979619,-.06762117662323441,0],[-1,-.8702632331800649,-.7430366914122081,-.6213373075161548,-.5072025698095242,-.40171437727184167,-.30517930701410456,-.21736343968190863,-.137710238299109,-.06550774483471955,0],[-1,-.8670016295947213,-.7373984232432306,-.6143173985094293,-.49973884395492807,-.394584953527678,-.2989649949848695,-.21245647317021688,-.13434688362382652,-.0638072667348083,0],[-1,-.8641642839543857,-.732534623168535,-.6083127477059322,-.4934049257184696,-.3885773075899922,-.29376029055315767,-.2083678561173622,-.13155653399373268,-.062401588652553186,0]],h=function(t){return a.fromValue_noAlloc(t)},q=function(e,t,n){return a.fromComponents(e,t,n)},U=function(t,n,i){return a.fromComponents_noNormalize(t,n,i)},dt=function(t,n){const i=n+1,s=Math.ceil(Math.log10(Math.abs(t))),l=Math.round(t*Math.pow(10,i-s))*Math.pow(10,s-i);return parseFloat(l.toFixed(Math.max(i-s,0)))},Pn=function(e){return Math.sign(e)*Math.log10(Math.abs(e))},Os=function(e){if(!isFinite(e))return e;if(e<-50)return e===Math.trunc(e)?Number.NEGATIVE_INFINITY:0;let t=1;for(;e<10;)t=t*e,++e;e-=1;let n=.9189385332046727;n=n+(e+.5)*Math.log(e),n=n-e;const i=e*e;let s=e;return n=n+1/(12*s),s=s*i,n=n+1/(360*s),s=s*i,n=n+1/(1260*s),s=s*i,n=n+1/(1680*s),s=s*i,n=n+1/(1188*s),s=s*i,n=n+691/(360360*s),s=s*i,n=n+7/(1092*s),s=s*i,n=n+3617/(122400*s),Math.exp(n)/t},oi=.5671432904097838,Yn=function(e,t=1e-10){let n,i;if(!Number.isFinite(e)||e===0)return e;if(e===1)return oi;e<10?n=0:n=Math.log(e)-Math.log(Math.log(e));for(let s=0;s<100;++s){if(i=(e*Math.exp(-n)+n*n)/(n+1),Math.abs(i-n).5?1:-1;if(Math.random()*20<1)return U(t,0,1);const n=Math.floor(Math.random()*(e+1));let i=n===0?Math.random()*616-308:Math.random()*16;Math.random()>.9&&(i=Math.trunc(i));let s=Math.pow(10,i);return Math.random()>.9&&(s=Math.trunc(s)),q(t,n,s)}static affordGeometricSeries_core(e,t,n,i){const s=t.mul(n.pow(i));return w.floor(e.div(s).mul(n.sub(1)).add(1).log10().div(n.log10()))}static sumGeometricSeries_core(e,t,n,i){return t.mul(n.pow(i)).mul(w.sub(1,n.pow(e))).div(w.sub(1,n))}static affordArithmeticSeries_core(e,t,n,i){const l=t.add(i.mul(n)).sub(n.div(2)),o=l.pow(2);return l.neg().add(o.add(n.mul(e).mul(2)).sqrt()).div(n).floor()}static sumArithmeticSeries_core(e,t,n,i){const s=t.add(i.mul(n));return e.div(2).mul(s.mul(2).plus(e.sub(1).mul(n)))}static efficiencyOfPurchase_core(e,t,n){return e.div(t).add(e.div(n))}normalize(){if(this.sign===0||this.mag===0&&this.layer===0)return this.sign=0,this.mag=0,this.layer=0,this;if(this.layer===0&&this.mag<0&&(this.mag=-this.mag,this.sign=-this.sign),this.layer===0&&this.mag<$s)return this.layer+=1,this.mag=Math.log10(this.mag),this;let e=Math.abs(this.mag),t=Math.sign(this.mag);if(e>=Es)return this.layer+=1,this.mag=t*Math.log10(e),this;for(;e0;)this.layer-=1,this.layer===0?this.mag=Math.pow(10,this.mag):(this.mag=t*Math.pow(10,e),e=Math.abs(this.mag),t=Math.sign(this.mag));return this.layer===0&&(this.mag<0?(this.mag=-this.mag,this.sign=-this.sign):this.mag===0&&(this.sign=0)),this}fromComponents(e,t,n){return this.sign=e,this.layer=t,this.mag=n,this.normalize(),this}fromComponents_noNormalize(e,t,n){return this.sign=e,this.layer=t,this.mag=n,this}fromMantissaExponent(e,t){return this.layer=1,this.sign=Math.sign(e),e=Math.abs(e),this.mag=t+Math.log10(e),this.normalize(),this}fromMantissaExponent_noNormalize(e,t){return this.fromMantissaExponent(e,t),this}fromDecimal(e){return this.sign=e.sign,this.layer=e.layer,this.mag=e.mag,this}fromNumber(e){return this.mag=Math.abs(e),this.sign=Math.sign(e),this.layer=0,this.normalize(),this}fromString(e){e=e.replace(",","");const t=e.split("^^^");if(t.length===2){const b=parseFloat(t[0]),p=parseFloat(t[1]),N=t[1].split(";");let C=1;if(N.length===2&&(C=parseFloat(N[1]),isFinite(C)||(C=1)),isFinite(b)&&isFinite(p)){const x=w.pentate(b,p,C);return this.sign=x.sign,this.layer=x.layer,this.mag=x.mag,this}}const n=e.split("^^");if(n.length===2){const b=parseFloat(n[0]),p=parseFloat(n[1]),N=n[1].split(";");let C=1;if(N.length===2&&(C=parseFloat(N[1]),isFinite(C)||(C=1)),isFinite(b)&&isFinite(p)){const x=w.tetrate(b,p,C);return this.sign=x.sign,this.layer=x.layer,this.mag=x.mag,this}}const i=e.split("^");if(i.length===2){const b=parseFloat(i[0]),p=parseFloat(i[1]);if(isFinite(b)&&isFinite(p)){const N=w.pow(b,p);return this.sign=N.sign,this.layer=N.layer,this.mag=N.mag,this}}e=e.trim().toLowerCase();let s,l,o=e.split("pt");if(o.length===2){s=10,l=parseFloat(o[0]),o[1]=o[1].replace("(",""),o[1]=o[1].replace(")","");let b=parseFloat(o[1]);if(isFinite(b)||(b=1),isFinite(s)&&isFinite(l)){const p=w.tetrate(s,l,b);return this.sign=p.sign,this.layer=p.layer,this.mag=p.mag,this}}if(o=e.split("p"),o.length===2){s=10,l=parseFloat(o[0]),o[1]=o[1].replace("(",""),o[1]=o[1].replace(")","");let b=parseFloat(o[1]);if(isFinite(b)||(b=1),isFinite(s)&&isFinite(l)){const p=w.tetrate(s,l,b);return this.sign=p.sign,this.layer=p.layer,this.mag=p.mag,this}}const c=e.split("e"),f=c.length-1;if(f===0){const b=parseFloat(e);if(isFinite(b))return this.fromNumber(b)}else if(f===1){const b=parseFloat(e);if(isFinite(b)&&b!==0)return this.fromNumber(b)}const d=e.split("e^");if(d.length===2){this.sign=1,d[0].charAt(0)=="-"&&(this.sign=-1);let b="";for(let p=0;p=43&&N<=57||N===101)b+=d[1].charAt(p);else return this.layer=parseFloat(b),this.mag=parseFloat(d[1].substr(p+1)),this.normalize(),this}}if(f<1)return this.sign=0,this.layer=0,this.mag=0,this;const g=parseFloat(c[0]);if(g===0)return this.sign=0,this.layer=0,this.mag=0,this;let y=parseFloat(c[c.length-1]);if(f>=2){const b=parseFloat(c[c.length-2]);isFinite(b)&&(y*=Math.sign(b),y+=Pn(b))}if(!isFinite(g))this.sign=c[0]==="-"?-1:1,this.layer=f,this.mag=y;else if(f===1)this.sign=Math.sign(g),this.layer=1,this.mag=y+Math.log10(Math.abs(g));else if(this.sign=Math.sign(g),this.layer=f,f===2){const b=w.mul(q(1,2,y),h(g));return this.sign=b.sign,this.layer=b.layer,this.mag=b.mag,this}else this.mag=y;return this.normalize(),this}fromValue(e){return e instanceof w||e!=null&&typeof e=="object"&&"sign"in e&&"mag"in e&&"layer"in e?this.fromDecimal(e):typeof e=="number"?this.fromNumber(e):typeof e=="string"?this.fromString(e):(this.sign=0,this.layer=0,this.mag=0,this)}toNumber(){return Number.isFinite(this.layer)?this.layer===0?this.sign*this.mag:this.layer===1?this.sign*Math.pow(10,this.mag):this.mag>0?this.sign>0?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:0:Number.NaN}mantissaWithDecimalPlaces(e){return isNaN(this.m)?Number.NaN:this.m===0?0:dt(this.m,e)}magnitudeWithDecimalPlaces(e){return isNaN(this.mag)?Number.NaN:this.mag===0?0:dt(this.mag,e)}toString(){return isNaN(this.layer)||isNaN(this.sign)||isNaN(this.mag)?"NaN":this.mag===Number.POSITIVE_INFINITY||this.layer===Number.POSITIVE_INFINITY?this.sign===1?"Infinity":"-Infinity":this.layer===0?this.mag<1e21&&this.mag>1e-7||this.mag===0?(this.sign*this.mag).toString():this.m+"e"+this.e:this.layer===1?this.m+"e"+this.e:this.layer<=Zn?(this.sign===-1?"-":"")+"e".repeat(this.layer)+this.mag:(this.sign===-1?"-":"")+"(e^"+this.layer+")"+this.mag}toExponential(e){return this.layer===0?(this.sign*this.mag).toExponential(e):this.toStringWithDecimalPlaces(e)}toFixed(e){return this.layer===0?(this.sign*this.mag).toFixed(e):this.toStringWithDecimalPlaces(e)}toPrecision(e){return this.e<=-7?this.toExponential(e-1):e>this.e?this.toFixed(e-this.exponent-1):this.toExponential(e-1)}valueOf(){return this.toString()}toJSON(){return this.toString()}toStringWithDecimalPlaces(e){return this.layer===0?this.mag<1e21&&this.mag>1e-7||this.mag===0?(this.sign*this.mag).toFixed(e):dt(this.m,e)+"e"+dt(this.e,e):this.layer===1?dt(this.m,e)+"e"+dt(this.e,e):this.layer<=Zn?(this.sign===-1?"-":"")+"e".repeat(this.layer)+dt(this.mag,e):(this.sign===-1?"-":"")+"(e^"+this.layer+")"+dt(this.mag,e)}abs(){return U(this.sign===0?0:1,this.layer,this.mag)}neg(){return U(-this.sign,this.layer,this.mag)}negate(){return this.neg()}negated(){return this.neg()}sgn(){return this.sign}round(){return this.mag<0?w.dZero:this.layer===0?q(this.sign,0,Math.round(this.mag)):this}floor(){return this.mag<0?w.dZero:this.layer===0?q(this.sign,0,Math.floor(this.mag)):this}ceil(){return this.mag<0?w.dZero:this.layer===0?q(this.sign,0,Math.ceil(this.mag)):this}trunc(){return this.mag<0?w.dZero:this.layer===0?q(this.sign,0,Math.trunc(this.mag)):this}add(e){const t=h(e);if(!Number.isFinite(this.layer))return this;if(!Number.isFinite(t.layer)||this.sign===0)return t;if(t.sign===0)return this;if(this.sign===-t.sign&&this.layer===t.layer&&this.mag===t.mag)return U(0,0,0);let n,i;if(this.layer>=2||t.layer>=2)return this.maxabs(t);if(w.cmpabs(this,t)>0?(n=this,i=t):(n=t,i=this),n.layer===0&&i.layer===0)return h(n.sign*n.mag+i.sign*i.mag);const s=n.layer*Math.sign(n.mag),l=i.layer*Math.sign(i.mag);if(s-l>=2)return n;if(s===0&&l===-1){if(Math.abs(i.mag-Math.log10(n.mag))>En)return n;{const o=Math.pow(10,Math.log10(n.mag)-i.mag),c=i.sign+n.sign*o;return q(Math.sign(c),1,i.mag+Math.log10(Math.abs(c)))}}if(s===1&&l===0){if(Math.abs(n.mag-Math.log10(i.mag))>En)return n;{const o=Math.pow(10,n.mag-Math.log10(i.mag)),c=i.sign+n.sign*o;return q(Math.sign(c),1,Math.log10(i.mag)+Math.log10(Math.abs(c)))}}if(Math.abs(n.mag-i.mag)>En)return n;{const o=Math.pow(10,n.mag-i.mag),c=i.sign+n.sign*o;return q(Math.sign(c),1,i.mag+Math.log10(Math.abs(c)))}}plus(e){return this.add(e)}sub(e){return this.add(h(e).neg())}subtract(e){return this.sub(e)}minus(e){return this.sub(e)}mul(e){const t=h(e);if(!Number.isFinite(this.layer))return this;if(!Number.isFinite(t.layer))return t;if(this.sign===0||t.sign===0)return U(0,0,0);if(this.layer===t.layer&&this.mag===-t.mag)return U(this.sign*t.sign,0,1);let n,i;if(this.layer>t.layer||this.layer==t.layer&&Math.abs(this.mag)>Math.abs(t.mag)?(n=this,i=t):(n=t,i=this),n.layer===0&&i.layer===0)return h(n.sign*i.sign*n.mag*i.mag);if(n.layer>=3||n.layer-i.layer>=2)return q(n.sign*i.sign,n.layer,n.mag);if(n.layer===1&&i.layer===0)return q(n.sign*i.sign,1,n.mag+Math.log10(i.mag));if(n.layer===1&&i.layer===1)return q(n.sign*i.sign,1,n.mag+i.mag);if(n.layer===2&&i.layer===1){const s=q(Math.sign(n.mag),n.layer-1,Math.abs(n.mag)).add(q(Math.sign(i.mag),i.layer-1,Math.abs(i.mag)));return q(n.sign*i.sign,s.layer+1,s.sign*s.mag)}if(n.layer===2&&i.layer===2){const s=q(Math.sign(n.mag),n.layer-1,Math.abs(n.mag)).add(q(Math.sign(i.mag),i.layer-1,Math.abs(i.mag)));return q(n.sign*i.sign,s.layer+1,s.sign*s.mag)}throw Error("Bad arguments to mul: "+this+", "+e)}multiply(e){return this.mul(e)}times(e){return this.mul(e)}div(e){const t=h(e);return this.mul(t.recip())}divide(e){return this.div(e)}divideBy(e){return this.div(e)}dividedBy(e){return this.div(e)}recip(){return this.mag===0?w.dNaN:this.layer===0?q(this.sign,0,1/this.mag):q(this.sign,this.layer,-this.mag)}reciprocal(){return this.recip()}reciprocate(){return this.recip()}cmp(e){const t=h(e);return this.sign>t.sign?1:this.sign0?this.layer:-this.layer,i=t.mag>0?t.layer:-t.layer;return n>i?1:nt.mag?1:this.mag0?t:this}clamp(e,t){return this.max(e).min(t)}clampMin(e){return this.max(e)}clampMax(e){return this.min(e)}cmp_tolerance(e,t){const n=h(e);return this.eq_tolerance(n,t)?0:this.cmp(n)}compare_tolerance(e,t){return this.cmp_tolerance(e,t)}eq_tolerance(e,t){const n=h(e);if(t==null&&(t=1e-7),this.sign!==n.sign||Math.abs(this.layer-n.layer)>1)return!1;let i=this.mag,s=n.mag;return this.layer>n.layer&&(s=Pn(s)),this.layer0?q(Math.sign(this.mag),this.layer-1,Math.abs(this.mag)):q(1,0,Math.log10(this.mag))}log10(){return this.sign<=0?w.dNaN:this.layer>0?q(Math.sign(this.mag),this.layer-1,Math.abs(this.mag)):q(this.sign,0,Math.log10(this.mag))}log(e){return e=h(e),this.sign<=0||e.sign<=0||e.sign===1&&e.layer===0&&e.mag===1?w.dNaN:this.layer===0&&e.layer===0?q(this.sign,0,Math.log(this.mag)/Math.log(e.mag)):w.div(this.log10(),e.log10())}log2(){return this.sign<=0?w.dNaN:this.layer===0?q(this.sign,0,Math.log2(this.mag)):this.layer===1?q(Math.sign(this.mag),0,Math.abs(this.mag)*3.321928094887362):this.layer===2?q(Math.sign(this.mag),1,Math.abs(this.mag)+.5213902276543247):q(Math.sign(this.mag),this.layer-1,Math.abs(this.mag))}ln(){return this.sign<=0?w.dNaN:this.layer===0?q(this.sign,0,Math.log(this.mag)):this.layer===1?q(Math.sign(this.mag),0,Math.abs(this.mag)*2.302585092994046):this.layer===2?q(Math.sign(this.mag),1,Math.abs(this.mag)+.36221568869946325):q(Math.sign(this.mag),this.layer-1,Math.abs(this.mag))}logarithm(e){return this.log(e)}pow(e){const t=h(e),n=this,i=t;if(n.sign===0)return i.eq(0)?U(1,0,1):n;if(n.sign===1&&n.layer===0&&n.mag===1)return n;if(i.sign===0)return U(1,0,1);if(i.sign===1&&i.layer===0&&i.mag===1)return n;const s=n.absLog10().mul(i).pow10();return this.sign===-1?Math.abs(i.toNumber()%2)%2===1?s.neg():Math.abs(i.toNumber()%2)%2===0?s:w.dNaN:s}pow10(){if(!Number.isFinite(this.layer)||!Number.isFinite(this.mag))return w.dNaN;let e=this;if(e.layer===0){const t=Math.pow(10,e.sign*e.mag);if(Number.isFinite(t)&&Math.abs(t)>=.1)return q(1,0,t);if(e.sign===0)return w.dOne;e=U(e.sign,e.layer+1,Math.log10(e.mag))}return e.sign>0&&e.mag>=0?q(e.sign,e.layer+1,e.mag):e.sign<0&&e.mag>=0?q(-e.sign,e.layer+1,-e.mag):w.dOne}pow_base(e){return h(e).pow(this)}root(e){const t=h(e);return this.pow(t.recip())}factorial(){return this.mag<0?this.add(1).gamma():this.layer===0?this.add(1).gamma():this.layer===1?w.exp(w.mul(this,w.ln(this).sub(1))):w.exp(this)}gamma(){if(this.mag<0)return this.recip();if(this.layer===0){if(this.lt(U(1,0,24)))return h(Os(this.sign*this.mag));const e=this.mag-1;let t=.9189385332046727;t=t+(e+.5)*Math.log(e),t=t-e;const n=e*e;let i=e,s=12*i,l=1/s,o=t+l;if(o===t||(t=o,i=i*n,s=360*i,l=1/s,o=t-l,o===t))return w.exp(t);t=o,i=i*n,s=1260*i;let c=1/s;return t=t+c,i=i*n,s=1680*i,c=1/s,t=t-c,w.exp(t)}else return this.layer===1?w.exp(w.mul(this,w.ln(this).sub(1))):w.exp(this)}lngamma(){return this.gamma().ln()}exp(){return this.mag<0?w.dOne:this.layer===0&&this.mag<=709.7?h(Math.exp(this.sign*this.mag)):this.layer===0?q(1,1,this.sign*Math.log10(Math.E)*this.mag):this.layer===1?q(1,2,this.sign*(Math.log10(.4342944819032518)+this.mag)):q(1,this.layer+1,this.sign*this.mag)}sqr(){return this.pow(2)}sqrt(){if(this.layer===0)return h(Math.sqrt(this.sign*this.mag));if(this.layer===1)return q(1,2,Math.log10(this.mag)-.3010299956639812);{const e=w.div(U(this.sign,this.layer-1,this.mag),U(1,0,2));return e.layer+=1,e.normalize(),e}}cube(){return this.pow(3)}cbrt(){return this.pow(1/3)}tetrate(e=2,t=U(1,0,1)){if(e===1)return w.pow(this,t);if(e===0)return new w(t);if(this.eq(w.dOne))return w.dOne;if(this.eq(-1))return w.pow(this,t);if(e===Number.POSITIVE_INFINITY){const s=this.toNumber();if(s<=1.444667861009766&&s>=.06598803584531254){if(s>1.444667861009099)return new w(Math.E);const l=w.ln(this).neg();return l.lambertw().div(l)}else return s>1.444667861009766?new w(Number.POSITIVE_INFINITY):w.dNaN}if(this.eq(w.dZero)){let s=Math.abs((e+1)%2);return s>1&&(s=2-s),new w(s)}if(e<0)return w.iteratedlog(t,this,-e);t=h(t);const n=e;e=Math.trunc(e);const i=n-e;if(this.gt(w.dZero)&&this.lte(1.444667861009766)){e=Math.min(1e4,e);for(let s=0;s3)return U(t.sign,t.layer+(e-s-1),t.mag);if(s>1e4)return t}return t}iteratedexp(e=2,t=U(1,0,1)){return this.tetrate(e,t)}iteratedlog(e=10,t=1){if(t<0)return w.tetrate(e,-t,this);e=h(e);let n=h(this);const i=t;t=Math.trunc(t);const s=i-t;if(n.layer-e.layer>3){const l=Math.min(t,n.layer-e.layer-3);t-=l,n.layer-=l}for(let l=0;l1e4)return n}return s>0&&s<1&&(e.eq(10)?n=n.layeradd10(-s):n=n.layeradd(-s,e)),n}slog(e=10){if(e=h(e),e.lte(w.dZero)||e.eq(w.dOne))return w.dNaN;if(e.lt(w.dOne))return this.eq(w.dOne)?w.dZero:this.eq(w.dZero)?w.dNegOne:w.dNaN;if(this.mag<0||this.eq(w.dZero))return w.dNegOne;let t=0,n=h(this);if(n.layer-e.layer>3){const i=n.layer-e.layer-3;t+=i,n.layer-=i}for(let i=0;i<100;++i)if(n.lt(w.dZero))n=w.pow(e,n),t-=1;else{if(n.lte(w.dOne))return h(t+w.slog_critical(e.toNumber(),n.toNumber()));t+=1,n=w.log(n,e)}return h(t)}static slog_critical(e,t){return e>10?t-1:w.critical_section(e,t,Ds)}static tetrate_critical(e,t){return w.critical_section(e,t,Bs)}static critical_section(e,t,n){t*=10,t<0&&(t=0),t>10&&(t=10),e<2&&(e=2),e>10&&(e=10);let i=0,s=0;for(let c=0;ce){const f=(e-Nt[c])/(Nt[c+1]-Nt[c]);i=n[c][Math.floor(t)]*(1-f)+n[c+1][Math.floor(t)]*f,s=n[c][Math.ceil(t)]*(1-f)+n[c+1][Math.ceil(t)]*f;break}const l=t-Math.floor(t);return i*(1-l)+s*l}layeradd10(e){e=w.fromValue_noAlloc(e).toNumber();const t=h(this);if(e>=1){t.mag<0&&t.layer>0?(t.sign=0,t.mag=0,t.layer=0):t.sign===-1&&t.layer==0&&(t.sign=1,t.mag=-t.mag);const n=Math.trunc(e);e-=n,t.layer+=n}if(e<=-1){const n=Math.trunc(e);if(e-=n,t.layer+=n,t.layer<0)for(let i=0;i<100;++i){if(t.layer++,t.mag=Math.log10(t.mag),!isFinite(t.mag))return t.sign===0&&(t.sign=1),t.layer<0&&(t.layer=0),t.normalize();if(t.layer>=0)break}}for(;t.layer<0;)t.layer++,t.mag=Math.log10(t.mag);return t.sign===0&&(t.sign=1,t.mag===0&&t.layer>=1&&(t.layer-=1,t.mag=1)),t.normalize(),e!==0?t.layeradd(e,10):t}layeradd(e,t){const i=this.slog(t).toNumber()+e;return i>=0?w.tetrate(t,i):Number.isFinite(i)?i>=-1?w.log(w.tetrate(t,i+1),t):w.log(w.log(w.tetrate(t,i+2),t),t):w.dNaN}lambertw(){if(this.lt(-.3678794411710499))throw Error("lambertw is unimplemented for results less than -1, sorry!");if(this.mag<0)return h(Yn(this.toNumber()));if(this.layer===0)return h(Yn(this.sign*this.mag));if(this.layer===1)return ei(this);if(this.layer===2)return ei(this);if(this.layer>=3)return U(this.sign,this.layer-1,this.mag);throw"Unhandled behavior in lambertw()"}ssqrt(){if(this.sign==1&&this.layer>=3)return U(this.sign,this.layer-1,this.mag);const e=this.ln();return e.div(e.lambertw())}pentate(e=2,t=U(1,0,1)){t=h(t);const n=e;e=Math.trunc(e);const i=n-e;i!==0&&(t.eq(w.dOne)?(++e,t=new w(i)):this.eq(10)?t=t.layeradd10(i):t=t.layeradd(i,this));for(let s=0;s10)return t}return t}sin(){return this.mag<0?this:this.layer===0?h(Math.sin(this.sign*this.mag)):U(0,0,0)}cos(){return this.mag<0?w.dOne:this.layer===0?h(Math.cos(this.sign*this.mag)):U(0,0,0)}tan(){return this.mag<0?this:this.layer===0?h(Math.tan(this.sign*this.mag)):U(0,0,0)}asin(){return this.mag<0?this:this.layer===0?h(Math.asin(this.sign*this.mag)):U(Number.NaN,Number.NaN,Number.NaN)}acos(){return this.mag<0?h(Math.acos(this.toNumber())):this.layer===0?h(Math.acos(this.sign*this.mag)):U(Number.NaN,Number.NaN,Number.NaN)}atan(){return this.mag<0?this:this.layer===0?h(Math.atan(this.sign*this.mag)):h(Math.atan(this.sign*(1/0)))}sinh(){return this.exp().sub(this.negate().exp()).div(2)}cosh(){return this.exp().add(this.negate().exp()).div(2)}tanh(){return this.sinh().div(this.cosh())}asinh(){return w.ln(this.add(this.sqr().add(1).sqrt()))}acosh(){return w.ln(this.add(this.sqr().sub(1).sqrt()))}atanh(){return this.abs().gte(1)?U(Number.NaN,Number.NaN,Number.NaN):w.ln(this.add(1).div(h(1).sub(this))).div(2)}ascensionPenalty(e){return e===0?this:this.root(w.pow(10,e))}egg(){return this.add(9)}lessThanOrEqualTo(e){return this.cmp(e)<1}lessThan(e){return this.cmp(e)<0}greaterThanOrEqualTo(e){return this.cmp(e)>-1}greaterThan(e){return this.cmp(e)>0}};let a=w;a.dZero=U(0,0,0);a.dOne=U(1,0,1);a.dNegOne=U(-1,0,1);a.dTwo=U(1,0,2);a.dTen=U(1,0,10);a.dNaN=U(Number.NaN,Number.NaN,Number.NaN);a.dInf=U(1,Number.POSITIVE_INFINITY,Number.POSITIVE_INFINITY);a.dNegInf=U(-1,Number.NEGATIVE_INFINITY,Number.NEGATIVE_INFINITY);a.dNumberMax=q(1,0,Number.MAX_VALUE);a.dNumberMin=q(1,0,Number.MIN_VALUE);const Rs=new a(1);function Qt(e,t,n=!0){let i=a.log10(e).floor(),s=a.div(e,a.pow(10,i));s.toStringWithDecimalPlaces(t)==="10"&&(s=Rs,i=i.add(1));const l=i.gte(1e9)?Ge(i,Math.max(Math.max(t,3),W.defaultDecimalsShown)):i.gte(1e4)?hn(i,0):i.toStringWithDecimalPlaces(0);return n?s.toStringWithDecimalPlaces(t)+"e"+l:"e"+l}function hn(e,t){if(e==null)return"NaN";if(e=new a(e),e.mag<.001)return 0 .toFixed(t);const i=e.toStringWithDecimalPlaces(t).split(".");return i[0]=i[0].replace(/(\d)(?=(\d\d\d)+(?!\d))/g,"$1,"),i.length==1?i[0]:i[0]+"."+i[1]}function ui(e,t){return e==null?"NaN":(e=new a(e),e.mag<1e-4?0 .toFixed(t):(e.mag<.1&&t!==0&&(t=Math.max(Math.max(t,e.log10().negate().ceil().toNumber()),W.defaultDecimalsShown)),e.toStringWithDecimalPlaces(t)))}const qs=new a("eeee1000"),Vs=new a("e100000"),ti=new a("e1000"),ci=new a(1e9),Ls=new a(1e6),Gs=new a(1e3),Us=new a(.98),Hs=new a(.001),di=new a(0);function Ge(e,t,n){if(t==null&&(t=W.defaultDecimalsShown),n=n!=null?n:W.defaultShowSmall,e=new a(e),isNaN(e.sign)||isNaN(e.layer)||isNaN(e.mag))return"NaN";if(e.sign<0)return"-"+Ge(e.neg(),t);if(e.mag===Number.POSITIVE_INFINITY)return"Infinity";if(e.gte(qs)){const i=e.slog();return i.gte(Ls)?"F"+Ge(i.floor()):a.pow(10,i.sub(i.floor())).toStringWithDecimalPlaces(3)+"F"+hn(i.floor(),0)}else{if(e.gte(Vs))return Qt(e,0,!1);if(e.gte(ti))return Qt(e,0);if(e.gte(ci))return Qt(e,t);if(e.gte(Gs))return hn(e,0);if(e.gte(Hs)||!n)return ui(e,t);if(e.eq(di))return 0 .toFixed(t)}return e=mi(e),e.lt(ti)?Qt(e,t).replace(/([^(?:e|F)]*)$/,"-$1"):Ge(e,t)+"\u207B\xB9"}function Ve(e){return e=new a(e),e.sign<0?"-"+Ve(e.neg()):e.gte(ci)||e.lte(Us)&&!e.eq(di)?Ge(e):Ge(e,0)}function fi(e){return a.lt(e,0)?"-"+fi(a.neg(e)):a.gt(e,2**51)?Ge(a.div(e,31536e3))+"y":(e=new a(e).toNumber(),e<60?Ge(e)+"s":e<3600?Ve(Math.floor(e/60))+"m "+Ge(e%60)+"s":e<86400?Ve(Math.floor(e/3600))+"h "+Ve(Math.floor(e/60)%60)+"m "+Ve(e%60)+"s":e<31536e3?Ve(Math.floor(e/84600)%365)+"d "+Ve(Math.floor(e/3600)%24)+"h "+Ve(Math.floor(e/60)%60)+"m":Ve(Math.floor(e/31536e3))+"y "+Ve(Math.floor(e/84600)%365)+"d "+Ve(Math.floor(e/3600)%24)+"h")}function js(e,t,n){e=new a(e);let i=e.toStringWithDecimalPlaces(t);return new a(i).gte(n)&&(i=a.sub(n,Math.pow(.1,t)).toStringWithDecimalPlaces(t)),i}function zs(e,t){return Ge(e,t,!0)}function mi(e){let t=a.log10(e).ceil();const n=a.div(e,a.pow(10,t));return t=t.neg(),e=new a(10).pow(t).times(n),e}var Ws=Object.freeze(Object.defineProperty({__proto__:null,default:a,exponentialFormat:Qt,commaFormat:hn,regularFormat:ui,format:Ge,formatWhole:Ve,formatTime:fi,toPlaces:js,formatSmall:zs,invertOOM:mi},Symbol.toStringTag,{value:"Module"}));const{exponentialFormat:Qs,commaFormat:Ks,regularFormat:Js,format:te,formatWhole:G,formatTime:_n,toPlaces:Xs,formatSmall:Zs,invertOOM:Ys}=Ws;window.Decimal=a;window.exponentialFormat=Qs;window.commaFormat=Ks;window.regularFormat=Js;window.format=te;window.formatWhole=G;window.formatTime=_n;window.toPlaces=Xs;window.formatSmall=Zs;window.invertOOM=Ys;function hi(e){let t=e.replace(/([A-Z])/g," $1");return t=t.charAt(0).toUpperCase()+t.slice(1),t}function $n(e){return typeof e=="function"}var J=(e=>(e.Up="Up",e.Down="Down",e.Left="Left",e.Right="Right",e.Default="Up",e))(J||{});const Zt=Symbol("DoNotCache");function E(e,t){const n=e[t];$n(n)&&n.length===0&&!n[Zt]?e[t]=S(n.bind(e)):$n(n)&&(e[t]=n.bind(e),e[t][Zt]=!0)}function Ie(e){return $n(e)&&!e[Zt]&&(e=S(e)),e}const gt=Symbol("Component"),vt=Symbol("GatherProps");let ea=0;function Vt(e="feature-"){return e+ea++}var ye=(e=>(e[e.Visible=0]="Visible",e[e.Hidden=1]="Hidden",e[e.None=2]="None",e))(ye||{});function F(e){return e[Zt]=!0,e}function X(e,t=2){return e?0:t}function _e(e,t,n){e[t]===void 0&&n!=null&&(e[t]=n)}function pi(e,...t){const n=[],i=s=>{Object.keys(s).forEach(l=>{const o=s[l];o&&typeof o=="object"&&(t.includes(o.type)?n.push(o):!(o instanceof a)&&!be(o)&&i(o))})};return i(e),n}const kt={variables:{"--foreground":"#dfdfdf","--background":"#0f0f0f","--feature-foreground":"#0f0f0f","--tooltip-background":"rgba(0, 0, 0, 0.75)","--raised-background":"#0f0f0f","--points":"#ffffff","--locked":"#bf8f8f","--highlighted":"#333","--bought":"#77bf5f","--danger":"rgb(220, 53, 69)","--link":"#02f2f2","--outline":"#dfdfdf","--accent1":"#627a82","--accent2":"#658262","--accent3":"#7c6282","--border-radius":"15px","--modal-border":"solid 2px var(--color)","--feature-margin":"0px"},floatingTabs:!0,mergeAdjacent:!0,showPin:!0};var xn=(e=>(e.Classic="classic",e.Paper="paper",e.Nordic="nordic",e.Aqua="aqua",e))(xn||{}),sn={classic:kt,paper:{...kt,variables:{...kt.variables,"--background":"#2a323d","--feature-foreground":"#000","--raised-background":"#333c4a","--locked":"#3a3e45","--bought":"#5C8A58","--outline":"#333c4a","--border-radius":"4px","--modal-border":"","--feature-margin":"5px"},floatingTabs:!1},nordic:{...kt,variables:{...kt.variables,"--foreground":"#D8DEE9","--background":"#2E3440","--feature-foreground":"#000","--raised-background":"#3B4252","--points":"#E5E9F0","--locked":"#4c566a","--highlighted":"#434c5e","--bought":"#8FBCBB","--danger":"#D08770","--link":"#88C0D0","--outline":"#3B4252","--accent1":"#B48EAD","--accent2":"#A3BE8C","--accent3":"#EBCB8B","--border-radius":"4px","--modal-border":"solid 2px #3B4252","--feature-margin":"5px"},floatingTabs:!1},aqua:{...kt,variables:{...kt.variables,"--foreground":"#bfdfff","--background":"#001f3f","--tooltip-background":"rgba(0, 15, 31, 0.75)","--raised-background":"#001f3f","--points":"#dfefff","--locked":"#c4a7b3","--outline":"#bfdfff"}}};const le=Symbol("ProxyState"),Ft=Symbol("ProxyPath");function Be(e,t={}){const n=t;let i=!1;function s(){return i||(Object.assign(n,e(n)),i=!0),n}return new Proxy(n,{get(l,o){return o===le?s():s()[o]},set(l,o,c){return s()[o]=c,!0},has(l,o){return o===le?!0:Reflect.has(s(),o)},ownKeys(){return Reflect.ownKeys(s())},getOwnPropertyDescriptor(l,o){return i||(Object.assign(n,e(n)),i=!0),Object.getOwnPropertyDescriptor(l,o)}})}var Y=window.state=vn({lastTenTicks:[],hasNaN:!1,NaNPath:[]});const gi=nn({id:"",devSpeed:null,name:"",tabs:[],time:-1,autosave:!0,offlineProd:!0,offlineTime:null,timePlayed:0,keepGoing:!1,modID:"",modVersion:"",layers:{}});function vi(e){return JSON.stringify(e,(t,n)=>r(n))}const yi={get(e,t){var i;if(t===le||t===Ft)return e[t];const n=e[le][t];if(t!=="value"&&(Yi(n)||Array.isArray(n))){if(n!==((i=e[t])==null?void 0:i[le])){const s=[...e[Ft],t];e[t]=new Proxy({[le]:n,[Ft]:s},yi)}return e[t]}return n},set(e,t,n,i){if(!Y.hasNaN&&(typeof n=="number"&&isNaN(n)||n instanceof a&&(isNaN(n.sign)||isNaN(n.layer)||isNaN(n.mag)))){const s=e[le][t];if(!(typeof s=="number"&&isNaN(s)||s instanceof a&&(isNaN(s.sign)||isNaN(s.layer)||isNaN(s.mag))))throw gi.autosave=!1,Y.hasNaN=!0,Y.NaNPath=[...e[Ft],t],Y.NaNReceiver=i,console.error("Attempted to set NaN value",[...e[Ft],t],e[le]),"Attempted to set NaN value. See above for details"}return e[le][t]=n,!0},ownKeys(e){return Reflect.ownKeys(e[le])},has(e,t){return Reflect.has(e[le],t)},getOwnPropertyDescriptor(e,t){return Object.getOwnPropertyDescriptor(e[le],t)}};var A=window.player=new Proxy({[le]:gi,[Ft]:["player"]},yi);const ae=li();let Bt=null,Kt=null;function pn(){const e=Date.now();let t=(e-A.time)/1e3;A.time=e;const n=t;if(Y.lastTenTicks.push(n),Y.lastTenTicks.length>10&&(Y.lastTenTicks=Y.lastTenTicks.slice(1)),!((Kt==null?void 0:Kt.value)&&!A.keepGoing)&&!Y.hasNaN&&(t=Math.max(t,0),A.devSpeed!==0)){if(A.offlineTime!=null){if(a.gt(A.offlineTime,W.offlineLimit*3600)&&(A.offlineTime=W.offlineLimit*3600),a.gt(A.offlineTime,0)&&A.devSpeed!==0){const i=Math.max(A.offlineTime/10,t);A.offlineTime=A.offlineTime-i,t+=i}else A.devSpeed===0&&(A.offlineTime+=t);(!A.offlineProd||a.lt(A.offlineTime,0))&&(A.offlineTime=null)}t=Math.min(t,W.maxTickLength),A.devSpeed!=null&&(t*=A.devSpeed),Number.isFinite(t)||(t=1e308),!a.eq(t,0)&&(A.timePlayed+=t,Number.isFinite(A.timePlayed)||(A.timePlayed=1e308),ae.emit("update",t,n),ne.unthrottled?(requestAnimationFrame(pn),Bt!=null&&(clearInterval(Bt),Bt=null)):Bt==null&&(Bt=setInterval(pn,50)))}}async function ta(){Kt=(await mn(()=>Promise.resolve().then(function(){return Fi}),void 0)).hasWon,ze(Kt,e=>{e&&ae.emit("gameWon")}),ne.unthrottled?requestAnimationFrame(pn):Bt=setInterval(pn,50)}document.fonts.onloadingdone=()=>ae.emit("fontsLoaded");var na=Object.freeze(Object.defineProperty({__proto__:null,globalBus:ae,startGameLoop:ta},Symbol.toStringTag,{value:"Module"}));function bi(e={}){return Object.assign({id:`${W.id}-0`,name:"Default Save",tabs:W.initialTabs.slice(),time:Date.now(),autosave:!0,offlineProd:!0,offlineTime:0,timePlayed:0,keepGoing:!1,modID:W.id,modVersion:W.versionNumber,layers:{}},e)}function He(e){const t=mt.compressToUTF16(vi(e!=null?e:A[le]));return localStorage.setItem((e!=null?e:A[le]).id,t),t}async function ia(){aa();try{let e=localStorage.getItem(ne.active);if(e==null){await Ct(Dt());return}if(e[0]!=="{")if(e[0]==="e")e=decodeURIComponent(escape(atob(e)));else if(e[0]==="\u1BE1")e=mt.decompressFromUTF16(e);else throw"Unable to determine save encoding";const t=JSON.parse(e);if(t.modID!==W.id){await Ct(Dt());return}t.id=ne.active,await Ct(t)}catch(e){console.error(`Failed to load save. Falling back to new save. -`,e),await Ct(Dt())}}function Dt(){const e=cn(),t=bi({id:e});return He(t),ne.saves.push(e),t}function cn(){let e,t=0;do e=`${W.id}-${t++}`;while(localStorage.getItem(e));return e}async function Ct(e){console.info("Loading save",e);const{layers:t,removeLayer:n,addLayer:i}=await mn(()=>Promise.resolve().then(function(){return Ma}),void 0),{fixOldSave:s,getInitialLayers:l}=await mn(()=>Promise.resolve().then(function(){return Fi}),void 0);for(const o in t){const c=t[o];c&&n(c)}l(e).forEach(o=>i(o,e)),e=bi(e),e.offlineProd&&e.time&&e.devSpeed!==0&&(e.offlineTime==null&&(e.offlineTime=0),e.offlineTime+=Math.min(e.offlineTime+(Date.now()-e.time)/1e3,W.offlineLimit*3600)),e.time=Date.now(),e.modVersion!==W.versionNumber&&s(e.modVersion,e),Object.assign(A,e),ne.active=A.id,ae.emit("onLoad")}setInterval(()=>{A.autosave&&He()},1e3);window.onbeforeunload=()=>{A.autosave&&He()};window.save=He;const sa=window.hardReset=async()=>{await Ct(Dt())},Yt=nn({active:"",saves:[],showTPS:!0,theme:xn.Nordic,unthrottled:!1});ze(Yt,e=>{const t=mt.compressToUTF16(JSON.stringify(e));localStorage.setItem(W.id,t)},{deep:!0});var ne=window.settings=Yt;window.hardResetSettings=()=>{const e={active:"",saves:[],showTPS:!0,theme:xn.Nordic};ae.emit("loadSettings",e),Object.assign(Yt,e),sa()};function aa(){try{let e=localStorage.getItem(W.id);if(e!=null&&e!==""){if(e[0]!=="{")if(e[0]==="e")e=decodeURIComponent(escape(atob(e)));else if(e[0]==="\u1BE1")e=mt.decompressFromUTF16(e);else{console.warn("Unable to determine settings encoding",e);return}const t=JSON.parse(e);typeof t=="object"&&Object.assign(Yt,t)}ae.emit("loadSettings",Yt)}catch{}}const _i=nn([]);function la(e){_i.push(e)}const wi=nn([]);function ra(e){wi.push(e)}const oa=nn([]),ua={class:"table"},dn=L({__name:"Column",setup(e){const t=S(()=>sn[ne.theme].mergeAdjacent);return(n,i)=>(_(),M("div",ua,[m("div",{class:ce(["col",{mergeAdjacent:r(t)}])},[Je(n.$slots,"default")],2)]))}}),ca={class:"table"},Ni=L({__name:"Row",setup(e){const t=S(()=>sn[ne.theme].mergeAdjacent);return(n,i)=>(_(),M("div",ca,[m("div",{class:ce(["row",{mergeAdjacent:r(t)}])},[Je(n.$slots,"default")],2)]))}});function ki(e){return typeof e=="function"||Object.prototype.toString.call(e)==="[object Object]"&&!ji(e)}function K(e,t="span"){return typeof e=="function"?L({render:e}):typeof e=="string"?e.length>0?(e=e.trim(),e.charAt(0)!=="<"&&(e=`<${t}>${e}`),L({template:e})):L({render:()=>({})}):e}function he(e){if(yt(e))return typeof e=="function"?e():K(e);const t=e[gt];return u(t,e[vt](),null)}function Oe(...e){let t;return u(Ni,null,ki(t=e.map(he))?t:{default:()=>[t]})}function Ci(...e){let t;return u(dn,null,ki(t=e.map(he))?t:{default:()=>[t]})}function Xe(e){if(yt(e))return typeof e=="function"?e():typeof e=="string"?u(D,null,[e]):u(e,null,null);const t=e[gt];return u(t,e[vt](),null)}function yt(e){return typeof e=="string"?!0:typeof e=="object"?e==null?!1:"render"in e||"component"in e:typeof e=="function"&&e[Zt]===!0}function Si(e,t,n){const i=T(null),s=T(void 0);function l(f){i.value||(i.value=setInterval(c,250)),s.value=f,n&&(n.value=!0)}function o(){i.value&&(clearInterval(i.value),i.value=null),n&&(n.value=!1)}function c(){t&&t.value?t.value():e&&e.value&&e.value(s.value)}return si(o),{start:l,stop:o,handleHolding:c}}function Mi(e,t="div"){const n=Le();return Fe(()=>{n.value=K(pe(e),t)}),n}function Lt(e,t="div"){const n=Le(null);return Fe(()=>{const i=pe(e);n.value=i==null?null:K(i,t)}),n}function da(e){return S(()=>pe(e))}function pe(e){return r(r(e))}function P(...e){return e.includes(Object)||e.push(Object),e}const Re=L({__name:"Spacer",props:{width:{default:"8px"},height:{default:"17px"}},setup(e){return(t,n)=>(_(),M("div",{style:me({width:e.width,height:e.height})},null,4))}});var Z=(e,t)=>{const n=e.__vccOpts||e;for(const[i,s]of t)n[i]=s;return n};const fa=L({__name:"Context",emits:["updateNodes"],setup(e,{emit:t}){var g;const n=T({}),i=new ResizeObserver(c),s=T(null);yn(()=>{const y=s.value;y!=null&&i.observe(y)});let l=!0,o=T((g=s.value)==null?void 0:g.getBoundingClientRect());function c(){l&&(l=!1,Mt(()=>{var y;o.value=(y=s.value)==null?void 0:y.getBoundingClientRect(),Object.values(n.value).filter(b=>b).forEach(b=>b.rect=b.element.getBoundingClientRect()),t("updateNodes",n.value),l=!0}))}ae.on("fontsLoaded",c);const f={attributes:!1,childList:!0,subtree:!1};on(Fn,(y,b)=>{const p=new MutationObserver(()=>d(y));p.observe(b,f),n.value[y]={element:b,observer:p,rect:b.getBoundingClientRect()},c()}),on(Bn,y=>{var b;(b=n.value[y])==null||b.observer.disconnect(),n.value[y]=void 0,c()}),on(Dn,n),on(On,o);function d(y){const b=n.value[y];b!=null&&(b.rect=b.element.getBoundingClientRect(),t("updateNodes",n.value))}return(y,b)=>(_(),M(D,null,[Je(y.$slots,"default",{},void 0,!0),m("div",{ref_key:"resizeListener",ref:s,class:"resize-listener"},null,512)],64))}});var Ii=Z(fa,[["__scopeId","data-v-2b1dc1bc"]]);const ma=["onPointerdown"],ha={class:"modal-wrapper"},pa={class:"modal-container"},ga={class:"modal-header"},va=v(" default header "),ya={class:"modal-body"},ba=v(" default body "),_a={class:"modal-footer"},wa=m("div",{class:"modal-default-flex-grow"},null,-1),We=L({__name:"Modal",props:{modelValue:{type:Boolean}},emits:["update:modelValue"],setup(e,{expose:t,emit:n}){const s=we(e),l=S(()=>s.modelValue||c.value);function o(){n("update:modelValue",!1)}const c=T(!1),f=T(null),d=S(()=>{var g,y;return(y=(g=f.value)==null?void 0:g.nodes)!=null?y:null});return t({isOpen:l,nodes:d}),(g,y)=>(_(),j(Wi,{to:"#modal-root"},[u(bn,{name:"modal",onBeforeEnter:y[0]||(y[0]=b=>c.value=!0),onAfterLeave:y[1]||(y[1]=b=>c.value=!1)},{default:R(()=>[Tn(m("div",It({class:"modal-mask",onPointerdown:Xt(o,["self"])},g.$attrs),[m("div",ha,[m("div",pa,[m("div",ga,[Je(g.$slots,"header",{shown:r(l)},()=>[va])]),m("div",ya,[u(Ii,{ref_key:"contextRef",ref:f},{default:R(()=>[Je(g.$slots,"body",{shown:r(l)},()=>[ba])]),_:3},512)]),m("div",_a,[Je(g.$slots,"footer",{shown:r(l)},()=>[m("div",{class:"modal-default-footer"},[wa,m("button",{class:"button modal-default-button",onClick:o}," Close ")])])])])])],16,ma),[[zi,e.modelValue]])]),_:3})]))}}),en=Symbol("PersistentState"),tn=Symbol("DefaultValue"),gn=Symbol("StackTrace"),Ai=Symbol("Deleted");function Na(){var e;return((e=new Error().stack)==null?void 0:e.split(` -`).slice(3,5).map(t=>t.trim()).join(` -`))||""}function Ae(e){const t=be(e)?e:T(e);return t[en]=t,t[tn]=be(e)?e.value:e,t[gn]=Na(),t[Ai]=!1,je.length===0?console.warn("Creating a persistent ref outside of a layer. This is not officially supported",t,` -Created at: -`+t[gn]):Ot[je[je.length-1]].add(t),t}ae.on("addLayer",(e,t)=>{const n=[],i=(s,l=[])=>{let o=!1;return Object.keys(s).forEach(c=>{const f=s[c];if(f&&typeof f=="object")if(en in f){if(o=!0,f[Ai]){console.warn("Deleted persistent ref present in returned object. Ignoring...",f,` -Created at: -`+f[gn]);return}Ot[e.id].delete(le in f?f[le]:f);const d=l.reduce((y,b)=>(b in y||(y[b]={}),y[b]),t),g=d[c];d[c]=f[en],Qi(d)?g!=null?d[c]=g:d[c]=f[tn]:g!=null?d[c].value=g:d[c].value=f[tn]}else!(f instanceof a)&&!be(f)&&!n.includes(f)&&(typeof f.type=="symbol"&&n.push(f),i(f,[...l,c])&&(Jn(f)&&!Jn(s)?console.warn("Found array that contains persistent values when adding layer. Keep in mind changing the order of elements in the array will mess with existing player saves.",le in s?s[le]:s,c):o=!0))}),o};i(e),Ot[e.id].forEach(s=>{console.error(`Created persistent ref in ${e.id} without registering it to the layer! Make sure to include everything persistent in the returned object`,s,` -Created at: -`+s[gn])}),Ot[e.id].clear()});const Fn=Symbol("RegisterNode"),Bn=Symbol("UnregisterNode"),Dn=Symbol("Nodes"),On=Symbol("Bounds"),Ne=vn({});window.layers=Ne;const Ot={},je=[];function Gt(e,t){return Be(()=>{const n={},i=n.emitter=li();if(n.on=i.on.bind(i),n.emit=i.emit.bind(i),n.nodes=T({}),n.id=e,je.push(e),Ot[e]=new Set,n.minimized=Ae(!1),Object.assign(n,t.call(n)),je[je.length-1]==null||je[je.length-1]!==e)throw`Adding layers stack in invalid state. This should not happen -Stack: ${je} -Trying to pop ${n.id}`;return je.pop(),E(n,"color"),E(n,"display"),E(n,"name"),_e(n,"name",n.id),E(n,"minWidth"),_e(n,"minWidth",600),E(n,"minimizable"),_e(n,"minimizable",!0),n})}function Ei(e,t){if(console.info("Adding layer",e.id),Ne[e.id]){console.error("Attempted to add layer with same ID as existing layer",e.id,Ne[e.id]);return}_e(t,"layers",{}),t.layers[e.id]==null&&(t.layers[e.id]={}),Ne[e.id]=e,ae.emit("addLayer",e,t.layers[e.id])}function ka(e){return Ne[e]}function Pi(e){console.info("Removing layer",e.id),ae.emit("removeLayer",e),Ne[e.id]=void 0}function Ca(e){Pi(e),Ei(e,A)}function Sa(e){const t=T(!1);return{openModal:()=>t.value=!0,modal:F(()=>u(We,{modelValue:t.value,"onUpdate:modelValue":n=>t.value=n},{header:()=>u("h2",null,[r(e.name)]),body:r(e.display)}))}}ae.on("update",function(t){Object.values(Ne).forEach(n=>{n==null||n.emit("preUpdate",t)}),Object.values(Ne).forEach(n=>{n==null||n.emit("update",t)}),Object.values(Ne).forEach(n=>{n==null||n.emit("postUpdate",t)})});var Ma=Object.freeze(Object.defineProperty({__proto__:null,RegisterNodeInjectionKey:Fn,UnregisterNodeInjectionKey:Bn,NodesInjectionKey:Dn,BoundsInjectionKey:On,layers:Ne,persistentRefs:Ot,addingLayers:je,createLayer:Gt,addLayer:Ei,getLayer:ka,removeLayer:Pi,reloadLayer:Ca,setupLayerModal:Sa},Symbol.toStringTag,{value:"Module"}));const Ia={},Aa={class:"notif"};function Ea(e,t){return _(),M("div",Aa,"!")}var ni=Z(Ia,[["render",Ea],["__scopeId","data-v-66323fd4"]]);const wn=e=>(nt("data-v-949cc93c"),e=e(),it(),e),Pa={key:0,class:"day feature dontMerge opened"},$a={class:"date"},Ta=v("Dec"),xa=wn(()=>m("br",null,null,-1)),Fa={class:"date"},Ba=v("Dec"),Da=wn(()=>m("br",null,null,-1)),Oa=wn(()=>m("div",{class:"doors"},null,-1)),Ra={class:"date"},qa=v("Dec"),Va=wn(()=>m("br",null,null,-1)),La={key:0,class:"material-icons lock"},Ga=L({__name:"Day",props:{day:null,symbol:null,opened:null,shouldNotify:null},emits:["openLore","openLayer","unlockLayer"],setup(e,{emit:t}){const n=e,i=S(()=>a.gte(B.day.value,n.day)&&new Date().getMonth()===11&&new Date().getDate()>=n.day);function s(){i.value&&t("unlockLayer")}return(l,o)=>e.opened.value?(_(),M("div",Pa,[u(bn,{appear:"",name:"door"},{default:R(()=>[m("div",{class:"doors",onClick:o[0]||(o[0]=c=>t("openLayer"))},[m("div",$a,[Ta,xa,v(H(e.day),1)]),m("div",Fa,[Ba,Da,v(H(e.day),1)])])]),_:1}),m("div",{class:"icon",style:me({backgroundImage:`url(${e.symbol})`})},null,4),m("div",{class:"lore",onClick:o[1]||(o[1]=c=>t("openLore"))},"?"),r(e.shouldNotify)?(_(),j(ni,{key:0})):$("",!0)])):(_(),M("div",{key:1,class:ce(["day feature dontMerge",{can:r(i),locked:!r(i),canOpen:r(i)}]),onClick:s},[Oa,m("div",Ra,[qa,Va,v(H(e.day),1)]),r(i)?$("",!0):(_(),M("div",La,"lock")),r(i)?(_(),j(ni,{key:1})):$("",!0)],2))}});var Ua=Z(Ga,[["__scopeId","data-v-949cc93c"]]);const Ha={key:0},ja={key:0,class:"mark star"},za=["src"],Wa=L({__name:"MarkNode",props:{mark:{type:[Boolean,String]}},setup(e){return(t,n)=>e.mark?(_(),M("div",Ha,[e.mark===!0?(_(),M("div",ja)):(_(),M("img",{key:1,class:"mark",src:e.mark},null,8,za))])):$("",!0)}});var Nn=Z(Wa,[["__scopeId","data-v-2207999f"]]);const Qa=L({__name:"Node",props:{id:null},setup(e){const n=we(e),i=fn(Fn,()=>{}),s=fn(Bn,()=>{}),l=Le(null),o=S(()=>l.value&&l.value.parentElement);return ze([o,n.id],([c,f],[d,g])=>{d&&s(r(g)),c&&i(f,c)}),si(()=>s(r(n.id))),(c,f)=>(_(),M("div",{class:"node",ref_key:"node",ref:l},null,512))}});var an=Z(Qa,[["__scopeId","data-v-a48cb382"]]),Ka=L({props:{display:{type:P(Object,String,Function),required:!0},visibility:{type:P(Number),required:!0},style:P(Object,String,Array),classes:P(Object),onClick:Function,onHold:Function,canClick:{type:P(Boolean),required:!0},small:Boolean,mark:P(Boolean,String),id:{type:String,required:!0},isHolding:Object},components:{Node:an,MarkNode:Nn},setup(e){const{display:t,onClick:n,onHold:i}=we(e),s=Le("");Fe(()=>{const c=pe(t);if(c==null){s.value="";return}if(yt(c)){s.value=K(c);return}const f=K(c.title||"","h3"),d=K(c.description,"div");s.value=K(F(()=>u("span",null,[c.title?u("div",null,[u(f,null,null)]):null,u(d,null,null)])))});const{start:l,stop:o}=Si(n,i,e.isHolding);return{start:l,stop:o,comp:s,Visibility:ye,unref:r}}});function Ja(e,t,n,i,s,l){var f;const o=pt("MarkNode"),c=pt("Node");return e.unref(e.visibility)!==e.Visibility.None?(_(),M("button",{key:0,style:me([{visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},(f=e.unref(e.style))!=null?f:[]]),onClick:t[0]||(t[0]=(...d)=>e.onClick&&e.onClick(...d)),onMousedown:t[1]||(t[1]=(...d)=>e.start&&e.start(...d)),onMouseleave:t[2]||(t[2]=(...d)=>e.stop&&e.stop(...d)),onMouseup:t[3]||(t[3]=(...d)=>e.stop&&e.stop(...d)),onTouchstartPassive:t[4]||(t[4]=(...d)=>e.start&&e.start(...d)),onTouchendPassive:t[5]||(t[5]=(...d)=>e.stop&&e.stop(...d)),onTouchcancelPassive:t[6]||(t[6]=(...d)=>e.stop&&e.stop(...d)),class:ce({feature:!0,clickable:!0,can:e.unref(e.canClick),locked:!e.unref(e.canClick),small:e.small,...e.unref(e.classes)})},[e.unref(e.comp)?(_(),j(ke(e.unref(e.comp)),{key:0})):$("",!0),u(o,{mark:e.unref(e.mark)},null,8,["mark"]),u(c,{id:e.id},null,8,["id"])],38)):$("",!0)}var $i=Z(Ka,[["render",Ja],["__scopeId","data-v-8cedd7da"]]);const Xa=Symbol("Clickable");function Se(e){return Be(()=>{var n;const t=(n=e==null?void 0:e())!=null?n:{};if(t.id=Vt("clickable-"),t.type=Xa,t[gt]=$i,t.isHolding=T(!1),E(t,"visibility"),_e(t,"visibility",ye.Visible),E(t,"canClick"),_e(t,"canClick",!0),E(t,"classes"),E(t,"style"),E(t,"mark"),E(t,"display"),t.onClick){const i=t.onClick.bind(t);t.onClick=function(s){r(t.canClick)&&i(s)}}if(t.onHold){const i=t.onHold.bind(t);t.onHold=function(){r(t.canClick)&&i()}}return t[vt]=function(){const{display:i,visibility:s,style:l,classes:o,onClick:c,onHold:f,isHolding:d,canClick:g,small:y,mark:b,id:p}=this;return{display:i,visibility:s,style:r(l),classes:o,onClick:c,onHold:f,isHolding:d,canClick:g,small:y,mark:b,id:p}},t})}function St(e,t="points",n=0,i=void 0){const s=be(e)?e:Ae(e);return s.displayName=t,s.precision=n,s.small=i,s}function Ti(e){const t=Ae(e.value);return ze(e,(n,i)=>{a.gt(n,i)&&(t.value=a.add(t.value,a.sub(n,i)))}),t}new a("10^^8");new a("1e100");function Rn(e,t){const n=t!=null?t:e.value;return a.eq(e.precision,0)?G(e.small?n:a.floor(n)):te(n,e.precision,e.small)}const Za=["x1","y1","x2","y2"],Ya=L({__name:"Link",props:{link:null,startNode:null,endNode:null,boundingRect:null},setup(e){const n=we(e),i=S(()=>{const l=n.startNode.value.rect,o=n.boundingRect.value,c=o?{x:l.x+l.width/2-o.x,y:l.y+l.height/2-o.y}:{x:0,y:0};return n.link.value.offsetStart&&(c.x+=n.link.value.offsetStart.x,c.y+=n.link.value.offsetStart.y),c}),s=S(()=>{const l=n.endNode.value.rect,o=n.boundingRect.value,c=o?{x:l.x+l.width/2-o.x,y:l.y+l.height/2-o.y}:{x:0,y:0};return n.link.value.offsetEnd&&(c.x+=n.link.value.offsetEnd.x,c.y+=n.link.value.offsetEnd.y),c});return(l,o)=>(_(),M("line",It({"stroke-width":"15px",stroke:"white"},e.link,{x1:r(i).x,y1:r(i).y,x2:r(s).x,y2:r(s).y}),null,16,Za))}});const el=L({__name:"Links",props:{links:null},setup(e){var f;const n=tt(e,"links"),i=T(null),s=fn(Dn,T({})),l=fn(On,T(void 0)),o=T((f=i.value)==null?void 0:f.getBoundingClientRect());ze(l,()=>{var d;return o.value=(d=i.value)==null?void 0:d.getBoundingClientRect()}),yn(()=>{var d;return o.value=(d=i.value)==null?void 0:d.getBoundingClientRect()});const c=S(()=>{var g,y;const d=s.value;return(y=(g=n.value)==null?void 0:g.filter(b=>{var p,N;return((p=d[b.startNode.id])==null?void 0:p.rect)&&((N=d[b.startNode.id])==null?void 0:N.rect)}))!=null?y:[]});return(d,g)=>(_(),M(D,null,[r(c)?(_(),M("svg",Ki(It({key:0},d.$attrs)),[(_(!0),M(D,null,ai(r(c),(y,b)=>(_(),j(Ya,{key:b,link:y,boundingRect:o.value,startNode:r(s)[y.startNode.id],endNode:r(s)[y.endNode.id]},null,8,["link","boundingRect","startNode","endNode"]))),128))],16)):$("",!0),m("div",{ref_key:"resizeListener",ref:i,class:"resize-listener"},null,512)],64))}});var tl=Z(el,[["__scopeId","data-v-063f6d6b"]]);L({props:{nodes:{type:P(Array),required:!0},leftSideNodes:P(Array),rightSideNodes:P(Array),branches:P(Array)},components:{Links:tl},setup(e){const{nodes:t,leftSideNodes:n,rightSideNodes:i}=we(e),s=Le();Fe(()=>{const c=pe(t);s.value=K(F(()=>u(D,null,[c.map(f=>u("span",{class:"row tree-row",style:"margin: 50px auto;"},[f.map(Xe)]))])))});const l=Le();Fe(()=>{const c=pe(n);l.value=c?K(F(()=>u("span",{class:"left-side-nodes small"},[c.map(Xe)]))):""});const o=Le();return Fe(()=>{const c=pe(i);o.value=c?K(F(()=>u("span",{class:"side-nodes small"},[c.map(Xe)]))):""}),{unref:r,nodesComp:s,leftNodesComp:l,rightNodesComp:o}}});L({props:{display:P(Object,String,Function),visibility:{type:P(Number),required:!0},style:P(String,Object,Array),classes:P(Object),onClick:Function,onHold:Function,color:P(String),glowColor:P(String),canClick:{type:P(Boolean),required:!0},mark:P(Boolean,String),id:{type:String,required:!0}},components:{MarkNode:Nn,Node:an},setup(e){const{onClick:t,onHold:n,display:i}=we(e),s=Lt(i),{start:l,stop:o}=Si(t,n);return{start:l,stop:o,comp:s,unref:r,Visibility:ye,isCoercableComponent:yt}}});function qn(e){const t=[],n={};let i=!1;function s(){return i||(t.push(...e()),n.base=t.map(c=>Ie(c.base)),n.baseText=t.map(c=>Ie(c.baseText)),n.visible=t.map(c=>Ie(c.visible)),i=!0),t}const l=Ae({});return[F(()=>{const c=s();let f=!0;const d=c.map((g,y)=>{var C,x,de;if(r(n.visible[y])===!1)return null;const b=u("h3",{onClick:()=>l.value[y]=!l.value[y],style:"cursor: pointer"},[u("span",{class:"modifier-toggle"+(r(l.value[y])?" collapsed":"")},[v("\u25BC")]),g.title,g.subtitle?u("span",{class:"subtitle"},[v(" ("),g.subtitle,v(")")]):null]),p=r(l.value[y])?null:u(D,null,[u("div",{class:"modifier-container"},[u("span",{class:"modifier-amount"},[te((C=r(n.base[y]))!=null?C:1),g.unit]),u("span",{class:"modifier-description"},[Xe((x=r(n.baseText[y]))!=null?x:"Base")])]),Xe(r(g.modifier.description))]),N=!f;return f=!1,u(D,null,[N?u("br",null,null):null,u("div",null,[b,u("br",null,null),p,u("hr",null,null),v("Total: "),te(g.modifier.apply((de=r(n.base[y]))!=null?de:1)),g.unit])])});return u(D,null,[d])}),l]}const nl=L({props:{progress:{type:P(String,Object,Number),required:!0},width:{type:P(Number),required:!0},height:{type:P(Number),required:!0},direction:{type:P(String),required:!0},display:P(Object,String,Function),visibility:{type:P(Number),required:!0},style:P(Object,String,Array),classes:P(Object),borderStyle:P(Object,String,Array),textStyle:P(Object,String,Array),baseStyle:P(Object,String,Array),fillStyle:P(Object,String,Array),mark:P(Boolean,String),id:{type:String,required:!0}},components:{MarkNode:Nn,Node:an},setup(e){const{progress:t,width:n,height:i,direction:s,display:l}=we(e),o=S(()=>{let d=t.value instanceof a?t.value.toNumber():Number(t.value);return(1-Math.min(Math.max(d,0),1))*100}),c=S(()=>{const d={width:pe(n)+.5+"px",height:pe(i)+.5+"px"};switch(r(s)){case J.Up:d.clipPath=`inset(${o.value}% 0% 0% 0%)`,d.width=pe(n)+1+"px";break;case J.Down:d.clipPath=`inset(0% 0% ${o.value}% 0%)`,d.width=pe(n)+1+"px";break;case J.Right:d.clipPath=`inset(0% ${o.value}% 0% 0%)`;break;case J.Left:d.clipPath=`inset(0% 0% 0% ${o.value} + '%)`;break;case J.Default:d.clipPath="inset(0% 50% 0% 0%)";break}return d}),f=Lt(l);return{normalizedProgress:o,barStyle:c,component:f,unref:r,Visibility:ye}}});function il(e,t,n,i,s,l){var f,d,g,y,b,p,N;const o=pt("MarkNode"),c=pt("Node");return e.unref(e.visibility)!==e.Visibility.None?(_(),M("div",{key:0,style:me([{width:e.unref(e.width)+"px",height:e.unref(e.height)+"px",visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},(f=e.unref(e.style))!=null?f:{}]),class:ce({bar:!0,...e.unref(e.classes)})},[m("div",{class:"overlayTextContainer border",style:me([{width:e.unref(e.width)+"px",height:e.unref(e.height)+"px"},(d=e.unref(e.borderStyle))!=null?d:{}])},[e.component?(_(),M("span",{key:0,class:"overlayText",style:me(e.unref(e.textStyle))},[(_(),j(ke(e.component)))],4)):$("",!0)],4),m("div",{class:"border",style:me([{width:e.unref(e.width)+"px",height:e.unref(e.height)+"px"},(g=e.unref(e.style))!=null?g:{},(y=e.unref(e.baseStyle))!=null?y:{},(b=e.unref(e.borderStyle))!=null?b:{}])},[m("div",{class:"fill",style:me([e.barStyle,(p=e.unref(e.style))!=null?p:{},(N=e.unref(e.fillStyle))!=null?N:{}])},null,4)],4),u(o,{mark:e.unref(e.mark)},null,8,["mark"]),u(c,{id:e.id},null,8,["id"])],6)):$("",!0)}var sl=Z(nl,[["render",il],["__scopeId","data-v-02d0d7b2"]]);const al=Symbol("Bar");function Rt(e){return Be(()=>{const t=e();return t.id=Vt("bar-"),t.type=al,t[gt]=sl,E(t,"visibility"),_e(t,"visibility",ye.Visible),E(t,"width"),E(t,"height"),E(t,"direction"),E(t,"style"),E(t,"classes"),E(t,"borderStyle"),E(t,"baseStyle"),E(t,"textStyle"),E(t,"fillStyle"),E(t,"progress"),E(t,"display"),E(t,"mark"),t[vt]=function(){const{progress:n,width:i,height:s,direction:l,display:o,visibility:c,style:f,classes:d,borderStyle:g,textStyle:y,baseStyle:b,fillStyle:p,mark:N,id:C}=this;return{progress:n,width:i,height:s,direction:l,display:o,visibility:c,style:r(f),classes:d,borderStyle:g,textStyle:y,baseStyle:b,fillStyle:p,mark:N,id:C}},t})}const ll=Symbol("Buyable");function et(e){const t=Ae(0);return Be(()=>{var l,o,c;const n=e();if(n.canPurchase==null&&(n.resource==null||n.cost==null))throw console.warn("Cannot create buyable without a canPurchase property or a resource and cost property",n),"Cannot create buyable without a canPurchase property or a resource and cost property";n.id=Vt("buyable-"),n.type=ll,n[gt]=$i,n.amount=t,n.amount[tn]=(l=n.initialValue)!=null?l:0,n.canAfford=S(()=>{const f=n,d=r(f.cost);return f.resource!=null&&d!=null&&a.gte(f.resource.value,d)}),n.canPurchase==null&&(n.canPurchase=S(()=>r(n.visibility)===ye.Visible&&r(n.canAfford)&&a.lt(n.amount.value,r(n.purchaseLimit)))),n.maxed=S(()=>a.gte(n.amount.value,r(n.purchaseLimit))),E(n,"classes");const i=n.classes;n.classes=S(()=>{const f=r(i)||{};return n.maxed.value&&(f.bought=!0),f}),E(n,"canPurchase"),n.canClick=n.canPurchase,n.onClick=n.purchase=(c=(o=n.onClick)!=null?o:n.purchase)!=null?c:function(){var g;const f=n;if(!r(f.canPurchase))return;const d=r(f.cost);f.cost!=null&&f.resource!=null&&(f.resource.value=a.sub(f.resource.value,d),f.amount.value=a.add(f.amount.value,1)),(g=f.onPurchase)==null||g.call(f,d)},E(n,"display");const s=n.display;return n.display=F(()=>{const f=r(s);if(yt(f)){const d=K(f);return u(d,null,null)}if(f!=null&&n.cost!=null&&n.resource!=null){const d=n,g=K(f.title||"","h3"),y=K(f.description||""),b=K(f.effectDisplay||"");return u("span",null,[f.title?u("div",null,[u(g,null,null)]):null,f.description?u(y,null,null):null,f.showAmount===!1?null:u("div",null,[u("br",null,null),r(d.purchaseLimit)===a.dInf?u(D,null,[v("Amount: "),G(d.amount.value)]):u(D,null,[v("Amount: "),G(d.amount.value),v(" /")," ",G(r(d.purchaseLimit))])]),f.effectDisplay?u("div",null,[u("br",null,null),v("Currently: "),u(b,null,null)]):null,d.cost&&!d.maxed.value?u("div",null,[u("br",null,null),v("Cost: "),te(r(d.cost)||0)," ",n.resource.displayName]):null])}return""}),E(n,"visibility"),_e(n,"visibility",ye.Visible),E(n,"cost"),E(n,"resource"),E(n,"purchaseLimit"),_e(n,"purchaseLimit",a.dInf),E(n,"style"),E(n,"mark"),E(n,"small"),n[vt]=function(){const{display:f,visibility:d,style:g,classes:y,onClick:b,canClick:p,small:N,mark:C,id:x}=this;return{display:f,visibility:d,style:r(g),classes:y,onClick:b,canClick:p,small:N,mark:C,id:x}},n})}const kn=vn({}),Vn=Symbol("Hotkey");function ii(e){return Be(()=>{const t=e();return t.type=Vn,E(t,"enabled"),_e(t,"enabled",!0),E(t,"description"),t})}ae.on("addLayer",e=>{pi(e,Vn).forEach(t=>{kn[t.key]=t})});ae.on("removeLayer",e=>{pi(e,Vn).forEach(t=>{kn[t.key]=void 0})});document.onkeydown=function(e){var i;if(((i=e.target)==null?void 0:i.tagName)==="INPUT"||Gn.value&&!A.keepGoing)return;let t=e.key;e.shiftKey&&(t="shift+"+t),e.ctrlKey&&(t="ctrl+"+t);const n=kn[t];n&&r(n.enabled)&&(e.preventDefault(),n.onPress())};ra(F(()=>{const e=Object.values(kn).filter(t=>r(t==null?void 0:t.enabled));return e.length===0?"":u("div",null,[u("br",null,null),u("h4",null,[v("Hotkeys")]),e.map(t=>u("div",null,[t==null?void 0:t.key,v(": "),t==null?void 0:t.description]))])}));const rl=L({__name:"Sticky",setup(e){const t=T("0"),n=new ResizeObserver(s),i=Le(null);function s(){let l=i.value;if(l==null)return;let o=0;for(;l.previousSibling;){const c=l.previousSibling;c.dataset&&"vSticky"in c.dataset&&(o+=c.offsetHeight),l=c}t.value=o+"px"}return Mt(s),document.fonts.ready.then(s),yn(()=>{var o;const l=(o=i.value)==null?void 0:o.parentElement;l&&n.observe(l)}),(l,o)=>(_(),M("div",{class:"sticky",style:me({top:t.value}),ref_key:"element",ref:i,"data-v-sticky":""},[Je(l.$slots,"default",{},void 0,!0)],4))}});var ol=Z(rl,[["__scopeId","data-v-cccac690"]]);const ul=L({__name:"Resource",props:{resource:null,color:null},setup(e){const t=e,n=S(()=>Rn(t.resource));return(i,s)=>(_(),M("h2",{style:me({color:e.color,"text-shadow":"0px 0px 10px "+e.color})},H(r(n)),5))}});const cl={class:"main-display"},dl={key:0},fl={key:1},ml=v(", "),Jt=L({__name:"MainDisplay",props:{resource:null,color:null,classes:null,style:null,effectDisplay:null},setup(e){const n=we(e),i=T(null),s=Lt(n.effectDisplay),l=S(()=>a.lt(n.resource.value,"1e1000"));return(o,c)=>(_(),j(ol,null,{default:R(()=>{var f,d,g,y;return[m("div",{class:ce(["main-display-container",(f=e.classes)!=null?f:{}]),style:me([{height:`${((g=(d=i.value)==null?void 0:d.$el.clientHeight)!=null?g:0)+50}px`},(y=e.style)!=null?y:{}])},[m("div",cl,[r(l)?(_(),M("span",dl,"You have ")):$("",!0),u(ul,{resource:e.resource,color:e.color||"white"},null,8,["resource","color"]),v(" "+H(e.resource.displayName),1),r(s)?(_(),M("span",fl,[ml,(_(),j(ke(r(s)),{ref_key:"effectRef",ref:i},null,512))])):$("",!0)])],6)]}),_:1}))}});var hl=L({props:{display:{type:P(String,Object,Function),required:!0},visibility:{type:P(Number),required:!0},style:P(String,Object,Array),classes:P(Object),resource:Object,cost:P(String,Object,Number),canPurchase:{type:P(Boolean),required:!0},bought:{type:P(Boolean),required:!0},mark:P(Boolean,String),id:{type:String,required:!0},purchase:{type:Function,required:!0}},components:{Node:an,MarkNode:Nn},setup(e){const{display:t,cost:n}=we(e),i=Le("");return Fe(()=>{const s=pe(t);if(s==null){i.value="";return}if(yt(s)){i.value=K(s);return}const l=pe(n),o=K(s.title||"","h3"),c=K(s.description,"div"),f=K(s.effectDisplay||"");i.value=K(F(()=>{var d;return u("span",null,[s.title?u("div",null,[u(o,null,null)]):null,u(c,null,null),s.effectDisplay?u("div",null,[v("Currently: "),u(f,null,null)]):null,e.resource!=null&&s.showCost!==!1?u(D,null,[u("br",null,null),v("Cost: "),e.resource&&Rn(e.resource,l)," ",(d=e.resource)==null?void 0:d.displayName]):null])}))}),{component:i,unref:r,Visibility:ye}}});const pl=["disabled"];function gl(e,t,n,i,s,l){var f;const o=pt("MarkNode"),c=pt("Node");return e.unref(e.visibility)!==e.Visibility.None?(_(),M("button",{key:0,style:me([{visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},(f=e.unref(e.style))!=null?f:{}]),onClick:t[0]||(t[0]=(...d)=>e.purchase&&e.purchase(...d)),class:ce({feature:!0,upgrade:!0,can:e.unref(e.canPurchase),locked:!e.unref(e.canPurchase),bought:e.unref(e.bought),...e.unref(e.classes)}),disabled:!e.unref(e.canPurchase)},[e.unref(e.component)?(_(),j(ke(e.unref(e.component)),{key:0})):$("",!0),u(o,{mark:e.unref(e.mark)},null,8,["mark"]),u(c,{id:e.id},null,8,["id"])],14,pl)):$("",!0)}var vl=Z(hl,[["render",gl],["__scopeId","data-v-7f411ac8"]]);const yl=Symbol("Upgrade");function re(e){const t=Ae(!1);return Be(()=>{const n=e();return n.id=Vt("upgrade-"),n.type=yl,n[gt]=vl,n.canAfford==null&&(n.resource==null||n.cost==null)&&console.warn("Error: can't create upgrade without a canAfford property or a resource and cost property",n),n.bought=t,n.canAfford==null?n.canAfford=S(()=>{const i=n;return i.resource!=null&&i.cost!=null&&a.gte(i.resource.value,r(i.cost))}):E(n,"canAfford"),n.canPurchase=S(()=>r(n.visibility)===ye.Visible&&r(n.canAfford)&&!r(n.bought)),n.purchase=function(){var s;const i=n;!r(i.canPurchase)||(i.resource!=null&&i.cost!=null&&(i.resource.value=a.sub(i.resource.value,r(i.cost))),t.value=!0,(s=i.onPurchase)==null||s.call(i))},E(n,"visibility"),_e(n,"visibility",ye.Visible),E(n,"classes"),E(n,"style"),E(n,"display"),E(n,"mark"),E(n,"cost"),E(n,"resource"),n[vt]=function(){const{display:i,visibility:s,style:l,classes:o,resource:c,cost:f,canPurchase:d,bought:g,mark:y,id:b,purchase:p}=this;return{display:i,visibility:s,style:r(l),classes:o,resource:c,cost:f,canPurchase:d,bought:g,mark:y,id:b,purchase:p}},n})}function ee(e){return Be(()=>{const{addend:t,description:n,enabled:i}=e(),s=Ie(t),l=Ie(n),o=i==null?void 0:Ie(i);return{apply:c=>a.add(c,r(s)),revert:c=>a.sub(c,r(s)),enabled:o,description:n==null?void 0:F(()=>u("div",{class:"modifier-container"},[u("span",{class:"modifier-amount"},[a.gte(r(s),0)?"+":"",te(r(s))]),r(l)?u("span",{class:"modifier-description"},[Xe(r(l))]):null]))}})}function ie(e){return Be(()=>{const{multiplier:t,description:n,enabled:i}=e(),s=Ie(t),l=Ie(n),o=i==null?void 0:Ie(i);return{apply:c=>a.times(c,r(s)),revert:c=>a.div(c,r(s)),enabled:o,description:n==null?void 0:F(()=>u("div",{class:"modifier-container"},[u("span",{class:"modifier-amount"},[v("x"),te(r(s))]),r(l)?u("span",{class:"modifier-description"},[Xe(r(l))]):null]))}})}function xi(e){return Be(()=>{const{exponent:t,description:n,enabled:i,supportLowNumbers:s}=e(),l=Ie(t),o=Ie(n),c=i==null?void 0:Ie(i);return{apply:f=>{let d=f;return s&&(d=a.add(d,1)),d=a.pow(d,r(l)),s&&(d=a.sub(d,1)),d},revert:f=>{let d=f;return s&&(d=a.add(d,1)),d=a.root(d,r(l)),s&&(d=a.sub(d,1)),d},enabled:c,description:n==null?void 0:F(()=>u("div",{class:"modifier-container"},[u("span",{class:"modifier-amount"},[v("^"),te(r(l))]),r(o)?u("span",{class:"modifier-description"},[Xe(r(o)),s?" (+1 effective)":null]):null]))}})}function Me(e){return Be(()=>{const t=e();return{apply:n=>t.filter(i=>r(i.enabled)!==!1).reduce((i,s)=>s.apply(i),n),revert:t.every(n=>n.revert!=null)?n=>t.filter(i=>r(i.enabled)!==!1).reduceRight((i,s)=>s.revert(i),n):void 0,enabled:S(()=>t.filter(n=>r(n.enabled)!==!1).length>0),description:F(()=>u(D,null,[t.filter(n=>r(n.enabled)!==!1).map(n=>r(n.description)).filter(n=>n).map(Xe)]))}})}const bl={class:"field"},_l={key:0,class:"field-title"},Ln=L({__name:"Select",props:{title:null,modelValue:null,options:null,placeholder:null,closeOnSelect:{type:Boolean}},emits:["update:modelValue"],setup(e,{emit:t}){var o;const n=e,i=Lt(tt(n,"title"),"span"),s=T((o=n.options.find(c=>c.value===n.modelValue))!=null?o:null);ze(tt(n,"modelValue"),c=>{var f;pe(s)!==c&&(s.value=(f=n.options.find(d=>d.value===c))!=null?f:null)});function l(c){t("update:modelValue",c.value)}return(c,f)=>(_(),M("div",bl,[r(i)?(_(),M("span",_l,[(_(),j(ke(r(i))))])):$("",!0),u(r(es),{options:e.options,modelValue:s.value,"onUpdate:modelValue":[f[0]||(f[0]=d=>s.value=d),l],min:1,"label-by":"label",placeholder:e.placeholder,"close-on-select":e.closeOnSelect},null,8,["options","modelValue","placeholder","close-on-select"])]))}});var wl=L({props:{visibility:{type:P(Number),required:!0},display:{type:P(String,Object,Function),required:!0},style:P(String,Object,Array),classes:P(Object),earned:{type:P(Boolean),required:!0},id:{type:String,required:!0}},components:{Node:an},setup(e){const{display:t}=we(e),n=Le("");return Fe(()=>{const i=pe(t);if(i==null){n.value="";return}if(yt(i)){n.value=K(i);return}const s=K(i.requirement,"h3"),l=K(i.effectDisplay||"","b"),o=K(i.optionsDisplay||"","span");n.value=K(F(()=>u("span",null,[u(s,null,null),i.effectDisplay?u("div",null,[u(l,null,null)]):null,i.optionsDisplay?u("div",{class:"equal-spaced"},[u(o,null,null)]):null])))}),{comp:n,unref:r,Visibility:ye}}});function Nl(e,t,n,i,s,l){var c;const o=pt("Node");return e.unref(e.visibility)!==e.Visibility.None?(_(),M("div",{key:0,style:me([{visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},(c=e.unref(e.style))!=null?c:{}]),class:ce({feature:!0,milestone:!0,done:e.unref(e.earned),...e.unref(e.classes)})},[(_(),j(ke(e.unref(e.comp)))),u(o,{id:e.id},null,8,["id"])],6)):$("",!0)}var kl=Z(wl,[["render",Nl],["__scopeId","data-v-f4e8794e"]]);ae.on("setupVue",e=>e.use(ts));const Cl=ri(),Sl=Symbol("Milestone");let ht;(function(e){e.All="all",e.Configurable="configurable",e.Incomplete="incomplete",e.None="none"})(ht||(ht={}));function xe(e){const t=Ae(!1);return Be(()=>{var s;const n=(s=e==null?void 0:e())!=null?s:{};n.id=Vt("milestone-"),n.type=Sl,n[gt]=kl,n.earned=t,n.complete=function(){t.value=!0},E(n,"visibility"),_e(n,"visibility",ye.Visible);const i=n.visibility;if(n.visibility=S(()=>{const l=r(n.display);switch(ne.msDisplay){default:case ht.All:return r(i);case ht.Configurable:return r(n.earned)&&!(l!=null&&typeof l=="object"&&"optionsDisplay"in l)?ye.None:r(i);case ht.Incomplete:return r(n.earned)?ye.None:r(i);case ht.None:return ye.None}}),E(n,"style"),E(n,"classes"),E(n,"display"),n[vt]=function(){const{visibility:l,display:o,style:c,classes:f,earned:d,id:g}=this;return{visibility:l,display:o,style:r(c),classes:f,earned:d,id:g}},n.shouldEarn){const l=n;Fe(()=>{var o,c;if(ne.active===A.id&&!l.earned.value&&r(l.visibility)===ye.Visible&&((o=l.shouldEarn)==null?void 0:o.call(l))&&(l.earned.value=!0,(c=l.onComplete)==null||c.call(l),l.display)){const f=r(l.display),d=K(yt(f)?f:f.requirement);Cl(u(D,null,[u("h3",null,[v("Milestone earned!")]),u("div",null,[u(d,null,null)])]))}})}return n})}ae.on("loadSettings",e=>{_e(e,"msDisplay",ht.All)});const Ml=Object.values(ht).map(e=>({label:hi(e),value:e}));la(F(()=>u(Ln,{title:"Show Milestones",options:Ml,"onUpdate:modelValue":e=>ne.msDisplay=e,modelValue:ne.msDisplay},null)));const Il=Symbol("Reset");function Al(e){return Be(()=>{const t=e();return t.id=Vt("reset-"),t.type=Il,t.reset=function(){var i;const n=s=>{s&&typeof s=="object"&&(en in s?s[en].value=s[tn]:!(s instanceof a)&&!be(s)&&Object.values(s).forEach(l=>n(l)))};r(t.thingsToReset).forEach(n),ae.emit("reset",t),(i=t.onReset)==null||i.call(t)},E(t,"thingsToReset"),t})}const un={};ae.on("removeLayer",e=>{var t;(t=un[e.id])==null||t.call(un),un[e.id]=void 0});function El(e){return Be(()=>{const t=e();return t.currentGain==null&&(t.currentGain=S(()=>{let n=t.gainModifier?t.gainModifier.apply(t.scaling.currentGain(t)):t.scaling.currentGain(t);return n=a.floor(n).max(0),r(t.buyMax)||(n=n.min(1)),n})),t.actualGain==null&&(t.actualGain=t.currentGain),t.currentAt==null&&(t.currentAt=S(()=>{let n=t.scaling.currentAt(t);return t.roundUpCost&&(n=a.ceil(n)),n})),t.nextAt==null&&(t.nextAt=S(()=>{let n=t.scaling.nextAt(t);return t.roundUpCost&&(n=a.ceil(n)),n})),t.convert==null&&(t.convert=function(){var s;const n=r(t.currentGain),i=r(t.currentAt);t.gainResource.value=a.add(t.gainResource.value,n),t.spend(n,i),(s=t.onConvert)==null||s.call(t,n)}),t.spend==null&&(t.spend=function(){t.baseResource.value=0}),E(t,"currentGain"),E(t,"actualGain"),E(t,"currentAt"),E(t,"nextAt"),E(t,"buyMax"),_e(t,"buyMax",!0),E(t,"roundUpCost"),_e(t,"roundUpCost",!0),t})}function Pl(e,t){const n=Ie(e),i=Ie(t);return{currentGain(s){let l=r(s.baseResource.value);if(s.costModifier&&(l=s.costModifier.apply(l)),a.lt(l,r(n)))return 0;const o=a.div(l,r(n)).pow(r(i));return o.isNan()?new a(0):o},currentAt(s){let l=r(s.currentGain);return s.gainModifier&&(l=s.gainModifier.revert(l)),l=a.max(0,l).root(r(i)).times(r(n)),s.costModifier&&(l=s.costModifier.revert(l)),l},nextAt(s){let l=a.add(r(s.currentGain),1).floor();return s.gainModifier&&(l=s.gainModifier.revert(l)),l=a.max(0,l).root(r(i)).times(r(n)).max(r(n)),s.costModifier&&(l=s.costModifier.revert(l)),l}}}function $l(e){return El(()=>{const t=e();return _e(t,"buyMax",!1),t.currentGain==null&&(t.currentGain=S(()=>{let n=t.gainModifier?t.gainModifier.apply(t.scaling.currentGain(t)):t.scaling.currentGain(t);return n=a.floor(n).max(t.gainResource.value),r(t.buyMax)||(n=n.min(a.add(t.gainResource.value,1))),n})),t.actualGain==null&&(t.actualGain=S(()=>{let n=a.sub(a.floor(t.scaling.currentGain(t)),t.gainResource.value).max(0);return r(t.buyMax)||(n=n.min(1)),n})),_e(t,"convert",function(){var s;const n=r(t.actualGain),i=r(t.currentAt);t.gainResource.value=t.gainModifier?t.gainModifier.apply(r(t.currentGain)):r(t.currentGain),t.spend(n,i),(s=t.onConvert)==null||s.call(t,n)}),t})}const Tl="workshop",Pt=2,Te=Gt(Tl,function(){const e="Workshop",t="#D66B02",n="#D66B02",i=St(0,"foundation progress"),s=$l(()=>({scaling:Pl(250,1.5),baseResource:se.logs,gainResource:i,roundUpCost:!0,buyMax:!1,spend(x,de){se.logs.value=a.sub(se.logs.value,de)}})),l=Se(()=>({display:F(()=>u(D,null,[u("b",{style:"font-size: x-large"},[v("Build part of the foundation")]),u("br",null,null),u("br",null,null),u("span",{style:"font-size: large"},[v("Cost:")," ",Rn(se.logs,a.gte(s.actualGain.value,1)?s.currentAt.value:s.nextAt.value)," ",se.logs.displayName])])),visibility:()=>X(a.lt(i.value,100)),canClick:()=>a.gte(s.actualGain.value,1)&&a.lt(i.value,100),onClick(){!r(this.canClick)||s.convert()},style:"width: 600px; min-height: unset"})),o=xe(()=>({display:{requirement:"1% Foundation Completed",effectDisplay:"Trees give 5% more logs for each % of foundation completed"},shouldEarn:()=>a.gte(i.value,1)})),c=xe(()=>({display:{requirement:"10% Foundation Completed",effectDisplay:"Cut an additional tree per second for each 5% of foundation completed"},shouldEarn:()=>a.gte(i.value,10),visibility:()=>X(o.earned.value)})),f=xe(()=>({display:{requirement:"20% Foundation Completed",effectDisplay:"Plant an additional tree per second for each 10% of foundation completed"},shouldEarn:()=>a.gte(i.value,20),visibility:()=>X(c.earned.value)})),d=xe(()=>({display:{requirement:"30% Foundation Completed",effectDisplay:"All automatic tree cutting is doubled"},shouldEarn:()=>a.gte(i.value,30),visibility:()=>X(f.earned.value)})),g=xe(()=>({display:{requirement:"40% Foundation Completed",effectDisplay:"All automatic tree planting is doubled"},shouldEarn:()=>a.gte(i.value,40),visibility:()=>X(d.earned.value)})),y=xe(()=>({display:{requirement:"50% Foundation Completed",effectDisplay:"Trees give twice as many logs"},shouldEarn:()=>a.gte(i.value,50),visibility:()=>X(g.earned.value)})),b=xe(()=>({display:{requirement:"75% Foundation Completed",effectDisplay:"The forest gains an extra tree for every 2% of foundation completed"},shouldEarn:()=>a.gte(i.value,75),visibility:()=>X(y.earned.value)})),p=xe(()=>({display:{requirement:"100% Foundation Completed",effectDisplay:"Trees' log gain is now raised to the 1.1th power"},shouldEarn:()=>a.gte(i.value,100),visibility:()=>X(b.earned.value)})),N={logGainMilestone1:o,autoCutMilestone1:c,autoPlantMilestone1:f,autoCutMilestone2:d,autoPlantMilestone2:g,logGainMilestone2:y,morePlantsMilestone1:b,logGainMilestone3:p},C=Rt(()=>({direction:J.Right,width:600,height:25,fillStyle:`backgroundColor: ${n}`,progress:()=>B.day.value===Pt?a.div(i.value,100):1,display:F(()=>B.day.value===Pt?u(D,null,[G(i.value),v("%")]):"")}));return Fe(()=>{B.day.value===Pt&&a.gte(i.value,100)&&(B.loreTitle.value="Day complete!",B.loreBody.value="The workshop complete, Santa once again dismisses you for the day. With a strong foundation, this workshop should suffice for supporting future work toward this impossible mission. Good Job!",B.day.value=Pt+1,B.minimized.value=!1,A.devSpeed=0)}),{name:e,day:Pt,color:t,foundationProgress:i,foundationConversion:s,milestones:N,minWidth:700,display:F(()=>u(D,null,[u("div",null,[B.day.value===Pt?"Complete the foundation to complete the day":`${e} Complete!`]),he(C),u(Re,null,null),he(l),a.lt(i.value,100)?u("div",null,[v("You have "),G(i.value),v("% completed")]):null,u(Re,null,null),Ci(...Object.values(N))]))}}),xl="elves",$t=4,ft=Gt(xl,function(){const e="Elves",t="red",n="#911D21",s=Rt(()=>({direction:J.Right,width:600,height:25,fillStyle:`backgroundColor: ${n}`,progress:()=>B.day.value===$t?a.div(x.value,6).times(.8333333333333334).add(a.div(a.add(ue.coal.value,1).log10(),a.log10(1e9)).clamp(0,1).div(6)):1,display:F(()=>B.day.value===$t?a.lt(x.value,6)?u(D,null,[G(x.value),v("/6 elves")]):u(D,null,[G(ue.coal.value),v("/"),G(1e9),v(" coal")]):"")})),l=Al(()=>({thingsToReset:[se,Te,ue],onReset(){setTimeout(()=>{I.earned.value&&(se.row1Upgrades[4].bought.value=!0,se.row2Upgrades[4].bought.value=!0)})}}));function o(ve){const De=S(()=>a.pow(4,x.value).times(1e6)),fe=Ae(0);function wt(Qe){if(Ze.bought.value){fe.value=a.add(fe.value,Qe);const at=a.recip(Ut.value);for(;a.gte(fe.value,at);)if(r(ve.buyable.canPurchase))ve.buyable.amount.value=a.add(ve.buyable.amount.value,1),fe.value=at.sub(.1);else{fe.value=at;break}}}const Ze=re(()=>({buyProgress:fe,update:wt,resource:ue.coal,cost:De,display:()=>({title:ve.name,description:F(()=>u(D,null,[ve.description,Ze.bought.value?null:u(D,null,[" ",v("Training this elf will require resetting all your progress from days 1-3.")])])),showCost:!Ze.bought.value}),style:"width: 190px",onPurchase:l.reset}));return Ze}const c=o({name:"Holly",description:"Holly will automatically purchase cutters you can afford, without actually spending any logs.",buyable:se.row1Buyables[0]}),f=o({name:"Ivy",description:"Ivy will automatically purchase planters you can afford, without actually spending any logs.",buyable:se.row1Buyables[1]}),d=o({name:"Hope",description:"Hope will automatically purchase forest expanders you can afford, without actually spending any logs.",buyable:se.row1Buyables[2]}),g=[c,f,d],y=o({name:"Jack",description:"Jack will automatically purchase heated cutters you can afford, without actually spending any coal.",buyable:ue.heatedCutters}),b=o({name:"Mary",description:"Mary will automatically purchase heated planters you can afford, without actually spending any coal.",buyable:ue.heatedPlanters}),p=o({name:"Noel",description:"Noel will automatically purchase fertilized soil you can afford, without actually spending any ash.",buyable:ue.moreFertilizer}),N=[y,b,p],C={cuttersElf:c,plantersElf:f,expandersElf:d,heatedCuttersElf:y,heatedPlantersElf:b,fertilizerElf:p},x=S(()=>Object.values(C).filter(ve=>ve.bought.value).length),de=xe(()=>({display:{requirement:"1 Elf Trained",effectDisplay:"Manual cutting and planting can happen twice as often for each trained elf"},shouldEarn:()=>a.gte(x.value,1)})),I=xe(()=>({display:{requirement:"2 Elves Trained",effectDisplay:"Research I & II are't reset after training"},shouldEarn:()=>a.gte(x.value,2),visibility:()=>X(de.earned.value)})),k=xe(()=>({display:{requirement:"3 Elves Trained",effectDisplay:"Coal gain is raised to the 1.25"},shouldEarn:()=>a.gte(x.value,3),visibility:()=>X(I.earned.value)})),z=xe(()=>({display:{requirement:"4 Elves Trained",effectDisplay:"Trees give twice as many logs"},shouldEarn:()=>a.gte(x.value,4),visibility:()=>X(k.earned.value)})),ge=xe(()=>({display:{requirement:"5 Elves Trained",effectDisplay:"Forest is twice as large"},shouldEarn:()=>a.gte(x.value,5),visibility:()=>X(z.earned.value)})),Ee=xe(()=>({display:{requirement:"6 Elves Trained",effectDisplay:"Elves work twice as fast"},shouldEarn:()=>a.gte(x.value,6),visibility:()=>X(ge.earned.value)})),Ce=[de,I,k,z,ge,Ee],bt=Me(()=>[ie(()=>({multiplier:2,description:"6 Elves Trained",enabled:Ee.earned}))]),Ut=S(()=>bt.apply(.1)),[At,_t]=qn(()=>[{title:"Elf Auto-Buy Frequency",modifier:bt,base:10,unit:"/s"}]),Q=T(!1),Ue=F(()=>u(We,{modelValue:Q.value,"onUpdate:modelValue":ve=>Q.value=ve},{header:()=>u("h2",null,[e,v(" Modifiers")]),body:At}));return ae.on("update",ve=>{a.lt(B.day.value,$t)||Object.values(C).forEach(De=>De.update(ve))}),Fe(()=>{B.day.value===$t&&a.gte(x.value,6)&&a.gte(ue.coal.value,1e9)&&(B.loreTitle.value="Day complete!",B.loreBody.value="The workshop now hums with the bustling elves working everything. They can take it from here - you deserve a break after such a long day! Good Job!",B.day.value=$t+1,B.minimized.value=!1,A.devSpeed=0)}),{name:e,color:t,elves:C,totalElves:x,milestones:Ce,generalTabCollapsed:_t,minWidth:700,display:F(()=>u(D,null,[u("div",null,[B.day.value===$t?`Reach ${G(6)} trained elves and ${G(1e9)} ${ue.coal.displayName} to complete the day`:`${e} Complete!`," ",v("-")," ",u("button",{class:"button",style:"display: inline-block;",onClick:()=>Q.value=!0},[v("Check Modifiers")])]),he(s),he(Ue),u(Re,null,null),u("div",{style:"width: 600px"},[Oe(...g),Oe(...N)]),Ci(...Ce)]))}}),Fl="coal",Tt=3,ue=Gt(Fl,function(){const e="Coal",t="#151716",n="#B2BeB5",i="var(--foreground)",s=St(0,"coal"),l=Ti(s),o=St(0,"ash"),c=1e7,f=Rt(()=>({direction:J.Right,width:600,height:25,fillStyle:`backgroundColor: ${t}`,progress:()=>B.day.value===Tt?a.log10(l.value).div(Math.log10(c)):1,display:F(()=>B.day.value===Tt?u(D,null,[G(l.value),v("/"),G(c)]):"")})),d=Ae(0),g=S(()=>a.times(d.value,1e3)),y=S(()=>a.times(d.value,.1)),b=S(()=>a.times(d.value,50)),p=et(()=>({resource:se.logs,cost(){return a.times(Ce.amount.value,10).plus(this.amount.value).pow(1.5).times(1e4)},display:F(()=>u(D,null,[u("h3",null,[v("Small Fire")]),u("br",null,null),v("Burn 1000 logs for 0.1 coal and 50 ash"),u("br",null,null),u("br",null,null),v("Currently:"),u("br",null,null),v("-"),te(g.value),v(" logs/sec"),u("br",null,null),v("+"),te(y.value),v(" coal/sec"),u("br",null,null),v("+"),te(b.value),v(" ash/sec"),u("br",null,null),u("br",null,null),v("Cost: "),G(r(p.cost)),v(" "),p.resource.displayName])),onPurchase(){d.value=a.add(d.value,1)},style:{color:i,width:"160px"}})),N=Se(()=>({display:"0",style:{minHeight:"20px",width:"40px",color:i},canClick(){return a.gt(d.value,0)},onClick(){d.value=0}})),C=Se(()=>({display:"-",style:{minHeight:"20px",width:"40px",color:i},canClick(){return a.gt(d.value,0)},onClick(){d.value=a.sub(d.value,1)}})),x=Se(()=>({display:"+",style:{minHeight:"20px",width:"40px",color:i},canClick(){return a.lt(d.value,p.amount.value)},onClick(){d.value=a.add(d.value,1)}})),de=Se(()=>({display:"Max",style:{minHeight:"20px",width:"40px",color:i},canClick(){return a.lt(d.value,p.amount.value)},onClick(){d.value=p.amount.value}})),I=St(p.amount,"small fires"),k=Ae(0),z=S(()=>a.times(k.value,1e4)),ge=S(()=>a.times(k.value,10)),Ee=S(()=>a.times(k.value,1e3)),Ce=et(()=>({resource:I,cost:10,display:F(()=>u(D,null,[u("h3",null,[v("Bonfire")]),u("br",null,null),v("Burn 10,000 logs for 10 coal and 1000 ash"),u("br",null,null),u("br",null,null),v("Currently:"),u("br",null,null),v("-"),te(z.value),v(" logs/sec"),u("br",null,null),v("+"),te(ge.value),v(" coal/sec"),u("br",null,null),v("+"),te(Ee.value),v(" ash/sec"),u("br",null,null),u("br",null,null),v("Cost: "),G(r(Ce.cost)),v(" "),Ce.resource.displayName])),onPurchase(V){d.value=a.sub(d.value,V).max(0),k.value=a.add(k.value,1)},style:{color:i,width:"160px"}})),bt=Se(()=>({display:"0",style:{minHeight:"20px",width:"40px",color:i},canClick(){return a.gt(k.value,0)},onClick(){k.value=0}})),Ut=Se(()=>({display:"-",style:{minHeight:"20px",width:"40px",color:i},canClick(){return a.gt(k.value,0)},onClick(){k.value=a.sub(k.value,1)}})),At=Se(()=>({display:"+",style:{minHeight:"20px",width:"40px",color:i},canClick(){return a.lt(k.value,Ce.amount.value)},onClick(){k.value=a.add(k.value,1)}})),_t=Se(()=>({display:"Max",style:{minHeight:"20px",width:"40px",color:i},canClick(){return a.lt(k.value,Ce.amount.value)},onClick(){k.value=Ce.amount.value}})),Q=Ae(0),Ue=S(()=>a.times(Q.value,1e6)),ve=S(()=>a.times(Q.value,1e4)),De=S(()=>a.times(Q.value,1e4)),fe=et(()=>({resource:se.logs,cost(){return a.pow(1.1,this.amount.value).times(1e7)},display:F(()=>u(D,null,[u("h3",null,[v("Charcoal Kiln")]),u("br",null,null),v("Burn 1,000,000 logs for 10,000 coal and 10,000 ash"),u("br",null,null),u("br",null,null),v("Currently:"),u("br",null,null),v("-"),te(Ue.value),v(" logs/sec"),u("br",null,null),v("+"),te(ve.value),v(" coal/sec"),u("br",null,null),v("+"),te(De.value),v(" ash/sec"),u("br",null,null),u("br",null,null),v("Cost: "),G(r(fe.cost)),v(" "),fe.resource.displayName])),onPurchase(){Q.value=a.add(Q.value,1)},style:{color:i,width:"160px"}})),wt=Se(()=>({display:"0",style:{minHeight:"20px",width:"40px",color:i},canClick(){return a.gt(Q.value,0)},onClick(){Q.value=0}})),Ze=Se(()=>({display:"-",style:{minHeight:"20px",width:"40px",color:i},canClick(){return a.gt(Q.value,0)},onClick(){Q.value=a.sub(Q.value,1)}})),Qe=Se(()=>({display:"+",style:{minHeight:"20px",width:"40px",color:i},canClick(){return a.lt(Q.value,fe.amount.value)},onClick(){Q.value=a.add(Q.value,1)}})),at=Se(()=>({display:"Max",style:{minHeight:"20px",width:"40px",color:i},canClick(){return a.lt(Q.value,fe.amount.value)},onClick(){Q.value=fe.amount.value}})),lt=re(()=>({resource:s,cost:5,display:{title:"Warmer Cutters",description:"Cut down twice as many trees/s"},style:{color:i}})),rt=re(()=>({resource:s,cost:5,display:{title:"Warmer Planters",description:"Plant twice as many trees/s"},style:{color:i}})),Pe=re(()=>({resource:o,cost:5e3,display:{title:"Ashy Soil",description:"Trees give 25% more logs"},style:{color:i}})),Ye=re(()=>({resource:I,cost:10,display:{title:"Bigger Fires",description:"Put all those fires together into a larger blaze"},onPurchase(){I.value=a.add(I.value,this.cost)},style:{color:i}})),ot=[lt,rt,Pe,Ye],$e=re(()=>({resource:s,cost:250,display:{title:"Dedicated Cutter Heaters",description:"Double the bonus from Heated Cutters"},style:{color:i},visibility:()=>X(Ye.bought.value)})),Ht=re(()=>({resource:s,cost:250,display:{title:"Dedicated Planter Heaters",description:"Double the bonus from Heated Planters"},style:{color:i},visibility:()=>X(Ye.bought.value)})),Ke=re(()=>({canAfford(){return a.gte(se.logs.value,1e5)&&a.gte(o.value,1e5)},onPurchase(){se.logs.value=a.sub(se.logs.value,1e5),o.value=a.sub(o.value,1e5)},display:F(()=>u(D,null,[u("h3",null,[v("Mulched Soil")]),u("br",null,null),v("Double the bonus from Fertilized Soil"),u("br",null,null),u("br",null,null),v("Cost: "),G(1e5),v(" "),se.logs.displayName,u("br",null,null),G(1e5),v(" "),o.displayName])),style:{color:i},visibility:()=>X(Ye.bought.value)})),jt=re(()=>({resource:se.logs,cost:1e7,display:{title:"Efficient Fires",description:"Move the fires underground to keep the coal from turning to ash"},style:{color:i},visibility:()=>X(Ye.bought.value)})),Sn=[$e,Ht,Ke,jt],ut=et(()=>({resource:s,cost(){let V=this.amount.value;return a.gte(V,50)&&(V=a.pow(V,2).div(50)),a.gte(V,200)&&(V=a.pow(V,2).div(200)),a.gte(V,2e6)&&(V=a.pow(V,2).div(2e6)),a.add(V,1).pow(2.5).times(10)},display:{title:"Heated Cutters",description:"Even warmer cutters cut down trees faster",effectDisplay:F(()=>u(D,null,[v("Cutters cut down trees "),te(rn.value),v("x faster")]))},style:{color:i},visibility:()=>X(lt.bought.value)})),Et=et(()=>({resource:s,cost(){let V=this.amount.value;return a.gte(V,50)&&(V=a.pow(V,2).div(50)),a.gte(V,200)&&(V=a.pow(V,2).div(200)),a.gte(V,2e6)&&(V=a.pow(V,2).div(2e6)),a.add(V,1).pow(2.5).times(10)},display:{title:"Heated Planters",description:"Even warmer planters plant trees faster",effectDisplay:F(()=>u(D,null,[v("Planters plant trees "),te(Wt.value),v("x faster")]))},style:{color:i},visibility:()=>X(rt.bought.value)})),ct=et(()=>({resource:o,cost(){let V=this.amount.value;return a.gte(V,50)&&(V=a.pow(V,2).div(50)),a.gte(V,200)&&(V=a.pow(V,2).div(200)),a.gte(V,2e6)&&(V=a.pow(V,2).div(2e6)),a.add(V,1).pow(1.5).times(5e4)},display:{title:"Fertilized Soil",description:"More fertilizer helps trees grow bigger",effectDisplay:F(()=>u(D,null,[v("Trees give "),te(jn.value),v("x more logs")]))},style:{color:i},visibility:()=>X(Pe.bought.value)})),zt=[ut,Et,ct],Mn=Me(()=>[ee(()=>({addend(){return a.times(ut.amount.value,.25)},description:"Heated Cutters",enabled(){return a.gt(ut.amount.value,0)}})),ie(()=>({multiplier:2,description:"Dedicated Cutter Heaters",enabled:$e.bought}))]),rn=S(()=>Mn.apply(1)),O=Me(()=>[ee(()=>({addend(){return a.times(Et.amount.value,.25)},description:"Heated Planters",enabled(){return a.gt(Et.amount.value,0)}})),ie(()=>({multiplier:2,description:"Dedicated Planter Heaters",enabled:Ht.bought}))]),Wt=S(()=>O.apply(1)),In=Me(()=>[ee(()=>({addend(){return a.times(ct.amount.value,.25)},description:"Fertilized Soil",enabled(){return a.gt(ct.amount.value,0)}})),ie(()=>({multiplier:2,description:"Mulched Soil",enabled:Ke.bought}))]),jn=S(()=>In.apply(1)),zn=Me(()=>[ee(()=>({addend(){return y.value},description:"Small Fires",enabled(){return a.gt(d.value,0)}})),ee(()=>({addend(){return ge.value},description:"Bonfires",enabled(){return a.gt(k.value,0)}})),ee(()=>({addend(){return ve.value},description:"Charcoal Kilns",enabled(){return a.gt(Q.value,0)}})),xi(()=>({exponent:1.25,description:"3 Elves Trained",enabled:ft.milestones[2].earned}))]),Vi=S(()=>zn.apply(0)),Wn=Me(()=>[ee(()=>({addend(){return b.value},description:"Small Fires",enabled(){return a.gt(d.value,0)}})),ee(()=>({addend(){return Ee.value},description:"Bonfires",enabled(){return a.gt(k.value,0)}})),ee(()=>({addend(){return De.value},description:"Charcoal Kilns",enabled(){return a.gt(Q.value,0)}}))]),Li=S(()=>Wn.apply(0)),Qn=Me(()=>[ee(()=>({addend(){return a.negate(g.value)},description:"Small Fires",enabled(){return a.gt(d.value,0)}})),ee(()=>({addend(){return a.negate(z.value)},description:"Bonfires",enabled(){return a.gt(k.value,0)}})),ee(()=>({addend(){return a.negate(Ue.value)},description:"Charcoal Kilns",enabled(){return a.gt(Q.value,0)}}))]),Kn=S(()=>Qn.apply(0)),[Gi,Ui]=qn(()=>[{title:"Log Consumption",modifier:Qn,base:0,visible(){return a.gt(d.value,0)||a.gt(k.value,0)||a.gt(Q.value,0)}},{title:"Coal Gain",modifier:zn,base:0,visible(){return a.gt(d.value,0)||a.gt(k.value,0)||a.gt(Q.value,0)}},{title:"Ash Gain",modifier:Wn,base:0,visible(){return a.gt(d.value,0)||a.gt(k.value,0)||a.gt(Q.value,0)}}]),An=T(!1),Hi=F(()=>u(We,{modelValue:An.value,"onUpdate:modelValue":V=>An.value=V},{header:()=>u("h2",null,[e,v(" Modifiers")]),body:Gi}));return ae.on("update",V=>{a.lt(B.day.value,Tt)||a.times(V,Kn.value).negate().gt(se.logs.value)||(se.logs.value=a.times(V,Kn.value).plus(se.logs.value),s.value=a.times(V,Vi.value).plus(s.value),o.value=a.times(V,Li.value).plus(o.value))}),Fe(()=>{B.day.value===Tt&&a.gte(l.value,c)&&(B.loreTitle.value="Day complete!",B.loreBody.value="Santa looks at all the coal you've gathered and tells you you've done well! He says you should take the rest of the day off so you're refreshed for tomorrow's work. Good Job!",B.day.value=Tt+1,B.minimized.value=!1,A.devSpeed=0)}),{name:e,color:t,coal:s,totalCoal:l,ash:o,activeFires:d,buildFire:p,activeBonfires:k,buildBonfire:Ce,activeKilns:Q,buildKiln:fe,warmerCutters:lt,warmerPlanters:rt,basicFertilizer:Pe,unlockBonfire:Ye,dedicatedCutters:$e,dedicatedPlanters:Ht,betterFertilizer:Ke,unlockKiln:jt,heatedCutters:ut,heatedPlanters:Et,moreFertilizer:ct,computedHeatedCutterEffect:rn,computedHeatedPlanterEffect:Wt,computedFertilizerEffect:jn,generalTabCollapsed:Ui,minWidth:700,display:F(()=>u(D,null,[u("div",null,[B.day.value===Tt?`Reach ${G(c)} ${s.displayName} to complete the day`:`${e} Complete!`," ",v("-")," ",u("button",{class:"button",style:"display: inline-block;",onClick:()=>An.value=!0},[v("Check Modifiers")])]),he(f),he(Hi),u(Re,null,null),u(Jt,{resource:s,color:t,style:"margin-bottom: 0",effectDisplay:void 0},null),u(Re,null,null),u(Jt,{resource:o,color:n,style:"margin-bottom: 0",effectDisplay:void 0},null),u(Re,null,null),u(Ni,null,{default:()=>[u(dn,null,{default:()=>[he(p),u("div",null,[G(d.value),v("/"),G(p.amount.value)]),Oe(N,C,x,de)]}),Ye.bought.value?u(D,null,[u(Re,null,null),u(dn,null,{default:()=>[he(Ce),u("div",null,[G(k.value),v("/"),G(Ce.amount.value)]),Oe(bt,Ut,At,_t)]})]):void 0,jt.bought.value?u(D,null,[u(Re,null,null),u(dn,null,{default:()=>[he(fe),u("div",null,[G(Q.value),v("/"),G(fe.amount.value)]),Oe(wt,Ze,Qe,at)]})]):void 0]}),u(Re,null,null),Oe(...ot),Oe(...Sn),Oe(...zt)]))}}),Bl="trees",xt=1,se=Gt(Bl,function(){const e="Trees",t="#4BDC13",n="green",i=St(0,"logs"),s=Ti(i),l=St(0,"saplings"),o=1e4,c=Me(()=>[ee(()=>({addend:()=>a.times(Ce.amount.value,10),description:"Expand Forest",enabled:k.bought})),ee(()=>({addend:()=>a.div(Te.foundationProgress.value,2),description:"75% Foundation Completed",enabled:Te.milestones.morePlantsMilestone1.earned})),ie(()=>({multiplier:2,description:"5 Elves Trained",enabled:ft.milestones[4].earned}))]),f=St(S(()=>a.sub(c.apply(10),l.value)),"trees"),d=re(()=>({resource:i,cost:10,display:{title:"Wooden Fingers",description:"Cut down an additional tree per click"}})),g=re(()=>({resource:i,cost:10,display:{title:"Leafy Fingers",description:"Plant an additional tree per click"}})),y=re(()=>({resource:i,cost:25,display:{title:"Automated Knives",description:"Cut down a tree every second"}})),b=re(()=>({resource:i,cost:25,display:{title:"Automated Spade",description:"Plant a tree every second"}})),p=re(()=>({resource:i,cost:40,display:{title:"Research I",description:"Trees give 25% more logs, and unlock more upgrades"}})),N=[d,g,y,b,p],C=re(()=>({resource:i,cost:50,visibility:()=>X(p.bought.value),display:{title:"Sharper Fingers",description:"Manually cut trees twice as often"}})),x=re(()=>({resource:i,cost:50,visibility:()=>X(p.bought.value),display:{title:"Greener Fingers",description:"Manually Plant trees twice as often"}})),de=re(()=>({resource:i,cost:150,visibility:()=>X(p.bought.value),display:{title:"Smart Knives",description:"Each time you manually chop trees, gain 1s of automatic tree chopping production"}})),I=re(()=>({resource:i,cost:150,visibility:()=>X(p.bought.value),display:{title:"Smart Spades",description:"Each time you manually plant trees, gain 1s of automatic tree planting production"}})),k=re(()=>({resource:i,cost:300,visibility:()=>X(p.bought.value),display:{title:"Research II",description:"Trees give 25% more logs, and unlock repeatable purchases"}})),z=[C,x,de,I,k],ge=et(()=>({resource:i,cost(){let O=this.amount.value;return a.gte(O,50)&&(O=a.pow(O,2).div(50)),a.gte(O,200)&&(O=a.pow(O,2).div(200)),a.gte(O,2e6)&&(O=a.pow(O,2).div(2e6)),a.times(100,O).add(200)},display:{title:"Generic Cutters",description:"Each cutter cuts down 1 tree/s"},visibility:()=>X(k.bought.value)})),Ee=et(()=>({resource:i,cost(){let O=this.amount.value;return a.gte(O,50)&&(O=a.pow(O,2).div(50)),a.gte(O,200)&&(O=a.pow(O,2).div(200)),a.gte(O,2e6)&&(O=a.pow(O,2).div(2e6)),a.times(100,O).add(200)},display:{title:"Generic Planters",description:"Each planter plants 0.5 trees/s"},visibility:()=>X(k.bought.value)})),Ce=et(()=>({resource:i,cost(){let O=this.amount.value;return a.gte(O,100)&&(O=a.pow(O,2).div(100)),a.gte(O,1e5)&&(O=a.pow(O,2).div(1e5)),a.pow(a.add(O,1),1.5).times(500)},display:{title:"Expand Forest",description:"Add 10 trees to the forest"},visibility:()=>X(k.bought.value)})),bt=[ge,Ee,Ce],Ut=Rt(()=>({direction:J.Right,width:600,height:25,fillStyle:`backgroundColor: ${n}`,progress:()=>B.day.value===xt?a.log10(s.value).div(Math.log10(o)):1,display:F(()=>B.day.value===xt?u(D,null,[G(s.value),v("/"),G(o)]):"")})),At=Me(()=>[ee(()=>({addend:1,description:"Wooden Fingers",enabled:d.bought})),ee(()=>({addend:De,description:"Smart Knives",enabled:de.bought}))]),_t=S(()=>At.apply(1)),Q=Me(()=>[ie(()=>({multiplier:.5,description:"Sharper Fingers",enabled:C.bought})),ie(()=>({multiplier:()=>a.pow(.5,ft.totalElves.value),description:"1 Elf Trained",enabled:ft.milestones[0].earned}))]),Ue=S(()=>Q.apply(1)),ve=Me(()=>[ee(()=>({addend:1,description:"Automated Knives",enabled:y.bought})),ee(()=>({addend:ge.amount,description:"Generic Cutters",enabled:k.bought})),ee(()=>({addend:()=>a.div(Te.foundationProgress.value,5).floor(),description:"10% Foundation Completed",enabled:Te.milestones.autoCutMilestone1.earned})),ie(()=>({multiplier:2,description:"30% Foundation Completed",enabled:Te.milestones.autoCutMilestone2.earned})),ie(()=>({multiplier:2,description:"Warmer Cutters",enabled:ue.warmerCutters.bought})),ie(()=>({multiplier:ue.computedHeatedCutterEffect,description:"Heated Cutters",enabled:()=>a.gt(ue.heatedCutters.amount.value,0)}))]),De=S(()=>ve.apply(0)),fe=Me(()=>[ee(()=>({addend:1,description:"Leafy Fingers",enabled:g.bought})),ee(()=>({addend:lt,description:"Smart Spades",enabled:I.bought}))]),wt=S(()=>fe.apply(1)),Ze=Me(()=>[ie(()=>({multiplier:.5,description:"Greener Fingers",enabled:x.bought})),ie(()=>({multiplier:()=>a.pow(.5,ft.totalElves.value),description:"1 Elf Trained",enabled:ft.milestones[0].earned}))]),Qe=S(()=>Ze.apply(1)),at=Me(()=>[ee(()=>({addend:1,description:"Automated Spade",enabled:b.bought})),ee(()=>({addend:()=>a.div(Ee.amount.value,2),description:"Generic Planters",enabled:k.bought})),ee(()=>({addend:()=>a.div(Te.foundationProgress.value,10).floor(),description:"20% Foundation Completed",enabled:Te.milestones.autoPlantMilestone1.earned})),ie(()=>({multiplier:2,description:"40% Foundation Completed",enabled:Te.milestones.autoPlantMilestone2.earned})),ie(()=>({multiplier:2,description:"Warmer Planters",enabled:ue.warmerPlanters.bought})),ie(()=>({multiplier:ue.computedHeatedPlanterEffect,description:"Heated Planters",enabled:()=>a.gt(ue.heatedPlanters.amount.value,0)}))]),lt=S(()=>at.apply(0)),rt=Me(()=>[ie(()=>({multiplier:1.25,description:"Research I",enabled:p.bought})),ie(()=>({multiplier:1.25,description:"Research II",enabled:k.bought})),ie(()=>({multiplier:()=>a.div(Te.foundationProgress.value,20).add(1),description:"1% Foundation Completed",enabled:Te.milestones.logGainMilestone1.earned})),ie(()=>({multiplier:2,description:"50% Foundation Completed",enabled:Te.milestones.logGainMilestone2.earned})),ie(()=>({multiplier:1.25,description:"Ashy Soil",enabled:ue.basicFertilizer.bought})),ie(()=>({multiplier:ue.computedFertilizerEffect,description:"Fertilized Soil",enabled:()=>a.gt(ue.moreFertilizer.amount.value,0)})),ie(()=>({multiplier:2,description:"4 Elves Trained",enabled:ft.milestones[3].earned})),xi(()=>({exponent:1.1,description:"100% Foundation Completed",enabled:Te.milestones.logGainMilestone3.earned}))]),Pe=Ae(0),Ye=Rt(()=>({direction:J.Right,width:100,height:10,style:"margin-top: 8px",baseStyle:"margin-top: 0",fillStyle:"margin-top: 0; transition-duration: 0s",progress:()=>a.div(Pe.value,Ue.value)})),ot=Se(()=>({display:{title:"Cut trees",description:F(()=>u(D,null,[v("Cut down up to "),G(a.floor(_t.value))," ",v("tree"),a.eq(_t.value,1)?"":"s",v(" at once!"),u("br",null,null),he(Ye)]))},style:{minHeight:"80px"},canClick:()=>a.gte(f.value,1)&&a.gte(Pe.value,Ue.value),onClick(){if(a.lt(Pe.value,Ue.value))return;const O=a.floor(a.min(f.value,a.times(_t.value,a.div(Pe.value,Ue.value).floor())));i.value=a.add(i.value,rt.apply(O)),l.value=a.add(l.value,O),Pe.value=0}})),$e=Ae(0),Ht=Rt(()=>({direction:J.Right,width:100,height:10,style:"margin-top: 8px",baseStyle:"margin-top: 0",fillStyle:"margin-top: 0; transition-duration: 0s",progress:()=>a.div($e.value,Qe.value)})),Ke=Se(()=>({display:{title:"Plant trees",description:F(()=>u(D,null,[v("Plant up to "),G(a.floor(wt.value))," ",v("tree"),a.eq(wt.value,1)?"":"s",v(" at once!"),u("br",null,null),he(Ht)]))},style:{minHeight:"80px"},canClick:()=>a.gte(l.value,1)&&a.gte($e.value,Qe.value),onClick(){if(a.lt($e.value,Qe.value))return;const O=a.floor(a.min(l.value,a.times(wt.value,a.div($e.value,Qe.value).floor())));l.value=a.sub(l.value,O),$e.value=0}})),[jt,Sn]=qn(()=>[{title:"Logs per Tree",modifier:rt,base:1,visible:p.bought},{title:"Manual Cutting Amount",modifier:At,base:1,visible:d.bought,unit:"/click"},{title:"Manual Cutting Cooldown",modifier:Q,base:1,visible:d.bought,unit:"s"},{title:"Manual Planting Amount",modifier:fe,base:1,visible:g.bought,unit:"/click"},{title:"Manual Planting Cooldown",modifier:Ze,base:1,visible:g.bought,unit:"s"},{title:"Auto Cutting Amount",modifier:ve,base:0,visible:y.bought,unit:"/s"},{title:"Auto Planting Amount",modifier:at,base:0,visible:b.bought,unit:"/s"},{title:"Forest Size",modifier:c,base:10,visible:k.bought}]),ut=T(!1),Et=F(()=>u(We,{modelValue:ut.value,"onUpdate:modelValue":O=>ut.value=O},{header:()=>u("h2",null,[e,v(" Modifiers")]),body:jt}));ae.on("update",O=>{if(a.lt(B.day.value,xt))return;a.gte(Pe.value,Ue.value)?Pe.value=Ue.value:(Pe.value=a.add(Pe.value,O),ot.isHolding.value&&ot.onClick()),a.gte($e.value,Qe.value)?$e.value=Qe.value:($e.value=a.add($e.value,O),Ke.isHolding.value&&Ke.onClick());const Wt=a.min(f.value,a.times(De.value,O));i.value=a.add(i.value,rt.apply(Wt)),l.value=a.add(l.value,Wt);const In=a.min(l.value,a.times(lt.value,O));l.value=a.sub(l.value,In)}),Fe(()=>{B.day.value===xt&&a.gte(s.value,o)&&(B.loreTitle.value="Day complete!",B.loreBody.value="Santa looks at all the wood you've gathered and tells you you've done well! He says you should take the rest of the day off so you're refreshed for tomorrow's work. Good Job!",B.day.value=xt+1,B.minimized.value=!1,A.devSpeed=0)});const ct=S(()=>a.sub(De.value,lt.value)),zt=S(()=>a.sub(lt.value,De.value)),Mn=ii(()=>({key:"c",description:'Press the "Cut trees" button.',onPress:()=>{ot.canClick.value&&ot.onClick()}})),rn=ii(()=>({key:"p",description:'Press the "Plant trees" button.',onPress:()=>{Ke.canClick.value&&Ke.onClick()}}));return{name:e,color:t,logs:i,totalLogs:s,trees:f,saplings:l,cutTree:ot,plantTree:Ke,cutTreeHK:Mn,plantTreeHK:rn,row1Upgrades:N,row2Upgrades:z,row1Buyables:bt,manualCutProgress:Pe,manualPlantProgress:$e,generalTabCollapsed:Sn,minWidth:700,display:F(()=>u(D,null,[u("div",null,[B.day.value===xt?`Reach ${G(1e4)} ${i.displayName} to complete the day`:`${e} Complete!`," ",v("-")," ",u("button",{class:"button",style:"display: inline-block;",onClick:()=>ut.value=!0},[v("Check Modifiers")])]),he(Ut),he(Et),u(Re,null,null),u(Jt,{resource:i,color:t,style:"margin-bottom: 0",effectDisplay:a.gt(De.value,0)?`+${te(rt.apply(De.value))}/s`:void 0},null),u(Jt,{resource:l,color:n,style:"margin-bottom: 0",effectDisplay:{[-1]:`${G(ct.value)}/s`,0:void 0,1:`+${G(ct.value)}/s`}[a.compare(ct.value,0)]},null),u(Jt,{resource:f,color:n,style:"margin-bottom: 0",effectDisplay:{[-1]:`${G(zt.value)}/s`,0:void 0,1:`+${G(zt.value)}/s`}[a.compare(zt.value,0)]},null),u(Re,null,null),Oe(ot,Ke),u("div",null,[v("Tip: You can hold down on actions to perform them automatically")]),u(Re,null,null),Oe(...N),Oe(...z),Oe(...bt)]))}});var Dl="./assets/tree.35808197.png",Ol="./assets/sws.714ad454.png",Rl="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMgAAADICAYAAACtWK6eAAAACXBIWXMAAFxGAABcRgEUlENBAAAAG3RFWHRTb2Z0d2FyZQBDZWxzeXMgU3R1ZGlvIFRvb2zBp+F8AAAMuElEQVR42u3dO4zkSAEG4L/Kr5me6dl1QkJAjkDiElJISAiO7CQSyCBHQis08QQrXUJISExKxCNBguQICJCIkBAZOqlmH0LbPW27CKa78XjtabddZVeV/z/ZXe12r11V39TDdllorcEwTHsEgTAMgTAMgTAMgTAMgTAMgTAMgTz5z4Ro/c+01oJVwSwaSBcOQmEWD6QPDiJhFgnkHBxEwiwKyBAcBMIQCIEwBDIcCJEwBEIgDIEQCEMgBMIQCIEwBOIQECJhggfCXoQhEAJhCIRAGAIhEIbxCQiRMARCIMySgXCYxRAIgTAEQiAMgRAIw/gEhEiY4IGwF2EIhEAYAiEQhkAIhGF8AkIkDIEQCLNkIBxmMQRCIAyBEAhDIATCMD4BIRImeCDsRRgCIRCGQAiEIRACYQjEJyBEwhAIgTBLBsJhFkMgBMIQCIEwBEIgDIH4BIRImOCBsBdhCIRAGAIhEIZACIQhEE7UGYZAGMYPIBxmMQRCIAyBEAhDIATCEAgn6gzjEBD2IgyBEAhDIATCEAiBMATCiTrDEAjD+AGEwyyGQAiEIRACYQiEQBgC4USdYRwCwl6EIRACYQiEQBgCIRCGQDhRZxgCYRg/gHCYxRAIgTAEQiAMgRAIQyCcqDME4hAQ9iIMgRAIQyAEwhCIs0CGfgeBMUEDsRGiIRD3DsoxJMRCIARCJK318Nz5ttVTaOVDIERitex9LysngRBJeGXua3k5C4RIwixr38qMQAhk8rL2qdw4xCKS2crah7LjJJ1IZi1v18uOFwoJZPYyz/P820qpLwgkQBwhIHGh3PM8/41S6jMCmaiSbm9fnfXv7+5eLxKJSz+U8jz/m1LqEwKxUEnngqhlB0AAkPtfi7u71wmBzAJkB+BzAL9USv2HQObHUQCo9jB0rTdJl9CLuDikzfN8A+AHSqnfEYiBShqBowJQ7mEcGvXh9zp0JKZw7H/qxwBwf38vDH3n35VS31w8EAM46o37nJR7IM3P16EMRuL80uXAcs/zvM/nxP39fTALILMBmRGHrgFpw1H/d+Lu7nXsK5JmGWutxZhyPwHko/M1DWWOcvUSyO3tq3rjPrfAqlrv0fX5Iz7fgNicV+R5fuxd9+Vz8hxtIJmyfGcBMhJH2VI5fQtL14ZYuu9nXUcyxWR7j6NZjr3Oz2ckkwMxgKOtYsSZSIoeFfykEQxBYrsCp1qFauAYFF+ReAPk9vbVrmVYJQYg0bVhlujTW9zevtq5dG1k6uVZE0BsIrEJZVIgI3HgxLCqfi2jAHBo0LLja4uxQ6g5Ks5XHL4i8QXIA9pXmXTHSoro+PeHv4vxuIw7yRzBRMXNcVHPNA7bQKz8QJoKyMjeQ7c09CYKWfv7LhyHHiOZsqGNrbRQcBCI4UquzTvaeouuIVcTSP1zwuZwykbFhYTDRySTABnRe1QNHBrdV79PZi4cQyttZhxDL8QGhcRZIHscBwBVA0l9Ut61kqX3KCI4knMrbUogtnuNqcF4A2Rk79HsIQ4XCWXHfOTQU0g4mHMqbUk4bKExsjjiIpAOHJ3l4DqMWkP8XCn18x5l9msAP1oiCpNQlgDk5DxjqqVagw3zT0qp77SU0wrAdwF8CuCnBsq9OJS9lBJpmsrdblcB0HEci4uLi8RmA+0LsOu7m5+fC4lVIANxoDEhb4OiXe8tTjScPwP4sVLqn/ty+iqAvwD4F4AbAN8a+v1SygKAllKiLMt6XUAIgTiORZqmMo5jaQPGOVhOfb8JJCED6UTiW6/RUukawKdKqd8KIb4B4PcAHgB8ZT/Puhrw1UWtzMVj29BHHFEUIU1TmWVZr0ULG6tM9Qbf9/uHfMYkEqeAnHo60MTGClNVSh8kWuufvXnz5ocAPsH/V+vSAeVcPG0P+ohCSikA6Kqq9Hq9TufCYaAuNAY+jOUkEAO9x+w4bA853r17V1ZVVWito9rw8axlaSllUVUVhHj8eBw/XuqpqkoLIbBer8+6a8AlHG1AhhxjnufXSqn/eg3EBRx9J5djG1Ge59hsNtXDw4Muy1I0hpHRmeVcRFEEIQS01ojjWMRxLJIkGTRHcw1IY1iKIb1InudfAvi+UuqvwQFxDYephpRlWVkUBfZAjh3CkOFVkiQyyzIRx/GouZmLOBpAxJjjzPP8a0qpfwc1xHJhaGWjUa1Wq+rDhw/Yl//gFbn9PANJkiDLMoQGpOvWl6km7E4DcR3HmMqK47gqimIUjn05I4oiXFxcIEmSoHA8VzdjjvesOxpcXcUyjSNN0w9XV1eXzYI9A0fbLfd638DFXA1MCAEpJW5ubkLuPYwec57nN0qp994B2SM57Ek1+kKglHKzX/LUUkq9Xq9XI76ueUdxs7JmuylSSokXL14QiIVexEUgFYBqzK3pQoiN1loeGrOUUqdpqi8vL1cjcOhnehQA0Pf397PcTp9lGVarVVBA9ntwtd2xbeyY+yBx7l6s29tX5dBb1GswjkunQogqSRJcXV1djG0seZ5XDSD1JdpZgAghsD+/SYHYmBs0cDw5TQIZn+3jfyeOJ34YWt3c3GSmGkoDyZOeZOph1mH+kWXZ5CtYNq4XPbNzo5hrmBUKkK14fOu9kFKiqqoDkCrLMnF5eZmYbCQtPQn2E3U5B5CxE3RbQPp+f489f8VccxGnH7k9I81tgQ6/VnmeJ6YbSEsvUv+eyZBEUWQEx8AyMHkqeiiOsVCWBOSj59SjKNI3NzexhcbRtYnEpEBevnx5vAcrUCDC5jksCUhzK1EhhNBxHIvr62srzz109SJLADICR9eKlDaBw1sgEyApmwUrpUQURTgFZCCOrnPRPgPpuUhhqqcQzwARtpEvEYhoTmDTNBWr1cr4CshzQKbqRQ6Tc9NAniuXATiab+/CM0B6v1JhynmIF1uP9kh9k4djpcRxjPV6bXwN/cSqyyS9iOkJ+gQx1ktM2YuECKTZiIQpGH2AmHpP34lyRBRFWK/XvuKwCsVbIBaRVF0FnSQJdrudsUo4tWZvG8hh84U0TXF5eekyCHHizwQyIRBjy4RnAPloRWaK3qPH8bnYW1iZkAcJxAKS5uvArO0p2+g9nAQyM5I+y7Xe9B4hANG2Ctq1oZVHUE6tVh3LqnbHLoEYRjLZioivOBwCcrKMTB7ngHvKcqXUG+eAGEQyKw6XgcyARA8tn7neg5jn+deVUv8IEYj1XF9fI0kS7SuOGcDoMeUzx94AeZ7/QSn1PSeBuIwkSRJUVYU4jrFarXQoQCxi0SbKY8wxjbgz4hcAvlBK/dE5IC4iOVxrONzGcXju4urqSoeCwzQU2xtd2z6Orsm6E0Bc7kkO+05VVQUp5fERVykl3r9/j1AypGHaeo59IJLBe/cSiIEepf4rAFRVhdAy5c6SlnoR40icAeLDpL0OxqVym7pxTrEDysA7h0cNfZ0H4hOSkDPFDveGkYxaPXsOiXDxJyGREMgZQDrvwzPxbIhwdahAJO4hmWNzuR5IjAJpIhEuj6WJhEB6HOOzd3KP7UWE65NNInECyOgJsMXjPPmow5gbGIUPqzFEMjsSZ4F0HeeigBCKO73IECC2X4pqemHBWyBE4sQwq9fkd+qVMAIhFGeAPNfoGnOC1tcX2AJSliU2mw2klNi//xFCiLPveggCCJFMDuQjJB1/1zZZ1mPnBVMmGCCE4hSQNiTNHqRXL0QghOIbkHM3WuhTDzaQGHnK1HkgQxr6k5MiFFNAxmyn9NFni6IQVVVBCIGHhwcUReHkXdFOAzHRuOtvmGIzH9V7jNpvbLfbHX+/3W6Pd0DvX3/NOcjcQyT2KtMD2W63xycwt9styrJEWZZenftigLSdMMGczmq1OrzzsPd7O7bbLaSUeHh4gNYaZVl6+1CZk0BsN9iTG4QRTHNi3jWXEG09RlEU0FpDa/1kaEUgHuDoi2TJcA6bVGRZhouLi15ANpsNiqKAEAK73e74pKXvK6OLBTIUyVKgSCkhpUSSJCeRFEWB7Xb7pLcI4ZKBcw9MzdHwzkWypOFXkiSIoqjt1QpProW8ffsWQHibVzgDZO5Gdw6SJQGRUj4ZcjX3BwNwXJkKbeOK2TdtcKmhEQjjBBBXGxeBMH3ag1UgLjcsAmH6tAVrQFxvVATC9GkHVoD40KAIhOnTBowDCQ0HgSwXh3EgIeIgkGXCWCSQoVfRiWR5MBYHZAwOIlkWCgIhEIIgEHsFRyhhNH4CsViwRBIWhEmAuNRwpixoYgkThxUgLjSYOQuaWAjE2cbiXPdMLF7jsA7EdsNxtVCJLJw6FKG+rXXpCfWuBgJhpob0EwC/IgwCYWbqgXweChMIwxAIwxAIwxAIwxAIwxAIwxAIwxAIw4Sa/wGDtUAHUuMNRQAAAABJRU5ErkJggg==",ql="./assets/elf.9fbfa563.png";const B=Gt("main",function(){const e=Ae(1),t=T(""),n=T("");function i(l){const o=Ae(!1);return Be(()=>{const c=l(),f=Ie(c.shouldNotify);return{...c,opened:o,shouldNotify:f,[gt]:Ua,[vt]:function(){const{day:d,layer:g,symbol:y,opened:b,shouldNotify:p,story:N}=this;return{day:d,symbol:y,opened:b,shouldNotify:p,onOpenLore(){var C,x;t.value=r((x=(C=Ne[g!=null?g:"trees"])==null?void 0:C.name)!=null?x:""),n.value=N},onOpenLayer(){if(window.matchMedia("(min-width: 1468px)").matches)if(A.tabs.includes(g!=null?g:"trees")){const C=A.tabs.lastIndexOf(g!=null?g:"trees");A.tabs.splice(C,1)}else A.tabs.push(g!=null?g:"trees"),B.minimized.value=!0;else A.tabs.splice(1,1/0,g!=null?g:"trees")},onUnlockLayer(){b.value=!0,setTimeout(()=>{var C,x;t.value=r((x=(C=Ne[g!=null?g:"trees"])==null?void 0:C.name)!=null?x:""),n.value=N,A.devSpeed=null},1e3)}}}}})}const s=[i(()=>({day:1,shouldNotify:!1,layer:"trees",symbol:Dl,story:"Oh no! Santa forgot about Christmas and it's only 25 days away! He's asked for your help due to your history getting large quantities of things in short amounts of time. Unfortunately you're really starting from scratch here - let's start with getting wood, which you'll need for everything from building workshops to wrapping paper to many of the toys themselves!"})),i(()=>({day:2,shouldNotify:!1,layer:"workshop",symbol:Ol,story:"Santa looked over your tree farm and was impressed with how much you could accomplish in just one day. Today's goal is to get a workshop built up for the elves to work in - and apparently, they need quite a lot of space to work!"})),i(()=>({day:3,shouldNotify:!1,layer:"coal",symbol:Rl,story:"Santa tells you that unfortunately there are quite a few naughty children out there this year, and he's going to need you to gather as much coal as you can for him to give out."})),i(()=>({day:4,shouldNotify:!1,layer:"elves",symbol:ql,story:"Alright, it seems you finally have enough things setup to start bringing in the elves! Unfortunately, it seems they'll need to be retrained on how to help, since they're out of practice by 11 months!"})),i(()=>({day:5,shouldNotify:!1,layer:null,symbol:"",story:""})),i(()=>({day:6,shouldNotify:!1,layer:null,symbol:"",story:""})),i(()=>({day:7,shouldNotify:!1,layer:null,symbol:"",story:""})),i(()=>({day:8,shouldNotify:!1,layer:null,symbol:"",story:""})),i(()=>({day:9,shouldNotify:!1,layer:null,symbol:"",story:""})),i(()=>({day:10,shouldNotify:!1,layer:null,symbol:"",story:""})),i(()=>({day:11,shouldNotify:!1,layer:null,symbol:"",story:""})),i(()=>({day:12,shouldNotify:!1,layer:null,symbol:"",story:""})),i(()=>({day:13,shouldNotify:!1,layer:null,symbol:"",story:""})),i(()=>({day:14,shouldNotify:!1,layer:null,symbol:"",story:""})),i(()=>({day:15,shouldNotify:!1,layer:null,symbol:"",story:""})),i(()=>({day:16,shouldNotify:!1,layer:null,symbol:"",story:""})),i(()=>({day:17,shouldNotify:!1,layer:null,symbol:"",story:""})),i(()=>({day:18,shouldNotify:!1,layer:null,symbol:"",story:""})),i(()=>({day:19,shouldNotify:!1,layer:null,symbol:"",story:""})),i(()=>({day:20,shouldNotify:!1,layer:null,symbol:"",story:""})),i(()=>({day:21,shouldNotify:!1,layer:null,symbol:"",story:""})),i(()=>({day:22,shouldNotify:!1,layer:null,symbol:"",story:""})),i(()=>({day:23,shouldNotify:!1,layer:null,symbol:"",story:""})),i(()=>({day:24,shouldNotify:!1,layer:null,symbol:"",story:""}))];return{name:"Calendar",days:s,day:e,loreTitle:t,loreBody:n,minWidth:700,display:F(()=>u(D,null,[A.devSpeed===0?u("div",null,[v("Game Paused")]):null,A.devSpeed&&A.devSpeed!==1?u("div",null,[v("Dev Speed: "),te(A.devSpeed),v("x")]):null,A.offlineTime?u("div",null,[v("Offline Time: "),_n(A.offlineTime)]):null,u(Re,null,null),u("div",{class:"advent"},[s.reduce((l,o)=>(l[l.length-1].length===4&&l.push([]),l[l.length-1].push(o),l),[[]]).map(l=>Oe(...l))])]))}}),Vl=e=>[B,se,Te,ue,ft],Gn=S(()=>!1);function Ll(e,t){["0.0","0.1","0.2"].includes(e!=null?e:"")&&(t.offlineProd=!1)}var Fi=Object.freeze(Object.defineProperty({__proto__:null,main:B,getInitialLayers:Vl,hasWon:Gn,fixOldSave:Ll},Symbol.toStringTag,{value:"Module"}));const Gl=L({components:{Context:Ii},props:{index:{type:Number,required:!0},tab:{type:Function,required:!0},display:{type:P(Object,String,Function),required:!0},minimized:{type:Object,required:!0},minWidth:{type:P(Number,String),required:!0},name:{type:P(String),required:!0},color:P(String),minimizable:P(Boolean),nodes:{type:Object,required:!0}},setup(e){const{display:t,index:n,minimized:i,minWidth:s,tab:l}=we(e),o=Mi(t),c=S(()=>W.allowGoBack&&n.value>0&&!i.value);function f(){A.tabs.splice(r(e.index),1)}Mt(()=>g(i.value,r(s.value))),ze([i,da(s)],([y,b])=>g(y,b));function d(y){e.nodes.value=y}function g(y,b){const p=typeof b=="number"||Number.isNaN(parseInt(b))?b+"px":b,N=l.value();N!=null&&(y?(N.style.flexGrow="0",N.style.flexShrink="0",N.style.width="60px",N.style.minWidth=N.style.flexBasis="",N.style.margin="0"):(N.style.flexGrow="",N.style.flexShrink="",N.style.width="",N.style.minWidth=N.style.flexBasis=p,N.style.margin=""))}return{component:o,showGoBack:c,updateNodes:d,unref:r,goBack:f}}});function Ul(e,t,n,i,s,l){const o=pt("Context");return _(),M("div",{class:"layer-container",style:me({"--layer-color":e.unref(e.color)})},[e.showGoBack?(_(),M("button",{key:0,class:"goBack",onClick:t[0]||(t[0]=(...c)=>e.goBack&&e.goBack(...c))},"\u274C")):$("",!0),e.minimized.value?(_(),M("button",{key:1,class:"layer-tab minimized",onClick:t[1]||(t[1]=c=>e.minimized.value=!1)},[m("div",null,H(e.unref(e.name)),1)])):(_(),M("div",{key:2,class:ce(["layer-tab",{showGoBack:e.showGoBack}])},[u(o,{onUpdateNodes:e.updateNodes},{default:R(()=>[(_(),j(ke(e.component)))]),_:1},8,["onUpdateNodes"])],2)),e.unref(e.minimizable)?(_(),M("button",{key:3,class:"minimize",onClick:t[2]||(t[2]=c=>e.minimized.value=!0)}," \u25BC ")):$("",!0)],4)}var Hl=Z(Gl,[["render",Ul],["__scopeId","data-v-0158bec3"]]);const Bi=e=>(nt("data-v-4b4bda40"),e=e(),it(),e),jl=Bi(()=>m("h2",null,"Changelog",-1)),zl=Bi(()=>m("details",{open:""},[m("summary",null,[v("v0.0 Initial Commit - "),m("time",null,"2021-09-04")]),v(" This is the first release :D "),m("ul",null,[m("li",{class:"feature"},"Did everything"),m("li",{class:"fix"},"Had some fun"),m("li",{class:"breaking"},"Removed everything"),m("li",{class:"balancing"},"Created some bugs to fix later")])],-1)),Wl=L({__name:"Changelog",setup(e,{expose:t}){const n=T(!1);return t({open(){n.value=!0}}),(i,s)=>(_(),j(We,{modelValue:n.value,"onUpdate:modelValue":s[0]||(s[0]=l=>n.value=l)},{header:R(()=>[jl]),body:R(()=>[zl]),_:1},8,["modelValue"]))}});var Ql=Z(Wl,[["__scopeId","data-v-4b4bda40"]]),Kl=L({props:{element:Object,display:{type:P(Object,String,Function),required:!0},style:P(Object,String,Array),classes:P(Object),direction:P(String),xoffset:P(String),yoffset:P(String),pinned:Object},setup(e){const{element:t,display:n,pinned:i}=we(e),s=T(!1),l=S(()=>(pe(i)||s.value)&&o.value),o=Lt(n),c=Le(K(F(()=>{const g=pe(t);return g==null?"":Xe(g)})));function f(g){const y=i;g.shiftKey&&y&&(y.value=!y.value,g.stopPropagation(),g.preventDefault())}const d=S(()=>pe(i)&&sn[ne.theme].showPin);return{Direction:J,isHovered:s,isShown:l,comp:o,elementComp:c,unref:r,togglePinned:f,showPin:d}}});const Jl={key:0,class:"material-icons pinned"};function Xl(e,t,n,i,s,l){return _(),M("div",{class:ce(["tooltip-container",{shown:e.isShown}]),onMouseenter:t[0]||(t[0]=o=>e.isHovered=!0),onMouseleave:t[1]||(t[1]=o=>e.isHovered=!1),onClickCapture:t[2]||(t[2]=(...o)=>e.togglePinned&&e.togglePinned(...o))},[Je(e.$slots,"default",{},void 0,!0),e.elementComp?(_(),j(ke(e.elementComp),{key:0})):$("",!0),u(bn,{name:"fade"},{default:R(()=>{var o;return[e.isShown?(_(),M("div",{key:0,class:ce(["tooltip",{top:e.unref(e.direction)===e.Direction.Up,left:e.unref(e.direction)===e.Direction.Left,right:e.unref(e.direction)===e.Direction.Right,bottom:e.unref(e.direction)===e.Direction.Down,...e.unref(e.classes)}]),style:me([{"--xoffset":e.unref(e.xoffset)||"0px","--yoffset":e.unref(e.yoffset)||"0px"},(o=e.unref(e.style))!=null?o:{}])},[e.showPin?(_(),M("span",Jl,"push_pin")):$("",!0),e.comp?(_(),j(ke(e.comp),{key:1})):$("",!0)],6)):$("",!0)]}),_:1})],34)}var oe=Z(Kl,[["render",Xl],["__scopeId","data-v-6102fa3a"]]);const Zl={class:"info-modal-header"},Yl=["src","alt"],er={class:"info-modal-title"},tr={key:0},nr={key:0},ir={key:0},sr=m("div",null," Made in Profectus, by thepaperpilot with inspiration from Acameada and Jacorb ",-1),ar=m("br",null,null,-1),lr=m("br",null,null,-1),rr=["href"],or=m("span",{class:"material-icons info-modal-discord"},"discord",-1),ur=m("div",null,[m("a",{href:"https://discord.gg/WzejVAx",class:"info-modal-discord-link"},[m("span",{class:"material-icons info-modal-discord"},"discord"),v(" The Paper Pilot Community ")])],-1),cr=m("div",null,[m("a",{href:"https://discord.gg/F3xveHV",class:"info-modal-discord-link"},[m("span",{class:"material-icons info-modal-discord"},"discord"),v(" The Modding Tree ")])],-1),dr=m("br",null,null,-1);var fr=L({__name:"Info",props:{changelog:null},setup(e,{expose:t}){const n=e,{title:i,logo:s,author:l,discordName:o,discordLink:c,versionNumber:f,versionTitle:d}=W,g=we(n),y=T(!1),b=S(()=>_n(A.timePlayed)),p=S(()=>K(F(()=>u(D,null,[wi.map(he)]))));t({open(){y.value=!0}});function N(){var C;(C=r(g.changelog))==null||C.open()}return(C,x)=>(_(),j(We,{modelValue:y.value,"onUpdate:modelValue":x[0]||(x[0]=de=>y.value=de)},{header:R(()=>[m("div",Zl,[r(s)?(_(),M("img",{key:0,class:"info-modal-logo",src:r(s),alt:r(i)},null,8,Yl)):$("",!0),m("div",er,[m("h2",null,H(r(i)),1),m("h4",null,[v(" v"+H(r(f)),1),r(d)?(_(),M("span",tr,": "+H(r(d)),1)):$("",!0)])])])]),body:R(({shown:de})=>[de?(_(),M("div",nr,[r(l)?(_(),M("div",ir,"By "+H(r(l)),1)):$("",!0),sr,ar,m("div",{class:"link",onClick:N},"Changelog"),lr,m("div",null,[r(c)?(_(),M("a",{key:0,href:r(c),class:"info-modal-discord-link"},[or,v(" "+H(r(o)),1)],8,rr)):$("",!0)]),ur,cr,dr,m("div",null,"Time Played: "+H(r(b)),1),(_(),j(ke(r(p))))])):$("",!0)]),_:1},8,["modelValue"]))}});const mr={class:"field"},hr=L({__name:"Toggle",props:{title:null,modelValue:{type:Boolean}},emits:["update:modelValue"],setup(e,{emit:t}){const n=e,i=S(()=>K(r(n.title)||"","span")),s=S({get(){return!!n.modelValue},set(l){t("update:modelValue",l)}});return(l,o)=>(_(),M("label",mr,[Tn(m("input",{type:"checkbox",class:"toggle","onUpdate:modelValue":o[0]||(o[0]=c=>be(s)?s.value=c:null)},null,512),[[Ji,r(s)]]),(_(),j(ke(r(i))))]))}});var qt=Z(hr,[["__scopeId","data-v-2b109500"]]);const Di=e=>(nt("data-v-1975661c"),e=e(),it(),e),pr=Di(()=>m("div",{class:"header"},[m("h2",null,"Options")],-1)),gr=Di(()=>m("hr",null,null,-1));var vr=L({__name:"Options",setup(e,{expose:t}){const n=T(!1);t({open(){n.value=!0}});const i=Object.keys(sn).map(p=>({label:hi(p),value:p})),s=S(()=>K(F(()=>u(D,null,[_i.map(he)])))),{showTPS:l,theme:o,unthrottled:c}=we(ne),{autosave:f,offlineProd:d}=we(A),g=S({get(){return A.devSpeed===0},set(p){A.devSpeed=p?0:null}});F(()=>u("span",null,[v("Offline Production"),u(oe,{display:"Save-specific"},{default:()=>[v("*")]})]));const y=F(()=>u("span",null,[v("Autosave"),u(oe,{display:"Save-specific"},{default:()=>[v("*")]})])),b=F(()=>u("span",null,[v("Pause game"),u(oe,{display:"Save-specific"},{default:()=>[v("*")]})]));return(p,N)=>(_(),j(We,{modelValue:n.value,"onUpdate:modelValue":N[4]||(N[4]=C=>n.value=C)},{header:R(()=>[pr]),body:R(()=>[u(Ln,{title:"Theme",options:r(i),modelValue:r(o),"onUpdate:modelValue":N[0]||(N[0]=C=>be(o)?o.value=C:null)},null,8,["options","modelValue"]),(_(),j(ke(r(s)))),u(qt,{title:"Show TPS",modelValue:r(l),"onUpdate:modelValue":N[1]||(N[1]=C=>be(l)?l.value=C:null)},null,8,["modelValue"]),gr,u(qt,{title:r(y),modelValue:r(f),"onUpdate:modelValue":N[2]||(N[2]=C=>be(f)?f.value=C:null)},null,8,["title","modelValue"]),r(W).enablePausing?(_(),j(qt,{key:0,title:r(b),modelValue:r(g),"onUpdate:modelValue":N[3]||(N[3]=C=>be(g)?g.value=C:null)},null,8,["title","modelValue"])):$("",!0)]),_:1},8,["modelValue"]))}});var yr=Z(vr,[["__scopeId","data-v-1975661c"]]);const br=["onSubmit"],_r={class:"field"},wr={key:0,class:"field-title"},Nr=["placeholder"],kr=L({__name:"Text",props:{title:null,modelValue:null,textArea:{type:Boolean},placeholder:null,maxHeight:null,submitOnBlur:{type:Boolean}},emits:["update:modelValue","submit","cancel"],setup(e,{emit:t}){const n=e,i=Lt(tt(n,"title"),"span"),s=Le(null);yn(()=>{var f;(f=s.value)==null||f.focus()});const l=S({get(){return r(n.modelValue)||""},set(f){t("update:modelValue",f)}});function o(){t("submit")}function c(){n.submitOnBlur!==!1?t("submit"):t("cancel")}return(f,d)=>(_(),M("form",{onSubmit:Xt(o,["prevent"])},[m("div",_r,[r(i)?(_(),M("span",wr,[(_(),j(ke(r(i))))])):$("",!0),e.textArea?(_(),j(r(is),{key:1,modelValue:r(l),"onUpdate:modelValue":d[0]||(d[0]=g=>be(l)?l.value=g:null),placeholder:e.placeholder,maxHeight:e.maxHeight,onBlur:c,ref_key:"field",ref:s},null,8,["modelValue","placeholder","maxHeight"])):Tn((_(),M("input",{key:2,type:"text","onUpdate:modelValue":d[1]||(d[1]=g=>be(l)?l.value=g:null),placeholder:e.placeholder,class:ce({fullWidth:!e.title}),onBlur:c,ref_key:"field",ref:s},null,42,Nr)),[[Xi,r(l)]])])],40,br))}});var Oi=Z(kr,[["__scopeId","data-v-67b44a54"]]);const Cr={key:0},Sr=["onClick","disabled"],Mr={key:0},Ir=["onClick"],Ar=L({__name:"DangerButton",props:{disabled:{type:Boolean},skipConfirm:{type:Boolean}},emits:["click","confirmingChanged"],setup(e,{emit:t}){const i=we(e),s=T(!1);ze(s,c=>{t("confirmingChanged",c)});function l(){if(r(i.skipConfirm)){t("click");return}s.value&&t("click"),s.value=!s.value}function o(){s.value=!1}return(c,f)=>(_(),M("span",{class:ce(["container",{confirming:s.value}])},[s.value?(_(),M("span",Cr,"Are you sure?")):$("",!0),m("button",{onClick:Xt(l,["stop"]),class:"button danger",disabled:e.disabled},[s.value?(_(),M("span",Mr,"Yes")):Je(c.$slots,"default",{key:1},void 0,!0)],8,Sr),s.value?(_(),M("button",{key:1,class:"button",onClick:Xt(o,["stop"])},"No",8,Ir)):$("",!0)],2))}});var Er=Z(Ar,[["__scopeId","data-v-2f8ef34c"]]);const Pr=["onClick"],$r=L({__name:"FeedbackButton",props:{left:{type:Boolean}},emits:["click"],setup(e,{emit:t}){const n=T(!1),i=T(null);function s(){t("click"),i.value&&clearTimeout(i.value),n.value=!1,Mt(()=>{n.value=!0,i.value=setTimeout(()=>n.value=!1,500)})}return(l,o)=>(_(),M("button",{onClick:Xt(s,["stop"]),class:ce(["feedback",{activated:n.value,left:e.left}])},[Je(l.$slots,"default",{},void 0,!0)],10,Pr))}});var Tr=Z($r,[["__scopeId","data-v-01a1b95c"]]);const st=e=>(nt("data-v-5285ac49"),e=e(),it(),e),xr=st(()=>m("div",{class:"handle material-icons"},"drag_handle",-1)),Fr={key:0,class:"actions"},Br=st(()=>m("span",{class:"material-icons"},"content_paste",-1)),Dr=st(()=>m("span",{class:"material-icons"},"content_copy",-1)),Or=st(()=>m("span",{class:"material-icons"},"edit",-1)),Rr=st(()=>m("span",{class:"material-icons",style:{margin:"-2px"}},"delete",-1)),qr={key:1,class:"actions"},Vr=st(()=>m("span",{class:"material-icons"},"check",-1)),Lr=st(()=>m("span",{class:"material-icons"},"close",-1)),Gr={key:2,class:"details"},Ur={class:"save-version"},Hr=st(()=>m("br",null,null,-1)),jr={key:0},zr={key:1},Wr={key:3,class:"details"},Qr={key:4,class:"details error"},Kr=st(()=>m("br",null,null,-1)),Jr=L({__name:"Save",props:{save:null},emits:["export","open","duplicate","delete","editName"],setup(e,{emit:t}){const n=e,{save:i}=we(n),s=new Intl.DateTimeFormat("en-US",{year:"numeric",month:"numeric",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric"}),l=T(!1),o=T(!1),c=T("");ze(l,()=>c.value=i.value.name||"");const f=S(()=>i.value&&i.value.id===A.id),d=S(()=>f.value?A.time:i.value&&i.value.time||0),g=Mi(S(()=>{var b,p,N,C;return`Day ${(C=(N=(p=(b=i.value)==null?void 0:b.layers)==null?void 0:p.main)==null?void 0:N.day)!=null?C:1}`}));function y(){t("editName",c.value),l.value=!1}return(b,p)=>(_(),M("div",{class:ce(["save",{active:r(f)}])},[xr,l.value?(_(),M("div",qr,[m("button",{onClick:y,class:"button"},[u(oe,{display:"Save",direction:r(J).Left,class:"info"},{default:R(()=>[Vr]),_:1},8,["direction"])]),m("button",{onClick:p[5]||(p[5]=N=>l.value=!l.value),class:"button"},[u(oe,{display:"Cancel",direction:r(J).Left,class:"info"},{default:R(()=>[Lr]),_:1},8,["direction"])])])):(_(),M("div",Fr,[r(i).error==null&&!o.value?(_(),j(Tr,{key:0,onClick:p[0]||(p[0]=N=>t("export")),class:"button",left:""},{default:R(()=>[u(oe,{display:"Export",direction:r(J).Left,class:"info"},{default:R(()=>[Br]),_:1},8,["direction"])]),_:1})):$("",!0),r(i).error==null&&!o.value?(_(),M("button",{key:1,onClick:p[1]||(p[1]=N=>t("duplicate")),class:"button"},[u(oe,{display:"Duplicate",direction:r(J).Left,class:"info"},{default:R(()=>[Dr]),_:1},8,["direction"])])):$("",!0),r(i).error==null&&!o.value?(_(),M("button",{key:2,onClick:p[2]||(p[2]=N=>l.value=!l.value),class:"button"},[u(oe,{display:"Edit Name",direction:r(J).Left,class:"info"},{default:R(()=>[Or]),_:1},8,["direction"])])):$("",!0),u(Er,{disabled:r(f),onClick:p[3]||(p[3]=N=>t("delete")),onConfirmingChanged:p[4]||(p[4]=N=>o.value=N)},{default:R(()=>[u(oe,{display:"Delete",direction:r(J).Left,class:"info"},{default:R(()=>[Rr]),_:1},8,["direction"])]),_:1},8,["disabled"])])),r(i).error==null&&!l.value?(_(),M("div",Gr,[m("button",{class:"button open",onClick:p[6]||(p[6]=N=>t("open"))},[m("h3",null,H(r(i).name),1)]),m("span",Ur,"v"+H(r(i).modVersion),1),Hr,r(d)?(_(),M("div",jr,"Last played "+H(r(s).format(r(d))),1)):$("",!0),r(g)?(_(),M("div",zr,[(_(),j(ke(r(g))))])):$("",!0)])):r(i).error==null&&l.value?(_(),M("div",Wr,[u(Oi,{modelValue:c.value,"onUpdate:modelValue":p[7]||(p[7]=N=>c.value=N),class:"editname",onSubmit:y},null,8,["modelValue"])])):(_(),M("div",Qr,[v(" Error: Failed to load save with id "+H(r(i).id),1),Kr,v(H(r(i).error),1)]))],2))}});var Xr=Z(Jr,[["__scopeId","data-v-5285ac49"]]);const Un=e=>(nt("data-v-3b9991aa"),e=e(),it(),e),Zr=Un(()=>m("h2",null,"Saves Manager",-1)),Yr={class:"modal-footer"},eo={class:"field"},to=Un(()=>m("span",{class:"field-title"},"Create Save",-1)),no={class:"field-buttons"},io={class:"footer"},so=Un(()=>m("div",{style:{"flex-grow":"1"}},null,-1)),ao=L({__name:"SavesManager",setup(e,{expose:t}){const n=T(!1),i=T(null);t({open(){n.value=!0}});const s=T(!1),l=T(""),o=T(null);ze(l,I=>{I?Mt(()=>{try{if(I[0]!=="{")if(I[0]==="e")I=decodeURIComponent(escape(atob(I)));else if(I[0]==="\u1BE1")I=mt.decompressFromUTF16(I);else{console.warn("Unable to determine preset encoding",I),s.value=!0;return}const k=JSON.parse(I);if(typeof k!="object"){s.value=!0;return}const z=cn();k.id=z,He(k),l.value="",s.value=!1,ne.saves.push(z)}catch{s.value=!0}}):s.value=!1});let c={},f=T(Object.keys(c).reduce((I,k)=>(I.push({label:k.split("/").slice(-1)[0].slice(0,-4),value:c[k]}),I),[]));const d=vn({});function g(I){if(d[I]==null){let k=localStorage.getItem(I);if(k==null)d[I]={error:"Save doesn't exist in localStorage",id:I};else if(k==="dW5kZWZpbmVk")d[I]={error:"Save is undefined",id:I};else try{if(k[0]!=="{")if(k[0]==="e")k=decodeURIComponent(escape(atob(k)));else if(k[0]==="\u1BE1")k=mt.decompressFromUTF16(k);else return console.warn("Unable to determine preset encoding",k),s.value=!0,d[I]={error:"Unable to determine preset encoding",id:I},d[I];d[I]={...JSON.parse(k),id:I}}catch(z){d[I]={error:z,id:I},console.warn(`SavesManager: Failed to load info about save with id ${I}: -${z} -${k}`)}}return d[I]}ze(n,I=>{I&&Object.keys(d).forEach(k=>delete d[k])});const y=S(()=>ne.saves.reduce((I,k)=>(I[k]=g(k),I),{}));function b(I){let k;switch(A.id===I?k=vi(A[le]):k=JSON.stringify(y.value[I]),W.exportEncoding){default:console.warn(`Unknown save encoding: ${W.exportEncoding}. Defaulting to lz`);case"lz":k=mt.compressToUTF16(k);break;case"base64":k=btoa(unescape(encodeURIComponent(k)));break;case"plain":break}const z=document.createElement("textarea");z.value=k,document.body.appendChild(z),z.select(),z.setSelectionRange(0,99999),document.execCommand("copy"),document.body.removeChild(z)}function p(I){A.id===I&&He();const k={...y.value[I],id:cn()};He(k),ne.saves.push(k.id)}function N(I){ne.saves=ne.saves.filter(k=>k!==I),localStorage.removeItem(I),d[I]=void 0}function C(I){y.value[A.id].time=A.time,He(),d[A.id]=void 0,Ct(y.value[I]),d[I]=void 0}function x(I){if(o.value=I,Mt(()=>{o.value=null}),I[0]!=="{")if(I[0]==="e")I=decodeURIComponent(escape(atob(I)));else if(I[0]==="\u1BE1")I=mt.decompressFromUTF16(I);else{console.warn("Unable to determine preset encoding",I);return}const k=JSON.parse(I);k.id=cn(),He(k),ne.saves.push(k.id),C(k.id)}function de(I,k){const z=y.value[I];z&&(z.name=k,A.id===I?(A.name=k,He()):(He(z),d[I]=void 0))}return(I,k)=>(_(),j(We,{modelValue:n.value,"onUpdate:modelValue":k[4]||(k[4]=z=>n.value=z),ref_key:"modal",ref:i},{header:R(()=>[Zr]),body:R(({shown:z})=>[z?(_(),j(r(ns),{key:0,list:r(ne).saves,handle:".handle",itemKey:ge=>ge},{item:R(({element:ge})=>[u(Xr,{save:r(y)[ge],onOpen:Ee=>C(ge),onExport:Ee=>b(ge),onEditName:Ee=>de(ge,Ee),onDuplicate:Ee=>p(ge),onDelete:Ee=>N(ge)},null,8,["save","onOpen","onExport","onEditName","onDuplicate","onDelete"])]),_:1},8,["list","itemKey"])):$("",!0)]),footer:R(()=>[m("div",Yr,[u(Oi,{modelValue:l.value,"onUpdate:modelValue":k[0]||(k[0]=z=>l.value=z),title:"Import Save",placeholder:"Paste your save here!",class:ce({importingFailed:s.value})},null,8,["modelValue","class"]),m("div",eo,[to,m("div",no,[m("button",{class:"button",onClick:k[1]||(k[1]=z=>C(r(Dt)().id))},"New Game"),Object.keys(r(f)).length>0?(_(),j(Ln,{key:0,options:r(f),modelValue:o.value,"onUpdate:modelValue":k[2]||(k[2]=z=>x(z)),closeOnSelect:"",placeholder:"Select preset",class:"presets"},null,8,["options","modelValue"])):$("",!0)])]),m("div",io,[so,m("button",{class:"button modal-default-button",onClick:k[3]||(k[3]=z=>n.value=!1)}," Close ")])])]),_:1},8,["modelValue"]))}});var Ri=Z(ao,[["__scopeId","data-v-3b9991aa"]]);const qe=e=>(nt("data-v-4a3f8425"),e=e(),it(),e),lo=["src","alt"],ro={key:1,class:"title"},oo=qe(()=>m("div",{style:{"flex-grow":"1",cursor:"unset"}},null,-1)),uo={class:"discord"},co={class:"discord-links"},fo={key:0},mo=["href"],ho=qe(()=>m("li",null,[m("a",{href:"https://discord.gg/WzejVAx",target:"_blank"},"The Paper Pilot Community")],-1)),po=qe(()=>m("li",null,[m("a",{href:"https://discord.gg/F3xveHV",target:"_blank"},"The Modding Tree")],-1)),go={href:"https://forums.moddingtree.com/",target:"_blank"},vo=qe(()=>m("span",{class:"material-icons"},"forum",-1)),yo=qe(()=>m("span",{class:"material-icons"},"info",-1)),bo=qe(()=>m("span",{class:"material-icons"},"library_books",-1)),_o=qe(()=>m("span",{class:"material-icons"},"settings",-1)),wo=qe(()=>m("span",{class:"material-icons"},"library_books",-1)),No=qe(()=>m("span",{class:"material-icons"},"settings",-1)),ko=qe(()=>m("span",{class:"material-icons"},"info",-1)),Co={href:"https://forums.moddingtree.com/",target:"_blank"},So=qe(()=>m("span",{class:"material-icons"},"forum",-1)),Mo={class:"discord"},Io={class:"discord-links"},Ao={key:0},Eo=["href"],Po=qe(()=>m("li",null,[m("a",{href:"https://discord.gg/WzejVAx",target:"_blank"},"The Paper Pilot Community")],-1)),$o=qe(()=>m("li",null,[m("a",{href:"https://discord.gg/F3xveHV",target:"_blank"},"The Modding Tree")],-1)),To=L({__name:"Nav",setup(e){const t=T(null),n=T(null),i=T(null),s=T(null),{useHeader:l,banner:o,title:c,discordName:f,discordLink:d,versionNumber:g}=W;function y(){window.open(d,"mywindow")}return(b,p)=>(_(),M(D,null,[r(l)?(_(),M("div",It({key:0,class:"nav"},b.$attrs),[r(o)?(_(),M("img",{key:0,src:r(o),class:"banner",alt:r(c)},null,8,lo)):(_(),M("div",ro,H(r(c)),1)),m("div",{onClick:p[0]||(p[0]=N=>{var C;return(C=s.value)==null?void 0:C.open()}),class:"version-container"},[u(oe,{display:"Changelog",direction:r(J).Down,class:"version"},{default:R(()=>[m("span",null,"v"+H(r(g)),1)]),_:1},8,["direction"])]),oo,m("div",uo,[m("span",{onClick:y,class:"material-icons"},"discord"),m("ul",co,[r(d)?(_(),M("li",fo,[m("a",{href:r(d),target:"_blank"},H(r(f)),9,mo)])):$("",!0),ho,po])]),m("div",null,[m("a",go,[u(oe,{display:"Forums",direction:r(J).Down,yoffset:"5px"},{default:R(()=>[vo]),_:1},8,["direction"])])]),m("div",{onClick:p[1]||(p[1]=N=>{var C;return(C=t.value)==null?void 0:C.open()})},[u(oe,{display:"Info",direction:r(J).Down,class:"info"},{default:R(()=>[yo]),_:1},8,["direction"])]),m("div",{onClick:p[2]||(p[2]=N=>{var C;return(C=n.value)==null?void 0:C.open()})},[u(oe,{display:"Saves",direction:r(J).Down,xoffset:"-20px"},{default:R(()=>[bo]),_:1},8,["direction"])]),m("div",{onClick:p[3]||(p[3]=N=>{var C;return(C=i.value)==null?void 0:C.open()})},[u(oe,{display:"Options",direction:r(J).Down,xoffset:"-66px"},{default:R(()=>[_o]),_:1},8,["direction"])])],16)):(_(),M("div",It({key:1,class:"overlay-nav"},b.$attrs),[m("div",{onClick:p[4]||(p[4]=N=>{var C;return(C=s.value)==null?void 0:C.open()}),class:"version-container"},[u(oe,{display:"Changelog",direction:r(J).Right,xoffset:"25%",class:"version"},{default:R(()=>[m("span",null,"v"+H(r(g)),1)]),_:1},8,["direction"])]),m("div",{onClick:p[5]||(p[5]=N=>{var C;return(C=n.value)==null?void 0:C.open()})},[u(oe,{display:"Saves",direction:r(J).Right},{default:R(()=>[wo]),_:1},8,["direction"])]),m("div",{onClick:p[6]||(p[6]=N=>{var C;return(C=i.value)==null?void 0:C.open()})},[u(oe,{display:"Options",direction:r(J).Right},{default:R(()=>[No]),_:1},8,["direction"])]),m("div",{onClick:p[7]||(p[7]=N=>{var C;return(C=t.value)==null?void 0:C.open()})},[u(oe,{display:"Info",direction:r(J).Right},{default:R(()=>[ko]),_:1},8,["direction"])]),m("div",null,[m("a",Co,[u(oe,{display:"Forums",direction:r(J).Right,xoffset:"7px"},{default:R(()=>[So]),_:1},8,["direction"])])]),m("div",Mo,[m("span",{onClick:y,class:"material-icons"},"discord"),m("ul",Io,[r(d)?(_(),M("li",Ao,[m("a",{href:r(d),target:"_blank"},H(r(f)),9,Eo)])):$("",!0),Po,$o])])],16)),u(fr,{ref_key:"info",ref:t,changelog:s.value},null,8,["changelog"]),u(Ri,{ref_key:"savesManager",ref:n},null,512),u(yr,{ref_key:"options",ref:i},null,512),u(Ql,{ref_key:"changelog",ref:s},null,512)],64))}});var qi=Z(To,[["__scopeId","data-v-4a3f8425"]]);const Hn=e=>(nt("data-v-62ae8bac"),e=e(),it(),e),xo={class:"inner-tab"},Fo={key:0},Bo=Hn(()=>m("br",null,null,-1)),Do=v(" You can help continue the "),Oo=Hn(()=>m("i",null,"advent",-1)),Ro=v("ure at: "),qo=Hn(()=>m("a",{href:"https://discord.gg/WzejVAx",class:"info-modal-discord-link"},[m("span",{class:"material-icons info-modal-discord"},"discord"),v(" The Paper Pilot Community ")],-1)),Vo=[Bo,Do,Oo,Ro,qo],Lo=L({__name:"Game",setup(e){const t=tt(A,"tabs"),n=S(()=>Object.keys(Ne)),i=W.useHeader;function s(l){const{display:o,minimized:c,minWidth:f,name:d,color:g,minimizable:y,nodes:b}=l;return{display:o,minimized:c,minWidth:f,name:d,color:g,minimizable:y,nodes:b}}return(l,o)=>(_(),M("div",{class:ce(["tabs-container",{useHeader:r(i)}])},[(_(!0),M(D,null,ai(r(t),(c,f)=>{var d,g;return _(),M("div",{key:f,class:ce(["tab",r((d=r(Ne)[c])==null?void 0:d.classes)]),ref_for:!0,ref:`tab-${f}`,style:me(r((g=r(Ne)[c])==null?void 0:g.style))},[f===0&&!r(i)?(_(),j(qi,{key:0})):$("",!0),m("div",xo,[r(n).includes(c)?(_(),j(Hl,It({key:0},s(r(Ne)[c]),{index:f,tab:()=>{var y;return(y=l.$refs[`tab-${f}`])==null?void 0:y[0]}}),null,16,["index","tab"])):(_(),j(ke(c),{key:1,index:f},null,8,["index"]))])],6)}),128)),u(We,{"model-value":r(B).loreBody.value!=="","onUpdate:modelValue":o[0]||(o[0]=()=>r(B).loreBody.value="")},{header:R(()=>[m("h2",null,H(r(B).loreTitle.value),1)]),body:R(()=>[v(H(r(B).loreBody.value)+" ",1),r(B).days[r(B).day.value-1].opened.value?$("",!0):(_(),M("div",Fo,Vo))]),_:1},8,["model-value"])],2))}});var Go=Z(Lo,[["__scopeId","data-v-62ae8bac"]]);const ln=e=>(nt("data-v-4a50ce42"),e=e(),it(),e),Uo={class:"game-over-modal-header"},Ho=["src","alt"],jo={class:"game-over-modal-title"},zo=ln(()=>m("h2",null,"Congratulations!",-1)),Wo={key:0},Qo=ln(()=>m("br",null,null,-1)),Ko=ln(()=>m("div",null," Please check the Discord to discuss the game or to check for new content updates! ",-1)),Jo=ln(()=>m("br",null,null,-1)),Xo=["href"],Zo=ln(()=>m("span",{class:"material-icons game-over-modal-discord"},"discord",-1)),Yo=L({__name:"GameOverScreen",setup(e){const{title:t,logo:n,discordName:i,discordLink:s,versionNumber:l,versionTitle:o}=W,c=S(()=>_n(A.timePlayed)),f=S(()=>Gn.value&&!A.keepGoing),d=tt(A,"autosave");function g(){A.keepGoing=!0}function y(){Ct(Dt())}return(b,p)=>(_(),j(We,{"model-value":r(f)},{header:R(()=>[m("div",Uo,[r(n)?(_(),M("img",{key:0,class:"game-over-modal-logo",src:r(n),alt:r(t)},null,8,Ho)):$("",!0),m("div",jo,[zo,m("h4",null,"You've beaten "+H(r(t))+" v"+H(r(l))+": "+H(r(o)),1)])])]),body:R(({shown:N})=>[N?(_(),M("div",Wo,[m("div",null,"It took you "+H(r(c))+" to beat the game.",1),Qo,Ko,Jo,m("div",null,[m("a",{href:r(s),class:"game-over-modal-discord-link"},[Zo,v(" "+H(r(i)),1)],8,Xo)]),u(qt,{title:"Autosave",modelValue:r(d),"onUpdate:modelValue":p[0]||(p[0]=C=>be(d)?d.value=C:null)},null,8,["modelValue"])])):$("",!0)]),footer:R(()=>[m("div",{class:"game-over-footer"},[m("button",{onClick:g,class:"button"},"Keep Going"),m("button",{onClick:y,class:"button danger"},"Play Again")])]),_:1},8,["model-value"]))}});var eu=Z(Yo,[["__scopeId","data-v-4a50ce42"]]);const Cn=e=>(nt("data-v-3de07c06"),e=e(),it(),e),tu=Cn(()=>m("div",{class:"nan-modal-header"},[m("h2",null,"NaN value detected!")],-1)),nu={key:0},iu=Cn(()=>m("br",null,null,-1)),su=["href"],au=Cn(()=>m("span",{class:"material-icons nan-modal-discord"},"discord",-1)),lu=Cn(()=>m("br",null,null,-1)),ru={class:"nan-footer"},ou=L({__name:"NaNScreen",setup(e){const{discordName:t,discordLink:n}=W,i=tt(A,"autosave"),s=tt(Y,"hasNaN"),l=T(null),o=S(()=>{var p;return(p=Y.NaNPath)==null?void 0:p.join(".")}),c=S(()=>{var p;return(p=Y.NaNPath)==null?void 0:p.slice(-1)[0]}),f=S(()=>Y.NaNReceiver&&c.value?Y.NaNReceiver[c.value]:null),d=S({get(){return A.devSpeed===0},set(p){A.devSpeed=p?null:0}});function g(){Y.NaNReceiver&&c.value&&(Y.NaNReceiver[c.value]=new a(0),Y.hasNaN=!1)}function y(){Y.NaNReceiver&&c.value&&(Y.NaNReceiver[c.value]=new a(1),Y.hasNaN=!1)}function b(){Y.NaNReceiver&&c.value&&(Y.NaNReceiver[c.value]=new a(NaN),Y.hasNaN=!1)}return(p,N)=>(_(),M(D,null,[u(We,It({modelValue:r(s),"onUpdate:modelValue":N[4]||(N[4]=C=>be(s)?s.value=C:null)},p.$attrs),{header:R(()=>[tu]),body:R(()=>[m("div",null,[v(' Attempted to assign "'+H(r(o))+'" to NaN',1),r(f)?(_(),M("span",nu,H(" ")+"(previously "+H(r(te)(r(f)))+")",1)):$("",!0),v(". Auto-saving has been "+H(r(i)?"enabled":"disabled")+". Check the console for more details, and consider sharing it with the developers on discord. ",1)]),iu,m("div",null,[m("a",{href:r(n),class:"nan-modal-discord-link"},[au,v(" "+H(r(t)),1)],8,su)]),lu,u(qt,{title:"Autosave",modelValue:r(i),"onUpdate:modelValue":N[0]||(N[0]=C=>be(i)?i.value=C:null)},null,8,["modelValue"]),r(W).enablePausing?(_(),j(qt,{key:0,title:"Pause game",modelValue:r(d),"onUpdate:modelValue":N[1]||(N[1]=C=>be(d)?d.value=C:null)},null,8,["modelValue"])):$("",!0)]),footer:R(()=>[m("div",ru,[m("button",{onClick:N[2]||(N[2]=C=>{var x;return(x=l.value)==null?void 0:x.open()}),class:"button"},"Open Saves Manager"),m("button",{onClick:g,class:"button"},"Set to 0"),m("button",{onClick:y,class:"button"},"Set to 1"),r(f)&&r(a).neq(r(f),0)&&r(a).neq(r(f),1)?(_(),M("button",{key:0,onClick:N[3]||(N[3]=C=>s.value=!1),class:"button"}," Set to previous ")):$("",!0),m("button",{onClick:b,class:"button danger"},"Ignore")])]),_:1},16,["modelValue"]),u(Ri,{ref_key:"savesManager",ref:l},null,512)],64))}});var uu=Z(ou,[["__scopeId","data-v-3de07c06"]]);const cu={key:0,class:"tpsDisplay"},du={key:0,class:"low"},fu=L({__name:"TPS",setup(e){const t=S(()=>a.div(Y.lastTenTicks.length,Y.lastTenTicks.reduce((l,o)=>l+o,0))),n=T([]);Fe(()=>{n.value.push(Math.round(t.value.toNumber())),n.value.length>10&&(n.value=n.value.slice(1))});const i=S(()=>n.value.reduce((l,o)=>a.max(l,o),0)),s=S(()=>a.sub(t.value,i.value).gt(1));return(l,o)=>r(t).isNan()?$("",!0):(_(),M("div",cu,[v(" TPS: "+H(r(G)(r(t)))+" ",1),u(bn,{name:"fade"},{default:R(()=>[r(s)?(_(),M("span",du,H(r(G)(r(i))),1)):$("",!0)]),_:1})]))}});var mu=Z(fu,[["__scopeId","data-v-46a3ed5b"]]);var hu=L({__name:"App",setup(e){const t=W.useHeader,n=S(()=>sn[ne.theme].variables),i=tt(ne,"showTPS"),s=S(()=>K(F(()=>u(D,null,[oa.map(he)]))));return(l,o)=>(_(),M(D,null,[m("div",{id:"modal-root",style:me(r(n))},null,4),m("div",{class:ce(["app",{useHeader:r(t)}]),style:me(r(n))},[r(t)?(_(),j(qi,{key:0})):$("",!0),u(Go),r(r(i))?(_(),j(mu,{key:1})):$("",!0),u(eu),u(uu),(_(),j(ke(r(s))))],6)],64))}});var pu=Z(hu,[["__scopeId","data-v-7c41425b"]]);function gu(e={}){const{immediate:t=!1,onNeedRefresh:n,onOfflineReady:i,onRegistered:s,onRegisterError:l}=e;let o,c;const f=async(d=!0)=>{d&&(o==null||o.addEventListener("controlling",g=>{g.isUpdate&&window.location.reload()})),c&&c.waiting&&await as(c.waiting,{type:"SKIP_WAITING"})};if("serviceWorker"in navigator){o=new ss("./sw.js",{scope:"./",type:"classic"}),o.addEventListener("activated",d=>{d.isUpdate||i==null||i()});{const d=()=>{n==null||n()};o.addEventListener("waiting",d),o.addEventListener("externalwaiting",d)}o.register({immediate:t}).then(d=>{c=d,s==null||s(d)}).catch(d=>{l==null||l(d)})}return f}function vu(e={}){const{immediate:t=!0,onNeedRefresh:n,onOfflineReady:i,onRegistered:s,onRegisterError:l}=e,o=T(!1),c=T(!1);return{updateServiceWorker:gu({immediate:t,onNeedRefresh(){o.value=!0,n==null||n()},onOfflineReady(){c.value=!0,i==null||i()},onRegistered:s,onRegisterError:l}),offlineReady:c,needRefresh:o}}document.title=W.title;window.projInfo=W;if(W.id==="")throw"Project ID is empty! Please select a unique ID for this project in /src/data/projInfo.json";requestAnimationFrame(async()=>{console.log(`%cMade in Profectus%c -Learn more at www.moddingtree.com`,"font-weight: bold; font-size: 24px; color: #A3BE8C; background: #2E3440; padding: 4px 8px; border-radius: 8px;","padding: 4px;"),await ia();const{globalBus:e,startGameLoop:t}=await mn(()=>Promise.resolve().then(function(){return na}),void 0),n=window.vue=Zi(pu);e.emit("setupVue",n),n.mount("#app"),Mt(()=>{const i=ri(),{updateServiceWorker:s}=vu({onNeedRefresh(){i.info("New content available, click or reload to update.",{timeout:!1,closeOnClick:!1,draggable:!1,icon:{iconClass:"material-icons",iconChildren:"refresh",iconTag:"i"},rtl:!1,onClick(){s()}})},onOfflineReady(){i.info("App ready to work offline")},onRegisterError:console.warn,onRegistered(l){l&&setInterval(l.update,60*60*1e3)}})}),t()}); diff --git a/assets/index.dd7ca786.js b/assets/index.dd7ca786.js new file mode 100644 index 0000000..466318a --- /dev/null +++ b/assets/index.dd7ca786.js @@ -0,0 +1,16 @@ +/* empty css */import"./vue.92681fcb.js";import{Z as S,l as _e,u as vn,q as nn,C as r,b1 as ze,aa as V,aE as y,a0 as M,a1 as m,aK as Je,G as fe,t as T,aC as si,w as Le,b2 as Fe,a8 as u,O as F,ao as Ki,I as pe,ay as yn,ar as Mt,aG as on,A as Ne,_ as U,b6 as D,b8 as Tn,bs as Ji,aq as It,bu as Xt,bb as bn,T as Xi,a7 as g,j as Zi,bv as Jn,J as j,$ as P,aH as nt,aF as it,al as fn,aL as ht,aN as ke,z as tt,H as Yi,aJ as ai,bn as es,br as ts,be as ns}from"./@vue.4ce677c2.js";import{i as is}from"./is-plain-object.906d88e8.js";import{c as li}from"./nanoevents.1080beb7.js";import{L as mt}from"./lz-string.731cedc5.js";import{Y as ss}from"./vue-next-select.a2bfab1d.js";import{s as as,u as ri}from"./vue-toastification.6f567382.js";import{D as ls}from"./vuedraggable.7949458c.js";import{p as rs}from"./vue-textarea-autosize.35804eaf.js";import{v as os,n as us}from"./workbox-window.8d14e8b7.js";import"./sortablejs.29100d8a.js";const cs=function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const s of document.querySelectorAll('link[rel="modulepreload"]'))i(s);new MutationObserver(s=>{for(const l of s)if(l.type==="childList")for(const o of l.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&i(o)}).observe(document,{childList:!0,subtree:!0});function n(s){const l={};return s.integrity&&(l.integrity=s.integrity),s.referrerpolicy&&(l.referrerPolicy=s.referrerpolicy),s.crossorigin==="use-credentials"?l.credentials="include":s.crossorigin==="anonymous"?l.credentials="omit":l.credentials="same-origin",l}function i(s){if(s.ep)return;s.ep=!0;const l=n(s);fetch(s.href,l)}};cs();const ds="modulepreload",Xn={},fs="./",mn=function(t,n){return!n||n.length===0?t():Promise.all(n.map(i=>{if(i=`${fs}${i}`,i in Xn)return;Xn[i]=!0;const s=i.endsWith(".css"),l=s?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${i}"]${l}`))return;const o=document.createElement("link");if(o.rel=s?"stylesheet":ds,s||(o.as="script",o.crossOrigin=""),o.href=i,document.head.appendChild(o),s)return new Promise((c,f)=>{o.addEventListener("load",c),o.addEventListener("error",()=>f(new Error(`Unable to preload CSS for ${i}`)))})})).then(()=>t())},ms="./projInfo-schema.json",ps="Advent Incremental",hs="An incremental game you play a day at a time, leading up to Christmas!",gs="advent-incremental",vs="thepaperpilot",ys="",bs="",_s="0.3",ws="Initial Commit",Ns=!0,ks=!1,Cs=2,Ss=!0,Ms=null,Is="",As=["main"],Es=3600,$s=0,Ps=!0,Ts="base64";var W={$schema:ms,title:ps,description:hs,id:gs,author:vs,discordName:ys,discordLink:bs,versionNumber:_s,versionTitle:ws,allowGoBack:Ns,defaultShowSmall:ks,defaultDecimalsShown:Cs,useHeader:Ss,banner:Ms,logo:Is,initialTabs:As,maxTickLength:Es,offlineLimit:$s,enablePausing:Ps,exportEncoding:Ts};const En=17,xs=9e15,Fs=Math.log10(9e15),Bs=1/9e15,Ds=308,Os=-324,Zn=5,Rs=function(){const e=[];for(let n=Os+1;n<=Ds;n++)e.push(Number("1e"+n));const t=323;return function(n){return e[n+t]}}(),Nt=[2,Math.E,3,4,5,6,7,8,9,10],qs=[[1,1.0891168053867777,1.1789745164521264,1.2701428397304229,1.3632066654400328,1.4587804913784246,1.557523817412741,1.660158301473385,1.767487542936873,1.8804205225512542,2],[1,1.1121114330934,1.23103892493161,1.35838369631113,1.49605193039935,1.64635423375119,1.81213853570186,1.99697132461829,2.20538955455724,2.44325744833852,Math.E],[1,1.1187738849693603,1.2464963939368214,1.38527004705667,1.5376664685821402,1.7068895236551784,1.897001227148399,2.1132403089001035,2.362480153784171,2.6539010333870774,3],[1,1.1367350847096405,1.2889510672956703,1.4606478703324786,1.6570295196661111,1.8850062585672889,2.1539465047453485,2.476829779693097,2.872061932789197,3.3664204535587183,4],[1,1.1494592900767588,1.319708228183931,1.5166291280087583,1.748171114438024,2.0253263297298045,2.3636668498288547,2.7858359149579424,3.3257226212448145,4.035730287722532,5],[1,1.159225940787673,1.343712473580932,1.5611293155111927,1.8221199554561318,2.14183924486326,2.542468319282638,3.0574682501653316,3.7390572020926873,4.6719550537360774,6],[1,1.1670905356972596,1.3632807444991446,1.5979222279405536,1.8842640123816674,2.2416069644878687,2.69893426559423,3.3012632110403577,4.121250340630164,5.281493033448316,7],[1,1.1736630594087796,1.379783782386201,1.6292821855668218,1.9378971836180754,2.3289975651071977,2.8384347394720835,3.5232708454565906,4.478242031114584,5.868592169644505,8],[1,1.1793017514670474,1.394054150657457,1.65664127441059,1.985170999970283,2.4069682290577457,2.9647310119960752,3.7278665320924946,4.814462547283592,6.436522247411611,9],[1,1.18422737399915,1.4066113788546144,1.680911177655277,2.027492094355525,2.4775152854601967,3.080455730250329,3.918234505962507,5.1332705696484595,6.9878696918072905,10]],Vs=[[-1,-.9194161097107025,-.8335625019330468,-.7425599821143978,-.6466611521029437,-.5462617907227869,-.4419033816638769,-.3342645487554494,-.224140440909962,-.11241087890006762,0],[-1,-.90603157029014,-.80786507256596,-.7064666939634,-.60294836853664,-.49849837513117,-.39430303318768,-.29147201034755,-.19097820800866,-.09361896280296,0],[-1,-.9021579584316141,-.8005762598234203,-.6964780623319391,-.5911906810998454,-.486050182576545,-.3823089430815083,-.28106046722897615,-.1831906535795894,-.08935809204418144,0],[-1,-.8917227442365535,-.781258746326964,-.6705130326902455,-.5612813129406509,-.4551067709033134,-.35319256652135966,-.2563741554088552,-.1651412821106526,-.0796919581982668,0],[-1,-.8843387974366064,-.7678744063886243,-.6529563724510552,-.5415870994657841,-.4352842206588936,-.33504449124791424,-.24138853420685147,-.15445285440944467,-.07409659641336663,0],[-1,-.8786709358426346,-.7577735191184886,-.6399546189952064,-.527284921869926,-.4211627631006314,-.3223479611761232,-.23107655627789858,-.1472057700818259,-.07035171210706326,0],[-1,-.8740862815291583,-.7497032990976209,-.6297119746181752,-.5161838335958787,-.41036238255751956,-.31277212146489963,-.2233976621705518,-.1418697367979619,-.06762117662323441,0],[-1,-.8702632331800649,-.7430366914122081,-.6213373075161548,-.5072025698095242,-.40171437727184167,-.30517930701410456,-.21736343968190863,-.137710238299109,-.06550774483471955,0],[-1,-.8670016295947213,-.7373984232432306,-.6143173985094293,-.49973884395492807,-.394584953527678,-.2989649949848695,-.21245647317021688,-.13434688362382652,-.0638072667348083,0],[-1,-.8641642839543857,-.732534623168535,-.6083127477059322,-.4934049257184696,-.3885773075899922,-.29376029055315767,-.2083678561173622,-.13155653399373268,-.062401588652553186,0]],h=function(t){return a.fromValue_noAlloc(t)},O=function(e,t,n){return a.fromComponents(e,t,n)},H=function(t,n,i){return a.fromComponents_noNormalize(t,n,i)},dt=function(t,n){const i=n+1,s=Math.ceil(Math.log10(Math.abs(t))),l=Math.round(t*Math.pow(10,i-s))*Math.pow(10,s-i);return parseFloat(l.toFixed(Math.max(i-s,0)))},$n=function(e){return Math.sign(e)*Math.log10(Math.abs(e))},Ls=function(e){if(!isFinite(e))return e;if(e<-50)return e===Math.trunc(e)?Number.NEGATIVE_INFINITY:0;let t=1;for(;e<10;)t=t*e,++e;e-=1;let n=.9189385332046727;n=n+(e+.5)*Math.log(e),n=n-e;const i=e*e;let s=e;return n=n+1/(12*s),s=s*i,n=n+1/(360*s),s=s*i,n=n+1/(1260*s),s=s*i,n=n+1/(1680*s),s=s*i,n=n+1/(1188*s),s=s*i,n=n+691/(360360*s),s=s*i,n=n+7/(1092*s),s=s*i,n=n+3617/(122400*s),Math.exp(n)/t},oi=.5671432904097838,Yn=function(e,t=1e-10){let n,i;if(!Number.isFinite(e)||e===0)return e;if(e===1)return oi;e<10?n=0:n=Math.log(e)-Math.log(Math.log(e));for(let s=0;s<100;++s){if(i=(e*Math.exp(-n)+n*n)/(n+1),Math.abs(i-n).5?1:-1;if(Math.random()*20<1)return H(t,0,1);const n=Math.floor(Math.random()*(e+1));let i=n===0?Math.random()*616-308:Math.random()*16;Math.random()>.9&&(i=Math.trunc(i));let s=Math.pow(10,i);return Math.random()>.9&&(s=Math.trunc(s)),O(t,n,s)}static affordGeometricSeries_core(e,t,n,i){const s=t.mul(n.pow(i));return w.floor(e.div(s).mul(n.sub(1)).add(1).log10().div(n.log10()))}static sumGeometricSeries_core(e,t,n,i){return t.mul(n.pow(i)).mul(w.sub(1,n.pow(e))).div(w.sub(1,n))}static affordArithmeticSeries_core(e,t,n,i){const l=t.add(i.mul(n)).sub(n.div(2)),o=l.pow(2);return l.neg().add(o.add(n.mul(e).mul(2)).sqrt()).div(n).floor()}static sumArithmeticSeries_core(e,t,n,i){const s=t.add(i.mul(n));return e.div(2).mul(s.mul(2).plus(e.sub(1).mul(n)))}static efficiencyOfPurchase_core(e,t,n){return e.div(t).add(e.div(n))}normalize(){if(this.sign===0||this.mag===0&&this.layer===0)return this.sign=0,this.mag=0,this.layer=0,this;if(this.layer===0&&this.mag<0&&(this.mag=-this.mag,this.sign=-this.sign),this.layer===0&&this.mag=xs)return this.layer+=1,this.mag=t*Math.log10(e),this;for(;e0;)this.layer-=1,this.layer===0?this.mag=Math.pow(10,this.mag):(this.mag=t*Math.pow(10,e),e=Math.abs(this.mag),t=Math.sign(this.mag));return this.layer===0&&(this.mag<0?(this.mag=-this.mag,this.sign=-this.sign):this.mag===0&&(this.sign=0)),this}fromComponents(e,t,n){return this.sign=e,this.layer=t,this.mag=n,this.normalize(),this}fromComponents_noNormalize(e,t,n){return this.sign=e,this.layer=t,this.mag=n,this}fromMantissaExponent(e,t){return this.layer=1,this.sign=Math.sign(e),e=Math.abs(e),this.mag=t+Math.log10(e),this.normalize(),this}fromMantissaExponent_noNormalize(e,t){return this.fromMantissaExponent(e,t),this}fromDecimal(e){return this.sign=e.sign,this.layer=e.layer,this.mag=e.mag,this}fromNumber(e){return this.mag=Math.abs(e),this.sign=Math.sign(e),this.layer=0,this.normalize(),this}fromString(e){e=e.replace(",","");const t=e.split("^^^");if(t.length===2){const v=parseFloat(t[0]),p=parseFloat(t[1]),k=t[1].split(";");let C=1;if(k.length===2&&(C=parseFloat(k[1]),isFinite(C)||(C=1)),isFinite(v)&&isFinite(p)){const R=w.pentate(v,p,C);return this.sign=R.sign,this.layer=R.layer,this.mag=R.mag,this}}const n=e.split("^^");if(n.length===2){const v=parseFloat(n[0]),p=parseFloat(n[1]),k=n[1].split(";");let C=1;if(k.length===2&&(C=parseFloat(k[1]),isFinite(C)||(C=1)),isFinite(v)&&isFinite(p)){const R=w.tetrate(v,p,C);return this.sign=R.sign,this.layer=R.layer,this.mag=R.mag,this}}const i=e.split("^");if(i.length===2){const v=parseFloat(i[0]),p=parseFloat(i[1]);if(isFinite(v)&&isFinite(p)){const k=w.pow(v,p);return this.sign=k.sign,this.layer=k.layer,this.mag=k.mag,this}}e=e.trim().toLowerCase();let s,l,o=e.split("pt");if(o.length===2){s=10,l=parseFloat(o[0]),o[1]=o[1].replace("(",""),o[1]=o[1].replace(")","");let v=parseFloat(o[1]);if(isFinite(v)||(v=1),isFinite(s)&&isFinite(l)){const p=w.tetrate(s,l,v);return this.sign=p.sign,this.layer=p.layer,this.mag=p.mag,this}}if(o=e.split("p"),o.length===2){s=10,l=parseFloat(o[0]),o[1]=o[1].replace("(",""),o[1]=o[1].replace(")","");let v=parseFloat(o[1]);if(isFinite(v)||(v=1),isFinite(s)&&isFinite(l)){const p=w.tetrate(s,l,v);return this.sign=p.sign,this.layer=p.layer,this.mag=p.mag,this}}const c=e.split("e"),f=c.length-1;if(f===0){const v=parseFloat(e);if(isFinite(v))return this.fromNumber(v)}else if(f===1){const v=parseFloat(e);if(isFinite(v)&&v!==0)return this.fromNumber(v)}const d=e.split("e^");if(d.length===2){this.sign=1,d[0].charAt(0)=="-"&&(this.sign=-1);let v="";for(let p=0;p=43&&k<=57||k===101)v+=d[1].charAt(p);else return this.layer=parseFloat(v),this.mag=parseFloat(d[1].substr(p+1)),this.normalize(),this}}if(f<1)return this.sign=0,this.layer=0,this.mag=0,this;const _=parseFloat(c[0]);if(_===0)return this.sign=0,this.layer=0,this.mag=0,this;let b=parseFloat(c[c.length-1]);if(f>=2){const v=parseFloat(c[c.length-2]);isFinite(v)&&(b*=Math.sign(v),b+=$n(v))}if(!isFinite(_))this.sign=c[0]==="-"?-1:1,this.layer=f,this.mag=b;else if(f===1)this.sign=Math.sign(_),this.layer=1,this.mag=b+Math.log10(Math.abs(_));else if(this.sign=Math.sign(_),this.layer=f,f===2){const v=w.mul(O(1,2,b),h(_));return this.sign=v.sign,this.layer=v.layer,this.mag=v.mag,this}else this.mag=b;return this.normalize(),this}fromValue(e){return e instanceof w||e!=null&&typeof e=="object"&&"sign"in e&&"mag"in e&&"layer"in e?this.fromDecimal(e):typeof e=="number"?this.fromNumber(e):typeof e=="string"?this.fromString(e):(this.sign=0,this.layer=0,this.mag=0,this)}toNumber(){return Number.isFinite(this.layer)?this.layer===0?this.sign*this.mag:this.layer===1?this.sign*Math.pow(10,this.mag):this.mag>0?this.sign>0?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:0:Number.NaN}mantissaWithDecimalPlaces(e){return isNaN(this.m)?Number.NaN:this.m===0?0:dt(this.m,e)}magnitudeWithDecimalPlaces(e){return isNaN(this.mag)?Number.NaN:this.mag===0?0:dt(this.mag,e)}toString(){return isNaN(this.layer)||isNaN(this.sign)||isNaN(this.mag)?"NaN":this.mag===Number.POSITIVE_INFINITY||this.layer===Number.POSITIVE_INFINITY?this.sign===1?"Infinity":"-Infinity":this.layer===0?this.mag<1e21&&this.mag>1e-7||this.mag===0?(this.sign*this.mag).toString():this.m+"e"+this.e:this.layer===1?this.m+"e"+this.e:this.layer<=Zn?(this.sign===-1?"-":"")+"e".repeat(this.layer)+this.mag:(this.sign===-1?"-":"")+"(e^"+this.layer+")"+this.mag}toExponential(e){return this.layer===0?(this.sign*this.mag).toExponential(e):this.toStringWithDecimalPlaces(e)}toFixed(e){return this.layer===0?(this.sign*this.mag).toFixed(e):this.toStringWithDecimalPlaces(e)}toPrecision(e){return this.e<=-7?this.toExponential(e-1):e>this.e?this.toFixed(e-this.exponent-1):this.toExponential(e-1)}valueOf(){return this.toString()}toJSON(){return this.toString()}toStringWithDecimalPlaces(e){return this.layer===0?this.mag<1e21&&this.mag>1e-7||this.mag===0?(this.sign*this.mag).toFixed(e):dt(this.m,e)+"e"+dt(this.e,e):this.layer===1?dt(this.m,e)+"e"+dt(this.e,e):this.layer<=Zn?(this.sign===-1?"-":"")+"e".repeat(this.layer)+dt(this.mag,e):(this.sign===-1?"-":"")+"(e^"+this.layer+")"+dt(this.mag,e)}abs(){return H(this.sign===0?0:1,this.layer,this.mag)}neg(){return H(-this.sign,this.layer,this.mag)}negate(){return this.neg()}negated(){return this.neg()}sgn(){return this.sign}round(){return this.mag<0?w.dZero:this.layer===0?O(this.sign,0,Math.round(this.mag)):this}floor(){return this.mag<0?w.dZero:this.layer===0?O(this.sign,0,Math.floor(this.mag)):this}ceil(){return this.mag<0?w.dZero:this.layer===0?O(this.sign,0,Math.ceil(this.mag)):this}trunc(){return this.mag<0?w.dZero:this.layer===0?O(this.sign,0,Math.trunc(this.mag)):this}add(e){const t=h(e);if(!Number.isFinite(this.layer))return this;if(!Number.isFinite(t.layer)||this.sign===0)return t;if(t.sign===0)return this;if(this.sign===-t.sign&&this.layer===t.layer&&this.mag===t.mag)return H(0,0,0);let n,i;if(this.layer>=2||t.layer>=2)return this.maxabs(t);if(w.cmpabs(this,t)>0?(n=this,i=t):(n=t,i=this),n.layer===0&&i.layer===0)return h(n.sign*n.mag+i.sign*i.mag);const s=n.layer*Math.sign(n.mag),l=i.layer*Math.sign(i.mag);if(s-l>=2)return n;if(s===0&&l===-1){if(Math.abs(i.mag-Math.log10(n.mag))>En)return n;{const o=Math.pow(10,Math.log10(n.mag)-i.mag),c=i.sign+n.sign*o;return O(Math.sign(c),1,i.mag+Math.log10(Math.abs(c)))}}if(s===1&&l===0){if(Math.abs(n.mag-Math.log10(i.mag))>En)return n;{const o=Math.pow(10,n.mag-Math.log10(i.mag)),c=i.sign+n.sign*o;return O(Math.sign(c),1,Math.log10(i.mag)+Math.log10(Math.abs(c)))}}if(Math.abs(n.mag-i.mag)>En)return n;{const o=Math.pow(10,n.mag-i.mag),c=i.sign+n.sign*o;return O(Math.sign(c),1,i.mag+Math.log10(Math.abs(c)))}}plus(e){return this.add(e)}sub(e){return this.add(h(e).neg())}subtract(e){return this.sub(e)}minus(e){return this.sub(e)}mul(e){const t=h(e);if(!Number.isFinite(this.layer))return this;if(!Number.isFinite(t.layer))return t;if(this.sign===0||t.sign===0)return H(0,0,0);if(this.layer===t.layer&&this.mag===-t.mag)return H(this.sign*t.sign,0,1);let n,i;if(this.layer>t.layer||this.layer==t.layer&&Math.abs(this.mag)>Math.abs(t.mag)?(n=this,i=t):(n=t,i=this),n.layer===0&&i.layer===0)return h(n.sign*i.sign*n.mag*i.mag);if(n.layer>=3||n.layer-i.layer>=2)return O(n.sign*i.sign,n.layer,n.mag);if(n.layer===1&&i.layer===0)return O(n.sign*i.sign,1,n.mag+Math.log10(i.mag));if(n.layer===1&&i.layer===1)return O(n.sign*i.sign,1,n.mag+i.mag);if(n.layer===2&&i.layer===1){const s=O(Math.sign(n.mag),n.layer-1,Math.abs(n.mag)).add(O(Math.sign(i.mag),i.layer-1,Math.abs(i.mag)));return O(n.sign*i.sign,s.layer+1,s.sign*s.mag)}if(n.layer===2&&i.layer===2){const s=O(Math.sign(n.mag),n.layer-1,Math.abs(n.mag)).add(O(Math.sign(i.mag),i.layer-1,Math.abs(i.mag)));return O(n.sign*i.sign,s.layer+1,s.sign*s.mag)}throw Error("Bad arguments to mul: "+this+", "+e)}multiply(e){return this.mul(e)}times(e){return this.mul(e)}div(e){const t=h(e);return this.mul(t.recip())}divide(e){return this.div(e)}divideBy(e){return this.div(e)}dividedBy(e){return this.div(e)}recip(){return this.mag===0?w.dNaN:this.layer===0?O(this.sign,0,1/this.mag):O(this.sign,this.layer,-this.mag)}reciprocal(){return this.recip()}reciprocate(){return this.recip()}cmp(e){const t=h(e);return this.sign>t.sign?1:this.sign0?this.layer:-this.layer,i=t.mag>0?t.layer:-t.layer;return n>i?1:nt.mag?1:this.mag0?t:this}clamp(e,t){return this.max(e).min(t)}clampMin(e){return this.max(e)}clampMax(e){return this.min(e)}cmp_tolerance(e,t){const n=h(e);return this.eq_tolerance(n,t)?0:this.cmp(n)}compare_tolerance(e,t){return this.cmp_tolerance(e,t)}eq_tolerance(e,t){const n=h(e);if(t==null&&(t=1e-7),this.sign!==n.sign||Math.abs(this.layer-n.layer)>1)return!1;let i=this.mag,s=n.mag;return this.layer>n.layer&&(s=$n(s)),this.layer0?O(Math.sign(this.mag),this.layer-1,Math.abs(this.mag)):O(1,0,Math.log10(this.mag))}log10(){return this.sign<=0?w.dNaN:this.layer>0?O(Math.sign(this.mag),this.layer-1,Math.abs(this.mag)):O(this.sign,0,Math.log10(this.mag))}log(e){return e=h(e),this.sign<=0||e.sign<=0||e.sign===1&&e.layer===0&&e.mag===1?w.dNaN:this.layer===0&&e.layer===0?O(this.sign,0,Math.log(this.mag)/Math.log(e.mag)):w.div(this.log10(),e.log10())}log2(){return this.sign<=0?w.dNaN:this.layer===0?O(this.sign,0,Math.log2(this.mag)):this.layer===1?O(Math.sign(this.mag),0,Math.abs(this.mag)*3.321928094887362):this.layer===2?O(Math.sign(this.mag),1,Math.abs(this.mag)+.5213902276543247):O(Math.sign(this.mag),this.layer-1,Math.abs(this.mag))}ln(){return this.sign<=0?w.dNaN:this.layer===0?O(this.sign,0,Math.log(this.mag)):this.layer===1?O(Math.sign(this.mag),0,Math.abs(this.mag)*2.302585092994046):this.layer===2?O(Math.sign(this.mag),1,Math.abs(this.mag)+.36221568869946325):O(Math.sign(this.mag),this.layer-1,Math.abs(this.mag))}logarithm(e){return this.log(e)}pow(e){const t=h(e),n=this,i=t;if(n.sign===0)return i.eq(0)?H(1,0,1):n;if(n.sign===1&&n.layer===0&&n.mag===1)return n;if(i.sign===0)return H(1,0,1);if(i.sign===1&&i.layer===0&&i.mag===1)return n;const s=n.absLog10().mul(i).pow10();return this.sign===-1?Math.abs(i.toNumber()%2)%2===1?s.neg():Math.abs(i.toNumber()%2)%2===0?s:w.dNaN:s}pow10(){if(!Number.isFinite(this.layer)||!Number.isFinite(this.mag))return w.dNaN;let e=this;if(e.layer===0){const t=Math.pow(10,e.sign*e.mag);if(Number.isFinite(t)&&Math.abs(t)>=.1)return O(1,0,t);if(e.sign===0)return w.dOne;e=H(e.sign,e.layer+1,Math.log10(e.mag))}return e.sign>0&&e.mag>=0?O(e.sign,e.layer+1,e.mag):e.sign<0&&e.mag>=0?O(-e.sign,e.layer+1,-e.mag):w.dOne}pow_base(e){return h(e).pow(this)}root(e){const t=h(e);return this.pow(t.recip())}factorial(){return this.mag<0?this.add(1).gamma():this.layer===0?this.add(1).gamma():this.layer===1?w.exp(w.mul(this,w.ln(this).sub(1))):w.exp(this)}gamma(){if(this.mag<0)return this.recip();if(this.layer===0){if(this.lt(H(1,0,24)))return h(Ls(this.sign*this.mag));const e=this.mag-1;let t=.9189385332046727;t=t+(e+.5)*Math.log(e),t=t-e;const n=e*e;let i=e,s=12*i,l=1/s,o=t+l;if(o===t||(t=o,i=i*n,s=360*i,l=1/s,o=t-l,o===t))return w.exp(t);t=o,i=i*n,s=1260*i;let c=1/s;return t=t+c,i=i*n,s=1680*i,c=1/s,t=t-c,w.exp(t)}else return this.layer===1?w.exp(w.mul(this,w.ln(this).sub(1))):w.exp(this)}lngamma(){return this.gamma().ln()}exp(){return this.mag<0?w.dOne:this.layer===0&&this.mag<=709.7?h(Math.exp(this.sign*this.mag)):this.layer===0?O(1,1,this.sign*Math.log10(Math.E)*this.mag):this.layer===1?O(1,2,this.sign*(Math.log10(.4342944819032518)+this.mag)):O(1,this.layer+1,this.sign*this.mag)}sqr(){return this.pow(2)}sqrt(){if(this.layer===0)return h(Math.sqrt(this.sign*this.mag));if(this.layer===1)return O(1,2,Math.log10(this.mag)-.3010299956639812);{const e=w.div(H(this.sign,this.layer-1,this.mag),H(1,0,2));return e.layer+=1,e.normalize(),e}}cube(){return this.pow(3)}cbrt(){return this.pow(1/3)}tetrate(e=2,t=H(1,0,1)){if(e===1)return w.pow(this,t);if(e===0)return new w(t);if(this.eq(w.dOne))return w.dOne;if(this.eq(-1))return w.pow(this,t);if(e===Number.POSITIVE_INFINITY){const s=this.toNumber();if(s<=1.444667861009766&&s>=.06598803584531254){if(s>1.444667861009099)return new w(Math.E);const l=w.ln(this).neg();return l.lambertw().div(l)}else return s>1.444667861009766?new w(Number.POSITIVE_INFINITY):w.dNaN}if(this.eq(w.dZero)){let s=Math.abs((e+1)%2);return s>1&&(s=2-s),new w(s)}if(e<0)return w.iteratedlog(t,this,-e);t=h(t);const n=e;e=Math.trunc(e);const i=n-e;if(this.gt(w.dZero)&&this.lte(1.444667861009766)){e=Math.min(1e4,e);for(let s=0;s3)return H(t.sign,t.layer+(e-s-1),t.mag);if(s>1e4)return t}return t}iteratedexp(e=2,t=H(1,0,1)){return this.tetrate(e,t)}iteratedlog(e=10,t=1){if(t<0)return w.tetrate(e,-t,this);e=h(e);let n=h(this);const i=t;t=Math.trunc(t);const s=i-t;if(n.layer-e.layer>3){const l=Math.min(t,n.layer-e.layer-3);t-=l,n.layer-=l}for(let l=0;l1e4)return n}return s>0&&s<1&&(e.eq(10)?n=n.layeradd10(-s):n=n.layeradd(-s,e)),n}slog(e=10){if(e=h(e),e.lte(w.dZero)||e.eq(w.dOne))return w.dNaN;if(e.lt(w.dOne))return this.eq(w.dOne)?w.dZero:this.eq(w.dZero)?w.dNegOne:w.dNaN;if(this.mag<0||this.eq(w.dZero))return w.dNegOne;let t=0,n=h(this);if(n.layer-e.layer>3){const i=n.layer-e.layer-3;t+=i,n.layer-=i}for(let i=0;i<100;++i)if(n.lt(w.dZero))n=w.pow(e,n),t-=1;else{if(n.lte(w.dOne))return h(t+w.slog_critical(e.toNumber(),n.toNumber()));t+=1,n=w.log(n,e)}return h(t)}static slog_critical(e,t){return e>10?t-1:w.critical_section(e,t,Vs)}static tetrate_critical(e,t){return w.critical_section(e,t,qs)}static critical_section(e,t,n){t*=10,t<0&&(t=0),t>10&&(t=10),e<2&&(e=2),e>10&&(e=10);let i=0,s=0;for(let c=0;ce){const f=(e-Nt[c])/(Nt[c+1]-Nt[c]);i=n[c][Math.floor(t)]*(1-f)+n[c+1][Math.floor(t)]*f,s=n[c][Math.ceil(t)]*(1-f)+n[c+1][Math.ceil(t)]*f;break}const l=t-Math.floor(t);return i*(1-l)+s*l}layeradd10(e){e=w.fromValue_noAlloc(e).toNumber();const t=h(this);if(e>=1){t.mag<0&&t.layer>0?(t.sign=0,t.mag=0,t.layer=0):t.sign===-1&&t.layer==0&&(t.sign=1,t.mag=-t.mag);const n=Math.trunc(e);e-=n,t.layer+=n}if(e<=-1){const n=Math.trunc(e);if(e-=n,t.layer+=n,t.layer<0)for(let i=0;i<100;++i){if(t.layer++,t.mag=Math.log10(t.mag),!isFinite(t.mag))return t.sign===0&&(t.sign=1),t.layer<0&&(t.layer=0),t.normalize();if(t.layer>=0)break}}for(;t.layer<0;)t.layer++,t.mag=Math.log10(t.mag);return t.sign===0&&(t.sign=1,t.mag===0&&t.layer>=1&&(t.layer-=1,t.mag=1)),t.normalize(),e!==0?t.layeradd(e,10):t}layeradd(e,t){const i=this.slog(t).toNumber()+e;return i>=0?w.tetrate(t,i):Number.isFinite(i)?i>=-1?w.log(w.tetrate(t,i+1),t):w.log(w.log(w.tetrate(t,i+2),t),t):w.dNaN}lambertw(){if(this.lt(-.3678794411710499))throw Error("lambertw is unimplemented for results less than -1, sorry!");if(this.mag<0)return h(Yn(this.toNumber()));if(this.layer===0)return h(Yn(this.sign*this.mag));if(this.layer===1)return ei(this);if(this.layer===2)return ei(this);if(this.layer>=3)return H(this.sign,this.layer-1,this.mag);throw"Unhandled behavior in lambertw()"}ssqrt(){if(this.sign==1&&this.layer>=3)return H(this.sign,this.layer-1,this.mag);const e=this.ln();return e.div(e.lambertw())}pentate(e=2,t=H(1,0,1)){t=h(t);const n=e;e=Math.trunc(e);const i=n-e;i!==0&&(t.eq(w.dOne)?(++e,t=new w(i)):this.eq(10)?t=t.layeradd10(i):t=t.layeradd(i,this));for(let s=0;s10)return t}return t}sin(){return this.mag<0?this:this.layer===0?h(Math.sin(this.sign*this.mag)):H(0,0,0)}cos(){return this.mag<0?w.dOne:this.layer===0?h(Math.cos(this.sign*this.mag)):H(0,0,0)}tan(){return this.mag<0?this:this.layer===0?h(Math.tan(this.sign*this.mag)):H(0,0,0)}asin(){return this.mag<0?this:this.layer===0?h(Math.asin(this.sign*this.mag)):H(Number.NaN,Number.NaN,Number.NaN)}acos(){return this.mag<0?h(Math.acos(this.toNumber())):this.layer===0?h(Math.acos(this.sign*this.mag)):H(Number.NaN,Number.NaN,Number.NaN)}atan(){return this.mag<0?this:this.layer===0?h(Math.atan(this.sign*this.mag)):h(Math.atan(this.sign*(1/0)))}sinh(){return this.exp().sub(this.negate().exp()).div(2)}cosh(){return this.exp().add(this.negate().exp()).div(2)}tanh(){return this.sinh().div(this.cosh())}asinh(){return w.ln(this.add(this.sqr().add(1).sqrt()))}acosh(){return w.ln(this.add(this.sqr().sub(1).sqrt()))}atanh(){return this.abs().gte(1)?H(Number.NaN,Number.NaN,Number.NaN):w.ln(this.add(1).div(h(1).sub(this))).div(2)}ascensionPenalty(e){return e===0?this:this.root(w.pow(10,e))}egg(){return this.add(9)}lessThanOrEqualTo(e){return this.cmp(e)<1}lessThan(e){return this.cmp(e)<0}greaterThanOrEqualTo(e){return this.cmp(e)>-1}greaterThan(e){return this.cmp(e)>0}};let a=w;a.dZero=H(0,0,0);a.dOne=H(1,0,1);a.dNegOne=H(-1,0,1);a.dTwo=H(1,0,2);a.dTen=H(1,0,10);a.dNaN=H(Number.NaN,Number.NaN,Number.NaN);a.dInf=H(1,Number.POSITIVE_INFINITY,Number.POSITIVE_INFINITY);a.dNegInf=H(-1,Number.NEGATIVE_INFINITY,Number.NEGATIVE_INFINITY);a.dNumberMax=O(1,0,Number.MAX_VALUE);a.dNumberMin=O(1,0,Number.MIN_VALUE);const Gs=new a(1);function Qt(e,t,n=!0){let i=a.log10(e).floor(),s=a.div(e,a.pow(10,i));s.toStringWithDecimalPlaces(t)==="10"&&(s=Gs,i=i.add(1));const l=i.gte(1e9)?Ge(i,Math.max(Math.max(t,3),W.defaultDecimalsShown)):i.gte(1e4)?pn(i,0):i.toStringWithDecimalPlaces(0);return n?s.toStringWithDecimalPlaces(t)+"e"+l:"e"+l}function pn(e,t){if(e==null)return"NaN";if(e=new a(e),e.mag<.001)return 0 .toFixed(t);const i=e.toStringWithDecimalPlaces(t).split(".");return i[0]=i[0].replace(/(\d)(?=(\d\d\d)+(?!\d))/g,"$1,"),i.length==1?i[0]:i[0]+"."+i[1]}function ui(e,t){return e==null?"NaN":(e=new a(e),e.mag<1e-4?0 .toFixed(t):(e.mag<.1&&t!==0&&(t=Math.max(Math.max(t,e.log10().negate().ceil().toNumber()),W.defaultDecimalsShown)),e.toStringWithDecimalPlaces(t)))}const Us=new a("eeee1000"),Hs=new a("e100000"),ti=new a("e1000"),ci=new a(1e9),js=new a(1e6),zs=new a(1e3),Ws=new a(.98),Qs=new a(.001),di=new a(0);function Ge(e,t,n){if(t==null&&(t=W.defaultDecimalsShown),n=n!=null?n:W.defaultShowSmall,e=new a(e),isNaN(e.sign)||isNaN(e.layer)||isNaN(e.mag))return"NaN";if(e.sign<0)return"-"+Ge(e.neg(),t);if(e.mag===Number.POSITIVE_INFINITY)return"Infinity";if(e.gte(Us)){const i=e.slog();return i.gte(js)?"F"+Ge(i.floor()):a.pow(10,i.sub(i.floor())).toStringWithDecimalPlaces(3)+"F"+pn(i.floor(),0)}else{if(e.gte(Hs))return Qt(e,0,!1);if(e.gte(ti))return Qt(e,0);if(e.gte(ci))return Qt(e,t);if(e.gte(zs))return pn(e,0);if(e.gte(Qs)||!n)return ui(e,t);if(e.eq(di))return 0 .toFixed(t)}return e=mi(e),e.lt(ti)?Qt(e,t).replace(/([^(?:e|F)]*)$/,"-$1"):Ge(e,t)+"\u207B\xB9"}function Ve(e){return e=new a(e),e.sign<0?"-"+Ve(e.neg()):e.gte(ci)||e.lte(Ws)&&!e.eq(di)?Ge(e):Ge(e,0)}function fi(e){return a.lt(e,0)?"-"+fi(a.neg(e)):a.gt(e,2**51)?Ge(a.div(e,31536e3))+"y":(e=new a(e).toNumber(),e<60?Ge(e)+"s":e<3600?Ve(Math.floor(e/60))+"m "+Ge(e%60)+"s":e<86400?Ve(Math.floor(e/3600))+"h "+Ve(Math.floor(e/60)%60)+"m "+Ve(e%60)+"s":e<31536e3?Ve(Math.floor(e/84600)%365)+"d "+Ve(Math.floor(e/3600)%24)+"h "+Ve(Math.floor(e/60)%60)+"m":Ve(Math.floor(e/31536e3))+"y "+Ve(Math.floor(e/84600)%365)+"d "+Ve(Math.floor(e/3600)%24)+"h")}function Ks(e,t,n){e=new a(e);let i=e.toStringWithDecimalPlaces(t);return new a(i).gte(n)&&(i=a.sub(n,Math.pow(.1,t)).toStringWithDecimalPlaces(t)),i}function Js(e,t){return Ge(e,t,!0)}function mi(e){let t=a.log10(e).ceil();const n=a.div(e,a.pow(10,t));return t=t.neg(),e=new a(10).pow(t).times(n),e}var Xs=Object.freeze(Object.defineProperty({__proto__:null,default:a,exponentialFormat:Qt,commaFormat:pn,regularFormat:ui,format:Ge,formatWhole:Ve,formatTime:fi,toPlaces:Ks,formatSmall:Js,invertOOM:mi},Symbol.toStringTag,{value:"Module"}));const{exponentialFormat:Zs,commaFormat:Ys,regularFormat:ea,format:te,formatWhole:G,formatTime:_n,toPlaces:ta,formatSmall:na,invertOOM:ia}=Xs;window.Decimal=a;window.exponentialFormat=Zs;window.commaFormat=Ys;window.regularFormat=ea;window.format=te;window.formatWhole=G;window.formatTime=_n;window.toPlaces=ta;window.formatSmall=na;window.invertOOM=ia;function pi(e){let t=e.replace(/([A-Z])/g," $1");return t=t.charAt(0).toUpperCase()+t.slice(1),t}function Pn(e){return typeof e=="function"}var J=(e=>(e.Up="Up",e.Down="Down",e.Left="Left",e.Right="Right",e.Default="Up",e))(J||{});const Zt=Symbol("DoNotCache");function E(e,t){const n=e[t];Pn(n)&&n.length===0&&!n[Zt]?e[t]=S(n.bind(e)):Pn(n)&&(e[t]=n.bind(e),e[t][Zt]=!0)}function Ae(e){return Pn(e)&&!e[Zt]&&(e=S(e)),e}const gt=Symbol("Component"),vt=Symbol("GatherProps");let sa=0;function Ot(e="feature-"){return e+sa++}var be=(e=>(e[e.Visible=0]="Visible",e[e.Hidden=1]="Hidden",e[e.None=2]="None",e))(be||{});function x(e){return e[Zt]=!0,e}function X(e,t=2){return e?0:t}function we(e,t,n){e[t]===void 0&&n!=null&&(e[t]=n)}function hi(e,...t){const n=[],i=s=>{Object.keys(s).forEach(l=>{const o=s[l];o&&typeof o=="object"&&(t.includes(o.type)?n.push(o):!(o instanceof a)&&!_e(o)&&i(o))})};return i(e),n}const kt={variables:{"--foreground":"#dfdfdf","--background":"#0f0f0f","--feature-foreground":"#0f0f0f","--tooltip-background":"rgba(0, 0, 0, 0.75)","--raised-background":"#0f0f0f","--points":"#ffffff","--locked":"#bf8f8f","--highlighted":"#333","--bought":"#77bf5f","--danger":"rgb(220, 53, 69)","--link":"#02f2f2","--outline":"#dfdfdf","--accent1":"#627a82","--accent2":"#658262","--accent3":"#7c6282","--border-radius":"15px","--modal-border":"solid 2px var(--color)","--feature-margin":"0px"},floatingTabs:!0,mergeAdjacent:!0,showPin:!0};var xn=(e=>(e.Classic="classic",e.Paper="paper",e.Nordic="nordic",e.Aqua="aqua",e))(xn||{}),sn={classic:kt,paper:{...kt,variables:{...kt.variables,"--background":"#2a323d","--feature-foreground":"#000","--raised-background":"#333c4a","--locked":"#3a3e45","--bought":"#5C8A58","--outline":"#333c4a","--border-radius":"4px","--modal-border":"","--feature-margin":"5px"},floatingTabs:!1},nordic:{...kt,variables:{...kt.variables,"--foreground":"#D8DEE9","--background":"#2E3440","--feature-foreground":"#000","--raised-background":"#3B4252","--points":"#E5E9F0","--locked":"#4c566a","--highlighted":"#434c5e","--bought":"#8FBCBB","--danger":"#D08770","--link":"#88C0D0","--outline":"#3B4252","--accent1":"#B48EAD","--accent2":"#A3BE8C","--accent3":"#EBCB8B","--border-radius":"4px","--modal-border":"solid 2px #3B4252","--feature-margin":"5px"},floatingTabs:!1},aqua:{...kt,variables:{...kt.variables,"--foreground":"#bfdfff","--background":"#001f3f","--tooltip-background":"rgba(0, 15, 31, 0.75)","--raised-background":"#001f3f","--points":"#dfefff","--locked":"#c4a7b3","--outline":"#bfdfff"}}};const oe=Symbol("ProxyState"),Pt=Symbol("ProxyPath");function Be(e,t={}){const n=t;let i=!1;function s(){return i||(Object.assign(n,e(n)),i=!0),n}return new Proxy(n,{get(l,o){return o===oe?s():s()[o]},set(l,o,c){return s()[o]=c,!0},has(l,o){return o===oe?!0:Reflect.has(s(),o)},ownKeys(){return Reflect.ownKeys(s())},getOwnPropertyDescriptor(l,o){return i||(Object.assign(n,e(n)),i=!0),Object.getOwnPropertyDescriptor(l,o)}})}var Y=window.state=vn({lastTenTicks:[],hasNaN:!1,NaNPath:[]});const gi=nn({id:"",devSpeed:null,name:"",tabs:[],time:-1,autosave:!0,offlineProd:!0,offlineTime:null,timePlayed:0,keepGoing:!1,modID:"",modVersion:"",layers:{}});function vi(e){return JSON.stringify(e,(t,n)=>r(n))}const yi={get(e,t){var i;if(t===oe||t===Pt)return e[t];const n=e[oe][t];if(t!=="value"&&(is(n)||Array.isArray(n))){if(n!==((i=e[t])==null?void 0:i[oe])){const s=[...e[Pt],t];e[t]=new Proxy({[oe]:n,[Pt]:s},yi)}return e[t]}return n},set(e,t,n,i){if(!Y.hasNaN&&(typeof n=="number"&&isNaN(n)||n instanceof a&&(isNaN(n.sign)||isNaN(n.layer)||isNaN(n.mag)))){const s=e[oe][t];if(!(typeof s=="number"&&isNaN(s)||s instanceof a&&(isNaN(s.sign)||isNaN(s.layer)||isNaN(s.mag))))throw gi.autosave=!1,Y.hasNaN=!0,Y.NaNPath=[...e[Pt],t],Y.NaNReceiver=i,console.error("Attempted to set NaN value",[...e[Pt],t],e[oe]),"Attempted to set NaN value. See above for details"}return e[oe][t]=n,!0},ownKeys(e){return Reflect.ownKeys(e[oe])},has(e,t){return Reflect.has(e[oe],t)},getOwnPropertyDescriptor(e,t){return Object.getOwnPropertyDescriptor(e[oe],t)}};var A=window.player=new Proxy({[oe]:gi,[Pt]:["player"]},yi);const le=li();let Tt=null,Kt=null;function hn(){const e=Date.now();let t=(e-A.time)/1e3;A.time=e;const n=t;if(Y.lastTenTicks.push(n),Y.lastTenTicks.length>10&&(Y.lastTenTicks=Y.lastTenTicks.slice(1)),!((Kt==null?void 0:Kt.value)&&!A.keepGoing)&&!Y.hasNaN&&(t=Math.max(t,0),A.devSpeed!==0)){if(A.offlineTime!=null){if(a.gt(A.offlineTime,W.offlineLimit*3600)&&(A.offlineTime=W.offlineLimit*3600),a.gt(A.offlineTime,0)&&A.devSpeed!==0){const i=Math.max(A.offlineTime/10,t);A.offlineTime=A.offlineTime-i,t+=i}else A.devSpeed===0&&(A.offlineTime+=t);(!A.offlineProd||a.lt(A.offlineTime,0))&&(A.offlineTime=null)}t=Math.min(t,W.maxTickLength),A.devSpeed!=null&&(t*=A.devSpeed),Number.isFinite(t)||(t=1e308),!a.eq(t,0)&&(A.timePlayed+=t,Number.isFinite(A.timePlayed)||(A.timePlayed=1e308),le.emit("update",t,n),ne.unthrottled?(requestAnimationFrame(hn),Tt!=null&&(clearInterval(Tt),Tt=null)):Tt==null&&(Tt=setInterval(hn,50)))}}async function aa(){Kt=(await mn(()=>Promise.resolve().then(function(){return Ri}),void 0)).hasWon,ze(Kt,e=>{e&&le.emit("gameWon")}),ne.unthrottled?requestAnimationFrame(hn):Tt=setInterval(hn,50)}document.fonts.onloadingdone=()=>le.emit("fontsLoaded");var la=Object.freeze(Object.defineProperty({__proto__:null,globalBus:le,startGameLoop:aa},Symbol.toStringTag,{value:"Module"}));function bi(e={}){return Object.assign({id:`${W.id}-0`,name:"Default Save",tabs:W.initialTabs.slice(),time:Date.now(),autosave:!0,offlineProd:!0,offlineTime:0,timePlayed:0,keepGoing:!1,modID:W.id,modVersion:W.versionNumber,layers:{}},e)}function He(e){const t=mt.compressToUTF16(vi(e!=null?e:A[oe]));return localStorage.setItem((e!=null?e:A[oe]).id,t),t}async function ra(){ua();try{let e=localStorage.getItem(ne.active);if(e==null){await Ct(xt());return}if(e[0]!=="{")if(e[0]==="e")e=decodeURIComponent(escape(atob(e)));else if(e[0]==="\u1BE1")e=mt.decompressFromUTF16(e);else throw"Unable to determine save encoding";const t=JSON.parse(e);if(t.modID!==W.id){await Ct(xt());return}t.id=ne.active,await Ct(t)}catch(e){console.error(`Failed to load save. Falling back to new save. +`,e),await Ct(xt())}}function xt(){const e=cn(),t=bi({id:e});return He(t),ne.saves.push(e),t}function cn(){let e,t=0;do e=`${W.id}-${t++}`;while(localStorage.getItem(e));return e}async function Ct(e){console.info("Loading save",e);const{layers:t,removeLayer:n,addLayer:i}=await mn(()=>Promise.resolve().then(function(){return $a}),void 0),{fixOldSave:s,getInitialLayers:l}=await mn(()=>Promise.resolve().then(function(){return Ri}),void 0);for(const o in t){const c=t[o];c&&n(c)}l(e).forEach(o=>i(o,e)),e=bi(e),e.offlineProd&&e.time&&e.devSpeed!==0&&(e.offlineTime==null&&(e.offlineTime=0),e.offlineTime+=Math.min(e.offlineTime+(Date.now()-e.time)/1e3,W.offlineLimit*3600)),e.time=Date.now(),e.modVersion!==W.versionNumber&&s(e.modVersion,e),Object.assign(A,e),ne.active=A.id,le.emit("onLoad")}setInterval(()=>{A.autosave&&He()},1e3);window.onbeforeunload=()=>{A.autosave&&He()};window.save=He;const oa=window.hardReset=async()=>{await Ct(xt())},Yt=nn({active:"",saves:[],showTPS:!0,theme:xn.Nordic,unthrottled:!1});ze(Yt,e=>{const t=mt.compressToUTF16(JSON.stringify(e));localStorage.setItem(W.id,t)},{deep:!0});var ne=window.settings=Yt;window.hardResetSettings=()=>{const e={active:"",saves:[],showTPS:!0,theme:xn.Nordic};le.emit("loadSettings",e),Object.assign(Yt,e),oa()};function ua(){try{let e=localStorage.getItem(W.id);if(e!=null&&e!==""){if(e[0]!=="{")if(e[0]==="e")e=decodeURIComponent(escape(atob(e)));else if(e[0]==="\u1BE1")e=mt.decompressFromUTF16(e);else{console.warn("Unable to determine settings encoding",e);return}const t=JSON.parse(e);typeof t=="object"&&Object.assign(Yt,t)}le.emit("loadSettings",Yt)}catch{}}const _i=nn([]);function ca(e){_i.push(e)}const wi=nn([]);function da(e){wi.push(e)}const fa=nn([]),ma={class:"table"},dn=V({__name:"Column",setup(e){const t=S(()=>sn[ne.theme].mergeAdjacent);return(n,i)=>(y(),M("div",ma,[m("div",{class:fe(["col",{mergeAdjacent:r(t)}])},[Je(n.$slots,"default")],2)]))}}),pa={class:"table"},Ni=V({__name:"Row",setup(e){const t=S(()=>sn[ne.theme].mergeAdjacent);return(n,i)=>(y(),M("div",pa,[m("div",{class:fe(["row",{mergeAdjacent:r(t)}])},[Je(n.$slots,"default")],2)]))}});function ki(e){return typeof e=="function"||Object.prototype.toString.call(e)==="[object Object]"&&!Ki(e)}function K(e,t="span"){return typeof e=="function"?V({render:e}):typeof e=="string"?e.length>0?(e=e.trim(),e.charAt(0)!=="<"&&(e=`<${t}>${e}`),V({template:e})):V({render:()=>({})}):e}function he(e){if(yt(e))return typeof e=="function"?e():K(e);const t=e[gt];return u(t,e[vt](),null)}function Oe(...e){let t;return u(Ni,null,ki(t=e.map(he))?t:{default:()=>[t]})}function Ci(...e){let t;return u(dn,null,ki(t=e.map(he))?t:{default:()=>[t]})}function Xe(e){if(yt(e))return typeof e=="function"?e():typeof e=="string"?u(F,null,[e]):u(e,null,null);const t=e[gt];return u(t,e[vt](),null)}function yt(e){return typeof e=="string"?!0:typeof e=="object"?e==null?!1:"render"in e||"component"in e:typeof e=="function"&&e[Zt]===!0}function Si(e,t,n){const i=T(null),s=T(void 0);function l(f){i.value||(i.value=setInterval(c,250)),s.value=f,n&&(n.value=!0)}function o(){i.value&&(clearInterval(i.value),i.value=null),n&&(n.value=!1)}function c(){t&&t.value?t.value():e&&e.value&&e.value(s.value)}return si(o),{start:l,stop:o,handleHolding:c}}function Mi(e,t="div"){const n=Le();return Fe(()=>{n.value=K(ge(e),t)}),n}function At(e,t="div"){const n=Le(null);return Fe(()=>{const i=ge(e);n.value=i==null?null:K(i,t)}),n}function ha(e){return S(()=>ge(e))}function ge(e){return r(r(e))}function $(...e){return e.includes(Object)||e.push(Object),e}const Re=V({__name:"Spacer",props:{width:{default:"8px"},height:{default:"17px"}},setup(e){return(t,n)=>(y(),M("div",{style:pe({width:e.width,height:e.height})},null,4))}});var Z=(e,t)=>{const n=e.__vccOpts||e;for(const[i,s]of t)n[i]=s;return n};const ga=V({__name:"Context",emits:["updateNodes"],setup(e,{emit:t}){var _;const n=T({}),i=new ResizeObserver(c),s=T(null);yn(()=>{const b=s.value;b!=null&&i.observe(b)});let l=!0,o=T((_=s.value)==null?void 0:_.getBoundingClientRect());function c(){l&&(l=!1,Mt(()=>{var b;o.value=(b=s.value)==null?void 0:b.getBoundingClientRect(),Object.values(n.value).filter(v=>v).forEach(v=>v.rect=v.element.getBoundingClientRect()),t("updateNodes",n.value),l=!0}))}le.on("fontsLoaded",c);const f={attributes:!1,childList:!0,subtree:!1};on(Fn,(b,v)=>{const p=new MutationObserver(()=>d(b));p.observe(v,f),n.value[b]={element:v,observer:p,rect:v.getBoundingClientRect()},c()}),on(Bn,b=>{var v;(v=n.value[b])==null||v.observer.disconnect(),n.value[b]=void 0,c()}),on(Dn,n),on(On,o);function d(b){const v=n.value[b];v!=null&&(v.rect=v.element.getBoundingClientRect(),t("updateNodes",n.value))}return(b,v)=>(y(),M(F,null,[Je(b.$slots,"default",{},void 0,!0),m("div",{ref_key:"resizeListener",ref:s,class:"resize-listener"},null,512)],64))}});var Ii=Z(ga,[["__scopeId","data-v-2b1dc1bc"]]);const va=["onPointerdown"],ya={class:"modal-wrapper"},ba={class:"modal-container"},_a={class:"modal-header"},wa=g(" default header "),Na={class:"modal-body"},ka=g(" default body "),Ca={class:"modal-footer"},Sa=m("div",{class:"modal-default-flex-grow"},null,-1),We=V({__name:"Modal",props:{modelValue:{type:Boolean}},emits:["update:modelValue"],setup(e,{expose:t,emit:n}){const s=Ne(e),l=S(()=>s.modelValue||c.value);function o(){n("update:modelValue",!1)}const c=T(!1),f=T(null),d=S(()=>{var _,b;return(b=(_=f.value)==null?void 0:_.nodes)!=null?b:null});return t({isOpen:l,nodes:d}),(_,b)=>(y(),U(Xi,{to:"#modal-root"},[u(bn,{name:"modal",onBeforeEnter:b[0]||(b[0]=v=>c.value=!0),onAfterLeave:b[1]||(b[1]=v=>c.value=!1)},{default:D(()=>[Tn(m("div",It({class:"modal-mask",onPointerdown:Xt(o,["self"])},_.$attrs),[m("div",ya,[m("div",ba,[m("div",_a,[Je(_.$slots,"header",{shown:r(l)},()=>[wa])]),m("div",Na,[u(Ii,{ref_key:"contextRef",ref:f},{default:D(()=>[Je(_.$slots,"body",{shown:r(l)},()=>[ka])]),_:3},512)]),m("div",Ca,[Je(_.$slots,"footer",{shown:r(l)},()=>[m("div",{class:"modal-default-footer"},[Sa,m("button",{class:"button modal-default-button",onClick:o}," Close ")])])])])])],16,va),[[Ji,e.modelValue]])]),_:3})]))}}),en=Symbol("PersistentState"),tn=Symbol("DefaultValue"),gn=Symbol("StackTrace"),Ai=Symbol("Deleted");function Ma(){var e;return((e=new Error().stack)==null?void 0:e.split(` +`).slice(3,5).map(t=>t.trim()).join(` +`))||""}function Ee(e){const t=_e(e)?e:T(e);return t[en]=t,t[tn]=_e(e)?e.value:e,t[gn]=Ma(),t[Ai]=!1,je.length===0?console.warn("Creating a persistent ref outside of a layer. This is not officially supported",t,` +Created at: +`+t[gn]):Ft[je[je.length-1]].add(t),t}le.on("addLayer",(e,t)=>{const n=[],i=(s,l=[])=>{let o=!1;return Object.keys(s).forEach(c=>{const f=s[c];if(f&&typeof f=="object")if(en in f){if(o=!0,f[Ai]){console.warn("Deleted persistent ref present in returned object. Ignoring...",f,` +Created at: +`+f[gn]);return}Ft[e.id].delete(oe in f?f[oe]:f);const d=l.reduce((b,v)=>(v in b||(b[v]={}),b[v]),t),_=d[c];d[c]=f[en],Zi(d)?_!=null?d[c]=_:d[c]=f[tn]:_!=null?d[c].value=_:d[c].value=f[tn]}else!(f instanceof a)&&!_e(f)&&!n.includes(f)&&(typeof f.type=="symbol"&&n.push(f),i(f,[...l,c])&&(Jn(f)&&!Jn(s)?console.warn("Found array that contains persistent values when adding layer. Keep in mind changing the order of elements in the array will mess with existing player saves.",oe in s?s[oe]:s,c):o=!0))}),o};i(e),Ft[e.id].forEach(s=>{console.error(`Created persistent ref in ${e.id} without registering it to the layer! Make sure to include everything persistent in the returned object`,s,` +Created at: +`+s[gn])}),Ft[e.id].clear()});const Fn=Symbol("RegisterNode"),Bn=Symbol("UnregisterNode"),Dn=Symbol("Nodes"),On=Symbol("Bounds"),Ce=vn({});window.layers=Ce;const Ft={},je=[];function Rt(e,t){return Be(()=>{const n={},i=n.emitter=li();if(n.on=i.on.bind(i),n.emit=i.emit.bind(i),n.nodes=T({}),n.id=e,je.push(e),Ft[e]=new Set,n.minimized=Ee(!1),Object.assign(n,t.call(n)),je[je.length-1]==null||je[je.length-1]!==e)throw`Adding layers stack in invalid state. This should not happen +Stack: ${je} +Trying to pop ${n.id}`;return je.pop(),E(n,"color"),E(n,"display"),E(n,"name"),we(n,"name",n.id),E(n,"minWidth"),we(n,"minWidth",600),E(n,"minimizable"),we(n,"minimizable",!0),n})}function Ei(e,t){if(console.info("Adding layer",e.id),Ce[e.id]){console.error("Attempted to add layer with same ID as existing layer",e.id,Ce[e.id]);return}we(t,"layers",{}),t.layers[e.id]==null&&(t.layers[e.id]={}),Ce[e.id]=e,le.emit("addLayer",e,t.layers[e.id])}function Ia(e){return Ce[e]}function $i(e){console.info("Removing layer",e.id),le.emit("removeLayer",e),Ce[e.id]=void 0}function Aa(e){$i(e),Ei(e,A)}function Ea(e){const t=T(!1);return{openModal:()=>t.value=!0,modal:x(()=>u(We,{modelValue:t.value,"onUpdate:modelValue":n=>t.value=n},{header:()=>u("h2",null,[r(e.name)]),body:r(e.display)}))}}le.on("update",function(t){Object.values(Ce).forEach(n=>{n==null||n.emit("preUpdate",t)}),Object.values(Ce).forEach(n=>{n==null||n.emit("update",t)}),Object.values(Ce).forEach(n=>{n==null||n.emit("postUpdate",t)})});var $a=Object.freeze(Object.defineProperty({__proto__:null,RegisterNodeInjectionKey:Fn,UnregisterNodeInjectionKey:Bn,NodesInjectionKey:Dn,BoundsInjectionKey:On,layers:Ce,persistentRefs:Ft,addingLayers:je,createLayer:Rt,addLayer:Ei,getLayer:Ia,removeLayer:$i,reloadLayer:Aa,setupLayerModal:Ea},Symbol.toStringTag,{value:"Module"}));const Pa={},Ta={class:"notif"};function xa(e,t){return y(),M("div",Ta,"!")}var ni=Z(Pa,[["render",xa],["__scopeId","data-v-66323fd4"]]);const wn=e=>(nt("data-v-949cc93c"),e=e(),it(),e),Fa={key:0,class:"day feature dontMerge opened"},Ba={class:"date"},Da=g("Dec"),Oa=wn(()=>m("br",null,null,-1)),Ra={class:"date"},qa=g("Dec"),Va=wn(()=>m("br",null,null,-1)),La=wn(()=>m("div",{class:"doors"},null,-1)),Ga={class:"date"},Ua=g("Dec"),Ha=wn(()=>m("br",null,null,-1)),ja={key:0,class:"material-icons lock"},za=V({__name:"Day",props:{day:null,symbol:null,opened:null,shouldNotify:null},emits:["openLore","openLayer","unlockLayer"],setup(e,{emit:t}){const n=e,i=S(()=>a.gte(z.day.value,n.day)&&new Date().getMonth()===11&&new Date().getDate()>=n.day);function s(){i.value&&t("unlockLayer")}return(l,o)=>e.opened.value?(y(),M("div",Fa,[u(bn,{appear:"",name:"door"},{default:D(()=>[m("div",{class:"doors",onClick:o[0]||(o[0]=c=>t("openLayer"))},[m("div",Ba,[Da,Oa,g(j(e.day),1)]),m("div",Ra,[qa,Va,g(j(e.day),1)])])]),_:1}),m("div",{class:"icon",style:pe({backgroundImage:`url(${e.symbol})`})},null,4),m("div",{class:"lore",onClick:o[1]||(o[1]=c=>t("openLore"))},"?"),r(e.shouldNotify)?(y(),U(ni,{key:0})):P("",!0)])):(y(),M("div",{key:1,class:fe(["day feature dontMerge",{can:r(i),locked:!r(i),canOpen:r(i)}]),onClick:s},[La,m("div",Ga,[Ua,Ha,g(j(e.day),1)]),r(i)?P("",!0):(y(),M("div",ja,"lock")),r(i)?(y(),U(ni,{key:1})):P("",!0)],2))}});var Wa=Z(za,[["__scopeId","data-v-949cc93c"]]);const Qa={key:0},Ka={key:0,class:"mark star"},Ja=["src"],Xa=V({__name:"MarkNode",props:{mark:{type:[Boolean,String]}},setup(e){return(t,n)=>e.mark?(y(),M("div",Qa,[e.mark===!0?(y(),M("div",Ka)):(y(),M("img",{key:1,class:"mark",src:e.mark},null,8,Ja))])):P("",!0)}});var Nn=Z(Xa,[["__scopeId","data-v-2207999f"]]);const Za=V({__name:"Node",props:{id:null},setup(e){const n=Ne(e),i=fn(Fn,()=>{}),s=fn(Bn,()=>{}),l=Le(null),o=S(()=>l.value&&l.value.parentElement);return ze([o,n.id],([c,f],[d,_])=>{d&&s(r(_)),c&&i(f,c)}),si(()=>s(r(n.id))),(c,f)=>(y(),M("div",{class:"node",ref_key:"node",ref:l},null,512))}});var an=Z(Za,[["__scopeId","data-v-a48cb382"]]),Ya=V({props:{display:{type:$(Object,String,Function),required:!0},visibility:{type:$(Number),required:!0},style:$(Object,String,Array),classes:$(Object),onClick:Function,onHold:Function,canClick:{type:$(Boolean),required:!0},small:Boolean,mark:$(Boolean,String),id:{type:String,required:!0},isHolding:Object},components:{Node:an,MarkNode:Nn},setup(e){const{display:t,onClick:n,onHold:i}=Ne(e),s=Le("");Fe(()=>{const c=ge(t);if(c==null){s.value="";return}if(yt(c)){s.value=K(c);return}const f=K(c.title||"","h3"),d=K(c.description,"div");s.value=K(x(()=>u("span",null,[c.title?u("div",null,[u(f,null,null)]):null,u(d,null,null)])))});const{start:l,stop:o}=Si(n,i,e.isHolding);return{start:l,stop:o,comp:s,Visibility:be,unref:r}}});function el(e,t,n,i,s,l){var f;const o=ht("MarkNode"),c=ht("Node");return e.unref(e.visibility)!==e.Visibility.None?(y(),M("button",{key:0,style:pe([{visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},(f=e.unref(e.style))!=null?f:[]]),onClick:t[0]||(t[0]=(...d)=>e.onClick&&e.onClick(...d)),onMousedown:t[1]||(t[1]=(...d)=>e.start&&e.start(...d)),onMouseleave:t[2]||(t[2]=(...d)=>e.stop&&e.stop(...d)),onMouseup:t[3]||(t[3]=(...d)=>e.stop&&e.stop(...d)),onTouchstartPassive:t[4]||(t[4]=(...d)=>e.start&&e.start(...d)),onTouchendPassive:t[5]||(t[5]=(...d)=>e.stop&&e.stop(...d)),onTouchcancelPassive:t[6]||(t[6]=(...d)=>e.stop&&e.stop(...d)),class:fe({feature:!0,clickable:!0,can:e.unref(e.canClick),locked:!e.unref(e.canClick),small:e.small,...e.unref(e.classes)})},[e.unref(e.comp)?(y(),U(ke(e.unref(e.comp)),{key:0})):P("",!0),u(o,{mark:e.unref(e.mark)},null,8,["mark"]),u(c,{id:e.id},null,8,["id"])],38)):P("",!0)}var Pi=Z(Ya,[["render",el],["__scopeId","data-v-8cedd7da"]]);const tl=Symbol("Clickable");function Me(e){return Be(()=>{var n;const t=(n=e==null?void 0:e())!=null?n:{};if(t.id=Ot("clickable-"),t.type=tl,t[gt]=Pi,t.isHolding=T(!1),E(t,"visibility"),we(t,"visibility",be.Visible),E(t,"canClick"),we(t,"canClick",!0),E(t,"classes"),E(t,"style"),E(t,"mark"),E(t,"display"),t.onClick){const i=t.onClick.bind(t);t.onClick=function(s){r(t.canClick)&&i(s)}}if(t.onHold){const i=t.onHold.bind(t);t.onHold=function(){r(t.canClick)&&i()}}return t[vt]=function(){const{display:i,visibility:s,style:l,classes:o,onClick:c,onHold:f,isHolding:d,canClick:_,small:b,mark:v,id:p}=this;return{display:i,visibility:s,style:r(l),classes:o,onClick:c,onHold:f,isHolding:d,canClick:_,small:b,mark:v,id:p}},t})}function St(e,t="points",n=0,i=void 0){const s=_e(e)?e:Ee(e);return s.displayName=t,s.precision=n,s.small=i,s}function Ti(e){const t=Ee(e.value);return ze(e,(n,i)=>{a.gt(n,i)&&(t.value=a.add(t.value,a.sub(n,i)))}),t}new a("10^^8");new a("1e100");function Rn(e,t){const n=t!=null?t:e.value;return a.eq(e.precision,0)?G(e.small?n:a.floor(n)):te(n,e.precision,e.small)}const nl=["x1","y1","x2","y2"],il=V({__name:"Link",props:{link:null,startNode:null,endNode:null,boundingRect:null},setup(e){const n=Ne(e),i=S(()=>{const l=n.startNode.value.rect,o=n.boundingRect.value,c=o?{x:l.x+l.width/2-o.x,y:l.y+l.height/2-o.y}:{x:0,y:0};return n.link.value.offsetStart&&(c.x+=n.link.value.offsetStart.x,c.y+=n.link.value.offsetStart.y),c}),s=S(()=>{const l=n.endNode.value.rect,o=n.boundingRect.value,c=o?{x:l.x+l.width/2-o.x,y:l.y+l.height/2-o.y}:{x:0,y:0};return n.link.value.offsetEnd&&(c.x+=n.link.value.offsetEnd.x,c.y+=n.link.value.offsetEnd.y),c});return(l,o)=>(y(),M("line",It({"stroke-width":"15px",stroke:"white"},e.link,{x1:r(i).x,y1:r(i).y,x2:r(s).x,y2:r(s).y}),null,16,nl))}});const sl=V({__name:"Links",props:{links:null},setup(e){var f;const n=tt(e,"links"),i=T(null),s=fn(Dn,T({})),l=fn(On,T(void 0)),o=T((f=i.value)==null?void 0:f.getBoundingClientRect());ze(l,()=>{var d;return o.value=(d=i.value)==null?void 0:d.getBoundingClientRect()}),yn(()=>{var d;return o.value=(d=i.value)==null?void 0:d.getBoundingClientRect()});const c=S(()=>{var _,b;const d=s.value;return(b=(_=n.value)==null?void 0:_.filter(v=>{var p,k;return((p=d[v.startNode.id])==null?void 0:p.rect)&&((k=d[v.startNode.id])==null?void 0:k.rect)}))!=null?b:[]});return(d,_)=>(y(),M(F,null,[r(c)?(y(),M("svg",Yi(It({key:0},d.$attrs)),[(y(!0),M(F,null,ai(r(c),(b,v)=>(y(),U(il,{key:v,link:b,boundingRect:o.value,startNode:r(s)[b.startNode.id],endNode:r(s)[b.endNode.id]},null,8,["link","boundingRect","startNode","endNode"]))),128))],16)):P("",!0),m("div",{ref_key:"resizeListener",ref:i,class:"resize-listener"},null,512)],64))}});var al=Z(sl,[["__scopeId","data-v-063f6d6b"]]);V({props:{nodes:{type:$(Array),required:!0},leftSideNodes:$(Array),rightSideNodes:$(Array),branches:$(Array)},components:{Links:al},setup(e){const{nodes:t,leftSideNodes:n,rightSideNodes:i}=Ne(e),s=Le();Fe(()=>{const c=ge(t);s.value=K(x(()=>u(F,null,[c.map(f=>u("span",{class:"row tree-row",style:"margin: 50px auto;"},[f.map(Xe)]))])))});const l=Le();Fe(()=>{const c=ge(n);l.value=c?K(x(()=>u("span",{class:"left-side-nodes small"},[c.map(Xe)]))):""});const o=Le();return Fe(()=>{const c=ge(i);o.value=c?K(x(()=>u("span",{class:"side-nodes small"},[c.map(Xe)]))):""}),{unref:r,nodesComp:s,leftNodesComp:l,rightNodesComp:o}}});V({props:{display:$(Object,String,Function),visibility:{type:$(Number),required:!0},style:$(String,Object,Array),classes:$(Object),onClick:Function,onHold:Function,color:$(String),glowColor:$(String),canClick:{type:$(Boolean),required:!0},mark:$(Boolean,String),id:{type:String,required:!0}},components:{MarkNode:Nn,Node:an},setup(e){const{onClick:t,onHold:n,display:i}=Ne(e),s=At(i),{start:l,stop:o}=Si(t,n);return{start:l,stop:o,comp:s,unref:r,Visibility:be,isCoercableComponent:yt}}});function qn(e){const t=[],n={};let i=!1;function s(){return i||(t.push(...e()),n.base=t.map(c=>Ae(c.base)),n.baseText=t.map(c=>Ae(c.baseText)),n.visible=t.map(c=>Ae(c.visible)),i=!0),t}const l=Ee({});return[x(()=>{const c=s();let f=!0;const d=c.map((_,b)=>{var C,R,ie;if(r(n.visible[b])===!1)return null;const v=u("h3",{onClick:()=>l.value[b]=!l.value[b],style:"cursor: pointer"},[u("span",{class:"modifier-toggle"+(r(l.value[b])?" collapsed":"")},[g("\u25BC")]),_.title,_.subtitle?u("span",{class:"subtitle"},[g(" ("),_.subtitle,g(")")]):null]),p=r(l.value[b])?null:u(F,null,[u("div",{class:"modifier-container"},[u("span",{class:"modifier-amount"},[te((C=r(n.base[b]))!=null?C:1),_.unit]),u("span",{class:"modifier-description"},[Xe((R=r(n.baseText[b]))!=null?R:"Base")])]),Xe(r(_.modifier.description))]),k=!f;return f=!1,u(F,null,[k?u("br",null,null):null,u("div",null,[v,u("br",null,null),p,u("hr",null,null),g("Total: "),te(_.modifier.apply((ie=r(n.base[b]))!=null?ie:1)),_.unit])])});return u(F,null,[d])}),l]}const ll=V({props:{progress:{type:$(String,Object,Number),required:!0},width:{type:$(Number),required:!0},height:{type:$(Number),required:!0},direction:{type:$(String),required:!0},display:$(Object,String,Function),visibility:{type:$(Number),required:!0},style:$(Object,String,Array),classes:$(Object),borderStyle:$(Object,String,Array),textStyle:$(Object,String,Array),baseStyle:$(Object,String,Array),fillStyle:$(Object,String,Array),mark:$(Boolean,String),id:{type:String,required:!0}},components:{MarkNode:Nn,Node:an},setup(e){const{progress:t,width:n,height:i,direction:s,display:l}=Ne(e),o=S(()=>{let d=t.value instanceof a?t.value.toNumber():Number(t.value);return(1-Math.min(Math.max(d,0),1))*100}),c=S(()=>{const d={width:ge(n)+.5+"px",height:ge(i)+.5+"px"};switch(r(s)){case J.Up:d.clipPath=`inset(${o.value}% 0% 0% 0%)`,d.width=ge(n)+1+"px";break;case J.Down:d.clipPath=`inset(0% 0% ${o.value}% 0%)`,d.width=ge(n)+1+"px";break;case J.Right:d.clipPath=`inset(0% ${o.value}% 0% 0%)`;break;case J.Left:d.clipPath=`inset(0% 0% 0% ${o.value} + '%)`;break;case J.Default:d.clipPath="inset(0% 50% 0% 0%)";break}return d}),f=At(l);return{normalizedProgress:o,barStyle:c,component:f,unref:r,Visibility:be}}});function rl(e,t,n,i,s,l){var f,d,_,b,v,p,k;const o=ht("MarkNode"),c=ht("Node");return e.unref(e.visibility)!==e.Visibility.None?(y(),M("div",{key:0,style:pe([{width:e.unref(e.width)+"px",height:e.unref(e.height)+"px",visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},(f=e.unref(e.style))!=null?f:{}]),class:fe({bar:!0,...e.unref(e.classes)})},[m("div",{class:"overlayTextContainer border",style:pe([{width:e.unref(e.width)+"px",height:e.unref(e.height)+"px"},(d=e.unref(e.borderStyle))!=null?d:{}])},[e.component?(y(),M("span",{key:0,class:"overlayText",style:pe(e.unref(e.textStyle))},[(y(),U(ke(e.component)))],4)):P("",!0)],4),m("div",{class:"border",style:pe([{width:e.unref(e.width)+"px",height:e.unref(e.height)+"px"},(_=e.unref(e.style))!=null?_:{},(b=e.unref(e.baseStyle))!=null?b:{},(v=e.unref(e.borderStyle))!=null?v:{}])},[m("div",{class:"fill",style:pe([e.barStyle,(p=e.unref(e.style))!=null?p:{},(k=e.unref(e.fillStyle))!=null?k:{}])},null,4)],4),u(o,{mark:e.unref(e.mark)},null,8,["mark"]),u(c,{id:e.id},null,8,["id"])],6)):P("",!0)}var ol=Z(ll,[["render",rl],["__scopeId","data-v-02d0d7b2"]]);const ul=Symbol("Bar");function Bt(e){return Be(()=>{const t=e();return t.id=Ot("bar-"),t.type=ul,t[gt]=ol,E(t,"visibility"),we(t,"visibility",be.Visible),E(t,"width"),E(t,"height"),E(t,"direction"),E(t,"style"),E(t,"classes"),E(t,"borderStyle"),E(t,"baseStyle"),E(t,"textStyle"),E(t,"fillStyle"),E(t,"progress"),E(t,"display"),E(t,"mark"),t[vt]=function(){const{progress:n,width:i,height:s,direction:l,display:o,visibility:c,style:f,classes:d,borderStyle:_,textStyle:b,baseStyle:v,fillStyle:p,mark:k,id:C}=this;return{progress:n,width:i,height:s,direction:l,display:o,visibility:c,style:r(f),classes:d,borderStyle:_,textStyle:b,baseStyle:v,fillStyle:p,mark:k,id:C}},t})}const cl=Symbol("Buyable");function et(e){const t=Ee(0);return Be(()=>{var l,o,c;const n=e();if(n.canPurchase==null&&(n.resource==null||n.cost==null))throw console.warn("Cannot create buyable without a canPurchase property or a resource and cost property",n),"Cannot create buyable without a canPurchase property or a resource and cost property";n.id=Ot("buyable-"),n.type=cl,n[gt]=Pi,n.amount=t,n.amount[tn]=(l=n.initialValue)!=null?l:0,n.canAfford=S(()=>{const f=n,d=r(f.cost);return f.resource!=null&&d!=null&&a.gte(f.resource.value,d)}),n.canPurchase==null&&(n.canPurchase=S(()=>r(n.visibility)===be.Visible&&r(n.canAfford)&&a.lt(n.amount.value,r(n.purchaseLimit)))),n.maxed=S(()=>a.gte(n.amount.value,r(n.purchaseLimit))),E(n,"classes");const i=n.classes;n.classes=S(()=>{const f=r(i)||{};return n.maxed.value&&(f.bought=!0),f}),E(n,"canPurchase"),n.canClick=n.canPurchase,n.onClick=n.purchase=(c=(o=n.onClick)!=null?o:n.purchase)!=null?c:function(){var _;const f=n;if(!r(f.canPurchase))return;const d=r(f.cost);f.cost!=null&&f.resource!=null&&(f.resource.value=a.sub(f.resource.value,d),f.amount.value=a.add(f.amount.value,1)),(_=f.onPurchase)==null||_.call(f,d)},E(n,"display");const s=n.display;return n.display=x(()=>{const f=r(s);if(yt(f)){const d=K(f);return u(d,null,null)}if(f!=null&&n.cost!=null&&n.resource!=null){const d=n,_=K(f.title||"","h3"),b=K(f.description||""),v=K(f.effectDisplay||"");return u("span",null,[f.title?u("div",null,[u(_,null,null)]):null,f.description?u(b,null,null):null,f.showAmount===!1?null:u("div",null,[u("br",null,null),r(d.purchaseLimit)===a.dInf?u(F,null,[g("Amount: "),G(d.amount.value)]):u(F,null,[g("Amount: "),G(d.amount.value),g(" /")," ",G(r(d.purchaseLimit))])]),f.effectDisplay?u("div",null,[u("br",null,null),g("Currently: "),u(v,null,null)]):null,d.cost&&!d.maxed.value?u("div",null,[u("br",null,null),g("Cost: "),te(r(d.cost)||0)," ",n.resource.displayName]):null])}return""}),E(n,"visibility"),we(n,"visibility",be.Visible),E(n,"cost"),E(n,"resource"),E(n,"purchaseLimit"),we(n,"purchaseLimit",a.dInf),E(n,"style"),E(n,"mark"),E(n,"small"),n[vt]=function(){const{display:f,visibility:d,style:_,classes:b,onClick:v,canClick:p,small:k,mark:C,id:R}=this;return{display:f,visibility:d,style:r(_),classes:b,onClick:v,canClick:p,small:k,mark:C,id:R}},n})}const kn=vn({}),Vn=Symbol("Hotkey");function ii(e){return Be(()=>{const t=e();return t.type=Vn,E(t,"enabled"),we(t,"enabled",!0),E(t,"description"),t})}le.on("addLayer",e=>{hi(e,Vn).forEach(t=>{kn[t.key]=t})});le.on("removeLayer",e=>{hi(e,Vn).forEach(t=>{kn[t.key]=void 0})});document.onkeydown=function(e){var i;if(((i=e.target)==null?void 0:i.tagName)==="INPUT"||Gn.value&&!A.keepGoing)return;let t=e.key;e.shiftKey&&(t="shift+"+t),e.ctrlKey&&(t="ctrl+"+t);const n=kn[t];n&&r(n.enabled)&&(e.preventDefault(),n.onPress())};da(x(()=>{const e=Object.values(kn).filter(t=>r(t==null?void 0:t.enabled));return e.length===0?"":u("div",null,[u("br",null,null),u("h4",null,[g("Hotkeys")]),e.map(t=>u("div",null,[t==null?void 0:t.key,g(": "),t==null?void 0:t.description]))])}));const dl=V({__name:"Sticky",setup(e){const t=T("0"),n=new ResizeObserver(s),i=Le(null);function s(){let l=i.value;if(l==null)return;let o=0;for(;l.previousSibling;){const c=l.previousSibling;c.dataset&&"vSticky"in c.dataset&&(o+=c.offsetHeight),l=c}t.value=o+"px"}return Mt(s),document.fonts.ready.then(s),yn(()=>{var o;const l=(o=i.value)==null?void 0:o.parentElement;l&&n.observe(l)}),(l,o)=>(y(),M("div",{class:"sticky",style:pe({top:t.value}),ref_key:"element",ref:i,"data-v-sticky":""},[Je(l.$slots,"default",{},void 0,!0)],4))}});var fl=Z(dl,[["__scopeId","data-v-cccac690"]]);const ml=V({__name:"Resource",props:{resource:null,color:null},setup(e){const t=e,n=S(()=>Rn(t.resource));return(i,s)=>(y(),M("h2",{style:pe({color:e.color,"text-shadow":"0px 0px 10px "+e.color})},j(r(n)),5))}});const pl={class:"main-display"},hl={key:0},gl={key:1},vl=g(", "),Jt=V({__name:"MainDisplay",props:{resource:null,color:null,classes:null,style:null,effectDisplay:null},setup(e){const n=Ne(e),i=T(null),s=At(n.effectDisplay),l=S(()=>a.lt(n.resource.value,"1e1000"));return(o,c)=>(y(),U(fl,null,{default:D(()=>{var f,d,_,b;return[m("div",{class:fe(["main-display-container",(f=e.classes)!=null?f:{}]),style:pe([{height:`${((_=(d=i.value)==null?void 0:d.$el.clientHeight)!=null?_:0)+50}px`},(b=e.style)!=null?b:{}])},[m("div",pl,[r(l)?(y(),M("span",hl,"You have ")):P("",!0),u(ml,{resource:e.resource,color:e.color||"white"},null,8,["resource","color"]),g(" "+j(e.resource.displayName),1),r(s)?(y(),M("span",gl,[vl,(y(),U(ke(r(s)),{ref_key:"effectRef",ref:i},null,512))])):P("",!0)])],6)]}),_:1}))}});var yl=V({props:{display:{type:$(String,Object,Function),required:!0},visibility:{type:$(Number),required:!0},style:$(String,Object,Array),classes:$(Object),resource:Object,cost:$(String,Object,Number),canPurchase:{type:$(Boolean),required:!0},bought:{type:$(Boolean),required:!0},mark:$(Boolean,String),id:{type:String,required:!0},purchase:{type:Function,required:!0}},components:{Node:an,MarkNode:Nn},setup(e){const{display:t,cost:n}=Ne(e),i=Le("");return Fe(()=>{const s=ge(t);if(s==null){i.value="";return}if(yt(s)){i.value=K(s);return}const l=ge(n),o=K(s.title||"","h3"),c=K(s.description,"div"),f=K(s.effectDisplay||"");i.value=K(x(()=>{var d;return u("span",null,[s.title?u("div",null,[u(o,null,null)]):null,u(c,null,null),s.effectDisplay?u("div",null,[g("Currently: "),u(f,null,null)]):null,e.resource!=null&&s.showCost!==!1?u(F,null,[u("br",null,null),g("Cost: "),e.resource&&Rn(e.resource,l)," ",(d=e.resource)==null?void 0:d.displayName]):null])}))}),{component:i,unref:r,Visibility:be}}});const bl=["disabled"];function _l(e,t,n,i,s,l){var f;const o=ht("MarkNode"),c=ht("Node");return e.unref(e.visibility)!==e.Visibility.None?(y(),M("button",{key:0,style:pe([{visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},(f=e.unref(e.style))!=null?f:{}]),onClick:t[0]||(t[0]=(...d)=>e.purchase&&e.purchase(...d)),class:fe({feature:!0,upgrade:!0,can:e.unref(e.canPurchase),locked:!e.unref(e.canPurchase),bought:e.unref(e.bought),...e.unref(e.classes)}),disabled:!e.unref(e.canPurchase)},[e.unref(e.component)?(y(),U(ke(e.unref(e.component)),{key:0})):P("",!0),u(o,{mark:e.unref(e.mark)},null,8,["mark"]),u(c,{id:e.id},null,8,["id"])],14,bl)):P("",!0)}var wl=Z(yl,[["render",_l],["__scopeId","data-v-7f411ac8"]]);const Nl=Symbol("Upgrade");function ue(e){const t=Ee(!1);return Be(()=>{const n=e();return n.id=Ot("upgrade-"),n.type=Nl,n[gt]=wl,n.canAfford==null&&(n.resource==null||n.cost==null)&&console.warn("Error: can't create upgrade without a canAfford property or a resource and cost property",n),n.bought=t,n.canAfford==null?n.canAfford=S(()=>{const i=n;return i.resource!=null&&i.cost!=null&&a.gte(i.resource.value,r(i.cost))}):E(n,"canAfford"),n.canPurchase=S(()=>r(n.visibility)===be.Visible&&r(n.canAfford)&&!r(n.bought)),n.purchase=function(){var s;const i=n;!r(i.canPurchase)||(i.resource!=null&&i.cost!=null&&(i.resource.value=a.sub(i.resource.value,r(i.cost))),t.value=!0,(s=i.onPurchase)==null||s.call(i))},E(n,"visibility"),we(n,"visibility",be.Visible),E(n,"classes"),E(n,"style"),E(n,"display"),E(n,"mark"),E(n,"cost"),E(n,"resource"),n[vt]=function(){const{display:i,visibility:s,style:l,classes:o,resource:c,cost:f,canPurchase:d,bought:_,mark:b,id:v,purchase:p}=this;return{display:i,visibility:s,style:r(l),classes:o,resource:c,cost:f,canPurchase:d,bought:_,mark:b,id:v,purchase:p}},n})}function ee(e){return Be(()=>{const{addend:t,description:n,enabled:i}=e(),s=Ae(t),l=Ae(n),o=i==null?void 0:Ae(i);return{apply:c=>a.add(c,r(s)),revert:c=>a.sub(c,r(s)),enabled:o,description:n==null?void 0:x(()=>u("div",{class:"modifier-container"},[u("span",{class:"modifier-amount"},[a.gte(r(s),0)?"+":"",te(r(s))]),r(l)?u("span",{class:"modifier-description"},[Xe(r(l))]):null]))}})}function se(e){return Be(()=>{const{multiplier:t,description:n,enabled:i}=e(),s=Ae(t),l=Ae(n),o=i==null?void 0:Ae(i);return{apply:c=>a.times(c,r(s)),revert:c=>a.div(c,r(s)),enabled:o,description:n==null?void 0:x(()=>u("div",{class:"modifier-container"},[u("span",{class:"modifier-amount"},[g("x"),te(r(s))]),r(l)?u("span",{class:"modifier-description"},[Xe(r(l))]):null]))}})}function xi(e){return Be(()=>{const{exponent:t,description:n,enabled:i,supportLowNumbers:s}=e(),l=Ae(t),o=Ae(n),c=i==null?void 0:Ae(i);return{apply:f=>{let d=f;return s&&(d=a.add(d,1)),d=a.pow(d,r(l)),s&&(d=a.sub(d,1)),d},revert:f=>{let d=f;return s&&(d=a.add(d,1)),d=a.root(d,r(l)),s&&(d=a.sub(d,1)),d},enabled:c,description:n==null?void 0:x(()=>u("div",{class:"modifier-container"},[u("span",{class:"modifier-amount"},[g("^"),te(r(l))]),r(o)?u("span",{class:"modifier-description"},[Xe(r(o)),s?" (+1 effective)":null]):null]))}})}function Ie(e){return Be(()=>{const t=e();return{apply:n=>t.filter(i=>r(i.enabled)!==!1).reduce((i,s)=>s.apply(i),n),revert:t.every(n=>n.revert!=null)?n=>t.filter(i=>r(i.enabled)!==!1).reduceRight((i,s)=>s.revert(i),n):void 0,enabled:S(()=>t.filter(n=>r(n.enabled)!==!1).length>0),description:x(()=>u(F,null,[t.filter(n=>r(n.enabled)!==!1).map(n=>r(n.description)).filter(n=>n).map(Xe)]))}})}const kl={class:"field"},Cl={key:0,class:"field-title"},Ln=V({__name:"Select",props:{title:null,modelValue:null,options:null,placeholder:null,closeOnSelect:{type:Boolean}},emits:["update:modelValue"],setup(e,{emit:t}){var o;const n=e,i=At(tt(n,"title"),"span"),s=T((o=n.options.find(c=>c.value===n.modelValue))!=null?o:null);ze(tt(n,"modelValue"),c=>{var f;ge(s)!==c&&(s.value=(f=n.options.find(d=>d.value===c))!=null?f:null)});function l(c){t("update:modelValue",c.value)}return(c,f)=>(y(),M("div",kl,[r(i)?(y(),M("span",Cl,[(y(),U(ke(r(i))))])):P("",!0),u(r(ss),{options:e.options,modelValue:s.value,"onUpdate:modelValue":[f[0]||(f[0]=d=>s.value=d),l],min:1,"label-by":"label",placeholder:e.placeholder,"close-on-select":e.closeOnSelect},null,8,["options","modelValue","placeholder","close-on-select"])]))}});var Sl=V({props:{visibility:{type:$(Number),required:!0},display:{type:$(String,Object,Function),required:!0},style:$(String,Object,Array),classes:$(Object),earned:{type:$(Boolean),required:!0},id:{type:String,required:!0}},components:{Node:an},setup(e){const{display:t}=Ne(e),n=Le("");return Fe(()=>{const i=ge(t);if(i==null){n.value="";return}if(yt(i)){n.value=K(i);return}const s=K(i.requirement,"h3"),l=K(i.effectDisplay||"","b"),o=K(i.optionsDisplay||"","span");n.value=K(x(()=>u("span",null,[u(s,null,null),i.effectDisplay?u("div",null,[u(l,null,null)]):null,i.optionsDisplay?u("div",{class:"equal-spaced"},[u(o,null,null)]):null])))}),{comp:n,unref:r,Visibility:be}}});function Ml(e,t,n,i,s,l){var c;const o=ht("Node");return e.unref(e.visibility)!==e.Visibility.None?(y(),M("div",{key:0,style:pe([{visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},(c=e.unref(e.style))!=null?c:{}]),class:fe({feature:!0,milestone:!0,done:e.unref(e.earned),...e.unref(e.classes)})},[(y(),U(ke(e.unref(e.comp)))),u(o,{id:e.id},null,8,["id"])],6)):P("",!0)}var Il=Z(Sl,[["render",Ml],["__scopeId","data-v-f4e8794e"]]);le.on("setupVue",e=>e.use(as));const Al=ri(),El=Symbol("Milestone");let pt;(function(e){e.All="all",e.Configurable="configurable",e.Incomplete="incomplete",e.None="none"})(pt||(pt={}));function xe(e){const t=Ee(!1);return Be(()=>{var s;const n=(s=e==null?void 0:e())!=null?s:{};n.id=Ot("milestone-"),n.type=El,n[gt]=Il,n.earned=t,n.complete=function(){t.value=!0},E(n,"visibility"),we(n,"visibility",be.Visible);const i=n.visibility;if(n.visibility=S(()=>{const l=r(n.display);switch(ne.msDisplay){default:case pt.All:return r(i);case pt.Configurable:return r(n.earned)&&!(l!=null&&typeof l=="object"&&"optionsDisplay"in l)?be.None:r(i);case pt.Incomplete:return r(n.earned)?be.None:r(i);case pt.None:return be.None}}),E(n,"style"),E(n,"classes"),E(n,"display"),n[vt]=function(){const{visibility:l,display:o,style:c,classes:f,earned:d,id:_}=this;return{visibility:l,display:o,style:r(c),classes:f,earned:d,id:_}},n.shouldEarn){const l=n;Fe(()=>{var o,c;if(ne.active===A.id&&!l.earned.value&&r(l.visibility)===be.Visible&&((o=l.shouldEarn)==null?void 0:o.call(l))&&(l.earned.value=!0,(c=l.onComplete)==null||c.call(l),l.display)){const f=r(l.display),d=K(yt(f)?f:f.requirement);Al(u(F,null,[u("h3",null,[g("Milestone earned!")]),u("div",null,[u(d,null,null)])]))}})}return n})}le.on("loadSettings",e=>{we(e,"msDisplay",pt.All)});const $l=Object.values(pt).map(e=>({label:pi(e),value:e}));ca(x(()=>u(Ln,{title:"Show Milestones",options:$l,"onUpdate:modelValue":e=>ne.msDisplay=e,modelValue:ne.msDisplay},null)));const Pl=Symbol("Reset");function Tl(e){return Be(()=>{const t=e();return t.id=Ot("reset-"),t.type=Pl,t.reset=function(){var i;const n=s=>{s&&typeof s=="object"&&(en in s?s[en].value=s[tn]:!(s instanceof a)&&!_e(s)&&Object.values(s).forEach(l=>n(l)))};r(t.thingsToReset).forEach(n),le.emit("reset",t),(i=t.onReset)==null||i.call(t)},E(t,"thingsToReset"),t})}const un={};le.on("removeLayer",e=>{var t;(t=un[e.id])==null||t.call(un),un[e.id]=void 0});function xl(e){return Be(()=>{const t=e();return t.currentGain==null&&(t.currentGain=S(()=>{let n=t.gainModifier?t.gainModifier.apply(t.scaling.currentGain(t)):t.scaling.currentGain(t);return n=a.floor(n).max(0),r(t.buyMax)||(n=n.min(1)),n})),t.actualGain==null&&(t.actualGain=t.currentGain),t.currentAt==null&&(t.currentAt=S(()=>{let n=t.scaling.currentAt(t);return t.roundUpCost&&(n=a.ceil(n)),n})),t.nextAt==null&&(t.nextAt=S(()=>{let n=t.scaling.nextAt(t);return t.roundUpCost&&(n=a.ceil(n)),n})),t.convert==null&&(t.convert=function(){var s;const n=r(t.currentGain),i=r(t.currentAt);t.gainResource.value=a.add(t.gainResource.value,n),t.spend(n,i),(s=t.onConvert)==null||s.call(t,n)}),t.spend==null&&(t.spend=function(){t.baseResource.value=0}),E(t,"currentGain"),E(t,"actualGain"),E(t,"currentAt"),E(t,"nextAt"),E(t,"buyMax"),we(t,"buyMax",!0),E(t,"roundUpCost"),we(t,"roundUpCost",!0),t})}function Fl(e,t){const n=Ae(e),i=Ae(t);return{currentGain(s){let l=r(s.baseResource.value);if(s.costModifier&&(l=s.costModifier.apply(l)),a.lt(l,r(n)))return 0;const o=a.div(l,r(n)).pow(r(i));return o.isNan()?new a(0):o},currentAt(s){let l=r(s.currentGain);return s.gainModifier&&(l=s.gainModifier.revert(l)),l=a.max(0,l).root(r(i)).times(r(n)),s.costModifier&&(l=s.costModifier.revert(l)),l},nextAt(s){let l=a.add(r(s.currentGain),1).floor();return s.gainModifier&&(l=s.gainModifier.revert(l)),l=a.max(0,l).root(r(i)).times(r(n)).max(r(n)),s.costModifier&&(l=s.costModifier.revert(l)),l}}}function Bl(e){return xl(()=>{const t=e();return we(t,"buyMax",!1),t.currentGain==null&&(t.currentGain=S(()=>{let n=t.gainModifier?t.gainModifier.apply(t.scaling.currentGain(t)):t.scaling.currentGain(t);return n=a.floor(n).max(t.gainResource.value),r(t.buyMax)||(n=n.min(a.add(t.gainResource.value,1))),n})),t.actualGain==null&&(t.actualGain=S(()=>{let n=a.sub(a.floor(t.scaling.currentGain(t)),t.gainResource.value).max(0);return r(t.buyMax)||(n=n.min(1)),n})),we(t,"convert",function(){var s;const n=r(t.actualGain),i=r(t.currentAt);t.gainResource.value=t.gainModifier?t.gainModifier.apply(r(t.currentGain)):r(t.currentGain),t.spend(n,i),(s=t.onConvert)==null||s.call(t,n)}),t})}const Dl="workshop",Ht=2,Te=Rt(Dl,function(){const e="Workshop",t="#D66B02",n="#D66B02",i=St(0,"foundation progress"),s=Bl(()=>({scaling:Fl(250,1.5),baseResource:ae.logs,gainResource:i,roundUpCost:!0,buyMax:!1,spend(R,ie){ae.logs.value=a.sub(ae.logs.value,ie)}})),l=Me(()=>({display:x(()=>u(F,null,[u("b",{style:"font-size: x-large"},[g("Build part of the foundation")]),u("br",null,null),u("br",null,null),u("span",{style:"font-size: large"},[g("Cost:")," ",Rn(ae.logs,a.gte(s.actualGain.value,1)?s.currentAt.value:s.nextAt.value)," ",ae.logs.displayName])])),visibility:()=>X(a.lt(i.value,100)),canClick:()=>a.gte(s.actualGain.value,1)&&a.lt(i.value,100),onClick(){!r(this.canClick)||s.convert()},style:"width: 600px; min-height: unset"})),o=xe(()=>({display:{requirement:"1% Foundation Completed",effectDisplay:"Trees give 5% more logs for each % of foundation completed"},shouldEarn:()=>a.gte(i.value,1)})),c=xe(()=>({display:{requirement:"10% Foundation Completed",effectDisplay:"Cut an additional tree per second for each 5% of foundation completed"},shouldEarn:()=>a.gte(i.value,10),visibility:()=>X(o.earned.value)})),f=xe(()=>({display:{requirement:"20% Foundation Completed",effectDisplay:"Plant an additional tree per second for each 10% of foundation completed"},shouldEarn:()=>a.gte(i.value,20),visibility:()=>X(c.earned.value)})),d=xe(()=>({display:{requirement:"30% Foundation Completed",effectDisplay:"All automatic tree cutting is doubled"},shouldEarn:()=>a.gte(i.value,30),visibility:()=>X(f.earned.value)})),_=xe(()=>({display:{requirement:"40% Foundation Completed",effectDisplay:"All automatic tree planting is doubled"},shouldEarn:()=>a.gte(i.value,40),visibility:()=>X(d.earned.value)})),b=xe(()=>({display:{requirement:"50% Foundation Completed",effectDisplay:"Trees give twice as many logs"},shouldEarn:()=>a.gte(i.value,50),visibility:()=>X(_.earned.value)})),v=xe(()=>({display:{requirement:"75% Foundation Completed",effectDisplay:"The forest gains an extra tree for every 2% of foundation completed"},shouldEarn:()=>a.gte(i.value,75),visibility:()=>X(b.earned.value)})),p=xe(()=>({display:{requirement:"100% Foundation Completed",effectDisplay:"Trees' log gain is now raised to the 1.1th power"},shouldEarn:()=>a.gte(i.value,100),visibility:()=>X(v.earned.value)})),k={logGainMilestone1:o,autoCutMilestone1:c,autoPlantMilestone1:f,autoCutMilestone2:d,autoPlantMilestone2:_,logGainMilestone2:b,morePlantsMilestone1:v,logGainMilestone3:p},C=Bt(()=>({direction:J.Right,width:600,height:25,fillStyle:`backgroundColor: ${n}`,progress:()=>z.day.value===Ht?a.div(i.value,100):1,display:x(()=>z.day.value===Ht?u(F,null,[G(i.value),g("%")]):"")}));return Fe(()=>{z.day.value===Ht&&a.gte(i.value,100)&&z.completeDay()}),{name:e,day:Ht,color:t,foundationProgress:i,foundationConversion:s,milestones:k,minWidth:700,display:x(()=>u(F,null,[u("div",null,[z.day.value===Ht?"Complete the foundation to complete the day":`${e} Complete!`]),he(C),u(Re,null,null),he(l),a.lt(i.value,100)?u("div",null,[g("You have "),G(i.value),g("% completed")]):null,u(Re,null,null),Ci(...Object.values(k))]))}}),Ol="elves",jt=4,ft=Rt(Ol,function(){const e="Elves",t="red",n="#911D21",s=Bt(()=>({direction:J.Right,width:600,height:25,fillStyle:`backgroundColor: ${n}`,progress:()=>z.day.value===jt?a.div(R.value,6).times(.8333333333333334).add(a.div(a.add(de.coal.value,1).log10(),a.log10(1e9)).clamp(0,1).div(6)):1,display:x(()=>z.day.value===jt?a.lt(R.value,6)?u(F,null,[G(R.value),g("/6 elves")]):u(F,null,[G(de.coal.value),g("/"),G(1e9),g(" coal")]):"")})),l=Tl(()=>({thingsToReset:[ae,Te,de],onReset(){setTimeout(()=>{I.earned.value&&(ae.row1Upgrades[4].bought.value=!0,ae.row2Upgrades[4].bought.value=!0)})}}));function o(ye){const De=S(()=>a.pow(4,R.value).times(1e6)),me=Ee(0);function wt(Qe){if(Ze.bought.value){me.value=a.add(me.value,Qe);const at=a.recip(qt.value);for(;a.gte(me.value,at);)if(r(ye.buyable.canPurchase))ye.buyable.amount.value=a.add(ye.buyable.amount.value,1),me.value=at.sub(.1);else{me.value=at;break}}}const Ze=ue(()=>({buyProgress:me,update:wt,resource:de.coal,cost:De,display:()=>({title:ye.name,description:x(()=>u(F,null,[ye.description,Ze.bought.value?null:u(F,null,[" ",g("Training this elf will require resetting all your progress from days 1-3.")])])),showCost:!Ze.bought.value}),style:"width: 190px",onPurchase:l.reset}));return Ze}const c=o({name:"Holly",description:"Holly will automatically purchase cutters you can afford, without actually spending any logs.",buyable:ae.row1Buyables[0]}),f=o({name:"Ivy",description:"Ivy will automatically purchase planters you can afford, without actually spending any logs.",buyable:ae.row1Buyables[1]}),d=o({name:"Hope",description:"Hope will automatically purchase forest expanders you can afford, without actually spending any logs.",buyable:ae.row1Buyables[2]}),_=[c,f,d],b=o({name:"Jack",description:"Jack will automatically purchase heated cutters you can afford, without actually spending any coal.",buyable:de.heatedCutters}),v=o({name:"Mary",description:"Mary will automatically purchase heated planters you can afford, without actually spending any coal.",buyable:de.heatedPlanters}),p=o({name:"Noel",description:"Noel will automatically purchase fertilized soil you can afford, without actually spending any ash.",buyable:de.moreFertilizer}),k=[b,v,p],C={cuttersElf:c,plantersElf:f,expandersElf:d,heatedCuttersElf:b,heatedPlantersElf:v,fertilizerElf:p},R=S(()=>Object.values(C).filter(ye=>ye.bought.value).length),ie=xe(()=>({display:{requirement:"1 Elf Trained",effectDisplay:"Manual cutting and planting can happen twice as often for each trained elf"},shouldEarn:()=>a.gte(R.value,1)})),I=xe(()=>({display:{requirement:"2 Elves Trained",effectDisplay:"Research I & II are't reset after training"},shouldEarn:()=>a.gte(R.value,2),visibility:()=>X(ie.earned.value)})),N=xe(()=>({display:{requirement:"3 Elves Trained",effectDisplay:"Coal gain is raised to the 1.25"},shouldEarn:()=>a.gte(R.value,3),visibility:()=>X(I.earned.value)})),L=xe(()=>({display:{requirement:"4 Elves Trained",effectDisplay:"Trees give twice as many logs"},shouldEarn:()=>a.gte(R.value,4),visibility:()=>X(N.earned.value)})),re=xe(()=>({display:{requirement:"5 Elves Trained",effectDisplay:"Forest is twice as large"},shouldEarn:()=>a.gte(R.value,5),visibility:()=>X(L.earned.value)})),ve=xe(()=>({display:{requirement:"6 Elves Trained",effectDisplay:"Elves work twice as fast"},shouldEarn:()=>a.gte(R.value,6),visibility:()=>X(re.earned.value)})),Se=[ie,I,N,L,re,ve],bt=Ie(()=>[se(()=>({multiplier:2,description:"6 Elves Trained",enabled:ve.earned}))]),qt=S(()=>bt.apply(.1)),[Et,_t]=qn(()=>[{title:"Elf Auto-Buy Frequency",modifier:bt,base:10,unit:"/s"}]),Q=T(!1),Ue=x(()=>u(We,{modelValue:Q.value,"onUpdate:modelValue":ye=>Q.value=ye},{header:()=>u("h2",null,[e,g(" Modifiers")]),body:Et}));return le.on("update",ye=>{a.lt(z.day.value,jt)||Object.values(C).forEach(De=>De.update(ye))}),Fe(()=>{z.day.value===jt&&a.gte(R.value,6)&&a.gte(de.coal.value,1e9)&&z.completeDay()}),{name:e,color:t,elves:C,totalElves:R,milestones:Se,generalTabCollapsed:_t,minWidth:700,display:x(()=>u(F,null,[u("div",null,[z.day.value===jt?`Reach ${G(6)} trained elves and ${G(1e9)} ${de.coal.displayName} to complete the day`:`${e} Complete!`," ",g("-")," ",u("button",{class:"button",style:"display: inline-block;",onClick:()=>Q.value=!0},[g("Check Modifiers")])]),he(s),he(Ue),u(Re,null,null),u("div",{style:"width: 600px"},[Oe(..._),Oe(...k)]),Ci(...Se)]))}}),Rl="coal",zt=3,de=Rt(Rl,function(){const e="Coal",t="#151716",n="#B2BeB5",i="var(--foreground)",s=St(0,"coal"),l=Ti(s),o=St(0,"ash"),c=1e7,f=Bt(()=>({direction:J.Right,width:600,height:25,fillStyle:`backgroundColor: ${t}`,progress:()=>z.day.value===zt?a.log10(l.value).div(Math.log10(c)):1,display:x(()=>z.day.value===zt?u(F,null,[G(l.value),g("/"),G(c)]):"")})),d=Ee(0),_=S(()=>a.times(d.value,1e3)),b=S(()=>a.times(d.value,.1)),v=S(()=>a.times(d.value,50)),p=et(()=>({resource:ae.logs,cost(){return a.times(Se.amount.value,10).plus(this.amount.value).pow(1.5).times(1e4)},display:x(()=>u(F,null,[u("h3",null,[g("Small Fire")]),u("br",null,null),g("Burn 1000 logs for 0.1 coal and 50 ash"),u("br",null,null),u("br",null,null),g("Currently:"),u("br",null,null),g("-"),te(_.value),g(" logs/sec"),u("br",null,null),g("+"),te(b.value),g(" coal/sec"),u("br",null,null),g("+"),te(v.value),g(" ash/sec"),u("br",null,null),u("br",null,null),g("Cost: "),G(r(p.cost)),g(" "),p.resource.displayName])),onPurchase(){d.value=a.add(d.value,1)},style:{color:i,width:"160px"}})),k=Me(()=>({display:"0",style:{minHeight:"20px",width:"40px",color:i},canClick(){return a.gt(d.value,0)},onClick(){d.value=0}})),C=Me(()=>({display:"-",style:{minHeight:"20px",width:"40px",color:i},canClick(){return a.gt(d.value,0)},onClick(){d.value=a.sub(d.value,1)}})),R=Me(()=>({display:"+",style:{minHeight:"20px",width:"40px",color:i},canClick(){return a.lt(d.value,p.amount.value)},onClick(){d.value=a.add(d.value,1)}})),ie=Me(()=>({display:"Max",style:{minHeight:"20px",width:"40px",color:i},canClick(){return a.lt(d.value,p.amount.value)},onClick(){d.value=p.amount.value}})),I=St(p.amount,"small fires"),N=Ee(0),L=S(()=>a.times(N.value,1e4)),re=S(()=>a.times(N.value,10)),ve=S(()=>a.times(N.value,1e3)),Se=et(()=>({resource:I,cost:10,display:x(()=>u(F,null,[u("h3",null,[g("Bonfire")]),u("br",null,null),g("Burn 10,000 logs for 10 coal and 1000 ash"),u("br",null,null),u("br",null,null),g("Currently:"),u("br",null,null),g("-"),te(L.value),g(" logs/sec"),u("br",null,null),g("+"),te(re.value),g(" coal/sec"),u("br",null,null),g("+"),te(ve.value),g(" ash/sec"),u("br",null,null),u("br",null,null),g("Cost: "),G(r(Se.cost)),g(" "),Se.resource.displayName])),onPurchase(q){d.value=a.sub(d.value,q).max(0),N.value=a.add(N.value,1)},style:{color:i,width:"160px"}})),bt=Me(()=>({display:"0",style:{minHeight:"20px",width:"40px",color:i},canClick(){return a.gt(N.value,0)},onClick(){N.value=0}})),qt=Me(()=>({display:"-",style:{minHeight:"20px",width:"40px",color:i},canClick(){return a.gt(N.value,0)},onClick(){N.value=a.sub(N.value,1)}})),Et=Me(()=>({display:"+",style:{minHeight:"20px",width:"40px",color:i},canClick(){return a.lt(N.value,Se.amount.value)},onClick(){N.value=a.add(N.value,1)}})),_t=Me(()=>({display:"Max",style:{minHeight:"20px",width:"40px",color:i},canClick(){return a.lt(N.value,Se.amount.value)},onClick(){N.value=Se.amount.value}})),Q=Ee(0),Ue=S(()=>a.times(Q.value,1e6)),ye=S(()=>a.times(Q.value,1e4)),De=S(()=>a.times(Q.value,1e4)),me=et(()=>({resource:ae.logs,cost(){return a.pow(1.1,this.amount.value).times(1e7)},display:x(()=>u(F,null,[u("h3",null,[g("Charcoal Kiln")]),u("br",null,null),g("Burn 1,000,000 logs for 10,000 coal and 10,000 ash"),u("br",null,null),u("br",null,null),g("Currently:"),u("br",null,null),g("-"),te(Ue.value),g(" logs/sec"),u("br",null,null),g("+"),te(ye.value),g(" coal/sec"),u("br",null,null),g("+"),te(De.value),g(" ash/sec"),u("br",null,null),u("br",null,null),g("Cost: "),G(r(me.cost)),g(" "),me.resource.displayName])),onPurchase(){Q.value=a.add(Q.value,1)},style:{color:i,width:"160px"}})),wt=Me(()=>({display:"0",style:{minHeight:"20px",width:"40px",color:i},canClick(){return a.gt(Q.value,0)},onClick(){Q.value=0}})),Ze=Me(()=>({display:"-",style:{minHeight:"20px",width:"40px",color:i},canClick(){return a.gt(Q.value,0)},onClick(){Q.value=a.sub(Q.value,1)}})),Qe=Me(()=>({display:"+",style:{minHeight:"20px",width:"40px",color:i},canClick(){return a.lt(Q.value,me.amount.value)},onClick(){Q.value=a.add(Q.value,1)}})),at=Me(()=>({display:"Max",style:{minHeight:"20px",width:"40px",color:i},canClick(){return a.lt(Q.value,me.amount.value)},onClick(){Q.value=me.amount.value}})),lt=ue(()=>({resource:s,cost:5,display:{title:"Warmer Cutters",description:"Cut down twice as many trees/s"},style:{color:i}})),rt=ue(()=>({resource:s,cost:5,display:{title:"Warmer Planters",description:"Plant twice as many trees/s"},style:{color:i}})),$e=ue(()=>({resource:o,cost:5e3,display:{title:"Ashy Soil",description:"Trees give 25% more logs"},style:{color:i}})),Ye=ue(()=>({resource:I,cost:10,display:{title:"Bigger Fires",description:"Put all those fires together into a larger blaze"},onPurchase(){I.value=a.add(I.value,this.cost)},style:{color:i}})),ot=[lt,rt,$e,Ye],Pe=ue(()=>({resource:s,cost:250,display:{title:"Dedicated Cutter Heaters",description:"Double the bonus from Heated Cutters"},style:{color:i},visibility:()=>X(Ye.bought.value)})),Vt=ue(()=>({resource:s,cost:250,display:{title:"Dedicated Planter Heaters",description:"Double the bonus from Heated Planters"},style:{color:i},visibility:()=>X(Ye.bought.value)})),Ke=ue(()=>({canAfford(){return a.gte(ae.logs.value,1e5)&&a.gte(o.value,1e5)},onPurchase(){ae.logs.value=a.sub(ae.logs.value,1e5),o.value=a.sub(o.value,1e5)},display:x(()=>u(F,null,[u("h3",null,[g("Mulched Soil")]),u("br",null,null),g("Double the bonus from Fertilized Soil"),u("br",null,null),u("br",null,null),g("Cost: "),G(1e5),g(" "),ae.logs.displayName,u("br",null,null),G(1e5),g(" "),o.displayName])),style:{color:i},visibility:()=>X(Ye.bought.value)})),Lt=ue(()=>({resource:ae.logs,cost:1e7,display:{title:"Efficient Fires",description:"Move the fires underground to keep the coal from turning to ash"},style:{color:i},visibility:()=>X(Ye.bought.value)})),Sn=[Pe,Vt,Ke,Lt],ut=et(()=>({resource:s,cost(){let q=this.amount.value;return a.gte(q,50)&&(q=a.pow(q,2).div(50)),a.gte(q,200)&&(q=a.pow(q,2).div(200)),a.gte(q,2e6)&&(q=a.pow(q,2).div(2e6)),a.add(q,1).pow(2.5).times(10)},display:{title:"Heated Cutters",description:"Even warmer cutters cut down trees faster",effectDisplay:x(()=>u(F,null,[g("Cutters cut down trees "),te(rn.value),g("x faster")]))},style:{color:i},visibility:()=>X(lt.bought.value)})),$t=et(()=>({resource:s,cost(){let q=this.amount.value;return a.gte(q,50)&&(q=a.pow(q,2).div(50)),a.gte(q,200)&&(q=a.pow(q,2).div(200)),a.gte(q,2e6)&&(q=a.pow(q,2).div(2e6)),a.add(q,1).pow(2.5).times(10)},display:{title:"Heated Planters",description:"Even warmer planters plant trees faster",effectDisplay:x(()=>u(F,null,[g("Planters plant trees "),te(Ut.value),g("x faster")]))},style:{color:i},visibility:()=>X(rt.bought.value)})),ct=et(()=>({resource:o,cost(){let q=this.amount.value;return a.gte(q,50)&&(q=a.pow(q,2).div(50)),a.gte(q,200)&&(q=a.pow(q,2).div(200)),a.gte(q,2e6)&&(q=a.pow(q,2).div(2e6)),a.add(q,1).pow(1.5).times(5e4)},display:{title:"Fertilized Soil",description:"More fertilizer helps trees grow bigger",effectDisplay:x(()=>u(F,null,[g("Trees give "),te(jn.value),g("x more logs")]))},style:{color:i},visibility:()=>X($e.bought.value)})),Gt=[ut,$t,ct],Mn=Ie(()=>[ee(()=>({addend(){return a.times(ut.amount.value,.25)},description:"Heated Cutters",enabled(){return a.gt(ut.amount.value,0)}})),se(()=>({multiplier:2,description:"Dedicated Cutter Heaters",enabled:Pe.bought}))]),rn=S(()=>Mn.apply(1)),B=Ie(()=>[ee(()=>({addend(){return a.times($t.amount.value,.25)},description:"Heated Planters",enabled(){return a.gt($t.amount.value,0)}})),se(()=>({multiplier:2,description:"Dedicated Planter Heaters",enabled:Vt.bought}))]),Ut=S(()=>B.apply(1)),In=Ie(()=>[ee(()=>({addend(){return a.times(ct.amount.value,.25)},description:"Fertilized Soil",enabled(){return a.gt(ct.amount.value,0)}})),se(()=>({multiplier:2,description:"Mulched Soil",enabled:Ke.bought}))]),jn=S(()=>In.apply(1)),zn=Ie(()=>[ee(()=>({addend(){return b.value},description:"Small Fires",enabled(){return a.gt(d.value,0)}})),ee(()=>({addend(){return re.value},description:"Bonfires",enabled(){return a.gt(N.value,0)}})),ee(()=>({addend(){return ye.value},description:"Charcoal Kilns",enabled(){return a.gt(Q.value,0)}})),xi(()=>({exponent:1.25,description:"3 Elves Trained",enabled:ft.milestones[2].earned}))]),Hi=S(()=>zn.apply(0)),Wn=Ie(()=>[ee(()=>({addend(){return v.value},description:"Small Fires",enabled(){return a.gt(d.value,0)}})),ee(()=>({addend(){return ve.value},description:"Bonfires",enabled(){return a.gt(N.value,0)}})),ee(()=>({addend(){return De.value},description:"Charcoal Kilns",enabled(){return a.gt(Q.value,0)}}))]),ji=S(()=>Wn.apply(0)),Qn=Ie(()=>[ee(()=>({addend(){return a.negate(_.value)},description:"Small Fires",enabled(){return a.gt(d.value,0)}})),ee(()=>({addend(){return a.negate(L.value)},description:"Bonfires",enabled(){return a.gt(N.value,0)}})),ee(()=>({addend(){return a.negate(Ue.value)},description:"Charcoal Kilns",enabled(){return a.gt(Q.value,0)}}))]),Kn=S(()=>Qn.apply(0)),[zi,Wi]=qn(()=>[{title:"Log Consumption",modifier:Qn,base:0,visible(){return a.gt(d.value,0)||a.gt(N.value,0)||a.gt(Q.value,0)}},{title:"Coal Gain",modifier:zn,base:0,visible(){return a.gt(d.value,0)||a.gt(N.value,0)||a.gt(Q.value,0)}},{title:"Ash Gain",modifier:Wn,base:0,visible(){return a.gt(d.value,0)||a.gt(N.value,0)||a.gt(Q.value,0)}}]),An=T(!1),Qi=x(()=>u(We,{modelValue:An.value,"onUpdate:modelValue":q=>An.value=q},{header:()=>u("h2",null,[e,g(" Modifiers")]),body:zi}));return le.on("update",q=>{a.lt(z.day.value,zt)||a.times(q,Kn.value).negate().gt(ae.logs.value)||(ae.logs.value=a.times(q,Kn.value).plus(ae.logs.value),s.value=a.times(q,Hi.value).plus(s.value),o.value=a.times(q,ji.value).plus(o.value))}),Fe(()=>{z.day.value===zt&&a.gte(l.value,c)&&z.completeDay()}),{name:e,color:t,coal:s,totalCoal:l,ash:o,activeFires:d,buildFire:p,activeBonfires:N,buildBonfire:Se,activeKilns:Q,buildKiln:me,warmerCutters:lt,warmerPlanters:rt,basicFertilizer:$e,unlockBonfire:Ye,dedicatedCutters:Pe,dedicatedPlanters:Vt,betterFertilizer:Ke,unlockKiln:Lt,heatedCutters:ut,heatedPlanters:$t,moreFertilizer:ct,computedHeatedCutterEffect:rn,computedHeatedPlanterEffect:Ut,computedFertilizerEffect:jn,generalTabCollapsed:Wi,minWidth:700,display:x(()=>u(F,null,[u("div",null,[z.day.value===zt?`Reach ${G(c)} ${s.displayName} to complete the day`:`${e} Complete!`," ",g("-")," ",u("button",{class:"button",style:"display: inline-block;",onClick:()=>An.value=!0},[g("Check Modifiers")])]),he(f),he(Qi),u(Re,null,null),u(Jt,{resource:s,color:t,style:"margin-bottom: 0",effectDisplay:void 0},null),u(Re,null,null),u(Jt,{resource:o,color:n,style:"margin-bottom: 0",effectDisplay:void 0},null),u(Re,null,null),u(Ni,null,{default:()=>[u(dn,null,{default:()=>[he(p),u("div",null,[G(d.value),g("/"),G(p.amount.value)]),Oe(k,C,R,ie)]}),Ye.bought.value?u(F,null,[u(Re,null,null),u(dn,null,{default:()=>[he(Se),u("div",null,[G(N.value),g("/"),G(Se.amount.value)]),Oe(bt,qt,Et,_t)]})]):void 0,Lt.bought.value?u(F,null,[u(Re,null,null),u(dn,null,{default:()=>[he(me),u("div",null,[G(Q.value),g("/"),G(me.amount.value)]),Oe(wt,Ze,Qe,at)]})]):void 0]}),u(Re,null,null),Oe(...ot),Oe(...Sn),Oe(...Gt)]))}}),ql="trees",Wt=1,ae=Rt(ql,function(){const e="Trees",t="#4BDC13",n="green",i=St(0,"logs"),s=Ti(i),l=St(0,"saplings"),o=1e4,c=Ie(()=>[ee(()=>({addend:()=>a.times(Se.amount.value,10),description:"Expand Forest",enabled:N.bought})),ee(()=>({addend:()=>a.div(Te.foundationProgress.value,2),description:"75% Foundation Completed",enabled:Te.milestones.morePlantsMilestone1.earned})),se(()=>({multiplier:2,description:"5 Elves Trained",enabled:ft.milestones[4].earned}))]),f=St(S(()=>a.sub(c.apply(10),l.value)),"trees"),d=ue(()=>({resource:i,cost:10,display:{title:"Wooden Fingers",description:"Cut down an additional tree per click"}})),_=ue(()=>({resource:i,cost:10,display:{title:"Leafy Fingers",description:"Plant an additional tree per click"}})),b=ue(()=>({resource:i,cost:25,display:{title:"Automated Knives",description:"Cut down a tree every second"}})),v=ue(()=>({resource:i,cost:25,display:{title:"Automated Spade",description:"Plant a tree every second"}})),p=ue(()=>({resource:i,cost:40,display:{title:"Research I",description:"Trees give 25% more logs, and unlock more upgrades"}})),k=[d,_,b,v,p],C=ue(()=>({resource:i,cost:50,visibility:()=>X(p.bought.value),display:{title:"Sharper Fingers",description:"Manually cut trees twice as often"}})),R=ue(()=>({resource:i,cost:50,visibility:()=>X(p.bought.value),display:{title:"Greener Fingers",description:"Manually Plant trees twice as often"}})),ie=ue(()=>({resource:i,cost:150,visibility:()=>X(p.bought.value),display:{title:"Smart Knives",description:"Each time you manually chop trees, gain 1s of automatic tree chopping production"}})),I=ue(()=>({resource:i,cost:150,visibility:()=>X(p.bought.value),display:{title:"Smart Spades",description:"Each time you manually plant trees, gain 1s of automatic tree planting production"}})),N=ue(()=>({resource:i,cost:300,visibility:()=>X(p.bought.value),display:{title:"Research II",description:"Trees give 25% more logs, and unlock repeatable purchases"}})),L=[C,R,ie,I,N],re=et(()=>({resource:i,cost(){let B=this.amount.value;return a.gte(B,50)&&(B=a.pow(B,2).div(50)),a.gte(B,200)&&(B=a.pow(B,2).div(200)),a.gte(B,2e6)&&(B=a.pow(B,2).div(2e6)),a.times(100,B).add(200)},display:{title:"Generic Cutters",description:"Each cutter cuts down 1 tree/s"},visibility:()=>X(N.bought.value)})),ve=et(()=>({resource:i,cost(){let B=this.amount.value;return a.gte(B,50)&&(B=a.pow(B,2).div(50)),a.gte(B,200)&&(B=a.pow(B,2).div(200)),a.gte(B,2e6)&&(B=a.pow(B,2).div(2e6)),a.times(100,B).add(200)},display:{title:"Generic Planters",description:"Each planter plants 0.5 trees/s"},visibility:()=>X(N.bought.value)})),Se=et(()=>({resource:i,cost(){let B=this.amount.value;return a.gte(B,100)&&(B=a.pow(B,2).div(100)),a.gte(B,1e5)&&(B=a.pow(B,2).div(1e5)),a.pow(a.add(B,1),1.5).times(500)},display:{title:"Expand Forest",description:"Add 10 trees to the forest"},visibility:()=>X(N.bought.value)})),bt=[re,ve,Se],qt=Bt(()=>({direction:J.Right,width:600,height:25,fillStyle:`backgroundColor: ${n}`,progress:()=>z.day.value===Wt?a.log10(s.value).div(Math.log10(o)):1,display:x(()=>z.day.value===Wt?u(F,null,[G(s.value),g("/"),G(o)]):"")})),Et=Ie(()=>[ee(()=>({addend:1,description:"Wooden Fingers",enabled:d.bought})),ee(()=>({addend:De,description:"Smart Knives",enabled:ie.bought}))]),_t=S(()=>Et.apply(1)),Q=Ie(()=>[se(()=>({multiplier:.5,description:"Sharper Fingers",enabled:C.bought})),se(()=>({multiplier:()=>a.pow(.5,ft.totalElves.value),description:"1 Elf Trained",enabled:ft.milestones[0].earned}))]),Ue=S(()=>Q.apply(1)),ye=Ie(()=>[ee(()=>({addend:1,description:"Automated Knives",enabled:b.bought})),ee(()=>({addend:re.amount,description:"Generic Cutters",enabled:N.bought})),ee(()=>({addend:()=>a.div(Te.foundationProgress.value,5).floor(),description:"10% Foundation Completed",enabled:Te.milestones.autoCutMilestone1.earned})),se(()=>({multiplier:2,description:"30% Foundation Completed",enabled:Te.milestones.autoCutMilestone2.earned})),se(()=>({multiplier:2,description:"Warmer Cutters",enabled:de.warmerCutters.bought})),se(()=>({multiplier:de.computedHeatedCutterEffect,description:"Heated Cutters",enabled:()=>a.gt(de.heatedCutters.amount.value,0)}))]),De=S(()=>ye.apply(0)),me=Ie(()=>[ee(()=>({addend:1,description:"Leafy Fingers",enabled:_.bought})),ee(()=>({addend:lt,description:"Smart Spades",enabled:I.bought}))]),wt=S(()=>me.apply(1)),Ze=Ie(()=>[se(()=>({multiplier:.5,description:"Greener Fingers",enabled:R.bought})),se(()=>({multiplier:()=>a.pow(.5,ft.totalElves.value),description:"1 Elf Trained",enabled:ft.milestones[0].earned}))]),Qe=S(()=>Ze.apply(1)),at=Ie(()=>[ee(()=>({addend:1,description:"Automated Spade",enabled:v.bought})),ee(()=>({addend:()=>a.div(ve.amount.value,2),description:"Generic Planters",enabled:N.bought})),ee(()=>({addend:()=>a.div(Te.foundationProgress.value,10).floor(),description:"20% Foundation Completed",enabled:Te.milestones.autoPlantMilestone1.earned})),se(()=>({multiplier:2,description:"40% Foundation Completed",enabled:Te.milestones.autoPlantMilestone2.earned})),se(()=>({multiplier:2,description:"Warmer Planters",enabled:de.warmerPlanters.bought})),se(()=>({multiplier:de.computedHeatedPlanterEffect,description:"Heated Planters",enabled:()=>a.gt(de.heatedPlanters.amount.value,0)}))]),lt=S(()=>at.apply(0)),rt=Ie(()=>[se(()=>({multiplier:1.25,description:"Research I",enabled:p.bought})),se(()=>({multiplier:1.25,description:"Research II",enabled:N.bought})),se(()=>({multiplier:()=>a.div(Te.foundationProgress.value,20).add(1),description:"1% Foundation Completed",enabled:Te.milestones.logGainMilestone1.earned})),se(()=>({multiplier:2,description:"50% Foundation Completed",enabled:Te.milestones.logGainMilestone2.earned})),se(()=>({multiplier:1.25,description:"Ashy Soil",enabled:de.basicFertilizer.bought})),se(()=>({multiplier:de.computedFertilizerEffect,description:"Fertilized Soil",enabled:()=>a.gt(de.moreFertilizer.amount.value,0)})),se(()=>({multiplier:2,description:"4 Elves Trained",enabled:ft.milestones[3].earned})),xi(()=>({exponent:1.1,description:"100% Foundation Completed",enabled:Te.milestones.logGainMilestone3.earned}))]),$e=Ee(0),Ye=Bt(()=>({direction:J.Right,width:100,height:10,style:"margin-top: 8px",baseStyle:"margin-top: 0",fillStyle:"margin-top: 0; transition-duration: 0s",progress:()=>a.div($e.value,Ue.value)})),ot=Me(()=>({display:{title:"Cut trees",description:x(()=>u(F,null,[g("Cut down up to "),G(a.floor(_t.value))," ",g("tree"),a.eq(_t.value,1)?"":"s",g(" at once!"),u("br",null,null),he(Ye)]))},style:{minHeight:"80px"},canClick:()=>a.gte(f.value,1)&&a.gte($e.value,Ue.value),onClick(){if(a.lt($e.value,Ue.value))return;const B=a.floor(a.min(f.value,a.times(_t.value,a.div($e.value,Ue.value).floor())));i.value=a.add(i.value,rt.apply(B)),l.value=a.add(l.value,B),$e.value=0}})),Pe=Ee(0),Vt=Bt(()=>({direction:J.Right,width:100,height:10,style:"margin-top: 8px",baseStyle:"margin-top: 0",fillStyle:"margin-top: 0; transition-duration: 0s",progress:()=>a.div(Pe.value,Qe.value)})),Ke=Me(()=>({display:{title:"Plant trees",description:x(()=>u(F,null,[g("Plant up to "),G(a.floor(wt.value))," ",g("tree"),a.eq(wt.value,1)?"":"s",g(" at once!"),u("br",null,null),he(Vt)]))},style:{minHeight:"80px"},canClick:()=>a.gte(l.value,1)&&a.gte(Pe.value,Qe.value),onClick(){if(a.lt(Pe.value,Qe.value))return;const B=a.floor(a.min(l.value,a.times(wt.value,a.div(Pe.value,Qe.value).floor())));l.value=a.sub(l.value,B),Pe.value=0}})),[Lt,Sn]=qn(()=>[{title:"Logs per Tree",modifier:rt,base:1,visible:p.bought},{title:"Manual Cutting Amount",modifier:Et,base:1,visible:d.bought,unit:"/click"},{title:"Manual Cutting Cooldown",modifier:Q,base:1,visible:d.bought,unit:"s"},{title:"Manual Planting Amount",modifier:me,base:1,visible:_.bought,unit:"/click"},{title:"Manual Planting Cooldown",modifier:Ze,base:1,visible:_.bought,unit:"s"},{title:"Auto Cutting Amount",modifier:ye,base:0,visible:b.bought,unit:"/s"},{title:"Auto Planting Amount",modifier:at,base:0,visible:v.bought,unit:"/s"},{title:"Forest Size",modifier:c,base:10,visible:N.bought}]),ut=T(!1),$t=x(()=>u(We,{modelValue:ut.value,"onUpdate:modelValue":B=>ut.value=B},{header:()=>u("h2",null,[e,g(" Modifiers")]),body:Lt}));le.on("update",B=>{if(a.lt(z.day.value,Wt))return;a.gte($e.value,Ue.value)?$e.value=Ue.value:($e.value=a.add($e.value,B),ot.isHolding.value&&ot.onClick()),a.gte(Pe.value,Qe.value)?Pe.value=Qe.value:(Pe.value=a.add(Pe.value,B),Ke.isHolding.value&&Ke.onClick());const Ut=a.min(f.value,a.times(De.value,B));i.value=a.add(i.value,rt.apply(Ut)),l.value=a.add(l.value,Ut);const In=a.min(l.value,a.times(lt.value,B));l.value=a.sub(l.value,In)}),Fe(()=>{z.day.value===Wt&&a.gte(s.value,o)&&z.completeDay()});const ct=S(()=>a.sub(De.value,lt.value)),Gt=S(()=>a.sub(lt.value,De.value)),Mn=ii(()=>({key:"c",description:'Press the "Cut trees" button.',onPress:()=>{ot.canClick.value&&ot.onClick()}})),rn=ii(()=>({key:"p",description:'Press the "Plant trees" button.',onPress:()=>{Ke.canClick.value&&Ke.onClick()}}));return{name:e,color:t,logs:i,totalLogs:s,trees:f,saplings:l,cutTree:ot,plantTree:Ke,cutTreeHK:Mn,plantTreeHK:rn,row1Upgrades:k,row2Upgrades:L,row1Buyables:bt,manualCutProgress:$e,manualPlantProgress:Pe,generalTabCollapsed:Sn,minWidth:700,display:x(()=>u(F,null,[u("div",null,[z.day.value===Wt?`Reach ${G(1e4)} ${i.displayName} to complete the day`:`${e} Complete!`," ",g("-")," ",u("button",{class:"button",style:"display: inline-block;",onClick:()=>ut.value=!0},[g("Check Modifiers")])]),he(qt),he($t),u(Re,null,null),u(Jt,{resource:i,color:t,style:"margin-bottom: 0",effectDisplay:a.gt(De.value,0)?`+${te(rt.apply(De.value))}/s`:void 0},null),u(Jt,{resource:l,color:n,style:"margin-bottom: 0",effectDisplay:{[-1]:`${G(ct.value)}/s`,0:void 0,1:`+${G(ct.value)}/s`}[a.compare(ct.value,0)]},null),u(Jt,{resource:f,color:n,style:"margin-bottom: 0",effectDisplay:{[-1]:`${G(Gt.value)}/s`,0:void 0,1:`+${G(Gt.value)}/s`}[a.compare(Gt.value,0)]},null),u(Re,null,null),Oe(ot,Ke),u("div",null,[g("Tip: You can hold down on actions to perform them automatically")]),u(Re,null,null),Oe(...k),Oe(...L),Oe(...bt)]))}});var Fi="./assets/tree.35808197.png",Bi="./assets/sws.714ad454.png",Di="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMgAAADICAYAAACtWK6eAAAACXBIWXMAAFxGAABcRgEUlENBAAAAG3RFWHRTb2Z0d2FyZQBDZWxzeXMgU3R1ZGlvIFRvb2zBp+F8AAAMuElEQVR42u3dO4zkSAEG4L/Kr5me6dl1QkJAjkDiElJISAiO7CQSyCBHQis08QQrXUJISExKxCNBguQICJCIkBAZOqlmH0LbPW27CKa78XjtabddZVeV/z/ZXe12r11V39TDdllorcEwTHsEgTAMgTAMgTAMgTAMgTAMgTAMgTz5z4Ro/c+01oJVwSwaSBcOQmEWD6QPDiJhFgnkHBxEwiwKyBAcBMIQCIEwBDIcCJEwBEIgDIEQCEMgBMIQCIEwBOIQECJhggfCXoQhEAJhCIRAGAIhEIbxCQiRMARCIMySgXCYxRAIgTAEQiAMgRAIw/gEhEiY4IGwF2EIhEAYAiEQhkAIhGF8AkIkDIEQCLNkIBxmMQRCIAyBEAhDIATCMD4BIRImeCDsRRgCIRCGQAiEIRACYQjEJyBEwhAIgTBLBsJhFkMgBMIQCIEwBEIgDIH4BIRImOCBsBdhCIRAGAIhEIZACIQhEE7UGYZAGMYPIBxmMQRCIAyBEAhDIATCEAgn6gzjEBD2IgyBEAhDIATCEAiBMATCiTrDEAjD+AGEwyyGQAiEIRACYQiEQBgC4USdYRwCwl6EIRACYQiEQBgCIRCGQDhRZxgCYRg/gHCYxRAIgTAEQiAMgRAIQyCcqDME4hAQ9iIMgRAIQyAEwhCIs0CGfgeBMUEDsRGiIRD3DsoxJMRCIARCJK318Nz5ttVTaOVDIERitex9LysngRBJeGXua3k5C4RIwixr38qMQAhk8rL2qdw4xCKS2crah7LjJJ1IZi1v18uOFwoJZPYyz/P820qpLwgkQBwhIHGh3PM8/41S6jMCmaiSbm9fnfXv7+5eLxKJSz+U8jz/m1LqEwKxUEnngqhlB0AAkPtfi7u71wmBzAJkB+BzAL9USv2HQObHUQCo9jB0rTdJl9CLuDikzfN8A+AHSqnfEYiBShqBowJQ7mEcGvXh9zp0JKZw7H/qxwBwf38vDH3n35VS31w8EAM46o37nJR7IM3P16EMRuL80uXAcs/zvM/nxP39fTALILMBmRGHrgFpw1H/d+Lu7nXsK5JmGWutxZhyPwHko/M1DWWOcvUSyO3tq3rjPrfAqlrv0fX5Iz7fgNicV+R5fuxd9+Vz8hxtIJmyfGcBMhJH2VI5fQtL14ZYuu9nXUcyxWR7j6NZjr3Oz2ckkwMxgKOtYsSZSIoeFfykEQxBYrsCp1qFauAYFF+ReAPk9vbVrmVYJQYg0bVhlujTW9zevtq5dG1k6uVZE0BsIrEJZVIgI3HgxLCqfi2jAHBo0LLja4uxQ6g5Ks5XHL4i8QXIA9pXmXTHSoro+PeHv4vxuIw7yRzBRMXNcVHPNA7bQKz8QJoKyMjeQ7c09CYKWfv7LhyHHiOZsqGNrbRQcBCI4UquzTvaeouuIVcTSP1zwuZwykbFhYTDRySTABnRe1QNHBrdV79PZi4cQyttZhxDL8QGhcRZIHscBwBVA0l9Ut61kqX3KCI4knMrbUogtnuNqcF4A2Rk79HsIQ4XCWXHfOTQU0g4mHMqbUk4bKExsjjiIpAOHJ3l4DqMWkP8XCn18x5l9msAP1oiCpNQlgDk5DxjqqVagw3zT0qp77SU0wrAdwF8CuCnBsq9OJS9lBJpmsrdblcB0HEci4uLi8RmA+0LsOu7m5+fC4lVIANxoDEhb4OiXe8tTjScPwP4sVLqn/ty+iqAvwD4F4AbAN8a+v1SygKAllKiLMt6XUAIgTiORZqmMo5jaQPGOVhOfb8JJCED6UTiW6/RUukawKdKqd8KIb4B4PcAHgB8ZT/Puhrw1UWtzMVj29BHHFEUIU1TmWVZr0ULG6tM9Qbf9/uHfMYkEqeAnHo60MTGClNVSh8kWuufvXnz5ocAPsH/V+vSAeVcPG0P+ohCSikA6Kqq9Hq9TufCYaAuNAY+jOUkEAO9x+w4bA853r17V1ZVVWito9rw8axlaSllUVUVhHj8eBw/XuqpqkoLIbBer8+6a8AlHG1AhhxjnufXSqn/eg3EBRx9J5djG1Ge59hsNtXDw4Muy1I0hpHRmeVcRFEEIQS01ojjWMRxLJIkGTRHcw1IY1iKIb1InudfAvi+UuqvwQFxDYephpRlWVkUBfZAjh3CkOFVkiQyyzIRx/GouZmLOBpAxJjjzPP8a0qpfwc1xHJhaGWjUa1Wq+rDhw/Yl//gFbn9PANJkiDLMoQGpOvWl6km7E4DcR3HmMqK47gqimIUjn05I4oiXFxcIEmSoHA8VzdjjvesOxpcXcUyjSNN0w9XV1eXzYI9A0fbLfd638DFXA1MCAEpJW5ubkLuPYwec57nN0qp994B2SM57Ek1+kKglHKzX/LUUkq9Xq9XI76ueUdxs7JmuylSSokXL14QiIVexEUgFYBqzK3pQoiN1loeGrOUUqdpqi8vL1cjcOhnehQA0Pf397PcTp9lGVarVVBA9ntwtd2xbeyY+yBx7l6s29tX5dBb1GswjkunQogqSRJcXV1djG0seZ5XDSD1JdpZgAghsD+/SYHYmBs0cDw5TQIZn+3jfyeOJ34YWt3c3GSmGkoDyZOeZOph1mH+kWXZ5CtYNq4XPbNzo5hrmBUKkK14fOu9kFKiqqoDkCrLMnF5eZmYbCQtPQn2E3U5B5CxE3RbQPp+f489f8VccxGnH7k9I81tgQ6/VnmeJ6YbSEsvUv+eyZBEUWQEx8AyMHkqeiiOsVCWBOSj59SjKNI3NzexhcbRtYnEpEBevnx5vAcrUCDC5jksCUhzK1EhhNBxHIvr62srzz109SJLADICR9eKlDaBw1sgEyApmwUrpUQURTgFZCCOrnPRPgPpuUhhqqcQzwARtpEvEYhoTmDTNBWr1cr4CshzQKbqRQ6Tc9NAniuXATiab+/CM0B6v1JhynmIF1uP9kh9k4djpcRxjPV6bXwN/cSqyyS9iOkJ+gQx1ktM2YuECKTZiIQpGH2AmHpP34lyRBRFWK/XvuKwCsVbIBaRVF0FnSQJdrudsUo4tWZvG8hh84U0TXF5eekyCHHizwQyIRBjy4RnAPloRWaK3qPH8bnYW1iZkAcJxAKS5uvArO0p2+g9nAQyM5I+y7Xe9B4hANG2Ctq1oZVHUE6tVh3LqnbHLoEYRjLZioivOBwCcrKMTB7ngHvKcqXUG+eAGEQyKw6XgcyARA8tn7neg5jn+deVUv8IEYj1XF9fI0kS7SuOGcDoMeUzx94AeZ7/QSn1PSeBuIwkSRJUVYU4jrFarXQoQCxi0SbKY8wxjbgz4hcAvlBK/dE5IC4iOVxrONzGcXju4urqSoeCwzQU2xtd2z6Orsm6E0Bc7kkO+05VVQUp5fERVykl3r9/j1AypGHaeo59IJLBe/cSiIEepf4rAFRVhdAy5c6SlnoR40icAeLDpL0OxqVym7pxTrEDysA7h0cNfZ0H4hOSkDPFDveGkYxaPXsOiXDxJyGREMgZQDrvwzPxbIhwdahAJO4hmWNzuR5IjAJpIhEuj6WJhEB6HOOzd3KP7UWE65NNInECyOgJsMXjPPmow5gbGIUPqzFEMjsSZ4F0HeeigBCKO73IECC2X4pqemHBWyBE4sQwq9fkd+qVMAIhFGeAPNfoGnOC1tcX2AJSliU2mw2klNi//xFCiLPveggCCJFMDuQjJB1/1zZZ1mPnBVMmGCCE4hSQNiTNHqRXL0QghOIbkHM3WuhTDzaQGHnK1HkgQxr6k5MiFFNAxmyn9NFni6IQVVVBCIGHhwcUReHkXdFOAzHRuOtvmGIzH9V7jNpvbLfbHX+/3W6Pd0DvX3/NOcjcQyT2KtMD2W63xycwt9styrJEWZZenftigLSdMMGczmq1OrzzsPd7O7bbLaSUeHh4gNYaZVl6+1CZk0BsN9iTG4QRTHNi3jWXEG09RlEU0FpDa/1kaEUgHuDoi2TJcA6bVGRZhouLi15ANpsNiqKAEAK73e74pKXvK6OLBTIUyVKgSCkhpUSSJCeRFEWB7Xb7pLcI4ZKBcw9MzdHwzkWypOFXkiSIoqjt1QpProW8ffsWQHibVzgDZO5Gdw6SJQGRUj4ZcjX3BwNwXJkKbeOK2TdtcKmhEQjjBBBXGxeBMH3ag1UgLjcsAmH6tAVrQFxvVATC9GkHVoD40KAIhOnTBowDCQ0HgSwXh3EgIeIgkGXCWCSQoVfRiWR5MBYHZAwOIlkWCgIhEIIgEHsFRyhhNH4CsViwRBIWhEmAuNRwpixoYgkThxUgLjSYOQuaWAjE2cbiXPdMLF7jsA7EdsNxtVCJLJw6FKG+rXXpCfWuBgJhpob0EwC/IgwCYWbqgXweChMIwxAIwxAIwxAIwxAIwxAIwxAIwxAIw4Sa/wGDtUAHUuMNRQAAAABJRU5ErkJggg==",Oi="./assets/elf.9fbfa563.png";const z=Rt("main",function(){const e=Ee(1),t=T(!1),n=T(-1),i=T(""),s=T();function l(f){const d=Ee(!1);return Be(()=>{const _=f(),b=Ae(_.shouldNotify);return{..._,opened:d,shouldNotify:b,[gt]:Wa,[vt]:function(){const{day:v,layer:p,symbol:k,opened:C,shouldNotify:R,story:ie,completedStory:I}=this;return{day:v,symbol:k,opened:C,shouldNotify:R,onOpenLore(){var re,ve;const N=z.day.value>v-1;n.value=N?v-1:-1;const L=r((ve=(re=Ce[p!=null?p:"trees"])==null?void 0:re.name)!=null?ve:"");i.value=N?`${L} - Completed!`:L,s.value=N?`${ie}
${I}`:ie,t.value=!0},onOpenLayer(){if(window.matchMedia("(min-width: 1468px)").matches)if(A.tabs.includes(p!=null?p:"trees")){const N=A.tabs.lastIndexOf(p!=null?p:"trees");A.tabs.splice(N,1)}else A.tabs.push(p!=null?p:"trees"),z.minimized.value=!0;else A.tabs.splice(1,1/0,p!=null?p:"trees")},onUnlockLayer(){C.value=!0,setTimeout(()=>{var N,L;n.value=-1,i.value=r((L=(N=Ce[p!=null?p:"trees"])==null?void 0:N.name)!=null?L:""),s.value=ie,A.devSpeed=null,t.value=!0},1e3)}}}}})}const o=[l(()=>({day:1,shouldNotify:!1,layer:"trees",symbol:Fi,story:"Oh no! Santa forgot about Christmas and it's only 25 days away! He's asked for your help due to your history getting large quantities of things in short amounts of time. Unfortunately you're really starting from scratch here - let's start with getting wood, which you'll need for everything from building workshops to wrapping paper to many of the toys themselves!",completedStory:"Santa looks at all the wood you've gathered and tells you you've done well! He says you should take the rest of the day off so you're refreshed for tomorrow's work. Good Job!"})),l(()=>({day:2,shouldNotify:!1,layer:"workshop",symbol:Bi,story:"Santa looked over your tree farm and was impressed with how much you could accomplish in just one day. Today's goal is to get a workshop built up for the elves to work in - and apparently, they need quite a lot of space to work!",completedStory:"The workshop complete, Santa once again dismisses you for the day. With a strong foundation, this workshop should suffice for supporting future work toward this impossible mission. Good Job!"})),l(()=>({day:3,shouldNotify:!1,layer:"coal",symbol:Di,story:"Santa tells you that unfortunately there are quite a few naughty children out there this year, and he's going to need you to gather as much coal as you can for him to give out.",completedStory:"Santa looks at all the coal you've gathered and tells you you've done well! He says you should take the rest of the day off so you're refreshed for tomorrow's work. Good Job!"})),l(()=>({day:4,shouldNotify:!1,layer:"elves",symbol:Oi,story:"Alright, it seems you finally have enough things setup to start bringing in the elves! Unfortunately, it seems they'll need to be retrained on how to help, since they're out of practice by 11 months!",completedStory:"The workshop now hums with the bustling elves working everything. They can take it from here - you deserve a break after such a long day! Good Job!"})),l(()=>({day:5,shouldNotify:!1,layer:null,symbol:"",story:"",completedStory:""})),l(()=>({day:6,shouldNotify:!1,layer:null,symbol:"",story:"",completedStory:""})),l(()=>({day:7,shouldNotify:!1,layer:null,symbol:"",story:"",completedStory:""})),l(()=>({day:8,shouldNotify:!1,layer:null,symbol:"",story:"",completedStory:""})),l(()=>({day:9,shouldNotify:!1,layer:null,symbol:"",story:"",completedStory:""})),l(()=>({day:10,shouldNotify:!1,layer:null,symbol:"",story:"",completedStory:""})),l(()=>({day:11,shouldNotify:!1,layer:null,symbol:"",story:"",completedStory:""})),l(()=>({day:12,shouldNotify:!1,layer:null,symbol:"",story:"",completedStory:""})),l(()=>({day:13,shouldNotify:!1,layer:null,symbol:"",story:"",completedStory:""})),l(()=>({day:14,shouldNotify:!1,layer:null,symbol:"",story:"",completedStory:""})),l(()=>({day:15,shouldNotify:!1,layer:null,symbol:"",story:"",completedStory:""})),l(()=>({day:16,shouldNotify:!1,layer:null,symbol:"",story:"",completedStory:""})),l(()=>({day:17,shouldNotify:!1,layer:null,symbol:"",story:"",completedStory:""})),l(()=>({day:18,shouldNotify:!1,layer:null,symbol:"",story:"",completedStory:""})),l(()=>({day:19,shouldNotify:!1,layer:null,symbol:"",story:"",completedStory:""})),l(()=>({day:20,shouldNotify:!1,layer:null,symbol:"",story:"",completedStory:""})),l(()=>({day:21,shouldNotify:!1,layer:null,symbol:"",story:"",completedStory:""})),l(()=>({day:22,shouldNotify:!1,layer:null,symbol:"",story:"",completedStory:""})),l(()=>({day:23,shouldNotify:!1,layer:null,symbol:"",story:"",completedStory:""})),l(()=>({day:24,shouldNotify:!1,layer:null,symbol:"",story:"",completedStory:""}))];function c(){n.value=e.value-1,i.value="Day Complete!",s.value=o[e.value-1].completedStory,t.value=!0,e.value++,z.minimized.value=!1,A.devSpeed=0}return{name:"Calendar",days:o,day:e,loreScene:n,loreTitle:i,loreBody:s,showLoreModal:t,completeDay:c,minWidth:700,display:x(()=>u(F,null,[A.devSpeed===0?u("div",null,[g("Game Paused")]):null,A.devSpeed&&A.devSpeed!==1?u("div",null,[g("Dev Speed: "),te(A.devSpeed),g("x")]):null,A.offlineTime?u("div",null,[g("Offline Time: "),_n(A.offlineTime)]):null,u(Re,null,null),u("div",{class:"advent"},[o.reduce((f,d)=>(f[f.length-1].length===4&&f.push([]),f[f.length-1].push(d),f),[[]]).map(f=>Oe(...f))])]))}}),Vl=e=>[z,ae,Te,de,ft],Gn=S(()=>!1);function Ll(e,t){["0.0","0.1","0.2"].includes(e!=null?e:"")&&(t.offlineProd=!1)}var Ri=Object.freeze(Object.defineProperty({__proto__:null,main:z,getInitialLayers:Vl,hasWon:Gn,fixOldSave:Ll},Symbol.toStringTag,{value:"Module"}));const Gl={class:"scene"},Ul=["src"],Hl=["src"],jl=["src"],zl=["src"],Wl=V({__name:"Scene",props:{day:null},setup(e){return(t,n)=>(y(),M("div",Gl,[e.day>=0?(y(),M("img",{key:0,src:r(Fi),class:"scene-item",style:{left:"10%",bottom:"10%"}},null,8,Ul)):P("",!0),e.day>=1?(y(),M("img",{key:1,src:r(Bi),class:"scene-item",style:{left:"40%",bottom:"12%"}},null,8,Hl)):P("",!0),e.day>=2?(y(),M("img",{key:2,src:r(Di),class:"scene-item",style:{left:"65%",bottom:"12%",width:"40px",height:"40px"}},null,8,jl)):P("",!0),e.day>=3?(y(),M("img",{key:3,src:r(Oi),class:"scene-item",style:{left:"52%",bottom:"12%"}},null,8,zl)):P("",!0)]))}});var Ql=Z(Wl,[["__scopeId","data-v-080e23dc"]]);const Kl=V({components:{Context:Ii},props:{index:{type:Number,required:!0},tab:{type:Function,required:!0},display:{type:$(Object,String,Function),required:!0},minimized:{type:Object,required:!0},minWidth:{type:$(Number,String),required:!0},name:{type:$(String),required:!0},color:$(String),minimizable:$(Boolean),nodes:{type:Object,required:!0}},setup(e){const{display:t,index:n,minimized:i,minWidth:s,tab:l}=Ne(e),o=Mi(t),c=S(()=>W.allowGoBack&&n.value>0&&!i.value);function f(){A.tabs.splice(r(e.index),1)}Mt(()=>_(i.value,r(s.value))),ze([i,ha(s)],([b,v])=>_(b,v));function d(b){e.nodes.value=b}function _(b,v){const p=typeof v=="number"||Number.isNaN(parseInt(v))?v+"px":v,k=l.value();k!=null&&(b?(k.style.flexGrow="0",k.style.flexShrink="0",k.style.width="60px",k.style.minWidth=k.style.flexBasis="",k.style.margin="0"):(k.style.flexGrow="",k.style.flexShrink="",k.style.width="",k.style.minWidth=k.style.flexBasis=p,k.style.margin=""))}return{component:o,showGoBack:c,updateNodes:d,unref:r,goBack:f}}});function Jl(e,t,n,i,s,l){const o=ht("Context");return y(),M("div",{class:"layer-container",style:pe({"--layer-color":e.unref(e.color)})},[e.showGoBack?(y(),M("button",{key:0,class:"goBack",onClick:t[0]||(t[0]=(...c)=>e.goBack&&e.goBack(...c))},"\u274C")):P("",!0),e.minimized.value?(y(),M("button",{key:1,class:"layer-tab minimized",onClick:t[1]||(t[1]=c=>e.minimized.value=!1)},[m("div",null,j(e.unref(e.name)),1)])):(y(),M("div",{key:2,class:fe(["layer-tab",{showGoBack:e.showGoBack}])},[u(o,{onUpdateNodes:e.updateNodes},{default:D(()=>[(y(),U(ke(e.component)))]),_:1},8,["onUpdateNodes"])],2)),e.unref(e.minimizable)?(y(),M("button",{key:3,class:"minimize",onClick:t[2]||(t[2]=c=>e.minimized.value=!0)}," \u25BC ")):P("",!0)],4)}var Xl=Z(Kl,[["render",Jl],["__scopeId","data-v-0158bec3"]]);const qi=e=>(nt("data-v-4b4bda40"),e=e(),it(),e),Zl=qi(()=>m("h2",null,"Changelog",-1)),Yl=qi(()=>m("details",{open:""},[m("summary",null,[g("v0.0 Initial Commit - "),m("time",null,"2021-09-04")]),g(" This is the first release :D "),m("ul",null,[m("li",{class:"feature"},"Did everything"),m("li",{class:"fix"},"Had some fun"),m("li",{class:"breaking"},"Removed everything"),m("li",{class:"balancing"},"Created some bugs to fix later")])],-1)),er=V({__name:"Changelog",setup(e,{expose:t}){const n=T(!1);return t({open(){n.value=!0}}),(i,s)=>(y(),U(We,{modelValue:n.value,"onUpdate:modelValue":s[0]||(s[0]=l=>n.value=l)},{header:D(()=>[Zl]),body:D(()=>[Yl]),_:1},8,["modelValue"]))}});var tr=Z(er,[["__scopeId","data-v-4b4bda40"]]),nr=V({props:{element:Object,display:{type:$(Object,String,Function),required:!0},style:$(Object,String,Array),classes:$(Object),direction:$(String),xoffset:$(String),yoffset:$(String),pinned:Object},setup(e){const{element:t,display:n,pinned:i}=Ne(e),s=T(!1),l=S(()=>(ge(i)||s.value)&&o.value),o=At(n),c=Le(K(x(()=>{const _=ge(t);return _==null?"":Xe(_)})));function f(_){const b=i;_.shiftKey&&b&&(b.value=!b.value,_.stopPropagation(),_.preventDefault())}const d=S(()=>ge(i)&&sn[ne.theme].showPin);return{Direction:J,isHovered:s,isShown:l,comp:o,elementComp:c,unref:r,togglePinned:f,showPin:d}}});const ir={key:0,class:"material-icons pinned"};function sr(e,t,n,i,s,l){return y(),M("div",{class:fe(["tooltip-container",{shown:e.isShown}]),onMouseenter:t[0]||(t[0]=o=>e.isHovered=!0),onMouseleave:t[1]||(t[1]=o=>e.isHovered=!1),onClickCapture:t[2]||(t[2]=(...o)=>e.togglePinned&&e.togglePinned(...o))},[Je(e.$slots,"default",{},void 0,!0),e.elementComp?(y(),U(ke(e.elementComp),{key:0})):P("",!0),u(bn,{name:"fade"},{default:D(()=>{var o;return[e.isShown?(y(),M("div",{key:0,class:fe(["tooltip",{top:e.unref(e.direction)===e.Direction.Up,left:e.unref(e.direction)===e.Direction.Left,right:e.unref(e.direction)===e.Direction.Right,bottom:e.unref(e.direction)===e.Direction.Down,...e.unref(e.classes)}]),style:pe([{"--xoffset":e.unref(e.xoffset)||"0px","--yoffset":e.unref(e.yoffset)||"0px"},(o=e.unref(e.style))!=null?o:{}])},[e.showPin?(y(),M("span",ir,"push_pin")):P("",!0),e.comp?(y(),U(ke(e.comp),{key:1})):P("",!0)],6)):P("",!0)]}),_:1})],34)}var ce=Z(nr,[["render",sr],["__scopeId","data-v-6102fa3a"]]);const ar={class:"info-modal-header"},lr=["src","alt"],rr={class:"info-modal-title"},or={key:0},ur={key:0},cr={key:0},dr=m("div",null," Made in Profectus, by thepaperpilot with inspiration from Acameada and Jacorb ",-1),fr=m("br",null,null,-1),mr=m("br",null,null,-1),pr=["href"],hr=m("span",{class:"material-icons info-modal-discord"},"discord",-1),gr=m("div",null,[m("a",{href:"https://discord.gg/WzejVAx",class:"info-modal-discord-link"},[m("span",{class:"material-icons info-modal-discord"},"discord"),g(" The Paper Pilot Community ")])],-1),vr=m("div",null,[m("a",{href:"https://discord.gg/F3xveHV",class:"info-modal-discord-link"},[m("span",{class:"material-icons info-modal-discord"},"discord"),g(" The Modding Tree ")])],-1),yr=m("br",null,null,-1);var br=V({__name:"Info",props:{changelog:null},setup(e,{expose:t}){const n=e,{title:i,logo:s,author:l,discordName:o,discordLink:c,versionNumber:f,versionTitle:d}=W,_=Ne(n),b=T(!1),v=S(()=>_n(A.timePlayed)),p=S(()=>K(x(()=>u(F,null,[wi.map(he)]))));t({open(){b.value=!0}});function k(){var C;(C=r(_.changelog))==null||C.open()}return(C,R)=>(y(),U(We,{modelValue:b.value,"onUpdate:modelValue":R[0]||(R[0]=ie=>b.value=ie)},{header:D(()=>[m("div",ar,[r(s)?(y(),M("img",{key:0,class:"info-modal-logo",src:r(s),alt:r(i)},null,8,lr)):P("",!0),m("div",rr,[m("h2",null,j(r(i)),1),m("h4",null,[g(" v"+j(r(f)),1),r(d)?(y(),M("span",or,": "+j(r(d)),1)):P("",!0)])])])]),body:D(({shown:ie})=>[ie?(y(),M("div",ur,[r(l)?(y(),M("div",cr,"By "+j(r(l)),1)):P("",!0),dr,fr,m("div",{class:"link",onClick:k},"Changelog"),mr,m("div",null,[r(c)?(y(),M("a",{key:0,href:r(c),class:"info-modal-discord-link"},[hr,g(" "+j(r(o)),1)],8,pr)):P("",!0)]),gr,vr,yr,m("div",null,"Time Played: "+j(r(v)),1),(y(),U(ke(r(p))))])):P("",!0)]),_:1},8,["modelValue"]))}});const _r={class:"field"},wr=V({__name:"Toggle",props:{title:null,modelValue:{type:Boolean}},emits:["update:modelValue"],setup(e,{emit:t}){const n=e,i=S(()=>K(r(n.title)||"","span")),s=S({get(){return!!n.modelValue},set(l){t("update:modelValue",l)}});return(l,o)=>(y(),M("label",_r,[Tn(m("input",{type:"checkbox",class:"toggle","onUpdate:modelValue":o[0]||(o[0]=c=>_e(s)?s.value=c:null)},null,512),[[es,r(s)]]),(y(),U(ke(r(i))))]))}});var Dt=Z(wr,[["__scopeId","data-v-2b109500"]]);const Vi=e=>(nt("data-v-1975661c"),e=e(),it(),e),Nr=Vi(()=>m("div",{class:"header"},[m("h2",null,"Options")],-1)),kr=Vi(()=>m("hr",null,null,-1));var Cr=V({__name:"Options",setup(e,{expose:t}){const n=T(!1);t({open(){n.value=!0}});const i=Object.keys(sn).map(p=>({label:pi(p),value:p})),s=S(()=>K(x(()=>u(F,null,[_i.map(he)])))),{showTPS:l,theme:o,unthrottled:c}=Ne(ne),{autosave:f,offlineProd:d}=Ne(A),_=S({get(){return A.devSpeed===0},set(p){A.devSpeed=p?0:null}});x(()=>u("span",null,[g("Offline Production"),u(ce,{display:"Save-specific"},{default:()=>[g("*")]})]));const b=x(()=>u("span",null,[g("Autosave"),u(ce,{display:"Save-specific"},{default:()=>[g("*")]})])),v=x(()=>u("span",null,[g("Pause game"),u(ce,{display:"Save-specific"},{default:()=>[g("*")]})]));return(p,k)=>(y(),U(We,{modelValue:n.value,"onUpdate:modelValue":k[4]||(k[4]=C=>n.value=C)},{header:D(()=>[Nr]),body:D(()=>[u(Ln,{title:"Theme",options:r(i),modelValue:r(o),"onUpdate:modelValue":k[0]||(k[0]=C=>_e(o)?o.value=C:null)},null,8,["options","modelValue"]),(y(),U(ke(r(s)))),u(Dt,{title:"Show TPS",modelValue:r(l),"onUpdate:modelValue":k[1]||(k[1]=C=>_e(l)?l.value=C:null)},null,8,["modelValue"]),kr,u(Dt,{title:r(b),modelValue:r(f),"onUpdate:modelValue":k[2]||(k[2]=C=>_e(f)?f.value=C:null)},null,8,["title","modelValue"]),r(W).enablePausing?(y(),U(Dt,{key:0,title:r(v),modelValue:r(_),"onUpdate:modelValue":k[3]||(k[3]=C=>_e(_)?_.value=C:null)},null,8,["title","modelValue"])):P("",!0)]),_:1},8,["modelValue"]))}});var Sr=Z(Cr,[["__scopeId","data-v-1975661c"]]);const Mr=["onSubmit"],Ir={class:"field"},Ar={key:0,class:"field-title"},Er=["placeholder"],$r=V({__name:"Text",props:{title:null,modelValue:null,textArea:{type:Boolean},placeholder:null,maxHeight:null,submitOnBlur:{type:Boolean}},emits:["update:modelValue","submit","cancel"],setup(e,{emit:t}){const n=e,i=At(tt(n,"title"),"span"),s=Le(null);yn(()=>{var f;(f=s.value)==null||f.focus()});const l=S({get(){return r(n.modelValue)||""},set(f){t("update:modelValue",f)}});function o(){t("submit")}function c(){n.submitOnBlur!==!1?t("submit"):t("cancel")}return(f,d)=>(y(),M("form",{onSubmit:Xt(o,["prevent"])},[m("div",Ir,[r(i)?(y(),M("span",Ar,[(y(),U(ke(r(i))))])):P("",!0),e.textArea?(y(),U(r(rs),{key:1,modelValue:r(l),"onUpdate:modelValue":d[0]||(d[0]=_=>_e(l)?l.value=_:null),placeholder:e.placeholder,maxHeight:e.maxHeight,onBlur:c,ref_key:"field",ref:s},null,8,["modelValue","placeholder","maxHeight"])):Tn((y(),M("input",{key:2,type:"text","onUpdate:modelValue":d[1]||(d[1]=_=>_e(l)?l.value=_:null),placeholder:e.placeholder,class:fe({fullWidth:!e.title}),onBlur:c,ref_key:"field",ref:s},null,42,Er)),[[ts,r(l)]])])],40,Mr))}});var Li=Z($r,[["__scopeId","data-v-67b44a54"]]);const Pr={key:0},Tr=["onClick","disabled"],xr={key:0},Fr=["onClick"],Br=V({__name:"DangerButton",props:{disabled:{type:Boolean},skipConfirm:{type:Boolean}},emits:["click","confirmingChanged"],setup(e,{emit:t}){const i=Ne(e),s=T(!1);ze(s,c=>{t("confirmingChanged",c)});function l(){if(r(i.skipConfirm)){t("click");return}s.value&&t("click"),s.value=!s.value}function o(){s.value=!1}return(c,f)=>(y(),M("span",{class:fe(["container",{confirming:s.value}])},[s.value?(y(),M("span",Pr,"Are you sure?")):P("",!0),m("button",{onClick:Xt(l,["stop"]),class:"button danger",disabled:e.disabled},[s.value?(y(),M("span",xr,"Yes")):Je(c.$slots,"default",{key:1},void 0,!0)],8,Tr),s.value?(y(),M("button",{key:1,class:"button",onClick:Xt(o,["stop"])},"No",8,Fr)):P("",!0)],2))}});var Dr=Z(Br,[["__scopeId","data-v-2f8ef34c"]]);const Or=["onClick"],Rr=V({__name:"FeedbackButton",props:{left:{type:Boolean}},emits:["click"],setup(e,{emit:t}){const n=T(!1),i=T(null);function s(){t("click"),i.value&&clearTimeout(i.value),n.value=!1,Mt(()=>{n.value=!0,i.value=setTimeout(()=>n.value=!1,500)})}return(l,o)=>(y(),M("button",{onClick:Xt(s,["stop"]),class:fe(["feedback",{activated:n.value,left:e.left}])},[Je(l.$slots,"default",{},void 0,!0)],10,Or))}});var qr=Z(Rr,[["__scopeId","data-v-01a1b95c"]]);const st=e=>(nt("data-v-5285ac49"),e=e(),it(),e),Vr=st(()=>m("div",{class:"handle material-icons"},"drag_handle",-1)),Lr={key:0,class:"actions"},Gr=st(()=>m("span",{class:"material-icons"},"content_paste",-1)),Ur=st(()=>m("span",{class:"material-icons"},"content_copy",-1)),Hr=st(()=>m("span",{class:"material-icons"},"edit",-1)),jr=st(()=>m("span",{class:"material-icons",style:{margin:"-2px"}},"delete",-1)),zr={key:1,class:"actions"},Wr=st(()=>m("span",{class:"material-icons"},"check",-1)),Qr=st(()=>m("span",{class:"material-icons"},"close",-1)),Kr={key:2,class:"details"},Jr={class:"save-version"},Xr=st(()=>m("br",null,null,-1)),Zr={key:0},Yr={key:1},eo={key:3,class:"details"},to={key:4,class:"details error"},no=st(()=>m("br",null,null,-1)),io=V({__name:"Save",props:{save:null},emits:["export","open","duplicate","delete","editName"],setup(e,{emit:t}){const n=e,{save:i}=Ne(n),s=new Intl.DateTimeFormat("en-US",{year:"numeric",month:"numeric",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric"}),l=T(!1),o=T(!1),c=T("");ze(l,()=>c.value=i.value.name||"");const f=S(()=>i.value&&i.value.id===A.id),d=S(()=>f.value?A.time:i.value&&i.value.time||0),_=Mi(S(()=>{var v,p,k,C;return`Day ${(C=(k=(p=(v=i.value)==null?void 0:v.layers)==null?void 0:p.main)==null?void 0:k.day)!=null?C:1}`}));function b(){t("editName",c.value),l.value=!1}return(v,p)=>(y(),M("div",{class:fe(["save",{active:r(f)}])},[Vr,l.value?(y(),M("div",zr,[m("button",{onClick:b,class:"button"},[u(ce,{display:"Save",direction:r(J).Left,class:"info"},{default:D(()=>[Wr]),_:1},8,["direction"])]),m("button",{onClick:p[5]||(p[5]=k=>l.value=!l.value),class:"button"},[u(ce,{display:"Cancel",direction:r(J).Left,class:"info"},{default:D(()=>[Qr]),_:1},8,["direction"])])])):(y(),M("div",Lr,[r(i).error==null&&!o.value?(y(),U(qr,{key:0,onClick:p[0]||(p[0]=k=>t("export")),class:"button",left:""},{default:D(()=>[u(ce,{display:"Export",direction:r(J).Left,class:"info"},{default:D(()=>[Gr]),_:1},8,["direction"])]),_:1})):P("",!0),r(i).error==null&&!o.value?(y(),M("button",{key:1,onClick:p[1]||(p[1]=k=>t("duplicate")),class:"button"},[u(ce,{display:"Duplicate",direction:r(J).Left,class:"info"},{default:D(()=>[Ur]),_:1},8,["direction"])])):P("",!0),r(i).error==null&&!o.value?(y(),M("button",{key:2,onClick:p[2]||(p[2]=k=>l.value=!l.value),class:"button"},[u(ce,{display:"Edit Name",direction:r(J).Left,class:"info"},{default:D(()=>[Hr]),_:1},8,["direction"])])):P("",!0),u(Dr,{disabled:r(f),onClick:p[3]||(p[3]=k=>t("delete")),onConfirmingChanged:p[4]||(p[4]=k=>o.value=k)},{default:D(()=>[u(ce,{display:"Delete",direction:r(J).Left,class:"info"},{default:D(()=>[jr]),_:1},8,["direction"])]),_:1},8,["disabled"])])),r(i).error==null&&!l.value?(y(),M("div",Kr,[m("button",{class:"button open",onClick:p[6]||(p[6]=k=>t("open"))},[m("h3",null,j(r(i).name),1)]),m("span",Jr,"v"+j(r(i).modVersion),1),Xr,r(d)?(y(),M("div",Zr,"Last played "+j(r(s).format(r(d))),1)):P("",!0),r(_)?(y(),M("div",Yr,[(y(),U(ke(r(_))))])):P("",!0)])):r(i).error==null&&l.value?(y(),M("div",eo,[u(Li,{modelValue:c.value,"onUpdate:modelValue":p[7]||(p[7]=k=>c.value=k),class:"editname",onSubmit:b},null,8,["modelValue"])])):(y(),M("div",to,[g(" Error: Failed to load save with id "+j(r(i).id),1),no,g(j(r(i).error),1)]))],2))}});var so=Z(io,[["__scopeId","data-v-5285ac49"]]);const Un=e=>(nt("data-v-3b9991aa"),e=e(),it(),e),ao=Un(()=>m("h2",null,"Saves Manager",-1)),lo={class:"modal-footer"},ro={class:"field"},oo=Un(()=>m("span",{class:"field-title"},"Create Save",-1)),uo={class:"field-buttons"},co={class:"footer"},fo=Un(()=>m("div",{style:{"flex-grow":"1"}},null,-1)),mo=V({__name:"SavesManager",setup(e,{expose:t}){const n=T(!1),i=T(null);t({open(){n.value=!0}});const s=T(!1),l=T(""),o=T(null);ze(l,I=>{I?Mt(()=>{try{if(I[0]!=="{")if(I[0]==="e")I=decodeURIComponent(escape(atob(I)));else if(I[0]==="\u1BE1")I=mt.decompressFromUTF16(I);else{console.warn("Unable to determine preset encoding",I),s.value=!0;return}const N=JSON.parse(I);if(typeof N!="object"){s.value=!0;return}const L=cn();N.id=L,He(N),l.value="",s.value=!1,ne.saves.push(L)}catch{s.value=!0}}):s.value=!1});let c={},f=T(Object.keys(c).reduce((I,N)=>(I.push({label:N.split("/").slice(-1)[0].slice(0,-4),value:c[N]}),I),[]));const d=vn({});function _(I){if(d[I]==null){let N=localStorage.getItem(I);if(N==null)d[I]={error:"Save doesn't exist in localStorage",id:I};else if(N==="dW5kZWZpbmVk")d[I]={error:"Save is undefined",id:I};else try{if(N[0]!=="{")if(N[0]==="e")N=decodeURIComponent(escape(atob(N)));else if(N[0]==="\u1BE1")N=mt.decompressFromUTF16(N);else return console.warn("Unable to determine preset encoding",N),s.value=!0,d[I]={error:"Unable to determine preset encoding",id:I},d[I];d[I]={...JSON.parse(N),id:I}}catch(L){d[I]={error:L,id:I},console.warn(`SavesManager: Failed to load info about save with id ${I}: +${L} +${N}`)}}return d[I]}ze(n,I=>{I&&Object.keys(d).forEach(N=>delete d[N])});const b=S(()=>ne.saves.reduce((I,N)=>(I[N]=_(N),I),{}));function v(I){let N;switch(A.id===I?N=vi(A[oe]):N=JSON.stringify(b.value[I]),W.exportEncoding){default:console.warn(`Unknown save encoding: ${W.exportEncoding}. Defaulting to lz`);case"lz":N=mt.compressToUTF16(N);break;case"base64":N=btoa(unescape(encodeURIComponent(N)));break;case"plain":break}const L=document.createElement("textarea");L.value=N,document.body.appendChild(L),L.select(),L.setSelectionRange(0,99999),document.execCommand("copy"),document.body.removeChild(L)}function p(I){A.id===I&&He();const N={...b.value[I],id:cn()};He(N),ne.saves.push(N.id)}function k(I){ne.saves=ne.saves.filter(N=>N!==I),localStorage.removeItem(I),d[I]=void 0}function C(I){b.value[A.id].time=A.time,He(),d[A.id]=void 0,Ct(b.value[I]),d[I]=void 0}function R(I){if(o.value=I,Mt(()=>{o.value=null}),I[0]!=="{")if(I[0]==="e")I=decodeURIComponent(escape(atob(I)));else if(I[0]==="\u1BE1")I=mt.decompressFromUTF16(I);else{console.warn("Unable to determine preset encoding",I);return}const N=JSON.parse(I);N.id=cn(),He(N),ne.saves.push(N.id),C(N.id)}function ie(I,N){const L=b.value[I];L&&(L.name=N,A.id===I?(A.name=N,He()):(He(L),d[I]=void 0))}return(I,N)=>(y(),U(We,{modelValue:n.value,"onUpdate:modelValue":N[4]||(N[4]=L=>n.value=L),ref_key:"modal",ref:i},{header:D(()=>[ao]),body:D(({shown:L})=>[L?(y(),U(r(ls),{key:0,list:r(ne).saves,handle:".handle",itemKey:re=>re},{item:D(({element:re})=>[u(so,{save:r(b)[re],onOpen:ve=>C(re),onExport:ve=>v(re),onEditName:ve=>ie(re,ve),onDuplicate:ve=>p(re),onDelete:ve=>k(re)},null,8,["save","onOpen","onExport","onEditName","onDuplicate","onDelete"])]),_:1},8,["list","itemKey"])):P("",!0)]),footer:D(()=>[m("div",lo,[u(Li,{modelValue:l.value,"onUpdate:modelValue":N[0]||(N[0]=L=>l.value=L),title:"Import Save",placeholder:"Paste your save here!",class:fe({importingFailed:s.value})},null,8,["modelValue","class"]),m("div",ro,[oo,m("div",uo,[m("button",{class:"button",onClick:N[1]||(N[1]=L=>C(r(xt)().id))},"New Game"),Object.keys(r(f)).length>0?(y(),U(Ln,{key:0,options:r(f),modelValue:o.value,"onUpdate:modelValue":N[2]||(N[2]=L=>R(L)),closeOnSelect:"",placeholder:"Select preset",class:"presets"},null,8,["options","modelValue"])):P("",!0)])]),m("div",co,[fo,m("button",{class:"button modal-default-button",onClick:N[3]||(N[3]=L=>n.value=!1)}," Close ")])])]),_:1},8,["modelValue"]))}});var Gi=Z(mo,[["__scopeId","data-v-3b9991aa"]]);const qe=e=>(nt("data-v-4a3f8425"),e=e(),it(),e),po=["src","alt"],ho={key:1,class:"title"},go=qe(()=>m("div",{style:{"flex-grow":"1",cursor:"unset"}},null,-1)),vo={class:"discord"},yo={class:"discord-links"},bo={key:0},_o=["href"],wo=qe(()=>m("li",null,[m("a",{href:"https://discord.gg/WzejVAx",target:"_blank"},"The Paper Pilot Community")],-1)),No=qe(()=>m("li",null,[m("a",{href:"https://discord.gg/F3xveHV",target:"_blank"},"The Modding Tree")],-1)),ko={href:"https://forums.moddingtree.com/",target:"_blank"},Co=qe(()=>m("span",{class:"material-icons"},"forum",-1)),So=qe(()=>m("span",{class:"material-icons"},"info",-1)),Mo=qe(()=>m("span",{class:"material-icons"},"library_books",-1)),Io=qe(()=>m("span",{class:"material-icons"},"settings",-1)),Ao=qe(()=>m("span",{class:"material-icons"},"library_books",-1)),Eo=qe(()=>m("span",{class:"material-icons"},"settings",-1)),$o=qe(()=>m("span",{class:"material-icons"},"info",-1)),Po={href:"https://forums.moddingtree.com/",target:"_blank"},To=qe(()=>m("span",{class:"material-icons"},"forum",-1)),xo={class:"discord"},Fo={class:"discord-links"},Bo={key:0},Do=["href"],Oo=qe(()=>m("li",null,[m("a",{href:"https://discord.gg/WzejVAx",target:"_blank"},"The Paper Pilot Community")],-1)),Ro=qe(()=>m("li",null,[m("a",{href:"https://discord.gg/F3xveHV",target:"_blank"},"The Modding Tree")],-1)),qo=V({__name:"Nav",setup(e){const t=T(null),n=T(null),i=T(null),s=T(null),{useHeader:l,banner:o,title:c,discordName:f,discordLink:d,versionNumber:_}=W;function b(){window.open(d,"mywindow")}return(v,p)=>(y(),M(F,null,[r(l)?(y(),M("div",It({key:0,class:"nav"},v.$attrs),[r(o)?(y(),M("img",{key:0,src:r(o),class:"banner",alt:r(c)},null,8,po)):(y(),M("div",ho,j(r(c)),1)),m("div",{onClick:p[0]||(p[0]=k=>{var C;return(C=s.value)==null?void 0:C.open()}),class:"version-container"},[u(ce,{display:"Changelog",direction:r(J).Down,class:"version"},{default:D(()=>[m("span",null,"v"+j(r(_)),1)]),_:1},8,["direction"])]),go,m("div",vo,[m("span",{onClick:b,class:"material-icons"},"discord"),m("ul",yo,[r(d)?(y(),M("li",bo,[m("a",{href:r(d),target:"_blank"},j(r(f)),9,_o)])):P("",!0),wo,No])]),m("div",null,[m("a",ko,[u(ce,{display:"Forums",direction:r(J).Down,yoffset:"5px"},{default:D(()=>[Co]),_:1},8,["direction"])])]),m("div",{onClick:p[1]||(p[1]=k=>{var C;return(C=t.value)==null?void 0:C.open()})},[u(ce,{display:"Info",direction:r(J).Down,class:"info"},{default:D(()=>[So]),_:1},8,["direction"])]),m("div",{onClick:p[2]||(p[2]=k=>{var C;return(C=n.value)==null?void 0:C.open()})},[u(ce,{display:"Saves",direction:r(J).Down,xoffset:"-20px"},{default:D(()=>[Mo]),_:1},8,["direction"])]),m("div",{onClick:p[3]||(p[3]=k=>{var C;return(C=i.value)==null?void 0:C.open()})},[u(ce,{display:"Options",direction:r(J).Down,xoffset:"-66px"},{default:D(()=>[Io]),_:1},8,["direction"])])],16)):(y(),M("div",It({key:1,class:"overlay-nav"},v.$attrs),[m("div",{onClick:p[4]||(p[4]=k=>{var C;return(C=s.value)==null?void 0:C.open()}),class:"version-container"},[u(ce,{display:"Changelog",direction:r(J).Right,xoffset:"25%",class:"version"},{default:D(()=>[m("span",null,"v"+j(r(_)),1)]),_:1},8,["direction"])]),m("div",{onClick:p[5]||(p[5]=k=>{var C;return(C=n.value)==null?void 0:C.open()})},[u(ce,{display:"Saves",direction:r(J).Right},{default:D(()=>[Ao]),_:1},8,["direction"])]),m("div",{onClick:p[6]||(p[6]=k=>{var C;return(C=i.value)==null?void 0:C.open()})},[u(ce,{display:"Options",direction:r(J).Right},{default:D(()=>[Eo]),_:1},8,["direction"])]),m("div",{onClick:p[7]||(p[7]=k=>{var C;return(C=t.value)==null?void 0:C.open()})},[u(ce,{display:"Info",direction:r(J).Right},{default:D(()=>[$o]),_:1},8,["direction"])]),m("div",null,[m("a",Po,[u(ce,{display:"Forums",direction:r(J).Right,xoffset:"7px"},{default:D(()=>[To]),_:1},8,["direction"])])]),m("div",xo,[m("span",{onClick:b,class:"material-icons"},"discord"),m("ul",Fo,[r(d)?(y(),M("li",Bo,[m("a",{href:r(d),target:"_blank"},j(r(f)),9,Do)])):P("",!0),Oo,Ro])])],16)),u(br,{ref_key:"info",ref:t,changelog:s.value},null,8,["changelog"]),u(Gi,{ref_key:"savesManager",ref:n},null,512),u(Sr,{ref_key:"options",ref:i},null,512),u(tr,{ref_key:"changelog",ref:s},null,512)],64))}});var Ui=Z(qo,[["__scopeId","data-v-4a3f8425"]]);const Hn=e=>(nt("data-v-6f125a90"),e=e(),it(),e),Vo={class:"inner-tab"},Lo={key:1},Go=Hn(()=>m("br",null,null,-1)),Uo=g(" You can help continue the "),Ho=Hn(()=>m("i",null,"advent",-1)),jo=g("ure at: "),zo=Hn(()=>m("a",{href:"https://discord.gg/WzejVAx",class:"info-modal-discord-link"},[m("span",{class:"material-icons info-modal-discord"},"discord"),g(" The Paper Pilot Community ")],-1)),Wo=V({__name:"Game",setup(e){const t=tt(A,"tabs"),n=S(()=>Object.keys(Ce)),i=W.useHeader,s=At(z.loreBody);function l(o){const{display:c,minimized:f,minWidth:d,name:_,color:b,minimizable:v,nodes:p}=o;return{display:c,minimized:f,minWidth:d,name:_,color:b,minimizable:v,nodes:p}}return(o,c)=>(y(),M("div",{class:fe(["tabs-container",{useHeader:r(i)}])},[(y(!0),M(F,null,ai(r(t),(f,d)=>{var _,b;return y(),M("div",{key:d,class:fe(["tab",r((_=r(Ce)[f])==null?void 0:_.classes)]),ref_for:!0,ref:`tab-${d}`,style:pe(r((b=r(Ce)[f])==null?void 0:b.style))},[d===0&&!r(i)?(y(),U(Ui,{key:0})):P("",!0),m("div",Vo,[r(n).includes(f)?(y(),U(Xl,It({key:0},l(r(Ce)[f]),{index:d,tab:()=>{var v;return(v=o.$refs[`tab-${d}`])==null?void 0:v[0]}}),null,16,["index","tab"])):(y(),U(ke(f),{key:1,index:d},null,8,["index"]))])],6)}),128)),u(We,{modelValue:r(z).showLoreModal.value,"onUpdate:modelValue":c[0]||(c[0]=f=>r(z).showLoreModal.value=f)},{header:D(()=>[m("h2",null,j(r(z).loreTitle.value),1)]),body:D(()=>[r(s)?(y(),U(ke(r(s)),{key:0})):P("",!0),r(z).loreScene.value!==-1?(y(),M("div",Lo,[u(Ql,{day:r(z).loreScene.value},null,8,["day"]),Go,Uo,Ho,jo,zo])):P("",!0)]),_:1},8,["modelValue"])],2))}});var Qo=Z(Wo,[["__scopeId","data-v-6f125a90"]]);const ln=e=>(nt("data-v-4a50ce42"),e=e(),it(),e),Ko={class:"game-over-modal-header"},Jo=["src","alt"],Xo={class:"game-over-modal-title"},Zo=ln(()=>m("h2",null,"Congratulations!",-1)),Yo={key:0},eu=ln(()=>m("br",null,null,-1)),tu=ln(()=>m("div",null," Please check the Discord to discuss the game or to check for new content updates! ",-1)),nu=ln(()=>m("br",null,null,-1)),iu=["href"],su=ln(()=>m("span",{class:"material-icons game-over-modal-discord"},"discord",-1)),au=V({__name:"GameOverScreen",setup(e){const{title:t,logo:n,discordName:i,discordLink:s,versionNumber:l,versionTitle:o}=W,c=S(()=>_n(A.timePlayed)),f=S(()=>Gn.value&&!A.keepGoing),d=tt(A,"autosave");function _(){A.keepGoing=!0}function b(){Ct(xt())}return(v,p)=>(y(),U(We,{"model-value":r(f)},{header:D(()=>[m("div",Ko,[r(n)?(y(),M("img",{key:0,class:"game-over-modal-logo",src:r(n),alt:r(t)},null,8,Jo)):P("",!0),m("div",Xo,[Zo,m("h4",null,"You've beaten "+j(r(t))+" v"+j(r(l))+": "+j(r(o)),1)])])]),body:D(({shown:k})=>[k?(y(),M("div",Yo,[m("div",null,"It took you "+j(r(c))+" to beat the game.",1),eu,tu,nu,m("div",null,[m("a",{href:r(s),class:"game-over-modal-discord-link"},[su,g(" "+j(r(i)),1)],8,iu)]),u(Dt,{title:"Autosave",modelValue:r(d),"onUpdate:modelValue":p[0]||(p[0]=C=>_e(d)?d.value=C:null)},null,8,["modelValue"])])):P("",!0)]),footer:D(()=>[m("div",{class:"game-over-footer"},[m("button",{onClick:_,class:"button"},"Keep Going"),m("button",{onClick:b,class:"button danger"},"Play Again")])]),_:1},8,["model-value"]))}});var lu=Z(au,[["__scopeId","data-v-4a50ce42"]]);const Cn=e=>(nt("data-v-3de07c06"),e=e(),it(),e),ru=Cn(()=>m("div",{class:"nan-modal-header"},[m("h2",null,"NaN value detected!")],-1)),ou={key:0},uu=Cn(()=>m("br",null,null,-1)),cu=["href"],du=Cn(()=>m("span",{class:"material-icons nan-modal-discord"},"discord",-1)),fu=Cn(()=>m("br",null,null,-1)),mu={class:"nan-footer"},pu=V({__name:"NaNScreen",setup(e){const{discordName:t,discordLink:n}=W,i=tt(A,"autosave"),s=tt(Y,"hasNaN"),l=T(null),o=S(()=>{var p;return(p=Y.NaNPath)==null?void 0:p.join(".")}),c=S(()=>{var p;return(p=Y.NaNPath)==null?void 0:p.slice(-1)[0]}),f=S(()=>Y.NaNReceiver&&c.value?Y.NaNReceiver[c.value]:null),d=S({get(){return A.devSpeed===0},set(p){A.devSpeed=p?null:0}});function _(){Y.NaNReceiver&&c.value&&(Y.NaNReceiver[c.value]=new a(0),Y.hasNaN=!1)}function b(){Y.NaNReceiver&&c.value&&(Y.NaNReceiver[c.value]=new a(1),Y.hasNaN=!1)}function v(){Y.NaNReceiver&&c.value&&(Y.NaNReceiver[c.value]=new a(NaN),Y.hasNaN=!1)}return(p,k)=>(y(),M(F,null,[u(We,It({modelValue:r(s),"onUpdate:modelValue":k[4]||(k[4]=C=>_e(s)?s.value=C:null)},p.$attrs),{header:D(()=>[ru]),body:D(()=>[m("div",null,[g(' Attempted to assign "'+j(r(o))+'" to NaN',1),r(f)?(y(),M("span",ou,j(" ")+"(previously "+j(r(te)(r(f)))+")",1)):P("",!0),g(". Auto-saving has been "+j(r(i)?"enabled":"disabled")+". Check the console for more details, and consider sharing it with the developers on discord. ",1)]),uu,m("div",null,[m("a",{href:r(n),class:"nan-modal-discord-link"},[du,g(" "+j(r(t)),1)],8,cu)]),fu,u(Dt,{title:"Autosave",modelValue:r(i),"onUpdate:modelValue":k[0]||(k[0]=C=>_e(i)?i.value=C:null)},null,8,["modelValue"]),r(W).enablePausing?(y(),U(Dt,{key:0,title:"Pause game",modelValue:r(d),"onUpdate:modelValue":k[1]||(k[1]=C=>_e(d)?d.value=C:null)},null,8,["modelValue"])):P("",!0)]),footer:D(()=>[m("div",mu,[m("button",{onClick:k[2]||(k[2]=C=>{var R;return(R=l.value)==null?void 0:R.open()}),class:"button"},"Open Saves Manager"),m("button",{onClick:_,class:"button"},"Set to 0"),m("button",{onClick:b,class:"button"},"Set to 1"),r(f)&&r(a).neq(r(f),0)&&r(a).neq(r(f),1)?(y(),M("button",{key:0,onClick:k[3]||(k[3]=C=>s.value=!1),class:"button"}," Set to previous ")):P("",!0),m("button",{onClick:v,class:"button danger"},"Ignore")])]),_:1},16,["modelValue"]),u(Gi,{ref_key:"savesManager",ref:l},null,512)],64))}});var hu=Z(pu,[["__scopeId","data-v-3de07c06"]]);const gu={key:0,class:"tpsDisplay"},vu={key:0,class:"low"},yu=V({__name:"TPS",setup(e){const t=S(()=>a.div(Y.lastTenTicks.length,Y.lastTenTicks.reduce((l,o)=>l+o,0))),n=T([]);Fe(()=>{n.value.push(Math.round(t.value.toNumber())),n.value.length>10&&(n.value=n.value.slice(1))});const i=S(()=>n.value.reduce((l,o)=>a.max(l,o),0)),s=S(()=>a.sub(t.value,i.value).gt(1));return(l,o)=>r(t).isNan()?P("",!0):(y(),M("div",gu,[g(" TPS: "+j(r(G)(r(t)))+" ",1),u(bn,{name:"fade"},{default:D(()=>[r(s)?(y(),M("span",vu,j(r(G)(r(i))),1)):P("",!0)]),_:1})]))}});var bu=Z(yu,[["__scopeId","data-v-46a3ed5b"]]);var _u=V({__name:"App",setup(e){const t=W.useHeader,n=S(()=>sn[ne.theme].variables),i=tt(ne,"showTPS"),s=S(()=>K(x(()=>u(F,null,[fa.map(he)]))));return(l,o)=>(y(),M(F,null,[m("div",{id:"modal-root",style:pe(r(n))},null,4),m("div",{class:fe(["app",{useHeader:r(t)}]),style:pe(r(n))},[r(t)?(y(),U(Ui,{key:0})):P("",!0),u(Qo),r(r(i))?(y(),U(bu,{key:1})):P("",!0),u(lu),u(hu),(y(),U(ke(r(s))))],6)],64))}});var wu=Z(_u,[["__scopeId","data-v-7c41425b"]]);function Nu(e={}){const{immediate:t=!1,onNeedRefresh:n,onOfflineReady:i,onRegistered:s,onRegisterError:l}=e;let o,c;const f=async(d=!0)=>{d&&(o==null||o.addEventListener("controlling",_=>{_.isUpdate&&window.location.reload()})),c&&c.waiting&&await us(c.waiting,{type:"SKIP_WAITING"})};if("serviceWorker"in navigator){o=new os("./sw.js",{scope:"./",type:"classic"}),o.addEventListener("activated",d=>{d.isUpdate||i==null||i()});{const d=()=>{n==null||n()};o.addEventListener("waiting",d),o.addEventListener("externalwaiting",d)}o.register({immediate:t}).then(d=>{c=d,s==null||s(d)}).catch(d=>{l==null||l(d)})}return f}function ku(e={}){const{immediate:t=!0,onNeedRefresh:n,onOfflineReady:i,onRegistered:s,onRegisterError:l}=e,o=T(!1),c=T(!1);return{updateServiceWorker:Nu({immediate:t,onNeedRefresh(){o.value=!0,n==null||n()},onOfflineReady(){c.value=!0,i==null||i()},onRegistered:s,onRegisterError:l}),offlineReady:c,needRefresh:o}}document.title=W.title;window.projInfo=W;if(W.id==="")throw"Project ID is empty! Please select a unique ID for this project in /src/data/projInfo.json";requestAnimationFrame(async()=>{console.log(`%cMade in Profectus%c +Learn more at www.moddingtree.com`,"font-weight: bold; font-size: 24px; color: #A3BE8C; background: #2E3440; padding: 4px 8px; border-radius: 8px;","padding: 4px;"),await ra();const{globalBus:e,startGameLoop:t}=await mn(()=>Promise.resolve().then(function(){return la}),void 0),n=window.vue=ns(wu);e.emit("setupVue",n),n.mount("#app"),Mt(()=>{const i=ri(),{updateServiceWorker:s}=ku({onNeedRefresh(){i.info("New content available, click or reload to update.",{timeout:!1,closeOnClick:!1,draggable:!1,icon:{iconClass:"material-icons",iconChildren:"refresh",iconTag:"i"},rtl:!1,onClick(){s()}})},onOfflineReady(){i.info("App ready to work offline")},onRegisterError:console.warn,onRegistered(l){l&&setInterval(l.update,60*60*1e3)}})}),t()}); diff --git a/assets/index.dfc8a303.css b/assets/index.dfc8a303.css new file mode 100644 index 0000000..dce29a7 --- /dev/null +++ b/assets/index.dfc8a303.css @@ -0,0 +1 @@ +.table{display:flex;flex-flow:column wrap;justify-content:center;align-items:center;max-width:100%;margin:0 auto}.table+.table{margin-top:10px}.row{display:flex;flex-flow:row wrap;justify-content:center;align-items:stretch;max-width:100%;margin:0 10px}.row>:not(.feature){margin:0;display:flex}.col{display:flex;flex-flow:column wrap;justify-content:center;align-items:center;height:100%;margin:10px 0}.row.mergeAdjacent>.feature:not(.dontMerge),.row.mergeAdjacent>.tooltip-container>.feature:not(.dontMerge){margin-left:0;margin-right:0;border-radius:0}.row.mergeAdjacent>.feature:not(.dontMerge):first-child,.row.mergeAdjacent>.tooltip-container:first-child>.feature:not(.dontMerge){border-radius:var(--border-radius) 0 0 var(--border-radius)}.row.mergeAdjacent>.feature:not(.dontMerge):last-child,.row.mergeAdjacent>.tooltip-container:last-child>.feature:not(.dontMerge){border-radius:0 var(--border-radius) var(--border-radius) 0}.row.mergeAdjacent>.feature:not(.dontMerge):first-child:last-child,.row.mergeAdjacent>.tooltip-container:first-child:last-child>.feature:not(.dontMerge){border-radius:var(--border-radius)}.col.mergeAdjacent .feature:not(.dontMerge){margin-top:0;margin-bottom:0;border-radius:0}.col.mergeAdjacent .feature:not(.dontMerge):first-child{border-radius:var(--border-radius) var(--border-radius) 0 0}.col.mergeAdjacent .feature:not(.dontMerge):last-child{border-radius:0 0 var(--border-radius) var(--border-radius)}.col.mergeAdjacent .feature:not(.dontMerge):first-child:last-child{border-radius:var(--border-radius)}.resize-listener[data-v-2b1dc1bc]{position:absolute;top:0px;left:0;right:-4px;bottom:5px;z-index:-10;pointer-events:none}.modal-mask{position:fixed;z-index:9998;top:0;left:0;bottom:0;right:0;background-color:#00000080;transition:opacity .3s ease}.modal-wrapper{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%)}.modal-container{width:640px;max-width:95vw;max-height:95vh;background-color:var(--background);padding:20px;border-radius:5px;transition:all .3s ease;text-align:left;border:var(--modal-border);box-sizing:border-box;display:flex;flex-direction:column}.modal-header{width:100%}.modal-body{margin:20px 0;width:100%;overflow-y:auto;overflow-x:hidden}.modal-footer{width:100%}.modal-default-footer{display:flex}.modal-default-flex-grow{flex-grow:1}.modal-enter-from,.modal-leave-active{opacity:0}.modal-enter-from .modal-container,.modal-leave-active .modal-container{-webkit-transform:scale(1.1);transform:scale(1.1)}.advent{width:80%;max-width:700px;background:url(./adventCalendarGameJamCalandar.0fdeb6b8.png);background-size:contain;display:flex;flex-direction:column;padding-top:28%;padding-left:10%;padding-right:10%;background-repeat:no-repeat;aspect-ratio:3151 / 4190}.advent>.table{width:100%}.advent>.table>.row{width:100%;margin:0 0 -5%;justify-content:space-around}.notif[data-v-66323fd4]{position:absolute;top:0;left:5px;z-index:10;pointer-events:none;user-select:none;color:var(--accent3);font-size:x-large;animation:1s linear infinite bounce-66323fd4;border-radius:var(--border-radius);background:var(--locked)}@keyframes bounce-66323fd4{0%{animation-timing-function:cubic-bezier(.1361,.2514,.2175,.8786);transform:translate(0) scaleY(1)}37%{animation-timing-function:cubic-bezier(.7674,.1844,.8382,.7157);transform:translateY(-20px) scaleY(1)}72%{animation-timing-function:cubic-bezier(.1118,.2149,.2172,.941);transform:translate(0) scaleY(1)}87%{animation-timing-function:cubic-bezier(.7494,.2259,.8209,.6963);transform:translateY(10px) scaleY(.602)}to{transform:translate(0) scaleY(1)}}.day[data-v-949cc93c]{flex:13% 0 0;position:relative;display:flex;background-color:var(--raised-background);aspect-ratio:1;margin:5%}.door-enter-from[data-v-949cc93c]:before,.door-enter-from[data-v-949cc93c]:after,.door-leave-to[data-v-949cc93c]:before,.door-leave-to[data-v-949cc93c]:after{transform:perspective(150px) rotateY(0)!important}.door-enter-from .date[data-v-949cc93c],.door-leave-to .date[data-v-949cc93c]{transform:translate(-50%,-50%) perspective(150px) rotateY(0)!important}.door-enter-active[data-v-949cc93c]:before,.door-enter-active[data-v-949cc93c]:after,.door-leave-active[data-v-949cc93c]:before,.door-leave-active[data-v-949cc93c]:after{z-index:2}.door-enter-active .date[data-v-949cc93c],.door-leave-active .date[data-v-949cc93c]{z-index:3}.day.opened .doors[data-v-949cc93c]:before,.day.opened .doors[data-v-949cc93c]:after,.day.opened .doors .date[data-v-949cc93c]{transition:1s}.day.opened .doors[data-v-949cc93c]:before{transform-origin:left;transform:perspective(150px) rotateY(-135deg)}.day.opened .doors[data-v-949cc93c]:after{transform-origin:right;transform:perspective(150px) rotateY(135deg)}.day.opened .doors .date[data-v-949cc93c]:first-child{transform-origin:left;transform:translate(-50%,-50%) perspective(150px) rotateY(-135deg);clip-path:polygon(0 0,50% 0,50% 100%,0 100%)}.day.opened .doors .date[data-v-949cc93c]:last-child{transform-origin:right;transform:translate(-50%,-50%) perspective(150px) rotateY(135deg);clip-path:polygon(100% 0,50% 0,50% 100%,100% 100%)}.doors[data-v-949cc93c]{position:absolute;width:100%;height:100%;top:0;left:0}.day.opened .doors[data-v-949cc93c]{cursor:pointer}.doors[data-v-949cc93c]:before,.doors[data-v-949cc93c]:after{content:"";position:absolute;background-color:var(--locked);width:50%;height:100%;pointer-events:none}.doors[data-v-949cc93c]:before{top:0;left:0}.doors[data-v-949cc93c]:after{top:0;right:0}.date[data-v-949cc93c]{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);z-index:2;font-size:large;pointer-events:none;user-select:none;backface-visibility:hidden;width:100%}.icon[data-v-949cc93c]{pointer-events:none;background-size:contain;width:100%;height:100%}.lore[data-v-949cc93c]{position:absolute;top:5px;right:5px;width:20px;height:20px;z-index:1;border-radius:50%;cursor:pointer;background-color:var(--highlighted);user-select:none}.lore[data-v-949cc93c]:hover{box-shadow:0 0 10px var(--points)}.lock[data-v-949cc93c]{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);opacity:.2;font-size:400%}.feature:not(li),.feature:not(li) button{position:relative;padding:5px;border-radius:var(--border-radius);border:2px solid rgba(0,0,0,.125);margin:var(--feature-margin);box-sizing:border-box;color:var(--feature-foreground);z-index:0;transition:all .5s,z-index 0s .5s}.can,.can button{background-color:var(--layer-color);cursor:pointer}.can:hover,.can:hover button{transform:scale(1.15);box-shadow:0 0 20px var(--points);z-index:1;transition:all .5s,z-index 0s}.locked,.locked button{background-color:var(--locked);cursor:not-allowed}.bought,.bought button{background-color:var(--bought);cursor:default}.mark[data-v-2207999f]{position:absolute;left:-25px;top:-10px;width:30px;height:30px;z-index:1;pointer-events:none;margin-left:.9em;margin-right:.9em;margin-bottom:1.2em;border-right:.3em solid transparent;border-bottom:.7em solid transparent;border-left:.3em solid transparent;font-size:10px}.star[data-v-2207999f]{left:-10px;width:0;height:0;margin-left:.9em;margin-right:.9em;margin-bottom:1.2em;border-right:.3em solid transparent;border-bottom:.7em solid #ffcc00;border-left:.3em solid transparent;font-size:10px;pointer-events:none}.star[data-v-2207999f]:before,.star[data-v-2207999f]:after{content:"";width:0;height:0;position:absolute;top:.6em;left:-1em;border-right:1em solid transparent;border-bottom:.7em solid #ffcc00;border-left:1em solid transparent;transform:rotate(-35deg)}.star[data-v-2207999f]:after{transform:rotate(35deg)}.node[data-v-a48cb382]{position:absolute;top:0;left:0;width:100%;height:100%;pointer-events:none}.clickable[data-v-8cedd7da]{min-height:120px;width:120px;font-size:10px}.clickable.small[data-v-8cedd7da]{min-height:unset}.clickable>*[data-v-8cedd7da]{pointer-events:none}.resize-listener[data-v-063f6d6b]{position:absolute;top:0px;left:0;right:-4px;bottom:5px;z-index:-10;pointer-events:none}svg[data-v-063f6d6b]{position:absolute;top:0;left:0;width:100%;height:100%;z-index:-10;pointer-events:none}.left-side-nodes[data-v-39ca96d0]{position:absolute;left:15px;top:65px}.side-nodes[data-v-39ca96d0]{position:absolute;right:15px;top:65px}.left-side-nodes[data-v-39ca96d0] .treeNode,.side-nodes[data-v-39ca96d0] .treeNode{margin:20px auto}.small[data-v-39ca96d0] .treeNode{height:60px;width:60px}.small[data-v-39ca96d0] .treeNode>*:first-child{font-size:30px}.treeNode[data-v-1c0c107d]{height:100px;width:100px;border-radius:50%;padding:0;margin:0 10px}.treeNode>*[data-v-1c0c107d]:first-child{width:100%;height:100%;border:2px solid rgba(0,0,0,.125);border-radius:inherit;font-size:40px;color:#00000080;text-shadow:2px 2px 4px rgba(0,0,0,.25);box-shadow:-4px -4px 4px #00000040 inset,0 0 20px var(--background);text-transform:capitalize;display:flex}.treeNode>*:first-child>*[data-v-1c0c107d]{pointer-events:none}.modifier-toggle{padding-right:10px;transform:translateY(-1px);display:inline-block}.modifier-toggle.collapsed{transform:translate(-5px,-5px) rotate(-90deg)}.bar[data-v-02d0d7b2]{position:relative;display:table}.overlayTextContainer[data-v-02d0d7b2]{position:absolute;border-radius:10px;vertical-align:middle;display:flex;justify-content:center;z-index:3}.overlayText[data-v-02d0d7b2]{z-index:6}.border[data-v-02d0d7b2]{border:2px solid;border-radius:10px;border-color:var(--foreground);overflow:hidden;mask-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAIAAACQd1PeAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAA5JREFUeNpiYGBgAAgwAAAEAAGbA+oJAAAAAElFTkSuQmCC);margin:0}.fill[data-v-02d0d7b2]{position:absolute;background-color:var(--foreground);overflow:hidden;margin-left:-.5px;transition-duration:.2s;z-index:2}.sticky[data-v-cccac690]{position:sticky;background:var(--background);width:calc(100% - 2px);z-index:3}.main-display-container{vertical-align:middle;margin-bottom:20px;display:flex;transition-duration:0s}.upgrade[data-v-7f411ac8]{min-height:120px;width:120px;font-size:10px}.upgrade>*[data-v-7f411ac8]{pointer-events:none}.modifier-container{display:flex}.modifier-container:nth-child(2n){background:var(--raised-background)}.modifier-amount{flex-basis:100px;flex-shrink:0}.modifier-description{flex-grow:1}.field{display:flex;position:relative;min-height:2em;margin:10px 0;user-select:none;justify-content:space-between;align-items:center}.field>*{margin:0}.vue-select{width:50%;border-radius:var(--border-radius)}.field-buttons .vue-select{width:unset}.vue-select,.vue-dropdown{border-color:var(--outline)}.vue-dropdown{background:var(--raised-background)}.vue-dropdown-item{color:var(--foreground)}.vue-dropdown-item,.vue-dropdown-item *{transition-duration:0s}.vue-dropdown-item.highlighted{background-color:var(--highlighted)}.vue-dropdown-item.selected,.vue-dropdown-item.highlighted.selected{background-color:var(--bought)}.vue-input input::placeholder{color:var(--link)}.milestone[data-v-f4e8794e]{width:calc(100% - 10px);min-width:120px;padding-left:5px;padding-right:5px;background-color:var(--locked);border-width:4px;border-radius:5px;color:#00000080}.milestone.done[data-v-f4e8794e]{background-color:var(--bought);cursor:default}.milestone[data-v-f4e8794e] .equal-spaced{display:flex;justify-content:center}.milestone[data-v-f4e8794e] .equal-spaced>*{margin:auto}.scene[data-v-080e23dc]{width:600px;height:300px;position:relative}.scene[data-v-080e23dc]:after{content:"";position:absolute;width:100%;height:20%;border-radius:50% 50% 0 0/100% 100% 0 0;bottom:0;background:white}.scene-item[data-v-080e23dc]{width:80px;height:80px;position:absolute;z-index:1}.layer-container[data-v-0158bec3]{min-width:100%;min-height:100%;margin:0;flex-grow:1;display:flex;isolation:isolate}.layer-tab[data-v-0158bec3]:not(.minimized){padding-top:20px;padding-bottom:20px;min-height:100%;flex-grow:1;text-align:center;position:relative}.inner-tab>.layer-container>.layer-tab[data-v-0158bec3]:not(.minimized){padding-top:50px}.layer-tab.minimized[data-v-0158bec3]{position:absolute;top:0;left:0;right:0;bottom:0;display:flex;padding:55px 0 0;margin:0;cursor:pointer;font-size:40px;color:var(--foreground);border:none;background-color:transparent}.layer-tab.minimized div[data-v-0158bec3]{margin:0;writing-mode:vertical-rl;padding-left:10px;width:50px}.inner-tab>.layer-container>.layer-tab[data-v-0158bec3]:not(.minimized){margin:-50px -10px;padding:50px 10px}.modal-body .layer-tab[data-v-0158bec3]{padding-bottom:0}.modal-body .layer-tab[data-v-0158bec3]:not(.hasSubtabs){padding-top:0}.minimize[data-v-0158bec3]{position:sticky;top:6px;right:9px;z-index:7;line-height:30px;border:none;background:var(--background);box-shadow:var(--background) 0 2px 3px 5px;border-radius:50%;color:var(--foreground);font-size:40px;cursor:pointer;margin-top:-44px;margin-right:-30px}.minimized+.minimize[data-v-0158bec3]{transform:rotate(-90deg);top:10px;right:18px;pointer-events:none}.goBack[data-v-0158bec3]{position:sticky;top:10px;left:10px;line-height:30px;margin-top:-50px;margin-left:-35px;border:none;background:var(--background);box-shadow:var(--background) 0 2px 3px 5px;border-radius:50%;color:var(--foreground);font-size:30px;cursor:pointer;z-index:7}.goBack[data-v-0158bec3]:hover{transform:scale(1.1);text-shadow:0 0 7px var(--foreground)}details[data-v-4b4bda40]{margin:10px 0;padding-left:18px}summary[data-v-4b4bda40]{cursor:pointer;margin-bottom:10px;margin-left:-18px}ul[data-v-4b4bda40]{margin:var(--feature-margin) 0;background:var(--raised-background);border:2px solid rgba(0,0,0,.125);padding:5px 5px 5px 15px;list-style:inside}li[data-v-4b4bda40]{margin:8px 0}li[data-v-4b4bda40]:before{padding:2px 8px;margin-right:8px;border-radius:var(--border-radius)}.feature[data-v-4b4bda40]:before{content:"Feature";background:var(--accent1)}.fix[data-v-4b4bda40]:before{content:"Fix";background:var(--accent2)}.balancing[data-v-4b4bda40]:before{content:"Balancing";background:var(--accent3)}.breaking[data-v-4b4bda40]:before{content:"Breaking";background:var(--danger)}.tooltip-container[data-v-6102fa3a]{position:relative;--xoffset: 0px;--yoffset: 0px;text-shadow:none!important}.tooltip[data-v-6102fa3a],.tooltip[data-v-6102fa3a]:after{pointer-events:none;position:absolute}.tooltip[data-v-6102fa3a]{text-align:center;width:150px;font-size:14px;line-height:1.2;bottom:calc(100% + var(--yoffset));left:calc(50% + var(--xoffset));margin-bottom:5px;transform:translate(-50%);padding:7px;border-radius:3px;background-color:var(--tooltip-background);color:var(--points);z-index:100!important;word-break:break-word}.tooltip[data-v-6102fa3a] hr{margin:var(--feature-margin) 0}.shown[data-v-6102fa3a]{z-index:10}.fade-enter-from[data-v-6102fa3a],.fade-leave-to[data-v-6102fa3a]{opacity:0}.tooltip[data-v-6102fa3a]:after{content:" ";position:absolute;top:100%;bottom:100%;left:calc(50% - var(--xoffset));width:0;margin-left:-5px;border-width:5px;border-style:solid;border-color:var(--tooltip-background) transparent transparent transparent}.tooltip.left[data-v-6102fa3a],.side-nodes .tooltip[data-v-6102fa3a]:not(.right):not(.bottom):not(.top){bottom:calc(50% + var(--yoffset));left:unset;right:calc(100% + var(--xoffset));margin-bottom:unset;margin-right:5px;transform:translateY(50%)}.tooltip.left[data-v-6102fa3a]:after,.side-nodes .tooltip[data-v-6102fa3a]:not(.right):not(.bottom):not(.top):after{top:calc(50% + var(--yoffset));bottom:unset;left:100%;right:100%;margin-left:unset;margin-top:-5px;border-color:transparent transparent transparent var(--tooltip-background)}.tooltip.right[data-v-6102fa3a]{bottom:calc(50% + var(--yoffset));left:calc(100% + var(--xoffset));margin-bottom:unset;margin-left:5px;transform:translateY(50%)}.tooltip.right[data-v-6102fa3a]:after{top:calc(50% + var(--yoffset));left:0;right:100%;margin-left:-10px;margin-top:-5px;border-color:transparent var(--tooltip-background) transparent transparent}.tooltip.bottom[data-v-6102fa3a]{top:calc(100% + var(--yoffset));bottom:unset;left:calc(50% + var(--xoffset));margin-bottom:unset;margin-top:5px;transform:translate(-50%)}.tooltip.bottom[data-v-6102fa3a]:after{top:0;margin-top:-10px;border-color:transparent transparent var(--tooltip-background) transparent}.pinned[data-v-6102fa3a]{position:absolute;right:-5px;top:-5px;transform:rotate(45deg)}.info-modal-header{display:flex;margin:-20px -20px 0;background:var(--raised-background);align-items:center}.info-modal-header *{margin:0}.info-modal-logo{height:4em;width:4em}.info-modal-title{display:flex;flex-direction:column;padding:10px 0;margin-left:10px}.info-modal-discord-link{display:flex;align-items:center}.info-modal-discord{margin:0 4px 0 0}.field[data-v-2b109500]{cursor:pointer}input[data-v-2b109500]{appearance:none;pointer-events:none}span[data-v-2b109500]{width:100%;position:relative}input+span[data-v-2b109500]:before{content:"";float:right;margin:5px 0 5px 10px;border-radius:7px;width:36px;height:14px;background-color:var(--outline);opacity:.38;vertical-align:top;transition:background-color .2s,opacity .2s}input+span[data-v-2b109500]:after{content:"";position:absolute;top:2px;right:16px;border-radius:50%;width:20px;height:20px;background-color:var(--locked);box-shadow:0 3px 1px -2px #0003,0 2px 2px #00000024,0 1px 5px #0000001f;transition:background-color .2s,transform .2s}input:checked+span[data-v-2b109500]:before{background-color:var(--link);opacity:.6}input:checked+span[data-v-2b109500]:after{background-color:var(--link);transform:translate(16px)}input:active+span[data-v-2b109500]:before{background-color:var(--link);opacity:.6}input:checked:active+span[data-v-2b109500]:before{background-color:var(--outline);opacity:.38}input:disabled+span[data-v-2b109500]{color:#000;opacity:.38;cursor:default}input:disabled+span[data-v-2b109500]:before{background-color:var(--outline);opacity:.38}input:checked:disabled+span[data-v-2b109500]:before{background-color:var(--link);opacity:.6}.header[data-v-1975661c]{margin-bottom:-10px}*[data-v-1975661c] .tooltip-container{display:inline;margin-left:5px}form[data-v-67b44a54]{margin:0;width:100%}.field>*[data-v-67b44a54]{margin:0}input[data-v-67b44a54]{width:50%;outline:none;border:solid 1px var(--outline);background-color:unset;border-radius:var(--border-radius)}.fullWidth[data-v-67b44a54]{width:100%}.container[data-v-2f8ef34c]{display:flex;align-items:center;background:var(--raised-background);box-shadow:var(--raised-background) 0 2px 3px 5px}.container.confirming button[data-v-2f8ef34c]{font-size:1em}.container>*[data-v-2f8ef34c]{margin:0 4px}.danger,.button.danger{position:relative;border:solid 2px var(--danger);border-right-width:16px}.danger:after{position:absolute;content:"!";color:#fff;right:-13px}.feedback[data-v-01a1b95c]{position:relative}.feedback[data-v-01a1b95c]:after{position:absolute;left:calc(100% + 5px);top:50%;transform:translateY(-50%);content:"\2714";opacity:0;pointer-events:none;box-shadow:inset 0 0 0 35px #6f94b600;text-shadow:none}.feedback.left[data-v-01a1b95c]:after{left:unset;right:calc(100% + 5px)}.feedback.activated[data-v-01a1b95c]:after{animation:feedback-01a1b95c .5s ease-out forwards}@keyframes feedback-01a1b95c{0%{opacity:1;transform:scale3d(.4,.4,1),translateY(-50%)}80%{opacity:.1}to{opacity:0;transform:scale3d(1.2,1.2,1),translateY(-50%)}}.save[data-v-5285ac49]{position:relative;border:solid 4px var(--outline);padding:4px;background:var(--raised-background);margin:var(--feature-margin);display:flex;align-items:center;min-height:30px}.save.active[data-v-5285ac49]{border-color:var(--bought)}.open[data-v-5285ac49]{display:inline;margin:0;padding-left:0}.handle[data-v-5285ac49]{flex-grow:0;margin-right:8px;margin-left:0;cursor:pointer}.details[data-v-5285ac49]{margin:0 80px 0 0;flex-grow:1}.error[data-v-5285ac49]{font-size:.8em;color:var(--danger)}.save-version[data-v-5285ac49]{margin-left:4px;font-size:.7em;opacity:.7}.actions[data-v-5285ac49]{position:absolute;top:0;bottom:0;right:4px;display:flex;padding:4px;z-index:1}.editname[data-v-5285ac49]{margin:0}.save button{transition-duration:0s}.save .actions button{display:flex;font-size:1.2em}.save .actions button .material-icons{font-size:unset}.save .button.danger{display:flex;align-items:center;padding:4px}.save .field,.field form[data-v-3b9991aa],.field .field-title[data-v-3b9991aa],.field .field-buttons[data-v-3b9991aa]{margin:0}.field-buttons[data-v-3b9991aa]{display:flex}.field-buttons .field[data-v-3b9991aa]{margin:0 0 0 8px}.modal-footer[data-v-3b9991aa]{margin-top:-20px}.footer[data-v-3b9991aa]{display:flex;margin-top:20px}.importingFailed input{color:red}.field-buttons .v-select{width:220px}.presets .vue-select[aria-expanded=true] vue-dropdown{visibility:hidden}.nav[data-v-4a3f8425]{background-color:var(--raised-background);display:flex;left:0;right:0;top:0;height:46px;width:100%;border-bottom:4px solid var(--outline)}.nav>*[data-v-4a3f8425]{height:46px;width:46px;display:flex;cursor:pointer;flex-shrink:0}.nav>.banner[data-v-4a3f8425]{height:100%;width:unset}.overlay-nav[data-v-4a3f8425]{position:fixed;top:10px;left:10px;display:flex;flex-direction:column;z-index:2}.overlay-nav>*[data-v-4a3f8425]{height:50px;width:50px;display:flex;cursor:pointer;margin:0;align-items:center;justify-content:center}.title[data-v-4a3f8425]{font-size:36px;text-align:left;margin-left:12px;cursor:unset}.nav>.title[data-v-4a3f8425]{width:unset;flex-shrink:1;overflow:hidden;white-space:nowrap}.nav .saves[data-v-4a3f8425],.nav .info[data-v-4a3f8425]{display:flex}.tooltip-container[data-v-4a3f8425]{width:100%;height:100%;display:flex}.overlay-nav .discord[data-v-4a3f8425]{position:relative}.discord img[data-v-4a3f8425]{width:100%;height:100%}.discord-links[data-v-4a3f8425]{position:fixed;top:45px;padding:20px;right:-280px;width:200px;transition:right .25s ease;background:var(--raised-background);z-index:10}.overlay-nav .discord-links[data-v-4a3f8425]{position:absolute;left:-280px;right:unset;transition:left .25s ease}.overlay-nav .discord:hover .discord-links[data-v-4a3f8425]{left:-10px}.discord-links li[data-v-4a3f8425]{margin-bottom:4px}.discord-links li[data-v-4a3f8425]:first-child{font-size:1.2em}*:not(.overlay-nav) .discord:hover .discord-links[data-v-4a3f8425]{right:0}.material-icons[data-v-4a3f8425]{font-size:36px}.material-icons[data-v-4a3f8425]:hover{text-shadow:5px 0 10px var(--link),-3px 0 12px var(--foreground)}.nav .version-container[data-v-4a3f8425]{display:flex;height:25px;margin-bottom:0;margin-left:10px}.overlay-nav .version-container[data-v-4a3f8425]{width:unset;height:25px}.version[data-v-4a3f8425]{color:var(--points)}.version:hover span[data-v-4a3f8425]{text-shadow:5px 0 10px var(--points),-3px 0 12px var(--points)}.nav>div>a[data-v-4a3f8425],.overlay-nav>div>a[data-v-4a3f8425]{color:var(--foreground);text-shadow:none}.tabs-container[data-v-6f125a90]{width:100vw;flex-grow:1;overflow-x:auto;overflow-y:hidden;display:flex}.tabs-container[data-v-6f125a90]:not(.useHeader){width:calc(100vw - 50px);margin-left:50px}.tab[data-v-6f125a90]{position:relative;height:100%;flex-grow:1;transition-duration:0s;overflow-y:auto;overflow-x:hidden}.inner-tab[data-v-6f125a90]{padding:50px 10px;min-height:calc(100% - 100px);display:flex;flex-direction:column;margin:0;flex-grow:1}.tab+.tab>.inner-tab[data-v-6f125a90]{border-left:solid 4px var(--outline)}.tab hr{height:4px;border:none;background:var(--outline);margin:var(--feature-margin) 0}.tab .modal-body hr{margin:7px 0}.game-over-modal-header[data-v-4a50ce42]{display:flex;margin:-20px -20px 0;background:var(--raised-background);align-items:center}.game-over-modal-header *[data-v-4a50ce42]{margin:0}.game-over-modal-logo[data-v-4a50ce42]{height:4em;width:4em}.game-over-modal-title[data-v-4a50ce42]{display:flex;flex-direction:column;padding:10px 0;margin-left:10px}.game-over-footer[data-v-4a50ce42]{display:flex;justify-content:flex-end}.game-over-footer button[data-v-4a50ce42]{margin:0 10px}.game-over-modal-discord-link[data-v-4a50ce42]{display:flex;align-items:center}.game-over-modal-discord[data-v-4a50ce42]{margin:0 4px 0 0}.nan-modal-header[data-v-3de07c06]{padding:10px 0;margin-left:10px}.nan-footer[data-v-3de07c06]{display:flex;justify-content:flex-end}.nan-footer button[data-v-3de07c06]{margin:0 10px}.nan-modal-discord-link[data-v-3de07c06]{display:flex;align-items:center}.nan-modal-discord[data-v-3de07c06]{margin:0 4px 0 0}.tpsDisplay[data-v-46a3ed5b]{position:absolute;left:10px;bottom:10px;z-index:100}.low[data-v-46a3ed5b]{color:var(--danger)}.fade-leave-to[data-v-46a3ed5b]{opacity:0}:root{color-scheme:dark}*{transition-duration:.5s;font-family:Roboto Mono,monospace;font-weight:700;margin:auto;text-size-adjust:none}*:focus{outline:none}body{overflow:hidden;transition:none;text-align:center}html,body,#app{min-height:100%;height:100%}h1,h2,h3,b,input{display:inline}button{color:#000}a,.button,.link{display:block;color:var(--link);background:none;border:none;cursor:pointer;text-decoration:none}a:hover,.button:hover,.link:hover{text-shadow:5px 0 10px var(--link),-3px 0 12px var(--link)}.button:disabled{opacity:.5;cursor:not-allowed}.button:disabled:hover{text-shadow:none}ul{list-style-type:none}.Vue-Toastification__toast{margin:unset}.app[data-v-7c41425b]{background-color:var(--background);color:var(--foreground);display:flex;flex-flow:column;min-height:100%;height:100%}#modal-root[data-v-7c41425b]{position:absolute;min-height:100%;height:100%} diff --git a/assets/index.f137628e.css b/assets/index.f137628e.css deleted file mode 100644 index 246d506..0000000 --- a/assets/index.f137628e.css +++ /dev/null @@ -1 +0,0 @@ -.table{display:flex;flex-flow:column wrap;justify-content:center;align-items:center;max-width:100%;margin:0 auto}.table+.table{margin-top:10px}.row{display:flex;flex-flow:row wrap;justify-content:center;align-items:stretch;max-width:100%;margin:0 10px}.row>:not(.feature){margin:0;display:flex}.col{display:flex;flex-flow:column wrap;justify-content:center;align-items:center;height:100%;margin:10px 0}.row.mergeAdjacent>.feature:not(.dontMerge),.row.mergeAdjacent>.tooltip-container>.feature:not(.dontMerge){margin-left:0;margin-right:0;border-radius:0}.row.mergeAdjacent>.feature:not(.dontMerge):first-child,.row.mergeAdjacent>.tooltip-container:first-child>.feature:not(.dontMerge){border-radius:var(--border-radius) 0 0 var(--border-radius)}.row.mergeAdjacent>.feature:not(.dontMerge):last-child,.row.mergeAdjacent>.tooltip-container:last-child>.feature:not(.dontMerge){border-radius:0 var(--border-radius) var(--border-radius) 0}.row.mergeAdjacent>.feature:not(.dontMerge):first-child:last-child,.row.mergeAdjacent>.tooltip-container:first-child:last-child>.feature:not(.dontMerge){border-radius:var(--border-radius)}.col.mergeAdjacent .feature:not(.dontMerge){margin-top:0;margin-bottom:0;border-radius:0}.col.mergeAdjacent .feature:not(.dontMerge):first-child{border-radius:var(--border-radius) var(--border-radius) 0 0}.col.mergeAdjacent .feature:not(.dontMerge):last-child{border-radius:0 0 var(--border-radius) var(--border-radius)}.col.mergeAdjacent .feature:not(.dontMerge):first-child:last-child{border-radius:var(--border-radius)}.resize-listener[data-v-2b1dc1bc]{position:absolute;top:0px;left:0;right:-4px;bottom:5px;z-index:-10;pointer-events:none}.modal-mask{position:fixed;z-index:9998;top:0;left:0;bottom:0;right:0;background-color:#00000080;transition:opacity .3s ease}.modal-wrapper{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%)}.modal-container{width:640px;max-width:95vw;max-height:95vh;background-color:var(--background);padding:20px;border-radius:5px;transition:all .3s ease;text-align:left;border:var(--modal-border);box-sizing:border-box;display:flex;flex-direction:column}.modal-header{width:100%}.modal-body{margin:20px 0;width:100%;overflow-y:auto;overflow-x:hidden}.modal-footer{width:100%}.modal-default-footer{display:flex}.modal-default-flex-grow{flex-grow:1}.modal-enter-from,.modal-leave-active{opacity:0}.modal-enter-from .modal-container,.modal-leave-active .modal-container{-webkit-transform:scale(1.1);transform:scale(1.1)}.advent{width:80%;max-width:700px;background:url(./adventCalendarGameJamCalandar.0fdeb6b8.png);background-size:contain;display:flex;flex-direction:column;padding-top:28%;padding-left:10%;padding-right:10%;background-repeat:no-repeat;aspect-ratio:3151 / 4190}.advent>.table{width:100%}.advent>.table>.row{width:100%;margin:0 0 -5%;justify-content:space-around}.notif[data-v-66323fd4]{position:absolute;top:0;left:5px;z-index:10;pointer-events:none;user-select:none;color:var(--accent3);font-size:x-large;animation:1s linear infinite bounce-66323fd4;border-radius:var(--border-radius);background:var(--locked)}@keyframes bounce-66323fd4{0%{animation-timing-function:cubic-bezier(.1361,.2514,.2175,.8786);transform:translate(0) scaleY(1)}37%{animation-timing-function:cubic-bezier(.7674,.1844,.8382,.7157);transform:translateY(-20px) scaleY(1)}72%{animation-timing-function:cubic-bezier(.1118,.2149,.2172,.941);transform:translate(0) scaleY(1)}87%{animation-timing-function:cubic-bezier(.7494,.2259,.8209,.6963);transform:translateY(10px) scaleY(.602)}to{transform:translate(0) scaleY(1)}}.day[data-v-949cc93c]{flex:13% 0 0;position:relative;display:flex;background-color:var(--raised-background);aspect-ratio:1;margin:5%}.door-enter-from[data-v-949cc93c]:before,.door-enter-from[data-v-949cc93c]:after,.door-leave-to[data-v-949cc93c]:before,.door-leave-to[data-v-949cc93c]:after{transform:perspective(150px) rotateY(0)!important}.door-enter-from .date[data-v-949cc93c],.door-leave-to .date[data-v-949cc93c]{transform:translate(-50%,-50%) perspective(150px) rotateY(0)!important}.door-enter-active[data-v-949cc93c]:before,.door-enter-active[data-v-949cc93c]:after,.door-leave-active[data-v-949cc93c]:before,.door-leave-active[data-v-949cc93c]:after{z-index:2}.door-enter-active .date[data-v-949cc93c],.door-leave-active .date[data-v-949cc93c]{z-index:3}.day.opened .doors[data-v-949cc93c]:before,.day.opened .doors[data-v-949cc93c]:after,.day.opened .doors .date[data-v-949cc93c]{transition:1s}.day.opened .doors[data-v-949cc93c]:before{transform-origin:left;transform:perspective(150px) rotateY(-135deg)}.day.opened .doors[data-v-949cc93c]:after{transform-origin:right;transform:perspective(150px) rotateY(135deg)}.day.opened .doors .date[data-v-949cc93c]:first-child{transform-origin:left;transform:translate(-50%,-50%) perspective(150px) rotateY(-135deg);clip-path:polygon(0 0,50% 0,50% 100%,0 100%)}.day.opened .doors .date[data-v-949cc93c]:last-child{transform-origin:right;transform:translate(-50%,-50%) perspective(150px) rotateY(135deg);clip-path:polygon(100% 0,50% 0,50% 100%,100% 100%)}.doors[data-v-949cc93c]{position:absolute;width:100%;height:100%;top:0;left:0}.day.opened .doors[data-v-949cc93c]{cursor:pointer}.doors[data-v-949cc93c]:before,.doors[data-v-949cc93c]:after{content:"";position:absolute;background-color:var(--locked);width:50%;height:100%;pointer-events:none}.doors[data-v-949cc93c]:before{top:0;left:0}.doors[data-v-949cc93c]:after{top:0;right:0}.date[data-v-949cc93c]{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);z-index:2;font-size:large;pointer-events:none;user-select:none;backface-visibility:hidden;width:100%}.icon[data-v-949cc93c]{pointer-events:none;background-size:contain;width:100%;height:100%}.lore[data-v-949cc93c]{position:absolute;top:5px;right:5px;width:20px;height:20px;z-index:1;border-radius:50%;cursor:pointer;background-color:var(--highlighted);user-select:none}.lore[data-v-949cc93c]:hover{box-shadow:0 0 10px var(--points)}.lock[data-v-949cc93c]{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);opacity:.2;font-size:400%}.feature:not(li),.feature:not(li) button{position:relative;padding:5px;border-radius:var(--border-radius);border:2px solid rgba(0,0,0,.125);margin:var(--feature-margin);box-sizing:border-box;color:var(--feature-foreground);z-index:0;transition:all .5s,z-index 0s .5s}.can,.can button{background-color:var(--layer-color);cursor:pointer}.can:hover,.can:hover button{transform:scale(1.15);box-shadow:0 0 20px var(--points);z-index:1;transition:all .5s,z-index 0s}.locked,.locked button{background-color:var(--locked);cursor:not-allowed}.bought,.bought button{background-color:var(--bought);cursor:default}.mark[data-v-2207999f]{position:absolute;left:-25px;top:-10px;width:30px;height:30px;z-index:1;pointer-events:none;margin-left:.9em;margin-right:.9em;margin-bottom:1.2em;border-right:.3em solid transparent;border-bottom:.7em solid transparent;border-left:.3em solid transparent;font-size:10px}.star[data-v-2207999f]{left:-10px;width:0;height:0;margin-left:.9em;margin-right:.9em;margin-bottom:1.2em;border-right:.3em solid transparent;border-bottom:.7em solid #ffcc00;border-left:.3em solid transparent;font-size:10px;pointer-events:none}.star[data-v-2207999f]:before,.star[data-v-2207999f]:after{content:"";width:0;height:0;position:absolute;top:.6em;left:-1em;border-right:1em solid transparent;border-bottom:.7em solid #ffcc00;border-left:1em solid transparent;transform:rotate(-35deg)}.star[data-v-2207999f]:after{transform:rotate(35deg)}.node[data-v-a48cb382]{position:absolute;top:0;left:0;width:100%;height:100%;pointer-events:none}.clickable[data-v-8cedd7da]{min-height:120px;width:120px;font-size:10px}.clickable.small[data-v-8cedd7da]{min-height:unset}.clickable>*[data-v-8cedd7da]{pointer-events:none}.resize-listener[data-v-063f6d6b]{position:absolute;top:0px;left:0;right:-4px;bottom:5px;z-index:-10;pointer-events:none}svg[data-v-063f6d6b]{position:absolute;top:0;left:0;width:100%;height:100%;z-index:-10;pointer-events:none}.left-side-nodes[data-v-39ca96d0]{position:absolute;left:15px;top:65px}.side-nodes[data-v-39ca96d0]{position:absolute;right:15px;top:65px}.left-side-nodes[data-v-39ca96d0] .treeNode,.side-nodes[data-v-39ca96d0] .treeNode{margin:20px auto}.small[data-v-39ca96d0] .treeNode{height:60px;width:60px}.small[data-v-39ca96d0] .treeNode>*:first-child{font-size:30px}.treeNode[data-v-1c0c107d]{height:100px;width:100px;border-radius:50%;padding:0;margin:0 10px}.treeNode>*[data-v-1c0c107d]:first-child{width:100%;height:100%;border:2px solid rgba(0,0,0,.125);border-radius:inherit;font-size:40px;color:#00000080;text-shadow:2px 2px 4px rgba(0,0,0,.25);box-shadow:-4px -4px 4px #00000040 inset,0 0 20px var(--background);text-transform:capitalize;display:flex}.treeNode>*:first-child>*[data-v-1c0c107d]{pointer-events:none}.modifier-toggle{padding-right:10px;transform:translateY(-1px);display:inline-block}.modifier-toggle.collapsed{transform:translate(-5px,-5px) rotate(-90deg)}.bar[data-v-02d0d7b2]{position:relative;display:table}.overlayTextContainer[data-v-02d0d7b2]{position:absolute;border-radius:10px;vertical-align:middle;display:flex;justify-content:center;z-index:3}.overlayText[data-v-02d0d7b2]{z-index:6}.border[data-v-02d0d7b2]{border:2px solid;border-radius:10px;border-color:var(--foreground);overflow:hidden;mask-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAIAAACQd1PeAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAA5JREFUeNpiYGBgAAgwAAAEAAGbA+oJAAAAAElFTkSuQmCC);margin:0}.fill[data-v-02d0d7b2]{position:absolute;background-color:var(--foreground);overflow:hidden;margin-left:-.5px;transition-duration:.2s;z-index:2}.sticky[data-v-cccac690]{position:sticky;background:var(--background);width:calc(100% - 2px);z-index:3}.main-display-container{vertical-align:middle;margin-bottom:20px;display:flex;transition-duration:0s}.upgrade[data-v-7f411ac8]{min-height:120px;width:120px;font-size:10px}.upgrade>*[data-v-7f411ac8]{pointer-events:none}.modifier-container{display:flex}.modifier-container:nth-child(2n){background:var(--raised-background)}.modifier-amount{flex-basis:100px;flex-shrink:0}.modifier-description{flex-grow:1}.field{display:flex;position:relative;min-height:2em;margin:10px 0;user-select:none;justify-content:space-between;align-items:center}.field>*{margin:0}.vue-select{width:50%;border-radius:var(--border-radius)}.field-buttons .vue-select{width:unset}.vue-select,.vue-dropdown{border-color:var(--outline)}.vue-dropdown{background:var(--raised-background)}.vue-dropdown-item{color:var(--foreground)}.vue-dropdown-item,.vue-dropdown-item *{transition-duration:0s}.vue-dropdown-item.highlighted{background-color:var(--highlighted)}.vue-dropdown-item.selected,.vue-dropdown-item.highlighted.selected{background-color:var(--bought)}.vue-input input::placeholder{color:var(--link)}.milestone[data-v-f4e8794e]{width:calc(100% - 10px);min-width:120px;padding-left:5px;padding-right:5px;background-color:var(--locked);border-width:4px;border-radius:5px;color:#00000080}.milestone.done[data-v-f4e8794e]{background-color:var(--bought);cursor:default}.milestone[data-v-f4e8794e] .equal-spaced{display:flex;justify-content:center}.milestone[data-v-f4e8794e] .equal-spaced>*{margin:auto}.layer-container[data-v-0158bec3]{min-width:100%;min-height:100%;margin:0;flex-grow:1;display:flex;isolation:isolate}.layer-tab[data-v-0158bec3]:not(.minimized){padding-top:20px;padding-bottom:20px;min-height:100%;flex-grow:1;text-align:center;position:relative}.inner-tab>.layer-container>.layer-tab[data-v-0158bec3]:not(.minimized){padding-top:50px}.layer-tab.minimized[data-v-0158bec3]{position:absolute;top:0;left:0;right:0;bottom:0;display:flex;padding:55px 0 0;margin:0;cursor:pointer;font-size:40px;color:var(--foreground);border:none;background-color:transparent}.layer-tab.minimized div[data-v-0158bec3]{margin:0;writing-mode:vertical-rl;padding-left:10px;width:50px}.inner-tab>.layer-container>.layer-tab[data-v-0158bec3]:not(.minimized){margin:-50px -10px;padding:50px 10px}.modal-body .layer-tab[data-v-0158bec3]{padding-bottom:0}.modal-body .layer-tab[data-v-0158bec3]:not(.hasSubtabs){padding-top:0}.minimize[data-v-0158bec3]{position:sticky;top:6px;right:9px;z-index:7;line-height:30px;border:none;background:var(--background);box-shadow:var(--background) 0 2px 3px 5px;border-radius:50%;color:var(--foreground);font-size:40px;cursor:pointer;margin-top:-44px;margin-right:-30px}.minimized+.minimize[data-v-0158bec3]{transform:rotate(-90deg);top:10px;right:18px;pointer-events:none}.goBack[data-v-0158bec3]{position:sticky;top:10px;left:10px;line-height:30px;margin-top:-50px;margin-left:-35px;border:none;background:var(--background);box-shadow:var(--background) 0 2px 3px 5px;border-radius:50%;color:var(--foreground);font-size:30px;cursor:pointer;z-index:7}.goBack[data-v-0158bec3]:hover{transform:scale(1.1);text-shadow:0 0 7px var(--foreground)}details[data-v-4b4bda40]{margin:10px 0;padding-left:18px}summary[data-v-4b4bda40]{cursor:pointer;margin-bottom:10px;margin-left:-18px}ul[data-v-4b4bda40]{margin:var(--feature-margin) 0;background:var(--raised-background);border:2px solid rgba(0,0,0,.125);padding:5px 5px 5px 15px;list-style:inside}li[data-v-4b4bda40]{margin:8px 0}li[data-v-4b4bda40]:before{padding:2px 8px;margin-right:8px;border-radius:var(--border-radius)}.feature[data-v-4b4bda40]:before{content:"Feature";background:var(--accent1)}.fix[data-v-4b4bda40]:before{content:"Fix";background:var(--accent2)}.balancing[data-v-4b4bda40]:before{content:"Balancing";background:var(--accent3)}.breaking[data-v-4b4bda40]:before{content:"Breaking";background:var(--danger)}.tooltip-container[data-v-6102fa3a]{position:relative;--xoffset: 0px;--yoffset: 0px;text-shadow:none!important}.tooltip[data-v-6102fa3a],.tooltip[data-v-6102fa3a]:after{pointer-events:none;position:absolute}.tooltip[data-v-6102fa3a]{text-align:center;width:150px;font-size:14px;line-height:1.2;bottom:calc(100% + var(--yoffset));left:calc(50% + var(--xoffset));margin-bottom:5px;transform:translate(-50%);padding:7px;border-radius:3px;background-color:var(--tooltip-background);color:var(--points);z-index:100!important;word-break:break-word}.tooltip[data-v-6102fa3a] hr{margin:var(--feature-margin) 0}.shown[data-v-6102fa3a]{z-index:10}.fade-enter-from[data-v-6102fa3a],.fade-leave-to[data-v-6102fa3a]{opacity:0}.tooltip[data-v-6102fa3a]:after{content:" ";position:absolute;top:100%;bottom:100%;left:calc(50% - var(--xoffset));width:0;margin-left:-5px;border-width:5px;border-style:solid;border-color:var(--tooltip-background) transparent transparent transparent}.tooltip.left[data-v-6102fa3a],.side-nodes .tooltip[data-v-6102fa3a]:not(.right):not(.bottom):not(.top){bottom:calc(50% + var(--yoffset));left:unset;right:calc(100% + var(--xoffset));margin-bottom:unset;margin-right:5px;transform:translateY(50%)}.tooltip.left[data-v-6102fa3a]:after,.side-nodes .tooltip[data-v-6102fa3a]:not(.right):not(.bottom):not(.top):after{top:calc(50% + var(--yoffset));bottom:unset;left:100%;right:100%;margin-left:unset;margin-top:-5px;border-color:transparent transparent transparent var(--tooltip-background)}.tooltip.right[data-v-6102fa3a]{bottom:calc(50% + var(--yoffset));left:calc(100% + var(--xoffset));margin-bottom:unset;margin-left:5px;transform:translateY(50%)}.tooltip.right[data-v-6102fa3a]:after{top:calc(50% + var(--yoffset));left:0;right:100%;margin-left:-10px;margin-top:-5px;border-color:transparent var(--tooltip-background) transparent transparent}.tooltip.bottom[data-v-6102fa3a]{top:calc(100% + var(--yoffset));bottom:unset;left:calc(50% + var(--xoffset));margin-bottom:unset;margin-top:5px;transform:translate(-50%)}.tooltip.bottom[data-v-6102fa3a]:after{top:0;margin-top:-10px;border-color:transparent transparent var(--tooltip-background) transparent}.pinned[data-v-6102fa3a]{position:absolute;right:-5px;top:-5px;transform:rotate(45deg)}.info-modal-header{display:flex;margin:-20px -20px 0;background:var(--raised-background);align-items:center}.info-modal-header *{margin:0}.info-modal-logo{height:4em;width:4em}.info-modal-title{display:flex;flex-direction:column;padding:10px 0;margin-left:10px}.info-modal-discord-link{display:flex;align-items:center}.info-modal-discord{margin:0 4px 0 0}.field[data-v-2b109500]{cursor:pointer}input[data-v-2b109500]{appearance:none;pointer-events:none}span[data-v-2b109500]{width:100%;position:relative}input+span[data-v-2b109500]:before{content:"";float:right;margin:5px 0 5px 10px;border-radius:7px;width:36px;height:14px;background-color:var(--outline);opacity:.38;vertical-align:top;transition:background-color .2s,opacity .2s}input+span[data-v-2b109500]:after{content:"";position:absolute;top:2px;right:16px;border-radius:50%;width:20px;height:20px;background-color:var(--locked);box-shadow:0 3px 1px -2px #0003,0 2px 2px #00000024,0 1px 5px #0000001f;transition:background-color .2s,transform .2s}input:checked+span[data-v-2b109500]:before{background-color:var(--link);opacity:.6}input:checked+span[data-v-2b109500]:after{background-color:var(--link);transform:translate(16px)}input:active+span[data-v-2b109500]:before{background-color:var(--link);opacity:.6}input:checked:active+span[data-v-2b109500]:before{background-color:var(--outline);opacity:.38}input:disabled+span[data-v-2b109500]{color:#000;opacity:.38;cursor:default}input:disabled+span[data-v-2b109500]:before{background-color:var(--outline);opacity:.38}input:checked:disabled+span[data-v-2b109500]:before{background-color:var(--link);opacity:.6}.header[data-v-1975661c]{margin-bottom:-10px}*[data-v-1975661c] .tooltip-container{display:inline;margin-left:5px}form[data-v-67b44a54]{margin:0;width:100%}.field>*[data-v-67b44a54]{margin:0}input[data-v-67b44a54]{width:50%;outline:none;border:solid 1px var(--outline);background-color:unset;border-radius:var(--border-radius)}.fullWidth[data-v-67b44a54]{width:100%}.container[data-v-2f8ef34c]{display:flex;align-items:center;background:var(--raised-background);box-shadow:var(--raised-background) 0 2px 3px 5px}.container.confirming button[data-v-2f8ef34c]{font-size:1em}.container>*[data-v-2f8ef34c]{margin:0 4px}.danger,.button.danger{position:relative;border:solid 2px var(--danger);border-right-width:16px}.danger:after{position:absolute;content:"!";color:#fff;right:-13px}.feedback[data-v-01a1b95c]{position:relative}.feedback[data-v-01a1b95c]:after{position:absolute;left:calc(100% + 5px);top:50%;transform:translateY(-50%);content:"\2714";opacity:0;pointer-events:none;box-shadow:inset 0 0 0 35px #6f94b600;text-shadow:none}.feedback.left[data-v-01a1b95c]:after{left:unset;right:calc(100% + 5px)}.feedback.activated[data-v-01a1b95c]:after{animation:feedback-01a1b95c .5s ease-out forwards}@keyframes feedback-01a1b95c{0%{opacity:1;transform:scale3d(.4,.4,1),translateY(-50%)}80%{opacity:.1}to{opacity:0;transform:scale3d(1.2,1.2,1),translateY(-50%)}}.save[data-v-5285ac49]{position:relative;border:solid 4px var(--outline);padding:4px;background:var(--raised-background);margin:var(--feature-margin);display:flex;align-items:center;min-height:30px}.save.active[data-v-5285ac49]{border-color:var(--bought)}.open[data-v-5285ac49]{display:inline;margin:0;padding-left:0}.handle[data-v-5285ac49]{flex-grow:0;margin-right:8px;margin-left:0;cursor:pointer}.details[data-v-5285ac49]{margin:0 80px 0 0;flex-grow:1}.error[data-v-5285ac49]{font-size:.8em;color:var(--danger)}.save-version[data-v-5285ac49]{margin-left:4px;font-size:.7em;opacity:.7}.actions[data-v-5285ac49]{position:absolute;top:0;bottom:0;right:4px;display:flex;padding:4px;z-index:1}.editname[data-v-5285ac49]{margin:0}.save button{transition-duration:0s}.save .actions button{display:flex;font-size:1.2em}.save .actions button .material-icons{font-size:unset}.save .button.danger{display:flex;align-items:center;padding:4px}.save .field,.field form[data-v-3b9991aa],.field .field-title[data-v-3b9991aa],.field .field-buttons[data-v-3b9991aa]{margin:0}.field-buttons[data-v-3b9991aa]{display:flex}.field-buttons .field[data-v-3b9991aa]{margin:0 0 0 8px}.modal-footer[data-v-3b9991aa]{margin-top:-20px}.footer[data-v-3b9991aa]{display:flex;margin-top:20px}.importingFailed input{color:red}.field-buttons .v-select{width:220px}.presets .vue-select[aria-expanded=true] vue-dropdown{visibility:hidden}.nav[data-v-4a3f8425]{background-color:var(--raised-background);display:flex;left:0;right:0;top:0;height:46px;width:100%;border-bottom:4px solid var(--outline)}.nav>*[data-v-4a3f8425]{height:46px;width:46px;display:flex;cursor:pointer;flex-shrink:0}.nav>.banner[data-v-4a3f8425]{height:100%;width:unset}.overlay-nav[data-v-4a3f8425]{position:fixed;top:10px;left:10px;display:flex;flex-direction:column;z-index:2}.overlay-nav>*[data-v-4a3f8425]{height:50px;width:50px;display:flex;cursor:pointer;margin:0;align-items:center;justify-content:center}.title[data-v-4a3f8425]{font-size:36px;text-align:left;margin-left:12px;cursor:unset}.nav>.title[data-v-4a3f8425]{width:unset;flex-shrink:1;overflow:hidden;white-space:nowrap}.nav .saves[data-v-4a3f8425],.nav .info[data-v-4a3f8425]{display:flex}.tooltip-container[data-v-4a3f8425]{width:100%;height:100%;display:flex}.overlay-nav .discord[data-v-4a3f8425]{position:relative}.discord img[data-v-4a3f8425]{width:100%;height:100%}.discord-links[data-v-4a3f8425]{position:fixed;top:45px;padding:20px;right:-280px;width:200px;transition:right .25s ease;background:var(--raised-background);z-index:10}.overlay-nav .discord-links[data-v-4a3f8425]{position:absolute;left:-280px;right:unset;transition:left .25s ease}.overlay-nav .discord:hover .discord-links[data-v-4a3f8425]{left:-10px}.discord-links li[data-v-4a3f8425]{margin-bottom:4px}.discord-links li[data-v-4a3f8425]:first-child{font-size:1.2em}*:not(.overlay-nav) .discord:hover .discord-links[data-v-4a3f8425]{right:0}.material-icons[data-v-4a3f8425]{font-size:36px}.material-icons[data-v-4a3f8425]:hover{text-shadow:5px 0 10px var(--link),-3px 0 12px var(--foreground)}.nav .version-container[data-v-4a3f8425]{display:flex;height:25px;margin-bottom:0;margin-left:10px}.overlay-nav .version-container[data-v-4a3f8425]{width:unset;height:25px}.version[data-v-4a3f8425]{color:var(--points)}.version:hover span[data-v-4a3f8425]{text-shadow:5px 0 10px var(--points),-3px 0 12px var(--points)}.nav>div>a[data-v-4a3f8425],.overlay-nav>div>a[data-v-4a3f8425]{color:var(--foreground);text-shadow:none}.tabs-container[data-v-62ae8bac]{width:100vw;flex-grow:1;overflow-x:auto;overflow-y:hidden;display:flex}.tabs-container[data-v-62ae8bac]:not(.useHeader){width:calc(100vw - 50px);margin-left:50px}.tab[data-v-62ae8bac]{position:relative;height:100%;flex-grow:1;transition-duration:0s;overflow-y:auto;overflow-x:hidden}.inner-tab[data-v-62ae8bac]{padding:50px 10px;min-height:calc(100% - 100px);display:flex;flex-direction:column;margin:0;flex-grow:1}.tab+.tab>.inner-tab[data-v-62ae8bac]{border-left:solid 4px var(--outline)}.tab hr{height:4px;border:none;background:var(--outline);margin:var(--feature-margin) 0}.tab .modal-body hr{margin:7px 0}.game-over-modal-header[data-v-4a50ce42]{display:flex;margin:-20px -20px 0;background:var(--raised-background);align-items:center}.game-over-modal-header *[data-v-4a50ce42]{margin:0}.game-over-modal-logo[data-v-4a50ce42]{height:4em;width:4em}.game-over-modal-title[data-v-4a50ce42]{display:flex;flex-direction:column;padding:10px 0;margin-left:10px}.game-over-footer[data-v-4a50ce42]{display:flex;justify-content:flex-end}.game-over-footer button[data-v-4a50ce42]{margin:0 10px}.game-over-modal-discord-link[data-v-4a50ce42]{display:flex;align-items:center}.game-over-modal-discord[data-v-4a50ce42]{margin:0 4px 0 0}.nan-modal-header[data-v-3de07c06]{padding:10px 0;margin-left:10px}.nan-footer[data-v-3de07c06]{display:flex;justify-content:flex-end}.nan-footer button[data-v-3de07c06]{margin:0 10px}.nan-modal-discord-link[data-v-3de07c06]{display:flex;align-items:center}.nan-modal-discord[data-v-3de07c06]{margin:0 4px 0 0}.tpsDisplay[data-v-46a3ed5b]{position:absolute;left:10px;bottom:10px;z-index:100}.low[data-v-46a3ed5b]{color:var(--danger)}.fade-leave-to[data-v-46a3ed5b]{opacity:0}:root{color-scheme:dark}*{transition-duration:.5s;font-family:Roboto Mono,monospace;font-weight:700;margin:auto;text-size-adjust:none}*:focus{outline:none}body{overflow:hidden;transition:none;text-align:center}html,body,#app{min-height:100%;height:100%}h1,h2,h3,b,input{display:inline}button{color:#000}a,.button,.link{display:block;color:var(--link);background:none;border:none;cursor:pointer;text-decoration:none}a:hover,.button:hover,.link:hover{text-shadow:5px 0 10px var(--link),-3px 0 12px var(--link)}.button:disabled{opacity:.5;cursor:not-allowed}.button:disabled:hover{text-shadow:none}ul{list-style-type:none}.Vue-Toastification__toast{margin:unset}.app[data-v-7c41425b]{background-color:var(--background);color:var(--foreground);display:flex;flex-flow:column;min-height:100%;height:100%}#modal-root[data-v-7c41425b]{position:absolute;min-height:100%;height:100%} diff --git a/index.html b/index.html index b660892..51411a2 100644 --- a/index.html +++ b/index.html @@ -13,7 +13,7 @@ Advent Incremental - + @@ -27,7 +27,7 @@ - + diff --git a/sw.js b/sw.js index ff34262..c0dbe72 100644 --- a/sw.js +++ b/sw.js @@ -1 +1 @@ -if(!self.define){let e,s={};const i=(i,n)=>(i=new URL(i+".js",n).href,s[i]||new Promise((s=>{if("document"in self){const e=document.createElement("script");e.src=i,e.onload=s,document.head.appendChild(e)}else e=i,importScripts(i),s()})).then((()=>{let e=s[i];if(!e)throw new Error(`Module ${i} didn’t register its module`);return e})));self.define=(n,l)=>{const r=e||("document"in self?document.currentScript.src:"")||location.href;if(s[r])return;let t={};const o=e=>i(e,r),u={module:{uri:r},exports:t,require:o};s[r]=Promise.all(n.map((e=>u[e]||o(e)))).then((e=>(l(...e),t)))}}define(["./workbox-958fa2bd"],(function(e){"use strict";self.addEventListener("message",(e=>{e.data&&"SKIP_WAITING"===e.data.type&&self.skipWaiting()})),e.precacheAndRoute([{url:"assets/@fontsource.f66d05e7.css",revision:null},{url:"assets/@vue.4ce677c2.js",revision:null},{url:"assets/index.32e0a20e.js",revision:null},{url:"assets/index.f137628e.css",revision:null},{url:"assets/is-plain-object.906d88e8.js",revision:null},{url:"assets/lz-string.731cedc5.js",revision:null},{url:"assets/nanoevents.1080beb7.js",revision:null},{url:"assets/sortablejs.29100d8a.js",revision:null},{url:"assets/vue-next-select.9e6f4164.css",revision:null},{url:"assets/vue-next-select.a2bfab1d.js",revision:null},{url:"assets/vue-textarea-autosize.35804eaf.js",revision:null},{url:"assets/vue-toastification.4b5f8ac8.css",revision:null},{url:"assets/vue-toastification.6f567382.js",revision:null},{url:"assets/vue.92681fcb.js",revision:null},{url:"assets/vuedraggable.7949458c.js",revision:null},{url:"assets/workbox-window.8d14e8b7.js",revision:null},{url:"index.html",revision:"48a7254fa4c0a9f186c397aa9958e179"},{url:"favicon.ico",revision:"eead31eb5b19fa3bdc34af83d898c0b7"},{url:"robots.txt",revision:"5e0bd1c281a62a380d7a948085bfe2d1"},{url:"apple-touch-icon.png",revision:"26e53bb981d06c8069ffd9d2a14fce0e"},{url:"pwa-192x192.png",revision:"a16785d9e890858c5b508e0ef6954aaf"},{url:"pwa-512x512.png",revision:"b84004b93fd62ef6599ff179372861a1"},{url:"manifest.webmanifest",revision:"5f32ad2a77eb001e1b6a588835dc1efc"}],{}),e.cleanupOutdatedCaches(),e.registerRoute(new e.NavigationRoute(e.createHandlerBoundToURL("index.html")))})); +if(!self.define){let e,s={};const i=(i,n)=>(i=new URL(i+".js",n).href,s[i]||new Promise((s=>{if("document"in self){const e=document.createElement("script");e.src=i,e.onload=s,document.head.appendChild(e)}else e=i,importScripts(i),s()})).then((()=>{let e=s[i];if(!e)throw new Error(`Module ${i} didn’t register its module`);return e})));self.define=(n,l)=>{const r=e||("document"in self?document.currentScript.src:"")||location.href;if(s[r])return;let t={};const o=e=>i(e,r),u={module:{uri:r},exports:t,require:o};s[r]=Promise.all(n.map((e=>u[e]||o(e)))).then((e=>(l(...e),t)))}}define(["./workbox-958fa2bd"],(function(e){"use strict";self.addEventListener("message",(e=>{e.data&&"SKIP_WAITING"===e.data.type&&self.skipWaiting()})),e.precacheAndRoute([{url:"assets/@fontsource.f66d05e7.css",revision:null},{url:"assets/@vue.4ce677c2.js",revision:null},{url:"assets/index.dd7ca786.js",revision:null},{url:"assets/index.dfc8a303.css",revision:null},{url:"assets/is-plain-object.906d88e8.js",revision:null},{url:"assets/lz-string.731cedc5.js",revision:null},{url:"assets/nanoevents.1080beb7.js",revision:null},{url:"assets/sortablejs.29100d8a.js",revision:null},{url:"assets/vue-next-select.9e6f4164.css",revision:null},{url:"assets/vue-next-select.a2bfab1d.js",revision:null},{url:"assets/vue-textarea-autosize.35804eaf.js",revision:null},{url:"assets/vue-toastification.4b5f8ac8.css",revision:null},{url:"assets/vue-toastification.6f567382.js",revision:null},{url:"assets/vue.92681fcb.js",revision:null},{url:"assets/vuedraggable.7949458c.js",revision:null},{url:"assets/workbox-window.8d14e8b7.js",revision:null},{url:"index.html",revision:"1b291065d44a5d3c08acdcb86501704d"},{url:"favicon.ico",revision:"eead31eb5b19fa3bdc34af83d898c0b7"},{url:"robots.txt",revision:"5e0bd1c281a62a380d7a948085bfe2d1"},{url:"apple-touch-icon.png",revision:"26e53bb981d06c8069ffd9d2a14fce0e"},{url:"pwa-192x192.png",revision:"a16785d9e890858c5b508e0ef6954aaf"},{url:"pwa-512x512.png",revision:"b84004b93fd62ef6599ff179372861a1"},{url:"manifest.webmanifest",revision:"5f32ad2a77eb001e1b6a588835dc1efc"}],{}),e.cleanupOutdatedCaches(),e.registerRoute(new e.NavigationRoute(e.createHandlerBoundToURL("index.html")))}));