/* empty css */import"./vue.92681fcb.js";import{Zasf,lasht,aaasAe,tasV,ayasua,aras_l,aEask,a0asI,aKasQt,a1asg,OasS,aGasZl,AasBt,_asye,a8asi,b6aspe,b8asda,bsassn,Casu,aqasSl,buasLl,bbasca,Tasli,a7ass,uaspa,jasai,bvas_a,qasjl,b1asXt,Gasct,aCasrn,was$t,b2asqt,aoasni,Iasyt,aNasnt,$asG,JasNe,aHasol,aFassl,zasYt,alasla,aLasgl,Hasii,aJasun,bnasoi,brassi,beasri}from"./@vue.4ce677c2.js";import{casdn}from"./nanoevents.1080beb7.js";import{Lasml}from"./lz-string.731cedc5.js";import{iasui}from"./is-plain-object.906d88e8.js";import{Yasdi}from"./vue-next-select.a2bfab1d.js";import{sasci,uascn}from"./vue-toastification.6f567382.js";import{Daspi}from"./vuedraggable.7949458c.js";import{pasmi}from"./vue-textarea-autosize.35804eaf.js";import{vasvi,nasfi}from"./workbox-window.8d14e8b7.js";import"./sortablejs.29100d8a.js";constgi=function(){constt=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(constoofdocument.querySelectorAll('link[rel="modulepreload"]'))n(o);newMutationObserver(o=>{for(constrofo)if(r.type==="childList")for(constdofr.addedNodes)d.tagName==="LINK"&&d.rel==="modulepreload"&&n(d)}).observe(document,{childList:!0,subtree:!0});functionl(o){constr={};returno.integrity&&(r.integrity=o.integrity),o.referrerpolicy&&(r.referrerPolicy=o.referrerpolicy),o.crossorigin==="use-credentials"?r.credentials="include":o.crossorigin==="anonymous"?r.credentials="omit":r.credentials="same-origin",r}functionn(o){if(o.ep)return;o.ep=!0;constr=l(o);fetch(o.href,r)}};gi();consthi="modulepreload",Ha={},yi="./",aa=function(t,l){return!l||l.length===0?t():Promise.all(l.map(n=>{if(n=`${yi}${n}`,ninHa)return;Ha[n]=!0;consto=n.endsWith(".css"),r=o?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${n}"]${r}`))return;constd=document.createElement("link");if(d.rel=o?"stylesheet":hi,o||(d.as="script",d.crossOrigin=""),d.href=n,document.head.appendChild(d),o)returnnewPromise((c,p)=>{d.addEventListener("load",c),d.addEventListener("error",()=>p(newError(`Unable to preload CSS for ${n}`)))})})).then(()=>t())},bi="./projInfo-schema.json",wi="Advent Incremental",Ai="An incremental game you play a day at a time, leading up to Christmas!",Ci="advent-incremental",ki="thepaperpilot and friends",Ei="",_i="",Si="0.5",Bi="Initial Commit",Mi=!0,Ni=!1,xi=2,Ii=!0,Di=null,Pi="",Ti=["main"],Fi=3600,Ui=0,Ri=!0,Oi="base64";varje={$schema:bi,title:wi,description:Ai,id:Ci,author:ki,discordName:Ei,discordLink:_i,versionNumber:Si,versionTitle:Bi,allowGoBack:Mi,defaultShowSmall:Ni,defaultDecimalsShown:xi,useHeader:Ii,banner:Di,logo:Pi,initialTabs:Ti,maxTickLength:Fi,offlineLimit:Ui,enablePausing:Ri,exportEncoding:Oi};constwa=17,qi=9e15,Gi=Math.log10(9e15),Li=1/9e15,Qi=308,$i=-324,ja=5,Vi=function(){conste=[];for(letl=$i+1;l<=Qi;l++)e.push(Number("1e"+l));constt=323;returnfunction(l){returne[l+t]}}(),Cl=[2,Math.E,3,4,5,6,7,8,9,10],Hi=[[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.167090535
`))||""}function Se(e){const t=ht(e)?e:V(e);t[Pa]=t,t[fl]=ht(e)?e.value:e,t[oa]=Bo(),t[_n]=!1;const l=f({get(){return t.value},set(n){t.value=n}});return l[fl]=t[fl],t[$l]=l,t[Gl]=void 0,Wt.length===0?console.warn("Creating a persistent ref outside of a layer. This is not officially supported",t,`
`+p[oa]);return}xl[e.id].delete(p);const m=[e.id,...r,c];p[Gl]!=null&&JSON.stringify(m)!==JSON.stringify(p[Gl])&&console.error(`Persistentrefisbeingsavedto\`${m.join(".")}\` when it's already present at \`${p[Gl].join(".")}\`. This can cause unexpected behavior when loading saves between updates.`,p),p[Gl]=m;constb=r.reduce((A,v)=>(vinA||(A[v]={}),A[v]),t),h=b[c];b[c]=p[Pa],ai(b)?h!=null?b[c]=h:b[c]=p[fl]:h!=null?b[c].value=h:b[c].value=p[fl]}else!(pinstanceofa)&&!ht(p)&&!l.includes(p)&&(typeofp.type=="symbol"&&l.push(p),n(p,[...r,c])&&(_a(p)&&!_a(o)?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.",otino?o[ot]:o,c):d=!0))}),d};n(e[ot]),xl[e.id].forEach(o=>{console.error(`Created persistent ref in ${e.id} without registering it to the layer! Make sure to include everything persistent in the returned object`,o,`
Cost:50${l.displayName}<br/>${Ee(1e11)}${q.coal.displayName}`}})),xe=O(()=>({resource:U(l),cost:1e5,display:{title:"Efficient Drills",description:"Use metal and a bunch of R&D to make drilling stuff faster. Double coal and ore mining speed."},visibility:()=>y(Ze.depthMilestones[4].earned.value)})),Fe=Re(()=>({resource:U(l),cost(){return a.pow(1.15,this.amount.value).times(10)},display:{title:"Mining Drill",description:"An automated machine to help you mine more ore, faster",effectDisplay:B(()=>i(S,null,[s("Mine 2.5x faster. Increase ore mining amount by")," ",we(Fe.amount.value),s(" ore per operation")]))},visibility:()=>y(a.gte(Fe.amount.value,1)||a.div(r.value,c.value).plus(n.value).gte(10)),style:{width:"200px"}})),W=Re(()=>({resource:U(l),cost(){return a.pow(1.15,a.times(this.amount.value,10)).times(10)},display:{title:"Industrial Crucible",description:"A giant automated crucible furnace, letting you smelt ore faster",effectDisplay:B(()=>i(S,null,[s("Automatically smelts")," ",we(a.times(W.amount.value,10)),s(" ore per second")]))},visibility:()=>y(a.gte(W.amount.value,1)||a.gte(Fe.amount.value,4)||a.gte(r.value,50)),style:{width:"200px"}})),ge=Se(!0),oe=Re(()=>({resource:q.coal,cost(){return a.pow(10,this.amount.value).times(1e12)},display:{title:"Hotter Forges",description:"More coal makes the fires burn hotter, getting just a little more metal out of each bit of ore",effectDisplay:B(()=>i(S,null,[s("Gain "),we(a.times(We.value,100)),s("% more metal per ore")]))},visibility:()=>y(a.gte(oe.amount.value,1)||ke.bought.value),style:{width:"200px"}})),We=f(()=>a.times(oe.amount.value,.25));Xe.on("update",he=>{T.value=a.times(he,E.value).plus(T.value);const pt=T.value.trunc();T.value=T.value.minus(pt),o.value=a.add(o.value,a.times(pt,H.value)),ge.value&&N(a.min(v.value,a.times(m.value,he)),h.value)});const[Je,At]=Zt(()=>[{title:"Auto Smelt Speed",modifier:p,base:0,unit:"/s",visible(){return a.gt(W.amount.value,0)}},{title:"Auto Smelt Multiplier",modifier:b,base:1,visible(){return a.gt(h.value,1)}},{title:"Metal per Ore",modifier:d,base:.1},{title:"Ore per Mining Operation",modifier:D,base:1},{title:"Mining Speed",modifier:M,base:.1,unit:"/s"}]),ae=V(!1),ie=B(()=>i(wt,{modelValue:ae.value,"onUpdate:modelValue":he=>ae.value=he},{header:()=>i("h2",null,[e,s(" Modifiers")]),body:Je})),{total:Ue,trackerDisplay:ze}=rl({resource:l,goal:25e3,name:e,day:tn,color:t,modal:{show:ae,display:ie}});return{name:e,day:tn,color:t,ore:o,bestOre:r,oreProgress:T,metal:l,bestMetal:n,totalMetal:Ue,simplePickaxe:Be,doublePickaxe:K,crucible:Ce,coalDrill:Le,industrialFurnace:ke,efficientDrill:xe,oreDrill:Fe,industrialCrucible:W,autoSmeltEnabled:ge,hotterForge:oe,generalTabCollapsed:At,minWidth:700,display:B(()=>i(S,null,[se(ze),i(_e,null,null),i(Tt,{resource:l,color:t,style:"margin-bottom: 0",sticky:!1,productionDisplay:B(()=>i(S,null,[ge.value&&a.gte(W.amount.value,1)?`+${hn([[m.value,"smelting speed"],[me.value,"ore gain"],[a.div(q.computedCoalGain.value,A),"coal gain"]],"/s",a.mul(c.value,h.value))}`:void 0]))},null),i(_e,null,null),se(_),a.gte(W.amount.value,1)?i("div",{style:{width:"150px"}},[i(nl,{title:"Auto Smelt",modelValue:ge.value,"onUpdate:modelValue":he=>ge.value=he},null)]):void 0,i(_e,null,null),i(Tt,{resource:o,color:t,style:"margin-bottom: 0",sticky:!1,productionDisplay:B(()=>i(S,null,[yn(Ge.value)]))},null),i(_e,null,null),i("div",null,[s("Currently mining "),Ee(H.value),s(" ore every")," ",Ee(a.recip(E.value)),s(" seconds")]),se(fe),i(_e,null,null),Ye(Be,K,Ce,Le,ke,xe),Ye(Fe,W,oe)]))}}),hr="coal",ln=3,q=Rt(hr,function(){const e="Coal",t="#151716",l="#B2BeB5",n="var(--foreground)",o=dt(0,"coal"),r=dt(0,"ash"),d=Se(0),c=f(()=>a.times(d.value,1e3)),p=f(()=>a.times(d.value,.1)),m=f(()=>a.times(d.value,50)),b=Re(()=>({resource:ve.logs,cost(){let F=a.times(T.amount.value,u(T.cost)).plus(this.amount.value);return a.gte(F,100)&&(F=a.pow(F,2).div(100)),a.gte(F,1e4)&&(F=a.pow(F,2).div(1e4)),F=a.pow(.95,te.books.smallFireBook.amount.value).times(F),F.pow(1.5).times(1e4)},display:B(()=>i(S,null,[i("h3",null,[s("Small Fire")
margin:10px0;"/>${J}`:T,l.value=!0},onOpenLayer(){if(fe.value=!1,window.matchMedia("(min-width:1468px)").matches)if(de.tabs.includes(D!=null?D:"trees")){const Q=de.tabs.lastIndexOf(D!=null?D:"trees");de.tabs.splice(Q,1)}else de.tabs.push(D!=null?D:"trees"),R.minimized.value=!0;else de.tabs.splice(1,1/0,D!=null?D:"trees")},onUnlockLayer(){D&&(M.value=!0,setTimeout(()=>{var Q,me;n.value=-1,o.value=u((me=(Q=_t[D!=null?D:"trees"])==null?void 0:Q.name)!=null?me:""),r.value=T,de.devSpeed=null,l.value=!0},1e3))}}}}})}const c=[d(()=>({day:1,shouldNotify:!1,layer:"trees",symbol:Un,story:"Ohno!SantaforgotaboutChristmasandit's only 25 days away! He'saskedforyourhelpduetoyourhistorygettinglargequantitiesofthingsinshortamountsoftime.Unfortunatelyyou're really starting from scratch here - let'sstartwithgettingwood,whichyou'll need for everything from building workshops to wrapping paper to many of the toys themselves!",completedStory:"Santa looks at all the wood you'vegatheredandtellsyouyou've done well! He says you should take the rest of the day off so you'rerefreshedfortomorrow's work. Good Job!"})),d(()=>({day:2,shouldNotify:!1,layer:"workshop",symbol:Rn,story:"Santa looked over your tree farm and was impressed with how much you could accomplish in just one day. Today'sgoalistogetaworkshopbuiltupfortheelvestoworkin-andapparently,theyneedquitealotofspacetowork!",completedStory:"Theworkshopcomplete,Santaonceagaindismissesyoufortheday.Withastrongfoundation,thisworkshopshouldsufficeforsupportingfutureworktowardthisimpossiblemission.GoodJob!"})),d(()=>({day:3,shouldNotify:!1,layer:"coal",symbol:On,story:"Santatellsyouthatunfortunatelytherearequiteafewnaughtychildrenouttherethisyear,andhe'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'vegatheredandtellsyouyou've done well! He says you should take the rest of the day off so you'rerefreshedfortomorrow's work. Good Job!"})),d(()=>({day:4,shouldNotify:!1,layer:"elves",symbol:qn,story:"Alright, it seems you finally have enough things set up to start bringing in the elves! Unfortunately, it seems they'llneedtoberetrainedonhowtohelp,sincethey've stopped practicing for 11 months!",completedStory:"The workshop now hums with the bustling elves working on everything. They can take it from here - you deserve a break after such a long day! Good Job!"})),d(()=>({day:5,shouldNotify:!1,layer:"paper",symbol:Gn,story:"With the elves trained, we'realmostreadytostartworkingonthesepresents!Justacouplemorepre-reqsfirst,startingwithturningallthiswoodintowoodpulpandfinallyintopaper,whichwillberequiredforwrappingpaperlateronbutinthemeantimecanbeusedtohelpwriteguideswhichwillhelptheseelvescontinuetheireducation!",completedStory:"Youlookuponyourriversofbookpulpasyouhandoutstacksofpaperstoelvestoreadthrough.You've continued getting closer and closer to preparing for Christmas, and can go to bed satisfied with your progress. Good Job!"})),d(()=>({day:6,shouldNotify:!1,layer:"boxes",symbol:Ln,story:"You watch all these elves carrying incredibly large loads just in their open elf-sized hands, and realize there'sprobablyabetterway.Youneedtoputthetoysinboxesanyways,sowhydon't we get started working on those so the workers can take advantage as well?",completedStory:"Wow, those boxes are really convenient! The workshop feels more and more proper with every day. You tick another requirement on your list and start looking towards tomorrow. Good Job!"})),d(()=>({day:7,shouldNotify:!1,layer:"metal",symbol:Qn,story:"You woke up ready to make some toys, before realizing most toys these days are made out of more than just wood! You'resureyou're close to really getting to work, but there'safewmorematerialsyou'regoingtoneed-likemetal!Lotsofthingsneedmetal!",completedStory:"Thesoundsof
${E}`)}}return m[M]}Xt(l,M=>{M&&Object.keys(m).forEach(E=>delete m[E])});const h=f(()=>at.saves.reduce((M,E)=>(M[E]=b(E),M),{}));function A(M){let E;switch(de.id===M?E=Bn(de[ot]):E=JSON.stringify(h.value[M]),je.exportEncoding){default:console.warn(`Unknownsaveencoding:${je.exportEncoding}.Defaultingtolz`);case"lz":E=ml.compressToUTF16(E);break;case"base64":E=btoa(unescape(encodeURIComponent(E)));break;case"plain":break}const T=document.createElement("textarea");T.value=E,document.body.appendChild(T),T.select(),T.setSelectionRange(0,99999),document.execCommand("copy"),document.body.removeChild(T)}function v(M){de.id===M&&Jt();const E={...h.value[M],id:ta()};Jt(E),at.saves.push(E.id)}function _(M){at.saves=at.saves.filter(E=>E!==M),localStorage.removeItem(M),m[M]=void 0}function N(M){h.value[de.id].time=de.time,Jt(),m[de.id]=void 0,El(h.value[M]),m[M]=void 0}function D(M){if(d.value=M,_l(()=>{d.value=null}),M[0]!=="{")if(M[0]==="e")M=decodeURIComponent(escape(atob(M)));else if(M[0]==="\u1BE1")M=ml.decompressFromUTF16(M);else{console.warn("Unable to determine preset encoding",M);return}const E=JSON.parse(M);E.id=ta(),Jt(E),at.saves.push(E.id),N(E.id)}function H(M,E){const T=h.value[M];T&&(T.name=E,de.id===M?(de.name=E,Jt()):(Jt(T),m[M]=void 0))}return(M,E)=>(k(),ye(wt,{modelValue:l.value,"onUpdate:modelValue":E[4]||(E[4]=T=>l.value=T),ref_key:"modal",ref:n},{header:pe(()=>[Xu]),body:pe(({shown:T})=>[T?(k(),ye(u(pi),{key:0,list:u(at).saves,handle:".handle",itemKey:J=>J},{item:pe(({element:J})=>[i(zu,{save:u(h)[J],onOpen:fe=>N(J),onExport:fe=>A(J),onEditName:fe=>H(J,fe),onDuplicate:fe=>v(J),onDelete:fe=>_(J)},null,8,["save","onOpen","onExport","onEditName","onDuplicate","onDelete"])]),_:1},8,["list","itemKey"])):G("",!0)]),footer:pe(()=>[g("div",Yu,[i(Kn,{modelValue:r.value,"onUpdate:modelValue":E[0]||(E[0]=T=>r.value=T),title:"Import Save",placeholder:"Paste your save here!",class:ct({importingFailed:o.value})},null,8,["modelValue","class"]),g("div",Zu,[ed,g("div",td,[g("button",{class:"button",onClick:E[1]||(E[1]=T=>N(u(Il)().id))},"New Game"),Object.keys(u(p)).length>0?(k(),ye(Oa,{key:0,options:u(p),modelValue:d.value,"onUpdate:modelValue":E[2]||(E[2]=T=>D(T)),closeOnSelect:"",placeholder:"Select preset",class:"presets"},null,8,["options","modelValue"])):G("",!0)])]),g("div",ld,[ad,g("button",{class:"button modal-default-button",onClick:E[3]||(E[3]=T=>l.value=!1)}," Close ")])])]),_:1},8,["modelValue"]))}});var zn=$e(nd,[["__scopeId","data-v-3b9991aa"]]);const Gt=e=>(ol("data-v-8495e562"),e=e(),sl(),e),id=["src","alt"],od={key:1,class:"title"},sd=Gt(()=>g("div",{style:{"flex-grow":"1",cursor:"unset"}},null,-1)),rd={class:"discord"},ud={class:"discord-links"},dd={key:0},cd=["href"],pd=Gt(()=>g("li",null,[g("a",{href:"https://discord.gg/WzejVAx",target:"_blank"},"The Paper Pilot Community")],-1)),md=Gt(()=>g("li",null,[g("a",{href:"https://discord.gg/F3xveHV",target:"_blank"},"The Modding Tree")],-1)),vd={href:"https://forums.moddingtree.com/",target:"_blank"},fd=Gt(()=>g("span",{class:"material-icons"},"forum",-1)),gd=Gt(()=>g("span",{class:"material-icons"},"info",-1)),hd=Gt(()=>g("span",{class:"material-icons"},"library_books",-1)),yd=Gt(()=>g("span",{class:"material-icons"},"settings",-1)),bd=Gt(()=>g("span",{class:"material-icons"},"library_books",-1)),wd=Gt(()=>g("span",{class:"material-icons"},"settings",-1)),Ad=Gt(()=>g("span",{class:"material-icons"},"info",-1)),Cd={href:"https://forums.moddingtree.com/",target:"_blank"},kd=Gt(()=>g("span",{class:"material-icons"},"forum",-1)),Ed={class:"discord"},_d={class:"discord-links"},Sd={key:0},Bd=["href"],Md=Gt(()=>g("li",null,[g("a",{href:"https://discord.gg/WzejVAx",target:"_blank"},"The Paper Pilot Community")],-1)),Nd=Gt(()=>g("li",null,[g("a",{href:"https://discord.gg/F3xveHV",target:"_blank"},"The Modding Tree")],-1)),xd=Ae({__name:"Nav",setup(e){const t=V(null),l=V(null),n=V(null),o=V(null),{useHeader:r,banner:d,title:c,discordName:p,discordLink:m,versionNumber:b}=je;function h(){window.open(m,"mywindow")}return(A,v)=>(k(),I(S,null,[u(r)?(k(),I("div",Sl({key:0,
Learnmoreatwww.moddingtree.com`,"font-weight: bold; font-size: 24px; color: #A3BE8C; background: #2E3440; padding: 4px 8px; border-radius: 8px;","padding: 4px;"),await No();const{globalBus:e}=await aa(()=>Promise.resolve().then(function(){return po}),void 0),{startGameLoop:t}=await aa(()=>import("./gameLoop.adaee6f9.js"),["assets/gameLoop.adaee6f9.js","assets/@fontsource.c175eac8.css","assets/vue.92681fcb.js","assets/lz-string.731cedc5.js","assets/@vue.4ce677c2.js","assets/nanoevents.1080beb7.js","assets/is-plain-object.906d88e8.js","assets/vue-next-select.a2bfab1d.js","assets/vue-next-select.9e6f4164.css","assets/vue-toastification.6f567382.js","assets/vue-toastification.4b5f8ac8.css","assets/vuedraggable.7949458c.js","assets/sortablejs.29100d8a.js","assets/vue-textarea-autosize.35804eaf.js","assets/workbox-window.8d14e8b7.js"]),l=window.vue=ri(pc);e.emit("setupVue",l),l.mount("#app"),_l(()=>{const n=cn(),{updateServiceWorker:o}=vc({onNeedRefresh(){n.info("New content available, click here to update.",{timeout:!1,closeOnClick:!1,draggable:!1,icon:{iconClass:"material-icons",iconChildren:"refresh",iconTag:"i"},rtl:!1,onClick(){o()}})},onOfflineReady(){n.info("App ready to work offline")},onRegisterError:console.warn,onRegistered(r){r&&setInterval(()=>r.update(),60*60*1e3)}})}),t()});export{a as D,aa as _,rt as a,je as b,Nr as c,Xe as g,Ta as l,de as p,at as s};