Advent-Incremental/assets/index.38969004.js

17 lines
169 KiB
JavaScript
Raw Normal View History

/* empty css */import"./vue.92681fcb.js";import{Z as S,l as we,aa as L,t as O,ay as Sn,ar as Ht,aE as y,a0 as M,aK as ft,a1 as f,O as x,aG as vn,A as De,_ as G,a8 as u,b6 as U,b8 as Mn,bs as fs,C as o,aq as Qt,bu as sn,bb as An,T as oi,a7 as h,u as In,j as ri,bv as es,q as dn,b1 as ht,G as ke,aC as ps,w as nt,b2 as Xe,ao as ui,I as Ie,J,$ as E,aH as wt,aF as kt,z as ot,aN as ye,al as _n,aL as xt,H as ci,aJ as hs,bn as di,br as mi,be as fi}from"./@vue.4ce677c2.js";import{c as gs}from"./nanoevents.1080beb7.js";import{L as Et}from"./lz-string.731cedc5.js";import{i as pi}from"./is-plain-object.906d88e8.js";import{Y as hi}from"./vue-next-select.a2bfab1d.js";import{s as gi,u as vs}from"./vue-toastification.6f567382.js";import{D as vi}from"./vuedraggable.7949458c.js";import{p as yi}from"./vue-textarea-autosize.35804eaf.js";import{v as bi,n as _i}from"./workbox-window.8d14e8b7.js";import"./sortablejs.29100d8a.js";const wi=function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))s(i);new MutationObserver(i=>{for(const l of i)if(l.type==="childList")for(const r of l.addedNodes)r.tagName==="LINK"&&r.rel==="modulepreload"&&s(r)}).observe(document,{childList:!0,subtree:!0});function n(i){const l={};return i.integrity&&(l.integrity=i.integrity),i.referrerpolicy&&(l.referrerPolicy=i.referrerpolicy),i.crossorigin==="use-credentials"?l.credentials="include":i.crossorigin==="anonymous"?l.credentials="omit":l.credentials="same-origin",l}function s(i){if(i.ep)return;i.ep=!0;const l=n(i);fetch(i.href,l)}};wi();const ki="modulepreload",ts={},Ci="./",wn=function(t,n){return!n||n.length===0?t():Promise.all(n.map(s=>{if(s=`${Ci}${s}`,s in ts)return;ts[s]=!0;const i=s.endsWith(".css"),l=i?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${s}"]${l}`))return;const r=document.createElement("link");if(r.rel=i?"stylesheet":ki,i||(r.as="script",r.crossOrigin=""),r.href=s,document.head.appendChild(r),i)return new Promise((c,d)=>{r.addEventListener("load",c),r.addEventListener("error",()=>d(new Error(`Unable to preload CSS for ${s}`)))})})).then(()=>t())},Ni="./projInfo-schema.json",Si="Advent Incremental",Mi="An incremental game you play a day at a time, leading up to Christmas!",Ai="advent-incremental",Ii="thepaperpilot and friends",Ei="",Bi="",Pi="0.3",xi="Initial Commit",Fi=!0,Ti=!1,Ri=2,$i=!0,Di=null,Oi="",qi=["main"],Ui=3600,Vi=0,Li=!0,Gi="base64";var ae={$schema:Ni,title:Si,description:Mi,id:Ai,author:Ii,discordName:Ei,discordLink:Bi,versionNumber:Pi,versionTitle:xi,allowGoBack:Fi,defaultShowSmall:Ti,defaultDecimalsShown:Ri,useHeader:$i,banner:Di,logo:Oi,initialTabs:qi,maxTickLength:Ui,offlineLimit:Vi,enablePausing:Li,exportEncoding:Gi};const $n=17,Hi=9e15,Qi=Math.log10(9e15),zi=1/9e15,ji=308,Ki=-324,ns=5,Wi=function(){const e=[];for(let n=Ki+1;n<=ji;n++)e.push(Number("1e"+n));const t=323;return function(n){return e[n+t]}}(),Ut=[2,Math.E,3,4,5,6,7,8,9,10],Ji=[[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
Stack: ${it}
Trying to pop ${n.id}`;return it.pop(),F(n,"color"),F(n,"display"),F(n,"name"),$e(n,"name",n.id),F(n,"minWidth"),$e(n,"minWidth",600),F(n,"minimizable"),$e(n,"minimizable",!0),n})}function Is(e,t){if(console.info("Adding layer",e.id),Ue[e.id]){console.error("Attempted to add layer with same ID as existing layer",e.id,Ue[e.id]);return}$e(t,"layers",{}),t.layers[e.id]==null&&(t.layers[e.id]={}),Ue[e.id]=e,Ce.emit("addLayer",e,t.layers[e.id])}function Ia(e){return Ue[e]}function Es(e){console.info("Removing layer",e.id),Ce.emit("removeLayer",e),Ue[e.id]=void 0}function Ea(e){Es(e),Is(e,q)}function Ba(e){const t=O(!1);return{openModal:()=>t.value=!0,modal:T(()=>u(rt,{modelValue:t.value,"onUpdate:modelValue":n=>t.value=n},{header:()=>u("h2",null,[o(e.name)]),body:o(e.display)}))}}Ce.on("update",function(t){Object.values(Ue).forEach(n=>{n==null||n.emit("preUpdate",t)}),Object.values(Ue).forEach(n=>{n==null||n.emit("update",t)}),Object.values(Ue).forEach(n=>{n==null||n.emit("postUpdate",t)})});var Pa=Object.freeze(Object.defineProperty({__proto__:null,RegisterNodeInjectionKey:Vn,UnregisterNodeInjectionKey:Ln,NodesInjectionKey:Gn,BoundsInjectionKey:Hn,layers:Ue,persistentRefs:Kt,addingLayers:it,createLayer:$t,addLayer:Is,getLayer:Ia,removeLayer:Es,reloadLayer:Ea,setupLayerModal:Ba},Symbol.toStringTag,{value:"Module"}));const ln=Symbol("PersistentState"),on=Symbol("DefaultValue"),Cn=Symbol("StackTrace"),Bs=Symbol("Deleted"),rn=Symbol("NonPersistent"),nn=Symbol("SaveDataPath");function xa(){var e;return((e=new Error().stack)==null?void 0:e.split(`
`).slice(3,5).map(t=>t.trim()).join(`
`))||""}function Pe(e){const t=we(e)?e:O(e);return t[ln]=t,t[on]=we(e)?e.value:e,t[Cn]=xa(),t[Bs]=!1,t[rn]=S({get(){return t.value},set(n){t.value=n}}),t[nn]=void 0,it.length===0?console.warn("Creating a persistent ref outside of a layer. This is not officially supported",t,`
Created at:
`+t[Cn]):Kt[it[it.length-1]].add(t),t}function Fa(e){return e&&typeof e=="object"&&ln in e}function Z(e){return e[rn]}Ce.on("addLayer",(e,t)=>{const n=[],s=(i,l=[])=>{let r=!1;return Object.keys(i).forEach(c=>{let d=i[c];if(d&&typeof d=="object")if(fe in d&&(d=d[fe]),Fa(d)){if(r=!0,d[Bs]){console.warn("Deleted persistent ref present in returned object. Ignoring...",d,`
Created at:
`+d[Cn]);return}Kt[e.id].delete(d);const m=[e.id,...l,c];d[nn]!=null&&JSON.stringify(m)!==JSON.stringify(d[nn])&&console.error(`Persistent ref is being saved to \`${m.join(".")}\` when it's already present at \`${d[nn].join(".")}\`. This can cause unexpected behavior when loading saves between updates.`,d),d[nn]=m;const v=l.reduce((b,g)=>(g in b||(b[g]={}),b[g]),t),_=v[c];v[c]=d[ln],ri(v)?_!=null?v[c]=_:v[c]=d[on]:_!=null?v[c].value=_:v[c].value=d[on]}else!(d instanceof a)&&!we(d)&&!n.includes(d)&&(typeof d.type=="symbol"&&n.push(d),s(d,[...l,c])&&(es(d)&&!es(i)?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.",fe in i?i[fe]:i,c):r=!0))}),r};s(e[fe]),Kt[e.id].forEach(i=>{console.error(`Created persistent ref in ${e.id} without registering it to the layer! Make sure to include everything persistent in the returned object`,i,`
Created at:
`+i[Cn])}),Kt[e.id].clear()});const fe=Symbol("ProxyState"),jt=Symbol("ProxyPath");function ze(e,t={}){const n=t;let s=!1;function i(){return s||(Object.assign(n,e(n)),s=!0),n}return new Proxy(n,{get(l,r){if(r===fe)return i();const c=i()[r];return c&&typeof c=="object"&&rn in c?c[rn]:c},set(l,r,c){return i()[r]=c,!0},has(l,r){return r===fe?!0:Reflect.has(i(),r)},ownKeys(){return Reflect.ownKeys(i())},getOwnPropertyDescriptor(l,r){return s||(Object.assign(n,e(n)),s=!0),Object.getOwnPropertyDescriptor(l,r)}})}var ge=window.state=In({lastTenTicks:[],hasNaN:!1,NaNPath:[]});const Ps=dn({id:"",devSpeed:null,name:"",tabs:[],time:-1,autosave:!0,offlineProd:!0,offlineTime:null,timePlayed:0,keepGoing:!1,modID:"",modVersion:"",layers:{},usingLog:!1});function xs(e){return JSON.stringify(e,(t,n)=>o(n))}const Fs={get(e,t){var s;if(t===fe||t===jt)return e[t];const n=e[fe][t];if(t!=="value"&&(pi(n)||Array.isArray(n))){if(n!==((s=e[t])==null?void 0:s[fe])){const i=[...e[jt],t];e[t]=new Proxy({[fe]:n,[jt]:i},Fs)}return e[t]}return n},set(e,t,n,s){if(!ge.hasNaN&&(typeof n=="number"&&isNaN(n)||n instanceof a&&(isNaN(n.sign)||isNaN(n.layer)||isNaN(n.mag)))){const i=e[fe][t];if(!(typeof i=="number"&&isNaN(i)||i instanceof a&&(isNaN(i.sign)||isNaN(i.layer)||isNaN(i.mag))))throw Ps.autosave=!1,ge.hasNaN=!0,ge.NaNPath=[...e[jt],t],ge.NaNReceiver=s,console.error("Attempted to set NaN value",[...e[jt],t],e[fe]),"Attempted to set NaN value. See above for details"}return e[fe][t]=n,!0},ownKeys(e){return Reflect.ownKeys(e[fe])},has(e,t){return Reflect.has(e[fe],t)},getOwnPropertyDescriptor(e,t){return Object.getOwnPropertyDescriptor(e[fe],t)}};var q=window.player=new Proxy({[fe]:Ps,[jt]:["player"]},Fs);function Ts(e={}){return Object.assign({id:`${ae.id}-0`,name:"Default Save",tabs:ae.initialTabs.slice(),time:Date.now(),autosave:!0,offlineProd:!0,offlineTime:0,timePlayed:0,keepGoing:!1,modID:ae.id,modVersion:ae.versionNumber,layers:{}},e)}function at(e){const t=Et.compressToUTF16(xs(e!=null?e:q[fe]));return localStorage.setItem((e!=null?e:q[fe]).id,t),t}async function Ta(){$a();try{let e=localStorage.getItem(pe.active);if(e==null){await Lt(Wt());return}if(e[0]!=="{")if(e[0]==="e")e=decodeURIComponent(escape(atob(e)));else if(e[0]==="\u1BE1")e=Et.decompressFromUTF16(e);else throw"Unable to determine save encoding";const t=JSON.parse(e);if(t.modID!==ae.id){await Lt(Wt());return}t.id=pe.active,await Lt(t)}catch(e){console.error(`Failed to load save. Falling back to new save.
`,e),await Lt(Wt())}}function Wt(){const e=bn(),t=Ts({id:e});return at(t),pe.saves.push(e),t}function bn(){let e,t=0;do e=`${ae.id}-${t++}`;while(localStorage.getItem(e));return e}async function Lt(e){console.info("Loading save",e);const{layers:t,removeLayer:n,addLayer:s}=await wn(()=>Promise.resolve().then(function(){return Pa}),void 0),{fixOldSave:i,getInitialLayers:l}=await wn(()=>Promise.resolve().then(function(){return ro}),void 0);for(const r in t){const c=t[r];c&&n(c)}l(e).forEach(r=>s(r,e)),e=Ts(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,ae.offlineLimit*3600)),e.time=Date.now(),e.modVersion!==ae.versionNumber&&i(e.modVersion,e),Object.assign(q,e),pe.active=q.id,Ce.emit("onLoad")}setInterval(()=>{q.autosave&&at()},1e3);window.onbeforeunload=()=>{q.autosave&&at()};window.save=at;const Ra=window.hardReset=async()=>{await Lt(Wt())},un=dn({active:"",saves:[],showTPS:!0,theme:Un.Nordic,unthrottled:!1});ht(un,e=>{const t=Et.compressToUTF16(JSON.stringify(e));localStorage.setItem(ae.id,t)},{deep:!0});var pe=window.settings=un;window.hardResetSettings=()=>{const e={active:"",saves:[],showTPS:!0,theme:Un.Nordic};Ce.emit("loadSettings",e),Object.assign(un,e),Ra()};function $a(){try{let e=localStorage.getItem(ae.id);if(e!=null&&e!==""){if(e[0]!=="{")if(e[0]==="e")e=decodeURIComponent(escape(atob(e)));else if(e[0]==="\u1BE1")e=Et.decompressFromUTF16(e);else{console.warn("Unable to determine settings encoding",e);return}const t=JSON.parse(e);typeof t=="object"&&Object.assign(un,t)}Ce.emit("loadSettings",un)}catch{}}const Rs=dn([]);function Da(e){Rs.push(e)}const $s=dn([]);function Oa(e){$s.push(e)}const qa=dn([]),Ua={class:"table"},Jt=L({__name:"Column",setup(e){const t=S(()=>mn[pe.theme].mergeAdjacent);return(n,s)=>(y(),M("div",Ua,[f("div",{class:ke(["col",{mergeAdjacent:o(t)}])},[ft(n.$slots,"default")],2)]))}}),Va={class:"table"},Ds=L({__name:"Row",setup(e){const t=S(()=>mn[pe.theme].mergeAdjacent);return(n,s)=>(y(),M("div",Va,[f("div",{class:ke(["row",{mergeAdjacent:o(t)}])},[ft(n.$slots,"default")],2)]))}});function Qn(e){return typeof e=="function"||Object.prototype.toString.call(e)==="[object Object]"&&!ui(e)}function ee(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}</${t}>`),L({template:e})):L({render:()=>({})}):e}function de(e){if(_t(e))return typeof e=="function"?e():ee(e);const t=e[Tt];return u(t,e[Rt](),null)}function qe(...e){let t;return u(Ds,null,Qn(t=e.map(de))?t:{default:()=>[t]})}function Os(...e){let t;return u(Jt,null,Qn(t=e.map(de))?t:{default:()=>[t]})}function lt(e){if(_t(e))return typeof e=="function"?e():typeof e=="string"?u(x,null,[e]):u(e,null,null);const t=e[Tt];return u(t,e[Rt](),null)}function La(...e){let t;return u(Jt,null,Qn(t=e.map(lt))?t:{default:()=>[t]})}function _t(e){return typeof e=="string"?!0:typeof e=="object"?e==null?!1:"render"in e||"component"in e:typeof e=="function"&&e[an]===!0}function qs(e,t,n){const s=O(null),i=O(void 0);function l(d){s.value||(s.value=setInterval(c,250)),i.value=d,n&&(n.value=!0)}function r(){s.value&&(clearInterval(s.value),s.value=null),n&&(n.value=!1)}function c(){t&&t.value?t.value():e&&e.value&&e.value(i.value)}return ps(r),{start:l,stop:r,handleHolding:c}}function Ga(e,t){const n=S(()=>e.filter(s=>o(s.visibility)===Ee.Visible&&t(s)));return{firstFeature:S(()=>n.value[0]),collapsedContent:T(()=>Os(...n.value.slice(1))),hasCollapsedContent:S(()=>n.value.length>1)}}function Nn(e,t="div"){const n=nt();return Xe(()=>{n.value=ee(Be(e),t)}),n}function Ft(e,t="div"){const n=nt(null);return Xe(()=>{const s=Be(e);n.value=s==null?null:ee(s,t)}),n}function Ha(e){return S(()=>Be(e))}function Be(e){return o(o(e))}function $(...e){return e.includes(Object)||e.push(Object),e}const ve=L({__name:"Spacer",props:{width:{default:"8px"},height:{default:"17px"}},setup(e){return(t,n)=>(y(),M("div",{style:Ie({width:e.width,height:e.height})},null,4))}});const Qa={},za={class:"notif"};function ja(
margin: 10px 0;"/>${R}`:N,t.value=!0},onOpenLayer(){if(me.value=!1,window.matchMedia("(min-width: 1468px)").matches)if(q.tabs.includes(k!=null?k:"trees")){const ue=q.tabs.lastIndexOf(k!=null?k:"trees");q.tabs.splice(ue,1)}else q.tabs.push(k!=null?k:"trees"),z.minimized.value=!0;else q.tabs.splice(1,1/0,k!=null?k:"trees")},onUnlockLayer(){le.value=!0,setTimeout(()=>{var ue,et;n.value=-1,s.value=o((et=(ue=Ue[k!=null?k:"trees"])==null?void 0:ue.name)!=null?et:""),i.value=N,q.devSpeed=null,t.value=!0},1e3)}}}}})}const r=[l(()=>({day:1,shouldNotify:!1,layer:"trees",symbol:Qs,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:zs,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:js,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:Ks,story:"Alright, it seems you finally have enough things set up to start bringing in the elves! Unfortunately, it seems they'll need to be retrained on how to help, since they'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!"})),l(()=>({day:5,shouldNotify:!1,layer:"paper",symbol:Ws,story:"With the elves trained, we're almost ready to start working on these presents! Just a couple more pre-reqs first, starting with turning all this wood into wood pulp and finally into paper, which will be required for wrapping paper later on but in the meantime can be used to help write guides which will help these elves continue their education!",completedStory:"You look upon your rivers of book pulp as you hand out stacks of papers to elves to read through. You've continued getting closer and closer to preparing for Christmas, and can go to bed satisfied with your progress. Good Job!"})),l(()=>({day:6,shouldNotify:!1,layer:"boxes",symbol:Js,story:"You watch all these elves carrying incredibly large loads just in their open elf-sized hands, and realize there's probably a better way. You need to put the toys in boxes anyways, so why don'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!"})),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,
${R}
${N}`)}}return m[A]}ht(n,A=>{A&&Object.keys(m).forEach(N=>delete m[N])});const _=S(()=>pe.saves.reduce((A,N)=>(A[N]=v(N),A),{}));function b(A){let N;switch(q.id===A?N=xs(q[fe]):N=JSON.stringify(_.value[A]),ae.exportEncoding){default:console.warn(`Unknown save encoding: ${ae.exportEncoding}. Defaulting to lz`);case"lz":N=Et.compressToUTF16(N);break;case"base64":N=btoa(unescape(encodeURIComponent(N)));break;case"plain":break}const R=document.createElement("textarea");R.value=N,document.body.appendChild(R),R.select(),R.setSelectionRange(0,99999),document.execCommand("copy"),document.body.removeChild(R)}function g(A){q.id===A&&at();const N={..._.value[A],id:bn()};at(N),pe.saves.push(N.id)}function w(A){pe.saves=pe.saves.filter(N=>N!==A),localStorage.removeItem(A),m[A]=void 0}function k(A){_.value[q.id].time=q.time,at(),m[q.id]=void 0,Lt(_.value[A]),m[A]=void 0}function P(A){if(r.value=A,Ht(()=>{r.value=null}),A[0]!=="{")if(A[0]==="e")A=decodeURIComponent(escape(atob(A)));else if(A[0]==="\u1BE1")A=Et.decompressFromUTF16(A);else{console.warn("Unable to determine preset encoding",A);return}const N=JSON.parse(A);N.id=bn(),at(N),pe.saves.push(N.id),k(N.id)}function le(A,N){const R=_.value[A];R&&(R.name=N,q.id===A?(q.name=N,at()):(at(R),m[A]=void 0))}return(A,N)=>(y(),G(rt,{modelValue:n.value,"onUpdate:modelValue":N[4]||(N[4]=R=>n.value=R),ref_key:"modal",ref:s},{header:U(()=>[Ir]),body:U(({shown:R})=>[R?(y(),G(o(vi),{key:0,list:o(pe).saves,handle:".handle",itemKey:me=>me},{item:U(({element:me})=>[u(Ar,{save:o(_)[me],onOpen:ue=>k(me),onExport:ue=>b(me),onEditName:ue=>le(me,ue),onDuplicate:ue=>g(me),onDelete:ue=>w(me)},null,8,["save","onOpen","onExport","onEditName","onDuplicate","onDelete"])]),_:1},8,["list","itemKey"])):E("",!0)]),footer:U(()=>[f("div",Er,[u(Zs,{modelValue:l.value,"onUpdate:modelValue":N[0]||(N[0]=R=>l.value=R),title:"Import Save",placeholder:"Paste your save here!",class:ke({importingFailed:i.value})},null,8,["modelValue","class"]),f("div",Br,[Pr,f("div",xr,[f("button",{class:"button",onClick:N[1]||(N[1]=R=>k(o(Wt)().id))},"New Game"),Object.keys(o(d)).length>0?(y(),G(Wn,{key:0,options:o(d),modelValue:r.value,"onUpdate:modelValue":N[2]||(N[2]=R=>P(R)),closeOnSelect:"",placeholder:"Select preset",class:"presets"},null,8,["options","modelValue"])):E("",!0)])]),f("div",Fr,[Tr,f("button",{class:"button modal-default-button",onClick:N[3]||(N[3]=R=>n.value=!1)}," Close ")])])]),_:1},8,["modelValue"]))}});var ei=ne(Rr,[["__scopeId","data-v-3b9991aa"]]);const Ze=e=>(wt("data-v-4a3f8425"),e=e(),kt(),e),$r=["src","alt"],Dr={key:1,class:"title"},Or=Ze(()=>f("div",{style:{"flex-grow":"1",cursor:"unset"}},null,-1)),qr={class:"discord"},Ur={class:"discord-links"},Vr={key:0},Lr=["href"],Gr=Ze(()=>f("li",null,[f("a",{href:"https://discord.gg/WzejVAx",target:"_blank"},"The Paper Pilot Community")],-1)),Hr=Ze(()=>f("li",null,[f("a",{href:"https://discord.gg/F3xveHV",target:"_blank"},"The Modding Tree")],-1)),Qr={href:"https://forums.moddingtree.com/",target:"_blank"},zr=Ze(()=>f("span",{class:"material-icons"},"forum",-1)),jr=Ze(()=>f("span",{class:"material-icons"},"info",-1)),Kr=Ze(()=>f("span",{class:"material-icons"},"library_books",-1)),Wr=Ze(()=>f("span",{class:"material-icons"},"settings",-1)),Jr=Ze(()=>f("span",{class:"material-icons"},"library_books",-1)),Xr=Ze(()=>f("span",{class:"material-icons"},"settings",-1)),Yr=Ze(()=>f("span",{class:"material-icons"},"info",-1)),Zr={href:"https://forums.moddingtree.com/",target:"_blank"},eu=Ze(()=>f("span",{class:"material-icons"},"forum",-1)),tu={class:"discord"},nu={class:"discord-links"},su={key:0},iu=["href"],au=Ze(()=>f("li",null,[f("a",{href:"https://discord.gg/WzejVAx",target:"_blank"},"The Paper Pilot Community")],-1)),lu=Ze(()=>f("li",null,[f("a",{href:"https://discord.gg/F3xveHV",target:"_blank"},"The Modding Tree")],-1)),ou=L({__name:"Nav",setup(e){const t=O(null),n=O(null),s=O(null),i=O(null),{useHeader:l,banner:r,title:c,discordName:d,discordLink:m,versionNumber:v}=ae;function _(){window.open(m,"mywindow")}return(b,g)=>(y(),M(x,null,[o(l)?(y(),M("div",Qt({key:0,class
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 Ta();const{globalBus:e}=await wn(()=>Promise.resolve().then(function(){return va}),void 0),{startGameLoop:t}=await wn(()=>import("./gameLoop.bd89404d.js"),["assets/gameLoop.bd89404d.js","assets/@fontsource.f66d05e7.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"]),n=window.vue=fi(Gu);e.emit("setupVue",n),n.mount("#app"),Ht(()=>{const s=vs(),{updateServiceWorker:i}=Qu({onNeedRefresh(){s.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(){i()}})},onOfflineReady(){s.info("App ready to work offline")},onRegisterError:console.warn,onRegistered(l){l&&setInterval(l.update,60*60*1e3)}})}),t()});export{a as D,wn as _,ge as a,ae as b,ro as c,Ce as g,q as p,pe as s};