diff --git a/Pictures/PseudoShop/ascended-monthly-sub.png b/Pictures/PseudoShop/ascended-monthly-sub.png new file mode 100644 index 000000000..622eb5356 Binary files /dev/null and b/Pictures/PseudoShop/ascended-monthly-sub.png differ diff --git a/Pictures/PseudoShop/omega-monthly-sub.png b/Pictures/PseudoShop/omega-monthly-sub.png new file mode 100644 index 000000000..0183e0944 Binary files /dev/null and b/Pictures/PseudoShop/omega-monthly-sub.png differ diff --git a/Pictures/PseudoShop/reincarnated-monthly-sub.png b/Pictures/PseudoShop/reincarnated-monthly-sub.png new file mode 100644 index 000000000..3beceeaef Binary files /dev/null and b/Pictures/PseudoShop/reincarnated-monthly-sub.png differ diff --git a/Pictures/PseudoShop/transcended-monthly-sub.png b/Pictures/PseudoShop/transcended-monthly-sub.png new file mode 100644 index 000000000..cfb08e817 Binary files /dev/null and b/Pictures/PseudoShop/transcended-monthly-sub.png differ diff --git a/Pictures/ascended-monthly-sub.png b/Pictures/ascended-monthly-sub.png new file mode 100644 index 000000000..622eb5356 Binary files /dev/null and b/Pictures/ascended-monthly-sub.png differ diff --git a/Pictures/Jar of PseudoCoins.png b/Pictures/jar-pseudocoins.png similarity index 100% rename from Pictures/Jar of PseudoCoins.png rename to Pictures/jar-pseudocoins.png diff --git a/Pictures/Jug of PseudoCoins.png b/Pictures/jug-pseudocoins.png similarity index 100% rename from Pictures/Jug of PseudoCoins.png rename to Pictures/jug-pseudocoins.png diff --git a/Pictures/Magic Pot of PseudoCoins.png b/Pictures/magic-pot-pseudocoins.png similarity index 100% rename from Pictures/Magic Pot of PseudoCoins.png rename to Pictures/magic-pot-pseudocoins.png diff --git a/Pictures/omega-monthly-sub.png b/Pictures/omega-monthly-sub.png new file mode 100644 index 000000000..0183e0944 Binary files /dev/null and b/Pictures/omega-monthly-sub.png differ diff --git a/Pictures/Piggy Bank of PseudoCoins.png b/Pictures/piggy-bank-pseudocoins.png similarity index 100% rename from Pictures/Piggy Bank of PseudoCoins.png rename to Pictures/piggy-bank-pseudocoins.png diff --git a/Pictures/reincarnated-monthly-sub.png b/Pictures/reincarnated-monthly-sub.png new file mode 100644 index 000000000..3beceeaef Binary files /dev/null and b/Pictures/reincarnated-monthly-sub.png differ diff --git a/Pictures/Roll of PseudoCoins.png b/Pictures/roll-pseudocoins.png similarity index 100% rename from Pictures/Roll of PseudoCoins.png rename to Pictures/roll-pseudocoins.png diff --git a/Pictures/transcended-monthly-sub.png b/Pictures/transcended-monthly-sub.png new file mode 100644 index 000000000..cfb08e817 Binary files /dev/null and b/Pictures/transcended-monthly-sub.png differ diff --git a/Synergism.css b/Synergism.css index eb0c43094..e018a391a 100644 --- a/Synergism.css +++ b/Synergism.css @@ -3995,6 +3995,30 @@ form input:hover { margin: 0 auto; } +.pseudoSubscriptionContainer { + display: flex; + flex-direction: column; + align-items: center; +} + +.pseudoSubscriptionContainer > form { + display: flex; + flex-direction: column; + justify-content: center; + margin-top: 10px; +} + +.pseudoSubscriptionContainer > form > input[type="submit"] { + border: 2px solid gold; + width: 200px; + height: 40px; +} + +.pseudoSubscriptionContainer > #sub-section-holder { + display: grid; + grid-template-columns: repeat(4, 1fr); +} + .pseudoCoinContainer { margin: 10px 10px 0 0; border: 1px solid #ccc; @@ -4002,10 +4026,22 @@ form input:hover { text-align: center; } +.subscriptionContainer { + margin: 10px 10px 0 0; + border: 1px solid lightgoldenrodyellow; + border: 2px solid gold; + text-align: center; +} + #pseudoCoins > #productContainer > section > * > .pseudoCoinImage { margin-top: 8px; } +.pseudoCoinSubImage { + height: 48px; + width: 48px; +} + .pseudoCoinText { width: 90%; height: 80px; @@ -4017,8 +4053,18 @@ form input:hover { margin: 5px auto; } +.pseudoSubscriptionText { + width: 100%; + height: 80px; + padding: 10px; + box-sizing: border-box; + text-align: center; + box-shadow: 0 0 10px rgb(0 0 0 / 10%); + margin: 5px auto; +} + .pseudoCoinButton { - width: 50%; + width: 75%; padding: 10px; background-color: black; color: white; diff --git a/dist/out.js b/dist/out.js index ea26725fd..cc31be485 100644 --- a/dist/out.js +++ b/dist/out.js @@ -1,6 +1,6 @@ -"use strict";(()=>{var lh=Object.create;var tc=Object.defineProperty,ch=Object.defineProperties,uh=Object.getOwnPropertyDescriptor,dh=Object.getOwnPropertyDescriptors,ph=Object.getOwnPropertyNames,ri=Object.getOwnPropertySymbols,gh=Object.getPrototypeOf,rc=Object.prototype.hasOwnProperty,qd=Object.prototype.propertyIsEnumerable;var Qd=(t,r,n)=>r in t?tc(t,r,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[r]=n,O=(t,r)=>{for(var n in r||(r={}))rc.call(r,n)&&Qd(t,n,r[n]);if(ri)for(var n of ri(r))qd.call(r,n)&&Qd(t,n,r[n]);return t},ee=(t,r)=>ch(t,dh(r));var jd=(t,r)=>{var n={};for(var a in t)rc.call(t,a)&&r.indexOf(a)<0&&(n[a]=t[a]);if(t!=null&&ri)for(var a of ri(t))r.indexOf(a)<0&&qd.call(t,a)&&(n[a]=t[a]);return n};var Wa=(t,r)=>()=>(r||t((r={exports:{}}).exports,r),r.exports);var mh=(t,r,n,a)=>{if(r&&typeof r=="object"||typeof r=="function")for(let s of ph(r))!rc.call(t,s)&&s!==n&&tc(t,s,{get:()=>r[s],enumerable:!(a=uh(r,s))||a.enumerable});return t};var Ln=(t,r,n)=>(n=t!=null?lh(gh(t)):{},mh(r||!t||!t.__esModule?tc(n,"default",{value:t,enumerable:!0}):n,t));var nc=(t,r,n)=>{if(!r.has(t))throw TypeError("Cannot "+n)};var te=(t,r,n)=>(nc(t,r,"read from private field"),n?n.call(t):r.get(t)),xt=(t,r,n)=>{if(r.has(t))throw TypeError("Cannot add the same private member more than once");r instanceof WeakSet?r.add(t):r.set(t,n)},Et=(t,r,n,a)=>(nc(t,r,"write to private field"),a?a.call(t,n):r.set(t,n),n);var ni=(t,r,n)=>(nc(t,r,"access private method"),n);var Wd=Wa((w2,Vd)=>{"use strict";Vd.exports=function(t,r,n){if(t==null||r==null)return t;var a=String(t),s=typeof r=="number"?r:parseInt(r,10);if(isNaN(s)||!isFinite(s))return a;var l=a.length;if(l>=s)return a;var c=n==null?"":String(n);c===""&&(c=" ");for(var p=s-l;c.lengthp?c.substr(0,p):c;return a+g}});var sc=Wa((M2,oi)=>{var ac=function(){var t=String.fromCharCode,r="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-$",a={};function s(c,p){if(!a[c]){a[c]={};for(var g=0;g>>8,g[m*2+1]=b%256}return g},decompressFromUint8Array:function(c){if(c==null)return l.decompress(c);for(var p=new Array(c.length/2),g=0,m=p.length;g>1}else{for(h=1,m=0;m>1}U--,U==0&&(U=Math.pow(2,L),L++),delete C[B]}else for(h=b[B],m=0;m>1;U--,U==0&&(U=Math.pow(2,L),L++),b[x]=k++,B=String(v)}if(B!==""){if(Object.prototype.hasOwnProperty.call(C,B)){if(B.charCodeAt(0)<256){for(m=0;m>1}else{for(h=1,m=0;m>1}U--,U==0&&(U=Math.pow(2,L),L++),delete C[B]}else for(h=b[B],m=0;m>1;U--,U==0&&(U=Math.pow(2,L),L++)}for(h=2,m=0;m>1;for(;;)if(T=T<<1,S==p-1){E.push(g(T));break}else S++;return E.join("")},decompress:function(c){return c==null?"":c==""?null:l._decompress(c.length,32768,function(p){return c.charCodeAt(p)})},_decompress:function(c,p,g){var m=[],h,b=4,C=4,v=3,x="",B=[],U,k,L,E,T,S,I,N={val:g(0),position:p,index:1};for(U=0;U<3;U+=1)m[U]=U;for(L=0,T=Math.pow(2,2),S=1;S!=T;)E=N.val&N.position,N.position>>=1,N.position==0&&(N.position=p,N.val=g(N.index++)),L|=(E>0?1:0)*S,S<<=1;switch(h=L){case 0:for(L=0,T=Math.pow(2,8),S=1;S!=T;)E=N.val&N.position,N.position>>=1,N.position==0&&(N.position=p,N.val=g(N.index++)),L|=(E>0?1:0)*S,S<<=1;I=t(L);break;case 1:for(L=0,T=Math.pow(2,16),S=1;S!=T;)E=N.val&N.position,N.position>>=1,N.position==0&&(N.position=p,N.val=g(N.index++)),L|=(E>0?1:0)*S,S<<=1;I=t(L);break;case 2:return""}for(m[3]=I,k=I,B.push(I);;){if(N.index>c)return"";for(L=0,T=Math.pow(2,v),S=1;S!=T;)E=N.val&N.position,N.position>>=1,N.position==0&&(N.position=p,N.val=g(N.index++)),L|=(E>0?1:0)*S,S<<=1;switch(I=L){case 0:for(L=0,T=Math.pow(2,8),S=1;S!=T;)E=N.val&N.position,N.position>>=1,N.position==0&&(N.position=p,N.val=g(N.index++)),L|=(E>0?1:0)*S,S<<=1;m[C++]=t(L),I=C-1,b--;break;case 1:for(L=0,T=Math.pow(2,16),S=1;S!=T;)E=N.val&N.position,N.position>>=1,N.position==0&&(N.position=p,N.val=g(N.index++)),L|=(E>0?1:0)*S,S<<=1;m[C++]=t(L),I=C-1,b--;break;case 2:return B.join("")}if(b==0&&(b=Math.pow(2,v),v++),m[I])x=m[I];else if(I===C)x=k+k.charAt(0);else return null;B.push(x),m[C++]=k+x.charAt(0),b--,k=x,b==0&&(b=Math.pow(2,v),v++)}}};return l}();typeof define=="function"&&define.amd?define(function(){return ac}):typeof oi<"u"&&oi!=null?oi.exports=ac:typeof angular<"u"&&angular!=null&&angular.module("LZString",[]).factory("LZString",function(){return ac})});var xp=Wa((Sw,uc)=>{"use strict";var Xh=Object.prototype.hasOwnProperty,Mt="~";function js(){}Object.create&&(js.prototype=Object.create(null),new js().__proto__||(Mt=!1));function Zh(t,r,n){this.fn=t,this.context=r,this.once=n||!1}function wp(t,r,n,a,s){if(typeof n!="function")throw new TypeError("The listener must be a function");var l=new Zh(n,a||t,s),c=Mt?Mt+r:r;return t._events[c]?t._events[c].fn?t._events[c]=[t._events[c],l]:t._events[c].push(l):(t._events[c]=l,t._eventsCount++),t}function hi(t,r){--t._eventsCount===0?t._events=new js:delete t._events[r]}function bt(){this._events=new js,this._eventsCount=0}bt.prototype.eventNames=function(){var r=[],n,a;if(this._eventsCount===0)return r;for(a in n=this._events)Xh.call(n,a)&&r.push(Mt?a.slice(1):a);return Object.getOwnPropertySymbols?r.concat(Object.getOwnPropertySymbols(n)):r};bt.prototype.listeners=function(r){var n=Mt?Mt+r:r,a=this._events[n];if(!a)return[];if(a.fn)return[a.fn];for(var s=0,l=a.length,c=new Array(l);s{(function(r,n){typeof Vs=="object"&&typeof dc=="object"?dc.exports=n():typeof define=="function"&&define.amd?define([],n):typeof Vs=="object"?Vs.ClipboardJS=n():r.ClipboardJS=n()})(Vs,function(){return function(){var t={686:function(a,s,l){"use strict";l.d(s,{default:function(){return _t}});var c=l(279),p=l.n(c),g=l(370),m=l.n(g),h=l(817),b=l.n(h);function C(ce){try{return document.execCommand(ce)}catch(z){return!1}}var v=function(z){var Z=b()(z);return C("cut"),Z},x=v;function B(ce){var z=document.documentElement.getAttribute("dir")==="rtl",Z=document.createElement("textarea");Z.style.fontSize="12pt",Z.style.border="0",Z.style.padding="0",Z.style.margin="0",Z.style.position="absolute",Z.style[z?"right":"left"]="-9999px";var se=window.pageYOffset||document.documentElement.scrollTop;return Z.style.top="".concat(se,"px"),Z.setAttribute("readonly",""),Z.value=ce,Z}var U=function(z,Z){var se=B(z);Z.container.appendChild(se);var ne=b()(se);return C("copy"),se.remove(),ne},k=function(z){var Z=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{container:document.body},se="";return typeof z=="string"?se=U(z,Z):z instanceof HTMLInputElement&&!["text","search","url","tel","password"].includes(z==null?void 0:z.type)?se=U(z.value,Z):(se=b()(z),C("copy")),se},L=k;function E(ce){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?E=function(Z){return typeof Z}:E=function(Z){return Z&&typeof Symbol=="function"&&Z.constructor===Symbol&&Z!==Symbol.prototype?"symbol":typeof Z},E(ce)}var T=function(){var z=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},Z=z.action,se=Z===void 0?"copy":Z,ne=z.container,he=z.target,Fe=z.text;if(se!=="copy"&&se!=="cut")throw new Error('Invalid "action" value, use either "copy" or "cut"');if(he!==void 0)if(he&&E(he)==="object"&&he.nodeType===1){if(se==="copy"&&he.hasAttribute("disabled"))throw new Error('Invalid "target" attribute. Please use "readonly" instead of "disabled" attribute');if(se==="cut"&&(he.hasAttribute("readonly")||he.hasAttribute("disabled")))throw new Error(`Invalid "target" attribute. You can't cut text from elements with "readonly" or "disabled" attributes`)}else throw new Error('Invalid "target" value, use a valid Element');if(Fe)return L(Fe,{container:ne});if(he)return se==="cut"?x(he):L(he,{container:ne})},S=T;function I(ce){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?I=function(Z){return typeof Z}:I=function(Z){return Z&&typeof Symbol=="function"&&Z.constructor===Symbol&&Z!==Symbol.prototype?"symbol":typeof Z},I(ce)}function N(ce,z){if(!(ce instanceof z))throw new TypeError("Cannot call a class as a function")}function X(ce,z){for(var Z=0;Z"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(ce){return!1}}function Ct(ce){return Ct=Object.setPrototypeOf?Object.getPrototypeOf:function(Z){return Z.__proto__||Object.getPrototypeOf(Z)},Ct(ce)}function $t(ce,z){var Z="data-clipboard-".concat(ce);if(z.hasAttribute(Z))return z.getAttribute(Z)}var Yt=function(ce){w(Z,ce);var z=J(Z);function Z(se,ne){var he;return N(this,Z),he=z.call(this),he.resolveOptions(ne),he.listenClick(se),he}return re(Z,[{key:"resolveOptions",value:function(){var ne=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};this.action=typeof ne.action=="function"?ne.action:this.defaultAction,this.target=typeof ne.target=="function"?ne.target:this.defaultTarget,this.text=typeof ne.text=="function"?ne.text:this.defaultText,this.container=I(ne.container)==="object"?ne.container:document.body}},{key:"listenClick",value:function(ne){var he=this;this.listener=m()(ne,"click",function(Fe){return he.onClick(Fe)})}},{key:"onClick",value:function(ne){var he=ne.delegateTarget||ne.currentTarget,Fe=this.action(he)||"copy",wt=S({action:Fe,container:this.container,target:this.target(he),text:this.text(he)});this.emit(wt?"success":"error",{action:Fe,text:wt,trigger:he,clearSelection:function(){he&&he.focus(),window.getSelection().removeAllRanges()}})}},{key:"defaultAction",value:function(ne){return $t("action",ne)}},{key:"defaultTarget",value:function(ne){var he=$t("target",ne);if(he)return document.querySelector(he)}},{key:"defaultText",value:function(ne){return $t("text",ne)}},{key:"destroy",value:function(){this.listener.destroy()}}],[{key:"copy",value:function(ne){var he=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{container:document.body};return L(ne,he)}},{key:"cut",value:function(ne){return x(ne)}},{key:"isSupported",value:function(){var ne=arguments.length>0&&arguments[0]!==void 0?arguments[0]:["copy","cut"],he=typeof ne=="string"?[ne]:ne,Fe=!!document.queryCommandSupported;return he.forEach(function(wt){Fe=Fe&&!!document.queryCommandSupported(wt)}),Fe}}]),Z}(p()),_t=Yt},828:function(a){var s=9;if(typeof Element<"u"&&!Element.prototype.matches){var l=Element.prototype;l.matches=l.matchesSelector||l.mozMatchesSelector||l.msMatchesSelector||l.oMatchesSelector||l.webkitMatchesSelector}function c(p,g){for(;p&&p.nodeType!==s;){if(typeof p.matches=="function"&&p.matches(g))return p;p=p.parentNode}}a.exports=c},438:function(a,s,l){var c=l(828);function p(h,b,C,v,x){var B=m.apply(this,arguments);return h.addEventListener(C,B,x),{destroy:function(){h.removeEventListener(C,B,x)}}}function g(h,b,C,v,x){return typeof h.addEventListener=="function"?p.apply(null,arguments):typeof C=="function"?p.bind(null,document).apply(null,arguments):(typeof h=="string"&&(h=document.querySelectorAll(h)),Array.prototype.map.call(h,function(B){return p(B,b,C,v,x)}))}function m(h,b,C,v){return function(x){x.delegateTarget=c(x.target,b),x.delegateTarget&&v.call(h,x)}}a.exports=g},879:function(a,s){s.node=function(l){return l!==void 0&&l instanceof HTMLElement&&l.nodeType===1},s.nodeList=function(l){var c=Object.prototype.toString.call(l);return l!==void 0&&(c==="[object NodeList]"||c==="[object HTMLCollection]")&&"length"in l&&(l.length===0||s.node(l[0]))},s.string=function(l){return typeof l=="string"||l instanceof String},s.fn=function(l){var c=Object.prototype.toString.call(l);return c==="[object Function]"}},370:function(a,s,l){var c=l(879),p=l(438);function g(C,v,x){if(!C&&!v&&!x)throw new Error("Missing required arguments");if(!c.string(v))throw new TypeError("Second argument must be a String");if(!c.fn(x))throw new TypeError("Third argument must be a Function");if(c.node(C))return m(C,v,x);if(c.nodeList(C))return h(C,v,x);if(c.string(C))return b(C,v,x);throw new TypeError("First argument must be a String, HTMLElement, HTMLCollection, or NodeList")}function m(C,v,x){return C.addEventListener(v,x),{destroy:function(){C.removeEventListener(v,x)}}}function h(C,v,x){return Array.prototype.forEach.call(C,function(B){B.addEventListener(v,x)}),{destroy:function(){Array.prototype.forEach.call(C,function(B){B.removeEventListener(v,x)})}}}function b(C,v,x){return p(document.body,C,v,x)}a.exports=g},817:function(a){function s(l){var c;if(l.nodeName==="SELECT")l.focus(),c=l.value;else if(l.nodeName==="INPUT"||l.nodeName==="TEXTAREA"){var p=l.hasAttribute("readonly");p||l.setAttribute("readonly",""),l.select(),l.setSelectionRange(0,l.value.length),p||l.removeAttribute("readonly"),c=l.value}else{l.hasAttribute("contenteditable")&&l.focus();var g=window.getSelection(),m=document.createRange();m.selectNodeContents(l),g.removeAllRanges(),g.addRange(m),c=g.toString()}return c}a.exports=s},279:function(a){function s(){}s.prototype={on:function(l,c,p){var g=this.e||(this.e={});return(g[l]||(g[l]=[])).push({fn:c,ctx:p}),this},once:function(l,c,p){var g=this;function m(){g.off(l,m),c.apply(p,arguments)}return m._=c,this.on(l,m,p)},emit:function(l){var c=[].slice.call(arguments,1),p=((this.e||(this.e={}))[l]||[]).slice(),g=0,m=p.length;for(g;g{var Jh=200,$p="__lodash_hash_undefined__",_p=9007199254740991,wc="[object Arguments]",e1="[object Array]",Dp="[object Boolean]",Gp="[object Date]",t1="[object Error]",xc="[object Function]",Hp="[object GeneratorFunction]",vi="[object Map]",Fp="[object Number]",Mc="[object Object]",kp="[object Promise]",Qp="[object RegExp]",Ci="[object Set]",qp="[object String]",jp="[object Symbol]",fc="[object WeakMap]",Vp="[object ArrayBuffer]",wi="[object DataView]",Wp="[object Float32Array]",Kp="[object Float64Array]",zp="[object Int8Array]",Xp="[object Int16Array]",Zp="[object Int32Array]",Yp="[object Uint8Array]",Jp="[object Uint8ClampedArray]",eg="[object Uint16Array]",tg="[object Uint32Array]",r1=/[\\^$.*+?()[\]{}|]/g,n1=/\w*$/,a1=/^\[object .+?Constructor\]$/,s1=/^(?:0|[1-9]\d*)$/,_e={};_e[wc]=_e[e1]=_e[Vp]=_e[wi]=_e[Dp]=_e[Gp]=_e[Wp]=_e[Kp]=_e[zp]=_e[Xp]=_e[Zp]=_e[vi]=_e[Fp]=_e[Mc]=_e[Qp]=_e[Ci]=_e[qp]=_e[jp]=_e[Yp]=_e[Jp]=_e[eg]=_e[tg]=!0;_e[t1]=_e[xc]=_e[fc]=!1;var o1=typeof global=="object"&&global&&global.Object===Object&&global,i1=typeof self=="object"&&self&&self.Object===Object&&self,rn=o1||i1||Function("return this")(),rg=typeof Ws=="object"&&Ws&&!Ws.nodeType&&Ws,Lp=rg&&typeof Ya=="object"&&Ya&&!Ya.nodeType&&Ya,l1=Lp&&Lp.exports===rg;function c1(t,r){return t.set(r[0],r[1]),t}function u1(t,r){return t.add(r),t}function d1(t,r){for(var n=-1,a=t?t.length:0;++n-1}function _1(t,r){var n=this.__data__,a=Ti(n,t);return a<0?n.push([t,r]):n[a][1]=r,this}nn.prototype.clear=R1;nn.prototype.delete=I1;nn.prototype.get=N1;nn.prototype.has=$1;nn.prototype.set=_1;function Ja(t){var r=-1,n=t?t.length:0;for(this.clear();++r-1&&t%1==0&&t-1&&t%1==0&&t<=_p}function ki(t){var r=typeof t;return!!t&&(r=="object"||r=="function")}function Mb(t){return!!t&&typeof t=="object"}function Lc(t){return dg(t)?z1(t):tb(t)}function Tb(){return[]}function Sb(){return!1}Ya.exports=yb});var um=Wa((Zi,cm)=>{(function(t,r){typeof Zi=="object"&&typeof cm<"u"?r(Zi):typeof define=="function"&&define.amd?define(["exports"],r):(t=typeof globalThis<"u"?globalThis:t||self,r(t.fastUniqueNumbers={}))})(Zi,function(t){"use strict";var r=function(C){return function(v){var x=C(v);return v.add(x),x}},n=function(C){return function(v,x){return C.set(v,x),x}},a=Number.MAX_SAFE_INTEGER===void 0?9007199254740991:Number.MAX_SAFE_INTEGER,s=536870912,l=s*2,c=function(C,v){return function(x){var B=v.get(x),U=B===void 0?x.size:Ba)throw new Error("Congratulations, you created a collection of unique numbers which uses all available integers!");for(;x.has(U);)U=Math.floor(Math.random()*a);return C(x,U)}},p=new WeakMap,g=n(p),m=c(g,p),h=r(m);t.addUniqueNumber=h,t.generateUniqueNumber=m})});(function(){"use strict";var t=function(Q,$){var q=function(Ne){for(var ye=0,Ue=Ne.length;yeQ.length)&&($=Q.length);for(var q=0,ue=new Array($);q<$;q++)ue[q]=Q[q];return ue}function a(Q,$){var q=typeof Symbol<"u"&&Q[Symbol.iterator]||Q["@@iterator"];if(!q){if(Array.isArray(Q)||(q=r(Q))||$&&Q&&typeof Q.length=="number"){q&&(Q=q);var ue=0,de=function(){};return{s:de,n:function(){return ue>=Q.length?{done:!0}:{done:!1,value:Q[ue++]}},e:function(et){throw et},f:de}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. -In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var Ne=!0,ye=!1,Ue;return{s:function(){q=q.call(Q)},n:function(){var et=q.next();return Ne=et.done,et},e:function(et){ye=!0,Ue=et},f:function(){try{!Ne&&q.return!=null&&q.return()}finally{if(ye)throw Ue}}}}var s=!0,l=!1,c="querySelectorAll",p=function($){var q=arguments.length>1&&arguments[1]!==void 0?arguments[1]:document,ue=arguments.length>2&&arguments[2]!==void 0?arguments[2]:MutationObserver,de=arguments.length>3&&arguments[3]!==void 0?arguments[3]:["*"],Ne=function et(Sn,kn,At,Me,We,tt){var Dt=a(Sn),Va;try{for(Dt.s();!(Va=Dt.n()).done;){var mt=Va.value;(tt||c in mt)&&(We?At.has(mt)||(At.add(mt),Me.delete(mt),$(mt,We)):Me.has(mt)||(Me.add(mt),At.delete(mt),$(mt,We)),tt||et(mt[c](kn),kn,At,Me,We,s))}}catch(ec){Dt.e(ec)}finally{Dt.f()}},ye=new ue(function(et){if(de.length){var Sn=de.join(","),kn=new Set,At=new Set,Me=a(et),We;try{for(Me.s();!(We=Me.n()).done;){var tt=We.value,Dt=tt.addedNodes,Va=tt.removedNodes;Ne(Va,Sn,kn,At,l,l),Ne(Dt,Sn,kn,At,s,l)}}catch(mt){Me.e(mt)}finally{Me.f()}}}),Ue=ye.observe;return(ye.observe=function(et){return Ue.call(ye,et,{subtree:s,childList:s})})(q),ye},g="querySelectorAll",m=self,h=m.document,b=m.Element,C=m.MutationObserver,v=m.Set,x=m.WeakMap,B=function($){return g in $},U=[].filter,k=function(Q){var $=new x,q=function(Me){for(var We=0,tt=Me.length;We1&&arguments[1]!==void 0?arguments[1]:!0,tt=0,Dt=Me.length;tt=1&&this.m<10)return this;if(this.m===0)return this.m=0,this.e=0,this;var r=Math.floor(Math.log10(Math.abs(this.m)));return this.m=r===-324?10*this.m/1e-323:this.m/ai(r),this.e+=r,this},t.prototype.fromMantissaExponent=function(r,n){return isFinite(r)&&isFinite(n)?(this.m=r,this.e=n,this.normalize(),this):(r=Number.NaN,n=Number.NaN,this)},t.prototype.fromMantissaExponent_noNormalize=function(r,n){return this.m=r,this.e=n,this},t.prototype.fromDecimal=function(r){return this.m=r.m,this.e=r.e,this},t.prototype.fromNumber=function(r){return isNaN(r)?(this.m=Number.NaN,this.e=Number.NaN):r===Number.POSITIVE_INFINITY?(this.m=1,this.e=Ir):r===Number.NEGATIVE_INFINITY?(this.m=-1,this.e=Ir):r===0?(this.m=0,this.e=0):(this.e=Math.floor(Math.log10(Math.abs(r))),this.m=this.e===-324?10*r/1e-323:r/ai(this.e),this.normalize()),this},t.prototype.fromString=function(r){if(r.indexOf("e")!==-1){var n=r.split("e");this.m=parseFloat(n[0]),this.e=parseFloat(n[1]),this.normalize()}else if(r==="NaN")this.m=Number.NaN,this.e=Number.NaN;else if(this.fromNumber(parseFloat(r)),isNaN(this.m))throw Error("[DecimalError] Invalid argument: "+r);return this},t.prototype.fromValue=function(r){return r instanceof t?this.fromDecimal(r):typeof r=="number"?this.fromNumber(r):typeof r=="string"?this.fromString(r):(this.m=0,this.e=0,this)},t.prototype.toNumber=function(){if(!isFinite(this.e))return Number.NaN;if(this.e>308)return this.m>0?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY;if(this.e<-324)return 0;if(this.e===-324)return this.m>0?5e-324:-5e-324;var r=this.m*ai(this.e);if(!isFinite(r)||this.e<0)return r;var n=Math.round(r);return Math.abs(n-r)<1e-10?n:r},t.prototype.mantissaWithDecimalPlaces=function(r){if(isNaN(this.m)||isNaN(this.e))return Number.NaN;if(this.m===0)return 0;var n=r+1,a=Math.ceil(Math.log10(Math.abs(this.m))),s=Math.round(this.m*Math.pow(10,n-a))*Math.pow(10,a-n);return parseFloat(s.toFixed(Math.max(n-a,0)))},t.prototype.toString=function(){return isNaN(this.m)||isNaN(this.e)?"NaN":this.e>=Ir?this.m>0?"Infinity":"-Infinity":this.e<=-Ir||this.m===0?"0":this.e<21&&this.e>-7?this.toNumber().toString():this.m+"e"+(this.e>=0?"+":"")+this.e},t.prototype.toExponential=function(r){if(isNaN(this.m)||isNaN(this.e))return"NaN";if(this.e>=Ir)return this.m>0?"Infinity":"-Infinity";if(this.e<=-Ir||this.m===0)return"0"+(r>0?(0,si.default)(".",r+1,"0"):"")+"e+0";if(this.e>-324&&this.e<308)return this.toNumber().toExponential(r);isFinite(r)||(r=17);var n=r+1,a=Math.max(1,Math.ceil(Math.log10(Math.abs(this.m))));return(Math.round(this.m*Math.pow(10,n-a))*Math.pow(10,a-n)).toFixed(Math.max(n-a,0))+"e"+(this.e>=0?"+":"")+this.e},t.prototype.toFixed=function(r){return isNaN(this.m)||isNaN(this.e)?"NaN":this.e>=Ir?this.m>0?"Infinity":"-Infinity":this.e<=-Ir||this.m===0?"0"+(r>0?(0,si.default)(".",r+1,"0"):""):this.e>=17?this.m.toString().replace(".","").padEnd(this.e+1,"0")+(r>0?(0,si.default)(".",r+1,"0"):""):this.toNumber().toFixed(r)},t.prototype.toPrecision=function(r){return this.e<=-7?this.toExponential(r-1):r>this.e?this.toFixed(r-this.e-1):this.toExponential(r-1)},t.prototype.valueOf=function(){return this.toString()},t.prototype.toJSON=function(){return this.toString()},t.prototype.toStringWithDecimalPlaces=function(r){return this.toExponential(r)},t.prototype.abs=function(){return ea(Math.abs(this.m),this.e)},t.prototype.neg=function(){return ea(-this.m,this.e)},t.prototype.negate=function(){return this.neg()},t.prototype.negated=function(){return this.neg()},t.prototype.sign=function(){return Math.sign(this.m)},t.prototype.sgn=function(){return this.sign()},t.prototype.round=function(){return this.e<-1?new t(0):this.e<17?new t(Math.round(this.toNumber())):this},t.prototype.floor=function(){return this.e<-1?Math.sign(this.m)>=0?new t(0):new t(-1):this.e<17?new t(Math.floor(this.toNumber())):this},t.prototype.ceil=function(){return this.e<-1?Math.sign(this.m)>0?new t(1):new t(0):this.e<17?new t(Math.ceil(this.toNumber())):this},t.prototype.trunc=function(){return this.e<0?new t(0):this.e<17?new t(Math.trunc(this.toNumber())):this},t.prototype.add=function(r){var n,a,s=D(r);if(this.m===0)return s;if(s.m===0)return this;if(this.e>=s.e?(n=this,a=s):(n=s,a=this),n.e-a.e>17)return n;var l=Math.round(1e14*n.m+1e14*a.m*ai(a.e-n.e));return Ot(l,n.e-14)},t.prototype.plus=function(r){return this.add(r)},t.prototype.sub=function(r){return this.add(D(r).neg())},t.prototype.subtract=function(r){return this.sub(r)},t.prototype.minus=function(r){return this.sub(r)},t.prototype.mul=function(r){if(typeof r=="number")return r<1e307&&r>-1e307?Ot(this.m*r,this.e):Ot(1e-307*this.m*r,this.e+307);var n=typeof r=="string"?new t(r):r;return Ot(this.m*n.m,this.e+n.e)},t.prototype.multiply=function(r){return this.mul(r)},t.prototype.times=function(r){return this.mul(r)},t.prototype.div=function(r){return this.mul(D(r).recip())},t.prototype.divide=function(r){return this.div(r)},t.prototype.divideBy=function(r){return this.div(r)},t.prototype.dividedBy=function(r){return this.div(r)},t.prototype.recip=function(){return Ot(1/this.m,-this.e)},t.prototype.reciprocal=function(){return this.recip()},t.prototype.reciprocate=function(){return this.recip()},t.prototype.cmp=function(r){var n=D(r);if(this.m===0){if(n.m===0)return 0;if(n.m<0)return 1;if(n.m>0)return-1}if(n.m===0){if(this.m<0)return-1;if(this.m>0)return 1}if(this.m>0)return n.m<0||this.e>n.e?1:this.en.m?1:this.m0||this.e>n.e?-1:this.en.m?1:this.m0:n.m===0?this.m<=0:this.e===n.e?this.m0?n.m>0&&this.e0||this.e>n.e},t.prototype.lte=function(r){return!this.gt(r)},t.prototype.gt=function(r){var n=D(r);return this.m===0?n.m<0:n.m===0?this.m>0:this.e===n.e?this.m>n.m:this.m>0?n.m<0||this.e>n.e:n.m<0&&this.e-1},t.prototype.greaterThan=function(r){return this.cmp(r)>0},t.prototype.decimalPlaces=function(){return this.dp()},t.prototype.dp=function(){if(!isFinite(this.mantissa))return NaN;if(this.exponent>=17)return 0;for(var r=this.mantissa,n=-this.exponent,a=1;Math.abs(Math.round(r*a)/a-r)>1e-10;)a*=10,n++;return n>0?n:0},Object.defineProperty(t,"MAX_VALUE",{get:function(){return bh},enumerable:!1,configurable:!0}),Object.defineProperty(t,"MIN_VALUE",{get:function(){return yh},enumerable:!1,configurable:!0}),Object.defineProperty(t,"NUMBER_MAX_VALUE",{get:function(){return vh},enumerable:!1,configurable:!0}),Object.defineProperty(t,"NUMBER_MIN_VALUE",{get:function(){return Ch},enumerable:!1,configurable:!0}),t}(),bh=ea(1,Ir),yh=ea(1,-Ir),vh=D(Number.MAX_VALUE),Ch=D(Number.MIN_VALUE),f=Pn;var z0=Ln(sc());function ft(t){"@babel/helpers - typeof";return ft=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(r){return typeof r}:function(r){return r&&typeof Symbol=="function"&&r.constructor===Symbol&&r!==Symbol.prototype?"symbol":typeof r},ft(t)}function Cr(t,r){if(!(t instanceof r))throw new TypeError("Cannot call a class as a function")}function Kd(t,r){if(ft(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,r||"default");if(ft(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return(r==="string"?String:Number)(t)}function ii(t){var r=Kd(t,"string");return ft(r)=="symbol"?r:r+""}function zd(t,r){for(var n=0;nt.length)&&(r=t.length);for(var n=0,a=Array(r);n1&&arguments[1]!==void 0?arguments[1]:{};Cr(this,t),this.init(r,n)}return wr(t,[{key:"init",value:function(n){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.prefix=a.prefix||"i18next:",this.logger=n||wh,this.options=a,this.debug=a.debug}},{key:"setDebug",value:function(n){this.debug=n}},{key:"log",value:function(){for(var n=arguments.length,a=new Array(n),s=0;s1?a-1:0),l=1;l-1?p.replace(/###/g,"."):p}function s(){return!t||typeof t=="string"}for(var l=typeof r!="string"?[].concat(r):r.split(".");l.length>1;){if(s())return{};var c=a(l.shift());!t[c]&&n&&(t[c]=new n),Object.prototype.hasOwnProperty.call(t,c)?t=t[c]:t={}}return s()?{}:{obj:t,k:a(l.shift())}}function ap(t,r,n){var a=lc(t,r,Object),s=a.obj,l=a.k;s[l]=n}function Th(t,r,n,a){var s=lc(t,r,Object),l=s.obj,c=s.k;l[c]=l[c]||[],a&&(l[c]=l[c].concat(n)),a||l[c].push(n)}function di(t,r){var n=lc(t,r),a=n.obj,s=n.k;if(a)return a[s]}function Sh(t,r,n){var a=di(t,n);return a!==void 0?a:di(r,n)}function vp(t,r,n){for(var a in r)a!=="__proto__"&&a!=="constructor"&&(a in t?typeof t[a]=="string"||t[a]instanceof String||typeof r[a]=="string"||r[a]instanceof String?n&&(t[a]=r[a]):vp(t[a],r[a],n):t[a]=r[a]);return t}function za(t){return t.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}var kh={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"};function Lh(t){return typeof t=="string"?t.replace(/[&<>"'\/]/g,function(r){return kh[r]}):t}var mi=typeof window<"u"&&window.navigator&&typeof window.navigator.userAgentData>"u"&&window.navigator.userAgent&&window.navigator.userAgent.indexOf("MSIE")>-1,Ph=[" ",",","?","!",";"];function Ah(t,r,n){r=r||"",n=n||"";var a=Ph.filter(function(p){return r.indexOf(p)<0&&n.indexOf(p)<0});if(a.length===0)return!0;var s=new RegExp("(".concat(a.map(function(p){return p==="?"?"\\?":p}).join("|"),")")),l=!s.test(t);if(!l){var c=t.indexOf(n);c>0&&!s.test(t.substring(0,c))&&(l=!0)}return l}function pi(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:".";if(t){if(t[r])return t[r];for(var a=r.split(n),s=t,l=0;ll+c;)c++,p=a.slice(l,l+c).join(n),g=s[p];if(g===void 0)return;if(g===null)return null;if(r.endsWith(p)){if(typeof g=="string")return g;if(p&&typeof g[p]=="string")return g[p]}var m=a.slice(l+c).join(n);return m?pi(g,m,n):void 0}s=s[a[l]]}return s}}function sp(t,r){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);r&&(a=a.filter(function(s){return Object.getOwnPropertyDescriptor(t,s).enumerable})),n.push.apply(n,a)}return n}function ci(t){for(var r=1;r"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(t){return!1}}var Uh=function(t){Qs(n,t);var r=Eh(n);function n(a){var s,l=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{ns:["translation"],defaultNS:"translation"};return Cr(this,n),s=r.call(this),mi&&An.call(Nr(s)),s.data=a||{},s.options=l,s.options.keySeparator===void 0&&(s.options.keySeparator="."),s.options.ignoreJSONStructure===void 0&&(s.options.ignoreJSONStructure=!0),s}return wr(n,[{key:"addNamespaces",value:function(s){this.options.ns.indexOf(s)<0&&this.options.ns.push(s)}},{key:"removeNamespaces",value:function(s){var l=this.options.ns.indexOf(s);l>-1&&this.options.ns.splice(l,1)}},{key:"getResource",value:function(s,l,c){var p=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},g=p.keySeparator!==void 0?p.keySeparator:this.options.keySeparator,m=p.ignoreJSONStructure!==void 0?p.ignoreJSONStructure:this.options.ignoreJSONStructure,h=[s,l];c&&typeof c!="string"&&(h=h.concat(c)),c&&typeof c=="string"&&(h=h.concat(g?c.split(g):c)),s.indexOf(".")>-1&&(h=s.split("."));var b=di(this.data,h);return b||!m||typeof c!="string"?b:pi(this.data&&this.data[s]&&this.data[s][l],c,g)}},{key:"addResource",value:function(s,l,c,p){var g=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{silent:!1},m=g.keySeparator!==void 0?g.keySeparator:this.options.keySeparator,h=[s,l];c&&(h=h.concat(m?c.split(m):c)),s.indexOf(".")>-1&&(h=s.split("."),p=l,l=h[1]),this.addNamespaces(l),ap(this.data,h,p),g.silent||this.emit("added",s,l,c,p)}},{key:"addResources",value:function(s,l,c){var p=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{silent:!1};for(var g in c)(typeof c[g]=="string"||Object.prototype.toString.apply(c[g])==="[object Array]")&&this.addResource(s,l,g,c[g],{silent:!0});p.silent||this.emit("added",s,l,c)}},{key:"addResourceBundle",value:function(s,l,c,p,g){var m=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{silent:!1},h=[s,l];s.indexOf(".")>-1&&(h=s.split("."),p=c,c=l,l=h[1]),this.addNamespaces(l);var b=di(this.data,h)||{};p?vp(b,c,g):b=ci(ci({},b),c),ap(this.data,h,b),m.silent||this.emit("added",s,l,c)}},{key:"removeResourceBundle",value:function(s,l){this.hasResourceBundle(s,l)&&delete this.data[s][l],this.removeNamespaces(l),this.emit("removed",s,l)}},{key:"hasResourceBundle",value:function(s,l){return this.getResource(s,l)!==void 0}},{key:"getResourceBundle",value:function(s,l){return l||(l=this.options.defaultNS),this.options.compatibilityAPI==="v1"?ci(ci({},{}),this.getResource(s,l)):this.getResource(s,l)}},{key:"getDataByLanguage",value:function(s){return this.data[s]}},{key:"hasLanguageSomeTranslations",value:function(s){var l=this.getDataByLanguage(s),c=l&&Object.keys(l)||[];return!!c.find(function(p){return l[p]&&Object.keys(l[p]).length>0})}},{key:"toJSON",value:function(){return this.data}}]),n}(An),Cp={processors:{},addPostProcessor:function(r){this.processors[r.name]=r},handle:function(r,n,a,s,l){var c=this;return r.forEach(function(p){c.processors[p]&&(n=c.processors[p].process(n,a,s,l))}),n}};function op(t,r){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);r&&(a=a.filter(function(s){return Object.getOwnPropertyDescriptor(t,s).enumerable})),n.push.apply(n,a)}return n}function ht(t){for(var r=1;r"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(t){return!1}}var ip={},lp=function(t){Qs(n,t);var r=Bh(n);function n(a){var s,l=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return Cr(this,n),s=r.call(this),mi&&An.call(Nr(s)),Mh(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],a,Nr(s)),s.options=l,s.options.keySeparator===void 0&&(s.options.keySeparator="."),s.logger=_r.create("translator"),s}return wr(n,[{key:"changeLanguage",value:function(s){s&&(this.language=s)}},{key:"exists",value:function(s){var l=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}};if(s==null)return!1;var c=this.resolve(s,l);return c&&c.res!==void 0}},{key:"extractFromKey",value:function(s,l){var c=l.nsSeparator!==void 0?l.nsSeparator:this.options.nsSeparator;c===void 0&&(c=":");var p=l.keySeparator!==void 0?l.keySeparator:this.options.keySeparator,g=l.ns||this.options.defaultNS||[],m=c&&s.indexOf(c)>-1,h=!this.options.userDefinedKeySeparator&&!l.keySeparator&&!this.options.userDefinedNsSeparator&&!l.nsSeparator&&!Ah(s,c,p);if(m&&!h){var b=s.match(this.interpolator.nestingRegexp);if(b&&b.length>0)return{key:s,namespaces:g};var C=s.split(c);(c!==p||c===p&&this.options.ns.indexOf(C[0])>-1)&&(g=C.shift()),s=C.join(p)}return typeof g=="string"&&(g=[g]),{key:s,namespaces:g}}},{key:"translate",value:function(s,l,c){var p=this;if(ft(l)!=="object"&&this.options.overloadTranslationOptionHandler&&(l=this.options.overloadTranslationOptionHandler(arguments)),ft(l)==="object"&&(l=ht({},l)),l||(l={}),s==null)return"";Array.isArray(s)||(s=[String(s)]);var g=l.returnDetails!==void 0?l.returnDetails:this.options.returnDetails,m=l.keySeparator!==void 0?l.keySeparator:this.options.keySeparator,h=this.extractFromKey(s[s.length-1],l),b=h.key,C=h.namespaces,v=C[C.length-1],x=l.lng||this.language,B=l.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if(x&&x.toLowerCase()==="cimode"){if(B){var U=l.nsSeparator||this.options.nsSeparator;return g?{res:"".concat(v).concat(U).concat(b),usedKey:b,exactUsedKey:b,usedLng:x,usedNS:v}:"".concat(v).concat(U).concat(b)}return g?{res:b,usedKey:b,exactUsedKey:b,usedLng:x,usedNS:v}:b}var k=this.resolve(s,l),L=k&&k.res,E=k&&k.usedKey||b,T=k&&k.exactUsedKey||b,S=Object.prototype.toString.apply(L),I=["[object Number]","[object Function]","[object RegExp]"],N=l.joinArrays!==void 0?l.joinArrays:this.options.joinArrays,X=!this.i18nFormat||this.i18nFormat.handleAsObject,re=typeof L!="string"&&typeof L!="boolean"&&typeof L!="number";if(X&&L&&re&&I.indexOf(S)<0&&!(typeof N=="string"&&S==="[object Array]")){if(!l.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");var w=this.options.returnedObjectHandler?this.options.returnedObjectHandler(E,L,ht(ht({},l),{},{ns:C})):"key '".concat(b," (").concat(this.language,")' returned an object instead of string.");return g?(k.res=w,k):w}if(m){var H=S==="[object Array]",J=H?[]:{},Te=H?T:E;for(var lt in L)if(Object.prototype.hasOwnProperty.call(L,lt)){var gt="".concat(Te).concat(m).concat(lt);J[lt]=this.translate(gt,ht(ht({},l),{joinArrays:!1,ns:C})),J[lt]===gt&&(J[lt]=L[lt])}L=J}}else if(X&&typeof N=="string"&&S==="[object Array]")L=L.join(N),L&&(L=this.extendTranslation(L,s,l,c));else{var Ct=!1,$t=!1,Yt=l.count!==void 0&&typeof l.count!="string",_t=n.hasDefaultValue(l),ce=Yt?this.pluralResolver.getSuffix(x,l.count,l):"",z=l["defaultValue".concat(ce)]||l.defaultValue;!this.isValidLookup(L)&&_t&&(Ct=!0,L=z),this.isValidLookup(L)||($t=!0,L=b);var Z=l.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey,se=Z&&$t?void 0:L,ne=_t&&z!==L&&this.options.updateMissing;if($t||Ct||ne){if(this.logger.log(ne?"updateKey":"missingKey",x,v,b,ne?z:L),m){var he=this.resolve(b,ht(ht({},l),{},{keySeparator:!1}));he&&he.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}var Fe=[],wt=this.languageUtils.getFallbackCodes(this.options.fallbackLng,l.lng||this.language);if(this.options.saveMissingTo==="fallback"&&wt&&wt[0])for(var A=0;A1&&arguments[1]!==void 0?arguments[1]:{},p,g,m,h,b;return typeof s=="string"&&(s=[s]),s.forEach(function(C){if(!l.isValidLookup(p)){var v=l.extractFromKey(C,c),x=v.key;g=x;var B=v.namespaces;l.options.fallbackNS&&(B=B.concat(l.options.fallbackNS));var U=c.count!==void 0&&typeof c.count!="string",k=U&&!c.ordinal&&c.count===0&&l.pluralResolver.shouldUseIntlApi(),L=c.context!==void 0&&(typeof c.context=="string"||typeof c.context=="number")&&c.context!=="",E=c.lngs?c.lngs:l.languageUtils.toResolveHierarchy(c.lng||l.language,c.fallbackLng);B.forEach(function(T){l.isValidLookup(p)||(b=T,!ip["".concat(E[0],"-").concat(T)]&&l.utils&&l.utils.hasLoadedNamespace&&!l.utils.hasLoadedNamespace(b)&&(ip["".concat(E[0],"-").concat(T)]=!0,l.logger.warn('key "'.concat(g,'" for languages "').concat(E.join(", "),`" won't get resolved as namespace "`).concat(b,'" was not yet loaded'),"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),E.forEach(function(S){if(!l.isValidLookup(p)){h=S;var I=[x];if(l.i18nFormat&&l.i18nFormat.addLookupKeys)l.i18nFormat.addLookupKeys(I,x,S,T,c);else{var N;U&&(N=l.pluralResolver.getSuffix(S,c.count,c));var X="".concat(l.options.pluralSeparator,"zero");if(U&&(I.push(x+N),k&&I.push(x+X)),L){var re="".concat(x).concat(l.options.contextSeparator).concat(c.context);I.push(re),U&&(I.push(re+N),k&&I.push(re+X))}}for(var w;w=I.pop();)l.isValidLookup(p)||(m=w,p=l.getResource(S,T,w,c))}}))})}}),{res:p,usedKey:g,exactUsedKey:m,usedLng:h,usedNS:b}}},{key:"isValidLookup",value:function(s){return s!==void 0&&!(!this.options.returnNull&&s===null)&&!(!this.options.returnEmptyString&&s==="")}},{key:"getResource",value:function(s,l,c){var p=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};return this.i18nFormat&&this.i18nFormat.getResource?this.i18nFormat.getResource(s,l,c,p):this.resourceStore.getResource(s,l,c,p)}}],[{key:"hasDefaultValue",value:function(s){var l="defaultValue";for(var c in s)if(Object.prototype.hasOwnProperty.call(s,c)&&l===c.substring(0,l.length)&&s[c]!==void 0)return!0;return!1}}]),n}(An);function ic(t){return t.charAt(0).toUpperCase()+t.slice(1)}var cp=function(){function t(r){Cr(this,t),this.options=r,this.supportedLngs=this.options.supportedLngs||!1,this.logger=_r.create("languageUtils")}return wr(t,[{key:"getScriptPartFromCode",value:function(n){if(!n||n.indexOf("-")<0)return null;var a=n.split("-");return a.length===2||(a.pop(),a[a.length-1].toLowerCase()==="x")?null:this.formatLanguageCode(a.join("-"))}},{key:"getLanguagePartFromCode",value:function(n){if(!n||n.indexOf("-")<0)return n;var a=n.split("-");return this.formatLanguageCode(a[0])}},{key:"formatLanguageCode",value:function(n){if(typeof n=="string"&&n.indexOf("-")>-1){var a=["hans","hant","latn","cyrl","cans","mong","arab"],s=n.split("-");return this.options.lowerCaseLng?s=s.map(function(l){return l.toLowerCase()}):s.length===2?(s[0]=s[0].toLowerCase(),s[1]=s[1].toUpperCase(),a.indexOf(s[1].toLowerCase())>-1&&(s[1]=ic(s[1].toLowerCase()))):s.length===3&&(s[0]=s[0].toLowerCase(),s[1].length===2&&(s[1]=s[1].toUpperCase()),s[0]!=="sgn"&&s[2].length===2&&(s[2]=s[2].toUpperCase()),a.indexOf(s[1].toLowerCase())>-1&&(s[1]=ic(s[1].toLowerCase())),a.indexOf(s[2].toLowerCase())>-1&&(s[2]=ic(s[2].toLowerCase()))),s.join("-")}return this.options.cleanCode||this.options.lowerCaseLng?n.toLowerCase():n}},{key:"isSupportedCode",value:function(n){return(this.options.load==="languageOnly"||this.options.nonExplicitSupportedLngs)&&(n=this.getLanguagePartFromCode(n)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(n)>-1}},{key:"getBestMatchFromCodes",value:function(n){var a=this;if(!n)return null;var s;return n.forEach(function(l){if(!s){var c=a.formatLanguageCode(l);(!a.options.supportedLngs||a.isSupportedCode(c))&&(s=c)}}),!s&&this.options.supportedLngs&&n.forEach(function(l){if(!s){var c=a.getLanguagePartFromCode(l);if(a.isSupportedCode(c))return s=c;s=a.options.supportedLngs.find(function(p){if(p===c)return p;if(!(p.indexOf("-")<0&&c.indexOf("-")<0)&&p.indexOf(c)===0)return p})}}),s||(s=this.getFallbackCodes(this.options.fallbackLng)[0]),s}},{key:"getFallbackCodes",value:function(n,a){if(!n)return[];if(typeof n=="function"&&(n=n(a)),typeof n=="string"&&(n=[n]),Object.prototype.toString.apply(n)==="[object Array]")return n;if(!a)return n.default||[];var s=n[a];return s||(s=n[this.getScriptPartFromCode(a)]),s||(s=n[this.formatLanguageCode(a)]),s||(s=n[this.getLanguagePartFromCode(a)]),s||(s=n.default),s||[]}},{key:"toResolveHierarchy",value:function(n,a){var s=this,l=this.getFallbackCodes(a||this.options.fallbackLng||[],n),c=[],p=function(m){m&&(s.isSupportedCode(m)?c.push(m):s.logger.warn("rejecting language code not found in supportedLngs: ".concat(m)))};return typeof n=="string"&&n.indexOf("-")>-1?(this.options.load!=="languageOnly"&&p(this.formatLanguageCode(n)),this.options.load!=="languageOnly"&&this.options.load!=="currentOnly"&&p(this.getScriptPartFromCode(n)),this.options.load!=="currentOnly"&&p(this.getLanguagePartFromCode(n))):typeof n=="string"&&p(this.formatLanguageCode(n)),l.forEach(function(g){c.indexOf(g)<0&&p(s.formatLanguageCode(g))}),c}}]),t}(),Ih=[{lngs:["ach","ak","am","arn","br","fil","gun","ln","mfe","mg","mi","oc","pt","pt-BR","tg","tl","ti","tr","uz","wa"],nr:[1,2],fc:1},{lngs:["af","an","ast","az","bg","bn","ca","da","de","dev","el","en","eo","es","et","eu","fi","fo","fur","fy","gl","gu","ha","hi","hu","hy","ia","it","kk","kn","ku","lb","mai","ml","mn","mr","nah","nap","nb","ne","nl","nn","no","nso","pa","pap","pms","ps","pt-PT","rm","sco","se","si","so","son","sq","sv","sw","ta","te","tk","ur","yo"],nr:[1,2],fc:2},{lngs:["ay","bo","cgg","fa","ht","id","ja","jbo","ka","km","ko","ky","lo","ms","sah","su","th","tt","ug","vi","wo","zh"],nr:[1],fc:3},{lngs:["be","bs","cnr","dz","hr","ru","sr","uk"],nr:[1,2,5],fc:4},{lngs:["ar"],nr:[0,1,2,3,11,100],fc:5},{lngs:["cs","sk"],nr:[1,2,5],fc:6},{lngs:["csb","pl"],nr:[1,2,5],fc:7},{lngs:["cy"],nr:[1,2,3,8],fc:8},{lngs:["fr"],nr:[1,2],fc:9},{lngs:["ga"],nr:[1,2,3,7,11],fc:10},{lngs:["gd"],nr:[1,2,3,20],fc:11},{lngs:["is"],nr:[1,2],fc:12},{lngs:["jv"],nr:[0,1],fc:13},{lngs:["kw"],nr:[1,2,3,4],fc:14},{lngs:["lt"],nr:[1,2,10],fc:15},{lngs:["lv"],nr:[1,2,0],fc:16},{lngs:["mk"],nr:[1,2],fc:17},{lngs:["mnk"],nr:[0,1,2],fc:18},{lngs:["mt"],nr:[1,2,11,20],fc:19},{lngs:["or"],nr:[2,1],fc:2},{lngs:["ro"],nr:[1,2,20],fc:20},{lngs:["sl"],nr:[5,1,2,3],fc:21},{lngs:["he","iw"],nr:[1,2,20,21],fc:22}],Nh={1:function(r){return+(r>1)},2:function(r){return+(r!=1)},3:function(r){return 0},4:function(r){return r%10==1&&r%100!=11?0:r%10>=2&&r%10<=4&&(r%100<10||r%100>=20)?1:2},5:function(r){return r==0?0:r==1?1:r==2?2:r%100>=3&&r%100<=10?3:r%100>=11?4:5},6:function(r){return r==1?0:r>=2&&r<=4?1:2},7:function(r){return r==1?0:r%10>=2&&r%10<=4&&(r%100<10||r%100>=20)?1:2},8:function(r){return r==1?0:r==2?1:r!=8&&r!=11?2:3},9:function(r){return+(r>=2)},10:function(r){return r==1?0:r==2?1:r<7?2:r<11?3:4},11:function(r){return r==1||r==11?0:r==2||r==12?1:r>2&&r<20?2:3},12:function(r){return+(r%10!=1||r%100==11)},13:function(r){return+(r!==0)},14:function(r){return r==1?0:r==2?1:r==3?2:3},15:function(r){return r%10==1&&r%100!=11?0:r%10>=2&&(r%100<10||r%100>=20)?1:2},16:function(r){return r%10==1&&r%100!=11?0:r!==0?1:2},17:function(r){return r==1||r%10==1&&r%100!=11?0:1},18:function(r){return r==0?0:r==1?1:2},19:function(r){return r==1?0:r==0||r%100>1&&r%100<11?1:r%100>10&&r%100<20?2:3},20:function(r){return r==1?0:r==0||r%100>0&&r%100<20?1:2},21:function(r){return r%100==1?1:r%100==2?2:r%100==3||r%100==4?3:0},22:function(r){return r==1?0:r==2?1:(r<0||r>10)&&r%10==0?2:3}},$h=["v1","v2","v3"],up={zero:0,one:1,two:2,few:3,many:4,other:5};function _h(){var t={};return Ih.forEach(function(r){r.lngs.forEach(function(n){t[n]={numbers:r.nr,plurals:Nh[r.fc]}})}),t}var Dh=function(){function t(r){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};Cr(this,t),this.languageUtils=r,this.options=n,this.logger=_r.create("pluralResolver"),(!this.options.compatibilityJSON||this.options.compatibilityJSON==="v4")&&(typeof Intl>"u"||!Intl.PluralRules)&&(this.options.compatibilityJSON="v3",this.logger.error("Your environment seems not to be Intl API compatible, use an Intl.PluralRules polyfill. Will fallback to the compatibilityJSON v3 format handling.")),this.rules=_h()}return wr(t,[{key:"addRule",value:function(n,a){this.rules[n]=a}},{key:"getRule",value:function(n){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(this.shouldUseIntlApi())try{return new Intl.PluralRules(n,{type:a.ordinal?"ordinal":"cardinal"})}catch(s){return}return this.rules[n]||this.rules[this.languageUtils.getLanguagePartFromCode(n)]}},{key:"needsPlural",value:function(n){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},s=this.getRule(n,a);return this.shouldUseIntlApi()?s&&s.resolvedOptions().pluralCategories.length>1:s&&s.numbers.length>1}},{key:"getPluralFormsOfKey",value:function(n,a){var s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return this.getSuffixes(n,s).map(function(l){return"".concat(a).concat(l)})}},{key:"getSuffixes",value:function(n){var a=this,s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},l=this.getRule(n,s);return l?this.shouldUseIntlApi()?l.resolvedOptions().pluralCategories.sort(function(c,p){return up[c]-up[p]}).map(function(c){return"".concat(a.options.prepend).concat(c)}):l.numbers.map(function(c){return a.getSuffix(n,c,s)}):[]}},{key:"getSuffix",value:function(n,a){var s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},l=this.getRule(n,s);return l?this.shouldUseIntlApi()?"".concat(this.options.prepend).concat(l.select(a)):this.getSuffixRetroCompatible(l,a):(this.logger.warn("no plural rule found for: ".concat(n)),"")}},{key:"getSuffixRetroCompatible",value:function(n,a){var s=this,l=n.noAbs?n.plurals(a):n.plurals(Math.abs(a)),c=n.numbers[l];this.options.simplifyPluralSuffix&&n.numbers.length===2&&n.numbers[0]===1&&(c===2?c="plural":c===1&&(c=""));var p=function(){return s.options.prepend&&c.toString()?s.options.prepend+c.toString():c.toString()};return this.options.compatibilityJSON==="v1"?c===1?"":typeof c=="number"?"_plural_".concat(c.toString()):p():this.options.compatibilityJSON==="v2"||this.options.simplifyPluralSuffix&&n.numbers.length===2&&n.numbers[0]===1?p():this.options.prepend&&l.toString()?this.options.prepend+l.toString():l.toString()}},{key:"shouldUseIntlApi",value:function(){return!$h.includes(this.options.compatibilityJSON)}}]),t}();function dp(t,r){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);r&&(a=a.filter(function(s){return Object.getOwnPropertyDescriptor(t,s).enumerable})),n.push.apply(n,a)}return n}function Mr(t){for(var r=1;r3&&arguments[3]!==void 0?arguments[3]:".",s=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!0,l=Sh(t,r,n);return!l&&s&&typeof n=="string"&&(l=pi(t,n,a),l===void 0&&(l=pi(r,n,a))),l}var Gh=function(){function t(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};Cr(this,t),this.logger=_r.create("interpolator"),this.options=r,this.format=r.interpolation&&r.interpolation.format||function(n){return n},this.init(r)}return wr(t,[{key:"init",value:function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};n.interpolation||(n.interpolation={escapeValue:!0});var a=n.interpolation;this.escape=a.escape!==void 0?a.escape:Lh,this.escapeValue=a.escapeValue!==void 0?a.escapeValue:!0,this.useRawValueToEscape=a.useRawValueToEscape!==void 0?a.useRawValueToEscape:!1,this.prefix=a.prefix?za(a.prefix):a.prefixEscaped||"{{",this.suffix=a.suffix?za(a.suffix):a.suffixEscaped||"}}",this.formatSeparator=a.formatSeparator?a.formatSeparator:a.formatSeparator||",",this.unescapePrefix=a.unescapeSuffix?"":a.unescapePrefix||"-",this.unescapeSuffix=this.unescapePrefix?"":a.unescapeSuffix||"",this.nestingPrefix=a.nestingPrefix?za(a.nestingPrefix):a.nestingPrefixEscaped||za("$t("),this.nestingSuffix=a.nestingSuffix?za(a.nestingSuffix):a.nestingSuffixEscaped||za(")"),this.nestingOptionsSeparator=a.nestingOptionsSeparator?a.nestingOptionsSeparator:a.nestingOptionsSeparator||",",this.maxReplaces=a.maxReplaces?a.maxReplaces:1e3,this.alwaysFormat=a.alwaysFormat!==void 0?a.alwaysFormat:!1,this.resetRegExp()}},{key:"reset",value:function(){this.options&&this.init(this.options)}},{key:"resetRegExp",value:function(){var n="".concat(this.prefix,"(.+?)").concat(this.suffix);this.regexp=new RegExp(n,"g");var a="".concat(this.prefix).concat(this.unescapePrefix,"(.+?)").concat(this.unescapeSuffix).concat(this.suffix);this.regexpUnescape=new RegExp(a,"g");var s="".concat(this.nestingPrefix,"(.+?)").concat(this.nestingSuffix);this.nestingRegexp=new RegExp(s,"g")}},{key:"interpolate",value:function(n,a,s,l){var c=this,p,g,m,h=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{};function b(U){return U.replace(/\$/g,"$$$$")}var C=function(k){if(k.indexOf(c.formatSeparator)<0){var L=pp(a,h,k,c.options.keySeparator,c.options.ignoreJSONStructure);return c.alwaysFormat?c.format(L,void 0,s,Mr(Mr(Mr({},l),a),{},{interpolationkey:k})):L}var E=k.split(c.formatSeparator),T=E.shift().trim(),S=E.join(c.formatSeparator).trim();return c.format(pp(a,h,T,c.options.keySeparator,c.options.ignoreJSONStructure),S,s,Mr(Mr(Mr({},l),a),{},{interpolationkey:T}))};this.resetRegExp();var v=l&&l.missingInterpolationHandler||this.options.missingInterpolationHandler,x=l&&l.interpolation&&l.interpolation.skipOnVariables!==void 0?l.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables,B=[{regex:this.regexpUnescape,safeValue:function(k){return b(k)}},{regex:this.regexp,safeValue:function(k){return c.escapeValue?b(c.escape(k)):b(k)}}];return B.forEach(function(U){for(m=0;p=U.regex.exec(n);){var k=p[1].trim();if(g=C(k),g===void 0)if(typeof v=="function"){var L=v(n,p,l);g=typeof L=="string"?L:""}else if(l&&Object.prototype.hasOwnProperty.call(l,k))g="";else if(x){g=p[0];continue}else c.logger.warn("missed to pass in variable ".concat(k," for interpolating ").concat(n)),g="";else typeof g!="string"&&!c.useRawValueToEscape&&(g=np(g));var E=U.safeValue(g);if(n=n.replace(p[0],E),x?(U.regex.lastIndex+=g.length,U.regex.lastIndex-=p[0].length):U.regex.lastIndex=0,m++,m>=c.maxReplaces)break}}),n}},{key:"nest",value:function(n,a){var s=this,l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},c,p,g;function m(v,x){var B=this.nestingOptionsSeparator;if(v.indexOf(B)<0)return v;var U=v.split(new RegExp("".concat(B,"[ ]*{"))),k="{".concat(U[1]);v=U[0],k=this.interpolate(k,g);var L=k.match(/'/g),E=k.match(/"/g);(L&&L.length%2===0&&!E||E.length%2!==0)&&(k=k.replace(/'/g,'"'));try{g=JSON.parse(k),x&&(g=Mr(Mr({},x),g))}catch(T){return this.logger.warn("failed parsing options string in nesting for key ".concat(v),T),"".concat(v).concat(B).concat(k)}return delete g.defaultValue,v}for(;c=this.nestingRegexp.exec(n);){var h=[];g=Mr({},l),g=g.replace&&typeof g.replace!="string"?g.replace:g,g.applyPostProcessor=!1,delete g.defaultValue;var b=!1;if(c[0].indexOf(this.formatSeparator)!==-1&&!/{.*}/.test(c[1])){var C=c[1].split(this.formatSeparator).map(function(v){return v.trim()});c[1]=C.shift(),h=C,b=!0}if(p=a(m.call(this,c[1].trim(),g),g),p&&c[0]===n&&typeof p!="string")return p;typeof p!="string"&&(p=np(p)),p||(this.logger.warn("missed to resolve ".concat(c[1]," for nesting ").concat(n)),p=""),b&&(p=h.reduce(function(v,x){return s.format(v,x,l.lng,Mr(Mr({},l),{},{interpolationkey:c[1].trim()}))},p.trim())),n=n.replace(c[0],p),this.regexp.lastIndex=0}return n}}]),t}();function gp(t,r){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);r&&(a=a.filter(function(s){return Object.getOwnPropertyDescriptor(t,s).enumerable})),n.push.apply(n,a)}return n}function tn(t){for(var r=1;r-1){var a=t.split("(");r=a[0].toLowerCase().trim();var s=a[1].substring(0,a[1].length-1);if(r==="currency"&&s.indexOf(":")<0)n.currency||(n.currency=s.trim());else if(r==="relativetime"&&s.indexOf(":")<0)n.range||(n.range=s.trim());else{var l=s.split(";");l.forEach(function(c){if(c){var p=c.split(":"),g=ep(p),m=g[0],h=g.slice(1),b=h.join(":").trim().replace(/^'+|'+$/g,"");n[m.trim()]||(n[m.trim()]=b),b==="false"&&(n[m.trim()]=!1),b==="true"&&(n[m.trim()]=!0),isNaN(b)||(n[m.trim()]=parseInt(b,10))}})}}return{formatName:r,formatOptions:n}}function Xa(t){var r={};return function(a,s,l){var c=s+JSON.stringify(l),p=r[c];return p||(p=t(s,l),r[c]=p),p(a)}}var Fh=function(){function t(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};Cr(this,t),this.logger=_r.create("formatter"),this.options=r,this.formats={number:Xa(function(n,a){var s=new Intl.NumberFormat(n,tn({},a));return function(l){return s.format(l)}}),currency:Xa(function(n,a){var s=new Intl.NumberFormat(n,tn(tn({},a),{},{style:"currency"}));return function(l){return s.format(l)}}),datetime:Xa(function(n,a){var s=new Intl.DateTimeFormat(n,tn({},a));return function(l){return s.format(l)}}),relativetime:Xa(function(n,a){var s=new Intl.RelativeTimeFormat(n,tn({},a));return function(l){return s.format(l,a.range||"day")}}),list:Xa(function(n,a){var s=new Intl.ListFormat(n,tn({},a));return function(l){return s.format(l)}})},this.init(r)}return wr(t,[{key:"init",value:function(n){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}},s=a.interpolation;this.formatSeparator=s.formatSeparator?s.formatSeparator:s.formatSeparator||","}},{key:"add",value:function(n,a){this.formats[n.toLowerCase().trim()]=a}},{key:"addCached",value:function(n,a){this.formats[n.toLowerCase().trim()]=Xa(a)}},{key:"format",value:function(n,a,s){var l=this,c=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},p=a.split(this.formatSeparator),g=p.reduce(function(m,h){var b=Hh(h),C=b.formatName,v=b.formatOptions;if(l.formats[C]){var x=m;try{var B=c&&c.formatParams&&c.formatParams[c.interpolationkey]||{},U=B.locale||B.lng||c.locale||c.lng||s;x=l.formats[C](m,U,tn(tn(tn({},v),c),B))}catch(k){l.logger.warn(k)}return x}else l.logger.warn("there was no format function for ".concat(C));return m},n);return g}}]),t}();function mp(t,r){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);r&&(a=a.filter(function(s){return Object.getOwnPropertyDescriptor(t,s).enumerable})),n.push.apply(n,a)}return n}function fp(t){for(var r=1;r"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(t){return!1}}function jh(t,r){t.pending[r]!==void 0&&(delete t.pending[r],t.pendingCount--)}var Vh=function(t){Qs(n,t);var r=Qh(n);function n(a,s,l){var c,p=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};return Cr(this,n),c=r.call(this),mi&&An.call(Nr(c)),c.backend=a,c.store=s,c.services=l,c.languageUtils=l.languageUtils,c.options=p,c.logger=_r.create("backendConnector"),c.waitingReads=[],c.maxParallelReads=p.maxParallelReads||10,c.readingCalls=0,c.maxRetries=p.maxRetries>=0?p.maxRetries:5,c.retryTimeout=p.retryTimeout>=1?p.retryTimeout:350,c.state={},c.queue=[],c.backend&&c.backend.init&&c.backend.init(l,p.backend,p),c}return wr(n,[{key:"queueLoad",value:function(s,l,c,p){var g=this,m={},h={},b={},C={};return s.forEach(function(v){var x=!0;l.forEach(function(B){var U="".concat(v,"|").concat(B);!c.reload&&g.store.hasResourceBundle(v,B)?g.state[U]=2:g.state[U]<0||(g.state[U]===1?h[U]===void 0&&(h[U]=!0):(g.state[U]=1,x=!1,h[U]===void 0&&(h[U]=!0),m[U]===void 0&&(m[U]=!0),C[B]===void 0&&(C[B]=!0)))}),x||(b[v]=!0)}),(Object.keys(m).length||Object.keys(h).length)&&this.queue.push({pending:h,pendingCount:Object.keys(h).length,loaded:{},errors:[],callback:p}),{toLoad:Object.keys(m),pending:Object.keys(h),toLoadLanguages:Object.keys(b),toLoadNamespaces:Object.keys(C)}}},{key:"loaded",value:function(s,l,c){var p=s.split("|"),g=p[0],m=p[1];l&&this.emit("failedLoading",g,m,l),c&&this.store.addResourceBundle(g,m,c),this.state[s]=l?-1:2;var h={};this.queue.forEach(function(b){Th(b.loaded,[g],m),jh(b,s),l&&b.errors.push(l),b.pendingCount===0&&!b.done&&(Object.keys(b.loaded).forEach(function(C){h[C]||(h[C]={});var v=b.loaded[C];v.length&&v.forEach(function(x){h[C][x]===void 0&&(h[C][x]=!0)})}),b.done=!0,b.errors.length?b.callback(b.errors):b.callback())}),this.emit("loaded",h),this.queue=this.queue.filter(function(b){return!b.done})}},{key:"read",value:function(s,l,c){var p=this,g=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0,m=arguments.length>4&&arguments[4]!==void 0?arguments[4]:this.retryTimeout,h=arguments.length>5?arguments[5]:void 0;if(!s.length)return h(null,{});if(this.readingCalls>=this.maxParallelReads){this.waitingReads.push({lng:s,ns:l,fcName:c,tried:g,wait:m,callback:h});return}this.readingCalls++;var b=function(B,U){if(p.readingCalls--,p.waitingReads.length>0){var k=p.waitingReads.shift();p.read(k.lng,k.ns,k.fcName,k.tried,k.wait,k.callback)}if(B&&U&&g2&&arguments[2]!==void 0?arguments[2]:{},g=arguments.length>3?arguments[3]:void 0;if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),g&&g();typeof s=="string"&&(s=this.languageUtils.toResolveHierarchy(s)),typeof l=="string"&&(l=[l]);var m=this.queueLoad(s,l,p,g);if(!m.toLoad.length)return m.pending.length||g(),null;m.toLoad.forEach(function(h){c.loadOne(h)})}},{key:"load",value:function(s,l,c){this.prepareLoading(s,l,{},c)}},{key:"reload",value:function(s,l,c){this.prepareLoading(s,l,{reload:!0},c)}},{key:"loadOne",value:function(s){var l=this,c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",p=s.split("|"),g=p[0],m=p[1];this.read(g,m,"read",void 0,void 0,function(h,b){h&&l.logger.warn("".concat(c,"loading namespace ").concat(m," for language ").concat(g," failed"),h),!h&&b&&l.logger.log("".concat(c,"loaded namespace ").concat(m," for language ").concat(g),b),l.loaded(s,h,b)})}},{key:"saveMissing",value:function(s,l,c,p,g){var m=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{},h=arguments.length>6&&arguments[6]!==void 0?arguments[6]:function(){};if(this.services.utils&&this.services.utils.hasLoadedNamespace&&!this.services.utils.hasLoadedNamespace(l)){this.logger.warn('did not save key "'.concat(c,'" as the namespace "').concat(l,'" was not yet loaded'),"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!");return}if(!(c==null||c==="")){if(this.backend&&this.backend.create){var b=fp(fp({},m),{},{isUpdate:g}),C=this.backend.create.bind(this.backend);if(C.length<6)try{var v;C.length===5?v=C(s,l,c,p,b):v=C(s,l,c,p),v&&typeof v.then=="function"?v.then(function(x){return h(null,x)}).catch(h):h(null,v)}catch(x){h(x)}else C(s,l,c,p,h,b)}!s||!s[0]||this.store.addResource(s[0],l,c,p)}}}]),n}(An);function hp(){return{debug:!1,initImmediate:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!0,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:function(r){var n={};if(ft(r[1])==="object"&&(n=r[1]),typeof r[1]=="string"&&(n.defaultValue=r[1]),typeof r[2]=="string"&&(n.tDescription=r[2]),ft(r[2])==="object"||ft(r[3])==="object"){var a=r[3]||r[2];Object.keys(a).forEach(function(s){n[s]=a[s]})}return n},interpolation:{escapeValue:!0,format:function(r,n,a,s){return r},prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0}}}function bp(t){return typeof t.ns=="string"&&(t.ns=[t.ns]),typeof t.fallbackLng=="string"&&(t.fallbackLng=[t.fallbackLng]),typeof t.fallbackNS=="string"&&(t.fallbackNS=[t.fallbackNS]),t.supportedLngs&&t.supportedLngs.indexOf("cimode")<0&&(t.supportedLngs=t.supportedLngs.concat(["cimode"])),t}function yp(t,r){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);r&&(a=a.filter(function(s){return Object.getOwnPropertyDescriptor(t,s).enumerable})),n.push.apply(n,a)}return n}function $r(t){for(var r=1;r"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(t){return!1}}function ui(){}function zh(t){var r=Object.getOwnPropertyNames(Object.getPrototypeOf(t));r.forEach(function(n){typeof t[n]=="function"&&(t[n]=t[n].bind(t))})}var gi=function(t){Qs(n,t);var r=Wh(n);function n(){var a,s=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},l=arguments.length>1?arguments[1]:void 0;if(Cr(this,n),a=r.call(this),mi&&An.call(Nr(a)),a.options=bp(s),a.services={},a.logger=_r,a.modules={external:[]},zh(Nr(a)),l&&!a.isInitialized&&!s.isClone){if(!a.options.initImmediate)return a.init(s,l),Ka(a,Nr(a));setTimeout(function(){a.init(s,l)},0)}return a}return wr(n,[{key:"init",value:function(){var s=this,l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},c=arguments.length>1?arguments[1]:void 0;typeof l=="function"&&(c=l,l={}),!l.defaultNS&&l.defaultNS!==!1&&l.ns&&(typeof l.ns=="string"?l.defaultNS=l.ns:l.ns.indexOf("translation")<0&&(l.defaultNS=l.ns[0]));var p=hp();this.options=$r($r($r({},p),this.options),bp(l)),this.options.compatibilityAPI!=="v1"&&(this.options.interpolation=$r($r({},p.interpolation),this.options.interpolation)),l.keySeparator!==void 0&&(this.options.userDefinedKeySeparator=l.keySeparator),l.nsSeparator!==void 0&&(this.options.userDefinedNsSeparator=l.nsSeparator);function g(k){return k?typeof k=="function"?new k:k:null}if(!this.options.isClone){this.modules.logger?_r.init(g(this.modules.logger),this.options):_r.init(null,this.options);var m;this.modules.formatter?m=this.modules.formatter:typeof Intl<"u"&&(m=Fh);var h=new cp(this.options);this.store=new Uh(this.options.resources,this.options);var b=this.services;b.logger=_r,b.resourceStore=this.store,b.languageUtils=h,b.pluralResolver=new Dh(h,{prepend:this.options.pluralSeparator,compatibilityJSON:this.options.compatibilityJSON,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),m&&(!this.options.interpolation.format||this.options.interpolation.format===p.interpolation.format)&&(b.formatter=g(m),b.formatter.init(b,this.options),this.options.interpolation.format=b.formatter.format.bind(b.formatter)),b.interpolator=new Gh(this.options),b.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},b.backendConnector=new Vh(g(this.modules.backend),b.resourceStore,b,this.options),b.backendConnector.on("*",function(k){for(var L=arguments.length,E=new Array(L>1?L-1:0),T=1;T1?L-1:0),T=1;T0&&C[0]!=="dev"&&(this.options.lng=C[0])}!this.services.languageDetector&&!this.options.lng&&this.logger.warn("init: no languageDetector is used and no lng is defined");var v=["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"];v.forEach(function(k){s[k]=function(){var L;return(L=s.store)[k].apply(L,arguments)}});var x=["addResource","addResources","addResourceBundle","removeResourceBundle"];x.forEach(function(k){s[k]=function(){var L;return(L=s.store)[k].apply(L,arguments),s}});var B=qs(),U=function(){var L=function(T,S){s.isInitialized&&!s.initializedStoreOnce&&s.logger.warn("init: i18next is already initialized. You should call init just once!"),s.isInitialized=!0,s.options.isClone||s.logger.log("initialized",s.options),s.emit("initialized",s.options),B.resolve(S),c(T,S)};if(s.languages&&s.options.compatibilityAPI!=="v1"&&!s.isInitialized)return L(null,s.t.bind(s));s.changeLanguage(s.options.lng,L)};return this.options.resources||!this.options.initImmediate?U():setTimeout(U,0),B}},{key:"loadResources",value:function(s){var l=this,c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:ui,p=c,g=typeof s=="string"?s:this.language;if(typeof s=="function"&&(p=s),!this.options.resources||this.options.partialBundledLanguages){if(g&&g.toLowerCase()==="cimode")return p();var m=[],h=function(v){if(v){var x=l.services.languageUtils.toResolveHierarchy(v);x.forEach(function(B){m.indexOf(B)<0&&m.push(B)})}};if(g)h(g);else{var b=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);b.forEach(function(C){return h(C)})}this.options.preload&&this.options.preload.forEach(function(C){return h(C)}),this.services.backendConnector.load(m,this.options.ns,function(C){!C&&!l.resolvedLanguage&&l.language&&l.setResolvedLanguage(l.language),p(C)})}else p(null)}},{key:"reloadResources",value:function(s,l,c){var p=qs();return s||(s=this.languages),l||(l=this.options.ns),c||(c=ui),this.services.backendConnector.reload(s,l,function(g){p.resolve(),c(g)}),p}},{key:"use",value:function(s){if(!s)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!s.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return s.type==="backend"&&(this.modules.backend=s),(s.type==="logger"||s.log&&s.warn&&s.error)&&(this.modules.logger=s),s.type==="languageDetector"&&(this.modules.languageDetector=s),s.type==="i18nFormat"&&(this.modules.i18nFormat=s),s.type==="postProcessor"&&Cp.addPostProcessor(s),s.type==="formatter"&&(this.modules.formatter=s),s.type==="3rdParty"&&this.modules.external.push(s),this}},{key:"setResolvedLanguage",value:function(s){if(!(!s||!this.languages)&&!(["cimode","dev"].indexOf(s)>-1))for(var l=0;l-1)&&this.store.hasLanguageSomeTranslations(c)){this.resolvedLanguage=c;break}}}},{key:"changeLanguage",value:function(s,l){var c=this;this.isLanguageChangingTo=s;var p=qs();this.emit("languageChanging",s);var g=function(C){c.language=C,c.languages=c.services.languageUtils.toResolveHierarchy(C),c.resolvedLanguage=void 0,c.setResolvedLanguage(C)},m=function(C,v){v?(g(v),c.translator.changeLanguage(v),c.isLanguageChangingTo=void 0,c.emit("languageChanged",v),c.logger.log("languageChanged",v)):c.isLanguageChangingTo=void 0,p.resolve(function(){return c.t.apply(c,arguments)}),l&&l(C,function(){return c.t.apply(c,arguments)})},h=function(C){!s&&!C&&c.services.languageDetector&&(C=[]);var v=typeof C=="string"?C:c.services.languageUtils.getBestMatchFromCodes(C);v&&(c.language||g(v),c.translator.language||c.translator.changeLanguage(v),c.services.languageDetector&&c.services.languageDetector.cacheUserLanguage&&c.services.languageDetector.cacheUserLanguage(v)),c.loadResources(v,function(x){m(x,v)})};return!s&&this.services.languageDetector&&!this.services.languageDetector.async?h(this.services.languageDetector.detect()):!s&&this.services.languageDetector&&this.services.languageDetector.async?this.services.languageDetector.detect.length===0?this.services.languageDetector.detect().then(h):this.services.languageDetector.detect(h):h(s),p}},{key:"getFixedT",value:function(s,l,c){var p=this,g=function m(h,b){var C;if(ft(b)!=="object"){for(var v=arguments.length,x=new Array(v>2?v-2:0),B=2;B1&&arguments[1]!==void 0?arguments[1]:{};if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;var p=c.lng||this.resolvedLanguage||this.languages[0],g=this.options?this.options.fallbackLng:!1,m=this.languages[this.languages.length-1];if(p.toLowerCase()==="cimode")return!0;var h=function(v,x){var B=l.services.backendConnector.state["".concat(v,"|").concat(x)];return B===-1||B===2};if(c.precheck){var b=c.precheck(this,h);if(b!==void 0)return b}return!!(this.hasResourceBundle(p,s)||!this.services.backendConnector.backend||this.options.resources&&!this.options.partialBundledLanguages||h(p,s)&&(!g||h(m,s)))}},{key:"loadNamespaces",value:function(s,l){var c=this,p=qs();return this.options.ns?(typeof s=="string"&&(s=[s]),s.forEach(function(g){c.options.ns.indexOf(g)<0&&c.options.ns.push(g)}),this.loadResources(function(g){p.resolve(),l&&l(g)}),p):(l&&l(),Promise.resolve())}},{key:"loadLanguages",value:function(s,l){var c=qs();typeof s=="string"&&(s=[s]);var p=this.options.preload||[],g=s.filter(function(m){return p.indexOf(m)<0});return g.length?(this.options.preload=p.concat(g),this.loadResources(function(m){c.resolve(),l&&l(m)}),c):(l&&l(),Promise.resolve())}},{key:"dir",value:function(s){if(s||(s=this.resolvedLanguage||(this.languages&&this.languages.length>0?this.languages[0]:this.language)),!s)return"rtl";var l=["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam","ckb"],c=this.services&&this.services.languageUtils||new cp(hp());return l.indexOf(c.getLanguagePartFromCode(s))>-1||s.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}},{key:"cloneInstance",value:function(){var s=this,l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:ui,p=$r($r($r({},this.options),l),{isClone:!0}),g=new n(p);(l.debug!==void 0||l.prefix!==void 0)&&(g.logger=g.logger.clone(l));var m=["store","services","language"];return m.forEach(function(h){g[h]=s[h]}),g.services=$r({},this.services),g.services.utils={hasLoadedNamespace:g.hasLoadedNamespace.bind(g)},g.translator=new lp(g.services,g.options),g.translator.on("*",function(h){for(var b=arguments.length,C=new Array(b>1?b-1:0),v=1;v0&&arguments[0]!==void 0?arguments[0]:{},r=arguments.length>1?arguments[1]:void 0;return new gi(t,r)});var u=gi.createInstance();u.createInstance=gi.createInstance;var cw=u.createInstance,uw=u.dir,dw=u.init,pw=u.loadResources,gw=u.reloadResources,mw=u.use,fw=u.changeLanguage,hw=u.getFixedT,bw=u.t,yw=u.exists,vw=u.setDefaultNamespace,Cw=u.hasLoadedNamespace,ww=u.loadNamespaces,xw=u.loadLanguages;var cc=new Map,i=t=>{let r=cc.get(t);if(r)return r;let n=document.getElementById(t);if(!n)throw new TypeError(`Element with id "${t}" was not found on page?`);return cc.set(t,n),n},fi=t=>cc.has(t);var Mp=Ln(xp()),yt=new Mp.default;var En=class{constructor(r){this.level=0;this.freeLevels=0;this.toggleBuy=1;var n,a,s,l;this.name=r.name,this.description=r.description,this.level=(n=r.level)!=null?n:0,this.freeLevels=(a=r.freeLevels)!=null?a:0,this.maxLevel=r.maxLevel,this.costPerLevel=r.costPerLevel,this.toggleBuy=(s=r.toggleBuy)!=null?s:1,this.effect=(l=r.effect)!=null?l:c=>({bonus:c,desc:"WIP not implemented"})}async changeToggle(){let r=await Ee(u.t("dynamicUpgrades.validation.setPurchaseAmount",{x:this.name})),n=Number(r);if(r===null)return P(u.t("dynamicUpgrades.validation.toggleKept",{x:d(this.toggleBuy)}));if(!Number.isInteger(r))return P(u.t("general.validation.fraction"));if(n<-1)return P(u.t("dynamicUpgrades.validation.onlyNegativeOne"));if(n===0)return P(u.t("dynamicUpgrades.validation.notZero"));this.toggleBuy=n;let a=n===-1?u.t("dynamicUpgrades.toggleMax"):u.t("dynamicUpgrades.toggle",{x:d(this.toggleBuy)});return P(a)}getEffect(){let r=this.level+Math.min(this.level,this.freeLevels)+Math.sqrt(Math.max(0,this.freeLevels-this.level));return this.effect(r)}};var n0=Ln(pc());var a0=Ln(sc());var Jt="3.1.1 January 15, 2025 pt 1.4: The Bakery Update";var On=new Date(Date.UTC(2025,0,17,23,39,50)),Dr=!0;var ta=()=>{let t=Object.keys(e.hypercubeBlessings);for(let r of t){let n=e.hypercubeBlessings[r],a=t.indexOf(r)+1,s=1,l=1;n>=1e3&&(s=o.benedictionDRPower[a],l*=Math.pow(1e3,1-o.benedictionDRPower[a])),o.hypercubeBonusMultiplier[a]=1+l*o.benedictionbase[a]*Math.pow(n,s)*o.platonicBonusMultiplier[4]}};var bi=()=>{let t=Object.values(e.platonicBlessings),r=[4e6,4e6,4e6,8e4,1e4,1e4,1e4,1e4];for(let n=0;n=1e20&&(l=Math.pow(l,.5)*1e10),t[n]>=r[n]&&(a=o.platonicDRPower[n],s*=Math.pow(r[n],1-o.platonicDRPower[n])),o.platonicBonusMultiplier[n]=1+s*o.platonicCubeBase[n]*Math.pow(l,a)}};var Ut=()=>{let t=9e4;e.researches[195]>0&&(t+=18e3*e.researches[195]);let r=5,n=[99,100,125,180,195];for(let p of n)r+=e.researches[p];r*=+e.octeractUpgrades.octeractExportQuarks.getEffect().bonus;let a=r,s=Math.floor(a*t/3600),l=Math.floor(e.quarkstimer*a/3600),c=Bn();return{maxTime:t,perHour:a,capacity:s,gain:l,cubeMult:c}},Tp=0,Sp=t=>Tp=t,er=()=>Tp,Yh,Un=class{constructor(r){this.QUARKS=0;this[Yh]=r=>r==="number"?this.QUARKS:null;this.QUARKS=r}applyBonus(r){let n=yi();return r*(1+er()/100)*n}add(r,n=!0){return this.QUARKS+=n?this.applyBonus(r):r,e.quarksThisSingularity+=n?this.applyBonus(r):r,this}sub(r){return this.QUARKS-=r,this.QUARKS<0&&(this.QUARKS=0),this}toString(r){return d(Math.floor(this.applyBonus(r)),0,!0)}reset(){this.QUARKS=0}};Yh=Symbol.toPrimitive;var ra=()=>{let t=[e.tesseractBlessings.accelerator,e.tesseractBlessings.multiplier,e.tesseractBlessings.offering,e.tesseractBlessings.runeExp,e.tesseractBlessings.obtainium,e.tesseractBlessings.antSpeed,e.tesseractBlessings.antSacrifice,e.tesseractBlessings.antELO,e.tesseractBlessings.talismanBonus,e.tesseractBlessings.globalSpeed];for(let r=0;r<10;r++){let n=1,a=1;t[r]>=1e3&&r!==5&&(n=o.giftDRPower[r],a*=Math.pow(1e3,1-o.giftDRPower[r])),o.tesseractBonusMultiplier[r+1]=1+a*o.giftbase[r]*Math.pow(t[r],n)*o.hypercubeBonusMultiplier[r+1]}};var Za={accelerator:{weight:4,pdf:t=>0<=t&&t<=20},multiplier:{weight:4,pdf:t=>2040506070808590950<=t&&t<=33},tesseracts:{weight:13200,pdf:t=>33669999.9999.992599.99599.9975100?P(u.t("cubes.validation.invalidPercent",{x:s})):a?this.open(Math.floor(r.value*(s/100)),s===100,!1):this.open(s,s===r.value,!1)}checkQuarkGain(r,n,a){if(a<1)return 0;let s=n*Ut().cubeMult;return Math.floor(e.worlds.applyBonus(Math.log10(a)*r*s))}checkCubesToNextQuark(r,n,a,s){let l=n*Ut().cubeMult;return Math.ceil(Math.pow(10,(a+1)/e.worlds.applyBonus(l*r))-s)}add(r){return this.value=Math.min(1e300,this.value+r),this}sub(r){return this.value=Math.max(0,this.value-r),this}[Symbol.toPrimitive](r){switch(r){case"string":return this.value.toString();case"number":return this.value;default:return null}}},tr=class extends Rn{constructor(r=Number(e.wowCubes)){super("wowCubes",r)}open(r,n=!1,a=!1){let s=n?Number(this):a?r:Math.min(Number(this),r);r===1&&e.cubeBlessings.accelerator>=2e11&&e.achievements[246]<1&&R(246),a||this.sub(s),e.cubeOpenedDaily+=s;let l=e.shopUpgrades.cubeToQuark?1.5:1,c=Number(this.checkQuarkGain(5,l,e.cubeOpenedDaily)),p=Math.max(0,c-e.cubeQuarkDaily);e.cubeQuarkDaily+=p,e.worlds.add(p,!1),s*=1+e.researches[138]/1e3,s*=1+.8*e.researches[168]/1e3,s*=1+.6*e.researches[198]/1e3,s=Math.floor(s);let g=s%20,m=Math.floor(s/20);m>0&&e.cubeUpgrades[13]===1&&(g+=m),m>0&&e.cubeUpgrades[23]===1&&(g+=m),m>0&&e.cubeUpgrades[33]===1&&(g+=m),m+=100/100*Math.floor(g/20),g=g%20;let h=Object.keys(e.cubeBlessings);for(let b of h)e.cubeBlessings[b]+=Za[b].weight*m*(1+Math.floor(_("ascension",e.challengecompletions[12])));for(let b=0;b0&&(e.platonicBlessings[v]+=m);let h=["hypercubeBonus","taxes","scoreBonus","globalSpeed"];for(let v=0;v=x&&g!==0&&(e.platonicBlessings[h[v]]+=1,g-=1)}let b=[Math.floor(33*g/100),Math.floor(33*g/100),Math.floor(33*g/100),Math.floor(396*g/4e4)],C=["cubes","tesseracts","hypercubes","platonics"];for(let v=0;v0){let v=Math.floor(s*Math.max(0,Math.min(1,(f.log(e.ascendShards.add(1),10)-1e5)/9e5)));e.wowHypercubes.open(v,!1,!0)}}};var mg=Ln(gg());var Li=t=>t instanceof f||typeof t=="object"&&t!==null&&Object.keys(t).length===2&&"mantissa"in t&&"exponent"in t,Ce=(t=0)=>t<=Number.MAX_SAFE_INTEGER?1:2**Math.floor(Math.log2(t)-52),ae=t=>(t=Array.isArray(t)?t:Object.values(t),t.reduce((r,n)=>r+n,0)),be=t=>t.reduce((r,n)=>r*n),fg=t=>Array.from([...t.keys()]).sort((r,n)=>t[r]i(t);var Pc=(t,r,n)=>{for(let a=0;a{let a=i(t);for(let s of r)a.classList.add(s);for(let s of n)a.classList.remove(s)},rs=t=>{try{return window.btoa(t)}catch(r){return console.error("An error occurred:",r),null}},Xs=t=>{let r="th";return t%10===1&&(r=t%100===11?"th":"st"),t%10===2&&(r=t%100===12?"th":"nd"),t%10===3&&(r=t%100===13?"th":"rd"),d(t,0,!0)+r},kb=t=>Object.entries({d:Math.floor(t/864e5),h:Math.floor(t/36e5)%24,m:Math.floor(t/6e4)%60,s:Math.floor(t/1e3)%60}).filter(r=>r[1]>0).map(r=>`${r[1]}${r[0]}`).join(" ")||"0s",Tr=t=>kb(1e3*t),Zs=t=>{let r="";for(let n=0;n255?"_":t[n]}return r};function Nn(t,r){if(!t)throw new TypeError("assertion failed",{cause:new TypeError(r)})}function Pi(t,r,n){return tn?r:t}var ca=()=>{let t,r,n=new Promise((a,s)=>{t=a,r=s});return{resolve:t,reject:r,promise:n}},Gr=t=>(0,mg.default)(t,r=>Li(r)||r instanceof f?new f(r):r);function Hr(t){let r=!1,n;return(...a)=>(r||(r=!0,n=t(...a)),n)}var Ac=()=>{let t=e.singularityCount,r=t>36?u.t("singularity.penalties.platonicCosts",{multiplier:d(Le("Platonic Costs",t),2,!0)}):'???????? ??????? ????? ??? ?????????? ?? ??? (37)',n=t>50?u.t("singularity.penalties.hepteractCosts",{multiplier:d(Le("Hepteract Costs",t),2,!0)}):'????????? ????? ????? ??? ?????????? ?? ??? (51)',a=`${Lb(t)}
${u.t("singularity.penalties.globalSpeed",{divisor:d(Le("Global Speed",t),2,!0)})} +"use strict";(()=>{var Ch=Object.create;var lc=Object.defineProperty,wh=Object.defineProperties,xh=Object.getOwnPropertyDescriptor,Mh=Object.getOwnPropertyDescriptors,Th=Object.getOwnPropertyNames,li=Object.getOwnPropertySymbols,Sh=Object.getPrototypeOf,cc=Object.prototype.hasOwnProperty,Yd=Object.prototype.propertyIsEnumerable;var Zd=(t,r,n)=>r in t?lc(t,r,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[r]=n,O=(t,r)=>{for(var n in r||(r={}))cc.call(r,n)&&Zd(t,n,r[n]);if(li)for(var n of li(r))Yd.call(r,n)&&Zd(t,n,r[n]);return t},te=(t,r)=>wh(t,Mh(r));var Jd=(t,r)=>{var n={};for(var a in t)cc.call(t,a)&&r.indexOf(a)<0&&(n[a]=t[a]);if(t!=null&&li)for(var a of li(t))r.indexOf(a)<0&&Yd.call(t,a)&&(n[a]=t[a]);return n};var Ja=(t,r)=>()=>(r||t((r={exports:{}}).exports,r),r.exports);var kh=(t,r,n,a)=>{if(r&&typeof r=="object"||typeof r=="function")for(let s of Th(r))!cc.call(t,s)&&s!==n&&lc(t,s,{get:()=>r[s],enumerable:!(a=xh(r,s))||a.enumerable});return t};var Un=(t,r,n)=>(n=t!=null?Ch(Sh(t)):{},kh(r||!t||!t.__esModule?lc(n,"default",{value:t,enumerable:!0}):n,t));var uc=(t,r,n)=>{if(!r.has(t))throw TypeError("Cannot "+n)};var ee=(t,r,n)=>(uc(t,r,"read from private field"),n?n.call(t):r.get(t)),Tt=(t,r,n)=>{if(r.has(t))throw TypeError("Cannot add the same private member more than once");r instanceof WeakSet?r.add(t):r.set(t,n)},St=(t,r,n,a)=>(uc(t,r,"write to private field"),a?a.call(t,n):r.set(t,n),n);var ci=(t,r,n)=>(uc(t,r,"access private method"),n);var tp=Ja((N2,ep)=>{"use strict";ep.exports=function(t,r,n){if(t==null||r==null)return t;var a=String(t),s=typeof r=="number"?r:parseInt(r,10);if(isNaN(s)||!isFinite(s))return a;var l=a.length;if(l>=s)return a;var c=n==null?"":String(n);c===""&&(c=" ");for(var p=s-l;c.lengthp?c.substr(0,p):c;return a+g}});var pc=Ja((_2,pi)=>{var dc=function(){var t=String.fromCharCode,r="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-$",a={};function s(c,p){if(!a[c]){a[c]={};for(var g=0;g>>8,g[m*2+1]=b%256}return g},decompressFromUint8Array:function(c){if(c==null)return l.decompress(c);for(var p=new Array(c.length/2),g=0,m=p.length;g>1}else{for(h=1,m=0;m>1}U--,U==0&&(U=Math.pow(2,L),L++),delete C[B]}else for(h=b[B],m=0;m>1;U--,U==0&&(U=Math.pow(2,L),L++),b[x]=k++,B=String(v)}if(B!==""){if(Object.prototype.hasOwnProperty.call(C,B)){if(B.charCodeAt(0)<256){for(m=0;m>1}else{for(h=1,m=0;m>1}U--,U==0&&(U=Math.pow(2,L),L++),delete C[B]}else for(h=b[B],m=0;m>1;U--,U==0&&(U=Math.pow(2,L),L++)}for(h=2,m=0;m>1;for(;;)if(T=T<<1,S==p-1){E.push(g(T));break}else S++;return E.join("")},decompress:function(c){return c==null?"":c==""?null:l._decompress(c.length,32768,function(p){return c.charCodeAt(p)})},_decompress:function(c,p,g){var m=[],h,b=4,C=4,v=3,x="",B=[],U,k,L,E,T,S,I,N={val:g(0),position:p,index:1};for(U=0;U<3;U+=1)m[U]=U;for(L=0,T=Math.pow(2,2),S=1;S!=T;)E=N.val&N.position,N.position>>=1,N.position==0&&(N.position=p,N.val=g(N.index++)),L|=(E>0?1:0)*S,S<<=1;switch(h=L){case 0:for(L=0,T=Math.pow(2,8),S=1;S!=T;)E=N.val&N.position,N.position>>=1,N.position==0&&(N.position=p,N.val=g(N.index++)),L|=(E>0?1:0)*S,S<<=1;I=t(L);break;case 1:for(L=0,T=Math.pow(2,16),S=1;S!=T;)E=N.val&N.position,N.position>>=1,N.position==0&&(N.position=p,N.val=g(N.index++)),L|=(E>0?1:0)*S,S<<=1;I=t(L);break;case 2:return""}for(m[3]=I,k=I,B.push(I);;){if(N.index>c)return"";for(L=0,T=Math.pow(2,v),S=1;S!=T;)E=N.val&N.position,N.position>>=1,N.position==0&&(N.position=p,N.val=g(N.index++)),L|=(E>0?1:0)*S,S<<=1;switch(I=L){case 0:for(L=0,T=Math.pow(2,8),S=1;S!=T;)E=N.val&N.position,N.position>>=1,N.position==0&&(N.position=p,N.val=g(N.index++)),L|=(E>0?1:0)*S,S<<=1;m[C++]=t(L),I=C-1,b--;break;case 1:for(L=0,T=Math.pow(2,16),S=1;S!=T;)E=N.val&N.position,N.position>>=1,N.position==0&&(N.position=p,N.val=g(N.index++)),L|=(E>0?1:0)*S,S<<=1;m[C++]=t(L),I=C-1,b--;break;case 2:return B.join("")}if(b==0&&(b=Math.pow(2,v),v++),m[I])x=m[I];else if(I===C)x=k+k.charAt(0);else return null;B.push(x),m[C++]=k+x.charAt(0),b--,k=x,b==0&&(b=Math.pow(2,v),v++)}}};return l}();typeof define=="function"&&define.amd?define(function(){return dc}):typeof pi<"u"&&pi!=null?pi.exports=dc:typeof angular<"u"&&angular!=null&&angular.module("LZString",[]).factory("LZString",function(){return dc})});var Ep=Ja((Gw,bc)=>{"use strict";var l1=Object.prototype.hasOwnProperty,kt="~";function zs(){}Object.create&&(zs.prototype=Object.create(null),new zs().__proto__||(kt=!1));function c1(t,r,n){this.fn=t,this.context=r,this.once=n||!1}function Ap(t,r,n,a,s){if(typeof n!="function")throw new TypeError("The listener must be a function");var l=new c1(n,a||t,s),c=kt?kt+r:r;return t._events[c]?t._events[c].fn?t._events[c]=[t._events[c],l]:t._events[c].push(l):(t._events[c]=l,t._eventsCount++),t}function xi(t,r){--t._eventsCount===0?t._events=new zs:delete t._events[r]}function vt(){this._events=new zs,this._eventsCount=0}vt.prototype.eventNames=function(){var r=[],n,a;if(this._eventsCount===0)return r;for(a in n=this._events)l1.call(n,a)&&r.push(kt?a.slice(1):a);return Object.getOwnPropertySymbols?r.concat(Object.getOwnPropertySymbols(n)):r};vt.prototype.listeners=function(r){var n=kt?kt+r:r,a=this._events[n];if(!a)return[];if(a.fn)return[a.fn];for(var s=0,l=a.length,c=new Array(l);s{(function(r,n){typeof Xs=="object"&&typeof yc=="object"?yc.exports=n():typeof define=="function"&&define.amd?define([],n):typeof Xs=="object"?Xs.ClipboardJS=n():r.ClipboardJS=n()})(Xs,function(){return function(){var t={686:function(a,s,l){"use strict";l.d(s,{default:function(){return Ht}});var c=l(279),p=l.n(c),g=l(370),m=l.n(g),h=l(817),b=l.n(h);function C(ce){try{return document.execCommand(ce)}catch(z){return!1}}var v=function(z){var Z=b()(z);return C("cut"),Z},x=v;function B(ce){var z=document.documentElement.getAttribute("dir")==="rtl",Z=document.createElement("textarea");Z.style.fontSize="12pt",Z.style.border="0",Z.style.padding="0",Z.style.margin="0",Z.style.position="absolute",Z.style[z?"right":"left"]="-9999px";var se=window.pageYOffset||document.documentElement.scrollTop;return Z.style.top="".concat(se,"px"),Z.setAttribute("readonly",""),Z.value=ce,Z}var U=function(z,Z){var se=B(z);Z.container.appendChild(se);var ne=b()(se);return C("copy"),se.remove(),ne},k=function(z){var Z=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{container:document.body},se="";return typeof z=="string"?se=U(z,Z):z instanceof HTMLInputElement&&!["text","search","url","tel","password"].includes(z==null?void 0:z.type)?se=U(z.value,Z):(se=b()(z),C("copy")),se},L=k;function E(ce){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?E=function(Z){return typeof Z}:E=function(Z){return Z&&typeof Symbol=="function"&&Z.constructor===Symbol&&Z!==Symbol.prototype?"symbol":typeof Z},E(ce)}var T=function(){var z=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},Z=z.action,se=Z===void 0?"copy":Z,ne=z.container,he=z.target,Fe=z.text;if(se!=="copy"&&se!=="cut")throw new Error('Invalid "action" value, use either "copy" or "cut"');if(he!==void 0)if(he&&E(he)==="object"&&he.nodeType===1){if(se==="copy"&&he.hasAttribute("disabled"))throw new Error('Invalid "target" attribute. Please use "readonly" instead of "disabled" attribute');if(se==="cut"&&(he.hasAttribute("readonly")||he.hasAttribute("disabled")))throw new Error(`Invalid "target" attribute. You can't cut text from elements with "readonly" or "disabled" attributes`)}else throw new Error('Invalid "target" value, use a valid Element');if(Fe)return L(Fe,{container:ne});if(he)return se==="cut"?x(he):L(he,{container:ne})},S=T;function I(ce){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?I=function(Z){return typeof Z}:I=function(Z){return Z&&typeof Symbol=="function"&&Z.constructor===Symbol&&Z!==Symbol.prototype?"symbol":typeof Z},I(ce)}function N(ce,z){if(!(ce instanceof z))throw new TypeError("Cannot call a class as a function")}function X(ce,z){for(var Z=0;Z"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(ce){return!1}}function xt(ce){return xt=Object.setPrototypeOf?Object.getPrototypeOf:function(Z){return Z.__proto__||Object.getPrototypeOf(Z)},xt(ce)}function Gt(ce,z){var Z="data-clipboard-".concat(ce);if(z.hasAttribute(Z))return z.getAttribute(Z)}var er=function(ce){w(Z,ce);var z=J(Z);function Z(se,ne){var he;return N(this,Z),he=z.call(this),he.resolveOptions(ne),he.listenClick(se),he}return re(Z,[{key:"resolveOptions",value:function(){var ne=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};this.action=typeof ne.action=="function"?ne.action:this.defaultAction,this.target=typeof ne.target=="function"?ne.target:this.defaultTarget,this.text=typeof ne.text=="function"?ne.text:this.defaultText,this.container=I(ne.container)==="object"?ne.container:document.body}},{key:"listenClick",value:function(ne){var he=this;this.listener=m()(ne,"click",function(Fe){return he.onClick(Fe)})}},{key:"onClick",value:function(ne){var he=ne.delegateTarget||ne.currentTarget,Fe=this.action(he)||"copy",Mt=S({action:Fe,container:this.container,target:this.target(he),text:this.text(he)});this.emit(Mt?"success":"error",{action:Fe,text:Mt,trigger:he,clearSelection:function(){he&&he.focus(),window.getSelection().removeAllRanges()}})}},{key:"defaultAction",value:function(ne){return Gt("action",ne)}},{key:"defaultTarget",value:function(ne){var he=Gt("target",ne);if(he)return document.querySelector(he)}},{key:"defaultText",value:function(ne){return Gt("text",ne)}},{key:"destroy",value:function(){this.listener.destroy()}}],[{key:"copy",value:function(ne){var he=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{container:document.body};return L(ne,he)}},{key:"cut",value:function(ne){return x(ne)}},{key:"isSupported",value:function(){var ne=arguments.length>0&&arguments[0]!==void 0?arguments[0]:["copy","cut"],he=typeof ne=="string"?[ne]:ne,Fe=!!document.queryCommandSupported;return he.forEach(function(Mt){Fe=Fe&&!!document.queryCommandSupported(Mt)}),Fe}}]),Z}(p()),Ht=er},828:function(a){var s=9;if(typeof Element<"u"&&!Element.prototype.matches){var l=Element.prototype;l.matches=l.matchesSelector||l.mozMatchesSelector||l.msMatchesSelector||l.oMatchesSelector||l.webkitMatchesSelector}function c(p,g){for(;p&&p.nodeType!==s;){if(typeof p.matches=="function"&&p.matches(g))return p;p=p.parentNode}}a.exports=c},438:function(a,s,l){var c=l(828);function p(h,b,C,v,x){var B=m.apply(this,arguments);return h.addEventListener(C,B,x),{destroy:function(){h.removeEventListener(C,B,x)}}}function g(h,b,C,v,x){return typeof h.addEventListener=="function"?p.apply(null,arguments):typeof C=="function"?p.bind(null,document).apply(null,arguments):(typeof h=="string"&&(h=document.querySelectorAll(h)),Array.prototype.map.call(h,function(B){return p(B,b,C,v,x)}))}function m(h,b,C,v){return function(x){x.delegateTarget=c(x.target,b),x.delegateTarget&&v.call(h,x)}}a.exports=g},879:function(a,s){s.node=function(l){return l!==void 0&&l instanceof HTMLElement&&l.nodeType===1},s.nodeList=function(l){var c=Object.prototype.toString.call(l);return l!==void 0&&(c==="[object NodeList]"||c==="[object HTMLCollection]")&&"length"in l&&(l.length===0||s.node(l[0]))},s.string=function(l){return typeof l=="string"||l instanceof String},s.fn=function(l){var c=Object.prototype.toString.call(l);return c==="[object Function]"}},370:function(a,s,l){var c=l(879),p=l(438);function g(C,v,x){if(!C&&!v&&!x)throw new Error("Missing required arguments");if(!c.string(v))throw new TypeError("Second argument must be a String");if(!c.fn(x))throw new TypeError("Third argument must be a Function");if(c.node(C))return m(C,v,x);if(c.nodeList(C))return h(C,v,x);if(c.string(C))return b(C,v,x);throw new TypeError("First argument must be a String, HTMLElement, HTMLCollection, or NodeList")}function m(C,v,x){return C.addEventListener(v,x),{destroy:function(){C.removeEventListener(v,x)}}}function h(C,v,x){return Array.prototype.forEach.call(C,function(B){B.addEventListener(v,x)}),{destroy:function(){Array.prototype.forEach.call(C,function(B){B.removeEventListener(v,x)})}}}function b(C,v,x){return p(document.body,C,v,x)}a.exports=g},817:function(a){function s(l){var c;if(l.nodeName==="SELECT")l.focus(),c=l.value;else if(l.nodeName==="INPUT"||l.nodeName==="TEXTAREA"){var p=l.hasAttribute("readonly");p||l.setAttribute("readonly",""),l.select(),l.setSelectionRange(0,l.value.length),p||l.removeAttribute("readonly"),c=l.value}else{l.hasAttribute("contenteditable")&&l.focus();var g=window.getSelection(),m=document.createRange();m.selectNodeContents(l),g.removeAllRanges(),g.addRange(m),c=g.toString()}return c}a.exports=s},279:function(a){function s(){}s.prototype={on:function(l,c,p){var g=this.e||(this.e={});return(g[l]||(g[l]=[])).push({fn:c,ctx:p}),this},once:function(l,c,p){var g=this;function m(){g.off(l,m),c.apply(p,arguments)}return m._=c,this.on(l,m,p)},emit:function(l){var c=[].slice.call(arguments,1),p=((this.e||(this.e={}))[l]||[]).slice(),g=0,m=p.length;for(g;g{var d1=200,jp="__lodash_hash_undefined__",Vp=9007199254740991,Pc="[object Arguments]",p1="[object Array]",Wp="[object Boolean]",Kp="[object Date]",g1="[object Error]",Ac="[object Function]",zp="[object GeneratorFunction]",Si="[object Map]",Xp="[object Number]",Ec="[object Object]",Rp="[object Promise]",Zp="[object RegExp]",ki="[object Set]",Yp="[object String]",Jp="[object Symbol]",xc="[object WeakMap]",eg="[object ArrayBuffer]",Li="[object DataView]",tg="[object Float32Array]",rg="[object Float64Array]",ng="[object Int8Array]",ag="[object Int16Array]",sg="[object Int32Array]",og="[object Uint8Array]",ig="[object Uint8ClampedArray]",lg="[object Uint16Array]",cg="[object Uint32Array]",m1=/[\\^$.*+?()[\]{}|]/g,f1=/\w*$/,h1=/^\[object .+?Constructor\]$/,b1=/^(?:0|[1-9]\d*)$/,_e={};_e[Pc]=_e[p1]=_e[eg]=_e[Li]=_e[Wp]=_e[Kp]=_e[tg]=_e[rg]=_e[ng]=_e[ag]=_e[sg]=_e[Si]=_e[Xp]=_e[Ec]=_e[Zp]=_e[ki]=_e[Yp]=_e[Jp]=_e[og]=_e[ig]=_e[lg]=_e[cg]=!0;_e[g1]=_e[Ac]=_e[xc]=!1;var y1=typeof global=="object"&&global&&global.Object===Object&&global,v1=typeof self=="object"&&self&&self.Object===Object&&self,rn=y1||v1||Function("return this")(),ug=typeof Zs=="object"&&Zs&&!Zs.nodeType&&Zs,Ip=ug&&typeof as=="object"&&as&&!as.nodeType&&as,C1=Ip&&Ip.exports===ug;function w1(t,r){return t.set(r[0],r[1]),t}function x1(t,r){return t.add(r),t}function M1(t,r){for(var n=-1,a=t?t.length:0;++n-1}function X1(t,r){var n=this.__data__,a=Ei(n,t);return a<0?n.push([t,r]):n[a][1]=r,this}nn.prototype.clear=V1;nn.prototype.delete=W1;nn.prototype.get=K1;nn.prototype.has=z1;nn.prototype.set=X1;function ss(t){var r=-1,n=t?t.length:0;for(this.clear();++r-1&&t%1==0&&t-1&&t%1==0&&t<=Vp}function Ui(t){var r=typeof t;return!!t&&(r=="object"||r=="function")}function Ib(t){return!!t&&typeof t=="object"}function Rc(t){return vg(t)?ib(t):gb(t)}function Nb(){return[]}function $b(){return!1}as.exports=Eb});var ym=Ja((nl,bm)=>{(function(t,r){typeof nl=="object"&&typeof bm<"u"?r(nl):typeof define=="function"&&define.amd?define(["exports"],r):(t=typeof globalThis<"u"?globalThis:t||self,r(t.fastUniqueNumbers={}))})(nl,function(t){"use strict";var r=function(C){return function(v){var x=C(v);return v.add(x),x}},n=function(C){return function(v,x){return C.set(v,x),x}},a=Number.MAX_SAFE_INTEGER===void 0?9007199254740991:Number.MAX_SAFE_INTEGER,s=536870912,l=s*2,c=function(C,v){return function(x){var B=v.get(x),U=B===void 0?x.size:Ba)throw new Error("Congratulations, you created a collection of unique numbers which uses all available integers!");for(;x.has(U);)U=Math.floor(Math.random()*a);return C(x,U)}},p=new WeakMap,g=n(p),m=c(g,p),h=r(m);t.addUniqueNumber=h,t.generateUniqueNumber=m})});(function(){"use strict";var t=function(Q,$){var q=function(Ne){for(var ve=0,Ue=Ne.length;veQ.length)&&($=Q.length);for(var q=0,ue=new Array($);q<$;q++)ue[q]=Q[q];return ue}function a(Q,$){var q=typeof Symbol<"u"&&Q[Symbol.iterator]||Q["@@iterator"];if(!q){if(Array.isArray(Q)||(q=r(Q))||$&&Q&&typeof Q.length=="number"){q&&(Q=q);var ue=0,de=function(){};return{s:de,n:function(){return ue>=Q.length?{done:!0}:{done:!1,value:Q[ue++]}},e:function(et){throw et},f:de}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var Ne=!0,ve=!1,Ue;return{s:function(){q=q.call(Q)},n:function(){var et=q.next();return Ne=et.done,et},e:function(et){ve=!0,Ue=et},f:function(){try{!Ne&&q.return!=null&&q.return()}finally{if(ve)throw Ue}}}}var s=!0,l=!1,c="querySelectorAll",p=function($){var q=arguments.length>1&&arguments[1]!==void 0?arguments[1]:document,ue=arguments.length>2&&arguments[2]!==void 0?arguments[2]:MutationObserver,de=arguments.length>3&&arguments[3]!==void 0?arguments[3]:["*"],Ne=function et(En,On,Ut,Me,We,tt){var Ft=a(En),Ya;try{for(Ft.s();!(Ya=Ft.n()).done;){var ht=Ya.value;(tt||c in ht)&&(We?Ut.has(ht)||(Ut.add(ht),Me.delete(ht),$(ht,We)):Me.has(ht)||(Me.add(ht),Ut.delete(ht),$(ht,We)),tt||et(ht[c](On),On,Ut,Me,We,s))}}catch(ic){Ft.e(ic)}finally{Ft.f()}},ve=new ue(function(et){if(de.length){var En=de.join(","),On=new Set,Ut=new Set,Me=a(et),We;try{for(Me.s();!(We=Me.n()).done;){var tt=We.value,Ft=tt.addedNodes,Ya=tt.removedNodes;Ne(Ya,En,On,Ut,l,l),Ne(Ft,En,On,Ut,s,l)}}catch(ht){Me.e(ht)}finally{Me.f()}}}),Ue=ve.observe;return(ve.observe=function(et){return Ue.call(ve,et,{subtree:s,childList:s})})(q),ve},g="querySelectorAll",m=self,h=m.document,b=m.Element,C=m.MutationObserver,v=m.Set,x=m.WeakMap,B=function($){return g in $},U=[].filter,k=function(Q){var $=new x,q=function(Me){for(var We=0,tt=Me.length;We1&&arguments[1]!==void 0?arguments[1]:!0,tt=0,Ft=Me.length;tt=1&&this.m<10)return this;if(this.m===0)return this.m=0,this.e=0,this;var r=Math.floor(Math.log10(Math.abs(this.m)));return this.m=r===-324?10*this.m/1e-323:this.m/ui(r),this.e+=r,this},t.prototype.fromMantissaExponent=function(r,n){return isFinite(r)&&isFinite(n)?(this.m=r,this.e=n,this.normalize(),this):(r=Number.NaN,n=Number.NaN,this)},t.prototype.fromMantissaExponent_noNormalize=function(r,n){return this.m=r,this.e=n,this},t.prototype.fromDecimal=function(r){return this.m=r.m,this.e=r.e,this},t.prototype.fromNumber=function(r){return isNaN(r)?(this.m=Number.NaN,this.e=Number.NaN):r===Number.POSITIVE_INFINITY?(this.m=1,this.e=$r):r===Number.NEGATIVE_INFINITY?(this.m=-1,this.e=$r):r===0?(this.m=0,this.e=0):(this.e=Math.floor(Math.log10(Math.abs(r))),this.m=this.e===-324?10*r/1e-323:r/ui(this.e),this.normalize()),this},t.prototype.fromString=function(r){if(r.indexOf("e")!==-1){var n=r.split("e");this.m=parseFloat(n[0]),this.e=parseFloat(n[1]),this.normalize()}else if(r==="NaN")this.m=Number.NaN,this.e=Number.NaN;else if(this.fromNumber(parseFloat(r)),isNaN(this.m))throw Error("[DecimalError] Invalid argument: "+r);return this},t.prototype.fromValue=function(r){return r instanceof t?this.fromDecimal(r):typeof r=="number"?this.fromNumber(r):typeof r=="string"?this.fromString(r):(this.m=0,this.e=0,this)},t.prototype.toNumber=function(){if(!isFinite(this.e))return Number.NaN;if(this.e>308)return this.m>0?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY;if(this.e<-324)return 0;if(this.e===-324)return this.m>0?5e-324:-5e-324;var r=this.m*ui(this.e);if(!isFinite(r)||this.e<0)return r;var n=Math.round(r);return Math.abs(n-r)<1e-10?n:r},t.prototype.mantissaWithDecimalPlaces=function(r){if(isNaN(this.m)||isNaN(this.e))return Number.NaN;if(this.m===0)return 0;var n=r+1,a=Math.ceil(Math.log10(Math.abs(this.m))),s=Math.round(this.m*Math.pow(10,n-a))*Math.pow(10,a-n);return parseFloat(s.toFixed(Math.max(n-a,0)))},t.prototype.toString=function(){return isNaN(this.m)||isNaN(this.e)?"NaN":this.e>=$r?this.m>0?"Infinity":"-Infinity":this.e<=-$r||this.m===0?"0":this.e<21&&this.e>-7?this.toNumber().toString():this.m+"e"+(this.e>=0?"+":"")+this.e},t.prototype.toExponential=function(r){if(isNaN(this.m)||isNaN(this.e))return"NaN";if(this.e>=$r)return this.m>0?"Infinity":"-Infinity";if(this.e<=-$r||this.m===0)return"0"+(r>0?(0,di.default)(".",r+1,"0"):"")+"e+0";if(this.e>-324&&this.e<308)return this.toNumber().toExponential(r);isFinite(r)||(r=17);var n=r+1,a=Math.max(1,Math.ceil(Math.log10(Math.abs(this.m))));return(Math.round(this.m*Math.pow(10,n-a))*Math.pow(10,a-n)).toFixed(Math.max(n-a,0))+"e"+(this.e>=0?"+":"")+this.e},t.prototype.toFixed=function(r){return isNaN(this.m)||isNaN(this.e)?"NaN":this.e>=$r?this.m>0?"Infinity":"-Infinity":this.e<=-$r||this.m===0?"0"+(r>0?(0,di.default)(".",r+1,"0"):""):this.e>=17?this.m.toString().replace(".","").padEnd(this.e+1,"0")+(r>0?(0,di.default)(".",r+1,"0"):""):this.toNumber().toFixed(r)},t.prototype.toPrecision=function(r){return this.e<=-7?this.toExponential(r-1):r>this.e?this.toFixed(r-this.e-1):this.toExponential(r-1)},t.prototype.valueOf=function(){return this.toString()},t.prototype.toJSON=function(){return this.toString()},t.prototype.toStringWithDecimalPlaces=function(r){return this.toExponential(r)},t.prototype.abs=function(){return oa(Math.abs(this.m),this.e)},t.prototype.neg=function(){return oa(-this.m,this.e)},t.prototype.negate=function(){return this.neg()},t.prototype.negated=function(){return this.neg()},t.prototype.sign=function(){return Math.sign(this.m)},t.prototype.sgn=function(){return this.sign()},t.prototype.round=function(){return this.e<-1?new t(0):this.e<17?new t(Math.round(this.toNumber())):this},t.prototype.floor=function(){return this.e<-1?Math.sign(this.m)>=0?new t(0):new t(-1):this.e<17?new t(Math.floor(this.toNumber())):this},t.prototype.ceil=function(){return this.e<-1?Math.sign(this.m)>0?new t(1):new t(0):this.e<17?new t(Math.ceil(this.toNumber())):this},t.prototype.trunc=function(){return this.e<0?new t(0):this.e<17?new t(Math.trunc(this.toNumber())):this},t.prototype.add=function(r){var n,a,s=D(r);if(this.m===0)return s;if(s.m===0)return this;if(this.e>=s.e?(n=this,a=s):(n=s,a=this),n.e-a.e>17)return n;var l=Math.round(1e14*n.m+1e14*a.m*ui(a.e-n.e));return Bt(l,n.e-14)},t.prototype.plus=function(r){return this.add(r)},t.prototype.sub=function(r){return this.add(D(r).neg())},t.prototype.subtract=function(r){return this.sub(r)},t.prototype.minus=function(r){return this.sub(r)},t.prototype.mul=function(r){if(typeof r=="number")return r<1e307&&r>-1e307?Bt(this.m*r,this.e):Bt(1e-307*this.m*r,this.e+307);var n=typeof r=="string"?new t(r):r;return Bt(this.m*n.m,this.e+n.e)},t.prototype.multiply=function(r){return this.mul(r)},t.prototype.times=function(r){return this.mul(r)},t.prototype.div=function(r){return this.mul(D(r).recip())},t.prototype.divide=function(r){return this.div(r)},t.prototype.divideBy=function(r){return this.div(r)},t.prototype.dividedBy=function(r){return this.div(r)},t.prototype.recip=function(){return Bt(1/this.m,-this.e)},t.prototype.reciprocal=function(){return this.recip()},t.prototype.reciprocate=function(){return this.recip()},t.prototype.cmp=function(r){var n=D(r);if(this.m===0){if(n.m===0)return 0;if(n.m<0)return 1;if(n.m>0)return-1}if(n.m===0){if(this.m<0)return-1;if(this.m>0)return 1}if(this.m>0)return n.m<0||this.e>n.e?1:this.en.m?1:this.m0||this.e>n.e?-1:this.en.m?1:this.m0:n.m===0?this.m<=0:this.e===n.e?this.m0?n.m>0&&this.e0||this.e>n.e},t.prototype.lte=function(r){return!this.gt(r)},t.prototype.gt=function(r){var n=D(r);return this.m===0?n.m<0:n.m===0?this.m>0:this.e===n.e?this.m>n.m:this.m>0?n.m<0||this.e>n.e:n.m<0&&this.e-1},t.prototype.greaterThan=function(r){return this.cmp(r)>0},t.prototype.decimalPlaces=function(){return this.dp()},t.prototype.dp=function(){if(!isFinite(this.mantissa))return NaN;if(this.exponent>=17)return 0;for(var r=this.mantissa,n=-this.exponent,a=1;Math.abs(Math.round(r*a)/a-r)>1e-10;)a*=10,n++;return n>0?n:0},Object.defineProperty(t,"MAX_VALUE",{get:function(){return Ah},enumerable:!1,configurable:!0}),Object.defineProperty(t,"MIN_VALUE",{get:function(){return Eh},enumerable:!1,configurable:!0}),Object.defineProperty(t,"NUMBER_MAX_VALUE",{get:function(){return Oh},enumerable:!1,configurable:!0}),Object.defineProperty(t,"NUMBER_MIN_VALUE",{get:function(){return Uh},enumerable:!1,configurable:!0}),t}(),Ah=oa(1,$r),Eh=oa(1,-$r),Oh=D(Number.MAX_VALUE),Uh=D(Number.MIN_VALUE),f=Bn;var ih=Un(pc());function bt(t){"@babel/helpers - typeof";return bt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(r){return typeof r}:function(r){return r&&typeof Symbol=="function"&&r.constructor===Symbol&&r!==Symbol.prototype?"symbol":typeof r},bt(t)}function xr(t,r){if(!(t instanceof r))throw new TypeError("Cannot call a class as a function")}function rp(t,r){if(bt(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,r||"default");if(bt(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return(r==="string"?String:Number)(t)}function gi(t){var r=rp(t,"string");return bt(r)=="symbol"?r:r+""}function np(t,r){for(var n=0;nt.length)&&(r=t.length);for(var n=0,a=Array(r);n1&&arguments[1]!==void 0?arguments[1]:{};xr(this,t),this.init(r,n)}return Mr(t,[{key:"init",value:function(n){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.prefix=a.prefix||"i18next:",this.logger=n||Bh,this.options=a,this.debug=a.debug}},{key:"setDebug",value:function(n){this.debug=n}},{key:"log",value:function(){for(var n=arguments.length,a=new Array(n),s=0;s1?a-1:0),l=1;l-1?p.replace(/###/g,"."):p}function s(){return!t||typeof t=="string"}for(var l=typeof r!="string"?[].concat(r):r.split(".");l.length>1;){if(s())return{};var c=a(l.shift());!t[c]&&n&&(t[c]=new n),Object.prototype.hasOwnProperty.call(t,c)?t=t[c]:t={}}return s()?{}:{obj:t,k:a(l.shift())}}function pp(t,r,n){var a=fc(t,r,Object),s=a.obj,l=a.k;s[l]=n}function Nh(t,r,n,a){var s=fc(t,r,Object),l=s.obj,c=s.k;l[c]=l[c]||[],a&&(l[c]=l[c].concat(n)),a||l[c].push(n)}function bi(t,r){var n=fc(t,r),a=n.obj,s=n.k;if(a)return a[s]}function $h(t,r,n){var a=bi(t,n);return a!==void 0?a:bi(r,n)}function Lp(t,r,n){for(var a in r)a!=="__proto__"&&a!=="constructor"&&(a in t?typeof t[a]=="string"||t[a]instanceof String||typeof r[a]=="string"||r[a]instanceof String?n&&(t[a]=r[a]):Lp(t[a],r[a],n):t[a]=r[a]);return t}function ts(t){return t.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}var _h={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"};function Dh(t){return typeof t=="string"?t.replace(/[&<>"'\/]/g,function(r){return _h[r]}):t}var Ci=typeof window<"u"&&window.navigator&&typeof window.navigator.userAgentData>"u"&&window.navigator.userAgent&&window.navigator.userAgent.indexOf("MSIE")>-1,Gh=[" ",",","?","!",";"];function Hh(t,r,n){r=r||"",n=n||"";var a=Gh.filter(function(p){return r.indexOf(p)<0&&n.indexOf(p)<0});if(a.length===0)return!0;var s=new RegExp("(".concat(a.map(function(p){return p==="?"?"\\?":p}).join("|"),")")),l=!s.test(t);if(!l){var c=t.indexOf(n);c>0&&!s.test(t.substring(0,c))&&(l=!0)}return l}function yi(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:".";if(t){if(t[r])return t[r];for(var a=r.split(n),s=t,l=0;ll+c;)c++,p=a.slice(l,l+c).join(n),g=s[p];if(g===void 0)return;if(g===null)return null;if(r.endsWith(p)){if(typeof g=="string")return g;if(p&&typeof g[p]=="string")return g[p]}var m=a.slice(l+c).join(n);return m?yi(g,m,n):void 0}s=s[a[l]]}return s}}function gp(t,r){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);r&&(a=a.filter(function(s){return Object.getOwnPropertyDescriptor(t,s).enumerable})),n.push.apply(n,a)}return n}function fi(t){for(var r=1;r"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(t){return!1}}var qh=function(t){Ws(n,t);var r=Fh(n);function n(a){var s,l=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{ns:["translation"],defaultNS:"translation"};return xr(this,n),s=r.call(this),Ci&&Rn.call(_r(s)),s.data=a||{},s.options=l,s.options.keySeparator===void 0&&(s.options.keySeparator="."),s.options.ignoreJSONStructure===void 0&&(s.options.ignoreJSONStructure=!0),s}return Mr(n,[{key:"addNamespaces",value:function(s){this.options.ns.indexOf(s)<0&&this.options.ns.push(s)}},{key:"removeNamespaces",value:function(s){var l=this.options.ns.indexOf(s);l>-1&&this.options.ns.splice(l,1)}},{key:"getResource",value:function(s,l,c){var p=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},g=p.keySeparator!==void 0?p.keySeparator:this.options.keySeparator,m=p.ignoreJSONStructure!==void 0?p.ignoreJSONStructure:this.options.ignoreJSONStructure,h=[s,l];c&&typeof c!="string"&&(h=h.concat(c)),c&&typeof c=="string"&&(h=h.concat(g?c.split(g):c)),s.indexOf(".")>-1&&(h=s.split("."));var b=bi(this.data,h);return b||!m||typeof c!="string"?b:yi(this.data&&this.data[s]&&this.data[s][l],c,g)}},{key:"addResource",value:function(s,l,c,p){var g=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{silent:!1},m=g.keySeparator!==void 0?g.keySeparator:this.options.keySeparator,h=[s,l];c&&(h=h.concat(m?c.split(m):c)),s.indexOf(".")>-1&&(h=s.split("."),p=l,l=h[1]),this.addNamespaces(l),pp(this.data,h,p),g.silent||this.emit("added",s,l,c,p)}},{key:"addResources",value:function(s,l,c){var p=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{silent:!1};for(var g in c)(typeof c[g]=="string"||Object.prototype.toString.apply(c[g])==="[object Array]")&&this.addResource(s,l,g,c[g],{silent:!0});p.silent||this.emit("added",s,l,c)}},{key:"addResourceBundle",value:function(s,l,c,p,g){var m=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{silent:!1},h=[s,l];s.indexOf(".")>-1&&(h=s.split("."),p=c,c=l,l=h[1]),this.addNamespaces(l);var b=bi(this.data,h)||{};p?Lp(b,c,g):b=fi(fi({},b),c),pp(this.data,h,b),m.silent||this.emit("added",s,l,c)}},{key:"removeResourceBundle",value:function(s,l){this.hasResourceBundle(s,l)&&delete this.data[s][l],this.removeNamespaces(l),this.emit("removed",s,l)}},{key:"hasResourceBundle",value:function(s,l){return this.getResource(s,l)!==void 0}},{key:"getResourceBundle",value:function(s,l){return l||(l=this.options.defaultNS),this.options.compatibilityAPI==="v1"?fi(fi({},{}),this.getResource(s,l)):this.getResource(s,l)}},{key:"getDataByLanguage",value:function(s){return this.data[s]}},{key:"hasLanguageSomeTranslations",value:function(s){var l=this.getDataByLanguage(s),c=l&&Object.keys(l)||[];return!!c.find(function(p){return l[p]&&Object.keys(l[p]).length>0})}},{key:"toJSON",value:function(){return this.data}}]),n}(Rn),Pp={processors:{},addPostProcessor:function(r){this.processors[r.name]=r},handle:function(r,n,a,s,l){var c=this;return r.forEach(function(p){c.processors[p]&&(n=c.processors[p].process(n,a,s,l))}),n}};function mp(t,r){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);r&&(a=a.filter(function(s){return Object.getOwnPropertyDescriptor(t,s).enumerable})),n.push.apply(n,a)}return n}function yt(t){for(var r=1;r"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(t){return!1}}var fp={},hp=function(t){Ws(n,t);var r=jh(n);function n(a){var s,l=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return xr(this,n),s=r.call(this),Ci&&Rn.call(_r(s)),Ih(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],a,_r(s)),s.options=l,s.options.keySeparator===void 0&&(s.options.keySeparator="."),s.logger=Gr.create("translator"),s}return Mr(n,[{key:"changeLanguage",value:function(s){s&&(this.language=s)}},{key:"exists",value:function(s){var l=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}};if(s==null)return!1;var c=this.resolve(s,l);return c&&c.res!==void 0}},{key:"extractFromKey",value:function(s,l){var c=l.nsSeparator!==void 0?l.nsSeparator:this.options.nsSeparator;c===void 0&&(c=":");var p=l.keySeparator!==void 0?l.keySeparator:this.options.keySeparator,g=l.ns||this.options.defaultNS||[],m=c&&s.indexOf(c)>-1,h=!this.options.userDefinedKeySeparator&&!l.keySeparator&&!this.options.userDefinedNsSeparator&&!l.nsSeparator&&!Hh(s,c,p);if(m&&!h){var b=s.match(this.interpolator.nestingRegexp);if(b&&b.length>0)return{key:s,namespaces:g};var C=s.split(c);(c!==p||c===p&&this.options.ns.indexOf(C[0])>-1)&&(g=C.shift()),s=C.join(p)}return typeof g=="string"&&(g=[g]),{key:s,namespaces:g}}},{key:"translate",value:function(s,l,c){var p=this;if(bt(l)!=="object"&&this.options.overloadTranslationOptionHandler&&(l=this.options.overloadTranslationOptionHandler(arguments)),bt(l)==="object"&&(l=yt({},l)),l||(l={}),s==null)return"";Array.isArray(s)||(s=[String(s)]);var g=l.returnDetails!==void 0?l.returnDetails:this.options.returnDetails,m=l.keySeparator!==void 0?l.keySeparator:this.options.keySeparator,h=this.extractFromKey(s[s.length-1],l),b=h.key,C=h.namespaces,v=C[C.length-1],x=l.lng||this.language,B=l.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if(x&&x.toLowerCase()==="cimode"){if(B){var U=l.nsSeparator||this.options.nsSeparator;return g?{res:"".concat(v).concat(U).concat(b),usedKey:b,exactUsedKey:b,usedLng:x,usedNS:v}:"".concat(v).concat(U).concat(b)}return g?{res:b,usedKey:b,exactUsedKey:b,usedLng:x,usedNS:v}:b}var k=this.resolve(s,l),L=k&&k.res,E=k&&k.usedKey||b,T=k&&k.exactUsedKey||b,S=Object.prototype.toString.apply(L),I=["[object Number]","[object Function]","[object RegExp]"],N=l.joinArrays!==void 0?l.joinArrays:this.options.joinArrays,X=!this.i18nFormat||this.i18nFormat.handleAsObject,re=typeof L!="string"&&typeof L!="boolean"&&typeof L!="number";if(X&&L&&re&&I.indexOf(S)<0&&!(typeof N=="string"&&S==="[object Array]")){if(!l.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");var w=this.options.returnedObjectHandler?this.options.returnedObjectHandler(E,L,yt(yt({},l),{},{ns:C})):"key '".concat(b," (").concat(this.language,")' returned an object instead of string.");return g?(k.res=w,k):w}if(m){var H=S==="[object Array]",J=H?[]:{},Te=H?T:E;for(var ut in L)if(Object.prototype.hasOwnProperty.call(L,ut)){var ft="".concat(Te).concat(m).concat(ut);J[ut]=this.translate(ft,yt(yt({},l),{joinArrays:!1,ns:C})),J[ut]===ft&&(J[ut]=L[ut])}L=J}}else if(X&&typeof N=="string"&&S==="[object Array]")L=L.join(N),L&&(L=this.extendTranslation(L,s,l,c));else{var xt=!1,Gt=!1,er=l.count!==void 0&&typeof l.count!="string",Ht=n.hasDefaultValue(l),ce=er?this.pluralResolver.getSuffix(x,l.count,l):"",z=l["defaultValue".concat(ce)]||l.defaultValue;!this.isValidLookup(L)&&Ht&&(xt=!0,L=z),this.isValidLookup(L)||(Gt=!0,L=b);var Z=l.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey,se=Z&&Gt?void 0:L,ne=Ht&&z!==L&&this.options.updateMissing;if(Gt||xt||ne){if(this.logger.log(ne?"updateKey":"missingKey",x,v,b,ne?z:L),m){var he=this.resolve(b,yt(yt({},l),{},{keySeparator:!1}));he&&he.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}var Fe=[],Mt=this.languageUtils.getFallbackCodes(this.options.fallbackLng,l.lng||this.language);if(this.options.saveMissingTo==="fallback"&&Mt&&Mt[0])for(var A=0;A1&&arguments[1]!==void 0?arguments[1]:{},p,g,m,h,b;return typeof s=="string"&&(s=[s]),s.forEach(function(C){if(!l.isValidLookup(p)){var v=l.extractFromKey(C,c),x=v.key;g=x;var B=v.namespaces;l.options.fallbackNS&&(B=B.concat(l.options.fallbackNS));var U=c.count!==void 0&&typeof c.count!="string",k=U&&!c.ordinal&&c.count===0&&l.pluralResolver.shouldUseIntlApi(),L=c.context!==void 0&&(typeof c.context=="string"||typeof c.context=="number")&&c.context!=="",E=c.lngs?c.lngs:l.languageUtils.toResolveHierarchy(c.lng||l.language,c.fallbackLng);B.forEach(function(T){l.isValidLookup(p)||(b=T,!fp["".concat(E[0],"-").concat(T)]&&l.utils&&l.utils.hasLoadedNamespace&&!l.utils.hasLoadedNamespace(b)&&(fp["".concat(E[0],"-").concat(T)]=!0,l.logger.warn('key "'.concat(g,'" for languages "').concat(E.join(", "),`" won't get resolved as namespace "`).concat(b,'" was not yet loaded'),"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),E.forEach(function(S){if(!l.isValidLookup(p)){h=S;var I=[x];if(l.i18nFormat&&l.i18nFormat.addLookupKeys)l.i18nFormat.addLookupKeys(I,x,S,T,c);else{var N;U&&(N=l.pluralResolver.getSuffix(S,c.count,c));var X="".concat(l.options.pluralSeparator,"zero");if(U&&(I.push(x+N),k&&I.push(x+X)),L){var re="".concat(x).concat(l.options.contextSeparator).concat(c.context);I.push(re),U&&(I.push(re+N),k&&I.push(re+X))}}for(var w;w=I.pop();)l.isValidLookup(p)||(m=w,p=l.getResource(S,T,w,c))}}))})}}),{res:p,usedKey:g,exactUsedKey:m,usedLng:h,usedNS:b}}},{key:"isValidLookup",value:function(s){return s!==void 0&&!(!this.options.returnNull&&s===null)&&!(!this.options.returnEmptyString&&s==="")}},{key:"getResource",value:function(s,l,c){var p=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};return this.i18nFormat&&this.i18nFormat.getResource?this.i18nFormat.getResource(s,l,c,p):this.resourceStore.getResource(s,l,c,p)}}],[{key:"hasDefaultValue",value:function(s){var l="defaultValue";for(var c in s)if(Object.prototype.hasOwnProperty.call(s,c)&&l===c.substring(0,l.length)&&s[c]!==void 0)return!0;return!1}}]),n}(Rn);function mc(t){return t.charAt(0).toUpperCase()+t.slice(1)}var bp=function(){function t(r){xr(this,t),this.options=r,this.supportedLngs=this.options.supportedLngs||!1,this.logger=Gr.create("languageUtils")}return Mr(t,[{key:"getScriptPartFromCode",value:function(n){if(!n||n.indexOf("-")<0)return null;var a=n.split("-");return a.length===2||(a.pop(),a[a.length-1].toLowerCase()==="x")?null:this.formatLanguageCode(a.join("-"))}},{key:"getLanguagePartFromCode",value:function(n){if(!n||n.indexOf("-")<0)return n;var a=n.split("-");return this.formatLanguageCode(a[0])}},{key:"formatLanguageCode",value:function(n){if(typeof n=="string"&&n.indexOf("-")>-1){var a=["hans","hant","latn","cyrl","cans","mong","arab"],s=n.split("-");return this.options.lowerCaseLng?s=s.map(function(l){return l.toLowerCase()}):s.length===2?(s[0]=s[0].toLowerCase(),s[1]=s[1].toUpperCase(),a.indexOf(s[1].toLowerCase())>-1&&(s[1]=mc(s[1].toLowerCase()))):s.length===3&&(s[0]=s[0].toLowerCase(),s[1].length===2&&(s[1]=s[1].toUpperCase()),s[0]!=="sgn"&&s[2].length===2&&(s[2]=s[2].toUpperCase()),a.indexOf(s[1].toLowerCase())>-1&&(s[1]=mc(s[1].toLowerCase())),a.indexOf(s[2].toLowerCase())>-1&&(s[2]=mc(s[2].toLowerCase()))),s.join("-")}return this.options.cleanCode||this.options.lowerCaseLng?n.toLowerCase():n}},{key:"isSupportedCode",value:function(n){return(this.options.load==="languageOnly"||this.options.nonExplicitSupportedLngs)&&(n=this.getLanguagePartFromCode(n)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(n)>-1}},{key:"getBestMatchFromCodes",value:function(n){var a=this;if(!n)return null;var s;return n.forEach(function(l){if(!s){var c=a.formatLanguageCode(l);(!a.options.supportedLngs||a.isSupportedCode(c))&&(s=c)}}),!s&&this.options.supportedLngs&&n.forEach(function(l){if(!s){var c=a.getLanguagePartFromCode(l);if(a.isSupportedCode(c))return s=c;s=a.options.supportedLngs.find(function(p){if(p===c)return p;if(!(p.indexOf("-")<0&&c.indexOf("-")<0)&&p.indexOf(c)===0)return p})}}),s||(s=this.getFallbackCodes(this.options.fallbackLng)[0]),s}},{key:"getFallbackCodes",value:function(n,a){if(!n)return[];if(typeof n=="function"&&(n=n(a)),typeof n=="string"&&(n=[n]),Object.prototype.toString.apply(n)==="[object Array]")return n;if(!a)return n.default||[];var s=n[a];return s||(s=n[this.getScriptPartFromCode(a)]),s||(s=n[this.formatLanguageCode(a)]),s||(s=n[this.getLanguagePartFromCode(a)]),s||(s=n.default),s||[]}},{key:"toResolveHierarchy",value:function(n,a){var s=this,l=this.getFallbackCodes(a||this.options.fallbackLng||[],n),c=[],p=function(m){m&&(s.isSupportedCode(m)?c.push(m):s.logger.warn("rejecting language code not found in supportedLngs: ".concat(m)))};return typeof n=="string"&&n.indexOf("-")>-1?(this.options.load!=="languageOnly"&&p(this.formatLanguageCode(n)),this.options.load!=="languageOnly"&&this.options.load!=="currentOnly"&&p(this.getScriptPartFromCode(n)),this.options.load!=="currentOnly"&&p(this.getLanguagePartFromCode(n))):typeof n=="string"&&p(this.formatLanguageCode(n)),l.forEach(function(g){c.indexOf(g)<0&&p(s.formatLanguageCode(g))}),c}}]),t}(),Wh=[{lngs:["ach","ak","am","arn","br","fil","gun","ln","mfe","mg","mi","oc","pt","pt-BR","tg","tl","ti","tr","uz","wa"],nr:[1,2],fc:1},{lngs:["af","an","ast","az","bg","bn","ca","da","de","dev","el","en","eo","es","et","eu","fi","fo","fur","fy","gl","gu","ha","hi","hu","hy","ia","it","kk","kn","ku","lb","mai","ml","mn","mr","nah","nap","nb","ne","nl","nn","no","nso","pa","pap","pms","ps","pt-PT","rm","sco","se","si","so","son","sq","sv","sw","ta","te","tk","ur","yo"],nr:[1,2],fc:2},{lngs:["ay","bo","cgg","fa","ht","id","ja","jbo","ka","km","ko","ky","lo","ms","sah","su","th","tt","ug","vi","wo","zh"],nr:[1],fc:3},{lngs:["be","bs","cnr","dz","hr","ru","sr","uk"],nr:[1,2,5],fc:4},{lngs:["ar"],nr:[0,1,2,3,11,100],fc:5},{lngs:["cs","sk"],nr:[1,2,5],fc:6},{lngs:["csb","pl"],nr:[1,2,5],fc:7},{lngs:["cy"],nr:[1,2,3,8],fc:8},{lngs:["fr"],nr:[1,2],fc:9},{lngs:["ga"],nr:[1,2,3,7,11],fc:10},{lngs:["gd"],nr:[1,2,3,20],fc:11},{lngs:["is"],nr:[1,2],fc:12},{lngs:["jv"],nr:[0,1],fc:13},{lngs:["kw"],nr:[1,2,3,4],fc:14},{lngs:["lt"],nr:[1,2,10],fc:15},{lngs:["lv"],nr:[1,2,0],fc:16},{lngs:["mk"],nr:[1,2],fc:17},{lngs:["mnk"],nr:[0,1,2],fc:18},{lngs:["mt"],nr:[1,2,11,20],fc:19},{lngs:["or"],nr:[2,1],fc:2},{lngs:["ro"],nr:[1,2,20],fc:20},{lngs:["sl"],nr:[5,1,2,3],fc:21},{lngs:["he","iw"],nr:[1,2,20,21],fc:22}],Kh={1:function(r){return+(r>1)},2:function(r){return+(r!=1)},3:function(r){return 0},4:function(r){return r%10==1&&r%100!=11?0:r%10>=2&&r%10<=4&&(r%100<10||r%100>=20)?1:2},5:function(r){return r==0?0:r==1?1:r==2?2:r%100>=3&&r%100<=10?3:r%100>=11?4:5},6:function(r){return r==1?0:r>=2&&r<=4?1:2},7:function(r){return r==1?0:r%10>=2&&r%10<=4&&(r%100<10||r%100>=20)?1:2},8:function(r){return r==1?0:r==2?1:r!=8&&r!=11?2:3},9:function(r){return+(r>=2)},10:function(r){return r==1?0:r==2?1:r<7?2:r<11?3:4},11:function(r){return r==1||r==11?0:r==2||r==12?1:r>2&&r<20?2:3},12:function(r){return+(r%10!=1||r%100==11)},13:function(r){return+(r!==0)},14:function(r){return r==1?0:r==2?1:r==3?2:3},15:function(r){return r%10==1&&r%100!=11?0:r%10>=2&&(r%100<10||r%100>=20)?1:2},16:function(r){return r%10==1&&r%100!=11?0:r!==0?1:2},17:function(r){return r==1||r%10==1&&r%100!=11?0:1},18:function(r){return r==0?0:r==1?1:2},19:function(r){return r==1?0:r==0||r%100>1&&r%100<11?1:r%100>10&&r%100<20?2:3},20:function(r){return r==1?0:r==0||r%100>0&&r%100<20?1:2},21:function(r){return r%100==1?1:r%100==2?2:r%100==3||r%100==4?3:0},22:function(r){return r==1?0:r==2?1:(r<0||r>10)&&r%10==0?2:3}},zh=["v1","v2","v3"],yp={zero:0,one:1,two:2,few:3,many:4,other:5};function Xh(){var t={};return Wh.forEach(function(r){r.lngs.forEach(function(n){t[n]={numbers:r.nr,plurals:Kh[r.fc]}})}),t}var Zh=function(){function t(r){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};xr(this,t),this.languageUtils=r,this.options=n,this.logger=Gr.create("pluralResolver"),(!this.options.compatibilityJSON||this.options.compatibilityJSON==="v4")&&(typeof Intl>"u"||!Intl.PluralRules)&&(this.options.compatibilityJSON="v3",this.logger.error("Your environment seems not to be Intl API compatible, use an Intl.PluralRules polyfill. Will fallback to the compatibilityJSON v3 format handling.")),this.rules=Xh()}return Mr(t,[{key:"addRule",value:function(n,a){this.rules[n]=a}},{key:"getRule",value:function(n){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(this.shouldUseIntlApi())try{return new Intl.PluralRules(n,{type:a.ordinal?"ordinal":"cardinal"})}catch(s){return}return this.rules[n]||this.rules[this.languageUtils.getLanguagePartFromCode(n)]}},{key:"needsPlural",value:function(n){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},s=this.getRule(n,a);return this.shouldUseIntlApi()?s&&s.resolvedOptions().pluralCategories.length>1:s&&s.numbers.length>1}},{key:"getPluralFormsOfKey",value:function(n,a){var s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return this.getSuffixes(n,s).map(function(l){return"".concat(a).concat(l)})}},{key:"getSuffixes",value:function(n){var a=this,s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},l=this.getRule(n,s);return l?this.shouldUseIntlApi()?l.resolvedOptions().pluralCategories.sort(function(c,p){return yp[c]-yp[p]}).map(function(c){return"".concat(a.options.prepend).concat(c)}):l.numbers.map(function(c){return a.getSuffix(n,c,s)}):[]}},{key:"getSuffix",value:function(n,a){var s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},l=this.getRule(n,s);return l?this.shouldUseIntlApi()?"".concat(this.options.prepend).concat(l.select(a)):this.getSuffixRetroCompatible(l,a):(this.logger.warn("no plural rule found for: ".concat(n)),"")}},{key:"getSuffixRetroCompatible",value:function(n,a){var s=this,l=n.noAbs?n.plurals(a):n.plurals(Math.abs(a)),c=n.numbers[l];this.options.simplifyPluralSuffix&&n.numbers.length===2&&n.numbers[0]===1&&(c===2?c="plural":c===1&&(c=""));var p=function(){return s.options.prepend&&c.toString()?s.options.prepend+c.toString():c.toString()};return this.options.compatibilityJSON==="v1"?c===1?"":typeof c=="number"?"_plural_".concat(c.toString()):p():this.options.compatibilityJSON==="v2"||this.options.simplifyPluralSuffix&&n.numbers.length===2&&n.numbers[0]===1?p():this.options.prepend&&l.toString()?this.options.prepend+l.toString():l.toString()}},{key:"shouldUseIntlApi",value:function(){return!zh.includes(this.options.compatibilityJSON)}}]),t}();function vp(t,r){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);r&&(a=a.filter(function(s){return Object.getOwnPropertyDescriptor(t,s).enumerable})),n.push.apply(n,a)}return n}function Sr(t){for(var r=1;r3&&arguments[3]!==void 0?arguments[3]:".",s=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!0,l=$h(t,r,n);return!l&&s&&typeof n=="string"&&(l=yi(t,n,a),l===void 0&&(l=yi(r,n,a))),l}var Yh=function(){function t(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};xr(this,t),this.logger=Gr.create("interpolator"),this.options=r,this.format=r.interpolation&&r.interpolation.format||function(n){return n},this.init(r)}return Mr(t,[{key:"init",value:function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};n.interpolation||(n.interpolation={escapeValue:!0});var a=n.interpolation;this.escape=a.escape!==void 0?a.escape:Dh,this.escapeValue=a.escapeValue!==void 0?a.escapeValue:!0,this.useRawValueToEscape=a.useRawValueToEscape!==void 0?a.useRawValueToEscape:!1,this.prefix=a.prefix?ts(a.prefix):a.prefixEscaped||"{{",this.suffix=a.suffix?ts(a.suffix):a.suffixEscaped||"}}",this.formatSeparator=a.formatSeparator?a.formatSeparator:a.formatSeparator||",",this.unescapePrefix=a.unescapeSuffix?"":a.unescapePrefix||"-",this.unescapeSuffix=this.unescapePrefix?"":a.unescapeSuffix||"",this.nestingPrefix=a.nestingPrefix?ts(a.nestingPrefix):a.nestingPrefixEscaped||ts("$t("),this.nestingSuffix=a.nestingSuffix?ts(a.nestingSuffix):a.nestingSuffixEscaped||ts(")"),this.nestingOptionsSeparator=a.nestingOptionsSeparator?a.nestingOptionsSeparator:a.nestingOptionsSeparator||",",this.maxReplaces=a.maxReplaces?a.maxReplaces:1e3,this.alwaysFormat=a.alwaysFormat!==void 0?a.alwaysFormat:!1,this.resetRegExp()}},{key:"reset",value:function(){this.options&&this.init(this.options)}},{key:"resetRegExp",value:function(){var n="".concat(this.prefix,"(.+?)").concat(this.suffix);this.regexp=new RegExp(n,"g");var a="".concat(this.prefix).concat(this.unescapePrefix,"(.+?)").concat(this.unescapeSuffix).concat(this.suffix);this.regexpUnescape=new RegExp(a,"g");var s="".concat(this.nestingPrefix,"(.+?)").concat(this.nestingSuffix);this.nestingRegexp=new RegExp(s,"g")}},{key:"interpolate",value:function(n,a,s,l){var c=this,p,g,m,h=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{};function b(U){return U.replace(/\$/g,"$$$$")}var C=function(k){if(k.indexOf(c.formatSeparator)<0){var L=Cp(a,h,k,c.options.keySeparator,c.options.ignoreJSONStructure);return c.alwaysFormat?c.format(L,void 0,s,Sr(Sr(Sr({},l),a),{},{interpolationkey:k})):L}var E=k.split(c.formatSeparator),T=E.shift().trim(),S=E.join(c.formatSeparator).trim();return c.format(Cp(a,h,T,c.options.keySeparator,c.options.ignoreJSONStructure),S,s,Sr(Sr(Sr({},l),a),{},{interpolationkey:T}))};this.resetRegExp();var v=l&&l.missingInterpolationHandler||this.options.missingInterpolationHandler,x=l&&l.interpolation&&l.interpolation.skipOnVariables!==void 0?l.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables,B=[{regex:this.regexpUnescape,safeValue:function(k){return b(k)}},{regex:this.regexp,safeValue:function(k){return c.escapeValue?b(c.escape(k)):b(k)}}];return B.forEach(function(U){for(m=0;p=U.regex.exec(n);){var k=p[1].trim();if(g=C(k),g===void 0)if(typeof v=="function"){var L=v(n,p,l);g=typeof L=="string"?L:""}else if(l&&Object.prototype.hasOwnProperty.call(l,k))g="";else if(x){g=p[0];continue}else c.logger.warn("missed to pass in variable ".concat(k," for interpolating ").concat(n)),g="";else typeof g!="string"&&!c.useRawValueToEscape&&(g=dp(g));var E=U.safeValue(g);if(n=n.replace(p[0],E),x?(U.regex.lastIndex+=g.length,U.regex.lastIndex-=p[0].length):U.regex.lastIndex=0,m++,m>=c.maxReplaces)break}}),n}},{key:"nest",value:function(n,a){var s=this,l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},c,p,g;function m(v,x){var B=this.nestingOptionsSeparator;if(v.indexOf(B)<0)return v;var U=v.split(new RegExp("".concat(B,"[ ]*{"))),k="{".concat(U[1]);v=U[0],k=this.interpolate(k,g);var L=k.match(/'/g),E=k.match(/"/g);(L&&L.length%2===0&&!E||E.length%2!==0)&&(k=k.replace(/'/g,'"'));try{g=JSON.parse(k),x&&(g=Sr(Sr({},x),g))}catch(T){return this.logger.warn("failed parsing options string in nesting for key ".concat(v),T),"".concat(v).concat(B).concat(k)}return delete g.defaultValue,v}for(;c=this.nestingRegexp.exec(n);){var h=[];g=Sr({},l),g=g.replace&&typeof g.replace!="string"?g.replace:g,g.applyPostProcessor=!1,delete g.defaultValue;var b=!1;if(c[0].indexOf(this.formatSeparator)!==-1&&!/{.*}/.test(c[1])){var C=c[1].split(this.formatSeparator).map(function(v){return v.trim()});c[1]=C.shift(),h=C,b=!0}if(p=a(m.call(this,c[1].trim(),g),g),p&&c[0]===n&&typeof p!="string")return p;typeof p!="string"&&(p=dp(p)),p||(this.logger.warn("missed to resolve ".concat(c[1]," for nesting ").concat(n)),p=""),b&&(p=h.reduce(function(v,x){return s.format(v,x,l.lng,Sr(Sr({},l),{},{interpolationkey:c[1].trim()}))},p.trim())),n=n.replace(c[0],p),this.regexp.lastIndex=0}return n}}]),t}();function wp(t,r){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);r&&(a=a.filter(function(s){return Object.getOwnPropertyDescriptor(t,s).enumerable})),n.push.apply(n,a)}return n}function tn(t){for(var r=1;r-1){var a=t.split("(");r=a[0].toLowerCase().trim();var s=a[1].substring(0,a[1].length-1);if(r==="currency"&&s.indexOf(":")<0)n.currency||(n.currency=s.trim());else if(r==="relativetime"&&s.indexOf(":")<0)n.range||(n.range=s.trim());else{var l=s.split(";");l.forEach(function(c){if(c){var p=c.split(":"),g=lp(p),m=g[0],h=g.slice(1),b=h.join(":").trim().replace(/^'+|'+$/g,"");n[m.trim()]||(n[m.trim()]=b),b==="false"&&(n[m.trim()]=!1),b==="true"&&(n[m.trim()]=!0),isNaN(b)||(n[m.trim()]=parseInt(b,10))}})}}return{formatName:r,formatOptions:n}}function rs(t){var r={};return function(a,s,l){var c=s+JSON.stringify(l),p=r[c];return p||(p=t(s,l),r[c]=p),p(a)}}var e1=function(){function t(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};xr(this,t),this.logger=Gr.create("formatter"),this.options=r,this.formats={number:rs(function(n,a){var s=new Intl.NumberFormat(n,tn({},a));return function(l){return s.format(l)}}),currency:rs(function(n,a){var s=new Intl.NumberFormat(n,tn(tn({},a),{},{style:"currency"}));return function(l){return s.format(l)}}),datetime:rs(function(n,a){var s=new Intl.DateTimeFormat(n,tn({},a));return function(l){return s.format(l)}}),relativetime:rs(function(n,a){var s=new Intl.RelativeTimeFormat(n,tn({},a));return function(l){return s.format(l,a.range||"day")}}),list:rs(function(n,a){var s=new Intl.ListFormat(n,tn({},a));return function(l){return s.format(l)}})},this.init(r)}return Mr(t,[{key:"init",value:function(n){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}},s=a.interpolation;this.formatSeparator=s.formatSeparator?s.formatSeparator:s.formatSeparator||","}},{key:"add",value:function(n,a){this.formats[n.toLowerCase().trim()]=a}},{key:"addCached",value:function(n,a){this.formats[n.toLowerCase().trim()]=rs(a)}},{key:"format",value:function(n,a,s){var l=this,c=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},p=a.split(this.formatSeparator),g=p.reduce(function(m,h){var b=Jh(h),C=b.formatName,v=b.formatOptions;if(l.formats[C]){var x=m;try{var B=c&&c.formatParams&&c.formatParams[c.interpolationkey]||{},U=B.locale||B.lng||c.locale||c.lng||s;x=l.formats[C](m,U,tn(tn(tn({},v),c),B))}catch(k){l.logger.warn(k)}return x}else l.logger.warn("there was no format function for ".concat(C));return m},n);return g}}]),t}();function xp(t,r){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);r&&(a=a.filter(function(s){return Object.getOwnPropertyDescriptor(t,s).enumerable})),n.push.apply(n,a)}return n}function Mp(t){for(var r=1;r"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(t){return!1}}function n1(t,r){t.pending[r]!==void 0&&(delete t.pending[r],t.pendingCount--)}var a1=function(t){Ws(n,t);var r=t1(n);function n(a,s,l){var c,p=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};return xr(this,n),c=r.call(this),Ci&&Rn.call(_r(c)),c.backend=a,c.store=s,c.services=l,c.languageUtils=l.languageUtils,c.options=p,c.logger=Gr.create("backendConnector"),c.waitingReads=[],c.maxParallelReads=p.maxParallelReads||10,c.readingCalls=0,c.maxRetries=p.maxRetries>=0?p.maxRetries:5,c.retryTimeout=p.retryTimeout>=1?p.retryTimeout:350,c.state={},c.queue=[],c.backend&&c.backend.init&&c.backend.init(l,p.backend,p),c}return Mr(n,[{key:"queueLoad",value:function(s,l,c,p){var g=this,m={},h={},b={},C={};return s.forEach(function(v){var x=!0;l.forEach(function(B){var U="".concat(v,"|").concat(B);!c.reload&&g.store.hasResourceBundle(v,B)?g.state[U]=2:g.state[U]<0||(g.state[U]===1?h[U]===void 0&&(h[U]=!0):(g.state[U]=1,x=!1,h[U]===void 0&&(h[U]=!0),m[U]===void 0&&(m[U]=!0),C[B]===void 0&&(C[B]=!0)))}),x||(b[v]=!0)}),(Object.keys(m).length||Object.keys(h).length)&&this.queue.push({pending:h,pendingCount:Object.keys(h).length,loaded:{},errors:[],callback:p}),{toLoad:Object.keys(m),pending:Object.keys(h),toLoadLanguages:Object.keys(b),toLoadNamespaces:Object.keys(C)}}},{key:"loaded",value:function(s,l,c){var p=s.split("|"),g=p[0],m=p[1];l&&this.emit("failedLoading",g,m,l),c&&this.store.addResourceBundle(g,m,c),this.state[s]=l?-1:2;var h={};this.queue.forEach(function(b){Nh(b.loaded,[g],m),n1(b,s),l&&b.errors.push(l),b.pendingCount===0&&!b.done&&(Object.keys(b.loaded).forEach(function(C){h[C]||(h[C]={});var v=b.loaded[C];v.length&&v.forEach(function(x){h[C][x]===void 0&&(h[C][x]=!0)})}),b.done=!0,b.errors.length?b.callback(b.errors):b.callback())}),this.emit("loaded",h),this.queue=this.queue.filter(function(b){return!b.done})}},{key:"read",value:function(s,l,c){var p=this,g=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0,m=arguments.length>4&&arguments[4]!==void 0?arguments[4]:this.retryTimeout,h=arguments.length>5?arguments[5]:void 0;if(!s.length)return h(null,{});if(this.readingCalls>=this.maxParallelReads){this.waitingReads.push({lng:s,ns:l,fcName:c,tried:g,wait:m,callback:h});return}this.readingCalls++;var b=function(B,U){if(p.readingCalls--,p.waitingReads.length>0){var k=p.waitingReads.shift();p.read(k.lng,k.ns,k.fcName,k.tried,k.wait,k.callback)}if(B&&U&&g2&&arguments[2]!==void 0?arguments[2]:{},g=arguments.length>3?arguments[3]:void 0;if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),g&&g();typeof s=="string"&&(s=this.languageUtils.toResolveHierarchy(s)),typeof l=="string"&&(l=[l]);var m=this.queueLoad(s,l,p,g);if(!m.toLoad.length)return m.pending.length||g(),null;m.toLoad.forEach(function(h){c.loadOne(h)})}},{key:"load",value:function(s,l,c){this.prepareLoading(s,l,{},c)}},{key:"reload",value:function(s,l,c){this.prepareLoading(s,l,{reload:!0},c)}},{key:"loadOne",value:function(s){var l=this,c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",p=s.split("|"),g=p[0],m=p[1];this.read(g,m,"read",void 0,void 0,function(h,b){h&&l.logger.warn("".concat(c,"loading namespace ").concat(m," for language ").concat(g," failed"),h),!h&&b&&l.logger.log("".concat(c,"loaded namespace ").concat(m," for language ").concat(g),b),l.loaded(s,h,b)})}},{key:"saveMissing",value:function(s,l,c,p,g){var m=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{},h=arguments.length>6&&arguments[6]!==void 0?arguments[6]:function(){};if(this.services.utils&&this.services.utils.hasLoadedNamespace&&!this.services.utils.hasLoadedNamespace(l)){this.logger.warn('did not save key "'.concat(c,'" as the namespace "').concat(l,'" was not yet loaded'),"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!");return}if(!(c==null||c==="")){if(this.backend&&this.backend.create){var b=Mp(Mp({},m),{},{isUpdate:g}),C=this.backend.create.bind(this.backend);if(C.length<6)try{var v;C.length===5?v=C(s,l,c,p,b):v=C(s,l,c,p),v&&typeof v.then=="function"?v.then(function(x){return h(null,x)}).catch(h):h(null,v)}catch(x){h(x)}else C(s,l,c,p,h,b)}!s||!s[0]||this.store.addResource(s[0],l,c,p)}}}]),n}(Rn);function Tp(){return{debug:!1,initImmediate:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!0,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:function(r){var n={};if(bt(r[1])==="object"&&(n=r[1]),typeof r[1]=="string"&&(n.defaultValue=r[1]),typeof r[2]=="string"&&(n.tDescription=r[2]),bt(r[2])==="object"||bt(r[3])==="object"){var a=r[3]||r[2];Object.keys(a).forEach(function(s){n[s]=a[s]})}return n},interpolation:{escapeValue:!0,format:function(r,n,a,s){return r},prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0}}}function Sp(t){return typeof t.ns=="string"&&(t.ns=[t.ns]),typeof t.fallbackLng=="string"&&(t.fallbackLng=[t.fallbackLng]),typeof t.fallbackNS=="string"&&(t.fallbackNS=[t.fallbackNS]),t.supportedLngs&&t.supportedLngs.indexOf("cimode")<0&&(t.supportedLngs=t.supportedLngs.concat(["cimode"])),t}function kp(t,r){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);r&&(a=a.filter(function(s){return Object.getOwnPropertyDescriptor(t,s).enumerable})),n.push.apply(n,a)}return n}function Dr(t){for(var r=1;r"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(t){return!1}}function hi(){}function i1(t){var r=Object.getOwnPropertyNames(Object.getPrototypeOf(t));r.forEach(function(n){typeof t[n]=="function"&&(t[n]=t[n].bind(t))})}var vi=function(t){Ws(n,t);var r=s1(n);function n(){var a,s=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},l=arguments.length>1?arguments[1]:void 0;if(xr(this,n),a=r.call(this),Ci&&Rn.call(_r(a)),a.options=Sp(s),a.services={},a.logger=Gr,a.modules={external:[]},i1(_r(a)),l&&!a.isInitialized&&!s.isClone){if(!a.options.initImmediate)return a.init(s,l),es(a,_r(a));setTimeout(function(){a.init(s,l)},0)}return a}return Mr(n,[{key:"init",value:function(){var s=this,l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},c=arguments.length>1?arguments[1]:void 0;typeof l=="function"&&(c=l,l={}),!l.defaultNS&&l.defaultNS!==!1&&l.ns&&(typeof l.ns=="string"?l.defaultNS=l.ns:l.ns.indexOf("translation")<0&&(l.defaultNS=l.ns[0]));var p=Tp();this.options=Dr(Dr(Dr({},p),this.options),Sp(l)),this.options.compatibilityAPI!=="v1"&&(this.options.interpolation=Dr(Dr({},p.interpolation),this.options.interpolation)),l.keySeparator!==void 0&&(this.options.userDefinedKeySeparator=l.keySeparator),l.nsSeparator!==void 0&&(this.options.userDefinedNsSeparator=l.nsSeparator);function g(k){return k?typeof k=="function"?new k:k:null}if(!this.options.isClone){this.modules.logger?Gr.init(g(this.modules.logger),this.options):Gr.init(null,this.options);var m;this.modules.formatter?m=this.modules.formatter:typeof Intl<"u"&&(m=e1);var h=new bp(this.options);this.store=new qh(this.options.resources,this.options);var b=this.services;b.logger=Gr,b.resourceStore=this.store,b.languageUtils=h,b.pluralResolver=new Zh(h,{prepend:this.options.pluralSeparator,compatibilityJSON:this.options.compatibilityJSON,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),m&&(!this.options.interpolation.format||this.options.interpolation.format===p.interpolation.format)&&(b.formatter=g(m),b.formatter.init(b,this.options),this.options.interpolation.format=b.formatter.format.bind(b.formatter)),b.interpolator=new Yh(this.options),b.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},b.backendConnector=new a1(g(this.modules.backend),b.resourceStore,b,this.options),b.backendConnector.on("*",function(k){for(var L=arguments.length,E=new Array(L>1?L-1:0),T=1;T1?L-1:0),T=1;T0&&C[0]!=="dev"&&(this.options.lng=C[0])}!this.services.languageDetector&&!this.options.lng&&this.logger.warn("init: no languageDetector is used and no lng is defined");var v=["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"];v.forEach(function(k){s[k]=function(){var L;return(L=s.store)[k].apply(L,arguments)}});var x=["addResource","addResources","addResourceBundle","removeResourceBundle"];x.forEach(function(k){s[k]=function(){var L;return(L=s.store)[k].apply(L,arguments),s}});var B=Ks(),U=function(){var L=function(T,S){s.isInitialized&&!s.initializedStoreOnce&&s.logger.warn("init: i18next is already initialized. You should call init just once!"),s.isInitialized=!0,s.options.isClone||s.logger.log("initialized",s.options),s.emit("initialized",s.options),B.resolve(S),c(T,S)};if(s.languages&&s.options.compatibilityAPI!=="v1"&&!s.isInitialized)return L(null,s.t.bind(s));s.changeLanguage(s.options.lng,L)};return this.options.resources||!this.options.initImmediate?U():setTimeout(U,0),B}},{key:"loadResources",value:function(s){var l=this,c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:hi,p=c,g=typeof s=="string"?s:this.language;if(typeof s=="function"&&(p=s),!this.options.resources||this.options.partialBundledLanguages){if(g&&g.toLowerCase()==="cimode")return p();var m=[],h=function(v){if(v){var x=l.services.languageUtils.toResolveHierarchy(v);x.forEach(function(B){m.indexOf(B)<0&&m.push(B)})}};if(g)h(g);else{var b=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);b.forEach(function(C){return h(C)})}this.options.preload&&this.options.preload.forEach(function(C){return h(C)}),this.services.backendConnector.load(m,this.options.ns,function(C){!C&&!l.resolvedLanguage&&l.language&&l.setResolvedLanguage(l.language),p(C)})}else p(null)}},{key:"reloadResources",value:function(s,l,c){var p=Ks();return s||(s=this.languages),l||(l=this.options.ns),c||(c=hi),this.services.backendConnector.reload(s,l,function(g){p.resolve(),c(g)}),p}},{key:"use",value:function(s){if(!s)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!s.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return s.type==="backend"&&(this.modules.backend=s),(s.type==="logger"||s.log&&s.warn&&s.error)&&(this.modules.logger=s),s.type==="languageDetector"&&(this.modules.languageDetector=s),s.type==="i18nFormat"&&(this.modules.i18nFormat=s),s.type==="postProcessor"&&Pp.addPostProcessor(s),s.type==="formatter"&&(this.modules.formatter=s),s.type==="3rdParty"&&this.modules.external.push(s),this}},{key:"setResolvedLanguage",value:function(s){if(!(!s||!this.languages)&&!(["cimode","dev"].indexOf(s)>-1))for(var l=0;l-1)&&this.store.hasLanguageSomeTranslations(c)){this.resolvedLanguage=c;break}}}},{key:"changeLanguage",value:function(s,l){var c=this;this.isLanguageChangingTo=s;var p=Ks();this.emit("languageChanging",s);var g=function(C){c.language=C,c.languages=c.services.languageUtils.toResolveHierarchy(C),c.resolvedLanguage=void 0,c.setResolvedLanguage(C)},m=function(C,v){v?(g(v),c.translator.changeLanguage(v),c.isLanguageChangingTo=void 0,c.emit("languageChanged",v),c.logger.log("languageChanged",v)):c.isLanguageChangingTo=void 0,p.resolve(function(){return c.t.apply(c,arguments)}),l&&l(C,function(){return c.t.apply(c,arguments)})},h=function(C){!s&&!C&&c.services.languageDetector&&(C=[]);var v=typeof C=="string"?C:c.services.languageUtils.getBestMatchFromCodes(C);v&&(c.language||g(v),c.translator.language||c.translator.changeLanguage(v),c.services.languageDetector&&c.services.languageDetector.cacheUserLanguage&&c.services.languageDetector.cacheUserLanguage(v)),c.loadResources(v,function(x){m(x,v)})};return!s&&this.services.languageDetector&&!this.services.languageDetector.async?h(this.services.languageDetector.detect()):!s&&this.services.languageDetector&&this.services.languageDetector.async?this.services.languageDetector.detect.length===0?this.services.languageDetector.detect().then(h):this.services.languageDetector.detect(h):h(s),p}},{key:"getFixedT",value:function(s,l,c){var p=this,g=function m(h,b){var C;if(bt(b)!=="object"){for(var v=arguments.length,x=new Array(v>2?v-2:0),B=2;B1&&arguments[1]!==void 0?arguments[1]:{};if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;var p=c.lng||this.resolvedLanguage||this.languages[0],g=this.options?this.options.fallbackLng:!1,m=this.languages[this.languages.length-1];if(p.toLowerCase()==="cimode")return!0;var h=function(v,x){var B=l.services.backendConnector.state["".concat(v,"|").concat(x)];return B===-1||B===2};if(c.precheck){var b=c.precheck(this,h);if(b!==void 0)return b}return!!(this.hasResourceBundle(p,s)||!this.services.backendConnector.backend||this.options.resources&&!this.options.partialBundledLanguages||h(p,s)&&(!g||h(m,s)))}},{key:"loadNamespaces",value:function(s,l){var c=this,p=Ks();return this.options.ns?(typeof s=="string"&&(s=[s]),s.forEach(function(g){c.options.ns.indexOf(g)<0&&c.options.ns.push(g)}),this.loadResources(function(g){p.resolve(),l&&l(g)}),p):(l&&l(),Promise.resolve())}},{key:"loadLanguages",value:function(s,l){var c=Ks();typeof s=="string"&&(s=[s]);var p=this.options.preload||[],g=s.filter(function(m){return p.indexOf(m)<0});return g.length?(this.options.preload=p.concat(g),this.loadResources(function(m){c.resolve(),l&&l(m)}),c):(l&&l(),Promise.resolve())}},{key:"dir",value:function(s){if(s||(s=this.resolvedLanguage||(this.languages&&this.languages.length>0?this.languages[0]:this.language)),!s)return"rtl";var l=["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam","ckb"],c=this.services&&this.services.languageUtils||new bp(Tp());return l.indexOf(c.getLanguagePartFromCode(s))>-1||s.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}},{key:"cloneInstance",value:function(){var s=this,l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:hi,p=Dr(Dr(Dr({},this.options),l),{isClone:!0}),g=new n(p);(l.debug!==void 0||l.prefix!==void 0)&&(g.logger=g.logger.clone(l));var m=["store","services","language"];return m.forEach(function(h){g[h]=s[h]}),g.services=Dr({},this.services),g.services.utils={hasLoadedNamespace:g.hasLoadedNamespace.bind(g)},g.translator=new hp(g.services,g.options),g.translator.on("*",function(h){for(var b=arguments.length,C=new Array(b>1?b-1:0),v=1;v0&&arguments[0]!==void 0?arguments[0]:{},r=arguments.length>1?arguments[1]:void 0;return new vi(t,r)});var u=vi.createInstance();u.createInstance=vi.createInstance;var Tw=u.createInstance,Sw=u.dir,kw=u.init,Lw=u.loadResources,Pw=u.reloadResources,Aw=u.use,Ew=u.changeLanguage,Ow=u.getFixedT,Uw=u.t,Bw=u.exists,Rw=u.setDefaultNamespace,Iw=u.hasLoadedNamespace,Nw=u.loadNamespaces,$w=u.loadLanguages;var hc=new Map,i=t=>{let r=hc.get(t);if(r)return r;let n=document.getElementById(t);if(!n)throw new TypeError(`Element with id "${t}" was not found on page?`);return hc.set(t,n),n},wi=t=>hc.has(t);var Op=Un(Ep()),Ct=new Op.default;var In=class{constructor(r){this.level=0;this.freeLevels=0;this.toggleBuy=1;var n,a,s,l;this.name=r.name,this.description=r.description,this.level=(n=r.level)!=null?n:0,this.freeLevels=(a=r.freeLevels)!=null?a:0,this.maxLevel=r.maxLevel,this.costPerLevel=r.costPerLevel,this.toggleBuy=(s=r.toggleBuy)!=null?s:1,this.effect=(l=r.effect)!=null?l:c=>({bonus:c,desc:"WIP not implemented"})}async changeToggle(){let r=await Ee(u.t("dynamicUpgrades.validation.setPurchaseAmount",{x:this.name})),n=Number(r);if(r===null)return P(u.t("dynamicUpgrades.validation.toggleKept",{x:d(this.toggleBuy)}));if(!Number.isInteger(r))return P(u.t("general.validation.fraction"));if(n<-1)return P(u.t("dynamicUpgrades.validation.onlyNegativeOne"));if(n===0)return P(u.t("dynamicUpgrades.validation.notZero"));this.toggleBuy=n;let a=n===-1?u.t("dynamicUpgrades.toggleMax"):u.t("dynamicUpgrades.toggle",{x:d(this.toggleBuy)});return P(a)}getEffect(){let r=this.level+Math.min(this.level,this.freeLevels)+Math.sqrt(Math.max(0,this.freeLevels-this.level));return this.effect(r)}};var f0=Un(vc());var h0=Un(pc());var tr="3.1.1 January 15, 2025 pt 1.4: The Bakery Update";var Nn=new Date(Date.UTC(2025,0,19,19,30,13)),nt=!0;var ia=()=>{let t=Object.keys(e.hypercubeBlessings);for(let r of t){let n=e.hypercubeBlessings[r],a=t.indexOf(r)+1,s=1,l=1;n>=1e3&&(s=o.benedictionDRPower[a],l*=Math.pow(1e3,1-o.benedictionDRPower[a])),o.hypercubeBonusMultiplier[a]=1+l*o.benedictionbase[a]*Math.pow(n,s)*o.platonicBonusMultiplier[4]}};var Mi=()=>{let t=Object.values(e.platonicBlessings),r=[4e6,4e6,4e6,8e4,1e4,1e4,1e4,1e4];for(let n=0;n=1e20&&(l=Math.pow(l,.5)*1e10),t[n]>=r[n]&&(a=o.platonicDRPower[n],s*=Math.pow(r[n],1-o.platonicDRPower[n])),o.platonicBonusMultiplier[n]=1+s*o.platonicCubeBase[n]*Math.pow(l,a)}};var Rt=()=>{let t=9e4;e.researches[195]>0&&(t+=18e3*e.researches[195]);let r=5,n=[99,100,125,180,195];for(let p of n)r+=e.researches[p];r*=+e.octeractUpgrades.octeractExportQuarks.getEffect().bonus;let a=r,s=Math.floor(a*t/3600),l=Math.floor(e.quarkstimer*a/3600),c=_n();return{maxTime:t,perHour:a,capacity:s,gain:l,cubeMult:c}},Up=0,Bp=t=>Up=t,rr=()=>Up,u1,$n=class{constructor(r){this.QUARKS=0;this[u1]=r=>r==="number"?this.QUARKS:null;this.QUARKS=r}applyBonus(r){let n=Ti();return r*(1+rr()/100)*n}add(r,n=!0){return this.QUARKS+=n?this.applyBonus(r):r,e.quarksThisSingularity+=n?this.applyBonus(r):r,this}sub(r){return this.QUARKS-=r,this.QUARKS<0&&(this.QUARKS=0),this}toString(r){return d(Math.floor(this.applyBonus(r)),0,!0)}reset(){this.QUARKS=0}};u1=Symbol.toPrimitive;var la=()=>{let t=[e.tesseractBlessings.accelerator,e.tesseractBlessings.multiplier,e.tesseractBlessings.offering,e.tesseractBlessings.runeExp,e.tesseractBlessings.obtainium,e.tesseractBlessings.antSpeed,e.tesseractBlessings.antSacrifice,e.tesseractBlessings.antELO,e.tesseractBlessings.talismanBonus,e.tesseractBlessings.globalSpeed];for(let r=0;r<10;r++){let n=1,a=1;t[r]>=1e3&&r!==5&&(n=o.giftDRPower[r],a*=Math.pow(1e3,1-o.giftDRPower[r])),o.tesseractBonusMultiplier[r+1]=1+a*o.giftbase[r]*Math.pow(t[r],n)*o.hypercubeBonusMultiplier[r+1]}};var ns={accelerator:{weight:4,pdf:t=>0<=t&&t<=20},multiplier:{weight:4,pdf:t=>2040506070808590950<=t&&t<=33},tesseracts:{weight:13200,pdf:t=>33669999.9999.992599.99599.9975100?P(u.t("cubes.validation.invalidPercent",{x:s})):a?this.open(Math.floor(r.value*(s/100)),s===100,!1):this.open(s,s===r.value,!1)}checkQuarkGain(r,n,a){if(a<1)return 0;let s=n*Rt().cubeMult;return Math.floor(e.worlds.applyBonus(Math.log10(a)*r*s))}checkCubesToNextQuark(r,n,a,s){let l=n*Rt().cubeMult;return Math.ceil(Math.pow(10,(a+1)/e.worlds.applyBonus(l*r))-s)}add(r){return this.value=Math.min(1e300,this.value+r),this}sub(r){return this.value=Math.max(0,this.value-r),this}[Symbol.toPrimitive](r){switch(r){case"string":return this.value.toString();case"number":return this.value;default:return null}}},nr=class extends Dn{constructor(r=Number(e.wowCubes)){super("wowCubes",r)}open(r,n=!1,a=!1){let s=n?Number(this):a?r:Math.min(Number(this),r);r===1&&e.cubeBlessings.accelerator>=2e11&&e.achievements[246]<1&&R(246),a||this.sub(s),e.cubeOpenedDaily+=s;let l=e.shopUpgrades.cubeToQuark?1.5:1,c=Number(this.checkQuarkGain(5,l,e.cubeOpenedDaily)),p=Math.max(0,c-e.cubeQuarkDaily);e.cubeQuarkDaily+=p,e.worlds.add(p,!1),s*=1+e.researches[138]/1e3,s*=1+.8*e.researches[168]/1e3,s*=1+.6*e.researches[198]/1e3,s=Math.floor(s);let g=s%20,m=Math.floor(s/20);m>0&&e.cubeUpgrades[13]===1&&(g+=m),m>0&&e.cubeUpgrades[23]===1&&(g+=m),m>0&&e.cubeUpgrades[33]===1&&(g+=m),m+=100/100*Math.floor(g/20),g=g%20;let h=Object.keys(e.cubeBlessings);for(let b of h)e.cubeBlessings[b]+=ns[b].weight*m*(1+Math.floor(_("ascension",e.challengecompletions[12])));for(let b=0;b0&&(e.platonicBlessings[v]+=m);let h=["hypercubeBonus","taxes","scoreBonus","globalSpeed"];for(let v=0;v=x&&g!==0&&(e.platonicBlessings[h[v]]+=1,g-=1)}let b=[Math.floor(33*g/100),Math.floor(33*g/100),Math.floor(33*g/100),Math.floor(396*g/4e4)],C=["cubes","tesseracts","hypercubes","platonics"];for(let v=0;v0){let v=Math.floor(s*Math.max(0,Math.min(1,(f.log(e.ascendShards.add(1),10)-1e5)/9e5)));e.wowHypercubes.open(v,!1,!0)}}};var xg=Un(wg());var Bi=t=>t instanceof f||typeof t=="object"&&t!==null&&Object.keys(t).length===2&&"mantissa"in t&&"exponent"in t,we=(t=0)=>t<=Number.MAX_SAFE_INTEGER?1:2**Math.floor(Math.log2(t)-52),ae=t=>(t=Array.isArray(t)?t:Object.values(t),t.reduce((r,n)=>r+n,0)),be=t=>t.reduce((r,n)=>r*n),Mg=t=>Array.from([...t.keys()]).sort((r,n)=>t[r]i(t);var Ic=(t,r,n)=>{for(let a=0;a{let a=i(t);for(let s of r)a.classList.add(s);for(let s of n)a.classList.remove(s)},ls=t=>{try{return window.btoa(t)}catch(r){return console.error("An error occurred:",r),null}},eo=t=>{let r="th";return t%10===1&&(r=t%100===11?"th":"st"),t%10===2&&(r=t%100===12?"th":"nd"),t%10===3&&(r=t%100===13?"th":"rd"),d(t,0,!0)+r},_b=t=>Object.entries({d:Math.floor(t/864e5),h:Math.floor(t/36e5)%24,m:Math.floor(t/6e4)%60,s:Math.floor(t/1e3)%60}).filter(r=>r[1]>0).map(r=>`${r[1]}${r[0]}`).join(" ")||"0s",kr=t=>_b(1e3*t),to=t=>{let r="";for(let n=0;n255?"_":t[n]}return r};function Hn(t,r){if(!t)throw new TypeError("assertion failed",{cause:new TypeError(r)})}function Ri(t,r,n){return tn?r:t}var Fn=()=>{let t,r,n=new Promise((a,s)=>{t=a,r=s});return{resolve:t,reject:r,promise:n}},Hr=t=>(0,xg.default)(t,r=>Bi(r)||r instanceof f?new f(r):r);function ar(t){let r=!1,n;return(...a)=>(r||(r=!0,n=t(...a)),n)}var Nc=()=>{let t=e.singularityCount,r=t>36?u.t("singularity.penalties.platonicCosts",{multiplier:d(Le("Platonic Costs",t),2,!0)}):'???????? ??????? ????? ??? ?????????? ?? ??? (37)',n=t>50?u.t("singularity.penalties.hepteractCosts",{multiplier:d(Le("Hepteract Costs",t),2,!0)}):'????????? ????? ????? ??? ?????????? ?? ??? (51)',a=`${Db(t)}
${u.t("singularity.penalties.globalSpeed",{divisor:d(Le("Global Speed",t),2,!0)})} ${u.t("singularity.penalties.ascensionSpeed",{divisor:d(Le("Ascension Speed",t),2,!0)})} ${u.t("singularity.penalties.offeringGain",{divisor:d(Le("Offering",t),2,!0)})} ${u.t("singularity.penalties.obtainiumGain",{divisor:d(Le("Obtainium",t),2,!0)})} @@ -9,29 +9,29 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho ${u.t("singularity.penalties.cubeUpgradeCosts",{multiplier:d(Le("Cube Upgrades",t),2,!0)})} ${r} ${n} - ${t>=270?u.t("singularity.penalties.penaltySmooth"):u.t("singularity.penalties.penaltyRough",{num:d(Ab(e.singularityCount),0,!0)})} - ${e.runelevels[6]>0?u.t("singularity.penalties.antiquitiesBought"):u.t("singularity.penalties.antiquitiesNotBought")}`;i("singularityPenaltiesMultiline").innerHTML=a};function Lb(t){return u.t("general.youAreInThe",{number:Xs(t)})}var V=class extends En{constructor(n,a){var c,p,g,m,h,b;let s=u.t(`singularity.data.${a}.name`),l=u.t(`singularity.data.${a}.description`);super(ee(O({},n),{name:s,description:l}));this.goldenQuarksInvested=0;this.goldenQuarksInvested=(c=n.goldenQuarksInvested)!=null?c:0,this.minimumSingularity=(p=n.minimumSingularity)!=null?p:0,this.canExceedCap=(g=n.canExceedCap)!=null?g:!1,this.specialCostForm=(m=n.specialCostForm)!=null?m:"Default",this.qualityOfLife=(h=n.qualityOfLife)!=null?h:!1,this.cacheUpdates=(b=n.cacheUpdates)!=null?b:void 0}toString(){let n=this.getCostTNL(),a=this.maxLevel===-1?"":`/${d(this.computeMaxLevel(),0,!0)}`,s=this.computeMaxLevel()===this.level?"plum":"white",l=e.highestSingularityCount0?`${u.t("general.minimum")} Singularity: ${this.minimumSingularity}`:u.t("singularity.toString.noMinimum"),p=this.freeLevels>0?` [+${d(this.freeLevels,2,!0)}]`:"";return this.freeLevels>this.level&&(p=`${p} ${u.t("general.softCapped")}`),`${this.name} + ${t>=270?u.t("singularity.penalties.penaltySmooth"):u.t("singularity.penalties.penaltyRough",{num:d(Hb(e.singularityCount),0,!0)})} + ${e.runelevels[6]>0?u.t("singularity.penalties.antiquitiesBought"):u.t("singularity.penalties.antiquitiesNotBought")}`;i("singularityPenaltiesMultiline").innerHTML=a};function Db(t){return u.t("general.youAreInThe",{number:eo(t)})}var V=class extends In{constructor(n,a){var c,p,g,m,h,b;let s=u.t(`singularity.data.${a}.name`),l=u.t(`singularity.data.${a}.description`);super(te(O({},n),{name:s,description:l}));this.goldenQuarksInvested=0;this.goldenQuarksInvested=(c=n.goldenQuarksInvested)!=null?c:0,this.minimumSingularity=(p=n.minimumSingularity)!=null?p:0,this.canExceedCap=(g=n.canExceedCap)!=null?g:!1,this.specialCostForm=(m=n.specialCostForm)!=null?m:"Default",this.qualityOfLife=(h=n.qualityOfLife)!=null?h:!1,this.cacheUpdates=(b=n.cacheUpdates)!=null?b:void 0}toString(){let n=this.getCostTNL(),a=this.maxLevel===-1?"":`/${d(this.computeMaxLevel(),0,!0)}`,s=this.computeMaxLevel()===this.level?"plum":"white",l=e.highestSingularityCount0?`${u.t("general.minimum")} Singularity: ${this.minimumSingularity}`:u.t("singularity.toString.noMinimum"),p=this.freeLevels>0?` [+${d(this.freeLevels,2,!0)}]`:"";return this.freeLevels>this.level&&(p=`${p} ${u.t("general.softCapped")}`),`${this.name} ${this.description} ${c} ${u.t("general.level")} ${d(this.level,0,!0)}${a}${p} ${this.getEffect().desc} ${u.t("singularity.toString.costNextLevel")}: ${d(n,0,!0)} Golden Quarks. - ${u.t("general.spent")} Quarks: ${d(this.goldenQuarksInvested,0,!0)}`}updateUpgradeHTML(){i("testingMultiline").innerHTML=this.toString()}getCostTNL(){let n=1;return this.computeMaxLevel()>this.maxLevel&&this.level>=this.maxLevel&&(n*=Math.pow(4,this.level-this.maxLevel+1)),this.specialCostForm==="Exponential2"?this.costPerLevel*Math.sqrt(n)*Math.pow(2,this.level):this.specialCostForm==="Cubic"?this.costPerLevel*n*(Math.pow(this.level+1,3)-Math.pow(this.level,3)):this.specialCostForm==="Quadratic"?this.costPerLevel*n*(Math.pow(this.level+1,2)-Math.pow(this.level,2)):(n*=this.maxLevel===-1&&this.level>=100?this.level/50:1,n*=this.maxLevel===-1&&this.level>=400?this.level/100:1,this.computeMaxLevel()===this.level?0:Math.ceil(this.costPerLevel*(1+this.level)*n))}async buyLevel(n){let a=0,s=1,l=e.goldenQuarks;if(n.shiftKey){s=1e5;let c=Number(await Ee(u.t("singularity.goldenQuarks.spendPrompt",{gq:d(e.goldenQuarks,0,!0)})));if(isNaN(c)||!isFinite(c)||!Number.isInteger(c))return P(u.t("general.validation.finite"));if(c===-1)l=e.goldenQuarks;else{if(c<=0)return P(u.t("general.validation.zeroOrLess"));l=c}l=Math.min(e.goldenQuarks,l)}if(this.maxLevel>0&&(s=Math.min(s,this.computeMaxLevel()-this.level)),s===0)return P(u.t("singularity.goldenQuarks.hasUpgrade"));if(e.highestSingularityCount0;){let c=this.getCostTNL();if(e.goldenQuarks1&&P(u.t("singularity.goldenQuarks.multiBuyPurchased",{levels:d(a)})),this.updateUpgradeHTML(),this.updateCaches(),Ac(),Oc(),Oe()}computeFreeLevelSoftcap(){let n=e.shopUpgrades.shopSingularityPotency>0?3.66:1;n+=.3/100*e.cubeUpgrades[75];let a=n*this.freeLevels;return Math.min(this.level,a)+Math.sqrt(Math.max(0,a-this.level))}computeMaxLevel(){if(this.canExceedCap){let n=this.maxLevel,a=[50,60,75,100,125,150,175,200,225,250];for(let s of a)if(e.highestSingularityCount>=s)n+=1;else break;return n+=+e.octeractUpgrades.octeractSingUpgradeCap.getEffect().bonus,n}else return this.maxLevel}actualTotalLevels(){if((e.singularityChallenges.noSingularityUpgrades.enabled||e.singularityChallenges.sadisticPrequel.enabled)&&!this.qualityOfLife||(e.singularityChallenges.limitedAscensions.enabled||e.singularityChallenges.limitedTime.enabled||e.singularityChallenges.sadisticPrequel.enabled)&&this.name===e.singularityUpgrades.platonicDelta.name)return 0;let n=this.computeFreeLevelSoftcap(),a=this.level+n,s=0;if(e.octeractUpgrades.octeractImprovedFree.getEffect().bonus){let l=.6;l+=+e.octeractUpgrades.octeractImprovedFree2.getEffect().bonus,l+=+e.octeractUpgrades.octeractImprovedFree3.getEffect().bonus,l+=+e.octeractUpgrades.octeractImprovedFree4.getEffect().bonus,s=Math.pow(this.level*n,l)}return Math.max(a,s)}getEffect(){return this.effect(this.actualTotalLevels())}updateCaches(){if(this.cacheUpdates!==void 0)for(let n of this.cacheUpdates)n()}refund(){e.goldenQuarks+=this.goldenQuarksInvested,this.level=0,this.goldenQuarksInvested=0}},F={goldenQuarks1:{maxLevel:15,costPerLevel:12,canExceedCap:!0,effect:t=>({bonus:1+.1*t,get desc(){return u.t("singularity.data.goldenQuarks1.effect",{n:d(10*t,0,!0)})}}),qualityOfLife:!0},goldenQuarks2:{maxLevel:75,costPerLevel:60,canExceedCap:!0,effect:t=>({bonus:t>250?1/Math.log2(t/62.5):1-Math.min(.5,t/500),get desc(){return u.t("singularity.data.goldenQuarks2.effect",{n:t>250?d(100-100/Math.log2(t/62.5),2,!0):d(Math.min(50,t/5),2,!0)})}}),qualityOfLife:!0},goldenQuarks3:{maxLevel:1e3,costPerLevel:1e3,effect:t=>({bonus:t*(t+1)/2,get desc(){return u.t("singularity.data.goldenQuarks3.effect",{n:d(t*(t+1)/2)})}})},starterPack:{maxLevel:1,costPerLevel:10,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.starterPack.effect${t>0?"Have":"HaveNot"}`)}})},wowPass:{maxLevel:1,costPerLevel:350,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.wowPass.effect${t>0?"Have":"HaveNot"}`)}}),qualityOfLife:!0},cookies:{maxLevel:1,costPerLevel:100,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.cookies.effect${t>0?"Have":"HaveNot"}`)}}),qualityOfLife:!0},cookies2:{maxLevel:1,costPerLevel:500,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.cookies2.effect${t>0?"Have":"HaveNot"}`)}}),qualityOfLife:!0},cookies3:{maxLevel:1,costPerLevel:24999,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.cookies3.effect${t>0?"Have":"HaveNot"}`)}}),qualityOfLife:!0},cookies4:{maxLevel:1,costPerLevel:499999,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.cookies4.effect${t>0?"Have":"HaveNot"}`)}}),qualityOfLife:!0},cookies5:{maxLevel:1,costPerLevel:166e13,minimumSingularity:209,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.cookies5.effect${t>0?"Have":"HaveNot"}`)}}),qualityOfLife:!0},ascensions:{maxLevel:-1,costPerLevel:5,effect:t=>({bonus:(1+2*t/100)*(1+Math.floor(t/10)/100),get desc(){return u.t("singularity.data.ascensions.effect",{n:d((100+2*t)*(1+Math.floor(t/10)/100)-100,1,!0)})}})},corruptionFourteen:{maxLevel:1,costPerLevel:1e3,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.corruptionFourteen.effect${t>0?"Have":"HaveNot"}`,{m:t>0?":)":":("})}})},corruptionFifteen:{maxLevel:1,costPerLevel:4e4,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.corruptionFifteen.effect${t>0?"Have":"HaveNot"}`,{m:t>0?":)":":("})}})},singOfferings1:{maxLevel:-1,costPerLevel:1,effect:t=>({bonus:1+.02*t,get desc(){return u.t("singularity.data.singOfferings1.effect",{n:d(2*t,0,!0)})}})},singOfferings2:{maxLevel:25,costPerLevel:25,canExceedCap:!0,effect:t=>({bonus:1+.08*t,get desc(){return u.t("singularity.data.singOfferings2.effect",{n:d(8*t,0,!0)})}})},singOfferings3:{maxLevel:40,costPerLevel:500,canExceedCap:!0,effect:t=>({bonus:1+.04*t,get desc(){return u.t("singularity.data.singOfferings3.effect",{n:d(4*t,0,!0)})}})},singObtainium1:{maxLevel:-1,costPerLevel:1,effect:t=>({bonus:1+.02*t,get desc(){return u.t("singularity.data.singObtainium1.effect",{n:d(2*t,0,!0)})}})},singObtainium2:{maxLevel:25,costPerLevel:25,canExceedCap:!0,effect:t=>({bonus:1+.08*t,get desc(){return u.t("singularity.data.singObtainium2.effect",{n:d(8*t,0,!0)})}})},singObtainium3:{maxLevel:40,costPerLevel:500,canExceedCap:!0,effect:t=>({bonus:1+.04*t,get desc(){return u.t("singularity.data.singObtainium3.effect",{n:d(4*t,0,!0)})}})},singCubes1:{maxLevel:-1,costPerLevel:1,effect:t=>({bonus:1+.01*t,get desc(){return u.t("singularity.data.singCubes1.effect",{n:d(1*t,0,!0)})}})},singCubes2:{maxLevel:25,costPerLevel:25,canExceedCap:!0,effect:t=>({bonus:1+.08*t,get desc(){return u.t("singularity.data.singCubes2.effect",{n:d(8*t,0,!0)})}})},singCubes3:{maxLevel:40,costPerLevel:500,canExceedCap:!0,effect:t=>({bonus:1+.04*t,get desc(){return u.t("singularity.data.singCubes3.effect",{n:d(4*t,0,!0)})}})},singCitadel:{maxLevel:-1,costPerLevel:5e5,minimumSingularity:100,effect:t=>({bonus:(1+.02*t)*(1+Math.floor(t/10)/100),get desc(){return u.t("singularity.data.singCubes2.effect",{n:d(100*((1+.02*t)*(1+Math.floor(t/10)/100)-1))})}})},singCitadel2:{maxLevel:100,costPerLevel:1e14,minimumSingularity:204,specialCostForm:"Quadratic",effect:t=>({bonus:(1+.02*t)*(1+Math.floor(t/10)/100),get desc(){return u.t("singularity.data.singCubes3.effect",{n:d(100*((1+.02*t)*(1+Math.floor(t/10)/100)-1))})}})},octeractUnlock:{maxLevel:1,costPerLevel:8888,minimumSingularity:8,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.octeractUnlock.effect${t>0?"Have":"HaveNot"}`)}}),qualityOfLife:!0},singOcteractPatreonBonus:{maxLevel:1,costPerLevel:9999,minimumSingularity:12,effect:t=>({bonus:t>0,get desc(){return u.t("singularity.data.singOcteractPatreonBonus.effect",{n:t})}})},offeringAutomatic:{maxLevel:-1,costPerLevel:1e14,minimumSingularity:222,effect:t=>({bonus:t,get desc(){return u.t("singularity.data.offeringAutomatic.effect",{n:t})}})},intermediatePack:{maxLevel:1,costPerLevel:1,minimumSingularity:4,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.intermediatePack.effect${t>0?"Have":"HaveNot"}`)}})},advancedPack:{maxLevel:1,costPerLevel:200,minimumSingularity:9,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.advancedPack.effect${t>0?"Have":"HaveNot"}`)}})},expertPack:{maxLevel:1,costPerLevel:800,minimumSingularity:16,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.expertPack.effect${t>0?"Have":"HaveNot"}`)}})},masterPack:{maxLevel:1,costPerLevel:3200,minimumSingularity:25,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.masterPack.effect${t>0?"Have":"HaveNot"}`)}})},divinePack:{maxLevel:1,costPerLevel:12800,minimumSingularity:36,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.divinePack.effect${t>0?"Have":"HaveNot"}`)}})},wowPass2:{maxLevel:1,costPerLevel:12500,minimumSingularity:9,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.wowPass2.effect${t>0?"Have":"HaveNot"}`)}}),qualityOfLife:!0},wowPass3:{maxLevel:1,costPerLevel:3e7-1,minimumSingularity:83,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.wowPass3.effect${t>0?"Have":"HaveNot"}`)}}),qualityOfLife:!0},potionBuff:{maxLevel:10,costPerLevel:999,minimumSingularity:4,canExceedCap:!0,effect:t=>({bonus:Math.max(1,10*Math.pow(t,2)),get desc(){return u.t("singularity.data.potionBuff.effect",{n:d(Math.max(1,10*Math.pow(t,2)),0,!0)})}})},potionBuff2:{maxLevel:10,costPerLevel:1e8,minimumSingularity:119,canExceedCap:!0,effect:t=>({bonus:Math.max(1,2*t),get desc(){return u.t("singularity.data.potionBuff2.effect",{n:d(Math.max(1,2*t),0,!0)})}})},potionBuff3:{maxLevel:10,costPerLevel:1e12,minimumSingularity:191,canExceedCap:!0,effect:t=>({bonus:Math.max(1,1+.5*t),get desc(){return u.t("singularity.data.potionBuff3.effect",{n:d(Math.max(1,1+.5*t),2,!0)})}})},singChallengeExtension:{maxLevel:4,costPerLevel:999,minimumSingularity:11,effect:t=>({bonus:t,get desc(){return u.t("singularity.data.singChallengeExtension.effect",{n:2*t,m:t})}})},singChallengeExtension2:{maxLevel:3,costPerLevel:29999,minimumSingularity:26,effect:t=>({bonus:t,get desc(){return u.t("singularity.data.singChallengeExtension2.effect",{n:2*t,m:t})}})},singChallengeExtension3:{maxLevel:3,costPerLevel:749999,minimumSingularity:51,effect:t=>({bonus:t,get desc(){return u.t("singularity.data.singChallengeExtension3.effect",{n:2*t,m:t})}})},singQuarkImprover1:{maxLevel:30,costPerLevel:1,minimumSingularity:173,canExceedCap:!0,specialCostForm:"Exponential2",effect:t=>({bonus:t/200,get desc(){return u.t("singularity.data.singQuarkImprover1.effect",{n:d(t/2,2,!0)})}}),qualityOfLife:!0},singQuarkHepteract:{maxLevel:1,costPerLevel:14999,minimumSingularity:5,effect:t=>({bonus:t/100,get desc(){return u.t("singularity.data.singQuarkHepteract.effect",{n:d(2*t,2,!0)})}}),qualityOfLife:!0},singQuarkHepteract2:{maxLevel:1,costPerLevel:449999,minimumSingularity:30,effect:t=>({bonus:t/100,get desc(){return u.t("singularity.data.singQuarkHepteract2.effect",{n:d(2*t,2,!0)})}}),qualityOfLife:!0},singQuarkHepteract3:{maxLevel:1,costPerLevel:1337e4,minimumSingularity:61,effect:t=>({bonus:t/100,get desc(){return u.t("singularity.data.singQuarkHepteract3.effect",{n:d(2*t,2,!0)})}}),qualityOfLife:!0},singOcteractGain:{maxLevel:-1,costPerLevel:2e4,minimumSingularity:36,effect:t=>({bonus:1+.0125*t,get desc(){return u.t("singularity.data.singOcteractGain.effect",{n:d(1.25*t,2,!0)})}})},singOcteractGain2:{maxLevel:25,costPerLevel:4e4,minimumSingularity:36,canExceedCap:!0,effect:t=>({bonus:1+.05*t,get desc(){return u.t("singularity.data.singOcteractGain2.effect",{n:d(5*t,0,!0)})}})},singOcteractGain3:{maxLevel:50,costPerLevel:25e4,minimumSingularity:55,canExceedCap:!0,effect:t=>({bonus:1+.025*t,get desc(){return u.t("singularity.data.singOcteractGain3.effect",{n:d(2.5*t,0,!0)})}})},singOcteractGain4:{maxLevel:100,costPerLevel:75e4,minimumSingularity:77,canExceedCap:!0,effect:t=>({bonus:1+.02*t,get desc(){return u.t("singularity.data.singOcteractGain4.effect",{n:d(2*t,0,!0)})}})},singOcteractGain5:{maxLevel:200,costPerLevel:7777777,minimumSingularity:100,canExceedCap:!0,effect:t=>({bonus:1+.01*t,get desc(){return u.t("singularity.data.singOcteractGain5.effect",{n:d(t,0,!0)})}})},platonicTau:{maxLevel:1,costPerLevel:1e5,minimumSingularity:29,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.platonicTau.effect${t?"Have":"HaveNot"}`)}}),qualityOfLife:!0},platonicAlpha:{maxLevel:1,costPerLevel:2e7,minimumSingularity:70,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.platonicAlpha.effect${t?"Have":"HaveNot"}`)}}),qualityOfLife:!0},platonicDelta:{maxLevel:1,costPerLevel:5e9,minimumSingularity:110,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.platonicDelta.effect${t?"Have":"HaveNot"}`)}})},platonicPhi:{maxLevel:1,costPerLevel:2e11,minimumSingularity:149,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.platonicPhi.effect${t?"Have":"HaveNot"}`)}}),qualityOfLife:!0},singFastForward:{maxLevel:1,costPerLevel:7e6-1,minimumSingularity:50,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.singFastForward.effect${t?"Have":"HaveNot"}`)}}),qualityOfLife:!0},singFastForward2:{maxLevel:1,costPerLevel:1e11-1,minimumSingularity:147,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.singFastForward2.effect${t?"Have":"HaveNot"}`)}}),qualityOfLife:!0},singAscensionSpeed:{maxLevel:1,costPerLevel:1e10,minimumSingularity:128,effect:t=>({bonus:t,get desc(){return u.t("singularity.data.singAscensionSpeed.effect",{n:d(1+.03*t,2,!0),m:d(1-.03*t,2,!0)})}})},singAscensionSpeed2:{maxLevel:1,costPerLevel:1e12,minimumSingularity:147,effect:t=>({bonus:t,get desc(){return u.t("singularity.data.singAscensionSpeed2.effect")}})},WIP:{maxLevel:100,costPerLevel:1e300,minimumSingularity:251,effect:t=>({bonus:t,get desc(){return u.t("singularity.data.WIP.effect")}})},ultimatePen:{maxLevel:1,costPerLevel:222e20,minimumSingularity:300,effect:t=>({bonus:t>0,get desc(){return u.t("singularity.data.ultimatePen.effect",{n:t?"":"NOT",m:t>0?" However, the pen just ran out of ink. How will you get more?":""})}})},oneMind:{maxLevel:1,costPerLevel:166e11,minimumSingularity:162,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.oneMind.effect${t?"Have":"HaveNot"}`)}}),qualityOfLife:!0},wowPass4:{maxLevel:1,costPerLevel:66666666666,minimumSingularity:147,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.wowPass4.effect${t?"Have":"HaveNot"}`)}}),qualityOfLife:!0},blueberries:{maxLevel:10,costPerLevel:1e16,minimumSingularity:215,effect:t=>({bonus:t,get desc(){return u.t("singularity.data.blueberries.effect",{n:t})}}),specialCostForm:"Exponential2",qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaBlueberries=da().value},()=>{o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value}]},singAmbrosiaLuck:{maxLevel:-1,costPerLevel:1e9,minimumSingularity:187,effect:t=>({bonus:4*t,get desc(){return u.t("singularity.data.singAmbrosiaLuck.effect",{n:d(4*t)})}}),specialCostForm:"Exponential2",qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaLuck=Ge().value}]},singAmbrosiaLuck2:{maxLevel:30,costPerLevel:4e5,minimumSingularity:50,effect:t=>({bonus:2*t,get desc(){return u.t("singularity.data.singAmbrosiaLuck2.effect",{n:d(2*t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaLuck=Ge().value}]},singAmbrosiaLuck3:{maxLevel:30,costPerLevel:2e8,minimumSingularity:119,effect:t=>({bonus:3*t,get desc(){return u.t("singularity.data.singAmbrosiaLuck3.effect",{n:d(3*t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaLuck=Ge().value}]},singAmbrosiaLuck4:{maxLevel:50,costPerLevel:1e19,minimumSingularity:256,effect:t=>({bonus:5*t,get desc(){return u.t("singularity.data.singAmbrosiaLuck4.effect",{n:d(5*t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaLuck=Ge().value}]},singAmbrosiaGeneration:{maxLevel:-1,costPerLevel:1e9,minimumSingularity:187,effect:t=>({bonus:1+t/100,get desc(){return u.t("singularity.data.singAmbrosiaGeneration.effect",{n:d(t)})}}),specialCostForm:"Exponential2",qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value}]},singAmbrosiaGeneration2:{maxLevel:20,costPerLevel:8e5,minimumSingularity:50,effect:t=>({bonus:1+t/100,get desc(){return u.t("singularity.data.singAmbrosiaGeneration2.effect",{n:d(t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value}]},singAmbrosiaGeneration3:{maxLevel:35,costPerLevel:3e8,minimumSingularity:119,effect:t=>({bonus:1+t/100,get desc(){return u.t("singularity.data.singAmbrosiaGeneration3.effect",{n:d(t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value}]},singAmbrosiaGeneration4:{maxLevel:50,costPerLevel:1e19,minimumSingularity:256,effect:t=>({bonus:1+2*t/100,get desc(){return u.t("singularity.data.singAmbrosiaGeneration4.effect",{n:d(2*t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value}]}};var Ec=[{name:()=>u.t("singularity.perks.welcometoSingularity.name"),levels:[1],description:()=>u.t("singularity.perks.welcometoSingularity.default"),ID:"welcometoSingularity"},{name:()=>u.t("singularity.perks.unlimitedGrowth.name"),levels:[1],description:()=>u.t("singularity.perks.unlimitedGrowth.default",{amount:d(10*e.singularityCount)}),ID:"unlimitedGrowth"},{name:()=>u.t("singularity.perks.goldenCoins.name"),levels:[1],description:()=>u.t("singularity.perks.goldenCoins.default",{amount:d(Math.pow(e.goldenQuarks+1,1.5)*Math.pow(e.highestSingularityCount+1,2),2)}),ID:"goldenCoins"},{name:()=>u.t("singularity.perks.xyz.name"),levels:[1,20,200],description:(t,r)=>t>=r[2]?u.t("singularity.perks.xyz.hasLevel2"):t>=r[1]?u.t("singularity.perks.xyz.hasLevel1"):u.t("singularity.perks.xyz.default"),ID:"xyz"},{name:()=>u.t("singularity.perks.generousOrbs.name"),levels:[1,2,5,10,15,20,25,30,35],description:(t,r)=>{let n={8:700,7:500,6:415,5:360,4:315,3:280,2:255,1:230};for(let a=8;a>0;a--)if(t>=r[a])return u.t("singularity.perks.generousOrbs.default",{amount:n[a]});return u.t("singularity.perks.generousOrbs.default",{amount:"215"})},ID:"generousOrbs"},{name:()=>u.t("singularity.perks.researchDummies.name"),levels:[1,11],description:(t,r)=>t>=r[1]?u.t("singularity.perks.researchDummies.hasLevel1"):u.t("singularity.perks.researchDummies.default"),ID:"researchDummies"},{name:()=>u.t("singularity.perks.antGodsCornucopia.name"),levels:[1,30,70,100],description:(t,r)=>t>=r[3]?u.t("singularity.perks.antGodsCornucopia.hasLevel3"):t>=r[2]?u.t("singularity.perks.antGodsCornucopia.hasLevel2"):t>=r[1]?u.t("singularity.perks.antGodsCornucopia.hasLevel1"):u.t("singularity.perks.antGodsCornucopia.default"),ID:"antGodsCornucopia"},{name:()=>u.t("singularity.perks.sweepomatic.name"),levels:[2,101],description:(t,r)=>t>=r[1]?u.t("singularity.perks.sweepomatic.hasLevel1"):u.t("singularity.perks.sweepomatic.default"),ID:"sweepomatic"},{name:()=>u.t("singularity.perks.superStart.name"),levels:[2,3,4,7,15],description:(t,r)=>t>=r[4]?u.t("singularity.perks.superStart.hasLevel4"):t>=r[3]?u.t("singularity.perks.superStart.hasLevel3"):t>=r[2]?u.t("singularity.perks.superStart.hasLevel2"):t>=r[1]?u.t("singularity.perks.superStart.hasLevel1"):u.t("singularity.perks.superStart.default"),ID:"superStart"},{name:()=>u.t("singularity.perks.notSoChallenging.name"),levels:[4,7,10,15,20],description:(t,r)=>t>=r[4]?u.t("singularity.perks.notSoChallenging.hasLevel4"):t>=r[3]?u.t("singularity.perks.notSoChallenging.hasLevel3"):t>=r[2]?u.t("singularity.perks.notSoChallenging.hasLevel2"):t>=r[1]?u.t("singularity.perks.notSoChallenging.hasLevel1"):u.t("singularity.perks.notSoChallenging.default"),ID:"notSoChallenging"},{name:()=>u.t("singularity.perks.automationUpgrades.name"),levels:[5,10,15,25,30,100],description:(t,r)=>t>=r[5]?u.t("singularity.perks.automationUpgrades.hasLevel5"):t>=r[4]?u.t("singularity.perks.automationUpgrades.hasLevel4"):t>=r[3]?u.t("singularity.perks.automationUpgrades.hasLevel3"):t>=r[2]?u.t("singularity.perks.automationUpgrades.hasLevel2"):t>=r[1]?u.t("singularity.perks.automationUpgrades.hasLevel1"):u.t("singularity.perks.automationUpgrades.default"),ID:"automationUpgrades"},{name:()=>u.t("singularity.perks.evenMoreQuarks.name"),levels:[5,7,10,20,35,50,65,80,90,100,121,144,150,160,166,169,170,175,180,190,196,200,201,202,203,204,205,210,212,214,216,218,220,225,250,255,260,261,262],description:(t,r)=>{for(let n=r.length-1;n>=0;n--)if(t>=r[n])return u.t("singularity.perks.evenMoreQuarks.default",{stack:n+1,inc:d(100*(Math.pow(1.05,n+1)-1),2)});return u.t("singularity.perks.evenMoreQuarks.bug")},ID:"evenMoreQuarks"},{name:()=>u.t("singularity.perks.shopSpecialOffer.name"),levels:[5,20,51],description:(t,r)=>t>=r[2]?u.t("singularity.perks.shopSpecialOffer.hasLevel2"):t>=r[1]?u.t("singularity.perks.shopSpecialOffer.hasLevel1"):u.t("singularity.perks.shopSpecialOffer.default"),ID:"shopSpecialOffer"},{name:()=>u.t("singularity.perks.potionAutogenerator.name"),levels:[6],description:()=>u.t("singularity.perks.potionAutogenerator.default"),ID:"potionAutogenerator"},{name:()=>u.t("singularity.perks.respecBeGone.name"),levels:[7],description:()=>u.t("singularity.perks.respecBeGone.default"),ID:"respecBeGone"},{name:()=>u.t("singularity.perks.forTheLoveOfTheAntGod.name"),levels:[10,15,25],description:(t,r)=>t>=r[2]?u.t("singularity.perks.forTheLoveOfTheAntGod.hasLevel2"):t>=r[1]?u.t("singularity.perks.forTheLoveOfTheAntGod.hasLevel1"):u.t("singularity.perks.forTheLoveOfTheAntGod.default"),ID:"forTheLoveOfTheAntGod"},{name:()=>u.t("singularity.perks.itAllAddsUp.name"),levels:[10,16,25,36,49,64,81,100,121,144,169,196,225,235,240],description:(t,r)=>{for(let n=r.length-1;n>=0;n--)if(t>=r[n])return u.t("singularity.perks.itAllAddsUp.default",{div:d(1+(n+1)/5,2,!0)});return u.t("singularity.perks.evenMoreQuarks.bug")},ID:"itAllAddsUp"},{name:()=>u.t("singularity.perks.automagicalRunes.name"),levels:[15,30,40,50],description:(t,r)=>t>=r[3]?u.t("singularity.perks.automagicalRunes.hasLevel3"):t>=r[2]?u.t("singularity.perks.automagicalRunes.hasLevel2"):t>=r[1]?u.t("singularity.perks.automagicalRunes.hasLevel1"):u.t("singularity.perks.automagicalRunes.default"),ID:"automagicalRunes"},{name:()=>u.t("singularity.perks.derpSmithsCornucopia.name"),levels:[18,38,58,78,88,98,118,148,178,188,198,208,218,228,238,248],description:(t,r)=>{for(let n=r.length-1;n>=0;n--)if(t>=r[n])return u.t("singularity.perks.derpSmithsCornucopia.default",{counter:n+1});return u.t("singularity.perks.evenMoreQuarks.bug")},ID:"derpSmithsCornucopia"},{name:()=>u.t("singularity.perks.eternalAscensions.name"),levels:[25],description:()=>u.t("singularity.perks.eternalAscensions.default"),ID:"eternalAscensions"},{name:()=>u.t("singularity.perks.exaltedAchievements.name"),levels:[25],description:()=>u.t("singularity.perks.exaltedAchievements.default"),ID:"exaltedAchievements"},{name:()=>u.t("singularity.perks.coolQOLCubes.name"),levels:[25,35],description:(t,r)=>t>=r[1]?u.t("singularity.perks.coolQOLCubes.hasLevel1"):u.t("singularity.perks.coolQOLCubes.default"),ID:"coolQOLCubes"},{name:()=>u.t("singularity.perks.irishAnt.name"),levels:[35,42,49,56,63,70,77,135,142,149,156,163,170,177],description:(t,r)=>{for(let n=r.length-1;n>=0;n--)if(t>=r[n])return n>=7?u.t("singularity.perks.irishAnt.default",{i:6*(n-6)+35}):u.t("singularity.perks.irishAnt.default",{i:5*(n+1)});return u.t("singularity.perks.evenMoreQuarks.bug")},ID:"irishAnt"},{name:()=>u.t("singularity.perks.overclocked.name"),levels:[50,60,75,100,125,150,175,200,225,250],description:(t,r)=>{for(let n=r.length-1;n>=0;n--)if(t>=r[n])return u.t("singularity.perks.overclocked.default",{i:n+1});return u.t("singularity.perks.evenMoreQuarks.bug")},ID:"overclocked"},{name:()=>u.t("singularity.perks.wowCubeAutomatedShipping.name"),levels:[50,150],description:(t,r)=>t>=r[1]?u.t("singularity.perks.wowCubeAutomatedShipping.hasLevel1"):u.t("singularity.perks.wowCubeAutomatedShipping.default"),ID:"wowCubeAutomatedShipping"},{name:()=>u.t("singularity.perks.congealedblueberries.name"),levels:[64,128,192,256,270],description(t,r){for(let n=r.length-1;n>=0;n--)if(t>=r[n])return u.t("singularity.perks.congealedblueberries.default",{i:n+1});return u.t("singularity.perks.evenMoreQuarks.bug")},ID:"congealedblueberries"},{name:()=>u.t("singularity.perks.goldenRevolution.name"),levels:[100],description:()=>u.t("singularity.perks.goldenRevolution.default",{current:d(Math.min(100,.4*e.singularityCount),1)}),ID:"goldenRevolution"},{name:()=>u.t("singularity.perks.goldenRevolutionII.name"),levels:[100],description:()=>u.t("singularity.perks.goldenRevolutionII.default",{current:d(Math.min(50,.2*e.singularityCount),1)}),ID:"goldenRevolution2"},{name:()=>u.t("singularity.perks.goldenRevolutionIII.name"),levels:[100],description:()=>u.t("singularity.perks.goldenRevolutionIII.default",{current:d(Math.min(500,2*e.singularityCount))}),ID:"goldenRevolution3"},{name:()=>u.t("singularity.perks.platonicClones.name"),levels:[100,200],description:(t,r)=>t>=r[1]?u.t("singularity.perks.platonicClones.hasLevel1"):u.t("singularity.perks.platonicClones.default"),ID:"platonicClones"},{name:()=>u.t("singularity.perks.irishAnt2.name"),levels:[100,150,200,225,250,255,260,265,269,272],description:(t,r)=>{for(let n=r.length-1;n>=0;n--)if(t>=r[n])return u.t("singularity.perks.irishAnt2.default",{percent:n+1});return u.t("singularity.perks.evenMoreQuarks.bug")},ID:"irishAnt2"},{name:()=>u.t("singularity.perks.platSigma.name"),levels:[125,200],description:(t,r)=>{let n=0;for(let a of r)t>=a&&(n+=.125);return u.t("singularity.perks.platSigma.default",{counter:n,current:d(Math.min(60,n*e.singularityCount),1)})},ID:"platSigma"},{name:()=>u.t("singularity.perks.primalPower.name"),levels:[131,269],description:(t,r)=>t>=r[1]?u.t("singularity.perks.primalPower.hasLevel1"):u.t("singularity.perks.primalPower.default"),ID:"primalPower"},{name:()=>u.t("singularity.perks.midasMilleniumAgedGold.name"),levels:[150],description:()=>u.t("singularity.perks.midasMilleniumAgedGold.default"),ID:"midasMilleniumAgedGold"},{name:()=>u.t("singularity.perks.goldenRevolution4.name"),levels:[160,173,185,194,204,210,219,229,240,249],description:(t,r)=>{let a=0;for(let s of r)t>=s&&(a+=1);return u.t("singularity.perks.goldenRevolution4.default",{gq:d(1e6/a,0,!0)})},ID:"goldenRevolution4"},{name:()=>u.t("singularity.perks.octeractMetagenesis.name"),levels:[200,205],description:(t,r)=>t>=r[1]?u.t("singularity.perks.octeractMetagenesis.hasLevel1"):u.t("singularity.perks.octeractMetagenesis.default"),ID:"octeractMetagenesis"},{name:()=>u.t("singularity.perks.immaculateAlchemy.name"),levels:[200,208,221],description:(t,r)=>t>=r[2]?u.t("singularity.perks.immaculateAlchemy.hasLevel2"):t>=r[1]?u.t("singularity.perks.immaculateAlchemy.hasLevel1"):u.t("singularity.perks.immaculateAlchemy.default"),ID:"immaculateAlchemy"},{name:()=>u.t("singularity.perks.skrauQ.name"),levels:[200],description:()=>{let t=d(Math.pow((e.singularityCount-179)/20,2),4);return u.t("singularity.perks.skrauQ.default",{amt:t})},ID:"skrauQ"},{name:()=>u.t("singularity.perks.permanentBenefaction.name"),levels:[244],description:()=>u.t("singularity.perks.permanentBenefaction.default"),ID:"permanentBenefaction"}],Oc=()=>{let t=e.highestSingularityCount;i("singularityPerksHeader").innerHTML=u.t("singularity.perks.header",{ord:Xs(t)}),i("singularityPerksText").innerHTML=u.t("singularity.perks.levelInfo",{level:"#",singularity:"#"}),i("singularityPerksDesc").innerHTML=u.t("singularity.perks.description"),Pb(t)},Uc=(t,r)=>{for(let n=t.levels.length-1;n>=0;n--)if(r>=t.levels[n])return{level:n+1,singularity:t.levels[n],next:n{let r=[],n=null,a=Number.POSITIVE_INFINITY;for(let c of Ec){let p=Uc(c,t);p.level>0?(r.push({name:c.name(),lastUpgraded:p.singularity,acquired:c.levels[0],htmlID:c.ID}),p.next&&(a=Math.min(a,p.next))):(n===null&&(n=p.singularity),i(c.ID).style.display="none")}r.sort((c,p)=>c.acquired===p.acquired&&c.lastUpgraded===p.lastUpgraded?0:c.lastUpgraded>p.lastUpgraded||c.lastUpgraded===p.lastUpgraded&&c.acquired>p.acquired?-1:1);for(let c of r){let p=ua(),g=i(c.htmlID);g.style.display="",i("singularityPerksGrid").append(g),t-c.lastUpgraded<=p?g.classList.replace("oldPerk","newPerk"):g.classList.replace("newPerk","oldPerk")}let s=i("singualrityUnlockNext");n?(s.style.display="",s.innerHTML=u.t("singularity.perks.unlockedIn",{sing:n})):s.style.display="none";let l=i("singualrityImproveNext");a{let t=0;return t+=+e.singularityUpgrades.singFastForward.getEffect().bonus,t+=+e.singularityUpgrades.singFastForward2.getEffect().bonus,t+=+e.octeractUpgrades.octeractFastForward.getEffect().bonus,t=Math.max(0,Math.min(t,200-e.singularityCount-1)),e.insideSingularityChallenge?0:e.highestSingularityCount!==e.singularityCount&&e.singularityCount+t+1>=e.highestSingularityCount?Math.max(0,Math.min(t,e.highestSingularityCount-e.singularityCount-1)):t},Bc=()=>{let r=1e4;r*=1-.1*Math.min(1,e.achievementPoints/1e4),r*=1-.3*e.cubeUpgrades[60]/1e4,r*=+e.singularityUpgrades.goldenQuarks2.getEffect().bonus,r*=+e.octeractUpgrades.octeractGQCostReduce.getEffect().bonus,r*=e.highestSingularityCount>=100?1-.5*e.highestSingularityCount/250:1;let n=1;return e.highestSingularityCount>=200&&(n=3),e.highestSingularityCount>=208&&(n=5),e.highestSingularityCount>=221&&(n=8),r/=n,r=1e4-r,{cost:1e4-r,costReduction:r}};async function hg(){let t=Bc(),r=Math.floor(+e.worlds/t.cost),n=null;if(r===0)return P(u.t("singularity.goldenQuarks.poor"));let a=await Ee(u.t("singularity.goldenQuarks.buyPrompt",{cost:d(t.cost,0,!0),discount:d(t.costReduction,0,!0),max:d(r,0,!0)}));if(a===null)return P(u.t("general.cancelled"));if(n=Number(a),Number.isNaN(n)||!Number.isFinite(n))return P(u.t("general.validation.finite"));if(n<=0&&n!==-1)return P(u.t("general.validation.zeroOrLess"));if(n>r)return P(u.t("general.validation.goldenQuarksTooMany"));if(!Number.isInteger(n))return P(u.t("general.validation.fraction"));let s;return n===-1?(s=r*t.cost,e.worlds.sub(s),e.goldenQuarks+=r):(s=n*t.cost,e.worlds.sub(s),e.goldenQuarks+=n),P(u.t("singularity.goldenQuarks.transaction",{spent:d(r,0,!0),cost:d(s,0,!0)}))}var Ys=(t=e.singularityCount)=>{let r=t;return r*=Math.min(4.75,.75*t/10+1),e.insideSingularityChallenge&&e.singularityChallenges.noOcteracts.enabled&&(r*=Math.pow(e.singularityChallenges.noOcteracts.completions+1,3)),t>10&&(r*=1.5,r*=Math.min(4,1.25*t/10-.25)),t>25&&(r*=2.5,r*=Math.min(6,1.5*t/25-.5)),t>36&&(r*=4,r*=Math.min(5,t/18-1),r*=Math.pow(1.1,Math.min(t-36,64))),t>50&&(r*=5,r*=Math.min(8,2*t/50-1),r*=Math.pow(1.1,Math.min(t-50,50))),t>100&&(r*=2,r*=t/25,r*=Math.pow(1.1,t-100)),t>150&&(r*=2,r*=Math.pow(1.05,t-150)),t>200&&(r*=1.5,r*=Math.pow(1.275,t-200)),t>215&&(r*=1.25,r*=Math.pow(1.2,t-215)),t>230&&(r*=2),t>269&&(r*=3,r*=Math.pow(3,t-269)),r},Ab=(t=e.singularityCount)=>{let r=[11,26,37,51,101,151,201,216,230,270],n=0;n+=e.shopUpgrades.shopSingularityPenaltyDebuff;for(let a of r)if(a+n>t)return a+n;return-1},Le=(t,r=e.singularityCount)=>{if(r===0||e.runelevels[6]>0)return 1;let n=r;if(n-=e.shopUpgrades.shopSingularityPenaltyDebuff,n<1)return 1;let a=Ys(n);if(t==="Offering")return Math.sqrt(Math.min(a,Ys(150))+1);if(t==="Global Speed")return 1+Math.sqrt(a)/4;if(t==="Obtainium")return Math.sqrt(Math.min(a,Ys(150))+1);if(t==="Researches")return 1+Math.sqrt(a)/2;if(t==="Ascension Speed")return n<150?1+Math.sqrt(a)/5:1+Math.pow(a,.75)/1e4;if(t==="Cubes"){let s=n>100?Math.pow(1.02,n-100):1;return n<150?1+Math.sqrt(a)*s/4:1+Math.pow(a,.75)*s/1e3}else return t==="Platonic Costs"?n>36?1+Math.pow(a,3/10)/12:1:t==="Hepteract Costs"?n>50?1+Math.pow(a,11/50)/25:1:Math.cbrt(a+1)};var bg=(t,r=1,n=0)=>(r=Math.min(o.researchMaxLevels[t]-e.researches[t],r),rr(e.researches[t],o.researchBaseCosts[t]*Le("Researches"),e.researchPoints,n,r)),Eb=(t,r)=>{if(Ht()&&r&&e.autoResearchMode==="cheapest"){for(e.autoResearch=o.researchOrderByCost[e.roombaResearchIndex],Ic(e.autoResearch)&&(i(`res${e.autoResearch||1}`).classList.remove("researchRoomba"),e.roombaResearchIndex=Math.min(o.researchOrderByCost.length-1,e.roombaResearchIndex+1));!Rc(e.autoResearch)&&e.autoResearch<200&&e.autoResearch>=76;)e.roombaResearchIndex+=1,e.autoResearch=o.researchOrderByCost[e.roombaResearchIndex];if(Rc(e.autoResearch)){let n=Math.max(o.researchOrderByCost[e.roombaResearchIndex],1),a=i(`res${n}`);e.researches[e.autoResearch]=o.researchMaxLevels[t]?Tt(`res${e.autoResearch}`,["researchMaxed"],["researchPurchased","researchUnpurchased"]):e.researches[t]>=1?Tt(`res${e.autoResearch}`,["researchPurchased"],["researchUnpurchased","researchMaxed"]):Tt(`res${e.autoResearch}`,["researchUnpurchased"],["researchPurchased","researchMaxed"]);return}else return},Ht=()=>e.cubeUpgrades[9]===1||e.highestSingularityCount>10,Fr=(t,r=!1,n=0,a=!1)=>{var p,g,m,h;let s=e.researchBuyMaxToggle||r||a?1e5:1,l=bg(t,s,n),c=e.researchPoints>=l.cost;return c&&Rc(t)&&!Ic(t)&&(e.researches[t]=l.levelCanBuy,e.researchPoints-=l.cost,Ic(t)&&i(`res${e.autoResearch||1}`).classList.remove("researchRoomba"),o.researchfiller2=`Level: ${e.researches[t]}/${o.researchMaxLevels[t]}`,Ai(t,r,n),(p=e.unlocks).rrow1||(p.rrow1=!0),(g=e.unlocks).rrow2||(g.rrow2=!0),(m=e.unlocks).rrow3||(m.rrow3=!0),(h=e.unlocks).rrow4||(h.rrow4=!0),t>=47&&t<=50&&Oe(),(t>=66&&t<=70||t===105)&&Sr(),He(),Bt()),e.autoResearchToggle&&Eb(t,r),c},yg=(t=e)=>{let r=t.ascensionCount>0?140:125,n=t.challengecompletions[11]>0?15:0,a=t.challengecompletions[12]>0?15:0,s=t.challengecompletions[13]>0?15:0,l=t.challengecompletions[14]>0?15:0;return r+n+a+s+l},Rc=t=>{let r=(s=>l=>s+=l)(0),n=[3*25,5,20,10,15,15,15,15,15,15].map(r),a=[50,124,127,134,141,183,197,204,211,218];for(let s=0;s0;if(t<=n[s])return e.achievements[a[s]]>0}return!1},Ic=t=>o.researchMaxLevels[t]<=e.researches[t],Ai=(t,r=!1,n=0)=>{let a=e.researchBuyMaxToggle||r?1e5:1,s=u.t(`researches.descriptions.${t}`),l=`res${t}`;e.toggles[38]&&e.singularityCount>0&&Fr(t,!1,t===200?.01:0,!0);let c=bg(t,a,n),p=u.t("researches.cost",{x:d(c.cost,0,!1),y:d(c.levelCanBuy-e.researches[t],0,!0)});e.researches[t]===o.researchMaxLevels[t]?(i("researchcost").style.color="Gold",i("researchinfo3").style.color="plum",Tt(l,["researchMaxed"],["researchAvailable","researchPurchased","researchPurchasedAvailable"]),p+=u.t("researches.maxed")):(i("researchcost").style.color="limegreen",i("researchinfo3").style.color="white",e.researches[t]>0?Tt(l,["researchPurchased","researchPurchasedAvailable"],["researchAvailable","researchMaxed","researchUnpurchased"]):Tt(l,["researchAvailable"],["researchPurchased","researchMaxed","researchUnpurchased"])),e.researchPoints{e.researches[t]>o.researchMaxLevels[t]&&(e.researchPoints+=(e.researches[t]-o.researchMaxLevels[t])*o.researchBaseCosts[t],e.researches[t]=o.researchMaxLevels[t]);let r=`res${t}`;e.researches[t]>.5&&e.researches[t].5&&e.researches[t]>=o.researchMaxLevels[t]?Tt(r,["researchMaxed"],["researchUnpurchased","researchPurchased"]):Tt(r,["researchUnpurchased"],["researchPurchased","researchMaxed"])};var as=(t,r)=>{t===1&&e.prestigePoints.gte(1e12)&&!e.unlocks.generation&&(e.unlocks.generation=!0);let n=100+t,a="transcendPoints";n<=110&&n>=106?a="coins":n<=115&&(a="prestigePoints");let s=f.pow(10,o.upgradeCosts[n]),l=Math.max(e.upgrades[101],e.upgrades[102],e.upgrades[103],e.upgrades[104],e.upgrades[105]);e.upgrades[n]===0&&e[a].gte(s)&&(l===0&&n>=102&&n<=105&&R(n-31),e[a]=e[a].sub(s),e.upgrades[n]=1,Ft(n,r))},vg=(t,r)=>{let n=t+80,a="reincarnationPoints";n<=87?a="prestigePoints":n<=93&&(a="transcendPoints");let s=f.pow(10,o.upgradeCosts[n]);e.upgrades[n]===0&&e[a].gte(s)&&(e[a]=e[a].sub(s),e.upgrades[n]=1,Ft(n,r))},Cg=()=>{if(e.upgrades[90]>.5&&e.shoptoggles.generators){for(let t=1;t<6;t++)e.upgrades[100+t]===0&&e.prestigePoints.gte(f.pow(10,o.upgradeCosts[100+t]))&&as(t,!0);for(let t=6;t<11;t++)e.upgrades[100+t]===0&&e.coins.gte(f.pow(10,o.upgradeCosts[100+t]))&&as(t,!0);for(let t=11;t<16;t++)e.upgrades[100+t]===0&&e.prestigePoints.gte(f.pow(10,o.upgradeCosts[100+t]))&&as(t,!0);for(let t=16;t<21;t++)e.upgrades[100+t]===0&&e.transcendPoints.gte(f.pow(10,o.upgradeCosts[100+t]))&&as(t,!0)}if(e.upgrades[91]>.5){for(let t=1;t<21;t++)e.upgrades[t]===0&&e.coins.gte(f.pow(10,o.upgradeCosts[t]))&&e.shoptoggles.coin&&nr("coins",t,!0);for(let t=121;t<=125;t++)e.upgrades[t]===0&&e.coins.gte(f.pow(10,o.upgradeCosts[t]))&&e.shoptoggles.coin&&e.cubeUpgrades[19]>0&&nr("coins",t,!0)}if(e.upgrades[92]>.5){for(let t=21;t<38;t++)e.upgrades[t]===0&&e.prestigePoints.gte(f.pow(10,o.upgradeCosts[t]))&&e.shoptoggles.prestige&&nr("prestigePoints",t,!0);e.upgrades[38]===0&&e.prestigePoints.gte(f.pow(10,5e4))&&e.shoptoggles.prestige&&e.achievements[120]===1&&nr("prestigePoints",38,!0),e.upgrades[39]===0&&e.prestigePoints.gte(f.pow(10,1e5))&&e.shoptoggles.prestige&&e.achievements[127]===1&&nr("prestigePoints",39,!0),e.upgrades[40]===0&&e.prestigePoints.gte(f.pow(10,2e5))&&e.shoptoggles.prestige&&e.achievements[134]===1&&nr("prestigePoints",40,!0)}if(e.upgrades[99]>.5)for(let t=41;t<61;t++)e.upgrades[t]===0&&e.transcendPoints.gte(f.pow(10,o.upgradeCosts[t]))&&e.shoptoggles.transcend&&nr("transcendPoints",t,!0);if(e.cubeUpgrades[8]>0)for(let t=61;t<=80;t++)e.upgrades[t]===0&&e.reincarnationPoints.gte(f.pow(10,o.upgradeCosts[t]))&&e.shoptoggles.reincarnate&&nr("reincarnationPoints",t,!0);if(e.highestSingularityCount>=25)for(let t=81;t<=100;t++)e.upgrades[t]===0&&pa(t,!0)};var Nc={3:()=>({max:d(100*(.12+.88*e.upgrades[122]+.001*e.researches[129]*Math.log(e.commonFragments+1)/Math.log(4)),2,!0)}),4:()=>({max:d(10+.05*e.researches[129]*Math.log(e.commonFragments+1)/Math.log(4)+20*Xe()/400*o.effectiveRuneSpiritPower[3])})},$c={1:()=>({level:d(5+e.achievements[270]+.1*e.platonicUpgrades[18],1,!0)}),2:()=>({max:d(10+e.achievements[270]+e.shopUpgrades.constantEX+100*(o.challenge15Rewards.exponent-1)+.3*e.platonicUpgrades[18],2,!0)})},_c=[()=>d((o.totalCoinOwned+1)*Math.min(1e30,Math.pow(1.008,o.totalCoinOwned)),2),()=>d((o.totalCoinOwned+1)*Math.min(1e30,Math.pow(1.008,o.totalCoinOwned)),2),()=>d((o.totalCoinOwned+1)*Math.min(1e30,Math.pow(1.008,o.totalCoinOwned)),2),()=>d((o.totalCoinOwned+1)*Math.min(1e30,Math.pow(1.008,o.totalCoinOwned)),2),()=>d((o.totalCoinOwned+1)*Math.min(1e30,Math.pow(1.008,o.totalCoinOwned)),2),()=>d((o.totalCoinOwned+1)*Math.min(1e30,Math.pow(1.008,o.totalCoinOwned)),2),()=>Math.min(4,1+Math.floor(f.log(e.fifthOwnedCoin+1,10))),()=>Math.floor(e.multiplierBought/7),()=>Math.floor(e.acceleratorBought/10),()=>d(f.pow(2,Math.min(50,e.secondOwnedCoin/15)),2),()=>d(f.pow(1.02,o.freeAccelerator),2),()=>d(f.min(1e4,f.pow(1.01,e.prestigeCount)),2),()=>d(f.min(1e50,f.pow(e.firstGeneratedMythos.add(e.firstOwnedMythos).add(1),4/3).times(1e10)),2),()=>d(f.pow(1.15,o.freeAccelerator),2),()=>d(f.pow(1.15,o.freeAccelerator),2),()=>d(f.pow(o.acceleratorEffect,1/3),2),()=>null,()=>d(f.min(1e125,e.transcendShards.add(1))),()=>d(f.min(1e200,e.transcendPoints.times(1e30).add(1))),()=>d(f.pow((o.totalCoinOwned+1)*Math.min(1e30,Math.pow(1.008,o.totalCoinOwned)),10),2),()=>({x:d(Math.floor(1+1/101*o.freeMultiplier)),y:d(Math.floor(5+1/101*o.freeAccelerator))}),()=>({x:d(Math.floor(1+1/101*o.freeMultiplier)),y:d(Math.floor(4+1/101*o.freeAccelerator))}),()=>({x:d(Math.floor(1+1/101*o.freeMultiplier)),y:d(Math.floor(3+1/101*o.freeAccelerator))}),()=>({x:d(Math.floor(1+1/101*o.freeMultiplier)),y:d(Math.floor(2+1/101*o.freeAccelerator))}),()=>({x:d(Math.floor(1+1/101*o.freeMultiplier)),y:d(Math.floor(1+1/101*o.freeAccelerator))}),()=>null,()=>d(Math.min(250,Math.floor(f.log(e.coins.add(1),1e3)))+Math.max(0,Math.min(1750,Math.floor(f.log(e.coins.add(1),1e15))-50))),()=>d(Math.min(1e3,Math.floor((e.firstOwnedCoin+e.secondOwnedCoin+e.thirdOwnedCoin+e.fourthOwnedCoin+e.fifthOwnedCoin)/160))),()=>d(Math.floor(Math.min(2e3,(e.firstOwnedCoin+e.secondOwnedCoin+e.thirdOwnedCoin+e.fourthOwnedCoin+e.fifthOwnedCoin)/80))),()=>d(Math.min(75,Math.floor(f.log(e.coins.add(1),1e10)))+Math.min(925,Math.floor(f.log(e.coins.add(1),1e30)))),()=>d(Math.floor(o.totalCoinOwned/2e3)),()=>d(Math.min(500,Math.floor(f.log(e.prestigePoints.add(1),1e25)))),()=>d(o.totalAcceleratorBoost),()=>d(Math.floor(3/103*o.freeMultiplier)),()=>d(Math.floor(2/102*o.freeMultiplier)),()=>d(f.min("1e5000",f.pow(e.prestigePoints,1/500)),2),()=>d(f.pow(f.log(e.prestigePoints.add(10),10),2),2),()=>null,()=>null,()=>null,()=>d(f.min(1e30,f.pow(e.transcendPoints.add(1),1/2))),()=>d(f.min(1e50,f.pow(e.prestigePoints.add(1),1/50).dividedBy(2.5).add(1)),2),()=>d(f.min(1e30,f.pow(1.01,e.transcendCount)),2),()=>d(f.min(1e6,f.pow(1.01,e.transcendCount)),2),()=>d(Math.min(2500,Math.floor(f.log(e.transcendShards.add(1),10)))),()=>null,()=>d(Math.pow(1.05,e.achievementPoints)*(e.achievementPoints+1),2),()=>d(Math.pow(Math.min(1e25,o.totalMultiplier*o.totalAccelerator)/1e3+1,8)),()=>d(Math.min(50,Math.floor(f.log(e.transcendPoints.add(1),1e10)))),()=>null,()=>d(Math.pow(o.totalAcceleratorBoost,2),2),()=>d(f.pow(o.globalMythosMultiplier,.025),2),()=>d(f.min("1e1250",f.pow(o.acceleratorEffect,1/125)),2),()=>d(f.min("1e2000",f.pow(o.multiplierEffect,1/180)),2),()=>d(f.pow("1e1000",Math.min(1e3,o.buildingPower-1)),2),()=>null,()=>null,()=>null,()=>null,()=>null,()=>null,()=>Math.floor(1/5*ae(e.challengecompletions)),()=>d(f.min("1e6000",f.pow(e.reincarnationPoints.add(1),6))),()=>d(f.pow(e.reincarnationPoints.add(1),2)),()=>null,()=>null,()=>d(f.pow(1.03,e.firstOwnedParticles+e.secondOwnedParticles+e.thirdOwnedParticles+e.fourthOwnedParticles+e.fifthOwnedParticles),2),()=>d(Math.min(2500,Math.floor(1/1e3*f.log(o.taxdivisor,10)))),()=>{let t=f.pow(f.log(o.reincarnationPointGain.add(10),10),.5),r=f.pow(f.log(o.reincarnationPointGain.add(10),10),.5);return{x:d(Math.min(10,new f(t).toNumber()),2),y:d(Math.min(3,new f(r).toNumber()),2)}},()=>d(1/3*Math.log(e.maxobtainium+1)/Math.log(10),2,!0),()=>null,()=>Math.min(50,1+2*e.challengecompletions[6]+2*e.challengecompletions[7]+2*e.challengecompletions[8]+2*e.challengecompletions[9]+2*e.challengecompletions[10]),()=>null,()=>d(1+4*Math.min(1,Math.pow(e.maxofferings/1e5,.5)),2),()=>d(1+2*Math.min(1,Math.pow(e.maxobtainium/3e7,.5)),2),()=>null,()=>d(f.pow(1.004+4/1e5*e.researches[96],e.firstOwnedAnts+e.secondOwnedAnts+e.thirdOwnedAnts+e.fourthOwnedAnts+e.fifthOwnedAnts+e.sixthOwnedAnts+e.seventhOwnedAnts+e.eighthOwnedAnts),3),()=>d(1+.005*Math.pow(Math.log(e.maxofferings+1)/Math.log(10),2),2,!0),()=>null,()=>null,...Array.from({length:39},()=>()=>null),()=>null,()=>null,()=>null,()=>null,()=>d(.333*e.challengecompletions[10],0),()=>d(.333*e.challengecompletions[10],0)],Ob=t=>{var s;let r=(s=_c[t-1])==null?void 0:s.call(_c),n=typeof r,a=i("upgradeeffect");t>=81&&t<=119?a.textContent=u.t("upgrades.effects.81"):r==null?a.textContent=u.t(`upgrades.effects.${t}`):n==="string"||n==="number"?a.textContent=u.t(`upgrades.effects.${t}`,{x:r}):a.textContent=u.t(`upgrades.effects.${t}`,r)},Mg=t=>{let r=u.t(`upgrades.descriptions.${t}`),n=e.upgrades[t]>.5?" BOUGHT!":"",a=i("upgradedescription");a.textContent=r+n,a.style.color=e.upgrades[t]>.5?"gold":"white",e.toggles[9]&&pa(t,!1);let s="",l="";(t<=20&&t>=1||t<=110&&t>=106||t<=125&&t>=121)&&(s="Coins",l="yellow"),(t<=40&&t>=21||t<=105&&t>=101||t<=115&&t>=111||t<=87&&t>=81)&&(s="Diamonds",l="cyan"),(t<=60&&t>=41||t<=120&&t>=116||t<=93&&t>=88)&&(s="Mythos",l="plum"),(t<=80&&t>=61||t<=100&&t>=94)&&(s="Particles",l="limegreen"),i("upgradecost").textContent=`Cost: ${d(f.pow(10,o.upgradeCosts[t]))} ${s}`,i("upgradecost").style.color=l,Ob(t)},pa=(t,r)=>{if(e.upgrades[t]!==0||t<=40&&t>=21&&!e.unlocks.prestige||t<=60&&t>=41&&!e.unlocks.transcend||t<=80&&t>=61&&!e.unlocks.reincarnate||t<=120&&t>=81&&!e.unlocks.prestige||i(`upg${t}`).style.display==="none")return;let n;t<=20&&t>=1&&(n="coins"),t<=40&&t>=21&&(n="prestigePoints"),t<=60&&t>=41&&(n="transcendPoints"),t<=80&&t>=61&&(n="reincarnationPoints"),t<=87&&t>=81&&(n="prestigePoints"),t<=93&&t>=88&&(n="transcendPoints"),t<=100&&t>=94&&(n="reincarnationPoints"),n&&t<=80&&t>=1&&nr(n,t,r),n&&t<=100&&t>=81&&vg(t-80,r),t<=120&&t>=101&&as(t-100,r),t<=125&&t>=121&&nr("coins",t,r)},Js=(t,r)=>{let n=0,a=0;if(t===1){n=121,a=125;for(let s=1;s<=20;s++)pa(s,r)}t===2&&(n=21,a=40),t===3&&(n=41,a=60),t===4&&(n=101,a=120),t===5&&(n=81,a=100),t===6&&(n=61,a=80);for(let s=n;s<=a;s++)pa(s,r)},xg={1:()=>({x:d(f.min(f.pow(10,50+2*e.crystalUpgrades[0]),f.pow(1.05,e.achievementPoints*e.crystalUpgrades[0])),2,!0)}),2:()=>({x:d(f.min(f.pow(10,100+5*e.crystalUpgrades[1]),f.pow(f.log(e.coins.add(1),10),e.crystalUpgrades[1]/3)),2,!0)}),3:()=>({x:d(f.pow(1+Math.min(.12+.88*e.upgrades[122]+.001*e.researches[129]*Math.log(e.commonFragments+1)/Math.log(4),.001*e.crystalUpgrades[2]),e.firstOwnedDiamonds+e.secondOwnedDiamonds+e.thirdOwnedDiamonds+e.fourthOwnedDiamonds+e.fifthOwnedDiamonds),2,!0)}),4:()=>({x:d(Math.min(10+.05*e.researches[129]*Math.log(e.commonFragments+1)/Math.log(4)+20*Xe()/400*o.effectiveRuneSpiritPower[3],.05*e.crystalUpgrades[3]),2,!0)}),5:()=>({x:d(f.pow(1.01,(e.challengecompletions[1]+e.challengecompletions[2]+e.challengecompletions[3]+e.challengecompletions[4]+e.challengecompletions[5])*e.crystalUpgrades[4]),2,!0)})},Ub=t=>{var r;return u.t(`upgrades.crystalUpgrades.${t}`,(r=Nc[t])==null?void 0:r.call(Nc))},Bb=t=>u.t("buildings.crystalUpgrades.currentEffect",{effect:t in xg?u.t(`upgrades.crystalEffects.${t}`,xg[t]()):""}),Ei=t=>{let r=e.crystalUpgrades[t-1],n=(e.upgrades[73]>.5&&e.currentChallenge.reincarnation!==0?10:0)+Math.floor(o.rune3level*o.effectiveLevelMult/16)*100/100,a=f.pow(10,o.crystalUpgradesCost[t-1]+o.crystalUpgradeCostIncrement[t-1]*Math.floor(Math.pow(e.crystalUpgrades[t-1]+.5-n,2)/2));i("crystalupgradedescription").textContent=Ub(t),i("crystalupgradeslevel1").innerHTML=u.t("buildings.crystalUpgrades.currentLevel",{amount:d(r,0,!0)}),i("crystalupgradescost1").innerHTML=u.t("buildings.crystalUpgrades.cost",{amount:d(a)}),i("crystalupgradeseffect1").innerHTML=Bb(t)},Ft=(t,r)=>{let n=i(`upg${t}`);e.upgrades[t]>.5?n.style.backgroundColor="green":n.style.backgroundColor="";let a=u.t(`upgrades.descriptions.${t}`),s=e.upgrades[t]>.5?" BOUGHT!":"";e.upgrades[t]>.5&&(r||(i("upgradedescription").textContent=a+s,i("upgradedescription").style.color="gold")),r||Oe()},Gc=()=>{let t=e.ascendBuilding1.owned+e.ascendBuilding2.owned+e.ascendBuilding3.owned+e.ascendBuilding4.owned+e.ascendBuilding5.owned;return t>1e5?Math.pow(1e5,.5)*Math.pow(t,.5):t},Dc={1:()=>({x:d(f.pow(1.05+.01*e.achievements[270]+.001*e.platonicUpgrades[18],e.constantUpgrades[1]),2,!0)}),2:()=>({x:d(f.pow(1+.001*Math.min(100+10*e.achievements[270]+10*e.shopUpgrades.constantEX+3*e.platonicUpgrades[18]+1e3*(o.challenge15Rewards.exponent-1),e.constantUpgrades[2]),Gc()),2,!0)}),3:()=>({x:d(1+.02*e.constantUpgrades[3],2,!0)}),4:()=>({x:d(1+.04*e.constantUpgrades[4],2,!0)}),5:()=>({x:d(f.pow(1+.1*f.log(e.ascendShards.add(1),10),e.constantUpgrades[5]),2,!0)}),6:()=>({x:d(2*e.constantUpgrades[6])}),7:()=>({x:d(7*e.constantUpgrades[7]),y:d(3*e.constantUpgrades[7])}),8:()=>({x:d(1+1/10*e.constantUpgrades[8],2,!0)}),9:()=>({x:d(1+.01*Math.log(e.talismanShards+1)/Math.log(4)*Math.min(1,e.constantUpgrades[9]),4,!0)}),10:()=>({x:d(1+.01*f.log(e.ascendShards.add(1),4)*Math.min(1,e.constantUpgrades[10]),4,!0)})},Rb=t=>{var r;return u.t(`upgrades.constantUpgrades.${t}`,(r=$c[t])==null?void 0:r.call($c))},Ib=t=>{var r;return u.t(`upgrades.constantEffects.${t}`,(r=Dc[t])==null?void 0:r.call(Dc))},eo=t=>{let r,n;return t>=9?e.constantUpgrades[t]>=1?r=0:r=Math.min(1,Math.max(0,Math.floor(1+f.log(f.max(.01,e.ascendShards),10)-Math.log(o.constUpgradeCosts[t])/Math.log(10)))):r=Math.max(0,Math.floor(1+f.log(f.max(.01,e.ascendShards),10)-Math.log(o.constUpgradeCosts[t])/Math.log(10))),r>e.constantUpgrades[t]?n=f.pow(10,r-1).times(o.constUpgradeCosts[t]):n=t>=9&&e.constantUpgrades[t]>=1?new f("0"):f.pow(10,e.constantUpgrades[t]).times(o.constUpgradeCosts[t]),[Math.max(1,r-e.constantUpgrades[t]),n]},Hc=t=>{let[r,n]=eo(t);i("constUpgradeDescription").textContent=Rb(t),t>=9?i("constUpgradeLevel2").textContent=`${d(Math.min(1,e.constantUpgrades[t]))}/1`:i("constUpgradeLevel2").textContent=d(e.constantUpgrades[t]),i("constUpgradeCost2").textContent=`${d(n)} [+${d(r)} LVL]`,i("constUpgradeEffect2").textContent=Ib(t)},to=(t,r=!1)=>{let[n,a]=eo(t);(t<=8||t>=9&&e.constantUpgrades[t]<1)&&e.ascendShards.gte(a)&&(e.constantUpgrades[t]+=n,e.researches[175]===0&&(e.ascendShards=e.ascendShards.sub(a)),r||Hc(t)),Bt(),He()};var Nb=[4,5,6,7,8,9,10,20,26,27,48,49],$b=[41,42,43,44,45,46,47,48,49,50,61,71,72,73,74,75,124,130,135,145,150,175,190],Fc=[200,200,200,500,500,500,500,500,2e3,4e4,5e3,1e3,1e4,2e4,4e4,1e4,4e3,1e4,5e4,12500,5e4,3e4,3e4,4e4,2e5,4e5,1e5,177777,1e5,1e6,5e5,3e5,2e6,4e6,2e6,4e6,1e6,2e7,5e7,1e7,5e6,1e7,1e8,4e7,2e7,4e7,5e7,1e8,5e8,1e8,1,1e4,1e8,1e12,1e16,10,1e5,1e9,1e13,1e17,100,1e6,1e10,1e14,1e18,1e20,1e30,1e40,1e50,1e60,1,1,1e8,1e16,1e30,1e100,1e100,1e200,1e250,1e300],_b=[3,10,5,1,1,1,1,1,1,1,3,10,1,10,10,10,5,1,1,1,5,10,1,10,10,10,1,1,5,1,5,1,1,10,10,10,10,1,1,10,5,10,10,10,10,20,20,1,1,1e5,1,900,100,900,900,20,1,1,400,1e4,100,1,1,1,1,1,1,1e3,1,1e5,1,1,5,1,30,2,25,30,1,1],Oi=(t,r)=>{let n=t===50?.01:0,a=t>50,s=ga(t),l=r?1e5:1,c=e.cubeUpgrades[t];l=Math.min(s-c,l);let p=t<=50?Le("Cube Upgrades"):1,g;return a?(l=r?s:Math.min(s,c+1),g=Sg(c,Fc[t-1],Number(e.wowCubes),l)):g=rr(c,Fc[t-1]*p,Number(e.wowCubes),n,l),g},ga=t=>{let r=_b[t-1];return e.cubeUpgrades[57]>0&&t<50&&t%10===1&&(r+=1),r},Qc=(t,r=e.cubeUpgradesBuyMaxToggle)=>{let n=Oi(t,r),a=i("cubeUpgradeName"),s=i("cubeUpgradeDescription"),l=i("cubeUpgradeCost"),c=i("cubeUpgradeLevel"),p=ga(t);a.textContent=u.t(`cubes.upgradeNames.${t}`),s.innerHTML=u.t(`cubes.upgradeDescriptions.${t}`),l.textContent=u.t("cubes.cubeMetadata.cost",{value1:d(n.cost,0,!0),value2:d(n.levelCanBuy-e.cubeUpgrades[t],0,!0)}),l.style.color="var(--green-text-color)",c.textContent=u.t("cubes.cubeMetadata.level",{value1:d(e.cubeUpgrades[t],0,!0),value2:d(p,0,!0)}),c.style.color="white",Number(e.wowCubes){let r=i(`cubeUpg${t}`),n=ga(t),a=e.cubeUpgrades[t];a>n&&(e.wowCubes.add((a-n)*Fc[t-1]),e.cubeUpgrades[t]=n),e.cubeUpgrades[t]===0&&(r.style.backgroundColor=""),a>0&&a{for(let t of Nb){let r=ga(t);e.cubeUpgrades[t]=r,ma(t)}Gt();for(let t of $b)e.researches[t]=o.researchMaxLevels[t],ns(t)},jc=(t,r=e.cubeUpgradesBuyMaxToggle,n=!1)=>{if(t>50&&t<=55&&!e.singularityUpgrades.cookies.getEffect().bonus||t>55&&t<=60&&!e.singularityUpgrades.cookies2.getEffect().bonus||t>60&&t<=65&&!e.singularityUpgrades.cookies3.getEffect().bonus||t>65&&t<=70&&!e.singularityUpgrades.cookies4.getEffect().bonus||t>70&&!e.singularityUpgrades.cookies5.getEffect().bonus)return;let a=Oi(t,r),s=ga(t);if(Number(e.wowCubes)>=a.cost&&e.cubeUpgrades[t]0)for(let l=94;l<=98;l++)e.upgrades[l]=1,Ft(l,!0);if(t===5&&e.cubeUpgrades[5]>0&&(e.upgrades[99]=1,Ft(99,!0)),t===6&&e.cubeUpgrades[6]>0&&(e.upgrades[100]=1,Ft(100,!0)),t===51&&e.cubeUpgrades[51]>0&&qc(),t===57&&e.cubeUpgrades[57]>0)for(let l=1;l{if(e.autoCubeUpgradesToggle&&(e.highestSingularityCount>=50&&e.insideSingularityChallenge||e.highestSingularityCount>=150)){let t=[];for(let r=1;r0){let r=!1;t.sort((n,a)=>n[1]-a[1]);for(let n of t){let a=ga(n[0]),s=Oi(n[0],!0);Number(e.wowCubes)>=s.cost&&e.cubeUpgrades[n[0]]this.UNLOCKED?this:(this.UNLOCKED=!0,e.highestSingularityCount<5?P(u.t("hepteracts.unlockedCraft",{x:r})):this);this.computeActualCap=()=>{let r=1;return r*=e.singularityChallenges.limitedAscensions.rewards.hepteractCap?2:1,this.CAP*r};this.craft=async(r=!1)=>{var m;let n=null,a=this.computeActualCap(),s=Le("Hepteract Costs");if(!this.UNLOCKED)return P(u.t("hepteracts.notUnlocked"));if(a-this.BAL<=0&&e.toggles[35])return P(u.t("hepteracts.reachedCapacity",{x:d(a,0,!0)}));(isNaN(e.wowAbyssals)||!isFinite(e.wowAbyssals)||e.wowAbyssals<0)&&(e.wowAbyssals=0);let l=Math.floor(e.wowAbyssals/(this.HEPTERACT_CONVERSION*s)*1/(1-this.DISCOUNT)),c=[];for(let h in this.OTHER_CONVERSIONS)h==="worlds"?c.push(Math.floor(e[h]/((m=this.OTHER_CONVERSIONS[h])!=null?m:1))*1/(1-this.DISCOUNT)):c.push(Math.floor(e[h]/(s*this.OTHER_CONVERSIONS[h]))*1/(1-this.DISCOUNT));let p=Math.min(...c),g=Math.min(p,l,a,a-this.BAL);if(isNaN(g)||!isFinite(g))return P(u.t("hepteracts.executionFailed"));if(r)n=a;else{let h=await Ee(u.t("hepteracts.craft",{x:d(g,0,!0),y:Math.floor(g/a*1e4)/100}));if(h===null)return e.toggles[35]?P(u.t("hepteracts.cancelled")):void 0;n=Number(h)}if(isNaN(n)||!isFinite(n)||!Number.isInteger(n))return P(u.t("general.validation.finite"));if(n<=0)return P(u.t("general.validation.zeroOrLess"));if(g=Math.min(p,l,n,a-this.BAL),r&&e.toggles[35]&&!await we(u.t("hepteracts.craftMax",{x:d(g,0,!0),y:Math.floor(g/a*1e4)/100})))return P(u.t("hepteracts.cancelled"));this.BAL=Math.min(a,this.BAL+g),e.wowAbyssals-=g*this.HEPTERACT_CONVERSION*s,e.wowAbyssals<0&&(e.wowAbyssals=0);for(let h of Object.keys(this.OTHER_CONVERSIONS))typeof e[h]=="number"&&(e[h]-=g*s*this.OTHER_CONVERSIONS[h]),e[h]<0?e[h]=0:e[h]instanceof Rn?e[h].sub(g*s*this.OTHER_CONVERSIONS[h]):h==="worlds"&&e.worlds.sub(g*this.OTHER_CONVERSIONS[h]);if(e.toggles[35])return r?P(u.t("hepteracts.craftedHepteractsMax",{x:d(g,0,!0)})):P(u.t("hepteracts.craftedHepteracts",{x:d(g,0,!0)}))};this.expand=async()=>{let n=this.BAL,a=this.computeActualCap(),s=this.CAP;if(!this.UNLOCKED)return P(u.t("hepteracts.notUnlocked"));if(this.BAL1-Number.EPSILON?(this.DISCOUNT=1-Number.EPSILON,this):(this.DISCOUNT+=r,this)}toggleAutomatic(r){let n=i(`${this.HTML_STRING}HepteractAuto`);return this.AUTO=r!=null?r:!this.AUTO,n.textContent=this.AUTO?u.t("general.autoOnColon"):u.t("general.autoOffColon"),n.style.border=`2px solid ${this.AUTO?"green":"red"}`,this}autoCraft(r){let a=Le("Hepteract Costs"),s=this.computeActualCap(),l=Math.floor(r/(a*this.HEPTERACT_CONVERSION)*1/(1-this.DISCOUNT)),c=[];for(let b in this.OTHER_CONVERSIONS)b==="worlds"&&c.push(Math.floor(e[b]/this.OTHER_CONVERSIONS[b])*1/(1-this.DISCOUNT));let p=Math.min(...c),g=Math.min(p,l),m=0,h=Math.min(s-this.BAL,g);for(this.BAL+=h,m+=h,g-=h;this.BAL>=s&&g>=this.CAP;)this.BAL-=this.CAP,this.CAP*=2,s*=2,h=Math.min(s-this.BAL,g),this.BAL+=h,m+=h,g-=h;for(let b in this.OTHER_CONVERSIONS)b==="worlds"&&e.worlds.sub(m*this.OTHER_CONVERSIONS[b]);return e.wowAbyssals-=m*a*this.HEPTERACT_CONVERSION,e.wowAbyssals<0&&(e.wowAbyssals=0),this}get amount(){return this.BAL}get capacity(){return this.CAP}get discount(){return this.DISCOUNT}},Ui={chronos:{LIMIT:1e3,DR:1/6},hyperrealism:{LIMIT:1e3,DR:.33},quark:{LIMIT:1e3,DR:.5},challenge:{LIMIT:1e3,DR:1/6},abyss:{LIMIT:1,DR:0},accelerator:{LIMIT:1e3,DR:.2},acceleratorBoost:{LIMIT:1e3,DR:.2},multiplier:{LIMIT:1e3,DR:.2}},Lg=t=>new kr(t),Ve=t=>{let r=Math.min(e.hepteractCrafts[t].BAL,Ui[t].LIMIT),n=0;if(t==="chronos"&&(n+=1/750*e.platonicUpgrades[19]),t==="quark"){n+=+e.singularityUpgrades.singQuarkHepteract.getEffect().bonus,n+=+e.singularityUpgrades.singQuarkHepteract2.getEffect().bonus,n+=+e.singularityUpgrades.singQuarkHepteract3.getEffect().bonus,n+=+e.octeractUpgrades.octeractImprovedQuarkHept.getEffect().bonus,n+=e.shopUpgrades.improveQuarkHept/100,n+=e.shopUpgrades.improveQuarkHept2/100,n+=e.shopUpgrades.improveQuarkHept3/100,n+=e.shopUpgrades.improveQuarkHept4/100,n+=e.shopUpgrades.improveQuarkHept5/5e3;let a=e.hepteractCrafts[t].BAL;if(1e3Ui[t].LIMIT&&(r*=Math.pow(e.hepteractCrafts[t].BAL/Ui[t].LIMIT,Ui[t].DR+n)),r},sn=t=>{i("hepteractUnlockedText").style.display="block",i("hepteractCurrentEffectText").style.display="block",i("hepteractBalanceText").style.display="block",i("powderDayWarpText").style.display="none",i("hepteractCostText").style.display="block";let r=i("hepteractUnlockedText"),n=i("hepteractEffectText"),a=i("hepteractCurrentEffectText"),s=i("hepteractBalanceText"),l=i("hepteractCostText"),c=i("hepteractBonusCapacity"),p=Le("Hepteract Costs"),g=e.hepteractCrafts[t].computeActualCap()/e.hepteractCrafts[t].CAP;c.textContent=e.hepteractCrafts[t].computeActualCap()/e.hepteractCrafts[t].CAP>1?`Hepteract capacities are currently multiplied by ${g}. Expansions cost what they would if this multiplier were 1.`:"";let m,h;switch(t){case"chronos":m={x:d(Ve("chronos")*6/100,2,!0)},h=d(1e115*p,0,!1);break;case"hyperrealism":m={x:d(Ve("hyperrealism")*6/100,2,!0)},h=d(1e80*p,0,!0);break;case"quark":m={x:d(Ve("quark")*5/100,2,!0)},h="100";break;case"challenge":m={x:d(Ve("challenge")*5/100,2,!0)},h={y:d(1e11*p),z:d(1e22*p)};break;case"abyss":h=d(69*p);break;case"accelerator":m={x:d(2e3*Ve("accelerator"),2,!0),y:d(Ve("accelerator")*3/100,2,!0)},h=d(1e14*p);break;case"acceleratorBoost":m={x:d(Ve("acceleratorBoost")/10,2,!0)},h=d(1e10*p);break;case"multiplier":m={x:d(1e3*Ve("multiplier"),2,!0),y:d(Ve("multiplier")*3/100,2,!0)},h=d(1e130*p);break}n.textContent=u.t(`wowCubes.hepteractForge.descriptions.${t}.effect`),a.textContent=u.t(`wowCubes.hepteractForge.descriptions.${t}.currentEffect`,m),s.textContent=u.t("wowCubes.hepteractForge.inventory",{x:d(e.hepteractCrafts[t].BAL,0,!0),y:d(e.hepteractCrafts[t].computeActualCap(),0,!0)});let b=typeof h=="string"?{y:h}:h;l.textContent=u.t(`wowCubes.hepteractForge.descriptions.${t}.oneCost`,O({x:d(e.hepteractCrafts[t].HEPTERACT_CONVERSION*p,0,!0)},b)),r.textContent=e.hepteractCrafts[t].UNLOCKED?u.t("wowCubes.hepteractForge.unlocked"):u.t("wowCubes.hepteractForge.locked")},Pg=()=>{i("hepteractUnlockedText").style.display="none",i("powderDayWarpText").style.display="none",i("hepteractCostText").style.display="block",i("hepteractCurrentEffectText").textContent=u.t("hepteracts.orbEffect",{x:d(100*(-1+Bn()),2,!0)}),i("hepteractBalanceText").textContent=u.t("hepteracts.orbsPurchasedToday",{x:d(e.overfluxOrbs,0,!0)}),i("hepteractEffectText").textContent=u.t("hepteracts.amalgamate"),i("hepteractCostText").textContent=u.t("hepteracts.cost250k")},Vc=async t=>{let r=Math.floor(e.wowAbyssals/25e4),n;if(t){if(e.toggles[35]&&!await we(u.t("hepteracts.craftMaxOrbs",{x:d(r,0,!0)})))return P(u.t("hepteracts.cancelled"));n=r}else{let g=await Ee(u.t("hepteracts.hepteractInput",{x:d(r,0,!0)}));if(g===null)return e.toggles[35]?P(u.t("hepteracts.cancelled")):void 0;if(n=Number(g),isNaN(n)||!isFinite(n)||!Number.isInteger(n)||n<=0)return P(u.t("general.validation.invalidNumber"))}let a=Math.min(r,Math.floor(n)),s=Bn();e.overfluxOrbs+=a,e.wowAbyssals-=25e4*a;let l=Bn();e.wowAbyssals<0&&(e.wowAbyssals=0);let c=e.shopUpgrades.powderAuto*Lr().mult*a/100;e.overfluxPowder+=c;let p=c>0?u.t("hepteracts.gainedPowder",{x:d(c,2,!0)}):"";if(e.toggles[35])return P(u.t("hepteracts.purchasedOrbs",{x:d(a,0,!0),y:d(100*(l-s),2,!0),z:p}))},Ri=(t,r=!1)=>{let n=i("hepteractToQuarkTradeAuto");r||(e.overfluxOrbsAutoBuy=t!=null?t:!e.overfluxOrbsAutoBuy),n.textContent=e.overfluxOrbsAutoBuy?u.t("general.autoOnColon"):u.t("general.autoOffColon"),n.style.border=`2px solid ${e.overfluxOrbsAutoBuy?"green":"red"}`},Ag=()=>{let t;e.platonicUpgrades[16]>0?t=u.t("hepteracts.allCubeGainExtended",{x:d(100*(Bi()-1),2,!0),y:d(100*(ss()-1),3,!0),z:d(2*e.platonicUpgrades[16]*Math.min(1,e.overfluxPowder/1e5),2,!0),a:d(f.pow(e.overfluxPowder+1,10*e.platonicUpgrades[16]))}):t=u.t("hepteracts.allCubeGain",{x:d(100*(Bi()-1),2,!0),y:d(100*(ss()-1),3,!0)}),i("hepteractUnlockedText").style.display="none",i("hepteractCurrentEffectText").textContent=u.t("hepteracts.powderEffect",{x:t}),i("hepteractBalanceText").textContent=u.t("hepteracts.powderLumps",{x:d(e.overfluxPowder,2,!0)}),i("hepteractEffectText").textContent=u.t("hepteracts.expiredOrbs",{x:d(1/Lr().mult,1,!0)}),i("hepteractCostText").style.display="none",i("powderDayWarpText").style.display="block",i("powderDayWarpText").textContent=u.t("hepteracts.dayWarpsRemaining",{x:e.dailyPowderResetUses})},Wc=async t=>{if(t)if(e.autoWarpCheck){if(await we(u.t("hepteracts.useAllWarpsPrompt")))return i("warpAuto").textContent=u.t("general.autoOffColon"),i("warpAuto").style.border="2px solid red",e.autoWarpCheck=!1,e.dailyPowderResetUses=0,P(u.t("hepteracts.machineCooldown"));if(e.toggles[35])return P(u.t("hepteracts.machineDidNotConsume"))}else{if(await we(u.t("hepteracts.boostQuarksPrompt")))return i("warpAuto").textContent=u.t("general.autoOnColon"),i("warpAuto").style.border="2px solid green",e.autoWarpCheck=!0,e.dailyPowderResetUses===0?P(u.t("hepteracts.machineOverdrive")):P(u.t("hepteracts.machineInOverdrive"));if(e.toggles[35])return P(u.t("hepteracts.machineUsualContinue"))}else{if(e.autoWarpCheck)return P(u.t("hepteracts.warpImpossible"));if(e.dailyPowderResetUses<=0)return P(u.t("hepteracts.machineCooldown"));if(e.overfluxPowder<25)return P(u.t("hepteracts.atleastPowder"));if(await we(u.t("hepteracts.stumbleMachine"))){if(e.overfluxPowder-=25,e.dailyPowderResetUses-=1,ro(),e.toggles[35])return P(u.t("hepteracts.useMachine"))}else if(e.toggles[35])return P(u.t("hepteracts.walkAwayMachine"))}},Eg=()=>{let t=[];for(let r of Object.keys(e.hepteractCrafts)){let n=r;e.hepteractCrafts[n].AUTO&&e.hepteractCrafts[n].UNLOCKED&&t.push(e.hepteractCrafts[n])}return t},Og=new kr({BASE_CAP:1e3,HEPTERACT_CONVERSION:1e4,OTHER_CONVERSIONS:{researchPoints:1e115},HTML_STRING:"chronos",UNLOCKED:!0}),Ug=new kr({BASE_CAP:1e3,HEPTERACT_CONVERSION:1e4,OTHER_CONVERSIONS:{runeshards:1e80},HTML_STRING:"hyperrealism",UNLOCKED:!0}),Bg=new kr({BASE_CAP:1e3,HEPTERACT_CONVERSION:1e4,OTHER_CONVERSIONS:{worlds:100},HTML_STRING:"quark",UNLOCKED:!0}),Rg=new kr({BASE_CAP:1e3,HEPTERACT_CONVERSION:5e4,OTHER_CONVERSIONS:{wowPlatonicCubes:1e11,wowCubes:1e22},HTML_STRING:"challenge"}),Ig=new kr({BASE_CAP:1,HEPTERACT_CONVERSION:1e8,OTHER_CONVERSIONS:{wowCubes:69},HTML_STRING:"abyss"}),Ng=new kr({BASE_CAP:1e3,HEPTERACT_CONVERSION:1e5,OTHER_CONVERSIONS:{wowTesseracts:1e14},HTML_STRING:"accelerator"}),$g=new kr({BASE_CAP:1e3,HEPTERACT_CONVERSION:2e5,OTHER_CONVERSIONS:{wowHypercubes:1e10},HTML_STRING:"acceleratorBoost"}),_g=new kr({BASE_CAP:1e3,HEPTERACT_CONVERSION:3e5,OTHER_CONVERSIONS:{researchPoints:1e130},HTML_STRING:"multiplier"});var Db=["+0.0090% Cubes per Corruption level per level!","+0.018% Tesseracts per Corruption level per level!","+0.054% Hypercubes per Corruption level per level!","Gain +2.4% Platonic Cubes per level! It is that simple.","C10 Exponent: 1.035 --> 1.0375, Constant tax exponent +0.10, 2x faster Constant production, +20% Quarks, +10 Reincarnation Challenge Cap, +5 Ascension Challenge Cap, 2x Obtainium and Offerings, ^1.10 coin gain in C15, as well +1 Corruption Cap Level!","Multiplies Viscosity exponent by (1 + level/30), capacity of ^1 on Multipliers and Accelerators.","Raises speed below 1x to the power of ^(1 - level/30).","Divides Hyperchallenged by (1 + 0.4 * level), with a minimum 1x Challenge requirement multiplier!","Raise Obtainium to the power of (1+(0.09*log10(Obtainium owned))) and add another x2.5 multiplier (Uncorruptable), up until 1e100 Obtainium!","C10 Exponent: 1.0375 --> 1.04, Constant tax exponent +0.20, 10x faster Constant production, +25% Quarks, +10 Reincarnation Challenge Cap, +5 Ascension Challenge Cap, 3.5x Obtainium and Offerings, 2x All Cubes, ^1.25 ant exponent in C15, +1 Corruption Cap Level again!","With this upgrade, you will gain diamonds equal to particle gain on Reincarnation while using Market Deflation 11 or higher! Does not work with Cube upgrade [3x8]!","Gain (1 + lvl/100)x Ant multiplier per Challenge completion, ignoring corruptions to Ants.","Effect of Drought is raised to the power of 0.5.","Reduce the effect of Financial Recession in Challenge 15, multiplying the coin exponent by 1.55.","You begin to find the start of the abyss. Coin Exponent +0.10 in Challenge 15, Challenge 15 Score +25%, Ascension Speed +0.2% per Corruption Level (Max: 20%), +1% all Cube types per C9 Completion (Multiplicative), +30% Quarks, 1e250x Tesseract Building Multiplier, 2x Ascension Count, +30 Reincarnation Challenge Cap, +20 Ascension Challenge Cap, 6x Offerings and Obtainium (Uncorruptable)! Talk about a deep dive.","Increase powder conversion rate by 1% per level, gain +2% Ascension count per level and gain up to 2% more Ascension count per level based on powder, up to 100,000. This will also multiply Tesseract Building production by (Powder + 1)^(10 * level), uncapped.","If Viscosity Corruption is set to level 10 or higher, score multiplier is raised by an exponent. That exponent is 3 + 0.04 per level of this upgrade.","Raise the base percentage of Constant Upgrade 1 by 0.1% and increase the base percentage cap of Constant Upgrade 2 by 0.3% per level!","The diminishing return power on Chronos Hepteract changes from 0.166 to (0.166 + 0.00133 * level) [Max of 0.2333].","You know, maybe some things should be left unbought."],Se={1:{obtainium:1e70,offerings:1e45,cubes:1e13,tesseracts:1e6,hypercubes:1e5,platonics:1e4,abyssals:0,maxLevel:300,priceMult:2},2:{obtainium:3e70,offerings:2e45,cubes:1e11,tesseracts:1e8,hypercubes:1e5,platonics:1e4,abyssals:0,maxLevel:300,priceMult:2},3:{obtainium:1e71,offerings:4e45,cubes:1e11,tesseracts:1e6,hypercubes:1e7,platonics:1e4,abyssals:0,maxLevel:300,priceMult:2},4:{obtainium:4e71,offerings:1e46,cubes:1e12,tesseracts:1e7,hypercubes:1e6,platonics:1e6,abyssals:0,maxLevel:300,priceMult:2},5:{obtainium:1e80,offerings:1e60,cubes:1e14,tesseracts:1e9,hypercubes:1e8,platonics:1e7,abyssals:0,maxLevel:1},6:{obtainium:1e82,offerings:1e61,cubes:1e15,tesseracts:1e9,hypercubes:1e8,platonics:1e7,abyssals:0,maxLevel:10},7:{obtainium:1e84,offerings:3e62,cubes:2e15,tesseracts:2e9,hypercubes:2e8,platonics:15e6,abyssals:0,maxLevel:15},8:{obtainium:1e87,offerings:1e64,cubes:4e15,tesseracts:4e9,hypercubes:4e8,platonics:3e7,abyssals:0,maxLevel:5},9:{obtainium:1e90,offerings:1e66,cubes:1e16,tesseracts:1e10,hypercubes:1e9,platonics:5e7,abyssals:0,maxLevel:1},10:{obtainium:1e93,offerings:1e68,cubes:1e18,tesseracts:1e12,hypercubes:1e11,platonics:1e9,abyssals:0,maxLevel:1},11:{obtainium:2e96,offerings:1e70,cubes:2e17,tesseracts:2e11,hypercubes:2e10,platonics:2e8,abyssals:0,maxLevel:1},12:{obtainium:1e100,offerings:1e72,cubes:1e18,tesseracts:1e12,hypercubes:1e11,platonics:1e9,abyssals:0,maxLevel:10},13:{obtainium:2e104,offerings:1e74,cubes:2e19,tesseracts:4e12,hypercubes:4e11,platonics:4e9,abyssals:0,maxLevel:1},14:{obtainium:1e108,offerings:1e77,cubes:4e20,tesseracts:1e13,hypercubes:1e12,platonics:1e10,abyssals:0,maxLevel:1},15:{obtainium:1e115,offerings:1e80,cubes:1e23,tesseracts:1e15,hypercubes:1e14,platonics:1e12,abyssals:1,maxLevel:1},16:{obtainium:1e140,offerings:1e110,cubes:0,tesseracts:0,hypercubes:25e14,platonics:0,abyssals:0,maxLevel:100,priceMult:10},17:{obtainium:1e145,offerings:1e113,cubes:0,tesseracts:0,hypercubes:1e19,platonics:0,abyssals:2,maxLevel:20,priceMult:10},18:{obtainium:1e150,offerings:1e116,cubes:0,tesseracts:0,hypercubes:1e19,platonics:0,abyssals:4,maxLevel:40,priceMult:500},19:{obtainium:1e160,offerings:1e121,cubes:0,tesseracts:0,hypercubes:1e21,platonics:0,abyssals:64,maxLevel:50,priceMult:200},20:{obtainium:1e180,offerings:1e130,cubes:1e45,tesseracts:1e28,hypercubes:1e25,platonics:1e25,abyssals:Math.pow(2,30)-1,maxLevel:1}},Kc=(t,r=!1)=>{let n=0,a=["obtainium","offerings","cubes","tesseracts","hypercubes","platonics","abyssals"],s=["researchPoints","runeshards","wowCubes","wowTesseracts","wowHypercubes","wowPlatonicCubes","wowAbyssals"],l={obtainium:!1,offerings:!1,cubes:!1,tesseracts:!1,hypercubes:!1,platonics:!1,abyssals:!1,canBuy:!1},c=1;Se[t].priceMult&&(c=Math.pow(Se[t].priceMult,Math.pow(e.platonicUpgrades[t]/(Se[t].maxLevel-1),1.25))),c*=Le("Platonic Costs");for(let p=0;p=Math.floor(Se[t].abyssals*c)||Se[t].abyssals===0)&&(n++,l.abyssals=!0),n===a.length&&e.platonicUpgrades[t]{let r="";e.platonicUpgrades[t]===Se[t].maxLevel&&(r=" [MAX]");let n=Kc(t),a=1;Se[t].priceMult&&(a=Math.pow(Se[t].priceMult,Math.pow(e.platonicUpgrades[t]/(Se[t].maxLevel-1),1.25))),a*=Le("Platonic Costs"),i("platonicUpgradeDescription").textContent=Db[t-1],i("platonicUpgradeLevel").textContent=`Level: ${d(e.platonicUpgrades[t])}/${d(Se[t].maxLevel)}${r}`,i("platonicOfferingCost").textContent=`${d(e.runeshards)}/${d(Se[t].offerings*a)} Offerings`,i("platonicObtainiumCost").textContent=`${d(e.researchPoints)}/${d(Se[t].obtainium*a)} Obtainium`,i("platonicCubeCost").textContent=`${d(e.wowCubes)}/${d(Se[t].cubes*a)} Wow! Cubes`,i("platonicTesseractCost").textContent=`${d(e.wowTesseracts)}/${d(Se[t].tesseracts*a)} Wow! Tesseracts`,i("platonicHypercubeCost").textContent=`${d(e.wowHypercubes)}/${d(Se[t].hypercubes*a)} Wow! Hypercubes`,i("platonicPlatonicCost").textContent=`${d(e.wowPlatonicCubes)}/${d(Se[t].platonics*a)} Platonic! Cubes`,i("platonicHepteractCost").textContent=`${d(e.hepteractCrafts.abyss.BAL)}/${d(Math.floor(Se[t].abyssals*a),0,!0)} Hepteracts of the Abyss`,n.offerings?i("platonicOfferingCost").style.color="lime":i("platonicOfferingCost").style.color="var(--crimson-text-color)",n.obtainium?i("platonicObtainiumCost").style.color="lime":i("platonicObtainiumCost").style.color="var(--crimson-text-color)",n.cubes?i("platonicCubeCost").style.color="lime":i("platonicCubeCost").style.color="var(--crimson-text-color)",n.tesseracts?i("platonicTesseractCost").style.color="lime":i("platonicTesseractCost").style.color="var(--crimson-text-color)",n.hypercubes?i("platonicHypercubeCost").style.color="lime":i("platonicHypercubeCost").style.color="var(--crimson-text-color)",n.platonics?i("platonicPlatonicCost").style.color="lime":i("platonicPlatonicCost").style.color="var(--crimson-text-color)",n.abyssals?i("platonicHepteractCost").style.color="lime":i("platonicHepteractCost").style.color="var(--crimson-text-color)",e.platonicUpgrades[t]{let r=i(`platUpg${t}`),n=Se[t].maxLevel;e.platonicUpgrades[t]===0?r.style.backgroundColor="":e.platonicUpgrades[t]>0&&e.platonicUpgrades[t]{for(;t>0;){let n=Kc(t,r),a=1;if(Se[t].priceMult&&(a=Math.pow(Se[t].priceMult,Math.pow(e.platonicUpgrades[t]/(Se[t].maxLevel-1),1.25))),a*=Le("Platonic Costs"),n.canBuy)e.platonicUpgrades[t]+=1,r||(e.researchPoints-=Math.floor(Se[t].obtainium*a),e.runeshards-=Math.floor(Se[t].offerings*a)),e.wowCubes.sub(Math.floor(Se[t].cubes*a)),e.wowTesseracts.sub(Math.floor(Se[t].tesseracts*a)),e.wowHypercubes.sub(Math.floor(Se[t].hypercubes*a)),e.wowPlatonicCubes.sub(Math.floor(Se[t].platonics*a)),e.hepteractCrafts.abyss.spend(Math.floor(Se[t].abyssals*a)),yt.emit("boughtPlatonicUpgrade",Se[t]),t===20&&!r&&e.singularityCount===0&&P("While I strongly recommended you not to buy this, you did it anyway. For that, you have unlocked the rune of Grandiloquence, for you are a richass.");else break;if(e.platonicUpgrades[t]===Se[t].maxLevel||e.singularityCount===0)break}zc(t),no(t),Oe()},Dg=()=>{if(e.autoPlatonicUpgradesToggle&&(e.highestSingularityCount>=100&&e.insideSingularityChallenge||e.highestSingularityCount>=200))for(let t=1;t{let n=o.effectiveLevelMult,a=1+e.researches[84]/200*(1+1*o.effectiveRuneSpiritPower[5]*Xe()/400),s=so(t-1,!1,e.runelevels[t-1]),l;if(t===1?l={bonus:d(Math.floor(Math.pow(o.rune1level*n/4,1.25))),percent:d(o.rune1level/4*n,2,!0),boost:d(Math.floor(o.rune1level/20*n))}:t===2?l={mult1:d(Math.floor(o.rune2level*n/10)*Math.floor(1+o.rune2level*n/10)/2),mult2:d(n*o.rune2level/4,1,!0),tax:(99.9*(1-Math.pow(6,-(o.rune2level*n)/1e3))).toPrecision(4)}:t===3?l={mult:d(f.pow(o.rune3level*n/2,2).times(f.pow(2,o.rune3level*n/2-8)).add(1),3),gain:d(Math.floor(o.rune3level/16*n))}:t===4?l={delay:(o.rune4level/8*n).toPrecision(3),chance:Math.min(25,o.rune4level/16),tax:(99*(1-Math.pow(4,Math.min(0,(400-o.rune4level)/1100)))).toPrecision(4)}:t===5?l={gain:d(1+o.rune5level/200*n*a,2,!0),speed:d(1+Math.pow(o.rune5level*n*a,2)/2500),offerings:d(o.rune5level*n*a*.005,3,!0)}:t===6?l={percent1:d(10+15/75*$n(),1,!0),percent2:d(1*$n(),0,!0)}:t===7&&r&&(l={exp:d(1e256*(1+e.singularityCount))}),r&&(i("runeshowlevelup").textContent=u.t(`runes.levelup.${t}`,l)),i(`runeshowpower${t}`).textContent=u.t(`runes.power.${t}`,l),r){let c=Fg(t-1,e.runelevels[t-1],e.offeringbuyamount),p=0,g=0;for(;g{e.runeshards=Math.min(1e300,e.runeshards+Qr(t))},ao=t=>[!1,!0,e.achievements[38]>.5,e.achievements[44]>.5,e.achievements[102]>.5,e.researches[82]>.5,ha(),e.platonicUpgrades[20]>0][t],Hg=t=>{let r=0;for(let n=0;n=rt(n+1))&&r++;return r},fa=(t,r=!1,n=0)=>{let a=t-1,s=e.offeringbuyamount;r&&(s=Math.pow(2,e.shopUpgrades.offeringAuto)),r&&n>0&&(s=Math.min(1e4,rt(a+1)));let l=0;if(e.runeshards>0&&e.runelevels[a]x+B,0));n>0&&(m=Math.min(e.runeshards,n));let h=so(a,!1,e.runelevels[a],!0),b=e.upgrades[71]/25,C=h[0]-b*e.runelevels[a],v=h.slice(1,h.length).reduce((x,B)=>x*B,1);for(;m>0&&l=on(a)&&e.runelevels[a]=on(x)&&e.runelevels[x]{let a=on(t,r)-e.runeexp[t],s=rt(t+1),l=[],c=0,p=e.runeshards,g=0,m=so(t,!1,r,!0),h=e.upgrades[71]/25,b=m[0]-h*r,C=m.slice(1,m.length).reduce((v,x)=>v*x,1);for(;gs;function r(s){}t.assertIs=r;function n(s){throw new Error}t.assertNever=n,t.arrayToEnum=s=>{let l={};for(let c of s)l[c]=c;return l},t.getValidEnumValues=s=>{let l=t.objectKeys(s).filter(p=>typeof s[s[p]]!="number"),c={};for(let p of l)c[p]=s[p];return t.objectValues(c)},t.objectValues=s=>t.objectKeys(s).map(function(l){return s[l]}),t.objectKeys=typeof Object.keys=="function"?s=>Object.keys(s):s=>{let l=[];for(let c in s)Object.prototype.hasOwnProperty.call(s,c)&&l.push(c);return l},t.find=(s,l)=>{for(let c of s)if(l(c))return c},t.isInteger=typeof Number.isInteger=="function"?s=>Number.isInteger(s):s=>typeof s=="number"&&isFinite(s)&&Math.floor(s)===s;function a(s,l=" | "){return s.map(c=>typeof c=="string"?`'${c}'`:c).join(l)}t.joinValues=a,t.jsonStringifyReplacer=(s,l)=>typeof l=="bigint"?l.toString():l})(ke||(ke={}));var Yc;(function(t){t.mergeShapes=(r,n)=>O(O({},r),n)})(Yc||(Yc={}));var K=ke.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),cn=t=>{switch(typeof t){case"undefined":return K.undefined;case"string":return K.string;case"number":return isNaN(t)?K.nan:K.number;case"boolean":return K.boolean;case"function":return K.function;case"bigint":return K.bigint;case"symbol":return K.symbol;case"object":return Array.isArray(t)?K.array:t===null?K.null:t.then&&typeof t.then=="function"&&t.catch&&typeof t.catch=="function"?K.promise:typeof Map<"u"&&t instanceof Map?K.map:typeof Set<"u"&&t instanceof Set?K.set:typeof Date<"u"&&t instanceof Date?K.date:K.object;default:return K.unknown}},G=ke.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]),Gb=t=>JSON.stringify(t,null,2).replace(/"([^"]+)":/g,"$1:"),St=class extends Error{get errors(){return this.issues}constructor(r){super(),this.issues=[],this.addIssue=a=>{this.issues=[...this.issues,a]},this.addIssues=(a=[])=>{this.issues=[...this.issues,...a]};let n=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,n):this.__proto__=n,this.name="ZodError",this.issues=r}format(r){let n=r||function(l){return l.message},a={_errors:[]},s=l=>{for(let c of l.issues)if(c.code==="invalid_union")c.unionErrors.map(s);else if(c.code==="invalid_return_type")s(c.returnTypeError);else if(c.code==="invalid_arguments")s(c.argumentsError);else if(c.path.length===0)a._errors.push(n(c));else{let p=a,g=0;for(;gn.message){let n={},a=[];for(let s of this.issues)s.path.length>0?(n[s.path[0]]=n[s.path[0]]||[],n[s.path[0]].push(r(s))):a.push(r(s));return{formErrors:a,fieldErrors:n}}get formErrors(){return this.flatten()}};St.create=t=>new St(t);var ls=(t,r)=>{let n;switch(t.code){case G.invalid_type:t.received===K.undefined?n="Required":n=`Expected ${t.expected}, received ${t.received}`;break;case G.invalid_literal:n=`Invalid literal value, expected ${JSON.stringify(t.expected,ke.jsonStringifyReplacer)}`;break;case G.unrecognized_keys:n=`Unrecognized key(s) in object: ${ke.joinValues(t.keys,", ")}`;break;case G.invalid_union:n="Invalid input";break;case G.invalid_union_discriminator:n=`Invalid discriminator value. Expected ${ke.joinValues(t.options)}`;break;case G.invalid_enum_value:n=`Invalid enum value. Expected ${ke.joinValues(t.options)}, received '${t.received}'`;break;case G.invalid_arguments:n="Invalid function arguments";break;case G.invalid_return_type:n="Invalid function return type";break;case G.invalid_date:n="Invalid date";break;case G.invalid_string:typeof t.validation=="object"?"includes"in t.validation?(n=`Invalid input: must include "${t.validation.includes}"`,typeof t.validation.position=="number"&&(n=`${n} at one or more positions greater than or equal to ${t.validation.position}`)):"startsWith"in t.validation?n=`Invalid input: must start with "${t.validation.startsWith}"`:"endsWith"in t.validation?n=`Invalid input: must end with "${t.validation.endsWith}"`:ke.assertNever(t.validation):t.validation!=="regex"?n=`Invalid ${t.validation}`:n="Invalid";break;case G.too_small:t.type==="array"?n=`Array must contain ${t.exact?"exactly":t.inclusive?"at least":"more than"} ${t.minimum} element(s)`:t.type==="string"?n=`String must contain ${t.exact?"exactly":t.inclusive?"at least":"over"} ${t.minimum} character(s)`:t.type==="number"?n=`Number must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${t.minimum}`:t.type==="date"?n=`Date must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(t.minimum))}`:n="Invalid input";break;case G.too_big:t.type==="array"?n=`Array must contain ${t.exact?"exactly":t.inclusive?"at most":"less than"} ${t.maximum} element(s)`:t.type==="string"?n=`String must contain ${t.exact?"exactly":t.inclusive?"at most":"under"} ${t.maximum} character(s)`:t.type==="number"?n=`Number must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`:t.type==="bigint"?n=`BigInt must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`:t.type==="date"?n=`Date must be ${t.exact?"exactly":t.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(t.maximum))}`:n="Invalid input";break;case G.custom:n="Invalid input";break;case G.invalid_intersection_types:n="Intersection results could not be merged";break;case G.not_multiple_of:n=`Number must be a multiple of ${t.multipleOf}`;break;case G.not_finite:n="Number must be finite";break;default:n=r.defaultError,ke.assertNever(t)}return{message:n}},jg=ls;function Hb(t){jg=t}function Ii(){return jg}var Ni=t=>{let{data:r,path:n,errorMaps:a,issueData:s}=t,l=[...n,...s.path||[]],c=ee(O({},s),{path:l});if(s.message!==void 0)return ee(O({},s),{path:l,message:s.message});let p="",g=a.filter(m=>!!m).slice().reverse();for(let m of g)p=m(c,{data:r,defaultError:p}).message;return ee(O({},s),{path:l,message:p})},Fb=[];function j(t,r){let n=Ii(),a=Ni({issueData:r,data:t.data,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,n,n===ls?void 0:ls].filter(s=>!!s)});t.common.issues.push(a)}var nt=class{constructor(){this.value="valid"}dirty(){this.value==="valid"&&(this.value="dirty")}abort(){this.value!=="aborted"&&(this.value="aborted")}static mergeArray(r,n){let a=[];for(let s of n){if(s.status==="aborted")return ie;s.status==="dirty"&&r.dirty(),a.push(s.value)}return{status:r.value,value:a}}static async mergeObjectAsync(r,n){let a=[];for(let s of n){let l=await s.key,c=await s.value;a.push({key:l,value:c})}return nt.mergeObjectSync(r,a)}static mergeObjectSync(r,n){let a={};for(let s of n){let{key:l,value:c}=s;if(l.status==="aborted"||c.status==="aborted")return ie;l.status==="dirty"&&r.dirty(),c.status==="dirty"&&r.dirty(),l.value!=="__proto__"&&(typeof c.value<"u"||s.alwaysSet)&&(a[l.value]=c.value)}return{status:r.value,value:a}}},ie=Object.freeze({status:"aborted"}),is=t=>({status:"dirty",value:t}),kt=t=>({status:"valid",value:t}),Jc=t=>t.status==="aborted",eu=t=>t.status==="dirty",ba=t=>t.status==="valid",lo=t=>typeof Promise<"u"&&t instanceof Promise;function $i(t,r,n,a){if(n==="a"&&!a)throw new TypeError("Private accessor was defined without a getter");if(typeof r=="function"?t!==r||!a:!r.has(t))throw new TypeError("Cannot read private member from an object whose class did not declare it");return n==="m"?a:n==="a"?a.call(t):a?a.value:r.get(t)}function Vg(t,r,n,a,s){if(a==="m")throw new TypeError("Private method is not writable");if(a==="a"&&!s)throw new TypeError("Private accessor was defined without a setter");if(typeof r=="function"?t!==r||!s:!r.has(t))throw new TypeError("Cannot write private member to an object whose class did not declare it");return a==="a"?s.call(t,n):s?s.value=n:r.set(t,n),n}var Y;(function(t){t.errToObj=r=>typeof r=="string"?{message:r}:r||{},t.toString=r=>typeof r=="string"?r:r==null?void 0:r.message})(Y||(Y={}));var oo,io,sr=class{constructor(r,n,a,s){this._cachedPath=[],this.parent=r,this.data=n,this._path=a,this._key=s}get path(){return this._cachedPath.length||(this._key instanceof Array?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}},Qg=(t,r)=>{if(ba(r))return{success:!0,data:r.value};if(!t.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;let n=new St(t.common.issues);return this._error=n,this._error}}};function ge(t){if(!t)return{};let{errorMap:r,invalid_type_error:n,required_error:a,description:s}=t;if(r&&(n||a))throw new Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);return r?{errorMap:r,description:s}:{errorMap:(c,p)=>{var g,m;let{message:h}=t;return c.code==="invalid_enum_value"?{message:h!=null?h:p.defaultError}:typeof p.data>"u"?{message:(g=h!=null?h:a)!==null&&g!==void 0?g:p.defaultError}:c.code!=="invalid_type"?{message:p.defaultError}:{message:(m=h!=null?h:n)!==null&&m!==void 0?m:p.defaultError}},description:s}}var me=class{get description(){return this._def.description}_getType(r){return cn(r.data)}_getOrReturnCtx(r,n){return n||{common:r.parent.common,data:r.data,parsedType:cn(r.data),schemaErrorMap:this._def.errorMap,path:r.path,parent:r.parent}}_processInputParams(r){return{status:new nt,ctx:{common:r.parent.common,data:r.data,parsedType:cn(r.data),schemaErrorMap:this._def.errorMap,path:r.path,parent:r.parent}}}_parseSync(r){let n=this._parse(r);if(lo(n))throw new Error("Synchronous parse encountered promise.");return n}_parseAsync(r){let n=this._parse(r);return Promise.resolve(n)}parse(r,n){let a=this.safeParse(r,n);if(a.success)return a.data;throw a.error}safeParse(r,n){var a;let s={common:{issues:[],async:(a=n==null?void 0:n.async)!==null&&a!==void 0?a:!1,contextualErrorMap:n==null?void 0:n.errorMap},path:(n==null?void 0:n.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:r,parsedType:cn(r)},l=this._parseSync({data:r,path:s.path,parent:s});return Qg(s,l)}"~validate"(r){var n,a;let s={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:r,parsedType:cn(r)};if(!this["~standard"].async)try{let l=this._parseSync({data:r,path:[],parent:s});return ba(l)?{value:l.value}:{issues:s.common.issues}}catch(l){!((a=(n=l==null?void 0:l.message)===null||n===void 0?void 0:n.toLowerCase())===null||a===void 0)&&a.includes("encountered")&&(this["~standard"].async=!0),s.common={issues:[],async:!0}}return this._parseAsync({data:r,path:[],parent:s}).then(l=>ba(l)?{value:l.value}:{issues:s.common.issues})}async parseAsync(r,n){let a=await this.safeParseAsync(r,n);if(a.success)return a.data;throw a.error}async safeParseAsync(r,n){let a={common:{issues:[],contextualErrorMap:n==null?void 0:n.errorMap,async:!0},path:(n==null?void 0:n.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:r,parsedType:cn(r)},s=this._parse({data:r,path:a.path,parent:a}),l=await(lo(s)?s:Promise.resolve(s));return Qg(a,l)}refine(r,n){let a=s=>typeof n=="string"||typeof n>"u"?{message:n}:typeof n=="function"?n(s):n;return this._refinement((s,l)=>{let c=r(s),p=()=>l.addIssue(O({code:G.custom},a(s)));return typeof Promise<"u"&&c instanceof Promise?c.then(g=>g?!0:(p(),!1)):c?!0:(p(),!1)})}refinement(r,n){return this._refinement((a,s)=>r(a)?!0:(s.addIssue(typeof n=="function"?n(a,s):n),!1))}_refinement(r){return new jt({schema:this,typeName:oe.ZodEffects,effect:{type:"refinement",refinement:r}})}superRefine(r){return this._refinement(r)}constructor(r){this.spa=this.safeParseAsync,this._def=r,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this),this["~standard"]={version:1,vendor:"zod",validate:n=>this["~validate"](n)}}optional(){return ar.create(this,this._def)}nullable(){return Wr.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return qt.create(this)}promise(){return Gn.create(this,this._def)}or(r){return wa.create([this,r],this._def)}and(r){return xa.create(this,r,this._def)}transform(r){return new jt(ee(O({},ge(this._def)),{schema:this,typeName:oe.ZodEffects,effect:{type:"transform",transform:r}}))}default(r){let n=typeof r=="function"?r:()=>r;return new La(ee(O({},ge(this._def)),{innerType:this,defaultValue:n,typeName:oe.ZodDefault}))}brand(){return new co(O({typeName:oe.ZodBranded,type:this},ge(this._def)))}catch(r){let n=typeof r=="function"?r:()=>r;return new Pa(ee(O({},ge(this._def)),{innerType:this,catchValue:n,typeName:oe.ZodCatch}))}describe(r){let n=this.constructor;return new n(ee(O({},this._def),{description:r}))}pipe(r){return Aa.create(this,r)}readonly(){return Ea.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}},Qb=/^c[^\s-]{8,}$/i,qb=/^[0-9a-z]+$/,jb=/^[0-9A-HJKMNP-TV-Z]{26}$/i,Vb=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,Wb=/^[a-z0-9_-]{21}$/i,Kb=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,zb=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,Xb=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,Zb="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$",Zc,Yb=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,Jb=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/(3[0-2]|[12]?[0-9])$/,ey=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/,ty=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,ry=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,ny=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,Wg="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",ay=new RegExp(`^${Wg}$`);function Kg(t){let r="([01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d";return t.precision?r=`${r}\\.\\d{${t.precision}}`:t.precision==null&&(r=`${r}(\\.\\d+)?`),r}function sy(t){return new RegExp(`^${Kg(t)}$`)}function zg(t){let r=`${Wg}T${Kg(t)}`,n=[];return n.push(t.local?"Z?":"Z"),t.offset&&n.push("([+-]\\d{2}:?\\d{2})"),r=`${r}(${n.join("|")})`,new RegExp(`^${r}$`)}function oy(t,r){return!!((r==="v4"||!r)&&Yb.test(t)||(r==="v6"||!r)&&ey.test(t))}function iy(t,r){if(!Kb.test(t))return!1;try{let[n]=t.split("."),a=n.replace(/-/g,"+").replace(/_/g,"/").padEnd(n.length+(4-n.length%4)%4,"="),s=JSON.parse(atob(a));return!(typeof s!="object"||s===null||!s.typ||!s.alg||r&&s.alg!==r)}catch(n){return!1}}function ly(t,r){return!!((r==="v4"||!r)&&Jb.test(t)||(r==="v6"||!r)&&ty.test(t))}var Qt=class extends me{_parse(r){if(this._def.coerce&&(r.data=String(r.data)),this._getType(r)!==K.string){let l=this._getOrReturnCtx(r);return j(l,{code:G.invalid_type,expected:K.string,received:l.parsedType}),ie}let a=new nt,s;for(let l of this._def.checks)if(l.kind==="min")r.data.lengthl.value&&(s=this._getOrReturnCtx(r,s),j(s,{code:G.too_big,maximum:l.value,type:"string",inclusive:!0,exact:!1,message:l.message}),a.dirty());else if(l.kind==="length"){let c=r.data.length>l.value,p=r.data.lengthr.test(s),O({validation:n,code:G.invalid_string},Y.errToObj(a)))}_addCheck(r){return new Qt(ee(O({},this._def),{checks:[...this._def.checks,r]}))}email(r){return this._addCheck(O({kind:"email"},Y.errToObj(r)))}url(r){return this._addCheck(O({kind:"url"},Y.errToObj(r)))}emoji(r){return this._addCheck(O({kind:"emoji"},Y.errToObj(r)))}uuid(r){return this._addCheck(O({kind:"uuid"},Y.errToObj(r)))}nanoid(r){return this._addCheck(O({kind:"nanoid"},Y.errToObj(r)))}cuid(r){return this._addCheck(O({kind:"cuid"},Y.errToObj(r)))}cuid2(r){return this._addCheck(O({kind:"cuid2"},Y.errToObj(r)))}ulid(r){return this._addCheck(O({kind:"ulid"},Y.errToObj(r)))}base64(r){return this._addCheck(O({kind:"base64"},Y.errToObj(r)))}base64url(r){return this._addCheck(O({kind:"base64url"},Y.errToObj(r)))}jwt(r){return this._addCheck(O({kind:"jwt"},Y.errToObj(r)))}ip(r){return this._addCheck(O({kind:"ip"},Y.errToObj(r)))}cidr(r){return this._addCheck(O({kind:"cidr"},Y.errToObj(r)))}datetime(r){var n,a;return typeof r=="string"?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:r}):this._addCheck(O({kind:"datetime",precision:typeof(r==null?void 0:r.precision)>"u"?null:r==null?void 0:r.precision,offset:(n=r==null?void 0:r.offset)!==null&&n!==void 0?n:!1,local:(a=r==null?void 0:r.local)!==null&&a!==void 0?a:!1},Y.errToObj(r==null?void 0:r.message)))}date(r){return this._addCheck({kind:"date",message:r})}time(r){return typeof r=="string"?this._addCheck({kind:"time",precision:null,message:r}):this._addCheck(O({kind:"time",precision:typeof(r==null?void 0:r.precision)>"u"?null:r==null?void 0:r.precision},Y.errToObj(r==null?void 0:r.message)))}duration(r){return this._addCheck(O({kind:"duration"},Y.errToObj(r)))}regex(r,n){return this._addCheck(O({kind:"regex",regex:r},Y.errToObj(n)))}includes(r,n){return this._addCheck(O({kind:"includes",value:r,position:n==null?void 0:n.position},Y.errToObj(n==null?void 0:n.message)))}startsWith(r,n){return this._addCheck(O({kind:"startsWith",value:r},Y.errToObj(n)))}endsWith(r,n){return this._addCheck(O({kind:"endsWith",value:r},Y.errToObj(n)))}min(r,n){return this._addCheck(O({kind:"min",value:r},Y.errToObj(n)))}max(r,n){return this._addCheck(O({kind:"max",value:r},Y.errToObj(n)))}length(r,n){return this._addCheck(O({kind:"length",value:r},Y.errToObj(n)))}nonempty(r){return this.min(1,Y.errToObj(r))}trim(){return new Qt(ee(O({},this._def),{checks:[...this._def.checks,{kind:"trim"}]}))}toLowerCase(){return new Qt(ee(O({},this._def),{checks:[...this._def.checks,{kind:"toLowerCase"}]}))}toUpperCase(){return new Qt(ee(O({},this._def),{checks:[...this._def.checks,{kind:"toUpperCase"}]}))}get isDatetime(){return!!this._def.checks.find(r=>r.kind==="datetime")}get isDate(){return!!this._def.checks.find(r=>r.kind==="date")}get isTime(){return!!this._def.checks.find(r=>r.kind==="time")}get isDuration(){return!!this._def.checks.find(r=>r.kind==="duration")}get isEmail(){return!!this._def.checks.find(r=>r.kind==="email")}get isURL(){return!!this._def.checks.find(r=>r.kind==="url")}get isEmoji(){return!!this._def.checks.find(r=>r.kind==="emoji")}get isUUID(){return!!this._def.checks.find(r=>r.kind==="uuid")}get isNANOID(){return!!this._def.checks.find(r=>r.kind==="nanoid")}get isCUID(){return!!this._def.checks.find(r=>r.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(r=>r.kind==="cuid2")}get isULID(){return!!this._def.checks.find(r=>r.kind==="ulid")}get isIP(){return!!this._def.checks.find(r=>r.kind==="ip")}get isCIDR(){return!!this._def.checks.find(r=>r.kind==="cidr")}get isBase64(){return!!this._def.checks.find(r=>r.kind==="base64")}get isBase64url(){return!!this._def.checks.find(r=>r.kind==="base64url")}get minLength(){let r=null;for(let n of this._def.checks)n.kind==="min"&&(r===null||n.value>r)&&(r=n.value);return r}get maxLength(){let r=null;for(let n of this._def.checks)n.kind==="max"&&(r===null||n.value{var r;return new Qt(O({checks:[],typeName:oe.ZodString,coerce:(r=t==null?void 0:t.coerce)!==null&&r!==void 0?r:!1},ge(t)))};function cy(t,r){let n=(t.toString().split(".")[1]||"").length,a=(r.toString().split(".")[1]||"").length,s=n>a?n:a,l=parseInt(t.toFixed(s).replace(".","")),c=parseInt(r.toFixed(s).replace(".",""));return l%c/Math.pow(10,s)}var qr=class extends me{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(r){if(this._def.coerce&&(r.data=Number(r.data)),this._getType(r)!==K.number){let l=this._getOrReturnCtx(r);return j(l,{code:G.invalid_type,expected:K.number,received:l.parsedType}),ie}let a,s=new nt;for(let l of this._def.checks)l.kind==="int"?ke.isInteger(r.data)||(a=this._getOrReturnCtx(r,a),j(a,{code:G.invalid_type,expected:"integer",received:"float",message:l.message}),s.dirty()):l.kind==="min"?(l.inclusive?r.datal.value:r.data>=l.value)&&(a=this._getOrReturnCtx(r,a),j(a,{code:G.too_big,maximum:l.value,type:"number",inclusive:l.inclusive,exact:!1,message:l.message}),s.dirty()):l.kind==="multipleOf"?cy(r.data,l.value)!==0&&(a=this._getOrReturnCtx(r,a),j(a,{code:G.not_multiple_of,multipleOf:l.value,message:l.message}),s.dirty()):l.kind==="finite"?Number.isFinite(r.data)||(a=this._getOrReturnCtx(r,a),j(a,{code:G.not_finite,message:l.message}),s.dirty()):ke.assertNever(l);return{status:s.value,value:r.data}}gte(r,n){return this.setLimit("min",r,!0,Y.toString(n))}gt(r,n){return this.setLimit("min",r,!1,Y.toString(n))}lte(r,n){return this.setLimit("max",r,!0,Y.toString(n))}lt(r,n){return this.setLimit("max",r,!1,Y.toString(n))}setLimit(r,n,a,s){return new qr(ee(O({},this._def),{checks:[...this._def.checks,{kind:r,value:n,inclusive:a,message:Y.toString(s)}]}))}_addCheck(r){return new qr(ee(O({},this._def),{checks:[...this._def.checks,r]}))}int(r){return this._addCheck({kind:"int",message:Y.toString(r)})}positive(r){return this._addCheck({kind:"min",value:0,inclusive:!1,message:Y.toString(r)})}negative(r){return this._addCheck({kind:"max",value:0,inclusive:!1,message:Y.toString(r)})}nonpositive(r){return this._addCheck({kind:"max",value:0,inclusive:!0,message:Y.toString(r)})}nonnegative(r){return this._addCheck({kind:"min",value:0,inclusive:!0,message:Y.toString(r)})}multipleOf(r,n){return this._addCheck({kind:"multipleOf",value:r,message:Y.toString(n)})}finite(r){return this._addCheck({kind:"finite",message:Y.toString(r)})}safe(r){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:Y.toString(r)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:Y.toString(r)})}get minValue(){let r=null;for(let n of this._def.checks)n.kind==="min"&&(r===null||n.value>r)&&(r=n.value);return r}get maxValue(){let r=null;for(let n of this._def.checks)n.kind==="max"&&(r===null||n.valuer.kind==="int"||r.kind==="multipleOf"&&ke.isInteger(r.value))}get isFinite(){let r=null,n=null;for(let a of this._def.checks){if(a.kind==="finite"||a.kind==="int"||a.kind==="multipleOf")return!0;a.kind==="min"?(n===null||a.value>n)&&(n=a.value):a.kind==="max"&&(r===null||a.valuenew qr(O({checks:[],typeName:oe.ZodNumber,coerce:(t==null?void 0:t.coerce)||!1},ge(t)));var jr=class extends me{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(r){if(this._def.coerce)try{r.data=BigInt(r.data)}catch(l){return this._getInvalidInput(r)}if(this._getType(r)!==K.bigint)return this._getInvalidInput(r);let a,s=new nt;for(let l of this._def.checks)l.kind==="min"?(l.inclusive?r.datal.value:r.data>=l.value)&&(a=this._getOrReturnCtx(r,a),j(a,{code:G.too_big,type:"bigint",maximum:l.value,inclusive:l.inclusive,message:l.message}),s.dirty()):l.kind==="multipleOf"?r.data%l.value!==BigInt(0)&&(a=this._getOrReturnCtx(r,a),j(a,{code:G.not_multiple_of,multipleOf:l.value,message:l.message}),s.dirty()):ke.assertNever(l);return{status:s.value,value:r.data}}_getInvalidInput(r){let n=this._getOrReturnCtx(r);return j(n,{code:G.invalid_type,expected:K.bigint,received:n.parsedType}),ie}gte(r,n){return this.setLimit("min",r,!0,Y.toString(n))}gt(r,n){return this.setLimit("min",r,!1,Y.toString(n))}lte(r,n){return this.setLimit("max",r,!0,Y.toString(n))}lt(r,n){return this.setLimit("max",r,!1,Y.toString(n))}setLimit(r,n,a,s){return new jr(ee(O({},this._def),{checks:[...this._def.checks,{kind:r,value:n,inclusive:a,message:Y.toString(s)}]}))}_addCheck(r){return new jr(ee(O({},this._def),{checks:[...this._def.checks,r]}))}positive(r){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:Y.toString(r)})}negative(r){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:Y.toString(r)})}nonpositive(r){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:Y.toString(r)})}nonnegative(r){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:Y.toString(r)})}multipleOf(r,n){return this._addCheck({kind:"multipleOf",value:r,message:Y.toString(n)})}get minValue(){let r=null;for(let n of this._def.checks)n.kind==="min"&&(r===null||n.value>r)&&(r=n.value);return r}get maxValue(){let r=null;for(let n of this._def.checks)n.kind==="max"&&(r===null||n.value{var r;return new jr(O({checks:[],typeName:oe.ZodBigInt,coerce:(r=t==null?void 0:t.coerce)!==null&&r!==void 0?r:!1},ge(t)))};var ya=class extends me{_parse(r){if(this._def.coerce&&(r.data=!!r.data),this._getType(r)!==K.boolean){let a=this._getOrReturnCtx(r);return j(a,{code:G.invalid_type,expected:K.boolean,received:a.parsedType}),ie}return kt(r.data)}};ya.create=t=>new ya(O({typeName:oe.ZodBoolean,coerce:(t==null?void 0:t.coerce)||!1},ge(t)));var dn=class extends me{_parse(r){if(this._def.coerce&&(r.data=new Date(r.data)),this._getType(r)!==K.date){let l=this._getOrReturnCtx(r);return j(l,{code:G.invalid_type,expected:K.date,received:l.parsedType}),ie}if(isNaN(r.data.getTime())){let l=this._getOrReturnCtx(r);return j(l,{code:G.invalid_date}),ie}let a=new nt,s;for(let l of this._def.checks)l.kind==="min"?r.data.getTime()l.value&&(s=this._getOrReturnCtx(r,s),j(s,{code:G.too_big,message:l.message,inclusive:!0,exact:!1,maximum:l.value,type:"date"}),a.dirty()):ke.assertNever(l);return{status:a.value,value:new Date(r.data.getTime())}}_addCheck(r){return new dn(ee(O({},this._def),{checks:[...this._def.checks,r]}))}min(r,n){return this._addCheck({kind:"min",value:r.getTime(),message:Y.toString(n)})}max(r,n){return this._addCheck({kind:"max",value:r.getTime(),message:Y.toString(n)})}get minDate(){let r=null;for(let n of this._def.checks)n.kind==="min"&&(r===null||n.value>r)&&(r=n.value);return r!=null?new Date(r):null}get maxDate(){let r=null;for(let n of this._def.checks)n.kind==="max"&&(r===null||n.valuenew dn(O({checks:[],coerce:(t==null?void 0:t.coerce)||!1,typeName:oe.ZodDate},ge(t)));var cs=class extends me{_parse(r){if(this._getType(r)!==K.symbol){let a=this._getOrReturnCtx(r);return j(a,{code:G.invalid_type,expected:K.symbol,received:a.parsedType}),ie}return kt(r.data)}};cs.create=t=>new cs(O({typeName:oe.ZodSymbol},ge(t)));var va=class extends me{_parse(r){if(this._getType(r)!==K.undefined){let a=this._getOrReturnCtx(r);return j(a,{code:G.invalid_type,expected:K.undefined,received:a.parsedType}),ie}return kt(r.data)}};va.create=t=>new va(O({typeName:oe.ZodUndefined},ge(t)));var Ca=class extends me{_parse(r){if(this._getType(r)!==K.null){let a=this._getOrReturnCtx(r);return j(a,{code:G.invalid_type,expected:K.null,received:a.parsedType}),ie}return kt(r.data)}};Ca.create=t=>new Ca(O({typeName:oe.ZodNull},ge(t)));var Dn=class extends me{constructor(){super(...arguments),this._any=!0}_parse(r){return kt(r.data)}};Dn.create=t=>new Dn(O({typeName:oe.ZodAny},ge(t)));var un=class extends me{constructor(){super(...arguments),this._unknown=!0}_parse(r){return kt(r.data)}};un.create=t=>new un(O({typeName:oe.ZodUnknown},ge(t)));var Pr=class extends me{_parse(r){let n=this._getOrReturnCtx(r);return j(n,{code:G.invalid_type,expected:K.never,received:n.parsedType}),ie}};Pr.create=t=>new Pr(O({typeName:oe.ZodNever},ge(t)));var us=class extends me{_parse(r){if(this._getType(r)!==K.undefined){let a=this._getOrReturnCtx(r);return j(a,{code:G.invalid_type,expected:K.void,received:a.parsedType}),ie}return kt(r.data)}};us.create=t=>new us(O({typeName:oe.ZodVoid},ge(t)));var qt=class extends me{_parse(r){let{ctx:n,status:a}=this._processInputParams(r),s=this._def;if(n.parsedType!==K.array)return j(n,{code:G.invalid_type,expected:K.array,received:n.parsedType}),ie;if(s.exactLength!==null){let c=n.data.length>s.exactLength.value,p=n.data.lengths.maxLength.value&&(j(n,{code:G.too_big,maximum:s.maxLength.value,type:"array",inclusive:!0,exact:!1,message:s.maxLength.message}),a.dirty()),n.common.async)return Promise.all([...n.data].map((c,p)=>s.type._parseAsync(new sr(n,c,n.path,p)))).then(c=>nt.mergeArray(a,c));let l=[...n.data].map((c,p)=>s.type._parseSync(new sr(n,c,n.path,p)));return nt.mergeArray(a,l)}get element(){return this._def.type}min(r,n){return new qt(ee(O({},this._def),{minLength:{value:r,message:Y.toString(n)}}))}max(r,n){return new qt(ee(O({},this._def),{maxLength:{value:r,message:Y.toString(n)}}))}length(r,n){return new qt(ee(O({},this._def),{exactLength:{value:r,message:Y.toString(n)}}))}nonempty(r){return this.min(1,r)}};qt.create=(t,r)=>new qt(O({type:t,minLength:null,maxLength:null,exactLength:null,typeName:oe.ZodArray},ge(r)));function os(t){if(t instanceof Qe){let r={};for(let n in t.shape){let a=t.shape[n];r[n]=ar.create(os(a))}return new Qe(ee(O({},t._def),{shape:()=>r}))}else return t instanceof qt?new qt(ee(O({},t._def),{type:os(t.element)})):t instanceof ar?ar.create(os(t.unwrap())):t instanceof Wr?Wr.create(os(t.unwrap())):t instanceof or?or.create(t.items.map(r=>os(r))):t}var Qe=class extends me{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;let r=this._def.shape(),n=ke.objectKeys(r);return this._cached={shape:r,keys:n}}_parse(r){if(this._getType(r)!==K.object){let m=this._getOrReturnCtx(r);return j(m,{code:G.invalid_type,expected:K.object,received:m.parsedType}),ie}let{status:a,ctx:s}=this._processInputParams(r),{shape:l,keys:c}=this._getCached(),p=[];if(!(this._def.catchall instanceof Pr&&this._def.unknownKeys==="strip"))for(let m in s.data)c.includes(m)||p.push(m);let g=[];for(let m of c){let h=l[m],b=s.data[m];g.push({key:{status:"valid",value:m},value:h._parse(new sr(s,b,s.path,m)),alwaysSet:m in s.data})}if(this._def.catchall instanceof Pr){let m=this._def.unknownKeys;if(m==="passthrough")for(let h of p)g.push({key:{status:"valid",value:h},value:{status:"valid",value:s.data[h]}});else if(m==="strict")p.length>0&&(j(s,{code:G.unrecognized_keys,keys:p}),a.dirty());else if(m!=="strip")throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{let m=this._def.catchall;for(let h of p){let b=s.data[h];g.push({key:{status:"valid",value:h},value:m._parse(new sr(s,b,s.path,h)),alwaysSet:h in s.data})}}return s.common.async?Promise.resolve().then(async()=>{let m=[];for(let h of g){let b=await h.key,C=await h.value;m.push({key:b,value:C,alwaysSet:h.alwaysSet})}return m}).then(m=>nt.mergeObjectSync(a,m)):nt.mergeObjectSync(a,g)}get shape(){return this._def.shape()}strict(r){return Y.errToObj,new Qe(O(ee(O({},this._def),{unknownKeys:"strict"}),r!==void 0?{errorMap:(n,a)=>{var s,l,c,p;let g=(c=(l=(s=this._def).errorMap)===null||l===void 0?void 0:l.call(s,n,a).message)!==null&&c!==void 0?c:a.defaultError;return n.code==="unrecognized_keys"?{message:(p=Y.errToObj(r).message)!==null&&p!==void 0?p:g}:{message:g}}}:{}))}strip(){return new Qe(ee(O({},this._def),{unknownKeys:"strip"}))}passthrough(){return new Qe(ee(O({},this._def),{unknownKeys:"passthrough"}))}extend(r){return new Qe(ee(O({},this._def),{shape:()=>O(O({},this._def.shape()),r)}))}merge(r){return new Qe({unknownKeys:r._def.unknownKeys,catchall:r._def.catchall,shape:()=>O(O({},this._def.shape()),r._def.shape()),typeName:oe.ZodObject})}setKey(r,n){return this.augment({[r]:n})}catchall(r){return new Qe(ee(O({},this._def),{catchall:r}))}pick(r){let n={};return ke.objectKeys(r).forEach(a=>{r[a]&&this.shape[a]&&(n[a]=this.shape[a])}),new Qe(ee(O({},this._def),{shape:()=>n}))}omit(r){let n={};return ke.objectKeys(this.shape).forEach(a=>{r[a]||(n[a]=this.shape[a])}),new Qe(ee(O({},this._def),{shape:()=>n}))}deepPartial(){return os(this)}partial(r){let n={};return ke.objectKeys(this.shape).forEach(a=>{let s=this.shape[a];r&&!r[a]?n[a]=s:n[a]=s.optional()}),new Qe(ee(O({},this._def),{shape:()=>n}))}required(r){let n={};return ke.objectKeys(this.shape).forEach(a=>{if(r&&!r[a])n[a]=this.shape[a];else{let l=this.shape[a];for(;l instanceof ar;)l=l._def.innerType;n[a]=l}}),new Qe(ee(O({},this._def),{shape:()=>n}))}keyof(){return Xg(ke.objectKeys(this.shape))}};Qe.create=(t,r)=>new Qe(O({shape:()=>t,unknownKeys:"strip",catchall:Pr.create(),typeName:oe.ZodObject},ge(r)));Qe.strictCreate=(t,r)=>new Qe(O({shape:()=>t,unknownKeys:"strict",catchall:Pr.create(),typeName:oe.ZodObject},ge(r)));Qe.lazycreate=(t,r)=>new Qe(O({shape:t,unknownKeys:"strip",catchall:Pr.create(),typeName:oe.ZodObject},ge(r)));var wa=class extends me{_parse(r){let{ctx:n}=this._processInputParams(r),a=this._def.options;function s(l){for(let p of l)if(p.result.status==="valid")return p.result;for(let p of l)if(p.result.status==="dirty")return n.common.issues.push(...p.ctx.common.issues),p.result;let c=l.map(p=>new St(p.ctx.common.issues));return j(n,{code:G.invalid_union,unionErrors:c}),ie}if(n.common.async)return Promise.all(a.map(async l=>{let c=ee(O({},n),{common:ee(O({},n.common),{issues:[]}),parent:null});return{result:await l._parseAsync({data:n.data,path:n.path,parent:c}),ctx:c}})).then(s);{let l,c=[];for(let g of a){let m=ee(O({},n),{common:ee(O({},n.common),{issues:[]}),parent:null}),h=g._parseSync({data:n.data,path:n.path,parent:m});if(h.status==="valid")return h;h.status==="dirty"&&!l&&(l={result:h,ctx:m}),m.common.issues.length&&c.push(m.common.issues)}if(l)return n.common.issues.push(...l.ctx.common.issues),l.result;let p=c.map(g=>new St(g));return j(n,{code:G.invalid_union,unionErrors:p}),ie}}get options(){return this._def.options}};wa.create=(t,r)=>new wa(O({options:t,typeName:oe.ZodUnion},ge(r)));var ln=t=>t instanceof Ta?ln(t.schema):t instanceof jt?ln(t.innerType()):t instanceof Sa?[t.value]:t instanceof Vr?t.options:t instanceof ka?ke.objectValues(t.enum):t instanceof La?ln(t._def.innerType):t instanceof va?[void 0]:t instanceof Ca?[null]:t instanceof ar?[void 0,...ln(t.unwrap())]:t instanceof Wr?[null,...ln(t.unwrap())]:t instanceof co||t instanceof Ea?ln(t.unwrap()):t instanceof Pa?ln(t._def.innerType):[],ds=class extends me{_parse(r){let{ctx:n}=this._processInputParams(r);if(n.parsedType!==K.object)return j(n,{code:G.invalid_type,expected:K.object,received:n.parsedType}),ie;let a=this.discriminator,s=n.data[a],l=this.optionsMap.get(s);return l?n.common.async?l._parseAsync({data:n.data,path:n.path,parent:n}):l._parseSync({data:n.data,path:n.path,parent:n}):(j(n,{code:G.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[a]}),ie)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(r,n,a){let s=new Map;for(let l of n){let c=ln(l.shape[r]);if(!c.length)throw new Error(`A discriminator value for key \`${r}\` could not be extracted from all schema options`);for(let p of c){if(s.has(p))throw new Error(`Discriminator property ${String(r)} has duplicate value ${String(p)}`);s.set(p,l)}}return new ds(O({typeName:oe.ZodDiscriminatedUnion,discriminator:r,options:n,optionsMap:s},ge(a)))}};function tu(t,r){let n=cn(t),a=cn(r);if(t===r)return{valid:!0,data:t};if(n===K.object&&a===K.object){let s=ke.objectKeys(r),l=ke.objectKeys(t).filter(p=>s.indexOf(p)!==-1),c=O(O({},t),r);for(let p of l){let g=tu(t[p],r[p]);if(!g.valid)return{valid:!1};c[p]=g.data}return{valid:!0,data:c}}else if(n===K.array&&a===K.array){if(t.length!==r.length)return{valid:!1};let s=[];for(let l=0;l{if(Jc(l)||Jc(c))return ie;let p=tu(l.value,c.value);return p.valid?((eu(l)||eu(c))&&n.dirty(),{status:n.value,value:p.data}):(j(a,{code:G.invalid_intersection_types}),ie)};return a.common.async?Promise.all([this._def.left._parseAsync({data:a.data,path:a.path,parent:a}),this._def.right._parseAsync({data:a.data,path:a.path,parent:a})]).then(([l,c])=>s(l,c)):s(this._def.left._parseSync({data:a.data,path:a.path,parent:a}),this._def.right._parseSync({data:a.data,path:a.path,parent:a}))}};xa.create=(t,r,n)=>new xa(O({left:t,right:r,typeName:oe.ZodIntersection},ge(n)));var or=class extends me{_parse(r){let{status:n,ctx:a}=this._processInputParams(r);if(a.parsedType!==K.array)return j(a,{code:G.invalid_type,expected:K.array,received:a.parsedType}),ie;if(a.data.lengththis._def.items.length&&(j(a,{code:G.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),n.dirty());let l=[...a.data].map((c,p)=>{let g=this._def.items[p]||this._def.rest;return g?g._parse(new sr(a,c,a.path,p)):null}).filter(c=>!!c);return a.common.async?Promise.all(l).then(c=>nt.mergeArray(n,c)):nt.mergeArray(n,l)}get items(){return this._def.items}rest(r){return new or(ee(O({},this._def),{rest:r}))}};or.create=(t,r)=>{if(!Array.isArray(t))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new or(O({items:t,typeName:oe.ZodTuple,rest:null},ge(r)))};var Ma=class extends me{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(r){let{status:n,ctx:a}=this._processInputParams(r);if(a.parsedType!==K.object)return j(a,{code:G.invalid_type,expected:K.object,received:a.parsedType}),ie;let s=[],l=this._def.keyType,c=this._def.valueType;for(let p in a.data)s.push({key:l._parse(new sr(a,p,a.path,p)),value:c._parse(new sr(a,a.data[p],a.path,p)),alwaysSet:p in a.data});return a.common.async?nt.mergeObjectAsync(n,s):nt.mergeObjectSync(n,s)}get element(){return this._def.valueType}static create(r,n,a){return n instanceof me?new Ma(O({keyType:r,valueType:n,typeName:oe.ZodRecord},ge(a))):new Ma(O({keyType:Qt.create(),valueType:r,typeName:oe.ZodRecord},ge(n)))}},ps=class extends me{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(r){let{status:n,ctx:a}=this._processInputParams(r);if(a.parsedType!==K.map)return j(a,{code:G.invalid_type,expected:K.map,received:a.parsedType}),ie;let s=this._def.keyType,l=this._def.valueType,c=[...a.data.entries()].map(([p,g],m)=>({key:s._parse(new sr(a,p,a.path,[m,"key"])),value:l._parse(new sr(a,g,a.path,[m,"value"]))}));if(a.common.async){let p=new Map;return Promise.resolve().then(async()=>{for(let g of c){let m=await g.key,h=await g.value;if(m.status==="aborted"||h.status==="aborted")return ie;(m.status==="dirty"||h.status==="dirty")&&n.dirty(),p.set(m.value,h.value)}return{status:n.value,value:p}})}else{let p=new Map;for(let g of c){let m=g.key,h=g.value;if(m.status==="aborted"||h.status==="aborted")return ie;(m.status==="dirty"||h.status==="dirty")&&n.dirty(),p.set(m.value,h.value)}return{status:n.value,value:p}}}};ps.create=(t,r,n)=>new ps(O({valueType:r,keyType:t,typeName:oe.ZodMap},ge(n)));var pn=class extends me{_parse(r){let{status:n,ctx:a}=this._processInputParams(r);if(a.parsedType!==K.set)return j(a,{code:G.invalid_type,expected:K.set,received:a.parsedType}),ie;let s=this._def;s.minSize!==null&&a.data.sizes.maxSize.value&&(j(a,{code:G.too_big,maximum:s.maxSize.value,type:"set",inclusive:!0,exact:!1,message:s.maxSize.message}),n.dirty());let l=this._def.valueType;function c(g){let m=new Set;for(let h of g){if(h.status==="aborted")return ie;h.status==="dirty"&&n.dirty(),m.add(h.value)}return{status:n.value,value:m}}let p=[...a.data.values()].map((g,m)=>l._parse(new sr(a,g,a.path,m)));return a.common.async?Promise.all(p).then(g=>c(g)):c(p)}min(r,n){return new pn(ee(O({},this._def),{minSize:{value:r,message:Y.toString(n)}}))}max(r,n){return new pn(ee(O({},this._def),{maxSize:{value:r,message:Y.toString(n)}}))}size(r,n){return this.min(r,n).max(r,n)}nonempty(r){return this.min(1,r)}};pn.create=(t,r)=>new pn(O({valueType:t,minSize:null,maxSize:null,typeName:oe.ZodSet},ge(r)));var _n=class extends me{constructor(){super(...arguments),this.validate=this.implement}_parse(r){let{ctx:n}=this._processInputParams(r);if(n.parsedType!==K.function)return j(n,{code:G.invalid_type,expected:K.function,received:n.parsedType}),ie;function a(p,g){return Ni({data:p,path:n.path,errorMaps:[n.common.contextualErrorMap,n.schemaErrorMap,Ii(),ls].filter(m=>!!m),issueData:{code:G.invalid_arguments,argumentsError:g}})}function s(p,g){return Ni({data:p,path:n.path,errorMaps:[n.common.contextualErrorMap,n.schemaErrorMap,Ii(),ls].filter(m=>!!m),issueData:{code:G.invalid_return_type,returnTypeError:g}})}let l={errorMap:n.common.contextualErrorMap},c=n.data;if(this._def.returns instanceof Gn){let p=this;return kt(async function(...g){let m=new St([]),h=await p._def.args.parseAsync(g,l).catch(v=>{throw m.addIssue(a(g,v)),m}),b=await Reflect.apply(c,this,h);return await p._def.returns._def.type.parseAsync(b,l).catch(v=>{throw m.addIssue(s(b,v)),m})})}else{let p=this;return kt(function(...g){let m=p._def.args.safeParse(g,l);if(!m.success)throw new St([a(g,m.error)]);let h=Reflect.apply(c,this,m.data),b=p._def.returns.safeParse(h,l);if(!b.success)throw new St([s(h,b.error)]);return b.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...r){return new _n(ee(O({},this._def),{args:or.create(r).rest(un.create())}))}returns(r){return new _n(ee(O({},this._def),{returns:r}))}implement(r){return this.parse(r)}strictImplement(r){return this.parse(r)}static create(r,n,a){return new _n(O({args:r||or.create([]).rest(un.create()),returns:n||un.create(),typeName:oe.ZodFunction},ge(a)))}},Ta=class extends me{get schema(){return this._def.getter()}_parse(r){let{ctx:n}=this._processInputParams(r);return this._def.getter()._parse({data:n.data,path:n.path,parent:n})}};Ta.create=(t,r)=>new Ta(O({getter:t,typeName:oe.ZodLazy},ge(r)));var Sa=class extends me{_parse(r){if(r.data!==this._def.value){let n=this._getOrReturnCtx(r);return j(n,{received:n.data,code:G.invalid_literal,expected:this._def.value}),ie}return{status:"valid",value:r.data}}get value(){return this._def.value}};Sa.create=(t,r)=>new Sa(O({value:t,typeName:oe.ZodLiteral},ge(r)));function Xg(t,r){return new Vr(O({values:t,typeName:oe.ZodEnum},ge(r)))}var Vr=class extends me{constructor(){super(...arguments),oo.set(this,void 0)}_parse(r){if(typeof r.data!="string"){let n=this._getOrReturnCtx(r),a=this._def.values;return j(n,{expected:ke.joinValues(a),received:n.parsedType,code:G.invalid_type}),ie}if($i(this,oo,"f")||Vg(this,oo,new Set(this._def.values),"f"),!$i(this,oo,"f").has(r.data)){let n=this._getOrReturnCtx(r),a=this._def.values;return j(n,{received:n.data,code:G.invalid_enum_value,options:a}),ie}return kt(r.data)}get options(){return this._def.values}get enum(){let r={};for(let n of this._def.values)r[n]=n;return r}get Values(){let r={};for(let n of this._def.values)r[n]=n;return r}get Enum(){let r={};for(let n of this._def.values)r[n]=n;return r}extract(r,n=this._def){return Vr.create(r,O(O({},this._def),n))}exclude(r,n=this._def){return Vr.create(this.options.filter(a=>!r.includes(a)),O(O({},this._def),n))}};oo=new WeakMap;Vr.create=Xg;var ka=class extends me{constructor(){super(...arguments),io.set(this,void 0)}_parse(r){let n=ke.getValidEnumValues(this._def.values),a=this._getOrReturnCtx(r);if(a.parsedType!==K.string&&a.parsedType!==K.number){let s=ke.objectValues(n);return j(a,{expected:ke.joinValues(s),received:a.parsedType,code:G.invalid_type}),ie}if($i(this,io,"f")||Vg(this,io,new Set(ke.getValidEnumValues(this._def.values)),"f"),!$i(this,io,"f").has(r.data)){let s=ke.objectValues(n);return j(a,{received:a.data,code:G.invalid_enum_value,options:s}),ie}return kt(r.data)}get enum(){return this._def.values}};io=new WeakMap;ka.create=(t,r)=>new ka(O({values:t,typeName:oe.ZodNativeEnum},ge(r)));var Gn=class extends me{unwrap(){return this._def.type}_parse(r){let{ctx:n}=this._processInputParams(r);if(n.parsedType!==K.promise&&n.common.async===!1)return j(n,{code:G.invalid_type,expected:K.promise,received:n.parsedType}),ie;let a=n.parsedType===K.promise?n.data:Promise.resolve(n.data);return kt(a.then(s=>this._def.type.parseAsync(s,{path:n.path,errorMap:n.common.contextualErrorMap})))}};Gn.create=(t,r)=>new Gn(O({type:t,typeName:oe.ZodPromise},ge(r)));var jt=class extends me{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===oe.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(r){let{status:n,ctx:a}=this._processInputParams(r),s=this._def.effect||null,l={addIssue:c=>{j(a,c),c.fatal?n.abort():n.dirty()},get path(){return a.path}};if(l.addIssue=l.addIssue.bind(l),s.type==="preprocess"){let c=s.transform(a.data,l);if(a.common.async)return Promise.resolve(c).then(async p=>{if(n.value==="aborted")return ie;let g=await this._def.schema._parseAsync({data:p,path:a.path,parent:a});return g.status==="aborted"?ie:g.status==="dirty"||n.value==="dirty"?is(g.value):g});{if(n.value==="aborted")return ie;let p=this._def.schema._parseSync({data:c,path:a.path,parent:a});return p.status==="aborted"?ie:p.status==="dirty"||n.value==="dirty"?is(p.value):p}}if(s.type==="refinement"){let c=p=>{let g=s.refinement(p,l);if(a.common.async)return Promise.resolve(g);if(g instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return p};if(a.common.async===!1){let p=this._def.schema._parseSync({data:a.data,path:a.path,parent:a});return p.status==="aborted"?ie:(p.status==="dirty"&&n.dirty(),c(p.value),{status:n.value,value:p.value})}else return this._def.schema._parseAsync({data:a.data,path:a.path,parent:a}).then(p=>p.status==="aborted"?ie:(p.status==="dirty"&&n.dirty(),c(p.value).then(()=>({status:n.value,value:p.value}))))}if(s.type==="transform")if(a.common.async===!1){let c=this._def.schema._parseSync({data:a.data,path:a.path,parent:a});if(!ba(c))return c;let p=s.transform(c.value,l);if(p instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:n.value,value:p}}else return this._def.schema._parseAsync({data:a.data,path:a.path,parent:a}).then(c=>ba(c)?Promise.resolve(s.transform(c.value,l)).then(p=>({status:n.value,value:p})):c);ke.assertNever(s)}};jt.create=(t,r,n)=>new jt(O({schema:t,typeName:oe.ZodEffects,effect:r},ge(n)));jt.createWithPreprocess=(t,r,n)=>new jt(O({schema:r,effect:{type:"preprocess",transform:t},typeName:oe.ZodEffects},ge(n)));var ar=class extends me{_parse(r){return this._getType(r)===K.undefined?kt(void 0):this._def.innerType._parse(r)}unwrap(){return this._def.innerType}};ar.create=(t,r)=>new ar(O({innerType:t,typeName:oe.ZodOptional},ge(r)));var Wr=class extends me{_parse(r){return this._getType(r)===K.null?kt(null):this._def.innerType._parse(r)}unwrap(){return this._def.innerType}};Wr.create=(t,r)=>new Wr(O({innerType:t,typeName:oe.ZodNullable},ge(r)));var La=class extends me{_parse(r){let{ctx:n}=this._processInputParams(r),a=n.data;return n.parsedType===K.undefined&&(a=this._def.defaultValue()),this._def.innerType._parse({data:a,path:n.path,parent:n})}removeDefault(){return this._def.innerType}};La.create=(t,r)=>new La(O({innerType:t,typeName:oe.ZodDefault,defaultValue:typeof r.default=="function"?r.default:()=>r.default},ge(r)));var Pa=class extends me{_parse(r){let{ctx:n}=this._processInputParams(r),a=ee(O({},n),{common:ee(O({},n.common),{issues:[]})}),s=this._def.innerType._parse({data:a.data,path:a.path,parent:O({},a)});return lo(s)?s.then(l=>({status:"valid",value:l.status==="valid"?l.value:this._def.catchValue({get error(){return new St(a.common.issues)},input:a.data})})):{status:"valid",value:s.status==="valid"?s.value:this._def.catchValue({get error(){return new St(a.common.issues)},input:a.data})}}removeCatch(){return this._def.innerType}};Pa.create=(t,r)=>new Pa(O({innerType:t,typeName:oe.ZodCatch,catchValue:typeof r.catch=="function"?r.catch:()=>r.catch},ge(r)));var gs=class extends me{_parse(r){if(this._getType(r)!==K.nan){let a=this._getOrReturnCtx(r);return j(a,{code:G.invalid_type,expected:K.nan,received:a.parsedType}),ie}return{status:"valid",value:r.data}}};gs.create=t=>new gs(O({typeName:oe.ZodNaN},ge(t)));var uy=Symbol("zod_brand"),co=class extends me{_parse(r){let{ctx:n}=this._processInputParams(r),a=n.data;return this._def.type._parse({data:a,path:n.path,parent:n})}unwrap(){return this._def.type}},Aa=class extends me{_parse(r){let{status:n,ctx:a}=this._processInputParams(r);if(a.common.async)return(async()=>{let l=await this._def.in._parseAsync({data:a.data,path:a.path,parent:a});return l.status==="aborted"?ie:l.status==="dirty"?(n.dirty(),is(l.value)):this._def.out._parseAsync({data:l.value,path:a.path,parent:a})})();{let s=this._def.in._parseSync({data:a.data,path:a.path,parent:a});return s.status==="aborted"?ie:s.status==="dirty"?(n.dirty(),{status:"dirty",value:s.value}):this._def.out._parseSync({data:s.value,path:a.path,parent:a})}}static create(r,n){return new Aa({in:r,out:n,typeName:oe.ZodPipeline})}},Ea=class extends me{_parse(r){let n=this._def.innerType._parse(r),a=s=>(ba(s)&&(s.value=Object.freeze(s.value)),s);return lo(n)?n.then(s=>a(s)):a(n)}unwrap(){return this._def.innerType}};Ea.create=(t,r)=>new Ea(O({innerType:t,typeName:oe.ZodReadonly},ge(r)));function Zg(t,r={},n){return t?Dn.create().superRefine((a,s)=>{var l,c;if(!t(a)){let p=typeof r=="function"?r(a):typeof r=="string"?{message:r}:r,g=(c=(l=p.fatal)!==null&&l!==void 0?l:n)!==null&&c!==void 0?c:!0,m=typeof p=="string"?{message:p}:p;s.addIssue(ee(O({code:"custom"},m),{fatal:g}))}}):Dn.create()}var dy={object:Qe.lazycreate},oe;(function(t){t.ZodString="ZodString",t.ZodNumber="ZodNumber",t.ZodNaN="ZodNaN",t.ZodBigInt="ZodBigInt",t.ZodBoolean="ZodBoolean",t.ZodDate="ZodDate",t.ZodSymbol="ZodSymbol",t.ZodUndefined="ZodUndefined",t.ZodNull="ZodNull",t.ZodAny="ZodAny",t.ZodUnknown="ZodUnknown",t.ZodNever="ZodNever",t.ZodVoid="ZodVoid",t.ZodArray="ZodArray",t.ZodObject="ZodObject",t.ZodUnion="ZodUnion",t.ZodDiscriminatedUnion="ZodDiscriminatedUnion",t.ZodIntersection="ZodIntersection",t.ZodTuple="ZodTuple",t.ZodRecord="ZodRecord",t.ZodMap="ZodMap",t.ZodSet="ZodSet",t.ZodFunction="ZodFunction",t.ZodLazy="ZodLazy",t.ZodLiteral="ZodLiteral",t.ZodEnum="ZodEnum",t.ZodEffects="ZodEffects",t.ZodNativeEnum="ZodNativeEnum",t.ZodOptional="ZodOptional",t.ZodNullable="ZodNullable",t.ZodDefault="ZodDefault",t.ZodCatch="ZodCatch",t.ZodPromise="ZodPromise",t.ZodBranded="ZodBranded",t.ZodPipeline="ZodPipeline",t.ZodReadonly="ZodReadonly"})(oe||(oe={}));var py=(t,r={message:`Input not instance of ${t.name}`})=>Zg(n=>n instanceof t,r),Yg=Qt.create,Jg=qr.create,gy=gs.create,my=jr.create,em=ya.create,fy=dn.create,hy=cs.create,by=va.create,yy=Ca.create,vy=Dn.create,Cy=un.create,wy=Pr.create,xy=us.create,My=qt.create,Ty=Qe.create,Sy=Qe.strictCreate,ky=wa.create,Ly=ds.create,Py=xa.create,Ay=or.create,Ey=Ma.create,Oy=ps.create,Uy=pn.create,By=_n.create,Ry=Ta.create,Iy=Sa.create,Ny=Vr.create,$y=ka.create,_y=Gn.create,qg=jt.create,Dy=ar.create,Gy=Wr.create,Hy=jt.createWithPreprocess,Fy=Aa.create,Qy=()=>Yg().optional(),qy=()=>Jg().optional(),jy=()=>em().optional(),Vy={string:t=>Qt.create(ee(O({},t),{coerce:!0})),number:t=>qr.create(ee(O({},t),{coerce:!0})),boolean:t=>ya.create(ee(O({},t),{coerce:!0})),bigint:t=>jr.create(ee(O({},t),{coerce:!0})),date:t=>dn.create(ee(O({},t),{coerce:!0}))},Wy=ie,y=Object.freeze({__proto__:null,defaultErrorMap:ls,setErrorMap:Hb,getErrorMap:Ii,makeIssue:Ni,EMPTY_PATH:Fb,addIssueToContext:j,ParseStatus:nt,INVALID:ie,DIRTY:is,OK:kt,isAborted:Jc,isDirty:eu,isValid:ba,isAsync:lo,get util(){return ke},get objectUtil(){return Yc},ZodParsedType:K,getParsedType:cn,ZodType:me,datetimeRegex:zg,ZodString:Qt,ZodNumber:qr,ZodBigInt:jr,ZodBoolean:ya,ZodDate:dn,ZodSymbol:cs,ZodUndefined:va,ZodNull:Ca,ZodAny:Dn,ZodUnknown:un,ZodNever:Pr,ZodVoid:us,ZodArray:qt,ZodObject:Qe,ZodUnion:wa,ZodDiscriminatedUnion:ds,ZodIntersection:xa,ZodTuple:or,ZodRecord:Ma,ZodMap:ps,ZodSet:pn,ZodFunction:_n,ZodLazy:Ta,ZodLiteral:Sa,ZodEnum:Vr,ZodNativeEnum:ka,ZodPromise:Gn,ZodEffects:jt,ZodTransformer:jt,ZodOptional:ar,ZodNullable:Wr,ZodDefault:La,ZodCatch:Pa,ZodNaN:gs,BRAND:uy,ZodBranded:co,ZodPipeline:Aa,ZodReadonly:Ea,custom:Zg,Schema:me,ZodSchema:me,late:dy,get ZodFirstPartyTypeKind(){return oe},coerce:Vy,any:vy,array:My,bigint:my,boolean:em,date:fy,discriminatedUnion:Ly,effect:qg,enum:Ny,function:By,instanceof:py,intersection:Py,lazy:Ry,literal:Iy,map:Oy,nan:gy,nativeEnum:$y,never:wy,null:yy,nullable:Gy,number:Jg,object:Ty,oboolean:jy,onumber:qy,optional:Dy,ostring:Qy,pipeline:Fy,preprocess:Hy,promise:_y,record:Ey,set:Uy,strictObject:Sy,string:Yg,symbol:hy,transformer:qg,tuple:Ay,undefined:by,union:ky,unknown:Cy,void:xy,NEVER:Wy,ZodIssueCode:G,quotelessJson:Gb,ZodError:St});var fe=class extends En{constructor(n,a){var c,p,g;let s=u.t(`octeract.data.${a}.name`),l=u.t(`octeract.data.${a}.description`);super(ee(O({},n),{name:s,description:l}));this.octeractsInvested=0;this.costFormula=n.costFormula,this.octeractsInvested=(c=n.octeractsInvested)!=null?c:0,this.qualityOfLife=(p=n.qualityOfLife)!=null?p:!1,this.cacheUpdates=(g=n.cacheUpdates)!=null?g:void 0}getCostTNL(){return this.level===this.maxLevel?0:this.costFormula(this.level,this.costPerLevel)}async buyLevel(n){let a=0,s=1,l=e.wowOcteracts;if(n.shiftKey){s=1e6;let c=Number(await Ee(`${u.t("octeract.buyLevel.buyPrompt",{n:d(e.wowOcteracts,0,!0)})}`));if(isNaN(c)||!isFinite(c)||!Number.isInteger(c))return P(u.t("general.validation.finite"));if(c===-1)l=e.wowOcteracts;else{if(c<=0)return P(u.t("octeract.buyLevel.cancelPurchase"));l=c}l=Math.min(e.wowOcteracts,l)}if(this.maxLevel>0&&(s=Math.min(s,this.maxLevel-this.level)),s===0)return P(u.t("octeract.buyLevel.alreadyMax"));for(;s>0;){let c=this.getCostTNL();if(e.wowOcteracts1)return P(`${u.t("octeract.buyLevel.multiBuy",{n:d(a)})}`);this.updateCaches(),this.updateUpgradeHTML()}toString(){let n=this.getCostTNL(),a=this.maxLevel===-1?"":`/${d(this.maxLevel,0,!0)}`,s=this.maxLevel===this.level,l=s?"plum":"white",c=this.freeLevels>0?` [+${d(this.freeLevels,1,!0)}]`:"";this.freeLevels>this.level&&(c=`${c}${u.t("general.softCapped")}`);let p=n<=e.wowOcteracts,g="";if(!s&&!p){let h=Kr();g=h>0?Vt((n-e.wowOcteracts)/h):`${u.t("general.infinity")}`}let m=s?` ${u.t("general.maxed")}`:p?` ${u.t("general.affordable")}`:` ${u.t("octeract.toString.becomeAffordable",{n:g})}`;return`${this.name} + ${u.t("general.spent")} Quarks: ${d(this.goldenQuarksInvested,0,!0)}`}updateUpgradeHTML(){i("testingMultiline").innerHTML=this.toString()}getCostTNL(){let n=1;return this.computeMaxLevel()>this.maxLevel&&this.level>=this.maxLevel&&(n*=Math.pow(4,this.level-this.maxLevel+1)),this.specialCostForm==="Exponential2"?this.costPerLevel*Math.sqrt(n)*Math.pow(2,this.level):this.specialCostForm==="Cubic"?this.costPerLevel*n*(Math.pow(this.level+1,3)-Math.pow(this.level,3)):this.specialCostForm==="Quadratic"?this.costPerLevel*n*(Math.pow(this.level+1,2)-Math.pow(this.level,2)):(n*=this.maxLevel===-1&&this.level>=100?this.level/50:1,n*=this.maxLevel===-1&&this.level>=400?this.level/100:1,this.computeMaxLevel()===this.level?0:Math.ceil(this.costPerLevel*(1+this.level)*n))}async buyLevel(n){let a=0,s=1,l=e.goldenQuarks;if(n.shiftKey){s=1e5;let c=Number(await Ee(u.t("singularity.goldenQuarks.spendPrompt",{gq:d(e.goldenQuarks,0,!0)})));if(isNaN(c)||!isFinite(c)||!Number.isInteger(c))return P(u.t("general.validation.finite"));if(c===-1)l=e.goldenQuarks;else{if(c<=0)return P(u.t("general.validation.zeroOrLess"));l=c}l=Math.min(e.goldenQuarks,l)}if(this.maxLevel>0&&(s=Math.min(s,this.computeMaxLevel()-this.level)),s===0)return P(u.t("singularity.goldenQuarks.hasUpgrade"));if(e.highestSingularityCount0;){let c=this.getCostTNL();if(e.goldenQuarks1&&P(u.t("singularity.goldenQuarks.multiBuyPurchased",{levels:d(a)})),this.updateUpgradeHTML(),this.updateCaches(),Nc(),_c(),Oe()}computeFreeLevelSoftcap(){let n=e.shopUpgrades.shopSingularityPotency>0?3.66:1;n+=.3/100*e.cubeUpgrades[75];let a=n*this.freeLevels;return Math.min(this.level,a)+Math.sqrt(Math.max(0,a-this.level))}computeMaxLevel(){if(this.canExceedCap){let n=this.maxLevel,a=[50,60,75,100,125,150,175,200,225,250];for(let s of a)if(e.highestSingularityCount>=s)n+=1;else break;return n+=+e.octeractUpgrades.octeractSingUpgradeCap.getEffect().bonus,n}else return this.maxLevel}actualTotalLevels(){if((e.singularityChallenges.noSingularityUpgrades.enabled||e.singularityChallenges.sadisticPrequel.enabled)&&!this.qualityOfLife||(e.singularityChallenges.limitedAscensions.enabled||e.singularityChallenges.limitedTime.enabled||e.singularityChallenges.sadisticPrequel.enabled)&&this.name===e.singularityUpgrades.platonicDelta.name)return 0;let n=this.computeFreeLevelSoftcap(),a=this.level+n,s=0;if(e.octeractUpgrades.octeractImprovedFree.getEffect().bonus){let l=.6;l+=+e.octeractUpgrades.octeractImprovedFree2.getEffect().bonus,l+=+e.octeractUpgrades.octeractImprovedFree3.getEffect().bonus,l+=+e.octeractUpgrades.octeractImprovedFree4.getEffect().bonus,s=Math.pow(this.level*n,l)}return Math.max(a,s)}getEffect(){return this.effect(this.actualTotalLevels())}updateCaches(){if(this.cacheUpdates!==void 0)for(let n of this.cacheUpdates)n()}refund(){e.goldenQuarks+=this.goldenQuarksInvested,this.level=0,this.goldenQuarksInvested=0}},F={goldenQuarks1:{maxLevel:15,costPerLevel:12,canExceedCap:!0,effect:t=>({bonus:1+.1*t,get desc(){return u.t("singularity.data.goldenQuarks1.effect",{n:d(10*t,0,!0)})}}),qualityOfLife:!0},goldenQuarks2:{maxLevel:75,costPerLevel:60,canExceedCap:!0,effect:t=>({bonus:t>250?1/Math.log2(t/62.5):1-Math.min(.5,t/500),get desc(){return u.t("singularity.data.goldenQuarks2.effect",{n:t>250?d(100-100/Math.log2(t/62.5),2,!0):d(Math.min(50,t/5),2,!0)})}}),qualityOfLife:!0},goldenQuarks3:{maxLevel:1e3,costPerLevel:1e3,effect:t=>({bonus:t*(t+1)/2,get desc(){return u.t("singularity.data.goldenQuarks3.effect",{n:d(t*(t+1)/2)})}})},starterPack:{maxLevel:1,costPerLevel:10,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.starterPack.effect${t>0?"Have":"HaveNot"}`)}})},wowPass:{maxLevel:1,costPerLevel:350,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.wowPass.effect${t>0?"Have":"HaveNot"}`)}}),qualityOfLife:!0},cookies:{maxLevel:1,costPerLevel:100,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.cookies.effect${t>0?"Have":"HaveNot"}`)}}),qualityOfLife:!0},cookies2:{maxLevel:1,costPerLevel:500,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.cookies2.effect${t>0?"Have":"HaveNot"}`)}}),qualityOfLife:!0},cookies3:{maxLevel:1,costPerLevel:24999,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.cookies3.effect${t>0?"Have":"HaveNot"}`)}}),qualityOfLife:!0},cookies4:{maxLevel:1,costPerLevel:499999,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.cookies4.effect${t>0?"Have":"HaveNot"}`)}}),qualityOfLife:!0},cookies5:{maxLevel:1,costPerLevel:166e13,minimumSingularity:209,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.cookies5.effect${t>0?"Have":"HaveNot"}`)}}),qualityOfLife:!0},ascensions:{maxLevel:-1,costPerLevel:5,effect:t=>({bonus:(1+2*t/100)*(1+Math.floor(t/10)/100),get desc(){return u.t("singularity.data.ascensions.effect",{n:d((100+2*t)*(1+Math.floor(t/10)/100)-100,1,!0)})}})},corruptionFourteen:{maxLevel:1,costPerLevel:1e3,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.corruptionFourteen.effect${t>0?"Have":"HaveNot"}`,{m:t>0?":)":":("})}})},corruptionFifteen:{maxLevel:1,costPerLevel:4e4,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.corruptionFifteen.effect${t>0?"Have":"HaveNot"}`,{m:t>0?":)":":("})}})},singOfferings1:{maxLevel:-1,costPerLevel:1,effect:t=>({bonus:1+.02*t,get desc(){return u.t("singularity.data.singOfferings1.effect",{n:d(2*t,0,!0)})}})},singOfferings2:{maxLevel:25,costPerLevel:25,canExceedCap:!0,effect:t=>({bonus:1+.08*t,get desc(){return u.t("singularity.data.singOfferings2.effect",{n:d(8*t,0,!0)})}})},singOfferings3:{maxLevel:40,costPerLevel:500,canExceedCap:!0,effect:t=>({bonus:1+.04*t,get desc(){return u.t("singularity.data.singOfferings3.effect",{n:d(4*t,0,!0)})}})},singObtainium1:{maxLevel:-1,costPerLevel:1,effect:t=>({bonus:1+.02*t,get desc(){return u.t("singularity.data.singObtainium1.effect",{n:d(2*t,0,!0)})}})},singObtainium2:{maxLevel:25,costPerLevel:25,canExceedCap:!0,effect:t=>({bonus:1+.08*t,get desc(){return u.t("singularity.data.singObtainium2.effect",{n:d(8*t,0,!0)})}})},singObtainium3:{maxLevel:40,costPerLevel:500,canExceedCap:!0,effect:t=>({bonus:1+.04*t,get desc(){return u.t("singularity.data.singObtainium3.effect",{n:d(4*t,0,!0)})}})},singCubes1:{maxLevel:-1,costPerLevel:1,effect:t=>({bonus:1+.01*t,get desc(){return u.t("singularity.data.singCubes1.effect",{n:d(1*t,0,!0)})}})},singCubes2:{maxLevel:25,costPerLevel:25,canExceedCap:!0,effect:t=>({bonus:1+.08*t,get desc(){return u.t("singularity.data.singCubes2.effect",{n:d(8*t,0,!0)})}})},singCubes3:{maxLevel:40,costPerLevel:500,canExceedCap:!0,effect:t=>({bonus:1+.04*t,get desc(){return u.t("singularity.data.singCubes3.effect",{n:d(4*t,0,!0)})}})},singCitadel:{maxLevel:-1,costPerLevel:5e5,minimumSingularity:100,effect:t=>({bonus:(1+.02*t)*(1+Math.floor(t/10)/100),get desc(){return u.t("singularity.data.singCubes2.effect",{n:d(100*((1+.02*t)*(1+Math.floor(t/10)/100)-1))})}})},singCitadel2:{maxLevel:100,costPerLevel:1e14,minimumSingularity:204,specialCostForm:"Quadratic",effect:t=>({bonus:(1+.02*t)*(1+Math.floor(t/10)/100),get desc(){return u.t("singularity.data.singCubes3.effect",{n:d(100*((1+.02*t)*(1+Math.floor(t/10)/100)-1))})}})},octeractUnlock:{maxLevel:1,costPerLevel:8888,minimumSingularity:8,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.octeractUnlock.effect${t>0?"Have":"HaveNot"}`)}}),qualityOfLife:!0},singOcteractPatreonBonus:{maxLevel:1,costPerLevel:9999,minimumSingularity:12,effect:t=>({bonus:t>0,get desc(){return u.t("singularity.data.singOcteractPatreonBonus.effect",{n:t})}})},offeringAutomatic:{maxLevel:-1,costPerLevel:1e14,minimumSingularity:222,effect:t=>({bonus:t,get desc(){return u.t("singularity.data.offeringAutomatic.effect",{n:t})}})},intermediatePack:{maxLevel:1,costPerLevel:1,minimumSingularity:4,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.intermediatePack.effect${t>0?"Have":"HaveNot"}`)}})},advancedPack:{maxLevel:1,costPerLevel:200,minimumSingularity:9,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.advancedPack.effect${t>0?"Have":"HaveNot"}`)}})},expertPack:{maxLevel:1,costPerLevel:800,minimumSingularity:16,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.expertPack.effect${t>0?"Have":"HaveNot"}`)}})},masterPack:{maxLevel:1,costPerLevel:3200,minimumSingularity:25,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.masterPack.effect${t>0?"Have":"HaveNot"}`)}})},divinePack:{maxLevel:1,costPerLevel:12800,minimumSingularity:36,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.divinePack.effect${t>0?"Have":"HaveNot"}`)}})},wowPass2:{maxLevel:1,costPerLevel:12500,minimumSingularity:9,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.wowPass2.effect${t>0?"Have":"HaveNot"}`)}}),qualityOfLife:!0},wowPass3:{maxLevel:1,costPerLevel:3e7-1,minimumSingularity:83,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.wowPass3.effect${t>0?"Have":"HaveNot"}`)}}),qualityOfLife:!0},potionBuff:{maxLevel:10,costPerLevel:999,minimumSingularity:4,canExceedCap:!0,effect:t=>({bonus:Math.max(1,10*Math.pow(t,2)),get desc(){return u.t("singularity.data.potionBuff.effect",{n:d(Math.max(1,10*Math.pow(t,2)),0,!0)})}})},potionBuff2:{maxLevel:10,costPerLevel:1e8,minimumSingularity:119,canExceedCap:!0,effect:t=>({bonus:Math.max(1,2*t),get desc(){return u.t("singularity.data.potionBuff2.effect",{n:d(Math.max(1,2*t),0,!0)})}})},potionBuff3:{maxLevel:10,costPerLevel:1e12,minimumSingularity:191,canExceedCap:!0,effect:t=>({bonus:Math.max(1,1+.5*t),get desc(){return u.t("singularity.data.potionBuff3.effect",{n:d(Math.max(1,1+.5*t),2,!0)})}})},singChallengeExtension:{maxLevel:4,costPerLevel:999,minimumSingularity:11,effect:t=>({bonus:t,get desc(){return u.t("singularity.data.singChallengeExtension.effect",{n:2*t,m:t})}})},singChallengeExtension2:{maxLevel:3,costPerLevel:29999,minimumSingularity:26,effect:t=>({bonus:t,get desc(){return u.t("singularity.data.singChallengeExtension2.effect",{n:2*t,m:t})}})},singChallengeExtension3:{maxLevel:3,costPerLevel:749999,minimumSingularity:51,effect:t=>({bonus:t,get desc(){return u.t("singularity.data.singChallengeExtension3.effect",{n:2*t,m:t})}})},singQuarkImprover1:{maxLevel:30,costPerLevel:1,minimumSingularity:173,canExceedCap:!0,specialCostForm:"Exponential2",effect:t=>({bonus:t/200,get desc(){return u.t("singularity.data.singQuarkImprover1.effect",{n:d(t/2,2,!0)})}}),qualityOfLife:!0},singQuarkHepteract:{maxLevel:1,costPerLevel:14999,minimumSingularity:5,effect:t=>({bonus:t/100,get desc(){return u.t("singularity.data.singQuarkHepteract.effect",{n:d(2*t,2,!0)})}}),qualityOfLife:!0},singQuarkHepteract2:{maxLevel:1,costPerLevel:449999,minimumSingularity:30,effect:t=>({bonus:t/100,get desc(){return u.t("singularity.data.singQuarkHepteract2.effect",{n:d(2*t,2,!0)})}}),qualityOfLife:!0},singQuarkHepteract3:{maxLevel:1,costPerLevel:1337e4,minimumSingularity:61,effect:t=>({bonus:t/100,get desc(){return u.t("singularity.data.singQuarkHepteract3.effect",{n:d(2*t,2,!0)})}}),qualityOfLife:!0},singOcteractGain:{maxLevel:-1,costPerLevel:2e4,minimumSingularity:36,effect:t=>({bonus:1+.0125*t,get desc(){return u.t("singularity.data.singOcteractGain.effect",{n:d(1.25*t,2,!0)})}})},singOcteractGain2:{maxLevel:25,costPerLevel:4e4,minimumSingularity:36,canExceedCap:!0,effect:t=>({bonus:1+.05*t,get desc(){return u.t("singularity.data.singOcteractGain2.effect",{n:d(5*t,0,!0)})}})},singOcteractGain3:{maxLevel:50,costPerLevel:25e4,minimumSingularity:55,canExceedCap:!0,effect:t=>({bonus:1+.025*t,get desc(){return u.t("singularity.data.singOcteractGain3.effect",{n:d(2.5*t,0,!0)})}})},singOcteractGain4:{maxLevel:100,costPerLevel:75e4,minimumSingularity:77,canExceedCap:!0,effect:t=>({bonus:1+.02*t,get desc(){return u.t("singularity.data.singOcteractGain4.effect",{n:d(2*t,0,!0)})}})},singOcteractGain5:{maxLevel:200,costPerLevel:7777777,minimumSingularity:100,canExceedCap:!0,effect:t=>({bonus:1+.01*t,get desc(){return u.t("singularity.data.singOcteractGain5.effect",{n:d(t,0,!0)})}})},platonicTau:{maxLevel:1,costPerLevel:1e5,minimumSingularity:29,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.platonicTau.effect${t?"Have":"HaveNot"}`)}}),qualityOfLife:!0},platonicAlpha:{maxLevel:1,costPerLevel:2e7,minimumSingularity:70,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.platonicAlpha.effect${t?"Have":"HaveNot"}`)}}),qualityOfLife:!0},platonicDelta:{maxLevel:1,costPerLevel:5e9,minimumSingularity:110,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.platonicDelta.effect${t?"Have":"HaveNot"}`)}})},platonicPhi:{maxLevel:1,costPerLevel:2e11,minimumSingularity:149,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.platonicPhi.effect${t?"Have":"HaveNot"}`)}}),qualityOfLife:!0},singFastForward:{maxLevel:1,costPerLevel:7e6-1,minimumSingularity:50,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.singFastForward.effect${t?"Have":"HaveNot"}`)}}),qualityOfLife:!0},singFastForward2:{maxLevel:1,costPerLevel:1e11-1,minimumSingularity:147,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.singFastForward2.effect${t?"Have":"HaveNot"}`)}}),qualityOfLife:!0},singAscensionSpeed:{maxLevel:1,costPerLevel:1e10,minimumSingularity:128,effect:t=>({bonus:t,get desc(){return u.t("singularity.data.singAscensionSpeed.effect",{n:d(1+.03*t,2,!0),m:d(1-.03*t,2,!0)})}})},singAscensionSpeed2:{maxLevel:1,costPerLevel:1e12,minimumSingularity:147,effect:t=>({bonus:t,get desc(){return u.t("singularity.data.singAscensionSpeed2.effect")}})},WIP:{maxLevel:100,costPerLevel:1e300,minimumSingularity:251,effect:t=>({bonus:t,get desc(){return u.t("singularity.data.WIP.effect")}})},ultimatePen:{maxLevel:1,costPerLevel:222e20,minimumSingularity:300,effect:t=>({bonus:t>0,get desc(){return u.t("singularity.data.ultimatePen.effect",{n:t?"":"NOT",m:t>0?" However, the pen just ran out of ink. How will you get more?":""})}})},oneMind:{maxLevel:1,costPerLevel:166e11,minimumSingularity:162,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.oneMind.effect${t?"Have":"HaveNot"}`)}}),qualityOfLife:!0},wowPass4:{maxLevel:1,costPerLevel:66666666666,minimumSingularity:147,effect:t=>({bonus:t>0,get desc(){return u.t(`singularity.data.wowPass4.effect${t?"Have":"HaveNot"}`)}}),qualityOfLife:!0},blueberries:{maxLevel:10,costPerLevel:1e16,minimumSingularity:215,effect:t=>({bonus:t,get desc(){return u.t("singularity.data.blueberries.effect",{n:t})}}),specialCostForm:"Exponential2",qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaBlueberries=ha().value},()=>{o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value}]},singAmbrosiaLuck:{maxLevel:-1,costPerLevel:1e9,minimumSingularity:187,effect:t=>({bonus:4*t,get desc(){return u.t("singularity.data.singAmbrosiaLuck.effect",{n:d(4*t)})}}),specialCostForm:"Exponential2",qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaLuck=Ge().value}]},singAmbrosiaLuck2:{maxLevel:30,costPerLevel:4e5,minimumSingularity:50,effect:t=>({bonus:2*t,get desc(){return u.t("singularity.data.singAmbrosiaLuck2.effect",{n:d(2*t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaLuck=Ge().value}]},singAmbrosiaLuck3:{maxLevel:30,costPerLevel:2e8,minimumSingularity:119,effect:t=>({bonus:3*t,get desc(){return u.t("singularity.data.singAmbrosiaLuck3.effect",{n:d(3*t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaLuck=Ge().value}]},singAmbrosiaLuck4:{maxLevel:50,costPerLevel:1e19,minimumSingularity:256,effect:t=>({bonus:5*t,get desc(){return u.t("singularity.data.singAmbrosiaLuck4.effect",{n:d(5*t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaLuck=Ge().value}]},singAmbrosiaGeneration:{maxLevel:-1,costPerLevel:1e9,minimumSingularity:187,effect:t=>({bonus:1+t/100,get desc(){return u.t("singularity.data.singAmbrosiaGeneration.effect",{n:d(t)})}}),specialCostForm:"Exponential2",qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value}]},singAmbrosiaGeneration2:{maxLevel:20,costPerLevel:8e5,minimumSingularity:50,effect:t=>({bonus:1+t/100,get desc(){return u.t("singularity.data.singAmbrosiaGeneration2.effect",{n:d(t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value}]},singAmbrosiaGeneration3:{maxLevel:35,costPerLevel:3e8,minimumSingularity:119,effect:t=>({bonus:1+t/100,get desc(){return u.t("singularity.data.singAmbrosiaGeneration3.effect",{n:d(t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value}]},singAmbrosiaGeneration4:{maxLevel:50,costPerLevel:1e19,minimumSingularity:256,effect:t=>({bonus:1+2*t/100,get desc(){return u.t("singularity.data.singAmbrosiaGeneration4.effect",{n:d(2*t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value}]}};var $c=[{name:()=>u.t("singularity.perks.welcometoSingularity.name"),levels:[1],description:()=>u.t("singularity.perks.welcometoSingularity.default"),ID:"welcometoSingularity"},{name:()=>u.t("singularity.perks.unlimitedGrowth.name"),levels:[1],description:()=>u.t("singularity.perks.unlimitedGrowth.default",{amount:d(10*e.singularityCount)}),ID:"unlimitedGrowth"},{name:()=>u.t("singularity.perks.goldenCoins.name"),levels:[1],description:()=>u.t("singularity.perks.goldenCoins.default",{amount:d(Math.pow(e.goldenQuarks+1,1.5)*Math.pow(e.highestSingularityCount+1,2),2)}),ID:"goldenCoins"},{name:()=>u.t("singularity.perks.xyz.name"),levels:[1,20,200],description:(t,r)=>t>=r[2]?u.t("singularity.perks.xyz.hasLevel2"):t>=r[1]?u.t("singularity.perks.xyz.hasLevel1"):u.t("singularity.perks.xyz.default"),ID:"xyz"},{name:()=>u.t("singularity.perks.generousOrbs.name"),levels:[1,2,5,10,15,20,25,30,35],description:(t,r)=>{let n={8:700,7:500,6:415,5:360,4:315,3:280,2:255,1:230};for(let a=8;a>0;a--)if(t>=r[a])return u.t("singularity.perks.generousOrbs.default",{amount:n[a]});return u.t("singularity.perks.generousOrbs.default",{amount:"215"})},ID:"generousOrbs"},{name:()=>u.t("singularity.perks.researchDummies.name"),levels:[1,11],description:(t,r)=>t>=r[1]?u.t("singularity.perks.researchDummies.hasLevel1"):u.t("singularity.perks.researchDummies.default"),ID:"researchDummies"},{name:()=>u.t("singularity.perks.antGodsCornucopia.name"),levels:[1,30,70,100],description:(t,r)=>t>=r[3]?u.t("singularity.perks.antGodsCornucopia.hasLevel3"):t>=r[2]?u.t("singularity.perks.antGodsCornucopia.hasLevel2"):t>=r[1]?u.t("singularity.perks.antGodsCornucopia.hasLevel1"):u.t("singularity.perks.antGodsCornucopia.default"),ID:"antGodsCornucopia"},{name:()=>u.t("singularity.perks.sweepomatic.name"),levels:[2,101],description:(t,r)=>t>=r[1]?u.t("singularity.perks.sweepomatic.hasLevel1"):u.t("singularity.perks.sweepomatic.default"),ID:"sweepomatic"},{name:()=>u.t("singularity.perks.superStart.name"),levels:[2,3,4,7,15],description:(t,r)=>t>=r[4]?u.t("singularity.perks.superStart.hasLevel4"):t>=r[3]?u.t("singularity.perks.superStart.hasLevel3"):t>=r[2]?u.t("singularity.perks.superStart.hasLevel2"):t>=r[1]?u.t("singularity.perks.superStart.hasLevel1"):u.t("singularity.perks.superStart.default"),ID:"superStart"},{name:()=>u.t("singularity.perks.notSoChallenging.name"),levels:[4,7,10,15,20],description:(t,r)=>t>=r[4]?u.t("singularity.perks.notSoChallenging.hasLevel4"):t>=r[3]?u.t("singularity.perks.notSoChallenging.hasLevel3"):t>=r[2]?u.t("singularity.perks.notSoChallenging.hasLevel2"):t>=r[1]?u.t("singularity.perks.notSoChallenging.hasLevel1"):u.t("singularity.perks.notSoChallenging.default"),ID:"notSoChallenging"},{name:()=>u.t("singularity.perks.automationUpgrades.name"),levels:[5,10,15,25,30,100],description:(t,r)=>t>=r[5]?u.t("singularity.perks.automationUpgrades.hasLevel5"):t>=r[4]?u.t("singularity.perks.automationUpgrades.hasLevel4"):t>=r[3]?u.t("singularity.perks.automationUpgrades.hasLevel3"):t>=r[2]?u.t("singularity.perks.automationUpgrades.hasLevel2"):t>=r[1]?u.t("singularity.perks.automationUpgrades.hasLevel1"):u.t("singularity.perks.automationUpgrades.default"),ID:"automationUpgrades"},{name:()=>u.t("singularity.perks.evenMoreQuarks.name"),levels:[5,7,10,20,35,50,65,80,90,100,121,144,150,160,166,169,170,175,180,190,196,200,201,202,203,204,205,210,212,214,216,218,220,225,250,255,260,261,262],description:(t,r)=>{for(let n=r.length-1;n>=0;n--)if(t>=r[n])return u.t("singularity.perks.evenMoreQuarks.default",{stack:n+1,inc:d(100*(Math.pow(1.05,n+1)-1),2)});return u.t("singularity.perks.evenMoreQuarks.bug")},ID:"evenMoreQuarks"},{name:()=>u.t("singularity.perks.shopSpecialOffer.name"),levels:[5,20,51],description:(t,r)=>t>=r[2]?u.t("singularity.perks.shopSpecialOffer.hasLevel2"):t>=r[1]?u.t("singularity.perks.shopSpecialOffer.hasLevel1"):u.t("singularity.perks.shopSpecialOffer.default"),ID:"shopSpecialOffer"},{name:()=>u.t("singularity.perks.potionAutogenerator.name"),levels:[6],description:()=>u.t("singularity.perks.potionAutogenerator.default"),ID:"potionAutogenerator"},{name:()=>u.t("singularity.perks.respecBeGone.name"),levels:[7],description:()=>u.t("singularity.perks.respecBeGone.default"),ID:"respecBeGone"},{name:()=>u.t("singularity.perks.forTheLoveOfTheAntGod.name"),levels:[10,15,25],description:(t,r)=>t>=r[2]?u.t("singularity.perks.forTheLoveOfTheAntGod.hasLevel2"):t>=r[1]?u.t("singularity.perks.forTheLoveOfTheAntGod.hasLevel1"):u.t("singularity.perks.forTheLoveOfTheAntGod.default"),ID:"forTheLoveOfTheAntGod"},{name:()=>u.t("singularity.perks.itAllAddsUp.name"),levels:[10,16,25,36,49,64,81,100,121,144,169,196,225,235,240],description:(t,r)=>{for(let n=r.length-1;n>=0;n--)if(t>=r[n])return u.t("singularity.perks.itAllAddsUp.default",{div:d(1+(n+1)/5,2,!0)});return u.t("singularity.perks.evenMoreQuarks.bug")},ID:"itAllAddsUp"},{name:()=>u.t("singularity.perks.automagicalRunes.name"),levels:[15,30,40,50],description:(t,r)=>t>=r[3]?u.t("singularity.perks.automagicalRunes.hasLevel3"):t>=r[2]?u.t("singularity.perks.automagicalRunes.hasLevel2"):t>=r[1]?u.t("singularity.perks.automagicalRunes.hasLevel1"):u.t("singularity.perks.automagicalRunes.default"),ID:"automagicalRunes"},{name:()=>u.t("singularity.perks.derpSmithsCornucopia.name"),levels:[18,38,58,78,88,98,118,148,178,188,198,208,218,228,238,248],description:(t,r)=>{for(let n=r.length-1;n>=0;n--)if(t>=r[n])return u.t("singularity.perks.derpSmithsCornucopia.default",{counter:n+1});return u.t("singularity.perks.evenMoreQuarks.bug")},ID:"derpSmithsCornucopia"},{name:()=>u.t("singularity.perks.eternalAscensions.name"),levels:[25],description:()=>u.t("singularity.perks.eternalAscensions.default"),ID:"eternalAscensions"},{name:()=>u.t("singularity.perks.exaltedAchievements.name"),levels:[25],description:()=>u.t("singularity.perks.exaltedAchievements.default"),ID:"exaltedAchievements"},{name:()=>u.t("singularity.perks.coolQOLCubes.name"),levels:[25,35],description:(t,r)=>t>=r[1]?u.t("singularity.perks.coolQOLCubes.hasLevel1"):u.t("singularity.perks.coolQOLCubes.default"),ID:"coolQOLCubes"},{name:()=>u.t("singularity.perks.irishAnt.name"),levels:[35,42,49,56,63,70,77,135,142,149,156,163,170,177],description:(t,r)=>{for(let n=r.length-1;n>=0;n--)if(t>=r[n])return n>=7?u.t("singularity.perks.irishAnt.default",{i:6*(n-6)+35}):u.t("singularity.perks.irishAnt.default",{i:5*(n+1)});return u.t("singularity.perks.evenMoreQuarks.bug")},ID:"irishAnt"},{name:()=>u.t("singularity.perks.overclocked.name"),levels:[50,60,75,100,125,150,175,200,225,250],description:(t,r)=>{for(let n=r.length-1;n>=0;n--)if(t>=r[n])return u.t("singularity.perks.overclocked.default",{i:n+1});return u.t("singularity.perks.evenMoreQuarks.bug")},ID:"overclocked"},{name:()=>u.t("singularity.perks.wowCubeAutomatedShipping.name"),levels:[50,150],description:(t,r)=>t>=r[1]?u.t("singularity.perks.wowCubeAutomatedShipping.hasLevel1"):u.t("singularity.perks.wowCubeAutomatedShipping.default"),ID:"wowCubeAutomatedShipping"},{name:()=>u.t("singularity.perks.congealedblueberries.name"),levels:[64,128,192,256,270],description(t,r){for(let n=r.length-1;n>=0;n--)if(t>=r[n])return u.t("singularity.perks.congealedblueberries.default",{i:n+1});return u.t("singularity.perks.evenMoreQuarks.bug")},ID:"congealedblueberries"},{name:()=>u.t("singularity.perks.goldenRevolution.name"),levels:[100],description:()=>u.t("singularity.perks.goldenRevolution.default",{current:d(Math.min(100,.4*e.singularityCount),1)}),ID:"goldenRevolution"},{name:()=>u.t("singularity.perks.goldenRevolutionII.name"),levels:[100],description:()=>u.t("singularity.perks.goldenRevolutionII.default",{current:d(Math.min(50,.2*e.singularityCount),1)}),ID:"goldenRevolution2"},{name:()=>u.t("singularity.perks.goldenRevolutionIII.name"),levels:[100],description:()=>u.t("singularity.perks.goldenRevolutionIII.default",{current:d(Math.min(500,2*e.singularityCount))}),ID:"goldenRevolution3"},{name:()=>u.t("singularity.perks.platonicClones.name"),levels:[100,200],description:(t,r)=>t>=r[1]?u.t("singularity.perks.platonicClones.hasLevel1"):u.t("singularity.perks.platonicClones.default"),ID:"platonicClones"},{name:()=>u.t("singularity.perks.irishAnt2.name"),levels:[100,150,200,225,250,255,260,265,269,272],description:(t,r)=>{for(let n=r.length-1;n>=0;n--)if(t>=r[n])return u.t("singularity.perks.irishAnt2.default",{percent:n+1});return u.t("singularity.perks.evenMoreQuarks.bug")},ID:"irishAnt2"},{name:()=>u.t("singularity.perks.platSigma.name"),levels:[125,200],description:(t,r)=>{let n=0;for(let a of r)t>=a&&(n+=.125);return u.t("singularity.perks.platSigma.default",{counter:n,current:d(Math.min(60,n*e.singularityCount),1)})},ID:"platSigma"},{name:()=>u.t("singularity.perks.primalPower.name"),levels:[131,269],description:(t,r)=>t>=r[1]?u.t("singularity.perks.primalPower.hasLevel1"):u.t("singularity.perks.primalPower.default"),ID:"primalPower"},{name:()=>u.t("singularity.perks.midasMilleniumAgedGold.name"),levels:[150],description:()=>u.t("singularity.perks.midasMilleniumAgedGold.default"),ID:"midasMilleniumAgedGold"},{name:()=>u.t("singularity.perks.goldenRevolution4.name"),levels:[160,173,185,194,204,210,219,229,240,249],description:(t,r)=>{let a=0;for(let s of r)t>=s&&(a+=1);return u.t("singularity.perks.goldenRevolution4.default",{gq:d(1e6/a,0,!0)})},ID:"goldenRevolution4"},{name:()=>u.t("singularity.perks.octeractMetagenesis.name"),levels:[200,205],description:(t,r)=>t>=r[1]?u.t("singularity.perks.octeractMetagenesis.hasLevel1"):u.t("singularity.perks.octeractMetagenesis.default"),ID:"octeractMetagenesis"},{name:()=>u.t("singularity.perks.immaculateAlchemy.name"),levels:[200,208,221],description:(t,r)=>t>=r[2]?u.t("singularity.perks.immaculateAlchemy.hasLevel2"):t>=r[1]?u.t("singularity.perks.immaculateAlchemy.hasLevel1"):u.t("singularity.perks.immaculateAlchemy.default"),ID:"immaculateAlchemy"},{name:()=>u.t("singularity.perks.skrauQ.name"),levels:[200],description:()=>{let t=d(Math.pow((e.singularityCount-179)/20,2),4);return u.t("singularity.perks.skrauQ.default",{amt:t})},ID:"skrauQ"},{name:()=>u.t("singularity.perks.permanentBenefaction.name"),levels:[244],description:()=>u.t("singularity.perks.permanentBenefaction.default"),ID:"permanentBenefaction"}],_c=()=>{let t=e.highestSingularityCount;i("singularityPerksHeader").innerHTML=u.t("singularity.perks.header",{ord:eo(t)}),i("singularityPerksText").innerHTML=u.t("singularity.perks.levelInfo",{level:"#",singularity:"#"}),i("singularityPerksDesc").innerHTML=u.t("singularity.perks.description"),Gb(t)},Dc=(t,r)=>{for(let n=t.levels.length-1;n>=0;n--)if(r>=t.levels[n])return{level:n+1,singularity:t.levels[n],next:n{let r=[],n=null,a=Number.POSITIVE_INFINITY;for(let c of $c){let p=Dc(c,t);p.level>0?(r.push({name:c.name(),lastUpgraded:p.singularity,acquired:c.levels[0],htmlID:c.ID}),p.next&&(a=Math.min(a,p.next))):(n===null&&(n=p.singularity),i(c.ID).style.display="none")}r.sort((c,p)=>c.acquired===p.acquired&&c.lastUpgraded===p.lastUpgraded?0:c.lastUpgraded>p.lastUpgraded||c.lastUpgraded===p.lastUpgraded&&c.acquired>p.acquired?-1:1);for(let c of r){let p=fa(),g=i(c.htmlID);g.style.display="",i("singularityPerksGrid").append(g),t-c.lastUpgraded<=p?g.classList.replace("oldPerk","newPerk"):g.classList.replace("newPerk","oldPerk")}let s=i("singualrityUnlockNext");n?(s.style.display="",s.innerHTML=u.t("singularity.perks.unlockedIn",{sing:n})):s.style.display="none";let l=i("singualrityImproveNext");a{let t=0;return t+=+e.singularityUpgrades.singFastForward.getEffect().bonus,t+=+e.singularityUpgrades.singFastForward2.getEffect().bonus,t+=+e.octeractUpgrades.octeractFastForward.getEffect().bonus,t=Math.max(0,Math.min(t,200-e.singularityCount-1)),e.insideSingularityChallenge?0:e.highestSingularityCount!==e.singularityCount&&e.singularityCount+t+1>=e.highestSingularityCount?Math.max(0,Math.min(t,e.highestSingularityCount-e.singularityCount-1)):t},Gc=()=>{let r=1e4;r*=1-.1*Math.min(1,e.achievementPoints/1e4),r*=1-.3*e.cubeUpgrades[60]/1e4,r*=+e.singularityUpgrades.goldenQuarks2.getEffect().bonus,r*=+e.octeractUpgrades.octeractGQCostReduce.getEffect().bonus,r*=e.highestSingularityCount>=100?1-.5*e.highestSingularityCount/250:1;let n=1;return e.highestSingularityCount>=200&&(n=3),e.highestSingularityCount>=208&&(n=5),e.highestSingularityCount>=221&&(n=8),r/=n,r=1e4-r,{cost:1e4-r,costReduction:r}};async function Tg(){let t=Gc(),r=Math.floor(+e.worlds/t.cost),n=null;if(r===0)return P(u.t("singularity.goldenQuarks.poor"));let a=await Ee(u.t("singularity.goldenQuarks.buyPrompt",{cost:d(t.cost,0,!0),discount:d(t.costReduction,0,!0),max:d(r,0,!0)}));if(a===null)return P(u.t("general.cancelled"));if(n=Number(a),Number.isNaN(n)||!Number.isFinite(n))return P(u.t("general.validation.finite"));if(n<=0&&n!==-1)return P(u.t("general.validation.zeroOrLess"));if(n>r)return P(u.t("general.validation.goldenQuarksTooMany"));if(!Number.isInteger(n))return P(u.t("general.validation.fraction"));let s;return n===-1?(s=r*t.cost,e.worlds.sub(s),e.goldenQuarks+=r):(s=n*t.cost,e.worlds.sub(s),e.goldenQuarks+=n),P(u.t("singularity.goldenQuarks.transaction",{spent:d(r,0,!0),cost:d(s,0,!0)}))}var ro=(t=e.singularityCount)=>{let r=t;return r*=Math.min(4.75,.75*t/10+1),e.insideSingularityChallenge&&e.singularityChallenges.noOcteracts.enabled&&(r*=Math.pow(e.singularityChallenges.noOcteracts.completions+1,3)),t>10&&(r*=1.5,r*=Math.min(4,1.25*t/10-.25)),t>25&&(r*=2.5,r*=Math.min(6,1.5*t/25-.5)),t>36&&(r*=4,r*=Math.min(5,t/18-1),r*=Math.pow(1.1,Math.min(t-36,64))),t>50&&(r*=5,r*=Math.min(8,2*t/50-1),r*=Math.pow(1.1,Math.min(t-50,50))),t>100&&(r*=2,r*=t/25,r*=Math.pow(1.1,t-100)),t>150&&(r*=2,r*=Math.pow(1.05,t-150)),t>200&&(r*=1.5,r*=Math.pow(1.275,t-200)),t>215&&(r*=1.25,r*=Math.pow(1.2,t-215)),t>230&&(r*=2),t>269&&(r*=3,r*=Math.pow(3,t-269)),r},Hb=(t=e.singularityCount)=>{let r=[11,26,37,51,101,151,201,216,230,270],n=0;n+=e.shopUpgrades.shopSingularityPenaltyDebuff;for(let a of r)if(a+n>t)return a+n;return-1},Le=(t,r=e.singularityCount)=>{if(r===0||e.runelevels[6]>0)return 1;let n=r;if(n-=e.shopUpgrades.shopSingularityPenaltyDebuff,n<1)return 1;let a=ro(n);if(t==="Offering")return Math.sqrt(Math.min(a,ro(150))+1);if(t==="Global Speed")return 1+Math.sqrt(a)/4;if(t==="Obtainium")return Math.sqrt(Math.min(a,ro(150))+1);if(t==="Researches")return 1+Math.sqrt(a)/2;if(t==="Ascension Speed")return n<150?1+Math.sqrt(a)/5:1+Math.pow(a,.75)/1e4;if(t==="Cubes"){let s=n>100?Math.pow(1.02,n-100):1;return n<150?1+Math.sqrt(a)*s/4:1+Math.pow(a,.75)*s/1e3}else return t==="Platonic Costs"?n>36?1+Math.pow(a,3/10)/12:1:t==="Hepteract Costs"?n>50?1+Math.pow(a,11/50)/25:1:Math.cbrt(a+1)};var Sg=(t,r=1,n=0)=>(r=Math.min(o.researchMaxLevels[t]-e.researches[t],r),sr(e.researches[t],o.researchBaseCosts[t]*Le("Researches"),e.researchPoints,n,r)),Fb=(t,r)=>{if(qt()&&r&&e.autoResearchMode==="cheapest"){for(e.autoResearch=o.researchOrderByCost[e.roombaResearchIndex],Fc(e.autoResearch)&&(i(`res${e.autoResearch||1}`).classList.remove("researchRoomba"),e.roombaResearchIndex=Math.min(o.researchOrderByCost.length-1,e.roombaResearchIndex+1));!Hc(e.autoResearch)&&e.autoResearch<200&&e.autoResearch>=76;)e.roombaResearchIndex+=1,e.autoResearch=o.researchOrderByCost[e.roombaResearchIndex];if(Hc(e.autoResearch)){let n=Math.max(o.researchOrderByCost[e.roombaResearchIndex],1),a=i(`res${n}`);e.researches[e.autoResearch]=o.researchMaxLevels[t]?Lt(`res${e.autoResearch}`,["researchMaxed"],["researchPurchased","researchUnpurchased"]):e.researches[t]>=1?Lt(`res${e.autoResearch}`,["researchPurchased"],["researchUnpurchased","researchMaxed"]):Lt(`res${e.autoResearch}`,["researchUnpurchased"],["researchPurchased","researchMaxed"]);return}else return},qt=()=>e.cubeUpgrades[9]===1||e.highestSingularityCount>10,Fr=(t,r=!1,n=0,a=!1)=>{var p,g,m,h;let s=e.researchBuyMaxToggle||r||a?1e5:1,l=Sg(t,s,n),c=e.researchPoints>=l.cost;return c&&Hc(t)&&!Fc(t)&&(e.researches[t]=l.levelCanBuy,e.researchPoints-=l.cost,Fc(t)&&i(`res${e.autoResearch||1}`).classList.remove("researchRoomba"),o.researchfiller2=`Level: ${e.researches[t]}/${o.researchMaxLevels[t]}`,Ii(t,r,n),(p=e.unlocks).rrow1||(p.rrow1=!0),(g=e.unlocks).rrow2||(g.rrow2=!0),(m=e.unlocks).rrow3||(m.rrow3=!0),(h=e.unlocks).rrow4||(h.rrow4=!0),t>=47&&t<=50&&Oe(),(t>=66&&t<=70||t===105)&&Lr(),He(),It()),e.autoResearchToggle&&Fb(t,r),c},kg=(t=e)=>{let r=t.ascensionCount>0?140:125,n=t.challengecompletions[11]>0?15:0,a=t.challengecompletions[12]>0?15:0,s=t.challengecompletions[13]>0?15:0,l=t.challengecompletions[14]>0?15:0;return r+n+a+s+l},Hc=t=>{let r=(s=>l=>s+=l)(0),n=[3*25,5,20,10,15,15,15,15,15,15].map(r),a=[50,124,127,134,141,183,197,204,211,218];for(let s=0;s0;if(t<=n[s])return e.achievements[a[s]]>0}return!1},Fc=t=>o.researchMaxLevels[t]<=e.researches[t],Ii=(t,r=!1,n=0)=>{let a=e.researchBuyMaxToggle||r?1e5:1,s=u.t(`researches.descriptions.${t}`),l=`res${t}`;e.toggles[38]&&e.singularityCount>0&&Fr(t,!1,t===200?.01:0,!0);let c=Sg(t,a,n),p=u.t("researches.cost",{x:d(c.cost,0,!1),y:d(c.levelCanBuy-e.researches[t],0,!0)});e.researches[t]===o.researchMaxLevels[t]?(i("researchcost").style.color="Gold",i("researchinfo3").style.color="plum",Lt(l,["researchMaxed"],["researchAvailable","researchPurchased","researchPurchasedAvailable"]),p+=u.t("researches.maxed")):(i("researchcost").style.color="limegreen",i("researchinfo3").style.color="white",e.researches[t]>0?Lt(l,["researchPurchased","researchPurchasedAvailable"],["researchAvailable","researchMaxed","researchUnpurchased"]):Lt(l,["researchAvailable"],["researchPurchased","researchMaxed","researchUnpurchased"])),e.researchPoints{e.researches[t]>o.researchMaxLevels[t]&&(e.researchPoints+=(e.researches[t]-o.researchMaxLevels[t])*o.researchBaseCosts[t],e.researches[t]=o.researchMaxLevels[t]);let r=`res${t}`;e.researches[t]>.5&&e.researches[t].5&&e.researches[t]>=o.researchMaxLevels[t]?Lt(r,["researchMaxed"],["researchUnpurchased","researchPurchased"]):Lt(r,["researchUnpurchased"],["researchPurchased","researchMaxed"])};var us=(t,r)=>{t===1&&e.prestigePoints.gte(1e12)&&!e.unlocks.generation&&(e.unlocks.generation=!0);let n=100+t,a="transcendPoints";n<=110&&n>=106?a="coins":n<=115&&(a="prestigePoints");let s=f.pow(10,o.upgradeCosts[n]),l=Math.max(e.upgrades[101],e.upgrades[102],e.upgrades[103],e.upgrades[104],e.upgrades[105]);e.upgrades[n]===0&&e[a].gte(s)&&(l===0&&n>=102&&n<=105&&R(n-31),e[a]=e[a].sub(s),e.upgrades[n]=1,jt(n,r))},Lg=(t,r)=>{let n=t+80,a="reincarnationPoints";n<=87?a="prestigePoints":n<=93&&(a="transcendPoints");let s=f.pow(10,o.upgradeCosts[n]);e.upgrades[n]===0&&e[a].gte(s)&&(e[a]=e[a].sub(s),e.upgrades[n]=1,jt(n,r))},Pg=()=>{if(e.upgrades[90]>.5&&e.shoptoggles.generators){for(let t=1;t<6;t++)e.upgrades[100+t]===0&&e.prestigePoints.gte(f.pow(10,o.upgradeCosts[100+t]))&&us(t,!0);for(let t=6;t<11;t++)e.upgrades[100+t]===0&&e.coins.gte(f.pow(10,o.upgradeCosts[100+t]))&&us(t,!0);for(let t=11;t<16;t++)e.upgrades[100+t]===0&&e.prestigePoints.gte(f.pow(10,o.upgradeCosts[100+t]))&&us(t,!0);for(let t=16;t<21;t++)e.upgrades[100+t]===0&&e.transcendPoints.gte(f.pow(10,o.upgradeCosts[100+t]))&&us(t,!0)}if(e.upgrades[91]>.5){for(let t=1;t<21;t++)e.upgrades[t]===0&&e.coins.gte(f.pow(10,o.upgradeCosts[t]))&&e.shoptoggles.coin&&or("coins",t,!0);for(let t=121;t<=125;t++)e.upgrades[t]===0&&e.coins.gte(f.pow(10,o.upgradeCosts[t]))&&e.shoptoggles.coin&&e.cubeUpgrades[19]>0&&or("coins",t,!0)}if(e.upgrades[92]>.5){for(let t=21;t<38;t++)e.upgrades[t]===0&&e.prestigePoints.gte(f.pow(10,o.upgradeCosts[t]))&&e.shoptoggles.prestige&&or("prestigePoints",t,!0);e.upgrades[38]===0&&e.prestigePoints.gte(f.pow(10,5e4))&&e.shoptoggles.prestige&&e.achievements[120]===1&&or("prestigePoints",38,!0),e.upgrades[39]===0&&e.prestigePoints.gte(f.pow(10,1e5))&&e.shoptoggles.prestige&&e.achievements[127]===1&&or("prestigePoints",39,!0),e.upgrades[40]===0&&e.prestigePoints.gte(f.pow(10,2e5))&&e.shoptoggles.prestige&&e.achievements[134]===1&&or("prestigePoints",40,!0)}if(e.upgrades[99]>.5)for(let t=41;t<61;t++)e.upgrades[t]===0&&e.transcendPoints.gte(f.pow(10,o.upgradeCosts[t]))&&e.shoptoggles.transcend&&or("transcendPoints",t,!0);if(e.cubeUpgrades[8]>0)for(let t=61;t<=80;t++)e.upgrades[t]===0&&e.reincarnationPoints.gte(f.pow(10,o.upgradeCosts[t]))&&e.shoptoggles.reincarnate&&or("reincarnationPoints",t,!0);if(e.highestSingularityCount>=25)for(let t=81;t<=100;t++)e.upgrades[t]===0&&ba(t,!0)};var Qc={3:()=>({max:d(100*(.12+.88*e.upgrades[122]+.001*e.researches[129]*Math.log(e.commonFragments+1)/Math.log(4)),2,!0)}),4:()=>({max:d(10+.05*e.researches[129]*Math.log(e.commonFragments+1)/Math.log(4)+20*Xe()/400*o.effectiveRuneSpiritPower[3])})},qc={1:()=>({level:d(5+e.achievements[270]+.1*e.platonicUpgrades[18],1,!0)}),2:()=>({max:d(10+e.achievements[270]+e.shopUpgrades.constantEX+100*(o.challenge15Rewards.exponent-1)+.3*e.platonicUpgrades[18],2,!0)})},jc=[()=>d((o.totalCoinOwned+1)*Math.min(1e30,Math.pow(1.008,o.totalCoinOwned)),2),()=>d((o.totalCoinOwned+1)*Math.min(1e30,Math.pow(1.008,o.totalCoinOwned)),2),()=>d((o.totalCoinOwned+1)*Math.min(1e30,Math.pow(1.008,o.totalCoinOwned)),2),()=>d((o.totalCoinOwned+1)*Math.min(1e30,Math.pow(1.008,o.totalCoinOwned)),2),()=>d((o.totalCoinOwned+1)*Math.min(1e30,Math.pow(1.008,o.totalCoinOwned)),2),()=>d((o.totalCoinOwned+1)*Math.min(1e30,Math.pow(1.008,o.totalCoinOwned)),2),()=>Math.min(4,1+Math.floor(f.log(e.fifthOwnedCoin+1,10))),()=>Math.floor(e.multiplierBought/7),()=>Math.floor(e.acceleratorBought/10),()=>d(f.pow(2,Math.min(50,e.secondOwnedCoin/15)),2),()=>d(f.pow(1.02,o.freeAccelerator),2),()=>d(f.min(1e4,f.pow(1.01,e.prestigeCount)),2),()=>d(f.min(1e50,f.pow(e.firstGeneratedMythos.add(e.firstOwnedMythos).add(1),4/3).times(1e10)),2),()=>d(f.pow(1.15,o.freeAccelerator),2),()=>d(f.pow(1.15,o.freeAccelerator),2),()=>d(f.pow(o.acceleratorEffect,1/3),2),()=>null,()=>d(f.min(1e125,e.transcendShards.add(1))),()=>d(f.min(1e200,e.transcendPoints.times(1e30).add(1))),()=>d(f.pow((o.totalCoinOwned+1)*Math.min(1e30,Math.pow(1.008,o.totalCoinOwned)),10),2),()=>({x:d(Math.floor(1+1/101*o.freeMultiplier)),y:d(Math.floor(5+1/101*o.freeAccelerator))}),()=>({x:d(Math.floor(1+1/101*o.freeMultiplier)),y:d(Math.floor(4+1/101*o.freeAccelerator))}),()=>({x:d(Math.floor(1+1/101*o.freeMultiplier)),y:d(Math.floor(3+1/101*o.freeAccelerator))}),()=>({x:d(Math.floor(1+1/101*o.freeMultiplier)),y:d(Math.floor(2+1/101*o.freeAccelerator))}),()=>({x:d(Math.floor(1+1/101*o.freeMultiplier)),y:d(Math.floor(1+1/101*o.freeAccelerator))}),()=>null,()=>d(Math.min(250,Math.floor(f.log(e.coins.add(1),1e3)))+Math.max(0,Math.min(1750,Math.floor(f.log(e.coins.add(1),1e15))-50))),()=>d(Math.min(1e3,Math.floor((e.firstOwnedCoin+e.secondOwnedCoin+e.thirdOwnedCoin+e.fourthOwnedCoin+e.fifthOwnedCoin)/160))),()=>d(Math.floor(Math.min(2e3,(e.firstOwnedCoin+e.secondOwnedCoin+e.thirdOwnedCoin+e.fourthOwnedCoin+e.fifthOwnedCoin)/80))),()=>d(Math.min(75,Math.floor(f.log(e.coins.add(1),1e10)))+Math.min(925,Math.floor(f.log(e.coins.add(1),1e30)))),()=>d(Math.floor(o.totalCoinOwned/2e3)),()=>d(Math.min(500,Math.floor(f.log(e.prestigePoints.add(1),1e25)))),()=>d(o.totalAcceleratorBoost),()=>d(Math.floor(3/103*o.freeMultiplier)),()=>d(Math.floor(2/102*o.freeMultiplier)),()=>d(f.min("1e5000",f.pow(e.prestigePoints,1/500)),2),()=>d(f.pow(f.log(e.prestigePoints.add(10),10),2),2),()=>null,()=>null,()=>null,()=>d(f.min(1e30,f.pow(e.transcendPoints.add(1),1/2))),()=>d(f.min(1e50,f.pow(e.prestigePoints.add(1),1/50).dividedBy(2.5).add(1)),2),()=>d(f.min(1e30,f.pow(1.01,e.transcendCount)),2),()=>d(f.min(1e6,f.pow(1.01,e.transcendCount)),2),()=>d(Math.min(2500,Math.floor(f.log(e.transcendShards.add(1),10)))),()=>null,()=>d(Math.pow(1.05,e.achievementPoints)*(e.achievementPoints+1),2),()=>d(Math.pow(Math.min(1e25,o.totalMultiplier*o.totalAccelerator)/1e3+1,8)),()=>d(Math.min(50,Math.floor(f.log(e.transcendPoints.add(1),1e10)))),()=>null,()=>d(Math.pow(o.totalAcceleratorBoost,2),2),()=>d(f.pow(o.globalMythosMultiplier,.025),2),()=>d(f.min("1e1250",f.pow(o.acceleratorEffect,1/125)),2),()=>d(f.min("1e2000",f.pow(o.multiplierEffect,1/180)),2),()=>d(f.pow("1e1000",Math.min(1e3,o.buildingPower-1)),2),()=>null,()=>null,()=>null,()=>null,()=>null,()=>null,()=>Math.floor(1/5*ae(e.challengecompletions)),()=>d(f.min("1e6000",f.pow(e.reincarnationPoints.add(1),6))),()=>d(f.pow(e.reincarnationPoints.add(1),2)),()=>null,()=>null,()=>d(f.pow(1.03,e.firstOwnedParticles+e.secondOwnedParticles+e.thirdOwnedParticles+e.fourthOwnedParticles+e.fifthOwnedParticles),2),()=>d(Math.min(2500,Math.floor(1/1e3*f.log(o.taxdivisor,10)))),()=>{let t=f.pow(f.log(o.reincarnationPointGain.add(10),10),.5),r=f.pow(f.log(o.reincarnationPointGain.add(10),10),.5);return{x:d(Math.min(10,new f(t).toNumber()),2),y:d(Math.min(3,new f(r).toNumber()),2)}},()=>d(1/3*Math.log(e.maxobtainium+1)/Math.log(10),2,!0),()=>null,()=>Math.min(50,1+2*e.challengecompletions[6]+2*e.challengecompletions[7]+2*e.challengecompletions[8]+2*e.challengecompletions[9]+2*e.challengecompletions[10]),()=>null,()=>d(1+4*Math.min(1,Math.pow(e.maxofferings/1e5,.5)),2),()=>d(1+2*Math.min(1,Math.pow(e.maxobtainium/3e7,.5)),2),()=>null,()=>d(f.pow(1.004+4/1e5*e.researches[96],e.firstOwnedAnts+e.secondOwnedAnts+e.thirdOwnedAnts+e.fourthOwnedAnts+e.fifthOwnedAnts+e.sixthOwnedAnts+e.seventhOwnedAnts+e.eighthOwnedAnts),3),()=>d(1+.005*Math.pow(Math.log(e.maxofferings+1)/Math.log(10),2),2,!0),()=>null,()=>null,...Array.from({length:39},()=>()=>null),()=>null,()=>null,()=>null,()=>null,()=>d(.333*e.challengecompletions[10],0),()=>d(.333*e.challengecompletions[10],0)],Qb=t=>{var s;let r=(s=jc[t-1])==null?void 0:s.call(jc),n=typeof r,a=i("upgradeeffect");t>=81&&t<=119?a.textContent=u.t("upgrades.effects.81"):r==null?a.textContent=u.t(`upgrades.effects.${t}`):n==="string"||n==="number"?a.textContent=u.t(`upgrades.effects.${t}`,{x:r}):a.textContent=u.t(`upgrades.effects.${t}`,r)},Og=t=>{let r=u.t(`upgrades.descriptions.${t}`),n=e.upgrades[t]>.5?" BOUGHT!":"",a=i("upgradedescription");a.textContent=r+n,a.style.color=e.upgrades[t]>.5?"gold":"white",e.toggles[9]&&ba(t,!1);let s="",l="";(t<=20&&t>=1||t<=110&&t>=106||t<=125&&t>=121)&&(s="Coins",l="yellow"),(t<=40&&t>=21||t<=105&&t>=101||t<=115&&t>=111||t<=87&&t>=81)&&(s="Diamonds",l="cyan"),(t<=60&&t>=41||t<=120&&t>=116||t<=93&&t>=88)&&(s="Mythos",l="plum"),(t<=80&&t>=61||t<=100&&t>=94)&&(s="Particles",l="limegreen"),i("upgradecost").textContent=`Cost: ${d(f.pow(10,o.upgradeCosts[t]))} ${s}`,i("upgradecost").style.color=l,Qb(t)},ba=(t,r)=>{if(e.upgrades[t]!==0||t<=40&&t>=21&&!e.unlocks.prestige||t<=60&&t>=41&&!e.unlocks.transcend||t<=80&&t>=61&&!e.unlocks.reincarnate||t<=120&&t>=81&&!e.unlocks.prestige||i(`upg${t}`).style.display==="none")return;let n;t<=20&&t>=1&&(n="coins"),t<=40&&t>=21&&(n="prestigePoints"),t<=60&&t>=41&&(n="transcendPoints"),t<=80&&t>=61&&(n="reincarnationPoints"),t<=87&&t>=81&&(n="prestigePoints"),t<=93&&t>=88&&(n="transcendPoints"),t<=100&&t>=94&&(n="reincarnationPoints"),n&&t<=80&&t>=1&&or(n,t,r),n&&t<=100&&t>=81&&Lg(t-80,r),t<=120&&t>=101&&us(t-100,r),t<=125&&t>=121&&or("coins",t,r)},no=(t,r)=>{let n=0,a=0;if(t===1){n=121,a=125;for(let s=1;s<=20;s++)ba(s,r)}t===2&&(n=21,a=40),t===3&&(n=41,a=60),t===4&&(n=101,a=120),t===5&&(n=81,a=100),t===6&&(n=61,a=80);for(let s=n;s<=a;s++)ba(s,r)},Eg={1:()=>({x:d(f.min(f.pow(10,50+2*e.crystalUpgrades[0]),f.pow(1.05,e.achievementPoints*e.crystalUpgrades[0])),2,!0)}),2:()=>({x:d(f.min(f.pow(10,100+5*e.crystalUpgrades[1]),f.pow(f.log(e.coins.add(1),10),e.crystalUpgrades[1]/3)),2,!0)}),3:()=>({x:d(f.pow(1+Math.min(.12+.88*e.upgrades[122]+.001*e.researches[129]*Math.log(e.commonFragments+1)/Math.log(4),.001*e.crystalUpgrades[2]),e.firstOwnedDiamonds+e.secondOwnedDiamonds+e.thirdOwnedDiamonds+e.fourthOwnedDiamonds+e.fifthOwnedDiamonds),2,!0)}),4:()=>({x:d(Math.min(10+.05*e.researches[129]*Math.log(e.commonFragments+1)/Math.log(4)+20*Xe()/400*o.effectiveRuneSpiritPower[3],.05*e.crystalUpgrades[3]),2,!0)}),5:()=>({x:d(f.pow(1.01,(e.challengecompletions[1]+e.challengecompletions[2]+e.challengecompletions[3]+e.challengecompletions[4]+e.challengecompletions[5])*e.crystalUpgrades[4]),2,!0)})},qb=t=>{var r;return u.t(`upgrades.crystalUpgrades.${t}`,(r=Qc[t])==null?void 0:r.call(Qc))},jb=t=>u.t("buildings.crystalUpgrades.currentEffect",{effect:t in Eg?u.t(`upgrades.crystalEffects.${t}`,Eg[t]()):""}),Ni=t=>{let r=e.crystalUpgrades[t-1],n=(e.upgrades[73]>.5&&e.currentChallenge.reincarnation!==0?10:0)+Math.floor(o.rune3level*o.effectiveLevelMult/16)*100/100,a=f.pow(10,o.crystalUpgradesCost[t-1]+o.crystalUpgradeCostIncrement[t-1]*Math.floor(Math.pow(e.crystalUpgrades[t-1]+.5-n,2)/2));i("crystalupgradedescription").textContent=qb(t),i("crystalupgradeslevel1").innerHTML=u.t("buildings.crystalUpgrades.currentLevel",{amount:d(r,0,!0)}),i("crystalupgradescost1").innerHTML=u.t("buildings.crystalUpgrades.cost",{amount:d(a)}),i("crystalupgradeseffect1").innerHTML=jb(t)},jt=(t,r)=>{let n=i(`upg${t}`);e.upgrades[t]>.5?n.style.backgroundColor="green":n.style.backgroundColor="";let a=u.t(`upgrades.descriptions.${t}`),s=e.upgrades[t]>.5?" BOUGHT!":"";e.upgrades[t]>.5&&(r||(i("upgradedescription").textContent=a+s,i("upgradedescription").style.color="gold")),r||Oe()},Wc=()=>{let t=e.ascendBuilding1.owned+e.ascendBuilding2.owned+e.ascendBuilding3.owned+e.ascendBuilding4.owned+e.ascendBuilding5.owned;return t>1e5?Math.pow(1e5,.5)*Math.pow(t,.5):t},Vc={1:()=>({x:d(f.pow(1.05+.01*e.achievements[270]+.001*e.platonicUpgrades[18],e.constantUpgrades[1]),2,!0)}),2:()=>({x:d(f.pow(1+.001*Math.min(100+10*e.achievements[270]+10*e.shopUpgrades.constantEX+3*e.platonicUpgrades[18]+1e3*(o.challenge15Rewards.exponent-1),e.constantUpgrades[2]),Wc()),2,!0)}),3:()=>({x:d(1+.02*e.constantUpgrades[3],2,!0)}),4:()=>({x:d(1+.04*e.constantUpgrades[4],2,!0)}),5:()=>({x:d(f.pow(1+.1*f.log(e.ascendShards.add(1),10),e.constantUpgrades[5]),2,!0)}),6:()=>({x:d(2*e.constantUpgrades[6])}),7:()=>({x:d(7*e.constantUpgrades[7]),y:d(3*e.constantUpgrades[7])}),8:()=>({x:d(1+1/10*e.constantUpgrades[8],2,!0)}),9:()=>({x:d(1+.01*Math.log(e.talismanShards+1)/Math.log(4)*Math.min(1,e.constantUpgrades[9]),4,!0)}),10:()=>({x:d(1+.01*f.log(e.ascendShards.add(1),4)*Math.min(1,e.constantUpgrades[10]),4,!0)})},Vb=t=>{var r;return u.t(`upgrades.constantUpgrades.${t}`,(r=qc[t])==null?void 0:r.call(qc))},Wb=t=>{var r;return u.t(`upgrades.constantEffects.${t}`,(r=Vc[t])==null?void 0:r.call(Vc))},ao=t=>{let r,n;return t>=9?e.constantUpgrades[t]>=1?r=0:r=Math.min(1,Math.max(0,Math.floor(1+f.log(f.max(.01,e.ascendShards),10)-Math.log(o.constUpgradeCosts[t])/Math.log(10)))):r=Math.max(0,Math.floor(1+f.log(f.max(.01,e.ascendShards),10)-Math.log(o.constUpgradeCosts[t])/Math.log(10))),r>e.constantUpgrades[t]?n=f.pow(10,r-1).times(o.constUpgradeCosts[t]):n=t>=9&&e.constantUpgrades[t]>=1?new f("0"):f.pow(10,e.constantUpgrades[t]).times(o.constUpgradeCosts[t]),[Math.max(1,r-e.constantUpgrades[t]),n]},Kc=t=>{let[r,n]=ao(t);i("constUpgradeDescription").textContent=Vb(t),t>=9?i("constUpgradeLevel2").textContent=`${d(Math.min(1,e.constantUpgrades[t]))}/1`:i("constUpgradeLevel2").textContent=d(e.constantUpgrades[t]),i("constUpgradeCost2").textContent=`${d(n)} [+${d(r)} LVL]`,i("constUpgradeEffect2").textContent=Wb(t)},so=(t,r=!1)=>{let[n,a]=ao(t);(t<=8||t>=9&&e.constantUpgrades[t]<1)&&e.ascendShards.gte(a)&&(e.constantUpgrades[t]+=n,e.researches[175]===0&&(e.ascendShards=e.ascendShards.sub(a)),r||Kc(t)),It(),He()};var Kb=[4,5,6,7,8,9,10,20,26,27,48,49],zb=[41,42,43,44,45,46,47,48,49,50,61,71,72,73,74,75,124,130,135,145,150,175,190],zc=[200,200,200,500,500,500,500,500,2e3,4e4,5e3,1e3,1e4,2e4,4e4,1e4,4e3,1e4,5e4,12500,5e4,3e4,3e4,4e4,2e5,4e5,1e5,177777,1e5,1e6,5e5,3e5,2e6,4e6,2e6,4e6,1e6,2e7,5e7,1e7,5e6,1e7,1e8,4e7,2e7,4e7,5e7,1e8,5e8,1e8,1,1e4,1e8,1e12,1e16,10,1e5,1e9,1e13,1e17,100,1e6,1e10,1e14,1e18,1e20,1e30,1e40,1e50,1e60,1,1,1e8,1e16,1e30,1e100,1e100,1e200,1e250,1e300],Xb=[3,10,5,1,1,1,1,1,1,1,3,10,1,10,10,10,5,1,1,1,5,10,1,10,10,10,1,1,5,1,5,1,1,10,10,10,10,1,1,10,5,10,10,10,10,20,20,1,1,1e5,1,900,100,900,900,20,1,1,400,1e4,100,1,1,1,1,1,1,1e3,1,1e5,1,1,5,1,30,2,25,30,1,1],$i=(t,r)=>{let n=t===50?.01:0,a=t>50,s=ya(t),l=r?1e5:1,c=e.cubeUpgrades[t];l=Math.min(s-c,l);let p=t<=50?Le("Cube Upgrades"):1,g;return a?(l=r?s:Math.min(s,c+1),g=Bg(c,zc[t-1],Number(e.wowCubes),l)):g=sr(c,zc[t-1]*p,Number(e.wowCubes),n,l),g},ya=t=>{let r=Xb[t-1];return e.cubeUpgrades[57]>0&&t<50&&t%10===1&&(r+=1),r},Xc=(t,r=e.cubeUpgradesBuyMaxToggle)=>{let n=$i(t,r),a=i("cubeUpgradeName"),s=i("cubeUpgradeDescription"),l=i("cubeUpgradeCost"),c=i("cubeUpgradeLevel"),p=ya(t);a.textContent=u.t(`cubes.upgradeNames.${t}`),s.innerHTML=u.t(`cubes.upgradeDescriptions.${t}`),l.textContent=u.t("cubes.cubeMetadata.cost",{value1:d(n.cost,0,!0),value2:d(n.levelCanBuy-e.cubeUpgrades[t],0,!0)}),l.style.color="var(--green-text-color)",c.textContent=u.t("cubes.cubeMetadata.level",{value1:d(e.cubeUpgrades[t],0,!0),value2:d(p,0,!0)}),c.style.color="white",Number(e.wowCubes){let r=i(`cubeUpg${t}`),n=ya(t),a=e.cubeUpgrades[t];a>n&&(e.wowCubes.add((a-n)*zc[t-1]),e.cubeUpgrades[t]=n),e.cubeUpgrades[t]===0&&(r.style.backgroundColor=""),a>0&&a{for(let t of Kb){let r=ya(t);e.cubeUpgrades[t]=r,va(t)}Qt();for(let t of zb)e.researches[t]=o.researchMaxLevels[t],cs(t)},Yc=(t,r=e.cubeUpgradesBuyMaxToggle,n=!1)=>{if(t>50&&t<=55&&!e.singularityUpgrades.cookies.getEffect().bonus||t>55&&t<=60&&!e.singularityUpgrades.cookies2.getEffect().bonus||t>60&&t<=65&&!e.singularityUpgrades.cookies3.getEffect().bonus||t>65&&t<=70&&!e.singularityUpgrades.cookies4.getEffect().bonus||t>70&&!e.singularityUpgrades.cookies5.getEffect().bonus)return;let a=$i(t,r),s=ya(t);if(Number(e.wowCubes)>=a.cost&&e.cubeUpgrades[t]0)for(let l=94;l<=98;l++)e.upgrades[l]=1,jt(l,!0);if(t===5&&e.cubeUpgrades[5]>0&&(e.upgrades[99]=1,jt(99,!0)),t===6&&e.cubeUpgrades[6]>0&&(e.upgrades[100]=1,jt(100,!0)),t===51&&e.cubeUpgrades[51]>0&&Zc(),t===57&&e.cubeUpgrades[57]>0)for(let l=1;l{if(e.autoCubeUpgradesToggle&&(e.highestSingularityCount>=50&&e.insideSingularityChallenge||e.highestSingularityCount>=150)){let t=[];for(let r=1;r0){let r=!1;t.sort((n,a)=>n[1]-a[1]);for(let n of t){let a=ya(n[0]),s=$i(n[0],!0);Number(e.wowCubes)>=s.cost&&e.cubeUpgrades[n[0]]this.UNLOCKED?this:(this.UNLOCKED=!0,e.highestSingularityCount<5?P(u.t("hepteracts.unlockedCraft",{x:r})):this);this.computeActualCap=()=>{let r=1;return r*=e.singularityChallenges.limitedAscensions.rewards.hepteractCap?2:1,this.CAP*r};this.craft=async(r=!1)=>{var m;let n=null,a=this.computeActualCap(),s=Le("Hepteract Costs");if(!this.UNLOCKED)return P(u.t("hepteracts.notUnlocked"));if(a-this.BAL<=0&&e.toggles[35])return P(u.t("hepteracts.reachedCapacity",{x:d(a,0,!0)}));(isNaN(e.wowAbyssals)||!isFinite(e.wowAbyssals)||e.wowAbyssals<0)&&(e.wowAbyssals=0);let l=Math.floor(e.wowAbyssals/(this.HEPTERACT_CONVERSION*s)*1/(1-this.DISCOUNT)),c=[];for(let h in this.OTHER_CONVERSIONS)h==="worlds"?c.push(Math.floor(e[h]/((m=this.OTHER_CONVERSIONS[h])!=null?m:1))*1/(1-this.DISCOUNT)):c.push(Math.floor(e[h]/(s*this.OTHER_CONVERSIONS[h]))*1/(1-this.DISCOUNT));let p=Math.min(...c),g=Math.min(p,l,a,a-this.BAL);if(isNaN(g)||!isFinite(g))return P(u.t("hepteracts.executionFailed"));if(r)n=a;else{let h=await Ee(u.t("hepteracts.craft",{x:d(g,0,!0),y:Math.floor(g/a*1e4)/100}));if(h===null)return e.toggles[35]?P(u.t("hepteracts.cancelled")):void 0;n=Number(h)}if(isNaN(n)||!isFinite(n)||!Number.isInteger(n))return P(u.t("general.validation.finite"));if(n<=0)return P(u.t("general.validation.zeroOrLess"));if(g=Math.min(p,l,n,a-this.BAL),r&&e.toggles[35]&&!await ye(u.t("hepteracts.craftMax",{x:d(g,0,!0),y:Math.floor(g/a*1e4)/100})))return P(u.t("hepteracts.cancelled"));this.BAL=Math.min(a,this.BAL+g),e.wowAbyssals-=g*this.HEPTERACT_CONVERSION*s,e.wowAbyssals<0&&(e.wowAbyssals=0);for(let h of Object.keys(this.OTHER_CONVERSIONS))typeof e[h]=="number"&&(e[h]-=g*s*this.OTHER_CONVERSIONS[h]),e[h]<0?e[h]=0:e[h]instanceof Dn?e[h].sub(g*s*this.OTHER_CONVERSIONS[h]):h==="worlds"&&e.worlds.sub(g*this.OTHER_CONVERSIONS[h]);if(e.toggles[35])return r?P(u.t("hepteracts.craftedHepteractsMax",{x:d(g,0,!0)})):P(u.t("hepteracts.craftedHepteracts",{x:d(g,0,!0)}))};this.expand=async()=>{let n=this.BAL,a=this.computeActualCap(),s=this.CAP;if(!this.UNLOCKED)return P(u.t("hepteracts.notUnlocked"));if(this.BAL1-Number.EPSILON?(this.DISCOUNT=1-Number.EPSILON,this):(this.DISCOUNT+=r,this)}toggleAutomatic(r){let n=i(`${this.HTML_STRING}HepteractAuto`);return this.AUTO=r!=null?r:!this.AUTO,n.textContent=this.AUTO?u.t("general.autoOnColon"):u.t("general.autoOffColon"),n.style.border=`2px solid ${this.AUTO?"green":"red"}`,this}autoCraft(r){let a=Le("Hepteract Costs"),s=this.computeActualCap(),l=Math.floor(r/(a*this.HEPTERACT_CONVERSION)*1/(1-this.DISCOUNT)),c=[];for(let b in this.OTHER_CONVERSIONS)b==="worlds"&&c.push(Math.floor(e[b]/this.OTHER_CONVERSIONS[b])*1/(1-this.DISCOUNT));let p=Math.min(...c),g=Math.min(p,l),m=0,h=Math.min(s-this.BAL,g);for(this.BAL+=h,m+=h,g-=h;this.BAL>=s&&g>=this.CAP;)this.BAL-=this.CAP,this.CAP*=2,s*=2,h=Math.min(s-this.BAL,g),this.BAL+=h,m+=h,g-=h;for(let b in this.OTHER_CONVERSIONS)b==="worlds"&&e.worlds.sub(m*this.OTHER_CONVERSIONS[b]);return e.wowAbyssals-=m*a*this.HEPTERACT_CONVERSION,e.wowAbyssals<0&&(e.wowAbyssals=0),this}get amount(){return this.BAL}get capacity(){return this.CAP}get discount(){return this.DISCOUNT}},_i={chronos:{LIMIT:1e3,DR:1/6},hyperrealism:{LIMIT:1e3,DR:.33},quark:{LIMIT:1e3,DR:.5},challenge:{LIMIT:1e3,DR:1/6},abyss:{LIMIT:1,DR:0},accelerator:{LIMIT:1e3,DR:.2},acceleratorBoost:{LIMIT:1e3,DR:.2},multiplier:{LIMIT:1e3,DR:.2}},Ig=t=>new Pr(t),Ve=t=>{let r=Math.min(e.hepteractCrafts[t].BAL,_i[t].LIMIT),n=0;if(t==="chronos"&&(n+=1/750*e.platonicUpgrades[19]),t==="quark"){n+=+e.singularityUpgrades.singQuarkHepteract.getEffect().bonus,n+=+e.singularityUpgrades.singQuarkHepteract2.getEffect().bonus,n+=+e.singularityUpgrades.singQuarkHepteract3.getEffect().bonus,n+=+e.octeractUpgrades.octeractImprovedQuarkHept.getEffect().bonus,n+=e.shopUpgrades.improveQuarkHept/100,n+=e.shopUpgrades.improveQuarkHept2/100,n+=e.shopUpgrades.improveQuarkHept3/100,n+=e.shopUpgrades.improveQuarkHept4/100,n+=e.shopUpgrades.improveQuarkHept5/5e3;let a=e.hepteractCrafts[t].BAL;if(1e3_i[t].LIMIT&&(r*=Math.pow(e.hepteractCrafts[t].BAL/_i[t].LIMIT,_i[t].DR+n)),r},sn=t=>{i("hepteractUnlockedText").style.display="block",i("hepteractCurrentEffectText").style.display="block",i("hepteractBalanceText").style.display="block",i("powderDayWarpText").style.display="none",i("hepteractCostText").style.display="block";let r=i("hepteractUnlockedText"),n=i("hepteractEffectText"),a=i("hepteractCurrentEffectText"),s=i("hepteractBalanceText"),l=i("hepteractCostText"),c=i("hepteractBonusCapacity"),p=Le("Hepteract Costs"),g=e.hepteractCrafts[t].computeActualCap()/e.hepteractCrafts[t].CAP;c.textContent=e.hepteractCrafts[t].computeActualCap()/e.hepteractCrafts[t].CAP>1?`Hepteract capacities are currently multiplied by ${g}. Expansions cost what they would if this multiplier were 1.`:"";let m,h;switch(t){case"chronos":m={x:d(Ve("chronos")*6/100,2,!0)},h=d(1e115*p,0,!1);break;case"hyperrealism":m={x:d(Ve("hyperrealism")*6/100,2,!0)},h=d(1e80*p,0,!0);break;case"quark":m={x:d(Ve("quark")*5/100,2,!0)},h="100";break;case"challenge":m={x:d(Ve("challenge")*5/100,2,!0)},h={y:d(1e11*p),z:d(1e22*p)};break;case"abyss":h=d(69*p);break;case"accelerator":m={x:d(2e3*Ve("accelerator"),2,!0),y:d(Ve("accelerator")*3/100,2,!0)},h=d(1e14*p);break;case"acceleratorBoost":m={x:d(Ve("acceleratorBoost")/10,2,!0)},h=d(1e10*p);break;case"multiplier":m={x:d(1e3*Ve("multiplier"),2,!0),y:d(Ve("multiplier")*3/100,2,!0)},h=d(1e130*p);break}n.textContent=u.t(`wowCubes.hepteractForge.descriptions.${t}.effect`),a.textContent=u.t(`wowCubes.hepteractForge.descriptions.${t}.currentEffect`,m),s.textContent=u.t("wowCubes.hepteractForge.inventory",{x:d(e.hepteractCrafts[t].BAL,0,!0),y:d(e.hepteractCrafts[t].computeActualCap(),0,!0)});let b=typeof h=="string"?{y:h}:h;l.textContent=u.t(`wowCubes.hepteractForge.descriptions.${t}.oneCost`,O({x:d(e.hepteractCrafts[t].HEPTERACT_CONVERSION*p,0,!0)},b)),r.textContent=e.hepteractCrafts[t].UNLOCKED?u.t("wowCubes.hepteractForge.unlocked"):u.t("wowCubes.hepteractForge.locked")},Ng=()=>{i("hepteractUnlockedText").style.display="none",i("powderDayWarpText").style.display="none",i("hepteractCostText").style.display="block",i("hepteractCurrentEffectText").textContent=u.t("hepteracts.orbEffect",{x:d(100*(-1+_n()),2,!0)}),i("hepteractBalanceText").textContent=u.t("hepteracts.orbsPurchasedToday",{x:d(e.overfluxOrbs,0,!0)}),i("hepteractEffectText").textContent=u.t("hepteracts.amalgamate"),i("hepteractCostText").textContent=u.t("hepteracts.cost250k")},Jc=async t=>{let r=Math.floor(e.wowAbyssals/25e4),n;if(t){if(e.toggles[35]&&!await ye(u.t("hepteracts.craftMaxOrbs",{x:d(r,0,!0)})))return P(u.t("hepteracts.cancelled"));n=r}else{let g=await Ee(u.t("hepteracts.hepteractInput",{x:d(r,0,!0)}));if(g===null)return e.toggles[35]?P(u.t("hepteracts.cancelled")):void 0;if(n=Number(g),isNaN(n)||!isFinite(n)||!Number.isInteger(n)||n<=0)return P(u.t("general.validation.invalidNumber"))}let a=Math.min(r,Math.floor(n)),s=_n();e.overfluxOrbs+=a,e.wowAbyssals-=25e4*a;let l=_n();e.wowAbyssals<0&&(e.wowAbyssals=0);let c=e.shopUpgrades.powderAuto*Ar().mult*a/100;e.overfluxPowder+=c;let p=c>0?u.t("hepteracts.gainedPowder",{x:d(c,2,!0)}):"";if(e.toggles[35])return P(u.t("hepteracts.purchasedOrbs",{x:d(a,0,!0),y:d(100*(l-s),2,!0),z:p}))},Gi=(t,r=!1)=>{let n=i("hepteractToQuarkTradeAuto");r||(e.overfluxOrbsAutoBuy=t!=null?t:!e.overfluxOrbsAutoBuy),n.textContent=e.overfluxOrbsAutoBuy?u.t("general.autoOnColon"):u.t("general.autoOffColon"),n.style.border=`2px solid ${e.overfluxOrbsAutoBuy?"green":"red"}`},$g=()=>{let t;e.platonicUpgrades[16]>0?t=u.t("hepteracts.allCubeGainExtended",{x:d(100*(Di()-1),2,!0),y:d(100*(ds()-1),3,!0),z:d(2*e.platonicUpgrades[16]*Math.min(1,e.overfluxPowder/1e5),2,!0),a:d(f.pow(e.overfluxPowder+1,10*e.platonicUpgrades[16]))}):t=u.t("hepteracts.allCubeGain",{x:d(100*(Di()-1),2,!0),y:d(100*(ds()-1),3,!0)}),i("hepteractUnlockedText").style.display="none",i("hepteractCurrentEffectText").textContent=u.t("hepteracts.powderEffect",{x:t}),i("hepteractBalanceText").textContent=u.t("hepteracts.powderLumps",{x:d(e.overfluxPowder,2,!0)}),i("hepteractEffectText").textContent=u.t("hepteracts.expiredOrbs",{x:d(1/Ar().mult,1,!0)}),i("hepteractCostText").style.display="none",i("powderDayWarpText").style.display="block",i("powderDayWarpText").textContent=u.t("hepteracts.dayWarpsRemaining",{x:e.dailyPowderResetUses})},eu=async t=>{if(t)if(e.autoWarpCheck){if(await ye(u.t("hepteracts.useAllWarpsPrompt")))return i("warpAuto").textContent=u.t("general.autoOffColon"),i("warpAuto").style.border="2px solid red",e.autoWarpCheck=!1,e.dailyPowderResetUses=0,P(u.t("hepteracts.machineCooldown"));if(e.toggles[35])return P(u.t("hepteracts.machineDidNotConsume"))}else{if(await ye(u.t("hepteracts.boostQuarksPrompt")))return i("warpAuto").textContent=u.t("general.autoOnColon"),i("warpAuto").style.border="2px solid green",e.autoWarpCheck=!0,e.dailyPowderResetUses===0?P(u.t("hepteracts.machineOverdrive")):P(u.t("hepteracts.machineInOverdrive"));if(e.toggles[35])return P(u.t("hepteracts.machineUsualContinue"))}else{if(e.autoWarpCheck)return P(u.t("hepteracts.warpImpossible"));if(e.dailyPowderResetUses<=0)return P(u.t("hepteracts.machineCooldown"));if(e.overfluxPowder<25)return P(u.t("hepteracts.atleastPowder"));if(await ye(u.t("hepteracts.stumbleMachine"))){if(e.overfluxPowder-=25,e.dailyPowderResetUses-=1,oo(),e.toggles[35])return P(u.t("hepteracts.useMachine"))}else if(e.toggles[35])return P(u.t("hepteracts.walkAwayMachine"))}},_g=()=>{let t=[];for(let r of Object.keys(e.hepteractCrafts)){let n=r;e.hepteractCrafts[n].AUTO&&e.hepteractCrafts[n].UNLOCKED&&t.push(e.hepteractCrafts[n])}return t},Dg=new Pr({BASE_CAP:1e3,HEPTERACT_CONVERSION:1e4,OTHER_CONVERSIONS:{researchPoints:1e115},HTML_STRING:"chronos",UNLOCKED:!0}),Gg=new Pr({BASE_CAP:1e3,HEPTERACT_CONVERSION:1e4,OTHER_CONVERSIONS:{runeshards:1e80},HTML_STRING:"hyperrealism",UNLOCKED:!0}),Hg=new Pr({BASE_CAP:1e3,HEPTERACT_CONVERSION:1e4,OTHER_CONVERSIONS:{worlds:100},HTML_STRING:"quark",UNLOCKED:!0}),Fg=new Pr({BASE_CAP:1e3,HEPTERACT_CONVERSION:5e4,OTHER_CONVERSIONS:{wowPlatonicCubes:1e11,wowCubes:1e22},HTML_STRING:"challenge"}),Qg=new Pr({BASE_CAP:1,HEPTERACT_CONVERSION:1e8,OTHER_CONVERSIONS:{wowCubes:69},HTML_STRING:"abyss"}),qg=new Pr({BASE_CAP:1e3,HEPTERACT_CONVERSION:1e5,OTHER_CONVERSIONS:{wowTesseracts:1e14},HTML_STRING:"accelerator"}),jg=new Pr({BASE_CAP:1e3,HEPTERACT_CONVERSION:2e5,OTHER_CONVERSIONS:{wowHypercubes:1e10},HTML_STRING:"acceleratorBoost"}),Vg=new Pr({BASE_CAP:1e3,HEPTERACT_CONVERSION:3e5,OTHER_CONVERSIONS:{researchPoints:1e130},HTML_STRING:"multiplier"});var Zb=["+0.0090% Cubes per Corruption level per level!","+0.018% Tesseracts per Corruption level per level!","+0.054% Hypercubes per Corruption level per level!","Gain +2.4% Platonic Cubes per level! It is that simple.","C10 Exponent: 1.035 --> 1.0375, Constant tax exponent +0.10, 2x faster Constant production, +20% Quarks, +10 Reincarnation Challenge Cap, +5 Ascension Challenge Cap, 2x Obtainium and Offerings, ^1.10 coin gain in C15, as well +1 Corruption Cap Level!","Multiplies Viscosity exponent by (1 + level/30), capacity of ^1 on Multipliers and Accelerators.","Raises speed below 1x to the power of ^(1 - level/30).","Divides Hyperchallenged by (1 + 0.4 * level), with a minimum 1x Challenge requirement multiplier!","Raise Obtainium to the power of (1+(0.09*log10(Obtainium owned))) and add another x2.5 multiplier (Uncorruptable), up until 1e100 Obtainium!","C10 Exponent: 1.0375 --> 1.04, Constant tax exponent +0.20, 10x faster Constant production, +25% Quarks, +10 Reincarnation Challenge Cap, +5 Ascension Challenge Cap, 3.5x Obtainium and Offerings, 2x All Cubes, ^1.25 ant exponent in C15, +1 Corruption Cap Level again!","With this upgrade, you will gain diamonds equal to particle gain on Reincarnation while using Market Deflation 11 or higher! Does not work with Cube upgrade [3x8]!","Gain (1 + lvl/100)x Ant multiplier per Challenge completion, ignoring corruptions to Ants.","Effect of Drought is raised to the power of 0.5.","Reduce the effect of Financial Recession in Challenge 15, multiplying the coin exponent by 1.55.","You begin to find the start of the abyss. Coin Exponent +0.10 in Challenge 15, Challenge 15 Score +25%, Ascension Speed +0.2% per Corruption Level (Max: 20%), +1% all Cube types per C9 Completion (Multiplicative), +30% Quarks, 1e250x Tesseract Building Multiplier, 2x Ascension Count, +30 Reincarnation Challenge Cap, +20 Ascension Challenge Cap, 6x Offerings and Obtainium (Uncorruptable)! Talk about a deep dive.","Increase powder conversion rate by 1% per level, gain +2% Ascension count per level and gain up to 2% more Ascension count per level based on powder, up to 100,000. This will also multiply Tesseract Building production by (Powder + 1)^(10 * level), uncapped.","If Viscosity Corruption is set to level 10 or higher, score multiplier is raised by an exponent. That exponent is 3 + 0.04 per level of this upgrade.","Raise the base percentage of Constant Upgrade 1 by 0.1% and increase the base percentage cap of Constant Upgrade 2 by 0.3% per level!","The diminishing return power on Chronos Hepteract changes from 0.166 to (0.166 + 0.00133 * level) [Max of 0.2333].","You know, maybe some things should be left unbought."],Se={1:{obtainium:1e70,offerings:1e45,cubes:1e13,tesseracts:1e6,hypercubes:1e5,platonics:1e4,abyssals:0,maxLevel:300,priceMult:2},2:{obtainium:3e70,offerings:2e45,cubes:1e11,tesseracts:1e8,hypercubes:1e5,platonics:1e4,abyssals:0,maxLevel:300,priceMult:2},3:{obtainium:1e71,offerings:4e45,cubes:1e11,tesseracts:1e6,hypercubes:1e7,platonics:1e4,abyssals:0,maxLevel:300,priceMult:2},4:{obtainium:4e71,offerings:1e46,cubes:1e12,tesseracts:1e7,hypercubes:1e6,platonics:1e6,abyssals:0,maxLevel:300,priceMult:2},5:{obtainium:1e80,offerings:1e60,cubes:1e14,tesseracts:1e9,hypercubes:1e8,platonics:1e7,abyssals:0,maxLevel:1},6:{obtainium:1e82,offerings:1e61,cubes:1e15,tesseracts:1e9,hypercubes:1e8,platonics:1e7,abyssals:0,maxLevel:10},7:{obtainium:1e84,offerings:3e62,cubes:2e15,tesseracts:2e9,hypercubes:2e8,platonics:15e6,abyssals:0,maxLevel:15},8:{obtainium:1e87,offerings:1e64,cubes:4e15,tesseracts:4e9,hypercubes:4e8,platonics:3e7,abyssals:0,maxLevel:5},9:{obtainium:1e90,offerings:1e66,cubes:1e16,tesseracts:1e10,hypercubes:1e9,platonics:5e7,abyssals:0,maxLevel:1},10:{obtainium:1e93,offerings:1e68,cubes:1e18,tesseracts:1e12,hypercubes:1e11,platonics:1e9,abyssals:0,maxLevel:1},11:{obtainium:2e96,offerings:1e70,cubes:2e17,tesseracts:2e11,hypercubes:2e10,platonics:2e8,abyssals:0,maxLevel:1},12:{obtainium:1e100,offerings:1e72,cubes:1e18,tesseracts:1e12,hypercubes:1e11,platonics:1e9,abyssals:0,maxLevel:10},13:{obtainium:2e104,offerings:1e74,cubes:2e19,tesseracts:4e12,hypercubes:4e11,platonics:4e9,abyssals:0,maxLevel:1},14:{obtainium:1e108,offerings:1e77,cubes:4e20,tesseracts:1e13,hypercubes:1e12,platonics:1e10,abyssals:0,maxLevel:1},15:{obtainium:1e115,offerings:1e80,cubes:1e23,tesseracts:1e15,hypercubes:1e14,platonics:1e12,abyssals:1,maxLevel:1},16:{obtainium:1e140,offerings:1e110,cubes:0,tesseracts:0,hypercubes:25e14,platonics:0,abyssals:0,maxLevel:100,priceMult:10},17:{obtainium:1e145,offerings:1e113,cubes:0,tesseracts:0,hypercubes:1e19,platonics:0,abyssals:2,maxLevel:20,priceMult:10},18:{obtainium:1e150,offerings:1e116,cubes:0,tesseracts:0,hypercubes:1e19,platonics:0,abyssals:4,maxLevel:40,priceMult:500},19:{obtainium:1e160,offerings:1e121,cubes:0,tesseracts:0,hypercubes:1e21,platonics:0,abyssals:64,maxLevel:50,priceMult:200},20:{obtainium:1e180,offerings:1e130,cubes:1e45,tesseracts:1e28,hypercubes:1e25,platonics:1e25,abyssals:Math.pow(2,30)-1,maxLevel:1}},tu=(t,r=!1)=>{let n=0,a=["obtainium","offerings","cubes","tesseracts","hypercubes","platonics","abyssals"],s=["researchPoints","runeshards","wowCubes","wowTesseracts","wowHypercubes","wowPlatonicCubes","wowAbyssals"],l={obtainium:!1,offerings:!1,cubes:!1,tesseracts:!1,hypercubes:!1,platonics:!1,abyssals:!1,canBuy:!1},c=1;Se[t].priceMult&&(c=Math.pow(Se[t].priceMult,Math.pow(e.platonicUpgrades[t]/(Se[t].maxLevel-1),1.25))),c*=Le("Platonic Costs");for(let p=0;p=Math.floor(Se[t].abyssals*c)||Se[t].abyssals===0)&&(n++,l.abyssals=!0),n===a.length&&e.platonicUpgrades[t]{let r="";e.platonicUpgrades[t]===Se[t].maxLevel&&(r=" [MAX]");let n=tu(t),a=1;Se[t].priceMult&&(a=Math.pow(Se[t].priceMult,Math.pow(e.platonicUpgrades[t]/(Se[t].maxLevel-1),1.25))),a*=Le("Platonic Costs"),i("platonicUpgradeDescription").textContent=Zb[t-1],i("platonicUpgradeLevel").textContent=`Level: ${d(e.platonicUpgrades[t])}/${d(Se[t].maxLevel)}${r}`,i("platonicOfferingCost").textContent=`${d(e.runeshards)}/${d(Se[t].offerings*a)} Offerings`,i("platonicObtainiumCost").textContent=`${d(e.researchPoints)}/${d(Se[t].obtainium*a)} Obtainium`,i("platonicCubeCost").textContent=`${d(e.wowCubes)}/${d(Se[t].cubes*a)} Wow! Cubes`,i("platonicTesseractCost").textContent=`${d(e.wowTesseracts)}/${d(Se[t].tesseracts*a)} Wow! Tesseracts`,i("platonicHypercubeCost").textContent=`${d(e.wowHypercubes)}/${d(Se[t].hypercubes*a)} Wow! Hypercubes`,i("platonicPlatonicCost").textContent=`${d(e.wowPlatonicCubes)}/${d(Se[t].platonics*a)} Platonic! Cubes`,i("platonicHepteractCost").textContent=`${d(e.hepteractCrafts.abyss.BAL)}/${d(Math.floor(Se[t].abyssals*a),0,!0)} Hepteracts of the Abyss`,n.offerings?i("platonicOfferingCost").style.color="lime":i("platonicOfferingCost").style.color="var(--crimson-text-color)",n.obtainium?i("platonicObtainiumCost").style.color="lime":i("platonicObtainiumCost").style.color="var(--crimson-text-color)",n.cubes?i("platonicCubeCost").style.color="lime":i("platonicCubeCost").style.color="var(--crimson-text-color)",n.tesseracts?i("platonicTesseractCost").style.color="lime":i("platonicTesseractCost").style.color="var(--crimson-text-color)",n.hypercubes?i("platonicHypercubeCost").style.color="lime":i("platonicHypercubeCost").style.color="var(--crimson-text-color)",n.platonics?i("platonicPlatonicCost").style.color="lime":i("platonicPlatonicCost").style.color="var(--crimson-text-color)",n.abyssals?i("platonicHepteractCost").style.color="lime":i("platonicHepteractCost").style.color="var(--crimson-text-color)",e.platonicUpgrades[t]{let r=i(`platUpg${t}`),n=Se[t].maxLevel;e.platonicUpgrades[t]===0?r.style.backgroundColor="":e.platonicUpgrades[t]>0&&e.platonicUpgrades[t]{for(;t>0;){let n=tu(t,r),a=1;if(Se[t].priceMult&&(a=Math.pow(Se[t].priceMult,Math.pow(e.platonicUpgrades[t]/(Se[t].maxLevel-1),1.25))),a*=Le("Platonic Costs"),n.canBuy)e.platonicUpgrades[t]+=1,r||(e.researchPoints-=Math.floor(Se[t].obtainium*a),e.runeshards-=Math.floor(Se[t].offerings*a)),e.wowCubes.sub(Math.floor(Se[t].cubes*a)),e.wowTesseracts.sub(Math.floor(Se[t].tesseracts*a)),e.wowHypercubes.sub(Math.floor(Se[t].hypercubes*a)),e.wowPlatonicCubes.sub(Math.floor(Se[t].platonics*a)),e.hepteractCrafts.abyss.spend(Math.floor(Se[t].abyssals*a)),Ct.emit("boughtPlatonicUpgrade",Se[t]),t===20&&!r&&e.singularityCount===0&&P("While I strongly recommended you not to buy this, you did it anyway. For that, you have unlocked the rune of Grandiloquence, for you are a richass.");else break;if(e.platonicUpgrades[t]===Se[t].maxLevel||e.singularityCount===0)break}ru(t),io(t),Oe()},Wg=()=>{if(e.autoPlatonicUpgradesToggle&&(e.highestSingularityCount>=100&&e.insideSingularityChallenge||e.highestSingularityCount>=200))for(let t=1;t{let n=o.effectiveLevelMult,a=1+e.researches[84]/200*(1+1*o.effectiveRuneSpiritPower[5]*Xe()/400),s=co(t-1,!1,e.runelevels[t-1]),l;if(t===1?l={bonus:d(Math.floor(Math.pow(o.rune1level*n/4,1.25))),percent:d(o.rune1level/4*n,2,!0),boost:d(Math.floor(o.rune1level/20*n))}:t===2?l={mult1:d(Math.floor(o.rune2level*n/10)*Math.floor(1+o.rune2level*n/10)/2),mult2:d(n*o.rune2level/4,1,!0),tax:(99.9*(1-Math.pow(6,-(o.rune2level*n)/1e3))).toPrecision(4)}:t===3?l={mult:d(f.pow(o.rune3level*n/2,2).times(f.pow(2,o.rune3level*n/2-8)).add(1),3),gain:d(Math.floor(o.rune3level/16*n))}:t===4?l={delay:(o.rune4level/8*n).toPrecision(3),chance:Math.min(25,o.rune4level/16),tax:(99*(1-Math.pow(4,Math.min(0,(400-o.rune4level)/1100)))).toPrecision(4)}:t===5?l={gain:d(1+o.rune5level/200*n*a,2,!0),speed:d(1+Math.pow(o.rune5level*n*a,2)/2500),offerings:d(o.rune5level*n*a*.005,3,!0)}:t===6?l={percent1:d(10+15/75*Qn(),1,!0),percent2:d(1*Qn(),0,!0)}:t===7&&r&&(l={exp:d(1e256*(1+e.singularityCount))}),r&&(i("runeshowlevelup").textContent=u.t(`runes.levelup.${t}`,l)),i(`runeshowpower${t}`).textContent=u.t(`runes.power.${t}`,l),r){let c=Xg(t-1,e.runelevels[t-1],e.offeringbuyamount),p=0,g=0;for(;g{e.runeshards=Math.min(1e300,e.runeshards+Qr(t))},lo=t=>[!1,!0,e.achievements[38]>.5,e.achievements[44]>.5,e.achievements[102]>.5,e.researches[82]>.5,wa(),e.platonicUpgrades[20]>0][t],zg=t=>{let r=0;for(let n=0;n=rt(n+1))&&r++;return r},Ca=(t,r=!1,n=0)=>{let a=t-1,s=e.offeringbuyamount;r&&(s=Math.pow(2,e.shopUpgrades.offeringAuto)),r&&n>0&&(s=Math.min(1e4,rt(a+1)));let l=0;if(e.runeshards>0&&e.runelevels[a]x+B,0));n>0&&(m=Math.min(e.runeshards,n));let h=co(a,!1,e.runelevels[a],!0),b=e.upgrades[71]/25,C=h[0]-b*e.runelevels[a],v=h.slice(1,h.length).reduce((x,B)=>x*B,1);for(;m>0&&l=on(a)&&e.runelevels[a]=on(x)&&e.runelevels[x]{let a=on(t,r)-e.runeexp[t],s=rt(t+1),l=[],c=0,p=e.runeshards,g=0,m=co(t,!1,r,!0),h=e.upgrades[71]/25,b=m[0]-h*r,C=m.slice(1,m.length).reduce((v,x)=>v*x,1);for(;gs;function r(s){}t.assertIs=r;function n(s){throw new Error}t.assertNever=n,t.arrayToEnum=s=>{let l={};for(let c of s)l[c]=c;return l},t.getValidEnumValues=s=>{let l=t.objectKeys(s).filter(p=>typeof s[s[p]]!="number"),c={};for(let p of l)c[p]=s[p];return t.objectValues(c)},t.objectValues=s=>t.objectKeys(s).map(function(l){return s[l]}),t.objectKeys=typeof Object.keys=="function"?s=>Object.keys(s):s=>{let l=[];for(let c in s)Object.prototype.hasOwnProperty.call(s,c)&&l.push(c);return l},t.find=(s,l)=>{for(let c of s)if(l(c))return c},t.isInteger=typeof Number.isInteger=="function"?s=>Number.isInteger(s):s=>typeof s=="number"&&isFinite(s)&&Math.floor(s)===s;function a(s,l=" | "){return s.map(c=>typeof c=="string"?`'${c}'`:c).join(l)}t.joinValues=a,t.jsonStringifyReplacer=(s,l)=>typeof l=="bigint"?l.toString():l})(ke||(ke={}));var su;(function(t){t.mergeShapes=(r,n)=>O(O({},r),n)})(su||(su={}));var K=ke.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),cn=t=>{switch(typeof t){case"undefined":return K.undefined;case"string":return K.string;case"number":return isNaN(t)?K.nan:K.number;case"boolean":return K.boolean;case"function":return K.function;case"bigint":return K.bigint;case"symbol":return K.symbol;case"object":return Array.isArray(t)?K.array:t===null?K.null:t.then&&typeof t.then=="function"&&t.catch&&typeof t.catch=="function"?K.promise:typeof Map<"u"&&t instanceof Map?K.map:typeof Set<"u"&&t instanceof Set?K.set:typeof Date<"u"&&t instanceof Date?K.date:K.object;default:return K.unknown}},G=ke.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]),Yb=t=>JSON.stringify(t,null,2).replace(/"([^"]+)":/g,"$1:"),Pt=class extends Error{get errors(){return this.issues}constructor(r){super(),this.issues=[],this.addIssue=a=>{this.issues=[...this.issues,a]},this.addIssues=(a=[])=>{this.issues=[...this.issues,...a]};let n=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,n):this.__proto__=n,this.name="ZodError",this.issues=r}format(r){let n=r||function(l){return l.message},a={_errors:[]},s=l=>{for(let c of l.issues)if(c.code==="invalid_union")c.unionErrors.map(s);else if(c.code==="invalid_return_type")s(c.returnTypeError);else if(c.code==="invalid_arguments")s(c.argumentsError);else if(c.path.length===0)a._errors.push(n(c));else{let p=a,g=0;for(;gn.message){let n={},a=[];for(let s of this.issues)s.path.length>0?(n[s.path[0]]=n[s.path[0]]||[],n[s.path[0]].push(r(s))):a.push(r(s));return{formErrors:a,fieldErrors:n}}get formErrors(){return this.flatten()}};Pt.create=t=>new Pt(t);var ms=(t,r)=>{let n;switch(t.code){case G.invalid_type:t.received===K.undefined?n="Required":n=`Expected ${t.expected}, received ${t.received}`;break;case G.invalid_literal:n=`Invalid literal value, expected ${JSON.stringify(t.expected,ke.jsonStringifyReplacer)}`;break;case G.unrecognized_keys:n=`Unrecognized key(s) in object: ${ke.joinValues(t.keys,", ")}`;break;case G.invalid_union:n="Invalid input";break;case G.invalid_union_discriminator:n=`Invalid discriminator value. Expected ${ke.joinValues(t.options)}`;break;case G.invalid_enum_value:n=`Invalid enum value. Expected ${ke.joinValues(t.options)}, received '${t.received}'`;break;case G.invalid_arguments:n="Invalid function arguments";break;case G.invalid_return_type:n="Invalid function return type";break;case G.invalid_date:n="Invalid date";break;case G.invalid_string:typeof t.validation=="object"?"includes"in t.validation?(n=`Invalid input: must include "${t.validation.includes}"`,typeof t.validation.position=="number"&&(n=`${n} at one or more positions greater than or equal to ${t.validation.position}`)):"startsWith"in t.validation?n=`Invalid input: must start with "${t.validation.startsWith}"`:"endsWith"in t.validation?n=`Invalid input: must end with "${t.validation.endsWith}"`:ke.assertNever(t.validation):t.validation!=="regex"?n=`Invalid ${t.validation}`:n="Invalid";break;case G.too_small:t.type==="array"?n=`Array must contain ${t.exact?"exactly":t.inclusive?"at least":"more than"} ${t.minimum} element(s)`:t.type==="string"?n=`String must contain ${t.exact?"exactly":t.inclusive?"at least":"over"} ${t.minimum} character(s)`:t.type==="number"?n=`Number must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${t.minimum}`:t.type==="date"?n=`Date must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(t.minimum))}`:n="Invalid input";break;case G.too_big:t.type==="array"?n=`Array must contain ${t.exact?"exactly":t.inclusive?"at most":"less than"} ${t.maximum} element(s)`:t.type==="string"?n=`String must contain ${t.exact?"exactly":t.inclusive?"at most":"under"} ${t.maximum} character(s)`:t.type==="number"?n=`Number must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`:t.type==="bigint"?n=`BigInt must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`:t.type==="date"?n=`Date must be ${t.exact?"exactly":t.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(t.maximum))}`:n="Invalid input";break;case G.custom:n="Invalid input";break;case G.invalid_intersection_types:n="Intersection results could not be merged";break;case G.not_multiple_of:n=`Number must be a multiple of ${t.multipleOf}`;break;case G.not_finite:n="Number must be finite";break;default:n=r.defaultError,ke.assertNever(t)}return{message:n}},Jg=ms;function Jb(t){Jg=t}function Hi(){return Jg}var Fi=t=>{let{data:r,path:n,errorMaps:a,issueData:s}=t,l=[...n,...s.path||[]],c=te(O({},s),{path:l});if(s.message!==void 0)return te(O({},s),{path:l,message:s.message});let p="",g=a.filter(m=>!!m).slice().reverse();for(let m of g)p=m(c,{data:r,defaultError:p}).message;return te(O({},s),{path:l,message:p})},ey=[];function j(t,r){let n=Hi(),a=Fi({issueData:r,data:t.data,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,n,n===ms?void 0:ms].filter(s=>!!s)});t.common.issues.push(a)}var at=class{constructor(){this.value="valid"}dirty(){this.value==="valid"&&(this.value="dirty")}abort(){this.value!=="aborted"&&(this.value="aborted")}static mergeArray(r,n){let a=[];for(let s of n){if(s.status==="aborted")return ie;s.status==="dirty"&&r.dirty(),a.push(s.value)}return{status:r.value,value:a}}static async mergeObjectAsync(r,n){let a=[];for(let s of n){let l=await s.key,c=await s.value;a.push({key:l,value:c})}return at.mergeObjectSync(r,a)}static mergeObjectSync(r,n){let a={};for(let s of n){let{key:l,value:c}=s;if(l.status==="aborted"||c.status==="aborted")return ie;l.status==="dirty"&&r.dirty(),c.status==="dirty"&&r.dirty(),l.value!=="__proto__"&&(typeof c.value<"u"||s.alwaysSet)&&(a[l.value]=c.value)}return{status:r.value,value:a}}},ie=Object.freeze({status:"aborted"}),gs=t=>({status:"dirty",value:t}),At=t=>({status:"valid",value:t}),ou=t=>t.status==="aborted",iu=t=>t.status==="dirty",xa=t=>t.status==="valid",go=t=>typeof Promise<"u"&&t instanceof Promise;function Qi(t,r,n,a){if(n==="a"&&!a)throw new TypeError("Private accessor was defined without a getter");if(typeof r=="function"?t!==r||!a:!r.has(t))throw new TypeError("Cannot read private member from an object whose class did not declare it");return n==="m"?a:n==="a"?a.call(t):a?a.value:r.get(t)}function em(t,r,n,a,s){if(a==="m")throw new TypeError("Private method is not writable");if(a==="a"&&!s)throw new TypeError("Private accessor was defined without a setter");if(typeof r=="function"?t!==r||!s:!r.has(t))throw new TypeError("Cannot write private member to an object whose class did not declare it");return a==="a"?s.call(t,n):s?s.value=n:r.set(t,n),n}var Y;(function(t){t.errToObj=r=>typeof r=="string"?{message:r}:r||{},t.toString=r=>typeof r=="string"?r:r==null?void 0:r.message})(Y||(Y={}));var uo,po,lr=class{constructor(r,n,a,s){this._cachedPath=[],this.parent=r,this.data=n,this._path=a,this._key=s}get path(){return this._cachedPath.length||(this._key instanceof Array?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}},Zg=(t,r)=>{if(xa(r))return{success:!0,data:r.value};if(!t.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;let n=new Pt(t.common.issues);return this._error=n,this._error}}};function ge(t){if(!t)return{};let{errorMap:r,invalid_type_error:n,required_error:a,description:s}=t;if(r&&(n||a))throw new Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);return r?{errorMap:r,description:s}:{errorMap:(c,p)=>{var g,m;let{message:h}=t;return c.code==="invalid_enum_value"?{message:h!=null?h:p.defaultError}:typeof p.data>"u"?{message:(g=h!=null?h:a)!==null&&g!==void 0?g:p.defaultError}:c.code!=="invalid_type"?{message:p.defaultError}:{message:(m=h!=null?h:n)!==null&&m!==void 0?m:p.defaultError}},description:s}}var me=class{get description(){return this._def.description}_getType(r){return cn(r.data)}_getOrReturnCtx(r,n){return n||{common:r.parent.common,data:r.data,parsedType:cn(r.data),schemaErrorMap:this._def.errorMap,path:r.path,parent:r.parent}}_processInputParams(r){return{status:new at,ctx:{common:r.parent.common,data:r.data,parsedType:cn(r.data),schemaErrorMap:this._def.errorMap,path:r.path,parent:r.parent}}}_parseSync(r){let n=this._parse(r);if(go(n))throw new Error("Synchronous parse encountered promise.");return n}_parseAsync(r){let n=this._parse(r);return Promise.resolve(n)}parse(r,n){let a=this.safeParse(r,n);if(a.success)return a.data;throw a.error}safeParse(r,n){var a;let s={common:{issues:[],async:(a=n==null?void 0:n.async)!==null&&a!==void 0?a:!1,contextualErrorMap:n==null?void 0:n.errorMap},path:(n==null?void 0:n.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:r,parsedType:cn(r)},l=this._parseSync({data:r,path:s.path,parent:s});return Zg(s,l)}"~validate"(r){var n,a;let s={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:r,parsedType:cn(r)};if(!this["~standard"].async)try{let l=this._parseSync({data:r,path:[],parent:s});return xa(l)?{value:l.value}:{issues:s.common.issues}}catch(l){!((a=(n=l==null?void 0:l.message)===null||n===void 0?void 0:n.toLowerCase())===null||a===void 0)&&a.includes("encountered")&&(this["~standard"].async=!0),s.common={issues:[],async:!0}}return this._parseAsync({data:r,path:[],parent:s}).then(l=>xa(l)?{value:l.value}:{issues:s.common.issues})}async parseAsync(r,n){let a=await this.safeParseAsync(r,n);if(a.success)return a.data;throw a.error}async safeParseAsync(r,n){let a={common:{issues:[],contextualErrorMap:n==null?void 0:n.errorMap,async:!0},path:(n==null?void 0:n.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:r,parsedType:cn(r)},s=this._parse({data:r,path:a.path,parent:a}),l=await(go(s)?s:Promise.resolve(s));return Zg(a,l)}refine(r,n){let a=s=>typeof n=="string"||typeof n>"u"?{message:n}:typeof n=="function"?n(s):n;return this._refinement((s,l)=>{let c=r(s),p=()=>l.addIssue(O({code:G.custom},a(s)));return typeof Promise<"u"&&c instanceof Promise?c.then(g=>g?!0:(p(),!1)):c?!0:(p(),!1)})}refinement(r,n){return this._refinement((a,s)=>r(a)?!0:(s.addIssue(typeof n=="function"?n(a,s):n),!1))}_refinement(r){return new Kt({schema:this,typeName:oe.ZodEffects,effect:{type:"refinement",refinement:r}})}superRefine(r){return this._refinement(r)}constructor(r){this.spa=this.safeParseAsync,this._def=r,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this),this["~standard"]={version:1,vendor:"zod",validate:n=>this["~validate"](n)}}optional(){return ir.create(this,this._def)}nullable(){return Wr.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return Wt.create(this)}promise(){return Vn.create(this,this._def)}or(r){return ka.create([this,r],this._def)}and(r){return La.create(this,r,this._def)}transform(r){return new Kt(te(O({},ge(this._def)),{schema:this,typeName:oe.ZodEffects,effect:{type:"transform",transform:r}}))}default(r){let n=typeof r=="function"?r:()=>r;return new Ua(te(O({},ge(this._def)),{innerType:this,defaultValue:n,typeName:oe.ZodDefault}))}brand(){return new mo(O({typeName:oe.ZodBranded,type:this},ge(this._def)))}catch(r){let n=typeof r=="function"?r:()=>r;return new Ba(te(O({},ge(this._def)),{innerType:this,catchValue:n,typeName:oe.ZodCatch}))}describe(r){let n=this.constructor;return new n(te(O({},this._def),{description:r}))}pipe(r){return Ra.create(this,r)}readonly(){return Ia.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}},ty=/^c[^\s-]{8,}$/i,ry=/^[0-9a-z]+$/,ny=/^[0-9A-HJKMNP-TV-Z]{26}$/i,ay=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,sy=/^[a-z0-9_-]{21}$/i,oy=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,iy=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,ly=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,cy="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$",au,uy=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,dy=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/(3[0-2]|[12]?[0-9])$/,py=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/,gy=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,my=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,fy=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,tm="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",hy=new RegExp(`^${tm}$`);function rm(t){let r="([01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d";return t.precision?r=`${r}\\.\\d{${t.precision}}`:t.precision==null&&(r=`${r}(\\.\\d+)?`),r}function by(t){return new RegExp(`^${rm(t)}$`)}function nm(t){let r=`${tm}T${rm(t)}`,n=[];return n.push(t.local?"Z?":"Z"),t.offset&&n.push("([+-]\\d{2}:?\\d{2})"),r=`${r}(${n.join("|")})`,new RegExp(`^${r}$`)}function yy(t,r){return!!((r==="v4"||!r)&&uy.test(t)||(r==="v6"||!r)&&py.test(t))}function vy(t,r){if(!oy.test(t))return!1;try{let[n]=t.split("."),a=n.replace(/-/g,"+").replace(/_/g,"/").padEnd(n.length+(4-n.length%4)%4,"="),s=JSON.parse(atob(a));return!(typeof s!="object"||s===null||!s.typ||!s.alg||r&&s.alg!==r)}catch(n){return!1}}function Cy(t,r){return!!((r==="v4"||!r)&&dy.test(t)||(r==="v6"||!r)&&gy.test(t))}var Vt=class extends me{_parse(r){if(this._def.coerce&&(r.data=String(r.data)),this._getType(r)!==K.string){let l=this._getOrReturnCtx(r);return j(l,{code:G.invalid_type,expected:K.string,received:l.parsedType}),ie}let a=new at,s;for(let l of this._def.checks)if(l.kind==="min")r.data.lengthl.value&&(s=this._getOrReturnCtx(r,s),j(s,{code:G.too_big,maximum:l.value,type:"string",inclusive:!0,exact:!1,message:l.message}),a.dirty());else if(l.kind==="length"){let c=r.data.length>l.value,p=r.data.lengthr.test(s),O({validation:n,code:G.invalid_string},Y.errToObj(a)))}_addCheck(r){return new Vt(te(O({},this._def),{checks:[...this._def.checks,r]}))}email(r){return this._addCheck(O({kind:"email"},Y.errToObj(r)))}url(r){return this._addCheck(O({kind:"url"},Y.errToObj(r)))}emoji(r){return this._addCheck(O({kind:"emoji"},Y.errToObj(r)))}uuid(r){return this._addCheck(O({kind:"uuid"},Y.errToObj(r)))}nanoid(r){return this._addCheck(O({kind:"nanoid"},Y.errToObj(r)))}cuid(r){return this._addCheck(O({kind:"cuid"},Y.errToObj(r)))}cuid2(r){return this._addCheck(O({kind:"cuid2"},Y.errToObj(r)))}ulid(r){return this._addCheck(O({kind:"ulid"},Y.errToObj(r)))}base64(r){return this._addCheck(O({kind:"base64"},Y.errToObj(r)))}base64url(r){return this._addCheck(O({kind:"base64url"},Y.errToObj(r)))}jwt(r){return this._addCheck(O({kind:"jwt"},Y.errToObj(r)))}ip(r){return this._addCheck(O({kind:"ip"},Y.errToObj(r)))}cidr(r){return this._addCheck(O({kind:"cidr"},Y.errToObj(r)))}datetime(r){var n,a;return typeof r=="string"?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:r}):this._addCheck(O({kind:"datetime",precision:typeof(r==null?void 0:r.precision)>"u"?null:r==null?void 0:r.precision,offset:(n=r==null?void 0:r.offset)!==null&&n!==void 0?n:!1,local:(a=r==null?void 0:r.local)!==null&&a!==void 0?a:!1},Y.errToObj(r==null?void 0:r.message)))}date(r){return this._addCheck({kind:"date",message:r})}time(r){return typeof r=="string"?this._addCheck({kind:"time",precision:null,message:r}):this._addCheck(O({kind:"time",precision:typeof(r==null?void 0:r.precision)>"u"?null:r==null?void 0:r.precision},Y.errToObj(r==null?void 0:r.message)))}duration(r){return this._addCheck(O({kind:"duration"},Y.errToObj(r)))}regex(r,n){return this._addCheck(O({kind:"regex",regex:r},Y.errToObj(n)))}includes(r,n){return this._addCheck(O({kind:"includes",value:r,position:n==null?void 0:n.position},Y.errToObj(n==null?void 0:n.message)))}startsWith(r,n){return this._addCheck(O({kind:"startsWith",value:r},Y.errToObj(n)))}endsWith(r,n){return this._addCheck(O({kind:"endsWith",value:r},Y.errToObj(n)))}min(r,n){return this._addCheck(O({kind:"min",value:r},Y.errToObj(n)))}max(r,n){return this._addCheck(O({kind:"max",value:r},Y.errToObj(n)))}length(r,n){return this._addCheck(O({kind:"length",value:r},Y.errToObj(n)))}nonempty(r){return this.min(1,Y.errToObj(r))}trim(){return new Vt(te(O({},this._def),{checks:[...this._def.checks,{kind:"trim"}]}))}toLowerCase(){return new Vt(te(O({},this._def),{checks:[...this._def.checks,{kind:"toLowerCase"}]}))}toUpperCase(){return new Vt(te(O({},this._def),{checks:[...this._def.checks,{kind:"toUpperCase"}]}))}get isDatetime(){return!!this._def.checks.find(r=>r.kind==="datetime")}get isDate(){return!!this._def.checks.find(r=>r.kind==="date")}get isTime(){return!!this._def.checks.find(r=>r.kind==="time")}get isDuration(){return!!this._def.checks.find(r=>r.kind==="duration")}get isEmail(){return!!this._def.checks.find(r=>r.kind==="email")}get isURL(){return!!this._def.checks.find(r=>r.kind==="url")}get isEmoji(){return!!this._def.checks.find(r=>r.kind==="emoji")}get isUUID(){return!!this._def.checks.find(r=>r.kind==="uuid")}get isNANOID(){return!!this._def.checks.find(r=>r.kind==="nanoid")}get isCUID(){return!!this._def.checks.find(r=>r.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(r=>r.kind==="cuid2")}get isULID(){return!!this._def.checks.find(r=>r.kind==="ulid")}get isIP(){return!!this._def.checks.find(r=>r.kind==="ip")}get isCIDR(){return!!this._def.checks.find(r=>r.kind==="cidr")}get isBase64(){return!!this._def.checks.find(r=>r.kind==="base64")}get isBase64url(){return!!this._def.checks.find(r=>r.kind==="base64url")}get minLength(){let r=null;for(let n of this._def.checks)n.kind==="min"&&(r===null||n.value>r)&&(r=n.value);return r}get maxLength(){let r=null;for(let n of this._def.checks)n.kind==="max"&&(r===null||n.value{var r;return new Vt(O({checks:[],typeName:oe.ZodString,coerce:(r=t==null?void 0:t.coerce)!==null&&r!==void 0?r:!1},ge(t)))};function wy(t,r){let n=(t.toString().split(".")[1]||"").length,a=(r.toString().split(".")[1]||"").length,s=n>a?n:a,l=parseInt(t.toFixed(s).replace(".","")),c=parseInt(r.toFixed(s).replace(".",""));return l%c/Math.pow(10,s)}var qr=class extends me{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(r){if(this._def.coerce&&(r.data=Number(r.data)),this._getType(r)!==K.number){let l=this._getOrReturnCtx(r);return j(l,{code:G.invalid_type,expected:K.number,received:l.parsedType}),ie}let a,s=new at;for(let l of this._def.checks)l.kind==="int"?ke.isInteger(r.data)||(a=this._getOrReturnCtx(r,a),j(a,{code:G.invalid_type,expected:"integer",received:"float",message:l.message}),s.dirty()):l.kind==="min"?(l.inclusive?r.datal.value:r.data>=l.value)&&(a=this._getOrReturnCtx(r,a),j(a,{code:G.too_big,maximum:l.value,type:"number",inclusive:l.inclusive,exact:!1,message:l.message}),s.dirty()):l.kind==="multipleOf"?wy(r.data,l.value)!==0&&(a=this._getOrReturnCtx(r,a),j(a,{code:G.not_multiple_of,multipleOf:l.value,message:l.message}),s.dirty()):l.kind==="finite"?Number.isFinite(r.data)||(a=this._getOrReturnCtx(r,a),j(a,{code:G.not_finite,message:l.message}),s.dirty()):ke.assertNever(l);return{status:s.value,value:r.data}}gte(r,n){return this.setLimit("min",r,!0,Y.toString(n))}gt(r,n){return this.setLimit("min",r,!1,Y.toString(n))}lte(r,n){return this.setLimit("max",r,!0,Y.toString(n))}lt(r,n){return this.setLimit("max",r,!1,Y.toString(n))}setLimit(r,n,a,s){return new qr(te(O({},this._def),{checks:[...this._def.checks,{kind:r,value:n,inclusive:a,message:Y.toString(s)}]}))}_addCheck(r){return new qr(te(O({},this._def),{checks:[...this._def.checks,r]}))}int(r){return this._addCheck({kind:"int",message:Y.toString(r)})}positive(r){return this._addCheck({kind:"min",value:0,inclusive:!1,message:Y.toString(r)})}negative(r){return this._addCheck({kind:"max",value:0,inclusive:!1,message:Y.toString(r)})}nonpositive(r){return this._addCheck({kind:"max",value:0,inclusive:!0,message:Y.toString(r)})}nonnegative(r){return this._addCheck({kind:"min",value:0,inclusive:!0,message:Y.toString(r)})}multipleOf(r,n){return this._addCheck({kind:"multipleOf",value:r,message:Y.toString(n)})}finite(r){return this._addCheck({kind:"finite",message:Y.toString(r)})}safe(r){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:Y.toString(r)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:Y.toString(r)})}get minValue(){let r=null;for(let n of this._def.checks)n.kind==="min"&&(r===null||n.value>r)&&(r=n.value);return r}get maxValue(){let r=null;for(let n of this._def.checks)n.kind==="max"&&(r===null||n.valuer.kind==="int"||r.kind==="multipleOf"&&ke.isInteger(r.value))}get isFinite(){let r=null,n=null;for(let a of this._def.checks){if(a.kind==="finite"||a.kind==="int"||a.kind==="multipleOf")return!0;a.kind==="min"?(n===null||a.value>n)&&(n=a.value):a.kind==="max"&&(r===null||a.valuenew qr(O({checks:[],typeName:oe.ZodNumber,coerce:(t==null?void 0:t.coerce)||!1},ge(t)));var jr=class extends me{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(r){if(this._def.coerce)try{r.data=BigInt(r.data)}catch(l){return this._getInvalidInput(r)}if(this._getType(r)!==K.bigint)return this._getInvalidInput(r);let a,s=new at;for(let l of this._def.checks)l.kind==="min"?(l.inclusive?r.datal.value:r.data>=l.value)&&(a=this._getOrReturnCtx(r,a),j(a,{code:G.too_big,type:"bigint",maximum:l.value,inclusive:l.inclusive,message:l.message}),s.dirty()):l.kind==="multipleOf"?r.data%l.value!==BigInt(0)&&(a=this._getOrReturnCtx(r,a),j(a,{code:G.not_multiple_of,multipleOf:l.value,message:l.message}),s.dirty()):ke.assertNever(l);return{status:s.value,value:r.data}}_getInvalidInput(r){let n=this._getOrReturnCtx(r);return j(n,{code:G.invalid_type,expected:K.bigint,received:n.parsedType}),ie}gte(r,n){return this.setLimit("min",r,!0,Y.toString(n))}gt(r,n){return this.setLimit("min",r,!1,Y.toString(n))}lte(r,n){return this.setLimit("max",r,!0,Y.toString(n))}lt(r,n){return this.setLimit("max",r,!1,Y.toString(n))}setLimit(r,n,a,s){return new jr(te(O({},this._def),{checks:[...this._def.checks,{kind:r,value:n,inclusive:a,message:Y.toString(s)}]}))}_addCheck(r){return new jr(te(O({},this._def),{checks:[...this._def.checks,r]}))}positive(r){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:Y.toString(r)})}negative(r){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:Y.toString(r)})}nonpositive(r){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:Y.toString(r)})}nonnegative(r){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:Y.toString(r)})}multipleOf(r,n){return this._addCheck({kind:"multipleOf",value:r,message:Y.toString(n)})}get minValue(){let r=null;for(let n of this._def.checks)n.kind==="min"&&(r===null||n.value>r)&&(r=n.value);return r}get maxValue(){let r=null;for(let n of this._def.checks)n.kind==="max"&&(r===null||n.value{var r;return new jr(O({checks:[],typeName:oe.ZodBigInt,coerce:(r=t==null?void 0:t.coerce)!==null&&r!==void 0?r:!1},ge(t)))};var Ma=class extends me{_parse(r){if(this._def.coerce&&(r.data=!!r.data),this._getType(r)!==K.boolean){let a=this._getOrReturnCtx(r);return j(a,{code:G.invalid_type,expected:K.boolean,received:a.parsedType}),ie}return At(r.data)}};Ma.create=t=>new Ma(O({typeName:oe.ZodBoolean,coerce:(t==null?void 0:t.coerce)||!1},ge(t)));var dn=class extends me{_parse(r){if(this._def.coerce&&(r.data=new Date(r.data)),this._getType(r)!==K.date){let l=this._getOrReturnCtx(r);return j(l,{code:G.invalid_type,expected:K.date,received:l.parsedType}),ie}if(isNaN(r.data.getTime())){let l=this._getOrReturnCtx(r);return j(l,{code:G.invalid_date}),ie}let a=new at,s;for(let l of this._def.checks)l.kind==="min"?r.data.getTime()l.value&&(s=this._getOrReturnCtx(r,s),j(s,{code:G.too_big,message:l.message,inclusive:!0,exact:!1,maximum:l.value,type:"date"}),a.dirty()):ke.assertNever(l);return{status:a.value,value:new Date(r.data.getTime())}}_addCheck(r){return new dn(te(O({},this._def),{checks:[...this._def.checks,r]}))}min(r,n){return this._addCheck({kind:"min",value:r.getTime(),message:Y.toString(n)})}max(r,n){return this._addCheck({kind:"max",value:r.getTime(),message:Y.toString(n)})}get minDate(){let r=null;for(let n of this._def.checks)n.kind==="min"&&(r===null||n.value>r)&&(r=n.value);return r!=null?new Date(r):null}get maxDate(){let r=null;for(let n of this._def.checks)n.kind==="max"&&(r===null||n.valuenew dn(O({checks:[],coerce:(t==null?void 0:t.coerce)||!1,typeName:oe.ZodDate},ge(t)));var fs=class extends me{_parse(r){if(this._getType(r)!==K.symbol){let a=this._getOrReturnCtx(r);return j(a,{code:G.invalid_type,expected:K.symbol,received:a.parsedType}),ie}return At(r.data)}};fs.create=t=>new fs(O({typeName:oe.ZodSymbol},ge(t)));var Ta=class extends me{_parse(r){if(this._getType(r)!==K.undefined){let a=this._getOrReturnCtx(r);return j(a,{code:G.invalid_type,expected:K.undefined,received:a.parsedType}),ie}return At(r.data)}};Ta.create=t=>new Ta(O({typeName:oe.ZodUndefined},ge(t)));var Sa=class extends me{_parse(r){if(this._getType(r)!==K.null){let a=this._getOrReturnCtx(r);return j(a,{code:G.invalid_type,expected:K.null,received:a.parsedType}),ie}return At(r.data)}};Sa.create=t=>new Sa(O({typeName:oe.ZodNull},ge(t)));var jn=class extends me{constructor(){super(...arguments),this._any=!0}_parse(r){return At(r.data)}};jn.create=t=>new jn(O({typeName:oe.ZodAny},ge(t)));var un=class extends me{constructor(){super(...arguments),this._unknown=!0}_parse(r){return At(r.data)}};un.create=t=>new un(O({typeName:oe.ZodUnknown},ge(t)));var Er=class extends me{_parse(r){let n=this._getOrReturnCtx(r);return j(n,{code:G.invalid_type,expected:K.never,received:n.parsedType}),ie}};Er.create=t=>new Er(O({typeName:oe.ZodNever},ge(t)));var hs=class extends me{_parse(r){if(this._getType(r)!==K.undefined){let a=this._getOrReturnCtx(r);return j(a,{code:G.invalid_type,expected:K.void,received:a.parsedType}),ie}return At(r.data)}};hs.create=t=>new hs(O({typeName:oe.ZodVoid},ge(t)));var Wt=class extends me{_parse(r){let{ctx:n,status:a}=this._processInputParams(r),s=this._def;if(n.parsedType!==K.array)return j(n,{code:G.invalid_type,expected:K.array,received:n.parsedType}),ie;if(s.exactLength!==null){let c=n.data.length>s.exactLength.value,p=n.data.lengths.maxLength.value&&(j(n,{code:G.too_big,maximum:s.maxLength.value,type:"array",inclusive:!0,exact:!1,message:s.maxLength.message}),a.dirty()),n.common.async)return Promise.all([...n.data].map((c,p)=>s.type._parseAsync(new lr(n,c,n.path,p)))).then(c=>at.mergeArray(a,c));let l=[...n.data].map((c,p)=>s.type._parseSync(new lr(n,c,n.path,p)));return at.mergeArray(a,l)}get element(){return this._def.type}min(r,n){return new Wt(te(O({},this._def),{minLength:{value:r,message:Y.toString(n)}}))}max(r,n){return new Wt(te(O({},this._def),{maxLength:{value:r,message:Y.toString(n)}}))}length(r,n){return new Wt(te(O({},this._def),{exactLength:{value:r,message:Y.toString(n)}}))}nonempty(r){return this.min(1,r)}};Wt.create=(t,r)=>new Wt(O({type:t,minLength:null,maxLength:null,exactLength:null,typeName:oe.ZodArray},ge(r)));function ps(t){if(t instanceof Qe){let r={};for(let n in t.shape){let a=t.shape[n];r[n]=ir.create(ps(a))}return new Qe(te(O({},t._def),{shape:()=>r}))}else return t instanceof Wt?new Wt(te(O({},t._def),{type:ps(t.element)})):t instanceof ir?ir.create(ps(t.unwrap())):t instanceof Wr?Wr.create(ps(t.unwrap())):t instanceof cr?cr.create(t.items.map(r=>ps(r))):t}var Qe=class extends me{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;let r=this._def.shape(),n=ke.objectKeys(r);return this._cached={shape:r,keys:n}}_parse(r){if(this._getType(r)!==K.object){let m=this._getOrReturnCtx(r);return j(m,{code:G.invalid_type,expected:K.object,received:m.parsedType}),ie}let{status:a,ctx:s}=this._processInputParams(r),{shape:l,keys:c}=this._getCached(),p=[];if(!(this._def.catchall instanceof Er&&this._def.unknownKeys==="strip"))for(let m in s.data)c.includes(m)||p.push(m);let g=[];for(let m of c){let h=l[m],b=s.data[m];g.push({key:{status:"valid",value:m},value:h._parse(new lr(s,b,s.path,m)),alwaysSet:m in s.data})}if(this._def.catchall instanceof Er){let m=this._def.unknownKeys;if(m==="passthrough")for(let h of p)g.push({key:{status:"valid",value:h},value:{status:"valid",value:s.data[h]}});else if(m==="strict")p.length>0&&(j(s,{code:G.unrecognized_keys,keys:p}),a.dirty());else if(m!=="strip")throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{let m=this._def.catchall;for(let h of p){let b=s.data[h];g.push({key:{status:"valid",value:h},value:m._parse(new lr(s,b,s.path,h)),alwaysSet:h in s.data})}}return s.common.async?Promise.resolve().then(async()=>{let m=[];for(let h of g){let b=await h.key,C=await h.value;m.push({key:b,value:C,alwaysSet:h.alwaysSet})}return m}).then(m=>at.mergeObjectSync(a,m)):at.mergeObjectSync(a,g)}get shape(){return this._def.shape()}strict(r){return Y.errToObj,new Qe(O(te(O({},this._def),{unknownKeys:"strict"}),r!==void 0?{errorMap:(n,a)=>{var s,l,c,p;let g=(c=(l=(s=this._def).errorMap)===null||l===void 0?void 0:l.call(s,n,a).message)!==null&&c!==void 0?c:a.defaultError;return n.code==="unrecognized_keys"?{message:(p=Y.errToObj(r).message)!==null&&p!==void 0?p:g}:{message:g}}}:{}))}strip(){return new Qe(te(O({},this._def),{unknownKeys:"strip"}))}passthrough(){return new Qe(te(O({},this._def),{unknownKeys:"passthrough"}))}extend(r){return new Qe(te(O({},this._def),{shape:()=>O(O({},this._def.shape()),r)}))}merge(r){return new Qe({unknownKeys:r._def.unknownKeys,catchall:r._def.catchall,shape:()=>O(O({},this._def.shape()),r._def.shape()),typeName:oe.ZodObject})}setKey(r,n){return this.augment({[r]:n})}catchall(r){return new Qe(te(O({},this._def),{catchall:r}))}pick(r){let n={};return ke.objectKeys(r).forEach(a=>{r[a]&&this.shape[a]&&(n[a]=this.shape[a])}),new Qe(te(O({},this._def),{shape:()=>n}))}omit(r){let n={};return ke.objectKeys(this.shape).forEach(a=>{r[a]||(n[a]=this.shape[a])}),new Qe(te(O({},this._def),{shape:()=>n}))}deepPartial(){return ps(this)}partial(r){let n={};return ke.objectKeys(this.shape).forEach(a=>{let s=this.shape[a];r&&!r[a]?n[a]=s:n[a]=s.optional()}),new Qe(te(O({},this._def),{shape:()=>n}))}required(r){let n={};return ke.objectKeys(this.shape).forEach(a=>{if(r&&!r[a])n[a]=this.shape[a];else{let l=this.shape[a];for(;l instanceof ir;)l=l._def.innerType;n[a]=l}}),new Qe(te(O({},this._def),{shape:()=>n}))}keyof(){return am(ke.objectKeys(this.shape))}};Qe.create=(t,r)=>new Qe(O({shape:()=>t,unknownKeys:"strip",catchall:Er.create(),typeName:oe.ZodObject},ge(r)));Qe.strictCreate=(t,r)=>new Qe(O({shape:()=>t,unknownKeys:"strict",catchall:Er.create(),typeName:oe.ZodObject},ge(r)));Qe.lazycreate=(t,r)=>new Qe(O({shape:t,unknownKeys:"strip",catchall:Er.create(),typeName:oe.ZodObject},ge(r)));var ka=class extends me{_parse(r){let{ctx:n}=this._processInputParams(r),a=this._def.options;function s(l){for(let p of l)if(p.result.status==="valid")return p.result;for(let p of l)if(p.result.status==="dirty")return n.common.issues.push(...p.ctx.common.issues),p.result;let c=l.map(p=>new Pt(p.ctx.common.issues));return j(n,{code:G.invalid_union,unionErrors:c}),ie}if(n.common.async)return Promise.all(a.map(async l=>{let c=te(O({},n),{common:te(O({},n.common),{issues:[]}),parent:null});return{result:await l._parseAsync({data:n.data,path:n.path,parent:c}),ctx:c}})).then(s);{let l,c=[];for(let g of a){let m=te(O({},n),{common:te(O({},n.common),{issues:[]}),parent:null}),h=g._parseSync({data:n.data,path:n.path,parent:m});if(h.status==="valid")return h;h.status==="dirty"&&!l&&(l={result:h,ctx:m}),m.common.issues.length&&c.push(m.common.issues)}if(l)return n.common.issues.push(...l.ctx.common.issues),l.result;let p=c.map(g=>new Pt(g));return j(n,{code:G.invalid_union,unionErrors:p}),ie}}get options(){return this._def.options}};ka.create=(t,r)=>new ka(O({options:t,typeName:oe.ZodUnion},ge(r)));var ln=t=>t instanceof Aa?ln(t.schema):t instanceof Kt?ln(t.innerType()):t instanceof Ea?[t.value]:t instanceof Vr?t.options:t instanceof Oa?ke.objectValues(t.enum):t instanceof Ua?ln(t._def.innerType):t instanceof Ta?[void 0]:t instanceof Sa?[null]:t instanceof ir?[void 0,...ln(t.unwrap())]:t instanceof Wr?[null,...ln(t.unwrap())]:t instanceof mo||t instanceof Ia?ln(t.unwrap()):t instanceof Ba?ln(t._def.innerType):[],bs=class extends me{_parse(r){let{ctx:n}=this._processInputParams(r);if(n.parsedType!==K.object)return j(n,{code:G.invalid_type,expected:K.object,received:n.parsedType}),ie;let a=this.discriminator,s=n.data[a],l=this.optionsMap.get(s);return l?n.common.async?l._parseAsync({data:n.data,path:n.path,parent:n}):l._parseSync({data:n.data,path:n.path,parent:n}):(j(n,{code:G.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[a]}),ie)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(r,n,a){let s=new Map;for(let l of n){let c=ln(l.shape[r]);if(!c.length)throw new Error(`A discriminator value for key \`${r}\` could not be extracted from all schema options`);for(let p of c){if(s.has(p))throw new Error(`Discriminator property ${String(r)} has duplicate value ${String(p)}`);s.set(p,l)}}return new bs(O({typeName:oe.ZodDiscriminatedUnion,discriminator:r,options:n,optionsMap:s},ge(a)))}};function lu(t,r){let n=cn(t),a=cn(r);if(t===r)return{valid:!0,data:t};if(n===K.object&&a===K.object){let s=ke.objectKeys(r),l=ke.objectKeys(t).filter(p=>s.indexOf(p)!==-1),c=O(O({},t),r);for(let p of l){let g=lu(t[p],r[p]);if(!g.valid)return{valid:!1};c[p]=g.data}return{valid:!0,data:c}}else if(n===K.array&&a===K.array){if(t.length!==r.length)return{valid:!1};let s=[];for(let l=0;l{if(ou(l)||ou(c))return ie;let p=lu(l.value,c.value);return p.valid?((iu(l)||iu(c))&&n.dirty(),{status:n.value,value:p.data}):(j(a,{code:G.invalid_intersection_types}),ie)};return a.common.async?Promise.all([this._def.left._parseAsync({data:a.data,path:a.path,parent:a}),this._def.right._parseAsync({data:a.data,path:a.path,parent:a})]).then(([l,c])=>s(l,c)):s(this._def.left._parseSync({data:a.data,path:a.path,parent:a}),this._def.right._parseSync({data:a.data,path:a.path,parent:a}))}};La.create=(t,r,n)=>new La(O({left:t,right:r,typeName:oe.ZodIntersection},ge(n)));var cr=class extends me{_parse(r){let{status:n,ctx:a}=this._processInputParams(r);if(a.parsedType!==K.array)return j(a,{code:G.invalid_type,expected:K.array,received:a.parsedType}),ie;if(a.data.lengththis._def.items.length&&(j(a,{code:G.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),n.dirty());let l=[...a.data].map((c,p)=>{let g=this._def.items[p]||this._def.rest;return g?g._parse(new lr(a,c,a.path,p)):null}).filter(c=>!!c);return a.common.async?Promise.all(l).then(c=>at.mergeArray(n,c)):at.mergeArray(n,l)}get items(){return this._def.items}rest(r){return new cr(te(O({},this._def),{rest:r}))}};cr.create=(t,r)=>{if(!Array.isArray(t))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new cr(O({items:t,typeName:oe.ZodTuple,rest:null},ge(r)))};var Pa=class extends me{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(r){let{status:n,ctx:a}=this._processInputParams(r);if(a.parsedType!==K.object)return j(a,{code:G.invalid_type,expected:K.object,received:a.parsedType}),ie;let s=[],l=this._def.keyType,c=this._def.valueType;for(let p in a.data)s.push({key:l._parse(new lr(a,p,a.path,p)),value:c._parse(new lr(a,a.data[p],a.path,p)),alwaysSet:p in a.data});return a.common.async?at.mergeObjectAsync(n,s):at.mergeObjectSync(n,s)}get element(){return this._def.valueType}static create(r,n,a){return n instanceof me?new Pa(O({keyType:r,valueType:n,typeName:oe.ZodRecord},ge(a))):new Pa(O({keyType:Vt.create(),valueType:r,typeName:oe.ZodRecord},ge(n)))}},ys=class extends me{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(r){let{status:n,ctx:a}=this._processInputParams(r);if(a.parsedType!==K.map)return j(a,{code:G.invalid_type,expected:K.map,received:a.parsedType}),ie;let s=this._def.keyType,l=this._def.valueType,c=[...a.data.entries()].map(([p,g],m)=>({key:s._parse(new lr(a,p,a.path,[m,"key"])),value:l._parse(new lr(a,g,a.path,[m,"value"]))}));if(a.common.async){let p=new Map;return Promise.resolve().then(async()=>{for(let g of c){let m=await g.key,h=await g.value;if(m.status==="aborted"||h.status==="aborted")return ie;(m.status==="dirty"||h.status==="dirty")&&n.dirty(),p.set(m.value,h.value)}return{status:n.value,value:p}})}else{let p=new Map;for(let g of c){let m=g.key,h=g.value;if(m.status==="aborted"||h.status==="aborted")return ie;(m.status==="dirty"||h.status==="dirty")&&n.dirty(),p.set(m.value,h.value)}return{status:n.value,value:p}}}};ys.create=(t,r,n)=>new ys(O({valueType:r,keyType:t,typeName:oe.ZodMap},ge(n)));var pn=class extends me{_parse(r){let{status:n,ctx:a}=this._processInputParams(r);if(a.parsedType!==K.set)return j(a,{code:G.invalid_type,expected:K.set,received:a.parsedType}),ie;let s=this._def;s.minSize!==null&&a.data.sizes.maxSize.value&&(j(a,{code:G.too_big,maximum:s.maxSize.value,type:"set",inclusive:!0,exact:!1,message:s.maxSize.message}),n.dirty());let l=this._def.valueType;function c(g){let m=new Set;for(let h of g){if(h.status==="aborted")return ie;h.status==="dirty"&&n.dirty(),m.add(h.value)}return{status:n.value,value:m}}let p=[...a.data.values()].map((g,m)=>l._parse(new lr(a,g,a.path,m)));return a.common.async?Promise.all(p).then(g=>c(g)):c(p)}min(r,n){return new pn(te(O({},this._def),{minSize:{value:r,message:Y.toString(n)}}))}max(r,n){return new pn(te(O({},this._def),{maxSize:{value:r,message:Y.toString(n)}}))}size(r,n){return this.min(r,n).max(r,n)}nonempty(r){return this.min(1,r)}};pn.create=(t,r)=>new pn(O({valueType:t,minSize:null,maxSize:null,typeName:oe.ZodSet},ge(r)));var qn=class extends me{constructor(){super(...arguments),this.validate=this.implement}_parse(r){let{ctx:n}=this._processInputParams(r);if(n.parsedType!==K.function)return j(n,{code:G.invalid_type,expected:K.function,received:n.parsedType}),ie;function a(p,g){return Fi({data:p,path:n.path,errorMaps:[n.common.contextualErrorMap,n.schemaErrorMap,Hi(),ms].filter(m=>!!m),issueData:{code:G.invalid_arguments,argumentsError:g}})}function s(p,g){return Fi({data:p,path:n.path,errorMaps:[n.common.contextualErrorMap,n.schemaErrorMap,Hi(),ms].filter(m=>!!m),issueData:{code:G.invalid_return_type,returnTypeError:g}})}let l={errorMap:n.common.contextualErrorMap},c=n.data;if(this._def.returns instanceof Vn){let p=this;return At(async function(...g){let m=new Pt([]),h=await p._def.args.parseAsync(g,l).catch(v=>{throw m.addIssue(a(g,v)),m}),b=await Reflect.apply(c,this,h);return await p._def.returns._def.type.parseAsync(b,l).catch(v=>{throw m.addIssue(s(b,v)),m})})}else{let p=this;return At(function(...g){let m=p._def.args.safeParse(g,l);if(!m.success)throw new Pt([a(g,m.error)]);let h=Reflect.apply(c,this,m.data),b=p._def.returns.safeParse(h,l);if(!b.success)throw new Pt([s(h,b.error)]);return b.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...r){return new qn(te(O({},this._def),{args:cr.create(r).rest(un.create())}))}returns(r){return new qn(te(O({},this._def),{returns:r}))}implement(r){return this.parse(r)}strictImplement(r){return this.parse(r)}static create(r,n,a){return new qn(O({args:r||cr.create([]).rest(un.create()),returns:n||un.create(),typeName:oe.ZodFunction},ge(a)))}},Aa=class extends me{get schema(){return this._def.getter()}_parse(r){let{ctx:n}=this._processInputParams(r);return this._def.getter()._parse({data:n.data,path:n.path,parent:n})}};Aa.create=(t,r)=>new Aa(O({getter:t,typeName:oe.ZodLazy},ge(r)));var Ea=class extends me{_parse(r){if(r.data!==this._def.value){let n=this._getOrReturnCtx(r);return j(n,{received:n.data,code:G.invalid_literal,expected:this._def.value}),ie}return{status:"valid",value:r.data}}get value(){return this._def.value}};Ea.create=(t,r)=>new Ea(O({value:t,typeName:oe.ZodLiteral},ge(r)));function am(t,r){return new Vr(O({values:t,typeName:oe.ZodEnum},ge(r)))}var Vr=class extends me{constructor(){super(...arguments),uo.set(this,void 0)}_parse(r){if(typeof r.data!="string"){let n=this._getOrReturnCtx(r),a=this._def.values;return j(n,{expected:ke.joinValues(a),received:n.parsedType,code:G.invalid_type}),ie}if(Qi(this,uo,"f")||em(this,uo,new Set(this._def.values),"f"),!Qi(this,uo,"f").has(r.data)){let n=this._getOrReturnCtx(r),a=this._def.values;return j(n,{received:n.data,code:G.invalid_enum_value,options:a}),ie}return At(r.data)}get options(){return this._def.values}get enum(){let r={};for(let n of this._def.values)r[n]=n;return r}get Values(){let r={};for(let n of this._def.values)r[n]=n;return r}get Enum(){let r={};for(let n of this._def.values)r[n]=n;return r}extract(r,n=this._def){return Vr.create(r,O(O({},this._def),n))}exclude(r,n=this._def){return Vr.create(this.options.filter(a=>!r.includes(a)),O(O({},this._def),n))}};uo=new WeakMap;Vr.create=am;var Oa=class extends me{constructor(){super(...arguments),po.set(this,void 0)}_parse(r){let n=ke.getValidEnumValues(this._def.values),a=this._getOrReturnCtx(r);if(a.parsedType!==K.string&&a.parsedType!==K.number){let s=ke.objectValues(n);return j(a,{expected:ke.joinValues(s),received:a.parsedType,code:G.invalid_type}),ie}if(Qi(this,po,"f")||em(this,po,new Set(ke.getValidEnumValues(this._def.values)),"f"),!Qi(this,po,"f").has(r.data)){let s=ke.objectValues(n);return j(a,{received:a.data,code:G.invalid_enum_value,options:s}),ie}return At(r.data)}get enum(){return this._def.values}};po=new WeakMap;Oa.create=(t,r)=>new Oa(O({values:t,typeName:oe.ZodNativeEnum},ge(r)));var Vn=class extends me{unwrap(){return this._def.type}_parse(r){let{ctx:n}=this._processInputParams(r);if(n.parsedType!==K.promise&&n.common.async===!1)return j(n,{code:G.invalid_type,expected:K.promise,received:n.parsedType}),ie;let a=n.parsedType===K.promise?n.data:Promise.resolve(n.data);return At(a.then(s=>this._def.type.parseAsync(s,{path:n.path,errorMap:n.common.contextualErrorMap})))}};Vn.create=(t,r)=>new Vn(O({type:t,typeName:oe.ZodPromise},ge(r)));var Kt=class extends me{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===oe.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(r){let{status:n,ctx:a}=this._processInputParams(r),s=this._def.effect||null,l={addIssue:c=>{j(a,c),c.fatal?n.abort():n.dirty()},get path(){return a.path}};if(l.addIssue=l.addIssue.bind(l),s.type==="preprocess"){let c=s.transform(a.data,l);if(a.common.async)return Promise.resolve(c).then(async p=>{if(n.value==="aborted")return ie;let g=await this._def.schema._parseAsync({data:p,path:a.path,parent:a});return g.status==="aborted"?ie:g.status==="dirty"||n.value==="dirty"?gs(g.value):g});{if(n.value==="aborted")return ie;let p=this._def.schema._parseSync({data:c,path:a.path,parent:a});return p.status==="aborted"?ie:p.status==="dirty"||n.value==="dirty"?gs(p.value):p}}if(s.type==="refinement"){let c=p=>{let g=s.refinement(p,l);if(a.common.async)return Promise.resolve(g);if(g instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return p};if(a.common.async===!1){let p=this._def.schema._parseSync({data:a.data,path:a.path,parent:a});return p.status==="aborted"?ie:(p.status==="dirty"&&n.dirty(),c(p.value),{status:n.value,value:p.value})}else return this._def.schema._parseAsync({data:a.data,path:a.path,parent:a}).then(p=>p.status==="aborted"?ie:(p.status==="dirty"&&n.dirty(),c(p.value).then(()=>({status:n.value,value:p.value}))))}if(s.type==="transform")if(a.common.async===!1){let c=this._def.schema._parseSync({data:a.data,path:a.path,parent:a});if(!xa(c))return c;let p=s.transform(c.value,l);if(p instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:n.value,value:p}}else return this._def.schema._parseAsync({data:a.data,path:a.path,parent:a}).then(c=>xa(c)?Promise.resolve(s.transform(c.value,l)).then(p=>({status:n.value,value:p})):c);ke.assertNever(s)}};Kt.create=(t,r,n)=>new Kt(O({schema:t,typeName:oe.ZodEffects,effect:r},ge(n)));Kt.createWithPreprocess=(t,r,n)=>new Kt(O({schema:r,effect:{type:"preprocess",transform:t},typeName:oe.ZodEffects},ge(n)));var ir=class extends me{_parse(r){return this._getType(r)===K.undefined?At(void 0):this._def.innerType._parse(r)}unwrap(){return this._def.innerType}};ir.create=(t,r)=>new ir(O({innerType:t,typeName:oe.ZodOptional},ge(r)));var Wr=class extends me{_parse(r){return this._getType(r)===K.null?At(null):this._def.innerType._parse(r)}unwrap(){return this._def.innerType}};Wr.create=(t,r)=>new Wr(O({innerType:t,typeName:oe.ZodNullable},ge(r)));var Ua=class extends me{_parse(r){let{ctx:n}=this._processInputParams(r),a=n.data;return n.parsedType===K.undefined&&(a=this._def.defaultValue()),this._def.innerType._parse({data:a,path:n.path,parent:n})}removeDefault(){return this._def.innerType}};Ua.create=(t,r)=>new Ua(O({innerType:t,typeName:oe.ZodDefault,defaultValue:typeof r.default=="function"?r.default:()=>r.default},ge(r)));var Ba=class extends me{_parse(r){let{ctx:n}=this._processInputParams(r),a=te(O({},n),{common:te(O({},n.common),{issues:[]})}),s=this._def.innerType._parse({data:a.data,path:a.path,parent:O({},a)});return go(s)?s.then(l=>({status:"valid",value:l.status==="valid"?l.value:this._def.catchValue({get error(){return new Pt(a.common.issues)},input:a.data})})):{status:"valid",value:s.status==="valid"?s.value:this._def.catchValue({get error(){return new Pt(a.common.issues)},input:a.data})}}removeCatch(){return this._def.innerType}};Ba.create=(t,r)=>new Ba(O({innerType:t,typeName:oe.ZodCatch,catchValue:typeof r.catch=="function"?r.catch:()=>r.catch},ge(r)));var vs=class extends me{_parse(r){if(this._getType(r)!==K.nan){let a=this._getOrReturnCtx(r);return j(a,{code:G.invalid_type,expected:K.nan,received:a.parsedType}),ie}return{status:"valid",value:r.data}}};vs.create=t=>new vs(O({typeName:oe.ZodNaN},ge(t)));var xy=Symbol("zod_brand"),mo=class extends me{_parse(r){let{ctx:n}=this._processInputParams(r),a=n.data;return this._def.type._parse({data:a,path:n.path,parent:n})}unwrap(){return this._def.type}},Ra=class extends me{_parse(r){let{status:n,ctx:a}=this._processInputParams(r);if(a.common.async)return(async()=>{let l=await this._def.in._parseAsync({data:a.data,path:a.path,parent:a});return l.status==="aborted"?ie:l.status==="dirty"?(n.dirty(),gs(l.value)):this._def.out._parseAsync({data:l.value,path:a.path,parent:a})})();{let s=this._def.in._parseSync({data:a.data,path:a.path,parent:a});return s.status==="aborted"?ie:s.status==="dirty"?(n.dirty(),{status:"dirty",value:s.value}):this._def.out._parseSync({data:s.value,path:a.path,parent:a})}}static create(r,n){return new Ra({in:r,out:n,typeName:oe.ZodPipeline})}},Ia=class extends me{_parse(r){let n=this._def.innerType._parse(r),a=s=>(xa(s)&&(s.value=Object.freeze(s.value)),s);return go(n)?n.then(s=>a(s)):a(n)}unwrap(){return this._def.innerType}};Ia.create=(t,r)=>new Ia(O({innerType:t,typeName:oe.ZodReadonly},ge(r)));function sm(t,r={},n){return t?jn.create().superRefine((a,s)=>{var l,c;if(!t(a)){let p=typeof r=="function"?r(a):typeof r=="string"?{message:r}:r,g=(c=(l=p.fatal)!==null&&l!==void 0?l:n)!==null&&c!==void 0?c:!0,m=typeof p=="string"?{message:p}:p;s.addIssue(te(O({code:"custom"},m),{fatal:g}))}}):jn.create()}var My={object:Qe.lazycreate},oe;(function(t){t.ZodString="ZodString",t.ZodNumber="ZodNumber",t.ZodNaN="ZodNaN",t.ZodBigInt="ZodBigInt",t.ZodBoolean="ZodBoolean",t.ZodDate="ZodDate",t.ZodSymbol="ZodSymbol",t.ZodUndefined="ZodUndefined",t.ZodNull="ZodNull",t.ZodAny="ZodAny",t.ZodUnknown="ZodUnknown",t.ZodNever="ZodNever",t.ZodVoid="ZodVoid",t.ZodArray="ZodArray",t.ZodObject="ZodObject",t.ZodUnion="ZodUnion",t.ZodDiscriminatedUnion="ZodDiscriminatedUnion",t.ZodIntersection="ZodIntersection",t.ZodTuple="ZodTuple",t.ZodRecord="ZodRecord",t.ZodMap="ZodMap",t.ZodSet="ZodSet",t.ZodFunction="ZodFunction",t.ZodLazy="ZodLazy",t.ZodLiteral="ZodLiteral",t.ZodEnum="ZodEnum",t.ZodEffects="ZodEffects",t.ZodNativeEnum="ZodNativeEnum",t.ZodOptional="ZodOptional",t.ZodNullable="ZodNullable",t.ZodDefault="ZodDefault",t.ZodCatch="ZodCatch",t.ZodPromise="ZodPromise",t.ZodBranded="ZodBranded",t.ZodPipeline="ZodPipeline",t.ZodReadonly="ZodReadonly"})(oe||(oe={}));var Ty=(t,r={message:`Input not instance of ${t.name}`})=>sm(n=>n instanceof t,r),om=Vt.create,im=qr.create,Sy=vs.create,ky=jr.create,lm=Ma.create,Ly=dn.create,Py=fs.create,Ay=Ta.create,Ey=Sa.create,Oy=jn.create,Uy=un.create,By=Er.create,Ry=hs.create,Iy=Wt.create,Ny=Qe.create,$y=Qe.strictCreate,_y=ka.create,Dy=bs.create,Gy=La.create,Hy=cr.create,Fy=Pa.create,Qy=ys.create,qy=pn.create,jy=qn.create,Vy=Aa.create,Wy=Ea.create,Ky=Vr.create,zy=Oa.create,Xy=Vn.create,Yg=Kt.create,Zy=ir.create,Yy=Wr.create,Jy=Kt.createWithPreprocess,ev=Ra.create,tv=()=>om().optional(),rv=()=>im().optional(),nv=()=>lm().optional(),av={string:t=>Vt.create(te(O({},t),{coerce:!0})),number:t=>qr.create(te(O({},t),{coerce:!0})),boolean:t=>Ma.create(te(O({},t),{coerce:!0})),bigint:t=>jr.create(te(O({},t),{coerce:!0})),date:t=>dn.create(te(O({},t),{coerce:!0}))},sv=ie,y=Object.freeze({__proto__:null,defaultErrorMap:ms,setErrorMap:Jb,getErrorMap:Hi,makeIssue:Fi,EMPTY_PATH:ey,addIssueToContext:j,ParseStatus:at,INVALID:ie,DIRTY:gs,OK:At,isAborted:ou,isDirty:iu,isValid:xa,isAsync:go,get util(){return ke},get objectUtil(){return su},ZodParsedType:K,getParsedType:cn,ZodType:me,datetimeRegex:nm,ZodString:Vt,ZodNumber:qr,ZodBigInt:jr,ZodBoolean:Ma,ZodDate:dn,ZodSymbol:fs,ZodUndefined:Ta,ZodNull:Sa,ZodAny:jn,ZodUnknown:un,ZodNever:Er,ZodVoid:hs,ZodArray:Wt,ZodObject:Qe,ZodUnion:ka,ZodDiscriminatedUnion:bs,ZodIntersection:La,ZodTuple:cr,ZodRecord:Pa,ZodMap:ys,ZodSet:pn,ZodFunction:qn,ZodLazy:Aa,ZodLiteral:Ea,ZodEnum:Vr,ZodNativeEnum:Oa,ZodPromise:Vn,ZodEffects:Kt,ZodTransformer:Kt,ZodOptional:ir,ZodNullable:Wr,ZodDefault:Ua,ZodCatch:Ba,ZodNaN:vs,BRAND:xy,ZodBranded:mo,ZodPipeline:Ra,ZodReadonly:Ia,custom:sm,Schema:me,ZodSchema:me,late:My,get ZodFirstPartyTypeKind(){return oe},coerce:av,any:Oy,array:Iy,bigint:ky,boolean:lm,date:Ly,discriminatedUnion:Dy,effect:Yg,enum:Ky,function:jy,instanceof:Ty,intersection:Gy,lazy:Vy,literal:Wy,map:Qy,nan:Sy,nativeEnum:zy,never:By,null:Ey,nullable:Yy,number:im,object:Ny,oboolean:nv,onumber:rv,optional:Zy,ostring:tv,pipeline:ev,preprocess:Jy,promise:Xy,record:Fy,set:qy,strictObject:$y,string:om,symbol:Py,transformer:Yg,tuple:Hy,undefined:Ay,union:_y,unknown:Uy,void:Ry,NEVER:sv,ZodIssueCode:G,quotelessJson:Yb,ZodError:Pt});var fe=class extends In{constructor(n,a){var c,p,g;let s=u.t(`octeract.data.${a}.name`),l=u.t(`octeract.data.${a}.description`);super(te(O({},n),{name:s,description:l}));this.octeractsInvested=0;this.costFormula=n.costFormula,this.octeractsInvested=(c=n.octeractsInvested)!=null?c:0,this.qualityOfLife=(p=n.qualityOfLife)!=null?p:!1,this.cacheUpdates=(g=n.cacheUpdates)!=null?g:void 0}getCostTNL(){return this.level===this.maxLevel?0:this.costFormula(this.level,this.costPerLevel)}async buyLevel(n){let a=0,s=1,l=e.wowOcteracts;if(n.shiftKey){s=1e6;let c=Number(await Ee(`${u.t("octeract.buyLevel.buyPrompt",{n:d(e.wowOcteracts,0,!0)})}`));if(isNaN(c)||!isFinite(c)||!Number.isInteger(c))return P(u.t("general.validation.finite"));if(c===-1)l=e.wowOcteracts;else{if(c<=0)return P(u.t("octeract.buyLevel.cancelPurchase"));l=c}l=Math.min(e.wowOcteracts,l)}if(this.maxLevel>0&&(s=Math.min(s,this.maxLevel-this.level)),s===0)return P(u.t("octeract.buyLevel.alreadyMax"));for(;s>0;){let c=this.getCostTNL();if(e.wowOcteracts1)return P(`${u.t("octeract.buyLevel.multiBuy",{n:d(a)})}`);this.updateCaches(),this.updateUpgradeHTML()}toString(){let n=this.getCostTNL(),a=this.maxLevel===-1?"":`/${d(this.maxLevel,0,!0)}`,s=this.maxLevel===this.level,l=s?"plum":"white",c=this.freeLevels>0?` [+${d(this.freeLevels,1,!0)}]`:"";this.freeLevels>this.level&&(c=`${c}${u.t("general.softCapped")}`);let p=n<=e.wowOcteracts,g="";if(!s&&!p){let h=Kr();g=h>0?zt((n-e.wowOcteracts)/h):`${u.t("general.infinity")}`}let m=s?` ${u.t("general.maxed")}`:p?` ${u.t("general.affordable")}`:` ${u.t("octeract.toString.becomeAffordable",{n:g})}`;return`${this.name} ${this.description} ${u.t("general.level")} ${d(this.level,0,!0)}${a}${c} ${this.getEffect().desc} ${u.t("octeract.toString.costNextLevel")} ${d(n,2,!0,!0,!0)} Octeracts${m} - ${u.t("general.spent")} Octeracts: ${d(this.octeractsInvested,2,!0,!0,!0)}`}updateUpgradeHTML(){i("singularityOcteractsMultiline").innerHTML=this.toString(),i("octeractAmount").innerHTML=u.t("octeract.amount",{octeracts:d(e.wowOcteracts,2,!0,!0,!0)})}computeFreeLevelSoftcap(){let n=1+.003*e.cubeUpgrades[78];return this.freeLevels*n}actualTotalLevels(){if((e.singularityChallenges.noOcteracts.enabled||e.singularityChallenges.sadisticPrequel.enabled)&&!this.qualityOfLife)return 0;let n=this.computeFreeLevelSoftcap();return this.level>=n?n+this.level:2*Math.sqrt(n*this.level)}getEffect(){return this.effect(this.actualTotalLevels())}refund(){e.wowOcteracts+=this.octeractsInvested,this.level=0,this.octeractsInvested=0}updateCaches(){if(this.cacheUpdates!==void 0)for(let n of this.cacheUpdates)n()}},le={octeractStarter:{costFormula:(t,r)=>r*(t+1),maxLevel:1,costPerLevel:1e-15,effect:t=>({bonus:t>0,get desc(){return u.t("octeract.data.octeractStarter.effect",{n:t>0?"":"not"})}})},octeractGain:{costFormula:(t,r)=>r*(Math.pow(t+1,6)-Math.pow(t,6)),maxLevel:1e8,costPerLevel:1e-8,effect:t=>({bonus:1+.011*t,get desc(){return u.t("octeract.data.octeractGain.effect",{n:d(t,0,!0)})}})},octeractGain2:{costFormula:(t,r)=>r*Math.pow(10,Math.pow(t,.5)/3),maxLevel:-1,costPerLevel:1e10,effect:t=>({bonus:1+.01*t,get desc(){return u.t("octeract.data.octeractGain2.effect",{n:d(t,0,!0)})}})},octeractQuarkGain:{costFormula:(t,r)=>{if(t<1e3)return r*(Math.pow(t+1,7)-Math.pow(t,7));{let n=t>=1e4?Math.pow(10,(t-1e4)/250):1,a=t>=15e3?Math.pow(10,(t-15e3)/250):1;return r*(Math.pow(1001,7)-Math.pow(1e3,7))*Math.pow(10,t/1e3)*n*a}},maxLevel:2e4,costPerLevel:1e-7,effect:t=>({bonus:1+.011*t,get desc(){return u.t("octeract.data.octeractQuarkGain.effect",{n:d(1.1*t,0,!0)})}})},octeractQuarkGain2:{costFormula:(t,r)=>r*Math.pow(1e20,t),maxLevel:5,costPerLevel:1e22,effect:t=>({bonus:t>0,get desc(){return u.t("octeract.data.octeractQuarkGain2.effect",{n:t>0?"":"NOT"})}})},octeractCorruption:{costFormula:(t,r)=>r*Math.pow(10,t*10),maxLevel:2,costPerLevel:10,effect:t=>({bonus:t,get desc(){return u.t("octeract.data.octeractCorruption.effect",{n:t})}})},octeractGQCostReduce:{costFormula:(t,r)=>r*Math.pow(2,t),maxLevel:50,costPerLevel:1e-9,effect:t=>({bonus:1-t/100,get desc(){return u.t("octeract.data.octeractGQCostReduce.effect",{n:t})}})},octeractExportQuarks:{costFormula:(t,r)=>r*Math.pow(t+1,3),maxLevel:100,costPerLevel:1,effect:t=>({bonus:4*t/10+1,get desc(){return u.t("octeract.data.octeractExportQuarks.effect",{n:d(40*t,0,!0)})}})},octeractImprovedDaily:{costFormula:(t,r)=>r*Math.pow(1.6,t),maxLevel:50,costPerLevel:.001,effect:t=>({bonus:t,get desc(){return u.t("octeract.data.octeractImprovedDaily.effect",{n:t})}}),qualityOfLife:!0},octeractImprovedDaily2:{costFormula:(t,r)=>r*Math.pow(2,t),maxLevel:50,costPerLevel:.01,effect:t=>({bonus:1+.01*t,get desc(){return u.t("octeract.data.octeractImprovedDaily2.effect",{n:t})}}),qualityOfLife:!0},octeractImprovedDaily3:{costFormula:(t,r)=>r*Math.pow(20,t),maxLevel:-1,costPerLevel:1e20,effect:t=>({bonus:t,get desc(){return u.t("octeract.data.octeractImprovedDaily3.effect",{n:`${t} +${.5*t}%`})}}),qualityOfLife:!0},octeractImprovedQuarkHept:{costFormula:(t,r)=>r*Math.pow(1e6,t),maxLevel:3,costPerLevel:1/10,effect:t=>({bonus:t/100,get desc(){return u.t("octeract.data.octeractImprovedQuarkHept.effect",{n:d(t/100,2,!0)})}})},octeractImprovedGlobalSpeed:{costFormula:(t,r)=>r*Math.pow(t+1,3),maxLevel:1e3,costPerLevel:1e-5,effect:t=>({bonus:t/100,get desc(){return u.t("octeract.data.octeractImprovedGlobalSpeed.effect",{n:d(t,0,!0)})}})},octeractImprovedAscensionSpeed:{costFormula:(t,r)=>r*Math.pow(1e9,t/100),maxLevel:100,costPerLevel:100,effect:t=>({bonus:t/2e3,get desc(){return u.t("octeract.data.octeractImprovedAscensionSpeed.effect",{n:d(t/20,2,!0)})}})},octeractImprovedAscensionSpeed2:{costFormula:(t,r)=>r*Math.pow(1e12,t/250),maxLevel:250,costPerLevel:1e5,effect:t=>({bonus:t/2e3,get desc(){return u.t("octeract.data.octeractImprovedAscensionSpeed2.effect",{n:d(t/50,2,!0)})}})},octeractImprovedFree:{costFormula:(t,r)=>r*Math.pow(t+1,3),maxLevel:1,costPerLevel:100,effect:t=>({bonus:t>0,get desc(){return u.t("octeract.data.octeractImprovedFree.effect",{n:t>0?"":"NOT"})}})},octeractImprovedFree2:{costFormula:(t,r)=>r*Math.pow(t+1,3),maxLevel:1,costPerLevel:1e7,effect:t=>({bonus:.05*t,get desc(){return u.t("octeract.data.octeractImprovedFree2.effect",{n:d(t/20,2,!0)})}})},octeractImprovedFree3:{costFormula:(t,r)=>r*Math.pow(t+1,3),maxLevel:1,costPerLevel:1e17,effect:t=>({bonus:.05*t,get desc(){return u.t("octeract.data.octeractImprovedFree3.effect",{n:d(t/20,2,!0)})}})},octeractImprovedFree4:{costFormula:(t,r)=>r*Math.pow(1e20,t/40),maxLevel:40,costPerLevel:1e20,effect:t=>({bonus:.001*t+(t>0?.01:0),get desc(){return u.t("octeract.data.octeractImprovedFree4.effect",{n:d(.001*t+(t>0?.01:0),3,!0)})}})},octeractSingUpgradeCap:{costFormula:(t,r)=>r*Math.pow(1e3,t),maxLevel:10,costPerLevel:1e10,effect:t=>({bonus:t,get desc(){return u.t("octeract.data.octeractSingUpgradeCap.effect",{n:t})}}),qualityOfLife:!0},octeractOfferings1:{costFormula:(t,r)=>t<25?r*Math.pow(t+1,5):r*1e15*Math.pow(10,t/25-1),maxLevel:-1,costPerLevel:1e-15,effect:t=>({bonus:1+.01*t,get desc(){return u.t("octeract.data.octeractOfferings1.effect",{n:d(t)})}})},octeractObtainium1:{costFormula:(t,r)=>t<25?r*Math.pow(t+1,5):r*1e15*Math.pow(10,t/25-1),maxLevel:-1,costPerLevel:1e-15,effect:t=>({bonus:1+.01*t,get desc(){return u.t("octeract.data.octeractObtainium1.effect",{n:d(t)})}})},octeractAscensions:{costFormula:(t,r)=>r*Math.pow(t+1,3),maxLevel:1e6,costPerLevel:1,effect:t=>({bonus:(1+t/100)*(1+2*Math.floor(t/10)/100),get desc(){return u.t("octeract.data.octeractAscensions.effect",{n:d((100+t)*(1+2*Math.floor(t/10)/100)-100,1,!0)})}})},octeractAscensions2:{costFormula:(t,r)=>r*Math.pow(10,Math.pow(t,.5)/3),maxLevel:-1,costPerLevel:1e12,effect:t=>({bonus:(1+t/100)*(1+2*Math.floor(t/10)/100),get desc(){return u.t("octeract.data.octeractAscensions2.effect",{n:d((100+t)*(1+2*Math.floor(t/10)/100)-100,1,!0)})}})},octeractAscensionsOcteractGain:{costFormula:(t,r)=>r*Math.pow(40,t),maxLevel:-1,costPerLevel:1e3,effect:t=>({bonus:t/100,get desc(){return u.t("octeract.data.octeractAscensionsOcteractGain.effect",{n:d(t,1,!0)})}})},octeractFastForward:{costFormula:(t,r)=>r*Math.pow(1e8,t),maxLevel:2,costPerLevel:1e8,effect:t=>({bonus:t,get desc(){return u.t("octeract.data.octeractFastForward.effect",{n100:100*t,n:t})}})},octeractAutoPotionSpeed:{costFormula:(t,r)=>r*Math.pow(10,t),maxLevel:-1,costPerLevel:1e-10,effect:t=>({bonus:1+4*t/100,get desc(){return u.t("octeract.data.octeractAutoPotionSpeed.effect",{n:4*t})}})},octeractAutoPotionEfficiency:{costFormula:(t,r)=>r*Math.pow(10,t),maxLevel:100,costPerLevel:1e-10*Math.pow(10,.5),effect:t=>({bonus:1+2*t/100,get desc(){return u.t("octeract.data.octeractAutoPotionEfficiency.effect",{n:2*t})}})},octeractOneMindImprover:{costFormula:(t,r)=>{let n=t>=10?Math.pow(1e3,t-10):1;return r*Math.pow(1e5,t)*n},maxLevel:16,costPerLevel:1e25,effect:t=>({bonus:.55+t/150,get desc(){return u.t("octeract.data.octeractOneMindImprover.effect",{n:d(.55+t/150,3,!0)})}}),qualityOfLife:!0},octeractAmbrosiaLuck:{costFormula:(t,r)=>{let n=t+1;return r*(Math.pow(10,n)-Math.pow(10,n-1))},maxLevel:-1,costPerLevel:1e60/9,effect:t=>({bonus:4*t,get desc(){return u.t("octeract.data.octeractAmbrosiaLuck.effect",{n:d(4*t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaLuck=Ge().value}]},octeractAmbrosiaLuck2:{costFormula:(t,r)=>r*(Math.pow(t+1,6)-Math.pow(t,6)),maxLevel:30,costPerLevel:1,effect:t=>({bonus:2*t,get desc(){return u.t("octeract.data.octeractAmbrosiaLuck2.effect",{n:d(2*t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaLuck=Ge().value}]},octeractAmbrosiaLuck3:{costFormula:(t,r)=>r*(Math.pow(t+1,8)-Math.pow(t,8)),maxLevel:30,costPerLevel:1e30,effect:t=>({bonus:3*t,get desc(){return u.t("octeract.data.octeractAmbrosiaLuck3.effect",{n:d(3*t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaLuck=Ge().value}]},octeractAmbrosiaLuck4:{costFormula:(t,r)=>{let n=t+1;return r*(Math.pow(3,n)-Math.pow(3,n-1))},maxLevel:50,costPerLevel:1e70/2,effect:t=>({bonus:5*t,get desc(){return u.t("octeract.data.octeractAmbrosiaLuck4.effect",{n:d(5*t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaLuck=Ge().value}]},octeractAmbrosiaGeneration:{costFormula:(t,r)=>{let n=t+1;return r*(Math.pow(10,n)-Math.pow(10,n-1))},maxLevel:-1,costPerLevel:1e60/9,effect:t=>({bonus:1+t/100,get desc(){return u.t("octeract.data.octeractAmbrosiaGeneration.effect",{n:d(t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value}]},octeractAmbrosiaGeneration2:{costFormula:(t,r)=>r*(Math.pow(t+1,6)-Math.pow(t,6)),maxLevel:20,costPerLevel:1,effect:t=>({bonus:1+t/100,get desc(){return u.t("octeract.data.octeractAmbrosiaGeneration2.effect",{n:d(t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value}]},octeractAmbrosiaGeneration3:{costFormula:(t,r)=>r*(Math.pow(t+1,8)-Math.pow(t,8)),maxLevel:35,costPerLevel:1e30,effect:t=>({bonus:1+t/100,get desc(){return u.t("octeract.data.octeractAmbrosiaGeneration3.effect",{n:d(t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value}]},octeractAmbrosiaGeneration4:{costFormula:(t,r)=>{let n=t+1;return r*(Math.pow(3,n)-Math.pow(3,n-1))},maxLevel:50,costPerLevel:1e70/2,effect:t=>({bonus:1+2*t/100,get desc(){return u.t("octeract.data.octeractAmbrosiaGeneration4.effect",{n:d(2*t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value}]}};var ir=class{constructor(r,n){var l,c,p,g,m;let a=u.t(`singularityChallenge.data.${n}.name`),s=u.t(`singularityChallenge.data.${n}.description`);this.name=a,this.description=s,this.baseReq=r.baseReq,this.completions=(l=r.completions)!=null?l:0,this.maxCompletions=r.maxCompletions,this.unlockSingularity=r.unlockSingularity,this.HTMLTag=r.HTMLTag,this.highestSingularityCompleted=(c=r.highestSingularityCompleted)!=null?c:0,this.enabled=(p=r.enabled)!=null?p:!1,this.resetTime=(g=r.resetTime)!=null?g:!1,this.singularityRequirement=r.singularityRequirement,this.effect=r.effect,this.scalingrewardcount=r.scalingrewardcount,this.uniquerewardcount=r.uniquerewardcount,this.updateIconHTML(),this.updateChallengeCompletions(),this.cacheUpdates=(m=r.cacheUpdates)!=null?m:void 0}computeSingularityRquirement(){return this.singularityRequirement(this.baseReq,this.completions)}updateChallengeCompletions(){let r=0;for(;this.singularityRequirement(this.baseReq,r)<=this.highestSingularityCompleted;)r+=1;this.completions=Math.min(this.maxCompletions,r)}challengeEntryHandler(){return this.enabled?this.exitChallenge(e.runelevels[6]>0):this.enableChallenge()}async enableChallenge(){if(e.highestSingularityCount${u.t("general.enabled")}`:"";return`${this.name} ${n} + ${u.t("general.spent")} Octeracts: ${d(this.octeractsInvested,2,!0,!0,!0)}`}updateUpgradeHTML(){i("singularityOcteractsMultiline").innerHTML=this.toString(),i("octeractAmount").innerHTML=u.t("octeract.amount",{octeracts:d(e.wowOcteracts,2,!0,!0,!0)})}computeFreeLevelSoftcap(){let n=1+.003*e.cubeUpgrades[78];return this.freeLevels*n}actualTotalLevels(){if((e.singularityChallenges.noOcteracts.enabled||e.singularityChallenges.sadisticPrequel.enabled)&&!this.qualityOfLife)return 0;let n=this.computeFreeLevelSoftcap();return this.level>=n?n+this.level:2*Math.sqrt(n*this.level)}getEffect(){return this.effect(this.actualTotalLevels())}refund(){e.wowOcteracts+=this.octeractsInvested,this.level=0,this.octeractsInvested=0}updateCaches(){if(this.cacheUpdates!==void 0)for(let n of this.cacheUpdates)n()}},le={octeractStarter:{costFormula:(t,r)=>r*(t+1),maxLevel:1,costPerLevel:1e-15,effect:t=>({bonus:t>0,get desc(){return u.t("octeract.data.octeractStarter.effect",{n:t>0?"":"not"})}})},octeractGain:{costFormula:(t,r)=>r*(Math.pow(t+1,6)-Math.pow(t,6)),maxLevel:1e8,costPerLevel:1e-8,effect:t=>({bonus:1+.011*t,get desc(){return u.t("octeract.data.octeractGain.effect",{n:d(t,0,!0)})}})},octeractGain2:{costFormula:(t,r)=>r*Math.pow(10,Math.pow(t,.5)/3),maxLevel:-1,costPerLevel:1e10,effect:t=>({bonus:1+.01*t,get desc(){return u.t("octeract.data.octeractGain2.effect",{n:d(t,0,!0)})}})},octeractQuarkGain:{costFormula:(t,r)=>{if(t<1e3)return r*(Math.pow(t+1,7)-Math.pow(t,7));{let n=t>=1e4?Math.pow(10,(t-1e4)/250):1,a=t>=15e3?Math.pow(10,(t-15e3)/250):1;return r*(Math.pow(1001,7)-Math.pow(1e3,7))*Math.pow(10,t/1e3)*n*a}},maxLevel:2e4,costPerLevel:1e-7,effect:t=>({bonus:1+.011*t,get desc(){return u.t("octeract.data.octeractQuarkGain.effect",{n:d(1.1*t,0,!0)})}})},octeractQuarkGain2:{costFormula:(t,r)=>r*Math.pow(1e20,t),maxLevel:5,costPerLevel:1e22,effect:t=>({bonus:t>0,get desc(){return u.t("octeract.data.octeractQuarkGain2.effect",{n:t>0?"":"NOT"})}})},octeractCorruption:{costFormula:(t,r)=>r*Math.pow(10,t*10),maxLevel:2,costPerLevel:10,effect:t=>({bonus:t,get desc(){return u.t("octeract.data.octeractCorruption.effect",{n:t})}})},octeractGQCostReduce:{costFormula:(t,r)=>r*Math.pow(2,t),maxLevel:50,costPerLevel:1e-9,effect:t=>({bonus:1-t/100,get desc(){return u.t("octeract.data.octeractGQCostReduce.effect",{n:t})}})},octeractExportQuarks:{costFormula:(t,r)=>r*Math.pow(t+1,3),maxLevel:100,costPerLevel:1,effect:t=>({bonus:4*t/10+1,get desc(){return u.t("octeract.data.octeractExportQuarks.effect",{n:d(40*t,0,!0)})}})},octeractImprovedDaily:{costFormula:(t,r)=>r*Math.pow(1.6,t),maxLevel:50,costPerLevel:.001,effect:t=>({bonus:t,get desc(){return u.t("octeract.data.octeractImprovedDaily.effect",{n:t})}}),qualityOfLife:!0},octeractImprovedDaily2:{costFormula:(t,r)=>r*Math.pow(2,t),maxLevel:50,costPerLevel:.01,effect:t=>({bonus:1+.01*t,get desc(){return u.t("octeract.data.octeractImprovedDaily2.effect",{n:t})}}),qualityOfLife:!0},octeractImprovedDaily3:{costFormula:(t,r)=>r*Math.pow(20,t),maxLevel:-1,costPerLevel:1e20,effect:t=>({bonus:t,get desc(){return u.t("octeract.data.octeractImprovedDaily3.effect",{n:`${t} +${.5*t}%`})}}),qualityOfLife:!0},octeractImprovedQuarkHept:{costFormula:(t,r)=>r*Math.pow(1e6,t),maxLevel:3,costPerLevel:1/10,effect:t=>({bonus:t/100,get desc(){return u.t("octeract.data.octeractImprovedQuarkHept.effect",{n:d(t/100,2,!0)})}})},octeractImprovedGlobalSpeed:{costFormula:(t,r)=>r*Math.pow(t+1,3),maxLevel:1e3,costPerLevel:1e-5,effect:t=>({bonus:t/100,get desc(){return u.t("octeract.data.octeractImprovedGlobalSpeed.effect",{n:d(t,0,!0)})}})},octeractImprovedAscensionSpeed:{costFormula:(t,r)=>r*Math.pow(1e9,t/100),maxLevel:100,costPerLevel:100,effect:t=>({bonus:t/2e3,get desc(){return u.t("octeract.data.octeractImprovedAscensionSpeed.effect",{n:d(t/20,2,!0)})}})},octeractImprovedAscensionSpeed2:{costFormula:(t,r)=>r*Math.pow(1e12,t/250),maxLevel:250,costPerLevel:1e5,effect:t=>({bonus:t/2e3,get desc(){return u.t("octeract.data.octeractImprovedAscensionSpeed2.effect",{n:d(t/50,2,!0)})}})},octeractImprovedFree:{costFormula:(t,r)=>r*Math.pow(t+1,3),maxLevel:1,costPerLevel:100,effect:t=>({bonus:t>0,get desc(){return u.t("octeract.data.octeractImprovedFree.effect",{n:t>0?"":"NOT"})}})},octeractImprovedFree2:{costFormula:(t,r)=>r*Math.pow(t+1,3),maxLevel:1,costPerLevel:1e7,effect:t=>({bonus:.05*t,get desc(){return u.t("octeract.data.octeractImprovedFree2.effect",{n:d(t/20,2,!0)})}})},octeractImprovedFree3:{costFormula:(t,r)=>r*Math.pow(t+1,3),maxLevel:1,costPerLevel:1e17,effect:t=>({bonus:.05*t,get desc(){return u.t("octeract.data.octeractImprovedFree3.effect",{n:d(t/20,2,!0)})}})},octeractImprovedFree4:{costFormula:(t,r)=>r*Math.pow(1e20,t/40),maxLevel:40,costPerLevel:1e20,effect:t=>({bonus:.001*t+(t>0?.01:0),get desc(){return u.t("octeract.data.octeractImprovedFree4.effect",{n:d(.001*t+(t>0?.01:0),3,!0)})}})},octeractSingUpgradeCap:{costFormula:(t,r)=>r*Math.pow(1e3,t),maxLevel:10,costPerLevel:1e10,effect:t=>({bonus:t,get desc(){return u.t("octeract.data.octeractSingUpgradeCap.effect",{n:t})}}),qualityOfLife:!0},octeractOfferings1:{costFormula:(t,r)=>t<25?r*Math.pow(t+1,5):r*1e15*Math.pow(10,t/25-1),maxLevel:-1,costPerLevel:1e-15,effect:t=>({bonus:1+.01*t,get desc(){return u.t("octeract.data.octeractOfferings1.effect",{n:d(t)})}})},octeractObtainium1:{costFormula:(t,r)=>t<25?r*Math.pow(t+1,5):r*1e15*Math.pow(10,t/25-1),maxLevel:-1,costPerLevel:1e-15,effect:t=>({bonus:1+.01*t,get desc(){return u.t("octeract.data.octeractObtainium1.effect",{n:d(t)})}})},octeractAscensions:{costFormula:(t,r)=>r*Math.pow(t+1,3),maxLevel:1e6,costPerLevel:1,effect:t=>({bonus:(1+t/100)*(1+2*Math.floor(t/10)/100),get desc(){return u.t("octeract.data.octeractAscensions.effect",{n:d((100+t)*(1+2*Math.floor(t/10)/100)-100,1,!0)})}})},octeractAscensions2:{costFormula:(t,r)=>r*Math.pow(10,Math.pow(t,.5)/3),maxLevel:-1,costPerLevel:1e12,effect:t=>({bonus:(1+t/100)*(1+2*Math.floor(t/10)/100),get desc(){return u.t("octeract.data.octeractAscensions2.effect",{n:d((100+t)*(1+2*Math.floor(t/10)/100)-100,1,!0)})}})},octeractAscensionsOcteractGain:{costFormula:(t,r)=>r*Math.pow(40,t),maxLevel:-1,costPerLevel:1e3,effect:t=>({bonus:t/100,get desc(){return u.t("octeract.data.octeractAscensionsOcteractGain.effect",{n:d(t,1,!0)})}})},octeractFastForward:{costFormula:(t,r)=>r*Math.pow(1e8,t),maxLevel:2,costPerLevel:1e8,effect:t=>({bonus:t,get desc(){return u.t("octeract.data.octeractFastForward.effect",{n100:100*t,n:t})}})},octeractAutoPotionSpeed:{costFormula:(t,r)=>r*Math.pow(10,t),maxLevel:-1,costPerLevel:1e-10,effect:t=>({bonus:1+4*t/100,get desc(){return u.t("octeract.data.octeractAutoPotionSpeed.effect",{n:4*t})}})},octeractAutoPotionEfficiency:{costFormula:(t,r)=>r*Math.pow(10,t),maxLevel:100,costPerLevel:1e-10*Math.pow(10,.5),effect:t=>({bonus:1+2*t/100,get desc(){return u.t("octeract.data.octeractAutoPotionEfficiency.effect",{n:2*t})}})},octeractOneMindImprover:{costFormula:(t,r)=>{let n=t>=10?Math.pow(1e3,t-10):1;return r*Math.pow(1e5,t)*n},maxLevel:16,costPerLevel:1e25,effect:t=>({bonus:.55+t/150,get desc(){return u.t("octeract.data.octeractOneMindImprover.effect",{n:d(.55+t/150,3,!0)})}}),qualityOfLife:!0},octeractAmbrosiaLuck:{costFormula:(t,r)=>{let n=t+1;return r*(Math.pow(10,n)-Math.pow(10,n-1))},maxLevel:-1,costPerLevel:1e60/9,effect:t=>({bonus:4*t,get desc(){return u.t("octeract.data.octeractAmbrosiaLuck.effect",{n:d(4*t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaLuck=Ge().value}]},octeractAmbrosiaLuck2:{costFormula:(t,r)=>r*(Math.pow(t+1,6)-Math.pow(t,6)),maxLevel:30,costPerLevel:1,effect:t=>({bonus:2*t,get desc(){return u.t("octeract.data.octeractAmbrosiaLuck2.effect",{n:d(2*t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaLuck=Ge().value}]},octeractAmbrosiaLuck3:{costFormula:(t,r)=>r*(Math.pow(t+1,8)-Math.pow(t,8)),maxLevel:30,costPerLevel:1e30,effect:t=>({bonus:3*t,get desc(){return u.t("octeract.data.octeractAmbrosiaLuck3.effect",{n:d(3*t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaLuck=Ge().value}]},octeractAmbrosiaLuck4:{costFormula:(t,r)=>{let n=t+1;return r*(Math.pow(3,n)-Math.pow(3,n-1))},maxLevel:50,costPerLevel:1e70/2,effect:t=>({bonus:5*t,get desc(){return u.t("octeract.data.octeractAmbrosiaLuck4.effect",{n:d(5*t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaLuck=Ge().value}]},octeractAmbrosiaGeneration:{costFormula:(t,r)=>{let n=t+1;return r*(Math.pow(10,n)-Math.pow(10,n-1))},maxLevel:-1,costPerLevel:1e60/9,effect:t=>({bonus:1+t/100,get desc(){return u.t("octeract.data.octeractAmbrosiaGeneration.effect",{n:d(t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value}]},octeractAmbrosiaGeneration2:{costFormula:(t,r)=>r*(Math.pow(t+1,6)-Math.pow(t,6)),maxLevel:20,costPerLevel:1,effect:t=>({bonus:1+t/100,get desc(){return u.t("octeract.data.octeractAmbrosiaGeneration2.effect",{n:d(t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value}]},octeractAmbrosiaGeneration3:{costFormula:(t,r)=>r*(Math.pow(t+1,8)-Math.pow(t,8)),maxLevel:35,costPerLevel:1e30,effect:t=>({bonus:1+t/100,get desc(){return u.t("octeract.data.octeractAmbrosiaGeneration3.effect",{n:d(t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value}]},octeractAmbrosiaGeneration4:{costFormula:(t,r)=>{let n=t+1;return r*(Math.pow(3,n)-Math.pow(3,n-1))},maxLevel:50,costPerLevel:1e70/2,effect:t=>({bonus:1+2*t/100,get desc(){return u.t("octeract.data.octeractAmbrosiaGeneration4.effect",{n:d(2*t)})}}),qualityOfLife:!0,cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value}]}};var ur=class{constructor(r,n){var l,c,p,g,m;let a=u.t(`singularityChallenge.data.${n}.name`),s=u.t(`singularityChallenge.data.${n}.description`);this.name=a,this.description=s,this.baseReq=r.baseReq,this.completions=(l=r.completions)!=null?l:0,this.maxCompletions=r.maxCompletions,this.unlockSingularity=r.unlockSingularity,this.HTMLTag=r.HTMLTag,this.highestSingularityCompleted=(c=r.highestSingularityCompleted)!=null?c:0,this.enabled=(p=r.enabled)!=null?p:!1,this.resetTime=(g=r.resetTime)!=null?g:!1,this.singularityRequirement=r.singularityRequirement,this.effect=r.effect,this.scalingrewardcount=r.scalingrewardcount,this.uniquerewardcount=r.uniquerewardcount,this.updateIconHTML(),this.updateChallengeCompletions(),this.cacheUpdates=(m=r.cacheUpdates)!=null?m:void 0}computeSingularityRquirement(){return this.singularityRequirement(this.baseReq,this.completions)}updateChallengeCompletions(){let r=0;for(;this.singularityRequirement(this.baseReq,r)<=this.highestSingularityCompleted;)r+=1;this.completions=Math.min(this.maxCompletions,r)}challengeEntryHandler(){return this.enabled?this.exitChallenge(e.runelevels[6]>0):this.enableChallenge()}async enableChallenge(){if(e.highestSingularityCount${u.t("general.enabled")}`:"";return`${this.name} ${n} ${u.t("singularityChallenge.toString.tiersCompleted")}: ${this.completions}/${this.maxCompletions} ${u.t("singularityChallenge.toString.canEnter",{unlockSing:this.unlockSingularity,highestSing:e.highestSingularityCount})} ${u.t("singularityChallenge.toString.currentTierSingularity")} ${this.singularityRequirement(this.baseReq,this.completions)} ${this.description}`}scaleString(){let r="";for(let n=1;n<=this.scalingrewardcount;n++){let a=u.t(`singularityChallenge.data.${String(this.HTMLTag)}.ScalingReward${n}`);r+=n>1?` ${a}`:a}return r}uniqueString(){let r="";for(let n=1;n<=this.uniquerewardcount;n++){let a=u.t(`singularityChallenge.data.${String(this.HTMLTag)}.UniqueReward${n}`);r+=n>1?` -${a}`:a}return r}updateChallengeHTML(){i("singularityChallengesInfo").innerHTML=this.toString(),i("singularityChallengesScalingRewards").innerHTML=this.scaleString(),i("singularityChallengesUniqueRewards").innerHTML=this.uniqueString()}updateIconHTML(){let r=this.enabled?"orchid":"";i(`${String(this.HTMLTag)}`).style.backgroundColor=r}get rewards(){return this.effect(this.completions)}},Ze={noSingularityUpgrades:{baseReq:1,maxCompletions:30,unlockSingularity:25,HTMLTag:"noSingularityUpgrades",singularityRequirement:(t,r)=>t+8*r,scalingrewardcount:1,uniquerewardcount:5,effect:t=>({cubes:1+.5*t,goldenQuarks:1+.12*+(t>0),blueberries:+(t>0),shopUpgrade:t>=20,luckBonus:t>=30?.04:0,shopUpgrade2:t>=30}),cacheUpdates:[()=>{o.ambrosiaCurrStats={ambrosiaAdditiveLuckMult:zr().value,ambrosiaLuck:Ge().value,ambrosiaBlueberries:da().value,ambrosiaGenerationSpeed:De().value}}]},oneChallengeCap:{baseReq:10,maxCompletions:25,unlockSingularity:40,HTMLTag:"oneChallengeCap",singularityRequirement:(t,r)=>t+11*r,scalingrewardcount:2,uniquerewardcount:4,effect:t=>({corrScoreIncrease:.03*t,blueberrySpeedMult:1+t/100,capIncrease:3*+(t>0),freeCorruptionLevel:t>=20,shopUpgrade:t>=20,reinCapIncrease2:7*+(t>=25),ascCapIncrease2:2*+(t>=25)})},noOcteracts:{baseReq:75,maxCompletions:15,unlockSingularity:100,HTMLTag:"noOcteracts",singularityRequirement:(t,r)=>r<10?t+13*r:t+13*9+10*(r-9),scalingrewardcount:1,uniquerewardcount:3,effect:t=>({octeractPow:t<=10?.02*t:.2+(t-10)/100,offeringBonus:t>0,obtainiumBonus:t>=10,shopUpgrade:t>=10})},limitedAscensions:{baseReq:10,maxCompletions:25,unlockSingularity:50,HTMLTag:"limitedAscensions",singularityRequirement:(t,r)=>t+10*r,scalingrewardcount:1,uniquerewardcount:4,effect:t=>({ultimateProgressBarUnlock:t>0,ascensionSpeedMult:.1*t/100,hepteractCap:t>0,exaltBonus:t>=20,shopUpgrade:t>=25})},noAmbrosiaUpgrades:{baseReq:150,maxCompletions:20,unlockSingularity:166,HTMLTag:"noAmbrosiaUpgrades",singularityRequirement:(t,r)=>t+6*r,scalingrewardcount:2,uniquerewardcount:6,effect:t=>({bonusAmbrosia:+(t>0),blueberries:Math.floor(t/10)+ +(t>0),luckBonus:t/200,additiveLuck:15*t,blueberrySpeedMult:1+t/50,shopUpgrade:t>=15,shopUpgrade2:t>=20})},limitedTime:{baseReq:203,maxCompletions:25,unlockSingularity:216,HTMLTag:"limitedTime",singularityRequirement:(t,r)=>t+3*r,scalingrewardcount:3,uniquerewardcount:3,effect:t=>({preserveQuarks:+(t>0),quarkMult:.01*t,globalSpeed:.06*t,ascensionSpeed:.06*t,tier1Upgrade:t>=15,tier2Upgrade:t>=25})},sadisticPrequel:{baseReq:135,maxCompletions:30,unlockSingularity:273,HTMLTag:"sadisticPrequel",singularityRequirement:(t,r)=>t+3*r,scalingrewardcount:2,uniquerewardcount:4,effect:t=>({extraFree:50*+(t>0),quarkMult:.03*t,freeUpgradeMult:.03*t,shopUpgrade:t>=10,shopUpgrade2:t>=20,shopUpgrade3:t>=30})}};var W=y.custom(t=>{try{return new f(t),!0}catch(r){return!1}}).transform(t=>new f(t)),lr=t=>y.tuple([y.null()]).rest(t),Hn=(t,r)=>(t.lengthy.object(O({level:y.number(),toggleBuy:y.number(),freeLevels:y.number()},t.reduce((r,n)=>(r[n]=y.number(),r),{}))),Ky=y.record(y.string(),y.boolean()).transform(t=>Object.fromEntries(Object.entries(t).filter(([r,n])=>/^\d+$/.test(r)))).transform(t=>{let r=Object.entries(M.toggles);for(let n of r)Object.hasOwn(t,n[0])||(t[n[0]]=n[1]);return t}),nu=y.string().regex(/^|-?\d+(\.\d{1,2})?$/),_i=y.string().regex(/^\d+$/),Fn=t=>y.object({AUTO:y.boolean().default(()=>M.hepteractCrafts[t].AUTO),BAL:y.number().default(()=>M.hepteractCrafts[t].BAL),BASE_CAP:y.number(),CAP:y.number().default(()=>M.hepteractCrafts[t].CAP),DISCOUNT:y.number().default(()=>M.hepteractCrafts[t].DISCOUNT),HEPTERACT_CONVERSION:y.number(),HTML_STRING:y.string().default(()=>M.hepteractCrafts[t].HTML_STRING),OTHER_CONVERSIONS:y.record(y.string(),y.number()),UNLOCKED:y.boolean().default(()=>M.hepteractCrafts[t].UNLOCKED)}),Di=y.object({firstPlayed:y.string().datetime().optional().default(()=>new Date().toISOString()),worlds:y.number().transform(t=>new Un(t)),coins:W,coinsThisPrestige:W,coinsThisTranscension:W,coinsThisReincarnation:W,coinsTotal:W,firstOwnedCoin:y.number(),firstGeneratedCoin:W,firstCostCoin:W,firstProduceCoin:y.number(),secondOwnedCoin:y.number(),secondGeneratedCoin:W,secondCostCoin:W,secondProduceCoin:y.number(),thirdOwnedCoin:y.number(),thirdGeneratedCoin:W,thirdCostCoin:W,thirdProduceCoin:y.number(),fourthOwnedCoin:y.number(),fourthGeneratedCoin:W,fourthCostCoin:W,fourthProduceCoin:y.number(),fifthOwnedCoin:y.number(),fifthGeneratedCoin:W,fifthCostCoin:W,fifthProduceCoin:y.number(),firstOwnedDiamonds:y.number(),firstGeneratedDiamonds:W,firstCostDiamonds:W,firstProduceDiamonds:y.number(),secondOwnedDiamonds:y.number(),secondGeneratedDiamonds:W,secondCostDiamonds:W,secondProduceDiamonds:y.number(),thirdOwnedDiamonds:y.number(),thirdGeneratedDiamonds:W,thirdCostDiamonds:W,thirdProduceDiamonds:y.number(),fourthOwnedDiamonds:y.number(),fourthGeneratedDiamonds:W,fourthCostDiamonds:W,fourthProduceDiamonds:y.number(),fifthOwnedDiamonds:y.number(),fifthGeneratedDiamonds:W,fifthCostDiamonds:W,fifthProduceDiamonds:y.number(),firstOwnedMythos:y.number(),firstGeneratedMythos:W,firstCostMythos:W,firstProduceMythos:y.number(),secondOwnedMythos:y.number(),secondGeneratedMythos:W,secondCostMythos:W,secondProduceMythos:y.number(),thirdOwnedMythos:y.number(),thirdGeneratedMythos:W,thirdCostMythos:W,thirdProduceMythos:y.number(),fourthOwnedMythos:y.number(),fourthGeneratedMythos:W,fourthCostMythos:W,fourthProduceMythos:y.number(),fifthOwnedMythos:y.number(),fifthGeneratedMythos:W,fifthCostMythos:W,fifthProduceMythos:y.number(),firstOwnedParticles:y.number(),firstGeneratedParticles:W,firstCostParticles:W,firstProduceParticles:y.number(),secondOwnedParticles:y.number(),secondGeneratedParticles:W,secondCostParticles:W,secondProduceParticles:y.number(),thirdOwnedParticles:y.number(),thirdGeneratedParticles:W,thirdCostParticles:W,thirdProduceParticles:y.number(),fourthOwnedParticles:y.number(),fourthGeneratedParticles:W,fourthCostParticles:W,fourthProduceParticles:y.number(),fifthOwnedParticles:y.number(),fifthGeneratedParticles:W,fifthCostParticles:W,fifthProduceParticles:y.number(),firstOwnedAnts:y.number().default(()=>M.firstOwnedAnts),firstGeneratedAnts:W,firstCostAnts:W,firstProduceAnts:y.number().default(()=>M.firstProduceAnts),secondOwnedAnts:y.number().default(()=>M.secondOwnedAnts),secondGeneratedAnts:W,secondCostAnts:W,secondProduceAnts:y.number().default(()=>M.secondProduceAnts),thirdOwnedAnts:y.number().default(()=>M.thirdOwnedAnts),thirdGeneratedAnts:W,thirdCostAnts:W,thirdProduceAnts:y.number().default(()=>M.thirdProduceAnts),fourthOwnedAnts:y.number().default(()=>M.fourthOwnedAnts),fourthGeneratedAnts:W,fourthCostAnts:W,fourthProduceAnts:y.number().default(()=>M.fourthProduceAnts),fifthOwnedAnts:y.number().default(()=>M.fifthOwnedAnts),fifthGeneratedAnts:W,fifthCostAnts:W,fifthProduceAnts:y.number().default(()=>M.fifthProduceAnts),sixthOwnedAnts:y.number().default(()=>M.sixthOwnedAnts),sixthGeneratedAnts:W,sixthCostAnts:W,sixthProduceAnts:y.number().default(()=>M.sixthProduceAnts),seventhOwnedAnts:y.number().default(()=>M.seventhOwnedAnts),seventhGeneratedAnts:W,seventhCostAnts:W,seventhProduceAnts:y.number().default(()=>M.seventhProduceAnts),eighthOwnedAnts:y.number().default(()=>M.eighthOwnedAnts),eighthGeneratedAnts:W,eighthCostAnts:W,eighthProduceAnts:y.number().default(()=>M.eighthProduceAnts),ascendBuilding1:uo.default(()=>Gr(M.ascendBuilding1)),ascendBuilding2:uo.default(()=>Gr(M.ascendBuilding2)),ascendBuilding3:uo.default(()=>Gr(M.ascendBuilding3)),ascendBuilding4:uo.default(()=>Gr(M.ascendBuilding4)),ascendBuilding5:uo.default(()=>Gr(M.ascendBuilding5)),multiplierCost:W,multiplierBought:y.number(),acceleratorCost:W,acceleratorBought:y.number(),acceleratorBoostBought:y.number(),acceleratorBoostCost:W,upgrades:y.number().array().transform(t=>(t.length{let r=Object.values(t);return Pc(r,0,M.challengecompletions.length),r})]),highestchallengecompletions:y.union([y.union([y.number(),y.null()]).array(),y.record(y.string(),y.number()).transform(t=>{let r=Object.values(t);return Pc(r,0,M.highestchallengecompletions.length),r})]),challenge15Exponent:y.number().default(()=>M.challenge15Exponent),highestChallenge15Exponent:y.number().default(()=>M.highestChallenge15Exponent),retrychallenges:y.boolean().default(()=>M.retrychallenges),currentChallenge:y.union([y.string().transform(()=>O({},M.currentChallenge)),y.object({transcension:y.number(),reincarnation:y.number(),ascension:y.number()}).default(()=>O({},M.currentChallenge))]),researchPoints:y.number(),obtainiumtimer:y.number(),obtainiumpersecond:y.number().default(()=>M.obtainiumpersecond),maxobtainiumpersecond:y.number().default(()=>M.maxobtainiumpersecond),maxobtainium:y.number().default(()=>M.maxobtainium),researches:y.number().array().transform(t=>Hn(t,"researches")),unlocks:y.record(y.string(),y.boolean()),achievements:y.number().array().transform(t=>Hn(t,"achievements")),achievementPoints:y.number(),prestigenomultiplier:y.boolean(),prestigenoaccelerator:y.boolean(),transcendnomultiplier:y.boolean(),transcendnoaccelerator:y.boolean(),reincarnatenomultiplier:y.boolean(),reincarnatenoaccelerator:y.boolean(),prestigenocoinupgrades:y.boolean(),transcendnocoinupgrades:y.boolean(),transcendnocoinorprestigeupgrades:y.boolean(),reincarnatenocoinupgrades:y.boolean(),reincarnatenocoinorprestigeupgrades:y.boolean(),reincarnatenocoinprestigeortranscendupgrades:y.boolean(),reincarnatenocoinprestigetranscendorgeneratorupgrades:y.boolean(),crystalUpgrades:y.number().array(),crystalUpgradesCost:y.number().array().default(()=>[...M.crystalUpgradesCost]),runelevels:y.number().array().transform(t=>Hn(t,"runelevels")),runeexp:y.union([y.number(),y.null().transform(()=>0)]).array().transform(t=>Hn(t,"runeexp")),runeshards:y.number(),maxofferings:y.number().default(()=>M.maxofferings),offeringpersecond:y.number().default(()=>M.offeringpersecond),prestigecounter:y.number(),transcendcounter:y.number(),reincarnationcounter:y.number(),offlinetick:y.number(),prestigeamount:y.union([y.number(),nu.transform(Number)]),transcendamount:y.union([y.number(),nu.transform(Number)]).default(()=>M.transcendamount),reincarnationamount:y.union([y.number(),nu.transform(Number)]),fastestprestige:y.number(),fastesttranscend:y.number(),fastestreincarnate:y.number(),resettoggle1:y.number().default(()=>M.resettoggle1),resettoggle2:y.number().default(()=>M.resettoggle2),resettoggle3:y.number().default(()=>M.resettoggle3),resettoggle4:y.number().default(()=>M.resettoggle4),tesseractAutoBuyerToggle:y.number().default(()=>M.tesseractAutoBuyerToggle),tesseractAutoBuyerAmount:y.number().default(()=>M.tesseractAutoBuyerAmount),coinbuyamount:y.number(),crystalbuyamount:y.number(),mythosbuyamount:y.number(),particlebuyamount:y.number(),offeringbuyamount:y.number(),tesseractbuyamount:y.number().default(()=>M.tesseractbuyamount),shoptoggles:y.record(y.string(),y.boolean()),tabnumber:y.number(),subtabNumber:y.number().default(()=>M.subtabNumber),codes:y.array(y.tuple([y.number(),y.boolean()])).transform(t=>new Map(t)).default(()=>Gr([...M.codes])),loaded1009:y.boolean().default(()=>M.loaded1009),loaded1009hotfix1:y.boolean().default(()=>M.loaded1009hotfix1),loaded10091:y.boolean().default(()=>M.loaded10091),loaded1010:y.boolean().default(()=>M.loaded1010),loaded10101:y.boolean().default(()=>M.loaded10101),shopUpgrades:y.record(y.string(),y.union([y.number(),y.null(),y.boolean()])).transform(t=>Object.fromEntries(Object.keys(M.shopUpgrades).map(r=>{var a;let n=(a=t[r])!=null?a:M.shopUpgrades[r];return n===null?[r,0]:[r,Number(n)]}))).default(()=>O({},M.shopUpgrades)),shopBuyMaxToggle:y.union([y.boolean(),y.string()]).default(()=>M.shopBuyMaxToggle),shopHideToggle:y.boolean().default(()=>M.shopHideToggle),shopConfirmationToggle:y.boolean().default(()=>M.shopConfirmationToggle),autoPotionTimer:y.number().default(()=>M.autoPotionTimer),autoPotionTimerObtainium:y.number().default(()=>M.autoPotionTimerObtainium),autoSacrificeToggle:y.boolean().default(()=>M.autoSacrificeToggle),autoBuyFragment:y.boolean().default(()=>M.autoBuyFragment),autoFortifyToggle:y.boolean().default(()=>M.autoFortifyToggle),autoEnhanceToggle:y.boolean().default(()=>M.autoEnhanceToggle),autoResearchToggle:y.boolean().default(()=>M.autoResearchToggle),researchBuyMaxToggle:y.boolean().default(()=>M.researchBuyMaxToggle),autoResearchMode:y.string().default(()=>M.autoResearchMode),autoResearch:y.number().default(()=>M.autoResearch),autoSacrifice:y.number().default(()=>M.autoSacrifice),sacrificeTimer:y.number().default(()=>M.sacrificeTimer),quarkstimer:y.number().default(()=>M.quarkstimer),goldenQuarksTimer:y.number().default(()=>M.goldenQuarksTimer),antPoints:W,antUpgrades:y.union([y.number().array(),lr(y.number()).transform(t=>t.slice(1))]).default(()=>[...M.antUpgrades]),antSacrificePoints:y.union([y.number(),y.null().transform(()=>Number.MAX_VALUE)]).default(()=>M.antSacrificePoints),antSacrificeTimer:y.number().default(()=>M.antSacrificeTimer),antSacrificeTimerReal:y.number().default(()=>M.antSacrificeTimerReal),talismanLevels:y.union([y.number().array(),lr(y.number()).transform(t=>t.slice(1))]).default(()=>[...M.talismanLevels]),talismanRarity:y.union([y.number().array(),lr(y.number()).transform(t=>t.slice(1))]).default(()=>[...M.talismanRarity]),talismanOne:lr(y.number()).default(()=>M.talismanOne),talismanTwo:lr(y.number()).default(()=>M.talismanTwo),talismanThree:lr(y.number()).default(()=>M.talismanThree),talismanFour:lr(y.number()).default(()=>M.talismanFour),talismanFive:lr(y.number()).default(()=>M.talismanFive),talismanSix:lr(y.number()).default(()=>M.talismanSix),talismanSeven:lr(y.number()).default(()=>M.talismanSeven),talismanShards:y.number().default(()=>M.talismanShards),commonFragments:y.number().default(()=>M.commonFragments),uncommonFragments:y.number().default(()=>M.uncommonFragments),rareFragments:y.number().default(()=>M.rareFragments),epicFragments:y.number().default(()=>M.epicFragments),legendaryFragments:y.number().default(()=>M.legendaryFragments),mythicalFragments:y.number().default(()=>M.mythicalFragments),buyTalismanShardPercent:y.number().default(()=>M.buyTalismanShardPercent),autoAntSacrifice:y.boolean().default(()=>M.autoAntSacrifice),autoAntSacTimer:y.number().default(()=>M.autoAntSacTimer),autoAntSacrificeMode:y.number().default(()=>M.autoAntSacrificeMode),antMax:y.boolean().default(()=>M.antMax),ascensionCount:y.number().default(()=>M.ascensionCount),ascensionCounter:y.number().default(()=>M.ascensionCounter),ascensionCounterReal:y.number().default(()=>M.ascensionCounterReal),ascensionCounterRealReal:y.number().default(()=>M.ascensionCounterRealReal),cubeUpgrades:lr(y.number()).transform(t=>Hn(t,"cubeUpgrades")).default(()=>[...M.cubeUpgrades]),cubeUpgradesBuyMaxToggle:y.boolean().default(()=>M.cubeUpgradesBuyMaxToggle),autoCubeUpgradesToggle:y.boolean().default(()=>M.autoCubeUpgradesToggle),autoPlatonicUpgradesToggle:y.boolean().default(()=>M.autoPlatonicUpgradesToggle),platonicUpgrades:y.number().array().transform(t=>Hn(t,"platonicUpgrades")).default(()=>[...M.platonicUpgrades]),wowCubes:y.number().default(()=>Number(M.wowCubes)).transform(t=>new tr(t)),wowTesseracts:y.number().default(()=>Number(M.wowTesseracts)).transform(t=>new na(t)),wowHypercubes:y.number().default(()=>Number(M.wowHypercubes)).transform(t=>new aa(t)),wowPlatonicCubes:y.number().default(()=>Number(M.wowPlatonicCubes)).transform(t=>new sa(t)),saveOfferingToggle:y.boolean().default(()=>M.saveOfferingToggle),wowAbyssals:y.number().default(()=>M.wowAbyssals),wowOcteracts:y.number().default(()=>M.wowOcteracts),totalWowOcteracts:y.number().default(()=>M.totalWowOcteracts),cubeBlessings:y.record(y.string(),y.number()).default(()=>O({},M.cubeBlessings)),tesseractBlessings:y.record(y.string(),y.number()).default(()=>O({},M.tesseractBlessings)),hypercubeBlessings:y.record(y.string(),y.number()).default(()=>O({},M.hypercubeBlessings)),platonicBlessings:y.record(y.string(),y.number()).default(()=>O({},M.platonicBlessings)),hepteractCrafts:y.object({chronos:Fn("chronos"),hyperrealism:Fn("hyperrealism"),quark:Fn("quark"),challenge:Fn("challenge"),abyss:Fn("abyss"),accelerator:Fn("accelerator"),acceleratorBoost:Fn("acceleratorBoost"),multiplier:Fn("multiplier")}).transform(t=>Object.fromEntries(Object.entries(M.hepteractCrafts).map(([r,n])=>[r,Lg(O(O({},n),t[r]))]))).default(()=>M.hepteractCrafts),ascendShards:W.default(()=>Gr(M.ascendShards)),autoAscend:y.boolean().default(()=>M.autoAscend),autoAscendMode:y.string().default(()=>M.autoAscendMode),autoAscendThreshold:y.number().default(()=>M.autoAscendThreshold),autoOpenCubes:y.boolean().default(()=>M.autoOpenCubes),openCubes:y.number().default(()=>M.openCubes),autoOpenTesseracts:y.boolean().default(()=>M.autoOpenTesseracts),openTesseracts:y.number().default(()=>M.openTesseracts),autoOpenHypercubes:y.boolean().default(()=>M.autoOpenHypercubes),openHypercubes:y.number().default(()=>M.openHypercubes),autoOpenPlatonicsCubes:y.boolean().default(()=>M.autoOpenPlatonicsCubes),openPlatonicsCubes:y.number().default(()=>M.openPlatonicsCubes),roombaResearchIndex:y.number().default(()=>M.roombaResearchIndex),ascStatToggles:y.record(_i,y.boolean()).default(()=>O({},M.ascStatToggles)),prototypeCorruptions:y.number().array().default(()=>[...M.prototypeCorruptions]),usedCorruptions:y.number().array().transform(t=>Hn(t,"usedCorruptions")).default(()=>[...M.usedCorruptions]),corruptionLoadouts:y.record(_i,y.number().array()).default(()=>Gr(M.corruptionLoadouts)),corruptionLoadoutNames:y.string().array().default(()=>M.corruptionLoadoutNames.slice()).default(()=>[...M.corruptionLoadoutNames]),corruptionShowStats:y.boolean().default(()=>M.corruptionShowStats),constantUpgrades:lr(y.number()).default(()=>[...M.constantUpgrades]),history:y.object({ants:y.any().array(),ascend:y.any().array().default(()=>[...M.history.ascend]),reset:y.any().array().default(()=>[...M.history.reset]),singularity:y.any().array().default(()=>[...M.history.singularity])}).default(()=>Gr(M.history)),historyShowPerSecond:y.boolean().default(()=>M.historyShowPerSecond),autoChallengeRunning:y.boolean().default(()=>M.autoChallengeRunning),autoChallengeIndex:y.number().default(()=>M.autoChallengeIndex),autoChallengeToggles:y.boolean().array().default(()=>[...M.autoChallengeToggles]),autoChallengeStartExponent:y.number().default(()=>M.autoChallengeStartExponent),autoChallengeTimer:y.record(y.string(),y.number()).default(()=>O({},M.autoChallengeTimer)),runeBlessingLevels:y.number().array().default(()=>[...M.runeBlessingLevels]),runeSpiritLevels:y.number().array().default(()=>[...M.runeSpiritLevels]),runeBlessingBuyAmount:y.number().default(()=>M.runeBlessingBuyAmount),runeSpiritBuyAmount:y.number().default(()=>M.runeSpiritBuyAmount),autoTesseracts:y.boolean().array().default(()=>[...M.autoTesseracts]),saveString:y.string().default(()=>M.saveString),exporttest:y.union([y.string(),y.boolean()]).transform(t=>typeof t=="string"?t==="YES!":t),dayCheck:y.string().datetime().nullable().default(()=>M.dayCheck).transform(t=>t===null?t:new Date(t)),dayTimer:y.number().default(()=>M.dayTimer),cubeOpenedDaily:y.number().default(()=>M.cubeOpenedDaily),cubeQuarkDaily:y.number().default(()=>M.cubeQuarkDaily),tesseractOpenedDaily:y.number().default(()=>M.tesseractOpenedDaily),tesseractQuarkDaily:y.number().default(()=>M.tesseractQuarkDaily),hypercubeOpenedDaily:y.number().default(()=>M.hypercubeOpenedDaily),hypercubeQuarkDaily:y.number().default(()=>M.hypercubeQuarkDaily),platonicCubeOpenedDaily:y.number().default(()=>M.platonicCubeOpenedDaily),platonicCubeQuarkDaily:y.number().default(()=>M.platonicCubeQuarkDaily),overfluxOrbs:y.number().default(()=>M.overfluxOrbs),overfluxOrbsAutoBuy:y.boolean().default(()=>M.overfluxOrbsAutoBuy),overfluxPowder:y.number().default(()=>M.overfluxPowder),dailyPowderResetUses:y.number().default(()=>M.dailyPowderResetUses),autoWarpCheck:y.boolean().default(()=>M.autoWarpCheck),loadedOct4Hotfix:y.boolean().default(()=>M.loadedOct4Hotfix),loadedNov13Vers:y.boolean().default(()=>M.loadedNov13Vers),loadedDec16Vers:y.boolean().default(()=>M.loadedDec16Vers),loadedV253:y.boolean().default(()=>M.loadedV253),loadedV255:y.boolean().default(()=>M.loadedV255),loadedV297Hotfix1:y.boolean().default(()=>M.loadedV297Hotfix1),loadedV2927Hotfix1:y.boolean().default(()=>M.loadedV2927Hotfix1),loadedV2930Hotfix1:y.boolean().default(()=>M.loadedV2930Hotfix1),loadedV2931Hotfix1:y.boolean().default(()=>M.loadedV2931Hotfix1),loadedV21003Hotfix1:y.boolean().default(()=>M.loadedV21003Hotfix1),loadedV21007Hotfix1:y.boolean().default(()=>M.loadedV21007Hotfix1),version:y.string().default(()=>M.version),rngCode:y.number().default(()=>M.rngCode),promoCodeTiming:y.record(y.string(),y.number()).default(()=>({time:Date.now()-60*1e3*15})),singularityCount:y.number().default(()=>M.singularityCount),highestSingularityCount:y.number().default(()=>M.highestSingularityCount),singularityCounter:y.number().default(()=>M.singularityCount),goldenQuarks:y.number().default(()=>M.goldenQuarks),quarksThisSingularity:y.number().nullable().default(()=>M.quarksThisSingularity),totalQuarksEver:y.number().default(()=>M.totalQuarksEver),hotkeys:y.record(_i,y.string().array()).default(()=>M.hotkeys),theme:y.string().default(()=>M.theme),iconSet:y.number().default(()=>M.iconSet),notation:y.string().default(()=>M.notation),singularityUpgrades:y.record(y.string(),ru("goldenQuarksInvested")).transform(t=>Object.fromEntries(Object.keys(F).map(r=>{var c;let{level:n,goldenQuarksInvested:a,toggleBuy:s,freeLevels:l}=(c=t[r])!=null?c:F[r];return[r,new V({maxLevel:F[r].maxLevel,costPerLevel:F[r].costPerLevel,level:n,goldenQuarksInvested:a,toggleBuy:s,freeLevels:l,minimumSingularity:F[r].minimumSingularity,effect:F[r].effect,canExceedCap:F[r].canExceedCap,specialCostForm:F[r].specialCostForm,qualityOfLife:F[r].qualityOfLife,cacheUpdates:F[r].cacheUpdates},r)]}))).default(()=>JSON.parse(JSON.stringify(M.singularityUpgrades))),octeractUpgrades:y.record(y.string(),ru("octeractsInvested")).transform(t=>Object.fromEntries(Object.keys(le).map(r=>{var c;let{level:n,octeractsInvested:a,toggleBuy:s,freeLevels:l}=(c=t[r])!=null?c:le[r];return[r,new fe({maxLevel:le[r].maxLevel,costPerLevel:le[r].costPerLevel,level:n,octeractsInvested:a,toggleBuy:s,effect:le[r].effect,costFormula:le[r].costFormula,freeLevels:l,qualityOfLife:le[r].qualityOfLife,cacheUpdates:le[r].cacheUpdates},r)]}))).default(()=>JSON.parse(JSON.stringify(M.octeractUpgrades))),dailyCodeUsed:y.boolean().default(()=>M.dailyCodeUsed),hepteractAutoCraftPercentage:y.number().default(()=>M.hepteractAutoCraftPercentage),octeractTimer:y.number().default(()=>M.octeractTimer),insideSingularityChallenge:y.boolean().default(()=>M.insideSingularityChallenge),singularityChallenges:y.record(y.string(),y.object({completions:y.number(),highestSingularityCompleted:y.number(),enabled:y.boolean()})).transform(t=>Object.fromEntries(Object.keys(M.singularityChallenges).map(r=>{var l;let{completions:n,highestSingularityCompleted:a,enabled:s}=(l=t[r])!=null?l:M.singularityChallenges[r];return[r,new ir({baseReq:Ze[r].baseReq,completions:n,maxCompletions:Ze[r].maxCompletions,unlockSingularity:Ze[r].unlockSingularity,HTMLTag:Ze[r].HTMLTag,highestSingularityCompleted:a,enabled:s,resetTime:Ze[r].resetTime,singularityRequirement:Ze[r].singularityRequirement,scalingrewardcount:Ze[r].scalingrewardcount,uniquerewardcount:Ze[r].uniquerewardcount,effect:Ze[r].effect,cacheUpdates:Ze[r].cacheUpdates},r)]}))).default(()=>JSON.parse(JSON.stringify(M.singularityChallenges))),ambrosia:y.number().default(()=>M.ambrosia),lifetimeAmbrosia:y.number().default(()=>M.lifetimeAmbrosia),ambrosiaRNG:y.number().default(()=>M.ambrosiaRNG),blueberryTime:y.number().default(()=>M.blueberryTime),visitedAmbrosiaSubtab:y.boolean().default(()=>M.visitedAmbrosiaSubtab),spentBlueberries:y.number().default(()=>M.spentBlueberries),blueberryUpgrades:y.record(y.string(),ru("blueberriesInvested","ambrosiaInvested")).transform(t=>Object.fromEntries(Object.keys(M.blueberryUpgrades).map(r=>{var p;let{level:n,ambrosiaInvested:a,blueberriesInvested:s,toggleBuy:l,freeLevels:c}=(p=t[r])!=null?p:M.blueberryUpgrades[r];return[r,new Ke({maxLevel:$e[r].maxLevel,costPerLevel:$e[r].costPerLevel,level:n,ambrosiaInvested:a,blueberriesInvested:s,toggleBuy:l,blueberryCost:$e[r].blueberryCost,rewards:$e[r].rewards,costFormula:$e[r].costFormula,freeLevels:c,prerequisites:$e[r].prerequisites,cacheUpdates:$e[r].cacheUpdates},r)]}))).default(()=>JSON.parse(JSON.stringify(M.blueberryUpgrades))),blueberryLoadouts:y.record(_i,y.any()).default(()=>M.blueberryLoadouts),blueberryLoadoutMode:y.string().default(()=>M.blueberryLoadoutMode),ultimateProgress:y.number().default(()=>M.ultimateProgress),ultimatePixels:y.number().default(()=>M.ultimatePixels),cubeUpgradeRedBarFilled:y.number().default(()=>M.cubeUpgradeRedBarFilled),singChallengeTimer:y.number().default(()=>M.singChallengeTimer),caches:y.record(y.string(),y.any()).transform(()=>(Object.values(M.caches).map(t=>t.reset()),M.caches)).default(()=>(Object.values(M.caches).map(t=>t.reset()),M.caches)),lastExportedSave:y.number().default(()=>M.lastExportedSave),seed:y.number().array().default(()=>M.seed).transform(t=>Hn(t,"seed")).refine(t=>t.every(r=>r>Date.parse("2020-01-01T00:00:00Z")&&rArray.from(t)),worlds:y.any().transform(t=>Number(t)),wowCubes:y.any().transform(t=>Number(t)),wowTesseracts:y.any().transform(t=>Number(t)),wowHypercubes:y.any().transform(t=>Number(t)),wowPlatonicCubes:y.any().transform(t=>Number(t)),singularityUpgrades:y.any().transform(t=>Object.fromEntries(Object.entries(t).map(([r,n])=>[r,{level:n.level,goldenQuarksInvested:n.goldenQuarksInvested,toggleBuy:n.toggleBuy,freeLevels:n.freeLevels}]))),octeractUpgrades:y.any().transform(t=>Object.fromEntries(Object.entries(t).map(([r,n])=>[r,{level:n.level,octeractsInvested:n.octeractsInvested,toggleBuy:n.toggleBuy,freeLevels:n.freeLevels}]))),singularityChallenges:y.any().transform(t=>Object.fromEntries(Object.entries(t).map(([r,n])=>[r,{completions:n.completions,highestSingularityCompleted:n.highestSingularityCompleted,enabled:n.enabled}]))),blueberryUpgrades:y.any().transform(t=>Object.fromEntries(Object.entries(t).map(([r,n])=>[r,{level:n.level,ambrosiaInvested:n.ambrosiaInvested,blueberriesInvested:n.blueberriesInvested,toggleBuy:n.toggleBuy,freeLevels:n.freeLevels}]))),dayCheck:y.any().transform(t=>{var r;return(r=t==null?void 0:t.toISOString())!=null?r:null})});var pe={offeringPotion:{price:100,priceIncrease:0,maxLevel:999999999,type:"consume",refundable:!1,refundMinimumLevel:0,tier:"Reincarnation"},obtainiumPotion:{tier:"Reincarnation",price:100,priceIncrease:0,maxLevel:999999999,type:"consume",refundable:!1,refundMinimumLevel:0},offeringEX:{tier:"Reincarnation",price:150,priceIncrease:10,maxLevel:100,type:"upgrade",refundable:!0,refundMinimumLevel:0},offeringAuto:{tier:"Reincarnation",price:150,priceIncrease:10,maxLevel:100,type:"upgrade",refundable:!0,refundMinimumLevel:1},obtainiumEX:{tier:"Reincarnation",price:150,priceIncrease:10,maxLevel:100,type:"upgrade",refundable:!0,refundMinimumLevel:0},obtainiumAuto:{tier:"Reincarnation",price:150,priceIncrease:10,maxLevel:100,type:"upgrade",refundable:!0,refundMinimumLevel:1},instantChallenge:{tier:"Reincarnation",price:300,priceIncrease:99999,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},antSpeed:{tier:"Reincarnation",price:200,priceIncrease:25,maxLevel:100,type:"upgrade",refundable:!0,refundMinimumLevel:0},cashGrab:{tier:"Reincarnation",price:100,priceIncrease:40,maxLevel:100,type:"upgrade",refundable:!0,refundMinimumLevel:0},shopTalisman:{tier:"Reincarnation",price:1500,priceIncrease:99999,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},seasonPass:{tier:"Ascension",price:500,priceIncrease:75,maxLevel:100,type:"upgrade",refundable:!0,refundMinimumLevel:0},challengeExtension:{tier:"Ascension",price:500,priceIncrease:250,maxLevel:5,type:"upgrade",refundable:!1,refundMinimumLevel:0},challengeTome:{tier:"Ascension",price:500,priceIncrease:250,maxLevel:15,type:"upgrade",refundable:!1,refundMinimumLevel:0},cubeToQuark:{tier:"Ascension",price:2e3,priceIncrease:99999,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},tesseractToQuark:{tier:"Ascension",price:3500,priceIncrease:99999,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},hypercubeToQuark:{tier:"Ascension",price:5e3,priceIncrease:99999,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},seasonPass2:{tier:"Ascension",price:2e3,priceIncrease:200,maxLevel:100,type:"upgrade",refundable:!0,refundMinimumLevel:0},seasonPass3:{tier:"Ascension",price:5e3,priceIncrease:500,maxLevel:100,type:"upgrade",refundable:!0,refundMinimumLevel:0},chronometer:{tier:"Ascension",price:1600,priceIncrease:400,maxLevel:100,type:"upgrade",refundable:!0,refundMinimumLevel:0},infiniteAscent:{tier:"Ascension",price:25e3,priceIncrease:9999999,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},calculator:{tier:"Reincarnation",price:500,priceIncrease:300,maxLevel:5,type:"upgrade",refundable:!1,refundMinimumLevel:1},calculator2:{tier:"Ascension",price:2500,priceIncrease:800,maxLevel:12,type:"upgrade",refundable:!1,refundMinimumLevel:0},calculator3:{tier:"Ascension",price:7500,priceIncrease:1500,maxLevel:10,type:"upgrade",refundable:!1,refundMinimumLevel:0},calculator4:{tier:"Singularity",price:1e7,priceIncrease:1e6,maxLevel:10,type:"upgrade",refundable:!1,refundMinimumLevel:0},calculator5:{tier:"SingularityVol2",price:1e8,priceIncrease:1e8,maxLevel:100,type:"upgrade",refundable:!1,refundMinimumLevel:0},calculator6:{tier:"SingularityVol3",price:1e11,priceIncrease:2e10,maxLevel:100,type:"upgrade",refundable:!1,refundMinimumLevel:0},constantEX:{tier:"Ascension",price:1e5,priceIncrease:899999,maxLevel:2,type:"upgrade",refundable:!1,refundMinimumLevel:0},powderEX:{tier:"Ascension",price:1e3,priceIncrease:750,maxLevel:50,type:"upgrade",refundable:!1,refundMinimumLevel:0},chronometer2:{tier:"Ascension",price:5e3,priceIncrease:1500,maxLevel:100,type:"upgrade",refundable:!0,refundMinimumLevel:0},chronometer3:{tier:"Singularity",price:250,priceIncrease:250,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},seasonPassY:{tier:"Ascension",price:1e4,priceIncrease:1500,maxLevel:100,type:"upgrade",refundable:!0,refundMinimumLevel:0},seasonPassZ:{tier:"Singularity",price:250,priceIncrease:250,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},challengeTome2:{tier:"Singularity",price:1e6,priceIncrease:1e6,maxLevel:5,type:"upgrade",refundable:!1,refundMinimumLevel:0},instantChallenge2:{tier:"Singularity",price:2e7,priceIncrease:0,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},cubeToQuarkAll:{tier:"SingularityVol2",price:2222222,priceIncrease:0,maxLevel:100,type:"upgrade",refundable:!1,refundMinimumLevel:0},cashGrab2:{tier:"SingularityVol2",price:5e3,priceIncrease:5e3,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},chronometerZ:{tier:"SingularityVol2",price:12500,priceIncrease:12500,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},offeringEX2:{tier:"SingularityVol2",price:1e4,priceIncrease:1e4,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},obtainiumEX2:{tier:"SingularityVol2",price:1e4,priceIncrease:1e4,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},powderAuto:{tier:"SingularityVol2",price:5e6,priceIncrease:0,maxLevel:100,type:"upgrade",refundable:!1,refundMinimumLevel:0},seasonPassLost:{tier:"SingularityVol2",price:1e6,priceIncrease:25e3,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},challenge15Auto:{tier:"SingularityVol3",price:5e11,priceIncrease:0,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},extraWarp:{tier:"SingularityVol3",price:125e9,priceIncrease:0,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},autoWarp:{tier:"SingularityVol3",price:5e11,priceIncrease:0,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},improveQuarkHept:{tier:"Ascension",price:2e5-1,priceIncrease:0,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},improveQuarkHept2:{tier:"Singularity",price:2e7-1,priceIncrease:0,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},improveQuarkHept3:{tier:"SingularityVol2",price:2e9-1,priceIncrease:0,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},improveQuarkHept4:{tier:"SingularityVol3",price:2e11-1,priceIncrease:0,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopImprovedDaily:{tier:"Ascension",price:5e3,priceIncrease:2500,maxLevel:20,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopImprovedDaily2:{tier:"Singularity",price:5e5,priceIncrease:5e5,maxLevel:10,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopImprovedDaily3:{tier:"SingularityVol2",price:5e6,priceIncrease:125e5,maxLevel:15,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopImprovedDaily4:{tier:"SingularityVol3",price:5e9,priceIncrease:5e9,maxLevel:25,type:"upgrade",refundable:!1,refundMinimumLevel:0},offeringEX3:{tier:"SingularityVol3",price:1,priceIncrease:125e10,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},obtainiumEX3:{tier:"SingularityVol3",price:1,priceIncrease:125e10,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},improveQuarkHept5:{tier:"SingularityVol4",price:1,priceIncrease:25e12,maxLevel:100,type:"upgrade",refundable:!1,refundMinimumLevel:0},chronometerInfinity:{tier:"SingularityVol4",price:1,priceIncrease:25e11,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},seasonPassInfinity:{tier:"SingularityVol4",price:1,priceIncrease:375e10,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopSingularityPenaltyDebuff:{tier:"Exalt1",price:1e17,priceIncrease:999e17,maxLevel:4,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopAmbrosiaLuckMultiplier4:{tier:"Exalt2",price:1e20,priceIncrease:3e20,maxLevel:4,type:"upgrade",refundable:!1,refundMinimumLevel:0},calculator7:{tier:"Exalt3",price:1e20,priceIncrease:1e19,maxLevel:50,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopOcteractAmbrosiaLuck:{tier:"Exalt4",price:1e21,priceIncrease:9e21,maxLevel:2,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopAmbrosiaGeneration1:{tier:"SingularityVol2",price:5e7,priceIncrease:5e7,maxLevel:25,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopAmbrosiaGeneration2:{tier:"SingularityVol3",price:5e11,priceIncrease:5e11,maxLevel:30,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopAmbrosiaGeneration3:{tier:"SingularityVol4",price:5e13,priceIncrease:5e13,maxLevel:35,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopAmbrosiaGeneration4:{tier:"SingularityVol4",price:1e17,priceIncrease:4*1e16,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopAmbrosiaLuck1:{tier:"SingularityVol2",price:2e7,priceIncrease:2e7,maxLevel:40,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopAmbrosiaLuck2:{tier:"SingularityVol3",price:2e11,priceIncrease:2e11,maxLevel:50,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopAmbrosiaLuck3:{tier:"SingularityVol4",price:2e13,priceIncrease:2e13,maxLevel:60,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopAmbrosiaLuck4:{tier:"SingularityVol4",price:1e17,priceIncrease:4*1e16,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopCashGrabUltra:{tier:"Exalt1x30",price:1,priceIncrease:1e22,maxLevel:5,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopAmbrosiaAccelerator:{tier:"Exalt5",price:1e21,priceIncrease:2e21,maxLevel:5,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopEXUltra:{tier:"Exalt5x20",price:5e21,priceIncrease:0,maxLevel:80,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopChronometerS:{tier:"Exalt6x15",price:5e21,priceIncrease:0,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopAmbrosiaUltra:{tier:"Exalt6x25",price:8e23,priceIncrease:2e23,maxLevel:5,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopSingularitySpeedup:{tier:"Exalt7x10",price:2e22,priceIncrease:0,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopSingularityPotency:{tier:"Exalt7x20",price:2e23,priceIncrease:0,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopSadisticRune:{tier:"Exalt7x30",price:444e22,priceIncrease:0,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0}},Ua=t=>{if(pe[t].type==="consume"||pe[t].maxLevel===1)return pe[t].price;{let r=e.shopUpgrades[t];return pe[t].price+pe[t].priceIncrease*r}},cr=t=>{let r=i("quarkdescription"),n=i("quarkeffect"),a=i("quarkRefundable");switch(r.innerHTML=u.t(`shop.upgradeDescriptions.${t}`),pe[t].refundable?a.textContent=`This item is refundable! Will be set to level ${pe[t].refundMinimumLevel} when refunded.`:a.textContent=u.t("shop.cannotRefund"),t){case"offeringPotion":n.innerHTML=u.t("shop.upgradeEffects.offeringPotion",{amount:d(7200*e.offeringpersecond*qe().mult*+e.singularityUpgrades.potionBuff.getEffect().bonus,0,!0)});break;case"obtainiumPotion":n.innerHTML=u.t("shop.upgradeEffects.obtainiumPotion",{amount:d(7200*e.maxobtainiumpersecond*qe().mult*+e.singularityUpgrades.potionBuff.getEffect().bonus,0,!0)});break;case"offeringEX":n.innerHTML=u.t("shop.upgradeEffects.offeringEX",{amount:d(4*e.shopUpgrades.offeringEX,2,!0)});break;case"offeringAuto":n.innerHTML=u.t("shop.upgradeEffects.offeringAuto",{amount1:d(Math.pow(2,e.shopUpgrades.offeringAuto)),amount2:d(2*e.shopUpgrades.offeringAuto,2)});break;case"obtainiumEX":n.innerHTML=u.t("shop.upgradeEffects.obtainiumEX",{amount:d(4*e.shopUpgrades.obtainiumEX,2,!0)});break;case"obtainiumAuto":n.innerHTML=u.t("shop.upgradeEffects.obtainiumAuto",{amount:d(e.shopUpgrades.obtainiumAuto*2,2)});break;case"instantChallenge":n.innerHTML=u.t("shop.upgradeEffects.instantChallenge");break;case"antSpeed":n.innerHTML=u.t("shop.upgradeEffects.antSpeed",{amount:d(Math.pow(1.2,e.shopUpgrades.antSpeed),2)});break;case"cashGrab":n.innerHTML=u.t("shop.upgradeEffects.cashGrab",{amount:d(e.shopUpgrades.cashGrab,2)});break;case"shopTalisman":n.innerHTML=u.t("shop.upgradeEffects.shopTalisman");break;case"seasonPass":n.innerHTML=u.t("shop.upgradeEffects.seasonPass",{amount:d(2.25*e.shopUpgrades.seasonPass)});break;case"challengeExtension":n.innerHTML=u.t("shop.upgradeEffects.challengeExtension",{amount:d(2*e.shopUpgrades.challengeExtension)});break;case"challengeTome":n.innerHTML=u.t("shop.upgradeEffects.challengeTome",{amount1:d(20*e.shopUpgrades.challengeTome),amount2:d(1-(e.shopUpgrades.challengeTome+e.shopUpgrades.challengeTome2)/100,2,!0)});break;case"cubeToQuark":n.innerHTML=u.t("shop.upgradeEffects.cubeToQuark");break;case"tesseractToQuark":n.innerHTML=u.t("shop.upgradeEffects.tesseractToQuark");break;case"hypercubeToQuark":n.innerHTML=u.t("shop.upgradeEffects.hypercubeToQuark");break;case"seasonPass2":n.innerHTML=u.t("shop.upgradeEffects.seasonPass2",{amount:d(1.5*e.shopUpgrades.seasonPass2)});break;case"seasonPass3":n.innerHTML=u.t("shop.upgradeEffects.seasonPass3",{amount:d(1.5*e.shopUpgrades.seasonPass3)});break;case"chronometer":n.innerHTML=u.t("shop.upgradeEffects.chronometer",{amount:d(1.2*e.shopUpgrades.chronometer)});break;case"infiniteAscent":n.innerHTML=u.t("shop.upgradeEffects.infiniteAscent");break;case"calculator":n.innerHTML=u.t("shop.upgradeEffects.calculator",{amount1:d(14*e.shopUpgrades.calculator),bool1:e.shopUpgrades.calculator>0,bool2:e.shopUpgrades.calculator===pe.calculator.maxLevel});break;case"calculator2":n.innerHTML=u.t("shop.upgradeEffects.calculator2",{amount1:d(2*e.shopUpgrades.calculator2),amount2:d(e.shopUpgrades.calculator2===pe.calculator2.maxLevel?25:0)});break;case"calculator3":n.innerHTML=u.t("shop.upgradeEffects.calculator3",{amount1:d(10*e.shopUpgrades.calculator3),amount2:d(60*e.shopUpgrades.calculator3)});break;case"calculator4":n.innerHTML=u.t("shop.upgradeEffects.calculator4",{amount1:d(2*e.shopUpgrades.calculator4),amount2:e.shopUpgrades.calculator4===10?32:0});break;case"calculator5":n.innerHTML=u.t("shop.upgradeEffects.calculator5",{amount1:d(6*e.shopUpgrades.calculator5),amount2:Math.floor(e.shopUpgrades.calculator5/10)+(e.shopUpgrades.calculator4===pe.calculator5.maxLevel?6:0)});break;case"calculator6":n.innerHTML=u.t("shop.upgradeEffects.calculator6",{amount1:d(e.shopUpgrades.calculator6),amount2:e.shopUpgrades.calculator6===pe.calculator6.maxLevel?24:0});break;case"calculator7":n.innerHTML=u.t("shop.upgradeEffects.calculator7",{amount1:d(e.shopUpgrades.calculator7,0,!0),amount2:e.shopUpgrades.calculator7===pe.calculator7.maxLevel?48:0});break;case"constantEX":n.innerHTML=u.t("shop.upgradeEffects.constantEX",{amount:d(e.shopUpgrades.constantEX,0,!0)});break;case"powderEX":n.innerHTML=u.t("shop.upgradeEffects.powderEX",{amount:d(2*e.shopUpgrades.powderEX)});break;case"chronometer2":n.innerHTML=u.t("shop.upgradeEffects.chronometer2",{amount:d(.6*e.shopUpgrades.chronometer2,1)});break;case"chronometer3":n.innerHTML=u.t("shop.upgradeEffects.chronometer3",{amount:d(1.5*e.shopUpgrades.chronometer3,1)});break;case"seasonPassY":n.innerHTML=u.t("shop.upgradeEffects.seasonPassY",{amount:d(.75*e.shopUpgrades.seasonPassY,2)});break;case"seasonPassZ":n.innerHTML=u.t("shop.upgradeEffects.seasonPassZ",{amount:d(1*e.shopUpgrades.seasonPassZ*e.singularityCount,0,!0)});break;case"challengeTome2":n.innerHTML=u.t("shop.upgradeEffects.challengeTome2",{amount1:20*e.shopUpgrades.challengeTome2,amount2:d(1-(e.shopUpgrades.challengeTome+e.shopUpgrades.challengeTome2)/100,2,!0)});break;case"instantChallenge2":n.innerHTML=u.t("shop.upgradeEffects.instantChallenge2",{amount:d(e.shopUpgrades.instantChallenge2*e.singularityCount,0)});break;case"cashGrab2":n.innerHTML=u.t("shop.upgradeEffects.cashGrab2",{amount:d(.5*e.shopUpgrades.cashGrab2,1)});break;case"cubeToQuarkAll":n.innerHTML=u.t("shop.upgradeEffects.cubeToQuarkAll",{amount:d(.2*e.shopUpgrades.cubeToQuarkAll,2)});break;case"chronometerZ":n.innerHTML=u.t("shop.upgradeEffects.chronometerZ",{amount:d(.1*e.singularityCount*e.shopUpgrades.chronometerZ,2)});break;case"offeringEX2":n.innerHTML=u.t("shop.upgradeEffects.offeringEX2",{amount:d(1*e.singularityCount*e.shopUpgrades.offeringEX2,2)});break;case"obtainiumEX2":n.innerHTML=u.t("shop.upgradeEffects.obtainiumEX2",{amount:d(1*e.singularityCount*e.shopUpgrades.obtainiumEX2,2)});break;case"powderAuto":n.innerHTML=u.t("shop.upgradeEffects.powderAuto",{amount:d(100/(Math.max(1,e.shopUpgrades.powderAuto)*Lr().mult),2,!0)});break;case"seasonPassLost":n.innerHTML=u.t("shop.upgradeEffects.seasonPassLost",{amount:d(.1*e.shopUpgrades.seasonPassLost,2)});break;case"challenge15Auto":n.innerHTML=u.t("shop.upgradeEffects.challenge15Auto");break;case"extraWarp":n.innerHTML=u.t("shop.upgradeEffects.extraWarp",{amount:e.shopUpgrades.extraWarp});break;case"autoWarp":n.innerHTML=u.t("shop.upgradeEffects.autoWarp");break;case"improveQuarkHept":n.innerHTML=u.t("shop.upgradeEffects.improveQuarkHept",{amount:2*e.shopUpgrades.improveQuarkHept});break;case"improveQuarkHept2":n.innerHTML=u.t("shop.upgradeEffects.improveQuarkHept2",{amount:2*e.shopUpgrades.improveQuarkHept2});break;case"improveQuarkHept3":n.innerHTML=u.t("shop.upgradeEffects.improveQuarkHept3",{amount:2*e.shopUpgrades.improveQuarkHept3});break;case"improveQuarkHept4":n.innerHTML=u.t("shop.upgradeEffects.improveQuarkHept4",{amount:2*e.shopUpgrades.improveQuarkHept4});break;case"shopImprovedDaily":n.innerHTML=u.t("shop.upgradeEffects.shopImprovedDaily",{amount:d(5*e.shopUpgrades.shopImprovedDaily)});break;case"shopImprovedDaily2":n.innerHTML=u.t("shop.upgradeEffects.shopImprovedDaily2",{amount1:e.shopUpgrades.shopImprovedDaily2,amount2:e.shopUpgrades.shopImprovedDaily2*20});break;case"shopImprovedDaily3":n.innerHTML=u.t("shop.upgradeEffects.shopImprovedDaily3",{amount1:e.shopUpgrades.shopImprovedDaily3,amount2:e.shopUpgrades.shopImprovedDaily3*15});break;case"shopImprovedDaily4":n.innerHTML=u.t("shop.upgradeEffects.shopImprovedDaily4",{amount1:e.shopUpgrades.shopImprovedDaily4,amount2:e.shopUpgrades.shopImprovedDaily4*100});break;case"offeringEX3":n.innerHTML=u.t("shop.upgradeEffects.offeringEX3",{amount:d(100*(Math.pow(1.02,e.shopUpgrades.offeringEX3)-1),2,!0)});break;case"obtainiumEX3":n.innerHTML=u.t("shop.upgradeEffects.obtainiumEX3",{amount:d(100*(Math.pow(1.02,e.shopUpgrades.obtainiumEX3)-1),2,!0)});break;case"improveQuarkHept5":n.innerHTML=u.t("shop.upgradeEffects.improveQuarkHept5",{amount:d(e.shopUpgrades.improveQuarkHept5/25,2,!0)});break;case"seasonPassInfinity":n.innerHTML=u.t("shop.upgradeEffects.seasonPassInfinity",{amount:d(100*(Math.pow(1.02,e.shopUpgrades.seasonPassInfinity)-1),2,!0)});break;case"chronometerInfinity":n.innerHTML=u.t("shop.upgradeEffects.chronometerInfinity",{amount:d(100*(Math.pow(1.01,e.shopUpgrades.chronometerInfinity)-1),2,!0)});break;case"shopSingularityPenaltyDebuff":n.innerHTML=u.t("shop.upgradeEffects.shopSingularityPenaltyDebuff",{amount1:d(e.singularityCount),amount2:d(e.singularityCount-e.shopUpgrades.shopSingularityPenaltyDebuff)});break;case"shopAmbrosiaLuckMultiplier4":n.innerHTML=u.t("shop.upgradeEffects.shopAmbrosiaLuckMultiplier4",{amount:d(e.shopUpgrades.shopAmbrosiaLuckMultiplier4)});break;case"shopOcteractAmbrosiaLuck":n.innerHTML=u.t("shop.upgradeEffects.shopOcteractAmbrosiaLuck",{amount:d(e.shopUpgrades.shopOcteractAmbrosiaLuck*(1+Math.floor(Math.log10(e.totalWowOcteracts+1))))});break;case"shopAmbrosiaGeneration1":n.innerHTML=u.t("shop.upgradeEffects.shopAmbrosiaGeneration1",{amount:d(e.shopUpgrades.shopAmbrosiaGeneration1)});break;case"shopAmbrosiaGeneration2":n.innerHTML=u.t("shop.upgradeEffects.shopAmbrosiaGeneration2",{amount:d(e.shopUpgrades.shopAmbrosiaGeneration2)});break;case"shopAmbrosiaGeneration3":n.innerHTML=u.t("shop.upgradeEffects.shopAmbrosiaGeneration3",{amount:d(e.shopUpgrades.shopAmbrosiaGeneration3)});break;case"shopAmbrosiaGeneration4":n.innerHTML=u.t("shop.upgradeEffects.shopAmbrosiaGeneration4",{amount:d(e.shopUpgrades.shopAmbrosiaGeneration4/10,1,!0)});break;case"shopAmbrosiaLuck1":n.innerHTML=u.t("shop.upgradeEffects.shopAmbrosiaLuck1",{amount:d(2*e.shopUpgrades.shopAmbrosiaLuck1)});break;case"shopAmbrosiaLuck2":n.innerHTML=u.t("shop.upgradeEffects.shopAmbrosiaLuck2",{amount:d(2*e.shopUpgrades.shopAmbrosiaLuck2)});break;case"shopAmbrosiaLuck3":n.innerHTML=u.t("shop.upgradeEffects.shopAmbrosiaLuck3",{amount:d(2*e.shopUpgrades.shopAmbrosiaLuck3)});break;case"shopAmbrosiaLuck4":n.innerHTML=u.t("shop.upgradeEffects.shopAmbrosiaLuck4",{amount:d(6*e.shopUpgrades.shopAmbrosiaLuck4/10,1,!0)});break;case"shopCashGrabUltra":n.innerHTML=u.t("shop.upgradeEffects.shopCashGrabUltra",{amount:d(100*(po()-1),2,!0),amount2:d(100*(Fi()-1),2,!0),amount3:d(100*(go()-1),2,!0)});break;case"shopAmbrosiaAccelerator":n.innerHTML=u.t("shop.upgradeEffects.shopAmbrosiaAccelerator",{amount:d(.2*e.shopUpgrades.shopAmbrosiaAccelerator,1,!0),amount2:d(e.shopUpgrades.shopAmbrosiaAccelerator*.2*o.ambrosiaCurrStats.ambrosiaGenerationSpeed,0,!0)});break;case"shopEXUltra":{let s=125e3*e.shopUpgrades.shopEXUltra;n.innerHTML=u.t("shop.upgradeEffects.shopEXUltra",{amount:d(.1*Math.floor(Math.min(s,e.lifetimeAmbrosia)/1e3),1,!0)})}break;case"shopChronometerS":{let s=e.singularityCount,l=e.shopUpgrades.shopChronometerS>0;n.innerHTML=u.t("shop.upgradeEffects.shopChronometerS",{amount:d(Math.max(0,100*(Math.pow(1.01,(s-200)*+l)-1)),2,!0)})}break;case"shopAmbrosiaUltra":{let s=au();n.innerHTML=u.t("shop.upgradeEffects.shopAmbrosiaUltra",{amount:d(e.shopUpgrades.shopAmbrosiaUltra*s,0,!0)})}break;case"shopSingularitySpeedup":{let s=e.shopUpgrades.shopSingularitySpeedup>0;n.innerHTML=u.t("shop.upgradeEffects.shopSingularitySpeedup",{amount:s?50:1});break}case"shopSingularityPotency":{let s=e.shopUpgrades.shopSingularityPotency>0;n.innerHTML=u.t("shop.upgradeEffects.shopSingularityPotency",{amount:s?3.66:1})}break;case"shopSadisticRune":n.innerHTML=u.t("shop.upgradeEffects.shopSadisticRune")}},Oa=t=>({offeringPotion:"Offering Potion",obtainiumPotion:"Obtainium Potion",offeringEX:"Offering EX",offeringAuto:"Offering Auto",obtainiumEX:"Obtainium EX",obtainiumAuto:"Obtainium Auto",instantChallenge:"Instant Challenge Completions",antSpeed:"Ant Speed",cashGrab:"Cash Grab",shopTalisman:"the Plastic talisman",seasonPass:"Season Pass",challengeExtension:"Reincarnation Challenge EX",challengeTome:"Challenge 10 Requirement Reduce",cubeToQuark:"Cube Quarks +50%",tesseractToQuark:"Tesseract Quarks +50%",hypercubeToQuark:"Hypercube Quarks +50%",seasonPass2:"Season Pass 2",seasonPass3:"Season Pass 3",chronometer:"Chronometer 1",infiniteAscent:"Infinite Ascent",calculator:"PL-AT calculator",calculator2:"PL-AT X calculator",calculator3:"PL-AT \u03A9 calculator",calculator4:"PL-AT \u03B4 calculator",calculator5:"PL-AT \u0393 calculator",calculator6:"QUAAA-T calculator",calculator7:"PL-AT \u03A9\u03A9 calculator",constantEX:"Constant EX",powderEX:"Powder EX",chronometer2:"Chronometer 2",chronometer3:"Chronometer 3",seasonPassY:"Season Pass Y",seasonPassZ:"Season Pass Z",challengeTome2:"Challenge 10 Requirement Reduction 2",instantChallenge2:"Instant Challenge Completions 2",cubeToQuarkAll:"Quark Gain Cube Improvement 2",cashGrab2:"Cash Grab 2",chronometerZ:"Chronometer Z",obtainiumEX2:"Obtainium EX 2",offeringEX2:"Offering EX 2",powderAuto:"Automated Powder",seasonPassLost:"Season Pass LOST",challenge15Auto:"Challenge 15 Automation",extraWarp:"Extra Warp",autoWarp:"a quack powered Warps?",improveQuarkHept:"Quark Hepteract 1",improveQuarkHept2:"Quark Hepteract 2",improveQuarkHept3:"Quark Hepteract 3",improveQuarkHept4:"Quack Hepteract 4",shopImprovedDaily:"Improved Daily Code 1",shopImprovedDaily2:"Improved Daily Code 2",shopImprovedDaily3:"Improved Daily Code 3",shopImprovedDaily4:"Improved Daily Code 4",offeringEX3:"The final Offering Upgrade",obtainiumEX3:"The final Obtainium Upgrade",improveQuarkHept5:"The final Quark Hepteract Improver",chronometerInfinity:"The final Chronometer",seasonPassInfinity:"The final Season pass",shopSingularityPenaltyDebuff:"A Singularity Tenderizer",shopAmbrosiaLuckMultiplier4:"The Fourth Multiplicative Ambrosia Luck Multiplier",shopOcteractAmbrosiaLuck:"Octeract-Based Ambrosia Luck Amplifier",shopAmbrosiaGeneration1:"Ambrosia Generation Speedup",shopAmbrosiaGeneration2:"Another Ambrosia Generation Speedup",shopAmbrosiaGeneration3:"A better Ambrosia Generation Speedup",shopAmbrosiaGeneration4:"A FINAL Ambrosia Generation Speedup",shopAmbrosiaLuck1:"Ambrosia Luck Increaser",shopAmbrosiaLuck2:"Another Ambrosia Luck Increaser",shopAmbrosiaLuck3:"A better Ambrosia Generation Speedup",shopAmbrosiaLuck4:"A FINAL Ambrosia Generation Speedup",shopCashGrabUltra:"It's the FINAL CASHGRAB!",shopAmbrosiaAccelerator:"An Ambrosial Accelerator!",shopEXUltra:"It's the FINAL E X!",shopChronometerS:"The FINAL Chronometer",shopAmbrosiaUltra:"The FINAL Ambrosia Exaltation... I don't flippin know!",shopSingularitySpeedup:"Singularity Timed-Perks Speedup",shopSingularityPotency:"Singularity Passives Potency",shopSadisticRune:"Sadistic Rune Unlock! Or does it?"})[t],Gi=async t=>{let r=pe[t];if(e.shopUpgrades[t]>=r.maxLevel)return e.shopConfirmationToggle?P(`You can't purchase ${Oa(t)} because you are already at the maximum ${r.type==="upgrade"?"level":"capacity"}!`):null;if(Number(e.worlds)t+8*r,scalingrewardcount:1,uniquerewardcount:5,effect:t=>({cubes:1+.5*t,goldenQuarks:1+.12*+(t>0),blueberries:+(t>0),shopUpgrade:t>=20,luckBonus:t>=30?.04:0,shopUpgrade2:t>=30}),cacheUpdates:[()=>{o.ambrosiaCurrStats={ambrosiaAdditiveLuckMult:zr().value,ambrosiaLuck:Ge().value,ambrosiaBlueberries:ha().value,ambrosiaGenerationSpeed:De().value}}]},oneChallengeCap:{baseReq:10,maxCompletions:25,unlockSingularity:40,HTMLTag:"oneChallengeCap",singularityRequirement:(t,r)=>t+11*r,scalingrewardcount:2,uniquerewardcount:4,effect:t=>({corrScoreIncrease:.03*t,blueberrySpeedMult:1+t/100,capIncrease:3*+(t>0),freeCorruptionLevel:t>=20,shopUpgrade:t>=20,reinCapIncrease2:7*+(t>=25),ascCapIncrease2:2*+(t>=25)})},noOcteracts:{baseReq:75,maxCompletions:15,unlockSingularity:100,HTMLTag:"noOcteracts",singularityRequirement:(t,r)=>r<10?t+13*r:t+13*9+10*(r-9),scalingrewardcount:1,uniquerewardcount:3,effect:t=>({octeractPow:t<=10?.02*t:.2+(t-10)/100,offeringBonus:t>0,obtainiumBonus:t>=10,shopUpgrade:t>=10})},limitedAscensions:{baseReq:10,maxCompletions:25,unlockSingularity:50,HTMLTag:"limitedAscensions",singularityRequirement:(t,r)=>t+10*r,scalingrewardcount:1,uniquerewardcount:4,effect:t=>({ultimateProgressBarUnlock:t>0,ascensionSpeedMult:.1*t/100,hepteractCap:t>0,exaltBonus:t>=20,shopUpgrade:t>=25})},noAmbrosiaUpgrades:{baseReq:150,maxCompletions:20,unlockSingularity:166,HTMLTag:"noAmbrosiaUpgrades",singularityRequirement:(t,r)=>t+6*r,scalingrewardcount:2,uniquerewardcount:6,effect:t=>({bonusAmbrosia:+(t>0),blueberries:Math.floor(t/10)+ +(t>0),luckBonus:t/200,additiveLuck:15*t,blueberrySpeedMult:1+t/50,shopUpgrade:t>=15,shopUpgrade2:t>=20})},limitedTime:{baseReq:203,maxCompletions:25,unlockSingularity:216,HTMLTag:"limitedTime",singularityRequirement:(t,r)=>t+3*r,scalingrewardcount:3,uniquerewardcount:3,effect:t=>({preserveQuarks:+(t>0),quarkMult:.01*t,globalSpeed:.06*t,ascensionSpeed:.06*t,tier1Upgrade:t>=15,tier2Upgrade:t>=25})},sadisticPrequel:{baseReq:135,maxCompletions:30,unlockSingularity:273,HTMLTag:"sadisticPrequel",singularityRequirement:(t,r)=>t+3*r,scalingrewardcount:2,uniquerewardcount:4,effect:t=>({extraFree:50*+(t>0),quarkMult:.03*t,freeUpgradeMult:.03*t,shopUpgrade:t>=10,shopUpgrade2:t>=20,shopUpgrade3:t>=30})}};var W=y.custom(t=>{try{return new f(t),!0}catch(r){return!1}}).transform(t=>new f(t)),dr=t=>y.tuple([y.null()]).rest(t),Wn=(t,r)=>(t.lengthy.object(O({level:y.number(),toggleBuy:y.number(),freeLevels:y.number()},t.reduce((r,n)=>(r[n]=y.number(),r),{}))),ov=y.record(y.string(),y.boolean()).transform(t=>Object.fromEntries(Object.entries(t).filter(([r,n])=>/^\d+$/.test(r)))).transform(t=>{let r=Object.entries(M.toggles);for(let n of r)Object.hasOwn(t,n[0])||(t[n[0]]=n[1]);return t}),uu=y.string().regex(/^|-?\d+(\.\d{1,2})?$/),qi=y.string().regex(/^\d+$/),Kn=t=>y.object({AUTO:y.boolean().default(()=>M.hepteractCrafts[t].AUTO),BAL:y.number().default(()=>M.hepteractCrafts[t].BAL),BASE_CAP:y.number(),CAP:y.number().default(()=>M.hepteractCrafts[t].CAP),DISCOUNT:y.number().default(()=>M.hepteractCrafts[t].DISCOUNT),HEPTERACT_CONVERSION:y.number(),HTML_STRING:y.string().default(()=>M.hepteractCrafts[t].HTML_STRING),OTHER_CONVERSIONS:y.record(y.string(),y.number()),UNLOCKED:y.boolean().default(()=>M.hepteractCrafts[t].UNLOCKED)}),ji=y.object({firstPlayed:y.string().datetime().optional().default(()=>new Date().toISOString()),worlds:y.number().transform(t=>new $n(t)),coins:W,coinsThisPrestige:W,coinsThisTranscension:W,coinsThisReincarnation:W,coinsTotal:W,firstOwnedCoin:y.number(),firstGeneratedCoin:W,firstCostCoin:W,firstProduceCoin:y.number(),secondOwnedCoin:y.number(),secondGeneratedCoin:W,secondCostCoin:W,secondProduceCoin:y.number(),thirdOwnedCoin:y.number(),thirdGeneratedCoin:W,thirdCostCoin:W,thirdProduceCoin:y.number(),fourthOwnedCoin:y.number(),fourthGeneratedCoin:W,fourthCostCoin:W,fourthProduceCoin:y.number(),fifthOwnedCoin:y.number(),fifthGeneratedCoin:W,fifthCostCoin:W,fifthProduceCoin:y.number(),firstOwnedDiamonds:y.number(),firstGeneratedDiamonds:W,firstCostDiamonds:W,firstProduceDiamonds:y.number(),secondOwnedDiamonds:y.number(),secondGeneratedDiamonds:W,secondCostDiamonds:W,secondProduceDiamonds:y.number(),thirdOwnedDiamonds:y.number(),thirdGeneratedDiamonds:W,thirdCostDiamonds:W,thirdProduceDiamonds:y.number(),fourthOwnedDiamonds:y.number(),fourthGeneratedDiamonds:W,fourthCostDiamonds:W,fourthProduceDiamonds:y.number(),fifthOwnedDiamonds:y.number(),fifthGeneratedDiamonds:W,fifthCostDiamonds:W,fifthProduceDiamonds:y.number(),firstOwnedMythos:y.number(),firstGeneratedMythos:W,firstCostMythos:W,firstProduceMythos:y.number(),secondOwnedMythos:y.number(),secondGeneratedMythos:W,secondCostMythos:W,secondProduceMythos:y.number(),thirdOwnedMythos:y.number(),thirdGeneratedMythos:W,thirdCostMythos:W,thirdProduceMythos:y.number(),fourthOwnedMythos:y.number(),fourthGeneratedMythos:W,fourthCostMythos:W,fourthProduceMythos:y.number(),fifthOwnedMythos:y.number(),fifthGeneratedMythos:W,fifthCostMythos:W,fifthProduceMythos:y.number(),firstOwnedParticles:y.number(),firstGeneratedParticles:W,firstCostParticles:W,firstProduceParticles:y.number(),secondOwnedParticles:y.number(),secondGeneratedParticles:W,secondCostParticles:W,secondProduceParticles:y.number(),thirdOwnedParticles:y.number(),thirdGeneratedParticles:W,thirdCostParticles:W,thirdProduceParticles:y.number(),fourthOwnedParticles:y.number(),fourthGeneratedParticles:W,fourthCostParticles:W,fourthProduceParticles:y.number(),fifthOwnedParticles:y.number(),fifthGeneratedParticles:W,fifthCostParticles:W,fifthProduceParticles:y.number(),firstOwnedAnts:y.number().default(()=>M.firstOwnedAnts),firstGeneratedAnts:W,firstCostAnts:W,firstProduceAnts:y.number().default(()=>M.firstProduceAnts),secondOwnedAnts:y.number().default(()=>M.secondOwnedAnts),secondGeneratedAnts:W,secondCostAnts:W,secondProduceAnts:y.number().default(()=>M.secondProduceAnts),thirdOwnedAnts:y.number().default(()=>M.thirdOwnedAnts),thirdGeneratedAnts:W,thirdCostAnts:W,thirdProduceAnts:y.number().default(()=>M.thirdProduceAnts),fourthOwnedAnts:y.number().default(()=>M.fourthOwnedAnts),fourthGeneratedAnts:W,fourthCostAnts:W,fourthProduceAnts:y.number().default(()=>M.fourthProduceAnts),fifthOwnedAnts:y.number().default(()=>M.fifthOwnedAnts),fifthGeneratedAnts:W,fifthCostAnts:W,fifthProduceAnts:y.number().default(()=>M.fifthProduceAnts),sixthOwnedAnts:y.number().default(()=>M.sixthOwnedAnts),sixthGeneratedAnts:W,sixthCostAnts:W,sixthProduceAnts:y.number().default(()=>M.sixthProduceAnts),seventhOwnedAnts:y.number().default(()=>M.seventhOwnedAnts),seventhGeneratedAnts:W,seventhCostAnts:W,seventhProduceAnts:y.number().default(()=>M.seventhProduceAnts),eighthOwnedAnts:y.number().default(()=>M.eighthOwnedAnts),eighthGeneratedAnts:W,eighthCostAnts:W,eighthProduceAnts:y.number().default(()=>M.eighthProduceAnts),ascendBuilding1:fo.default(()=>Hr(M.ascendBuilding1)),ascendBuilding2:fo.default(()=>Hr(M.ascendBuilding2)),ascendBuilding3:fo.default(()=>Hr(M.ascendBuilding3)),ascendBuilding4:fo.default(()=>Hr(M.ascendBuilding4)),ascendBuilding5:fo.default(()=>Hr(M.ascendBuilding5)),multiplierCost:W,multiplierBought:y.number(),acceleratorCost:W,acceleratorBought:y.number(),acceleratorBoostBought:y.number(),acceleratorBoostCost:W,upgrades:y.number().array().transform(t=>(t.length{let r=Object.values(t);return Ic(r,0,M.challengecompletions.length),r})]),highestchallengecompletions:y.union([y.union([y.number(),y.null()]).array(),y.record(y.string(),y.number()).transform(t=>{let r=Object.values(t);return Ic(r,0,M.highestchallengecompletions.length),r})]),challenge15Exponent:y.number().default(()=>M.challenge15Exponent),highestChallenge15Exponent:y.number().default(()=>M.highestChallenge15Exponent),retrychallenges:y.boolean().default(()=>M.retrychallenges),currentChallenge:y.union([y.string().transform(()=>O({},M.currentChallenge)),y.object({transcension:y.number(),reincarnation:y.number(),ascension:y.number()}).default(()=>O({},M.currentChallenge))]),researchPoints:y.number(),obtainiumtimer:y.number(),obtainiumpersecond:y.number().default(()=>M.obtainiumpersecond),maxobtainiumpersecond:y.number().default(()=>M.maxobtainiumpersecond),maxobtainium:y.number().default(()=>M.maxobtainium),researches:y.number().array().transform(t=>Wn(t,"researches")),unlocks:y.record(y.string(),y.boolean()),achievements:y.number().array().transform(t=>Wn(t,"achievements")),achievementPoints:y.number(),prestigenomultiplier:y.boolean(),prestigenoaccelerator:y.boolean(),transcendnomultiplier:y.boolean(),transcendnoaccelerator:y.boolean(),reincarnatenomultiplier:y.boolean(),reincarnatenoaccelerator:y.boolean(),prestigenocoinupgrades:y.boolean(),transcendnocoinupgrades:y.boolean(),transcendnocoinorprestigeupgrades:y.boolean(),reincarnatenocoinupgrades:y.boolean(),reincarnatenocoinorprestigeupgrades:y.boolean(),reincarnatenocoinprestigeortranscendupgrades:y.boolean(),reincarnatenocoinprestigetranscendorgeneratorupgrades:y.boolean(),crystalUpgrades:y.number().array(),crystalUpgradesCost:y.number().array().default(()=>[...M.crystalUpgradesCost]),runelevels:y.number().array().transform(t=>Wn(t,"runelevels")),runeexp:y.union([y.number(),y.null().transform(()=>0)]).array().transform(t=>Wn(t,"runeexp")),runeshards:y.number(),maxofferings:y.number().default(()=>M.maxofferings),offeringpersecond:y.number().default(()=>M.offeringpersecond),prestigecounter:y.number(),transcendcounter:y.number(),reincarnationcounter:y.number(),offlinetick:y.number(),prestigeamount:y.union([y.number(),uu.transform(Number)]),transcendamount:y.union([y.number(),uu.transform(Number)]).default(()=>M.transcendamount),reincarnationamount:y.union([y.number(),uu.transform(Number)]),fastestprestige:y.number(),fastesttranscend:y.number(),fastestreincarnate:y.number(),resettoggle1:y.number().default(()=>M.resettoggle1),resettoggle2:y.number().default(()=>M.resettoggle2),resettoggle3:y.number().default(()=>M.resettoggle3),resettoggle4:y.number().default(()=>M.resettoggle4),tesseractAutoBuyerToggle:y.number().default(()=>M.tesseractAutoBuyerToggle),tesseractAutoBuyerAmount:y.number().default(()=>M.tesseractAutoBuyerAmount),coinbuyamount:y.number(),crystalbuyamount:y.number(),mythosbuyamount:y.number(),particlebuyamount:y.number(),offeringbuyamount:y.number(),tesseractbuyamount:y.number().default(()=>M.tesseractbuyamount),shoptoggles:y.record(y.string(),y.boolean()),tabnumber:y.number(),subtabNumber:y.number().default(()=>M.subtabNumber),codes:y.array(y.tuple([y.number(),y.boolean()])).transform(t=>new Map(t)).default(()=>Hr([...M.codes])),loaded1009:y.boolean().default(()=>M.loaded1009),loaded1009hotfix1:y.boolean().default(()=>M.loaded1009hotfix1),loaded10091:y.boolean().default(()=>M.loaded10091),loaded1010:y.boolean().default(()=>M.loaded1010),loaded10101:y.boolean().default(()=>M.loaded10101),shopUpgrades:y.record(y.string(),y.union([y.number(),y.null(),y.boolean()])).transform(t=>Object.fromEntries(Object.keys(M.shopUpgrades).map(r=>{var a;let n=(a=t[r])!=null?a:M.shopUpgrades[r];return n===null?[r,0]:[r,Number(n)]}))).default(()=>O({},M.shopUpgrades)),shopBuyMaxToggle:y.union([y.boolean(),y.string()]).default(()=>M.shopBuyMaxToggle),shopHideToggle:y.boolean().default(()=>M.shopHideToggle),shopConfirmationToggle:y.boolean().default(()=>M.shopConfirmationToggle),autoPotionTimer:y.number().default(()=>M.autoPotionTimer),autoPotionTimerObtainium:y.number().default(()=>M.autoPotionTimerObtainium),autoSacrificeToggle:y.boolean().default(()=>M.autoSacrificeToggle),autoBuyFragment:y.boolean().default(()=>M.autoBuyFragment),autoFortifyToggle:y.boolean().default(()=>M.autoFortifyToggle),autoEnhanceToggle:y.boolean().default(()=>M.autoEnhanceToggle),autoResearchToggle:y.boolean().default(()=>M.autoResearchToggle),researchBuyMaxToggle:y.boolean().default(()=>M.researchBuyMaxToggle),autoResearchMode:y.string().default(()=>M.autoResearchMode),autoResearch:y.number().default(()=>M.autoResearch),autoSacrifice:y.number().default(()=>M.autoSacrifice),sacrificeTimer:y.number().default(()=>M.sacrificeTimer),quarkstimer:y.number().default(()=>M.quarkstimer),goldenQuarksTimer:y.number().default(()=>M.goldenQuarksTimer),antPoints:W,antUpgrades:y.union([y.number().array(),dr(y.number()).transform(t=>t.slice(1))]).default(()=>[...M.antUpgrades]),antSacrificePoints:y.union([y.number(),y.null().transform(()=>Number.MAX_VALUE)]).default(()=>M.antSacrificePoints),antSacrificeTimer:y.number().default(()=>M.antSacrificeTimer),antSacrificeTimerReal:y.number().default(()=>M.antSacrificeTimerReal),talismanLevels:y.union([y.number().array(),dr(y.number()).transform(t=>t.slice(1))]).default(()=>[...M.talismanLevels]),talismanRarity:y.union([y.number().array(),dr(y.number()).transform(t=>t.slice(1))]).default(()=>[...M.talismanRarity]),talismanOne:dr(y.number()).default(()=>M.talismanOne),talismanTwo:dr(y.number()).default(()=>M.talismanTwo),talismanThree:dr(y.number()).default(()=>M.talismanThree),talismanFour:dr(y.number()).default(()=>M.talismanFour),talismanFive:dr(y.number()).default(()=>M.talismanFive),talismanSix:dr(y.number()).default(()=>M.talismanSix),talismanSeven:dr(y.number()).default(()=>M.talismanSeven),talismanShards:y.number().default(()=>M.talismanShards),commonFragments:y.number().default(()=>M.commonFragments),uncommonFragments:y.number().default(()=>M.uncommonFragments),rareFragments:y.number().default(()=>M.rareFragments),epicFragments:y.number().default(()=>M.epicFragments),legendaryFragments:y.number().default(()=>M.legendaryFragments),mythicalFragments:y.number().default(()=>M.mythicalFragments),buyTalismanShardPercent:y.number().default(()=>M.buyTalismanShardPercent),autoAntSacrifice:y.boolean().default(()=>M.autoAntSacrifice),autoAntSacTimer:y.number().default(()=>M.autoAntSacTimer),autoAntSacrificeMode:y.number().default(()=>M.autoAntSacrificeMode),antMax:y.boolean().default(()=>M.antMax),ascensionCount:y.number().default(()=>M.ascensionCount),ascensionCounter:y.number().default(()=>M.ascensionCounter),ascensionCounterReal:y.number().default(()=>M.ascensionCounterReal),ascensionCounterRealReal:y.number().default(()=>M.ascensionCounterRealReal),cubeUpgrades:dr(y.number()).transform(t=>Wn(t,"cubeUpgrades")).default(()=>[...M.cubeUpgrades]),cubeUpgradesBuyMaxToggle:y.boolean().default(()=>M.cubeUpgradesBuyMaxToggle),autoCubeUpgradesToggle:y.boolean().default(()=>M.autoCubeUpgradesToggle),autoPlatonicUpgradesToggle:y.boolean().default(()=>M.autoPlatonicUpgradesToggle),platonicUpgrades:y.number().array().transform(t=>Wn(t,"platonicUpgrades")).default(()=>[...M.platonicUpgrades]),wowCubes:y.number().default(()=>Number(M.wowCubes)).transform(t=>new nr(t)),wowTesseracts:y.number().default(()=>Number(M.wowTesseracts)).transform(t=>new ca(t)),wowHypercubes:y.number().default(()=>Number(M.wowHypercubes)).transform(t=>new ua(t)),wowPlatonicCubes:y.number().default(()=>Number(M.wowPlatonicCubes)).transform(t=>new da(t)),saveOfferingToggle:y.boolean().default(()=>M.saveOfferingToggle),wowAbyssals:y.number().default(()=>M.wowAbyssals),wowOcteracts:y.number().default(()=>M.wowOcteracts),totalWowOcteracts:y.number().default(()=>M.totalWowOcteracts),cubeBlessings:y.record(y.string(),y.number()).default(()=>O({},M.cubeBlessings)),tesseractBlessings:y.record(y.string(),y.number()).default(()=>O({},M.tesseractBlessings)),hypercubeBlessings:y.record(y.string(),y.number()).default(()=>O({},M.hypercubeBlessings)),platonicBlessings:y.record(y.string(),y.number()).default(()=>O({},M.platonicBlessings)),hepteractCrafts:y.object({chronos:Kn("chronos"),hyperrealism:Kn("hyperrealism"),quark:Kn("quark"),challenge:Kn("challenge"),abyss:Kn("abyss"),accelerator:Kn("accelerator"),acceleratorBoost:Kn("acceleratorBoost"),multiplier:Kn("multiplier")}).transform(t=>Object.fromEntries(Object.entries(M.hepteractCrafts).map(([r,n])=>[r,Ig(O(O({},n),t[r]))]))).default(()=>M.hepteractCrafts),ascendShards:W.default(()=>Hr(M.ascendShards)),autoAscend:y.boolean().default(()=>M.autoAscend),autoAscendMode:y.string().default(()=>M.autoAscendMode),autoAscendThreshold:y.number().default(()=>M.autoAscendThreshold),autoOpenCubes:y.boolean().default(()=>M.autoOpenCubes),openCubes:y.number().default(()=>M.openCubes),autoOpenTesseracts:y.boolean().default(()=>M.autoOpenTesseracts),openTesseracts:y.number().default(()=>M.openTesseracts),autoOpenHypercubes:y.boolean().default(()=>M.autoOpenHypercubes),openHypercubes:y.number().default(()=>M.openHypercubes),autoOpenPlatonicsCubes:y.boolean().default(()=>M.autoOpenPlatonicsCubes),openPlatonicsCubes:y.number().default(()=>M.openPlatonicsCubes),roombaResearchIndex:y.number().default(()=>M.roombaResearchIndex),ascStatToggles:y.record(qi,y.boolean()).default(()=>O({},M.ascStatToggles)),prototypeCorruptions:y.number().array().default(()=>[...M.prototypeCorruptions]),usedCorruptions:y.number().array().transform(t=>Wn(t,"usedCorruptions")).default(()=>[...M.usedCorruptions]),corruptionLoadouts:y.record(qi,y.number().array()).default(()=>Hr(M.corruptionLoadouts)),corruptionLoadoutNames:y.string().array().default(()=>M.corruptionLoadoutNames.slice()).default(()=>[...M.corruptionLoadoutNames]),corruptionShowStats:y.boolean().default(()=>M.corruptionShowStats),constantUpgrades:dr(y.number()).default(()=>[...M.constantUpgrades]),history:y.object({ants:y.any().array(),ascend:y.any().array().default(()=>[...M.history.ascend]),reset:y.any().array().default(()=>[...M.history.reset]),singularity:y.any().array().default(()=>[...M.history.singularity])}).default(()=>Hr(M.history)),historyShowPerSecond:y.boolean().default(()=>M.historyShowPerSecond),autoChallengeRunning:y.boolean().default(()=>M.autoChallengeRunning),autoChallengeIndex:y.number().default(()=>M.autoChallengeIndex),autoChallengeToggles:y.boolean().array().default(()=>[...M.autoChallengeToggles]),autoChallengeStartExponent:y.number().default(()=>M.autoChallengeStartExponent),autoChallengeTimer:y.record(y.string(),y.number()).default(()=>O({},M.autoChallengeTimer)),runeBlessingLevels:y.number().array().default(()=>[...M.runeBlessingLevels]),runeSpiritLevels:y.number().array().default(()=>[...M.runeSpiritLevels]),runeBlessingBuyAmount:y.number().default(()=>M.runeBlessingBuyAmount),runeSpiritBuyAmount:y.number().default(()=>M.runeSpiritBuyAmount),autoTesseracts:y.boolean().array().default(()=>[...M.autoTesseracts]),saveString:y.string().default(()=>M.saveString),exporttest:y.union([y.string(),y.boolean()]).transform(t=>typeof t=="string"?t==="YES!":t),dayCheck:y.string().datetime().nullable().default(()=>M.dayCheck).transform(t=>t===null?t:new Date(t)),dayTimer:y.number().default(()=>M.dayTimer),cubeOpenedDaily:y.number().default(()=>M.cubeOpenedDaily),cubeQuarkDaily:y.number().default(()=>M.cubeQuarkDaily),tesseractOpenedDaily:y.number().default(()=>M.tesseractOpenedDaily),tesseractQuarkDaily:y.number().default(()=>M.tesseractQuarkDaily),hypercubeOpenedDaily:y.number().default(()=>M.hypercubeOpenedDaily),hypercubeQuarkDaily:y.number().default(()=>M.hypercubeQuarkDaily),platonicCubeOpenedDaily:y.number().default(()=>M.platonicCubeOpenedDaily),platonicCubeQuarkDaily:y.number().default(()=>M.platonicCubeQuarkDaily),overfluxOrbs:y.number().default(()=>M.overfluxOrbs),overfluxOrbsAutoBuy:y.boolean().default(()=>M.overfluxOrbsAutoBuy),overfluxPowder:y.number().default(()=>M.overfluxPowder),dailyPowderResetUses:y.number().default(()=>M.dailyPowderResetUses),autoWarpCheck:y.boolean().default(()=>M.autoWarpCheck),loadedOct4Hotfix:y.boolean().default(()=>M.loadedOct4Hotfix),loadedNov13Vers:y.boolean().default(()=>M.loadedNov13Vers),loadedDec16Vers:y.boolean().default(()=>M.loadedDec16Vers),loadedV253:y.boolean().default(()=>M.loadedV253),loadedV255:y.boolean().default(()=>M.loadedV255),loadedV297Hotfix1:y.boolean().default(()=>M.loadedV297Hotfix1),loadedV2927Hotfix1:y.boolean().default(()=>M.loadedV2927Hotfix1),loadedV2930Hotfix1:y.boolean().default(()=>M.loadedV2930Hotfix1),loadedV2931Hotfix1:y.boolean().default(()=>M.loadedV2931Hotfix1),loadedV21003Hotfix1:y.boolean().default(()=>M.loadedV21003Hotfix1),loadedV21007Hotfix1:y.boolean().default(()=>M.loadedV21007Hotfix1),version:y.string().default(()=>M.version),rngCode:y.number().default(()=>M.rngCode),promoCodeTiming:y.record(y.string(),y.number()).default(()=>({time:Date.now()-60*1e3*15})),singularityCount:y.number().default(()=>M.singularityCount),highestSingularityCount:y.number().default(()=>M.highestSingularityCount),singularityCounter:y.number().default(()=>M.singularityCount),goldenQuarks:y.number().default(()=>M.goldenQuarks),quarksThisSingularity:y.number().nullable().default(()=>M.quarksThisSingularity),totalQuarksEver:y.number().default(()=>M.totalQuarksEver),hotkeys:y.record(qi,y.string().array()).default(()=>M.hotkeys),theme:y.string().default(()=>M.theme),iconSet:y.number().default(()=>M.iconSet),notation:y.string().default(()=>M.notation),singularityUpgrades:y.record(y.string(),cu("goldenQuarksInvested")).transform(t=>Object.fromEntries(Object.keys(F).map(r=>{var c;let{level:n,goldenQuarksInvested:a,toggleBuy:s,freeLevels:l}=(c=t[r])!=null?c:F[r];return[r,new V({maxLevel:F[r].maxLevel,costPerLevel:F[r].costPerLevel,level:n,goldenQuarksInvested:a,toggleBuy:s,freeLevels:l,minimumSingularity:F[r].minimumSingularity,effect:F[r].effect,canExceedCap:F[r].canExceedCap,specialCostForm:F[r].specialCostForm,qualityOfLife:F[r].qualityOfLife,cacheUpdates:F[r].cacheUpdates},r)]}))).default(()=>JSON.parse(JSON.stringify(M.singularityUpgrades))),octeractUpgrades:y.record(y.string(),cu("octeractsInvested")).transform(t=>Object.fromEntries(Object.keys(le).map(r=>{var c;let{level:n,octeractsInvested:a,toggleBuy:s,freeLevels:l}=(c=t[r])!=null?c:le[r];return[r,new fe({maxLevel:le[r].maxLevel,costPerLevel:le[r].costPerLevel,level:n,octeractsInvested:a,toggleBuy:s,effect:le[r].effect,costFormula:le[r].costFormula,freeLevels:l,qualityOfLife:le[r].qualityOfLife,cacheUpdates:le[r].cacheUpdates},r)]}))).default(()=>JSON.parse(JSON.stringify(M.octeractUpgrades))),dailyCodeUsed:y.boolean().default(()=>M.dailyCodeUsed),hepteractAutoCraftPercentage:y.number().default(()=>M.hepteractAutoCraftPercentage),octeractTimer:y.number().default(()=>M.octeractTimer),insideSingularityChallenge:y.boolean().default(()=>M.insideSingularityChallenge),singularityChallenges:y.record(y.string(),y.object({completions:y.number(),highestSingularityCompleted:y.number(),enabled:y.boolean()})).transform(t=>Object.fromEntries(Object.keys(M.singularityChallenges).map(r=>{var l;let{completions:n,highestSingularityCompleted:a,enabled:s}=(l=t[r])!=null?l:M.singularityChallenges[r];return[r,new ur({baseReq:Ze[r].baseReq,completions:n,maxCompletions:Ze[r].maxCompletions,unlockSingularity:Ze[r].unlockSingularity,HTMLTag:Ze[r].HTMLTag,highestSingularityCompleted:a,enabled:s,resetTime:Ze[r].resetTime,singularityRequirement:Ze[r].singularityRequirement,scalingrewardcount:Ze[r].scalingrewardcount,uniquerewardcount:Ze[r].uniquerewardcount,effect:Ze[r].effect,cacheUpdates:Ze[r].cacheUpdates},r)]}))).default(()=>JSON.parse(JSON.stringify(M.singularityChallenges))),ambrosia:y.number().default(()=>M.ambrosia),lifetimeAmbrosia:y.number().default(()=>M.lifetimeAmbrosia),ambrosiaRNG:y.number().default(()=>M.ambrosiaRNG),blueberryTime:y.number().default(()=>M.blueberryTime),visitedAmbrosiaSubtab:y.boolean().default(()=>M.visitedAmbrosiaSubtab),spentBlueberries:y.number().default(()=>M.spentBlueberries),blueberryUpgrades:y.record(y.string(),cu("blueberriesInvested","ambrosiaInvested")).transform(t=>Object.fromEntries(Object.keys(M.blueberryUpgrades).map(r=>{var p;let{level:n,ambrosiaInvested:a,blueberriesInvested:s,toggleBuy:l,freeLevels:c}=(p=t[r])!=null?p:M.blueberryUpgrades[r];return[r,new Ke({maxLevel:$e[r].maxLevel,costPerLevel:$e[r].costPerLevel,level:n,ambrosiaInvested:a,blueberriesInvested:s,toggleBuy:l,blueberryCost:$e[r].blueberryCost,rewards:$e[r].rewards,costFormula:$e[r].costFormula,freeLevels:c,prerequisites:$e[r].prerequisites,cacheUpdates:$e[r].cacheUpdates},r)]}))).default(()=>JSON.parse(JSON.stringify(M.blueberryUpgrades))),blueberryLoadouts:y.record(qi,y.any()).default(()=>M.blueberryLoadouts),blueberryLoadoutMode:y.string().default(()=>M.blueberryLoadoutMode),ultimateProgress:y.number().default(()=>M.ultimateProgress),ultimatePixels:y.number().default(()=>M.ultimatePixels),cubeUpgradeRedBarFilled:y.number().default(()=>M.cubeUpgradeRedBarFilled),singChallengeTimer:y.number().default(()=>M.singChallengeTimer),caches:y.record(y.string(),y.any()).transform(()=>(Object.values(M.caches).map(t=>t.reset()),M.caches)).default(()=>(Object.values(M.caches).map(t=>t.reset()),M.caches)),lastExportedSave:y.number().default(()=>M.lastExportedSave),seed:y.number().array().default(()=>M.seed).transform(t=>Wn(t,"seed")).refine(t=>t.every(r=>r>Date.parse("2020-01-01T00:00:00Z")&&rArray.from(t)),worlds:y.any().transform(t=>Number(t)),wowCubes:y.any().transform(t=>Number(t)),wowTesseracts:y.any().transform(t=>Number(t)),wowHypercubes:y.any().transform(t=>Number(t)),wowPlatonicCubes:y.any().transform(t=>Number(t)),singularityUpgrades:y.any().transform(t=>Object.fromEntries(Object.entries(t).map(([r,n])=>[r,{level:n.level,goldenQuarksInvested:n.goldenQuarksInvested,toggleBuy:n.toggleBuy,freeLevels:n.freeLevels}]))),octeractUpgrades:y.any().transform(t=>Object.fromEntries(Object.entries(t).map(([r,n])=>[r,{level:n.level,octeractsInvested:n.octeractsInvested,toggleBuy:n.toggleBuy,freeLevels:n.freeLevels}]))),singularityChallenges:y.any().transform(t=>Object.fromEntries(Object.entries(t).map(([r,n])=>[r,{completions:n.completions,highestSingularityCompleted:n.highestSingularityCompleted,enabled:n.enabled}]))),blueberryUpgrades:y.any().transform(t=>Object.fromEntries(Object.entries(t).map(([r,n])=>[r,{level:n.level,ambrosiaInvested:n.ambrosiaInvested,blueberriesInvested:n.blueberriesInvested,toggleBuy:n.toggleBuy,freeLevels:n.freeLevels}]))),dayCheck:y.any().transform(t=>{var r;return(r=t==null?void 0:t.toISOString())!=null?r:null})});var pe={offeringPotion:{price:100,priceIncrease:0,maxLevel:999999999,type:"consume",refundable:!1,refundMinimumLevel:0,tier:"Reincarnation"},obtainiumPotion:{tier:"Reincarnation",price:100,priceIncrease:0,maxLevel:999999999,type:"consume",refundable:!1,refundMinimumLevel:0},offeringEX:{tier:"Reincarnation",price:150,priceIncrease:10,maxLevel:100,type:"upgrade",refundable:!0,refundMinimumLevel:0},offeringAuto:{tier:"Reincarnation",price:150,priceIncrease:10,maxLevel:100,type:"upgrade",refundable:!0,refundMinimumLevel:1},obtainiumEX:{tier:"Reincarnation",price:150,priceIncrease:10,maxLevel:100,type:"upgrade",refundable:!0,refundMinimumLevel:0},obtainiumAuto:{tier:"Reincarnation",price:150,priceIncrease:10,maxLevel:100,type:"upgrade",refundable:!0,refundMinimumLevel:1},instantChallenge:{tier:"Reincarnation",price:300,priceIncrease:99999,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},antSpeed:{tier:"Reincarnation",price:200,priceIncrease:25,maxLevel:100,type:"upgrade",refundable:!0,refundMinimumLevel:0},cashGrab:{tier:"Reincarnation",price:100,priceIncrease:40,maxLevel:100,type:"upgrade",refundable:!0,refundMinimumLevel:0},shopTalisman:{tier:"Reincarnation",price:1500,priceIncrease:99999,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},seasonPass:{tier:"Ascension",price:500,priceIncrease:75,maxLevel:100,type:"upgrade",refundable:!0,refundMinimumLevel:0},challengeExtension:{tier:"Ascension",price:500,priceIncrease:250,maxLevel:5,type:"upgrade",refundable:!1,refundMinimumLevel:0},challengeTome:{tier:"Ascension",price:500,priceIncrease:250,maxLevel:15,type:"upgrade",refundable:!1,refundMinimumLevel:0},cubeToQuark:{tier:"Ascension",price:2e3,priceIncrease:99999,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},tesseractToQuark:{tier:"Ascension",price:3500,priceIncrease:99999,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},hypercubeToQuark:{tier:"Ascension",price:5e3,priceIncrease:99999,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},seasonPass2:{tier:"Ascension",price:2e3,priceIncrease:200,maxLevel:100,type:"upgrade",refundable:!0,refundMinimumLevel:0},seasonPass3:{tier:"Ascension",price:5e3,priceIncrease:500,maxLevel:100,type:"upgrade",refundable:!0,refundMinimumLevel:0},chronometer:{tier:"Ascension",price:1600,priceIncrease:400,maxLevel:100,type:"upgrade",refundable:!0,refundMinimumLevel:0},infiniteAscent:{tier:"Ascension",price:25e3,priceIncrease:9999999,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},calculator:{tier:"Reincarnation",price:500,priceIncrease:300,maxLevel:5,type:"upgrade",refundable:!1,refundMinimumLevel:1},calculator2:{tier:"Ascension",price:2500,priceIncrease:800,maxLevel:12,type:"upgrade",refundable:!1,refundMinimumLevel:0},calculator3:{tier:"Ascension",price:7500,priceIncrease:1500,maxLevel:10,type:"upgrade",refundable:!1,refundMinimumLevel:0},calculator4:{tier:"Singularity",price:1e7,priceIncrease:1e6,maxLevel:10,type:"upgrade",refundable:!1,refundMinimumLevel:0},calculator5:{tier:"SingularityVol2",price:1e8,priceIncrease:1e8,maxLevel:100,type:"upgrade",refundable:!1,refundMinimumLevel:0},calculator6:{tier:"SingularityVol3",price:1e11,priceIncrease:2e10,maxLevel:100,type:"upgrade",refundable:!1,refundMinimumLevel:0},constantEX:{tier:"Ascension",price:1e5,priceIncrease:899999,maxLevel:2,type:"upgrade",refundable:!1,refundMinimumLevel:0},powderEX:{tier:"Ascension",price:1e3,priceIncrease:750,maxLevel:50,type:"upgrade",refundable:!1,refundMinimumLevel:0},chronometer2:{tier:"Ascension",price:5e3,priceIncrease:1500,maxLevel:100,type:"upgrade",refundable:!0,refundMinimumLevel:0},chronometer3:{tier:"Singularity",price:250,priceIncrease:250,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},seasonPassY:{tier:"Ascension",price:1e4,priceIncrease:1500,maxLevel:100,type:"upgrade",refundable:!0,refundMinimumLevel:0},seasonPassZ:{tier:"Singularity",price:250,priceIncrease:250,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},challengeTome2:{tier:"Singularity",price:1e6,priceIncrease:1e6,maxLevel:5,type:"upgrade",refundable:!1,refundMinimumLevel:0},instantChallenge2:{tier:"Singularity",price:2e7,priceIncrease:0,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},cubeToQuarkAll:{tier:"SingularityVol2",price:2222222,priceIncrease:0,maxLevel:100,type:"upgrade",refundable:!1,refundMinimumLevel:0},cashGrab2:{tier:"SingularityVol2",price:5e3,priceIncrease:5e3,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},chronometerZ:{tier:"SingularityVol2",price:12500,priceIncrease:12500,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},offeringEX2:{tier:"SingularityVol2",price:1e4,priceIncrease:1e4,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},obtainiumEX2:{tier:"SingularityVol2",price:1e4,priceIncrease:1e4,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},powderAuto:{tier:"SingularityVol2",price:5e6,priceIncrease:0,maxLevel:100,type:"upgrade",refundable:!1,refundMinimumLevel:0},seasonPassLost:{tier:"SingularityVol2",price:1e6,priceIncrease:25e3,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},challenge15Auto:{tier:"SingularityVol3",price:5e11,priceIncrease:0,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},extraWarp:{tier:"SingularityVol3",price:125e9,priceIncrease:0,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},autoWarp:{tier:"SingularityVol3",price:5e11,priceIncrease:0,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},improveQuarkHept:{tier:"Ascension",price:2e5-1,priceIncrease:0,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},improveQuarkHept2:{tier:"Singularity",price:2e7-1,priceIncrease:0,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},improveQuarkHept3:{tier:"SingularityVol2",price:2e9-1,priceIncrease:0,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},improveQuarkHept4:{tier:"SingularityVol3",price:2e11-1,priceIncrease:0,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopImprovedDaily:{tier:"Ascension",price:5e3,priceIncrease:2500,maxLevel:20,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopImprovedDaily2:{tier:"Singularity",price:5e5,priceIncrease:5e5,maxLevel:10,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopImprovedDaily3:{tier:"SingularityVol2",price:5e6,priceIncrease:125e5,maxLevel:15,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopImprovedDaily4:{tier:"SingularityVol3",price:5e9,priceIncrease:5e9,maxLevel:25,type:"upgrade",refundable:!1,refundMinimumLevel:0},offeringEX3:{tier:"SingularityVol3",price:1,priceIncrease:125e10,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},obtainiumEX3:{tier:"SingularityVol3",price:1,priceIncrease:125e10,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},improveQuarkHept5:{tier:"SingularityVol4",price:1,priceIncrease:25e12,maxLevel:100,type:"upgrade",refundable:!1,refundMinimumLevel:0},chronometerInfinity:{tier:"SingularityVol4",price:1,priceIncrease:25e11,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},seasonPassInfinity:{tier:"SingularityVol4",price:1,priceIncrease:375e10,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopSingularityPenaltyDebuff:{tier:"Exalt1",price:1e17,priceIncrease:999e17,maxLevel:4,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopAmbrosiaLuckMultiplier4:{tier:"Exalt2",price:1e20,priceIncrease:3e20,maxLevel:4,type:"upgrade",refundable:!1,refundMinimumLevel:0},calculator7:{tier:"Exalt3",price:1e20,priceIncrease:1e19,maxLevel:50,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopOcteractAmbrosiaLuck:{tier:"Exalt4",price:1e21,priceIncrease:9e21,maxLevel:2,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopAmbrosiaGeneration1:{tier:"SingularityVol2",price:5e7,priceIncrease:5e7,maxLevel:25,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopAmbrosiaGeneration2:{tier:"SingularityVol3",price:5e11,priceIncrease:5e11,maxLevel:30,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopAmbrosiaGeneration3:{tier:"SingularityVol4",price:5e13,priceIncrease:5e13,maxLevel:35,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopAmbrosiaGeneration4:{tier:"SingularityVol4",price:1e17,priceIncrease:4*1e16,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopAmbrosiaLuck1:{tier:"SingularityVol2",price:2e7,priceIncrease:2e7,maxLevel:40,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopAmbrosiaLuck2:{tier:"SingularityVol3",price:2e11,priceIncrease:2e11,maxLevel:50,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopAmbrosiaLuck3:{tier:"SingularityVol4",price:2e13,priceIncrease:2e13,maxLevel:60,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopAmbrosiaLuck4:{tier:"SingularityVol4",price:1e17,priceIncrease:4*1e16,maxLevel:1e3,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopCashGrabUltra:{tier:"Exalt1x30",price:1,priceIncrease:1e22,maxLevel:5,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopAmbrosiaAccelerator:{tier:"Exalt5",price:1e21,priceIncrease:2e21,maxLevel:5,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopEXUltra:{tier:"Exalt5x20",price:5e21,priceIncrease:0,maxLevel:80,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopChronometerS:{tier:"Exalt6x15",price:5e21,priceIncrease:0,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopAmbrosiaUltra:{tier:"Exalt6x25",price:8e23,priceIncrease:2e23,maxLevel:5,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopSingularitySpeedup:{tier:"Exalt7x10",price:2e22,priceIncrease:0,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopSingularityPotency:{tier:"Exalt7x20",price:2e23,priceIncrease:0,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0},shopSadisticRune:{tier:"Exalt7x30",price:444e22,priceIncrease:0,maxLevel:1,type:"upgrade",refundable:!1,refundMinimumLevel:0}},$a=t=>{if(pe[t].type==="consume"||pe[t].maxLevel===1)return pe[t].price;{let r=e.shopUpgrades[t];return pe[t].price+pe[t].priceIncrease*r}},pr=t=>{let r=i("quarkdescription"),n=i("quarkeffect"),a=i("quarkRefundable");switch(r.innerHTML=u.t(`shop.upgradeDescriptions.${t}`),pe[t].refundable?a.textContent=`This item is refundable! Will be set to level ${pe[t].refundMinimumLevel} when refunded.`:a.textContent=u.t("shop.cannotRefund"),t){case"offeringPotion":n.innerHTML=u.t("shop.upgradeEffects.offeringPotion",{amount:d(7200*e.offeringpersecond*qe().mult*+e.singularityUpgrades.potionBuff.getEffect().bonus,0,!0)});break;case"obtainiumPotion":n.innerHTML=u.t("shop.upgradeEffects.obtainiumPotion",{amount:d(7200*e.maxobtainiumpersecond*qe().mult*+e.singularityUpgrades.potionBuff.getEffect().bonus,0,!0)});break;case"offeringEX":n.innerHTML=u.t("shop.upgradeEffects.offeringEX",{amount:d(4*e.shopUpgrades.offeringEX,2,!0)});break;case"offeringAuto":n.innerHTML=u.t("shop.upgradeEffects.offeringAuto",{amount1:d(Math.pow(2,e.shopUpgrades.offeringAuto)),amount2:d(2*e.shopUpgrades.offeringAuto,2)});break;case"obtainiumEX":n.innerHTML=u.t("shop.upgradeEffects.obtainiumEX",{amount:d(4*e.shopUpgrades.obtainiumEX,2,!0)});break;case"obtainiumAuto":n.innerHTML=u.t("shop.upgradeEffects.obtainiumAuto",{amount:d(e.shopUpgrades.obtainiumAuto*2,2)});break;case"instantChallenge":n.innerHTML=u.t("shop.upgradeEffects.instantChallenge");break;case"antSpeed":n.innerHTML=u.t("shop.upgradeEffects.antSpeed",{amount:d(Math.pow(1.2,e.shopUpgrades.antSpeed),2)});break;case"cashGrab":n.innerHTML=u.t("shop.upgradeEffects.cashGrab",{amount:d(e.shopUpgrades.cashGrab,2)});break;case"shopTalisman":n.innerHTML=u.t("shop.upgradeEffects.shopTalisman");break;case"seasonPass":n.innerHTML=u.t("shop.upgradeEffects.seasonPass",{amount:d(2.25*e.shopUpgrades.seasonPass)});break;case"challengeExtension":n.innerHTML=u.t("shop.upgradeEffects.challengeExtension",{amount:d(2*e.shopUpgrades.challengeExtension)});break;case"challengeTome":n.innerHTML=u.t("shop.upgradeEffects.challengeTome",{amount1:d(20*e.shopUpgrades.challengeTome),amount2:d(1-(e.shopUpgrades.challengeTome+e.shopUpgrades.challengeTome2)/100,2,!0)});break;case"cubeToQuark":n.innerHTML=u.t("shop.upgradeEffects.cubeToQuark");break;case"tesseractToQuark":n.innerHTML=u.t("shop.upgradeEffects.tesseractToQuark");break;case"hypercubeToQuark":n.innerHTML=u.t("shop.upgradeEffects.hypercubeToQuark");break;case"seasonPass2":n.innerHTML=u.t("shop.upgradeEffects.seasonPass2",{amount:d(1.5*e.shopUpgrades.seasonPass2)});break;case"seasonPass3":n.innerHTML=u.t("shop.upgradeEffects.seasonPass3",{amount:d(1.5*e.shopUpgrades.seasonPass3)});break;case"chronometer":n.innerHTML=u.t("shop.upgradeEffects.chronometer",{amount:d(1.2*e.shopUpgrades.chronometer)});break;case"infiniteAscent":n.innerHTML=u.t("shop.upgradeEffects.infiniteAscent");break;case"calculator":n.innerHTML=u.t("shop.upgradeEffects.calculator",{amount1:d(14*e.shopUpgrades.calculator),bool1:e.shopUpgrades.calculator>0,bool2:e.shopUpgrades.calculator===pe.calculator.maxLevel});break;case"calculator2":n.innerHTML=u.t("shop.upgradeEffects.calculator2",{amount1:d(2*e.shopUpgrades.calculator2),amount2:d(e.shopUpgrades.calculator2===pe.calculator2.maxLevel?25:0)});break;case"calculator3":n.innerHTML=u.t("shop.upgradeEffects.calculator3",{amount1:d(10*e.shopUpgrades.calculator3),amount2:d(60*e.shopUpgrades.calculator3)});break;case"calculator4":n.innerHTML=u.t("shop.upgradeEffects.calculator4",{amount1:d(2*e.shopUpgrades.calculator4),amount2:e.shopUpgrades.calculator4===10?32:0});break;case"calculator5":n.innerHTML=u.t("shop.upgradeEffects.calculator5",{amount1:d(6*e.shopUpgrades.calculator5),amount2:Math.floor(e.shopUpgrades.calculator5/10)+(e.shopUpgrades.calculator4===pe.calculator5.maxLevel?6:0)});break;case"calculator6":n.innerHTML=u.t("shop.upgradeEffects.calculator6",{amount1:d(e.shopUpgrades.calculator6),amount2:e.shopUpgrades.calculator6===pe.calculator6.maxLevel?24:0});break;case"calculator7":n.innerHTML=u.t("shop.upgradeEffects.calculator7",{amount1:d(e.shopUpgrades.calculator7,0,!0),amount2:e.shopUpgrades.calculator7===pe.calculator7.maxLevel?48:0});break;case"constantEX":n.innerHTML=u.t("shop.upgradeEffects.constantEX",{amount:d(e.shopUpgrades.constantEX,0,!0)});break;case"powderEX":n.innerHTML=u.t("shop.upgradeEffects.powderEX",{amount:d(2*e.shopUpgrades.powderEX)});break;case"chronometer2":n.innerHTML=u.t("shop.upgradeEffects.chronometer2",{amount:d(.6*e.shopUpgrades.chronometer2,1)});break;case"chronometer3":n.innerHTML=u.t("shop.upgradeEffects.chronometer3",{amount:d(1.5*e.shopUpgrades.chronometer3,1)});break;case"seasonPassY":n.innerHTML=u.t("shop.upgradeEffects.seasonPassY",{amount:d(.75*e.shopUpgrades.seasonPassY,2)});break;case"seasonPassZ":n.innerHTML=u.t("shop.upgradeEffects.seasonPassZ",{amount:d(1*e.shopUpgrades.seasonPassZ*e.singularityCount,0,!0)});break;case"challengeTome2":n.innerHTML=u.t("shop.upgradeEffects.challengeTome2",{amount1:20*e.shopUpgrades.challengeTome2,amount2:d(1-(e.shopUpgrades.challengeTome+e.shopUpgrades.challengeTome2)/100,2,!0)});break;case"instantChallenge2":n.innerHTML=u.t("shop.upgradeEffects.instantChallenge2",{amount:d(e.shopUpgrades.instantChallenge2*e.singularityCount,0)});break;case"cashGrab2":n.innerHTML=u.t("shop.upgradeEffects.cashGrab2",{amount:d(.5*e.shopUpgrades.cashGrab2,1)});break;case"cubeToQuarkAll":n.innerHTML=u.t("shop.upgradeEffects.cubeToQuarkAll",{amount:d(.2*e.shopUpgrades.cubeToQuarkAll,2)});break;case"chronometerZ":n.innerHTML=u.t("shop.upgradeEffects.chronometerZ",{amount:d(.1*e.singularityCount*e.shopUpgrades.chronometerZ,2)});break;case"offeringEX2":n.innerHTML=u.t("shop.upgradeEffects.offeringEX2",{amount:d(1*e.singularityCount*e.shopUpgrades.offeringEX2,2)});break;case"obtainiumEX2":n.innerHTML=u.t("shop.upgradeEffects.obtainiumEX2",{amount:d(1*e.singularityCount*e.shopUpgrades.obtainiumEX2,2)});break;case"powderAuto":n.innerHTML=u.t("shop.upgradeEffects.powderAuto",{amount:d(100/(Math.max(1,e.shopUpgrades.powderAuto)*Ar().mult),2,!0)});break;case"seasonPassLost":n.innerHTML=u.t("shop.upgradeEffects.seasonPassLost",{amount:d(.1*e.shopUpgrades.seasonPassLost,2)});break;case"challenge15Auto":n.innerHTML=u.t("shop.upgradeEffects.challenge15Auto");break;case"extraWarp":n.innerHTML=u.t("shop.upgradeEffects.extraWarp",{amount:e.shopUpgrades.extraWarp});break;case"autoWarp":n.innerHTML=u.t("shop.upgradeEffects.autoWarp");break;case"improveQuarkHept":n.innerHTML=u.t("shop.upgradeEffects.improveQuarkHept",{amount:2*e.shopUpgrades.improveQuarkHept});break;case"improveQuarkHept2":n.innerHTML=u.t("shop.upgradeEffects.improveQuarkHept2",{amount:2*e.shopUpgrades.improveQuarkHept2});break;case"improveQuarkHept3":n.innerHTML=u.t("shop.upgradeEffects.improveQuarkHept3",{amount:2*e.shopUpgrades.improveQuarkHept3});break;case"improveQuarkHept4":n.innerHTML=u.t("shop.upgradeEffects.improveQuarkHept4",{amount:2*e.shopUpgrades.improveQuarkHept4});break;case"shopImprovedDaily":n.innerHTML=u.t("shop.upgradeEffects.shopImprovedDaily",{amount:d(5*e.shopUpgrades.shopImprovedDaily)});break;case"shopImprovedDaily2":n.innerHTML=u.t("shop.upgradeEffects.shopImprovedDaily2",{amount1:e.shopUpgrades.shopImprovedDaily2,amount2:e.shopUpgrades.shopImprovedDaily2*20});break;case"shopImprovedDaily3":n.innerHTML=u.t("shop.upgradeEffects.shopImprovedDaily3",{amount1:e.shopUpgrades.shopImprovedDaily3,amount2:e.shopUpgrades.shopImprovedDaily3*15});break;case"shopImprovedDaily4":n.innerHTML=u.t("shop.upgradeEffects.shopImprovedDaily4",{amount1:e.shopUpgrades.shopImprovedDaily4,amount2:e.shopUpgrades.shopImprovedDaily4*100});break;case"offeringEX3":n.innerHTML=u.t("shop.upgradeEffects.offeringEX3",{amount:d(100*(Math.pow(1.02,e.shopUpgrades.offeringEX3)-1),2,!0)});break;case"obtainiumEX3":n.innerHTML=u.t("shop.upgradeEffects.obtainiumEX3",{amount:d(100*(Math.pow(1.02,e.shopUpgrades.obtainiumEX3)-1),2,!0)});break;case"improveQuarkHept5":n.innerHTML=u.t("shop.upgradeEffects.improveQuarkHept5",{amount:d(e.shopUpgrades.improveQuarkHept5/25,2,!0)});break;case"seasonPassInfinity":n.innerHTML=u.t("shop.upgradeEffects.seasonPassInfinity",{amount:d(100*(Math.pow(1.02,e.shopUpgrades.seasonPassInfinity)-1),2,!0)});break;case"chronometerInfinity":n.innerHTML=u.t("shop.upgradeEffects.chronometerInfinity",{amount:d(100*(Math.pow(1.01,e.shopUpgrades.chronometerInfinity)-1),2,!0)});break;case"shopSingularityPenaltyDebuff":n.innerHTML=u.t("shop.upgradeEffects.shopSingularityPenaltyDebuff",{amount1:d(e.singularityCount),amount2:d(e.singularityCount-e.shopUpgrades.shopSingularityPenaltyDebuff)});break;case"shopAmbrosiaLuckMultiplier4":n.innerHTML=u.t("shop.upgradeEffects.shopAmbrosiaLuckMultiplier4",{amount:d(e.shopUpgrades.shopAmbrosiaLuckMultiplier4)});break;case"shopOcteractAmbrosiaLuck":n.innerHTML=u.t("shop.upgradeEffects.shopOcteractAmbrosiaLuck",{amount:d(e.shopUpgrades.shopOcteractAmbrosiaLuck*(1+Math.floor(Math.log10(e.totalWowOcteracts+1))))});break;case"shopAmbrosiaGeneration1":n.innerHTML=u.t("shop.upgradeEffects.shopAmbrosiaGeneration1",{amount:d(e.shopUpgrades.shopAmbrosiaGeneration1)});break;case"shopAmbrosiaGeneration2":n.innerHTML=u.t("shop.upgradeEffects.shopAmbrosiaGeneration2",{amount:d(e.shopUpgrades.shopAmbrosiaGeneration2)});break;case"shopAmbrosiaGeneration3":n.innerHTML=u.t("shop.upgradeEffects.shopAmbrosiaGeneration3",{amount:d(e.shopUpgrades.shopAmbrosiaGeneration3)});break;case"shopAmbrosiaGeneration4":n.innerHTML=u.t("shop.upgradeEffects.shopAmbrosiaGeneration4",{amount:d(e.shopUpgrades.shopAmbrosiaGeneration4/10,1,!0)});break;case"shopAmbrosiaLuck1":n.innerHTML=u.t("shop.upgradeEffects.shopAmbrosiaLuck1",{amount:d(2*e.shopUpgrades.shopAmbrosiaLuck1)});break;case"shopAmbrosiaLuck2":n.innerHTML=u.t("shop.upgradeEffects.shopAmbrosiaLuck2",{amount:d(2*e.shopUpgrades.shopAmbrosiaLuck2)});break;case"shopAmbrosiaLuck3":n.innerHTML=u.t("shop.upgradeEffects.shopAmbrosiaLuck3",{amount:d(2*e.shopUpgrades.shopAmbrosiaLuck3)});break;case"shopAmbrosiaLuck4":n.innerHTML=u.t("shop.upgradeEffects.shopAmbrosiaLuck4",{amount:d(6*e.shopUpgrades.shopAmbrosiaLuck4/10,1,!0)});break;case"shopCashGrabUltra":n.innerHTML=u.t("shop.upgradeEffects.shopCashGrabUltra",{amount:d(100*(ho()-1),2,!0),amount2:d(100*(Ki()-1),2,!0),amount3:d(100*(bo()-1),2,!0)});break;case"shopAmbrosiaAccelerator":n.innerHTML=u.t("shop.upgradeEffects.shopAmbrosiaAccelerator",{amount:d(.2*e.shopUpgrades.shopAmbrosiaAccelerator,1,!0),amount2:d(e.shopUpgrades.shopAmbrosiaAccelerator*.2*o.ambrosiaCurrStats.ambrosiaGenerationSpeed,0,!0)});break;case"shopEXUltra":{let s=125e3*e.shopUpgrades.shopEXUltra;n.innerHTML=u.t("shop.upgradeEffects.shopEXUltra",{amount:d(.1*Math.floor(Math.min(s,e.lifetimeAmbrosia)/1e3),1,!0)})}break;case"shopChronometerS":{let s=e.singularityCount,l=e.shopUpgrades.shopChronometerS>0;n.innerHTML=u.t("shop.upgradeEffects.shopChronometerS",{amount:d(Math.max(0,100*(Math.pow(1.01,(s-200)*+l)-1)),2,!0)})}break;case"shopAmbrosiaUltra":{let s=du();n.innerHTML=u.t("shop.upgradeEffects.shopAmbrosiaUltra",{amount:d(e.shopUpgrades.shopAmbrosiaUltra*s,0,!0)})}break;case"shopSingularitySpeedup":{let s=e.shopUpgrades.shopSingularitySpeedup>0;n.innerHTML=u.t("shop.upgradeEffects.shopSingularitySpeedup",{amount:s?50:1});break}case"shopSingularityPotency":{let s=e.shopUpgrades.shopSingularityPotency>0;n.innerHTML=u.t("shop.upgradeEffects.shopSingularityPotency",{amount:s?3.66:1})}break;case"shopSadisticRune":n.innerHTML=u.t("shop.upgradeEffects.shopSadisticRune")}},Na=t=>({offeringPotion:"Offering Potion",obtainiumPotion:"Obtainium Potion",offeringEX:"Offering EX",offeringAuto:"Offering Auto",obtainiumEX:"Obtainium EX",obtainiumAuto:"Obtainium Auto",instantChallenge:"Instant Challenge Completions",antSpeed:"Ant Speed",cashGrab:"Cash Grab",shopTalisman:"the Plastic talisman",seasonPass:"Season Pass",challengeExtension:"Reincarnation Challenge EX",challengeTome:"Challenge 10 Requirement Reduce",cubeToQuark:"Cube Quarks +50%",tesseractToQuark:"Tesseract Quarks +50%",hypercubeToQuark:"Hypercube Quarks +50%",seasonPass2:"Season Pass 2",seasonPass3:"Season Pass 3",chronometer:"Chronometer 1",infiniteAscent:"Infinite Ascent",calculator:"PL-AT calculator",calculator2:"PL-AT X calculator",calculator3:"PL-AT \u03A9 calculator",calculator4:"PL-AT \u03B4 calculator",calculator5:"PL-AT \u0393 calculator",calculator6:"QUAAA-T calculator",calculator7:"PL-AT \u03A9\u03A9 calculator",constantEX:"Constant EX",powderEX:"Powder EX",chronometer2:"Chronometer 2",chronometer3:"Chronometer 3",seasonPassY:"Season Pass Y",seasonPassZ:"Season Pass Z",challengeTome2:"Challenge 10 Requirement Reduction 2",instantChallenge2:"Instant Challenge Completions 2",cubeToQuarkAll:"Quark Gain Cube Improvement 2",cashGrab2:"Cash Grab 2",chronometerZ:"Chronometer Z",obtainiumEX2:"Obtainium EX 2",offeringEX2:"Offering EX 2",powderAuto:"Automated Powder",seasonPassLost:"Season Pass LOST",challenge15Auto:"Challenge 15 Automation",extraWarp:"Extra Warp",autoWarp:"a quack powered Warps?",improveQuarkHept:"Quark Hepteract 1",improveQuarkHept2:"Quark Hepteract 2",improveQuarkHept3:"Quark Hepteract 3",improveQuarkHept4:"Quack Hepteract 4",shopImprovedDaily:"Improved Daily Code 1",shopImprovedDaily2:"Improved Daily Code 2",shopImprovedDaily3:"Improved Daily Code 3",shopImprovedDaily4:"Improved Daily Code 4",offeringEX3:"The final Offering Upgrade",obtainiumEX3:"The final Obtainium Upgrade",improveQuarkHept5:"The final Quark Hepteract Improver",chronometerInfinity:"The final Chronometer",seasonPassInfinity:"The final Season pass",shopSingularityPenaltyDebuff:"A Singularity Tenderizer",shopAmbrosiaLuckMultiplier4:"The Fourth Multiplicative Ambrosia Luck Multiplier",shopOcteractAmbrosiaLuck:"Octeract-Based Ambrosia Luck Amplifier",shopAmbrosiaGeneration1:"Ambrosia Generation Speedup",shopAmbrosiaGeneration2:"Another Ambrosia Generation Speedup",shopAmbrosiaGeneration3:"A better Ambrosia Generation Speedup",shopAmbrosiaGeneration4:"A FINAL Ambrosia Generation Speedup",shopAmbrosiaLuck1:"Ambrosia Luck Increaser",shopAmbrosiaLuck2:"Another Ambrosia Luck Increaser",shopAmbrosiaLuck3:"A better Ambrosia Generation Speedup",shopAmbrosiaLuck4:"A FINAL Ambrosia Generation Speedup",shopCashGrabUltra:"It's the FINAL CASHGRAB!",shopAmbrosiaAccelerator:"An Ambrosial Accelerator!",shopEXUltra:"It's the FINAL E X!",shopChronometerS:"The FINAL Chronometer",shopAmbrosiaUltra:"The FINAL Ambrosia Exaltation... I don't flippin know!",shopSingularitySpeedup:"Singularity Timed-Perks Speedup",shopSingularityPotency:"Singularity Passives Potency",shopSadisticRune:"Sadistic Rune Unlock! Or does it?"})[t],Vi=async t=>{let r=pe[t];if(e.shopUpgrades[t]>=r.maxLevel)return e.shopConfirmationToggle?P(`You can't purchase ${Na(t)} because you are already at the maximum ${r.type==="upgrade"?"level":"capacity"}!`):null;if(Number(e.worlds)<$a(t))return e.shopConfirmationToggle?P(`You can't purchase ${Na(t)} because you don't have enough Quarks!`):null;if(!xs(t))return P(`You do not have the right to purchase ${Na(t)}!`);let n,a=r.maxLevel-e.shopUpgrades[t],s,l;switch(e.shopBuyMaxToggle){case!1:s=1,l=$a(t);break;case"TEN":n=sr(e.shopUpgrades[t],r.price,+e.worlds,r.priceIncrease/r.price,Math.min(10,a)),s=n.levelCanBuy-e.shopUpgrades[t],l=n.cost;break;default:n=sr(e.shopUpgrades[t],r.price,+e.worlds,r.priceIncrease/r.price,a),s=n.levelCanBuy-e.shopUpgrades[t],l=n.cost}let c=r.maxLevel===1,p=s.toLocaleString()+(r.type==="upgrade"?" level":" vial")+(s===1?"":"s"),g=r.refundable?"":` \u26A0\uFE0F !! No Refunds !! \u26A0\uFE0F`,m=r.type==="consume"?` -Type -1 in Buy: ANY to buy equal amounts of both Potions.`:"";if(e.shopBuyMaxToggle==="ANY"&&!c){let b=await Ee(`You can afford to purchase up to ${p} of ${Oa(t)} for ${l.toLocaleString()} Quarks. How many would you like to buy?${m+g}`),C;if(Number(b)===-1&&r.type==="consume"){let x=t==="offeringPotion"?"obtainiumPotion":"offeringPotion",B=Math.max(+e.worlds/2,+e.worlds-l),U=rr(e.shopUpgrades[x],pe[x].price,B,pe[x].priceIncrease/pe[x].price,pe[x].maxLevel-e.shopUpgrades[x]);e.worlds.sub(U.cost),e.shopUpgrades[x]=U.levelCanBuy,C=s}else{if(C=Math.floor(Number(b)),C===0)return;if(Number.isNaN(C)||!Number.isFinite(C)||C<0)return P("Amount must be a finite, positive integer.")}let v=rr(e.shopUpgrades[t],r.price,+e.worlds,r.priceIncrease/r.price,Math.min(C,s));e.worlds.sub(v.cost),e.shopUpgrades[t]=v.levelCanBuy,Oe(),o.ambrosiaCurrStats.ambrosiaLuck=Ge().value,o.ambrosiaCurrStats.ambrosiaAdditiveLuckMult=zr().value,o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value;return}let h=!0;(e.shopConfirmationToggle||!r.refundable&&e.shopBuyMaxToggle!==!1)&&(h=await we(`You are about to ${c?"unlock":`purchase ${p} of`} ${Oa(t)} for ${l.toLocaleString()} Quarks. Press 'OK' to finalize purchase.${m+g}`)),h&&(e.worlds.sub(l),e.shopUpgrades[t]+=s,o.ambrosiaCurrStats.ambrosiaLuck=Ge().value,o.ambrosiaCurrStats.ambrosiaAdditiveLuckMult=zr().value,o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value,Oe())};var gn=async(t,r=!1,n=1,a=!0)=>{let s=xe.AUTO_POTION_FREE_POTIONS_QOL;if(e.shopConfirmationToggle&&!r?await we("Would you like to use some of this potion?"):!0){let c=+e.singularityUpgrades.potionBuff.getEffect().bonus*+e.singularityUpgrades.potionBuff2.getEffect().bonus*+e.singularityUpgrades.potionBuff3.getEffect().bonus*+e.octeractUpgrades.octeractAutoPotionEfficiency.getEffect().bonus*n;t==="offeringPotion"?s&&r?(e.runeshards+=Math.floor(7200*e.offeringpersecond*qe().mult*c),e.runeshards=Math.min(1e300,e.runeshards)):(e.shopUpgrades.offeringPotion>=n||!a)&&(e.shopUpgrades.offeringPotion-=a?n:0,e.runeshards+=Math.floor(7200*e.offeringpersecond*qe().mult*c),e.runeshards=Math.min(1e300,e.runeshards)):t==="obtainiumPotion"&&(s&&r?(e.researchPoints+=Math.floor(7200*e.maxobtainiumpersecond*qe().mult*c),e.researchPoints=Math.min(1e300,e.researchPoints)):(e.shopUpgrades.obtainiumPotion>=n||!a)&&(e.shopUpgrades.obtainiumPotion-=a?n:0,e.researchPoints+=Math.floor(7200*e.maxobtainiumpersecond*qe().mult*c),e.researchPoints=Math.min(1e300,e.researchPoints)))}},Hi=async(t=!1)=>{let r=!1;if(t||(r=e.shopConfirmationToggle?await we("This will fully refund most of your permanent upgrades for an upfront cost of 15 Quarks. Would you like to do this?"):!0),r||t){let n=e.quarksThisSingularity,a=!1;for(let s in pe){let l=s,c=pe[l];if(c.refundable&&e.shopUpgrades[l]>c.refundMinimumLevel){a=!0;let p=c.price*c.refundMinimumLevel+c.priceIncrease*c.refundMinimumLevel*(c.refundMinimumLevel-1)/2;e.worlds.add(c.price*e.shopUpgrades[l]+c.priceIncrease*e.shopUpgrades[l]*(e.shopUpgrades[l]-1)/2-p,!1),e.shopUpgrades[l]=c.refundMinimumLevel}}a?e.worlds.sub(15):!t&&e.shopConfirmationToggle&&P("Nothing to Refund!"),e.quarksThisSingularity=n}};var hs=t=>{switch(t){case"offeringPotion":return!0;case"obtainiumPotion":return!0;case"offeringEX":return e.reincarnationCount>0||e.highestSingularityCount>0;case"offeringAuto":return e.reincarnationCount>0||e.highestSingularityCount>0;case"obtainiumEX":return e.reincarnationCount>0||e.highestSingularityCount>0;case"obtainiumAuto":return e.reincarnationCount>0||e.highestSingularityCount>0;case"instantChallenge":return e.reincarnationCount>0||e.highestSingularityCount>0;case"antSpeed":return e.highestchallengecompletions[8]>0||e.ascensionCount>0||e.highestSingularityCount>0;case"cashGrab":return e.highestchallengecompletions[8]>0||e.ascensionCount>0||e.highestSingularityCount>0;case"shopTalisman":return e.highestchallengecompletions[9]>0||e.ascensionCount>0||e.highestSingularityCount>0;case"seasonPass":return e.ascensionCount>0||e.highestSingularityCount>0;case"challengeExtension":return e.ascensionCount>0||e.highestSingularityCount>0;case"challengeTome":return e.ascensionCount>0||e.highestSingularityCount>0;case"cubeToQuark":return e.ascensionCount>0||e.highestSingularityCount>0;case"tesseractToQuark":return e.highestchallengecompletions[11]>0||e.highestSingularityCount>0;case"hypercubeToQuark":return e.highestchallengecompletions[13]>0||e.highestSingularityCount>0;case"seasonPass2":return e.highestchallengecompletions[14]>0||e.highestSingularityCount>0;case"seasonPass3":return e.highestchallengecompletions[14]>0||e.highestSingularityCount>0;case"chronometer":return e.highestchallengecompletions[12]>0||e.highestSingularityCount>0;case"infiniteAscent":return e.highestchallengecompletions[14]>0||e.highestSingularityCount>0;case"calculator":return e.ascensionCount>0||e.highestSingularityCount>0;case"calculator2":return e.highestchallengecompletions[11]>0||e.highestSingularityCount>0;case"calculator3":return e.highestchallengecompletions[13]>0||e.highestSingularityCount>0;case"calculator4":return!!e.singularityUpgrades.wowPass.getEffect().bonus;case"calculator5":return!!e.singularityUpgrades.wowPass2.getEffect().bonus;case"calculator6":return!!e.singularityUpgrades.wowPass3.getEffect().bonus;case"calculator7":return!!e.singularityChallenges.limitedAscensions.rewards.shopUpgrade;case"constantEX":return e.highestchallengecompletions[14]>0||e.highestSingularityCount>0;case"powderEX":return e.challenge15Exponent>=1e15||e.highestSingularityCount>0;case"chronometer2":return e.challenge15Exponent>=1e15||e.highestSingularityCount>0;case"chronometer3":return!!e.singularityUpgrades.wowPass.getEffect().bonus;case"seasonPassY":return e.challenge15Exponent>=1e15||e.highestSingularityCount>0;case"seasonPassZ":return!!e.singularityUpgrades.wowPass.getEffect().bonus;case"challengeTome2":return!!e.singularityUpgrades.wowPass.getEffect().bonus;case"instantChallenge2":return!!e.singularityUpgrades.wowPass.getEffect().bonus;case"cashGrab2":return!!e.singularityUpgrades.wowPass2.getEffect().bonus;case"cubeToQuarkAll":return!!e.singularityUpgrades.wowPass2.getEffect().bonus;case"chronometerZ":return!!e.singularityUpgrades.wowPass2.getEffect().bonus;case"offeringEX2":return!!e.singularityUpgrades.wowPass2.getEffect().bonus;case"obtainiumEX2":return!!e.singularityUpgrades.wowPass2.getEffect().bonus;case"powderAuto":return!!e.singularityUpgrades.wowPass2.getEffect().bonus;case"seasonPassLost":return!!e.singularityUpgrades.wowPass2.getEffect().bonus;case"challenge15Auto":return!!e.singularityUpgrades.wowPass3.getEffect().bonus;case"extraWarp":return!!e.singularityUpgrades.wowPass3.getEffect().bonus;case"autoWarp":return!!e.singularityUpgrades.wowPass3.getEffect().bonus;case"improveQuarkHept":return e.challenge15Exponent>=1e15||e.highestSingularityCount>0;case"improveQuarkHept2":return!!e.singularityUpgrades.wowPass.getEffect().bonus;case"improveQuarkHept3":return!!e.singularityUpgrades.wowPass2.getEffect().bonus;case"improveQuarkHept4":return!!e.singularityUpgrades.wowPass3.getEffect().bonus;case"shopImprovedDaily":return e.highestchallengecompletions[14]>0||e.highestSingularityCount>0;case"shopImprovedDaily2":return!!e.singularityUpgrades.wowPass.getEffect().bonus;case"shopImprovedDaily3":return!!e.singularityUpgrades.wowPass2.getEffect().bonus;case"shopImprovedDaily4":return!!e.singularityUpgrades.wowPass3.getEffect().bonus;case"offeringEX3":return!!e.singularityUpgrades.wowPass4.getEffect().bonus;case"obtainiumEX3":return!!e.singularityUpgrades.wowPass4.getEffect().bonus;case"improveQuarkHept5":return!!e.singularityUpgrades.wowPass4.getEffect().bonus;case"chronometerInfinity":return!!e.singularityUpgrades.wowPass4.getEffect().bonus;case"seasonPassInfinity":return!!e.singularityUpgrades.wowPass4.getEffect().bonus;case"shopSingularityPenaltyDebuff":return!!e.singularityChallenges.noSingularityUpgrades.rewards.shopUpgrade;case"shopAmbrosiaLuckMultiplier4":return!!e.singularityChallenges.oneChallengeCap.rewards.shopUpgrade;case"shopOcteractAmbrosiaLuck":return!!e.singularityChallenges.noOcteracts.rewards.shopUpgrade;case"shopAmbrosiaGeneration1":return!!e.singularityUpgrades.wowPass2.getEffect().bonus;case"shopAmbrosiaGeneration2":return!!e.singularityUpgrades.wowPass3.getEffect().bonus;case"shopAmbrosiaGeneration3":return!!e.singularityUpgrades.wowPass4.getEffect().bonus;case"shopAmbrosiaGeneration4":return!!e.singularityUpgrades.wowPass4.getEffect().bonus;case"shopAmbrosiaLuck1":return!!e.singularityUpgrades.wowPass2.getEffect().bonus;case"shopAmbrosiaLuck2":return!!e.singularityUpgrades.wowPass3.getEffect().bonus;case"shopAmbrosiaLuck3":return!!e.singularityUpgrades.wowPass4.getEffect().bonus;case"shopAmbrosiaLuck4":return!!e.singularityUpgrades.wowPass4.getEffect().bonus;case"shopCashGrabUltra":return!!e.singularityChallenges.noSingularityUpgrades.rewards.shopUpgrade2;case"shopAmbrosiaAccelerator":return!!e.singularityChallenges.noAmbrosiaUpgrades.rewards.shopUpgrade;case"shopEXUltra":return!!e.singularityChallenges.noAmbrosiaUpgrades.rewards.shopUpgrade2;case"shopChronometerS":return!!e.singularityChallenges.limitedTime.rewards.tier1Upgrade;case"shopAmbrosiaUltra":return!!e.singularityChallenges.limitedTime.rewards.tier2Upgrade;case"shopSingularitySpeedup":return!!e.singularityChallenges.sadisticPrequel.rewards.shopUpgrade;case"shopSingularityPotency":return!!e.singularityChallenges.sadisticPrequel.rewards.shopUpgrade2;case"shopSadisticRune":return!!e.singularityChallenges.sadisticPrequel.rewards.shopUpgrade3}};var tm={shard:{obtainium:1e13,offerings:100},commonFragment:{obtainium:1e14,offerings:1e4},uncommonFragment:{obtainium:1e16,offerings:1e5},rareFragment:{obtainium:1e18,offerings:1e6},epicFragment:{obtainium:1e20,offerings:1e7},legendaryFragment:{obtainium:1e22,offerings:1e8},mythicalFragment:{obtainium:1e24,offerings:1e9}},su=["One","Two","Three","Four","Five","Six","Seven"],mo=t=>{let r=30*e.talismanRarity[t];return r+=6*_("ascension",e.challengecompletions[13]),r+=Math.floor(e.researches[200]/400),t===6&&(r+=xe.INSTANT_UNLOCK_1?10:0),e.cubeUpgrades[67]>0&&t===3&&(r+=1337),r},rm=(t,r=e.buyTalismanShardPercent)=>{let n=tm[t].obtainium,a=tm[t].offerings,s=Math.max(1,Math.floor(e.researchPoints/n)),l=Math.max(1,Math.floor(e.runeshards/a)),c=Math.max(1,Math.floor(r/100*Math.min(s,l)));return{canBuy:n<=e.researchPoints&&a<=e.runeshards,buyAmount:c,obtainiumCost:n*c,offeringCost:a*c}},Qi=(t,r=e.buyTalismanShardPercent)=>{let n=i("talismanFragmentCost");if(t){let a=rm(t,r),s=u.t(`runes.talismans.shards.${t}`);n.textContent=u.t("runes.talismans.costToBuy",{name:s,buyAmount:d(a.buyAmount),obtainium:d(a.obtainiumCost),offerings:d(a.offeringCost)})}else n.textContent=u.t("runes.talismans.clickBuyEveryType")},bs=(t=e.buyTalismanShardPercent)=>{i("talismanTen").style.backgroundColor="",i("talismanTwentyFive").style.backgroundColor="",i("talismanFifty").style.backgroundColor="",i("talismanHundred").style.backgroundColor="",e.buyTalismanShardPercent=t;let r="Ten";t===25&&(r="TwentyFive"),t===50&&(r="Fifty"),t===100&&(r="Hundred"),i(`talisman${r}`).style.backgroundColor="green"},Kt=()=>{i("talismanShardInventory").textContent=d(e.talismanShards),i("commonFragmentInventory").textContent=d(e.commonFragments),i("uncommonFragmentInventory").textContent=d(e.uncommonFragments),i("rareFragmentInventory").textContent=d(e.rareFragments),i("epicFragmentInventory").textContent=d(e.epicFragments),i("legendaryFragmentInventory").textContent=d(e.legendaryFragments),i("mythicalFragmentInventory").textContent=d(e.mythicalFragments)},qi=()=>{let t=["shard","commonFragment","uncommonFragment","rareFragment","epicFragment","legendaryFragment","mythicalFragment"];for(let r=t.length-1;r>=0;r--)ou(t[r])},ou=(t,r=e.buyTalismanShardPercent)=>{let n=rm(t,r);n.canBuy&&(t==="shard"?e.talismanShards+=n.buyAmount:e[`${t}s`]+=n.buyAmount,t==="mythicalFragment"&&e.mythicalFragments>=1e25&&e.achievements[239]<1&&R(239),e.researchPoints-=n.obtainiumCost,e.runeshards-=n.offeringCost,e.researchPoints<0&&(e.researchPoints=0),e.runeshards<0&&(e.runeshards=0)),Qi(t,r),Kt()},ji=t=>{i("talismanlevelup").style.display="none",i("talismanEffect").style.display="block",i("talismanrespec").style.display="none";let r=i("talismanSummary"),n=i("talismanBonus"),a=i("talismanRune1Effect"),s=i("talismanRune2Effect"),l=i("talismanRune3Effect"),c=i("talismanRune4Effect"),p=i("talismanRune5Effect"),g=i("talismanMythicEffect"),m="",h="";switch(t){case 0:m="exemption",h=d(10*(e.talismanRarity[0]-1));break;case 1:m="chronos",h=d(10*(e.talismanRarity[1]-1));break;case 2:m="midas",h=d(10*(e.talismanRarity[2]-1));break;case 3:m="metaphysics",h=d(.02*(e.talismanRarity[3]-1),2);break;case 4:m="polymath",h=d(1*(e.talismanRarity[4]-1));break;case 5:m="mortuus",h=d(2*(e.talismanRarity[5]-1));break;case 6:m="plastic";break}let b=`talisman${t+1}Effect`;r.textContent=u.t(`runes.talismans.summaries.${m}`),n.textContent=u.t(`runes.talismans.effects.${m}`,{x:h}),a.textContent=u.t("runes.talismans.bonusRuneLevels.speed",{x:d(o[b][1],2,!0)}),s.textContent=u.t("runes.talismans.bonusRuneLevels.duplication",{x:d(o[b][2],2,!0)}),l.textContent=u.t("runes.talismans.bonusRuneLevels.prism",{x:d(o[b][3],2,!0)}),c.textContent=u.t("runes.talismans.bonusRuneLevels.thrift",{x:d(o[b][4],2,!0)}),p.textContent=u.t("runes.talismans.bonusRuneLevels.SI",{x:d(o[b][5],2,!0)}),g.textContent=u.t(`runes.talismans.mythicEffects.${m}`),e.talismanRarity[t]!==6&&(g.textContent=u.t("runes.talismans.maxEnhance"))},iu=t=>{i("talismanEffect").style.display="none",i("talismanlevelup").style.display="block",i("talismanrespec").style.display="none";let r=i("talismanShardCost"),n=i("talismanCommonFragmentCost"),a=i("talismanUncommonFragmentCost"),s=i("talismanRareFragmentCost"),l=i("talismanEpicFragmentCost"),c=i("talismanLegendaryFragmentCost"),p=i("talismanMythicalFragmentCost");i("talismanLevelUpSummary").textContent=u.t("runes.resourcesToLevelup"),i("talismanLevelUpSummary").style.color="silver";let g=o.talismanLevelCostMultiplier[t];e.talismanLevels[t]>=120&&(g*=(e.talismanLevels[t]-90)/30),e.talismanLevels[t]>=150&&(g*=(e.talismanLevels[t]-120)/30),e.talismanLevels[t]>=180&&(g*=(e.talismanLevels[t]-170)/10),r.textContent=d(g*Math.max(0,Math.floor(1+1/8*Math.pow(e.talismanLevels[t],3)))),n.textContent=d(g*Math.max(0,Math.floor(1+1/32*Math.pow(e.talismanLevels[t]-30,3)))),a.textContent=d(g*Math.max(0,Math.floor(1+1/384*Math.pow(e.talismanLevels[t]-60,3)))),s.textContent=d(g*Math.max(0,Math.floor(1+1/500*Math.pow(e.talismanLevels[t]-90,3)))),l.textContent=d(g*Math.max(0,Math.floor(1+1/375*Math.pow(e.talismanLevels[t]-120,3)))),c.textContent=d(g*Math.max(0,Math.floor(1+1/192*Math.pow(e.talismanLevels[t]-150,3)))),p.textContent=d(g*Math.max(0,Math.floor(1+1/1280*Math.pow(e.talismanLevels[t]-150,3))))},lu=t=>{i("talismanEffect").style.display="none",i("talismanlevelup").style.display="block",i("talismanrespec").style.display="none";let r=i("talismanShardCost"),n=i("talismanCommonFragmentCost"),a=i("talismanUncommonFragmentCost"),s=i("talismanRareFragmentCost"),l=i("talismanEpicFragmentCost"),c=i("talismanLegendaryFragmentCost"),p=i("talismanMythicalFragmentCost");i("talismanLevelUpSummary").textContent=u.t("runes.resourcesToEnhance"),i("talismanLevelUpSummary").style.color="gold";let g=[o.commonTalismanEnhanceCost,o.uncommonTalismanEnchanceCost,o.rareTalismanEnchanceCost,o.epicTalismanEnhanceCost,o.legendaryTalismanEnchanceCost,o.mythicalTalismanEnchanceCost],m=e.talismanRarity[t],h=g[m-1],b=o.talismanLevelCostMultiplier[t];r.textContent=d(b*h[1]),n.textContent=d(b*h[2]),a.textContent=d(b*h[3]),s.textContent=d(b*h[4]),l.textContent=d(b*h[5]),c.textContent=d(b*h[6]),p.textContent=d(b*h[7])},cu=t=>{o.talismanRespec=t,i("talismanEffect").style.display="none",i("talismanlevelup").style.display="none",i("talismanrespec").style.display="block";let r=["speed","duplication","prism","thrift","SI"],n=["positive","positive","positive","positive","positive"];if(t<=6){for(let a=1;a<=5;a++)o.mirrorTalismanStats[a]=e[`talisman${su[t]}`][a];i("confirmTalismanRespec").textContent=u.t("runes.talismans.respecConfirm")}if(t===7){for(let a=1;a<=5;a++)o.mirrorTalismanStats[a]=1;i("confirmTalismanRespec").textContent=u.t("runes.talismans.respecConfirmAll")}for(let a=1;a<=5;a++){let s=i(`talismanRespecButton${a}`);o.mirrorTalismanStats[a]===1?(s.style.border="2px solid limegreen",n[a-1]="positive"):o.mirrorTalismanStats[a]===-1&&(s.style.border="2px solid crimson",n[a-1]="negative"),s.textContent=u.t(`runes.talismans.modifiers.${n[a-1]}`,{name:u.t(`runes.names.${r[a-1]}`)})}i("confirmTalismanRespec").style.display="none"},nm=t=>{let r=[null,"speed","duplication","prism","thrift","SI"],n=i(`talismanRespecButton${t}`);o.mirrorTalismanStats[t]===1?(o.mirrorTalismanStats[t]=-1,n.textContent=u.t("runes.talismans.modifiers.negative",{name:u.t(`runes.names.${r[t]}`)}),n.style.border="2px solid crimson"):(o.mirrorTalismanStats[t]=1,n.textContent=u.t("runes.talismans.modifiers.positive",{name:u.t(`runes.names.${r[t]}`)}),n.style.border="2px solid limegreen"),o.mirrorTalismanStats.reduce((s,l)=>s+l,0)===1?i("confirmTalismanRespec").style.display="block":i("confirmTalismanRespec").style.display="none"},am=t=>{if(e.runeshards>=1e5&&t<7){for(let r=1;r<=5;r++)e[`talisman${su[t]}`][r]=o.mirrorTalismanStats[r];e.runeshards-=1e5,i("confirmTalismanRespec").style.display="none",i("talismanrespec").style.display="none",i("talismanEffect").style.display="block",ji(t)}else if(e.runeshards>=4e5&&t===7){e.runeshards-=4e5;for(let r=0;r<7;r++)for(let n=1;n<=5;n++)e[`talisman${su[r]}`][n]=o.mirrorTalismanStats[n];i("confirmTalismanRespec").style.display="none"}He()},sm=t=>{i("talismanrespec").style.display="none",t<7&&(i("talismanEffect").style.display="block",ji(t))},ct=t=>{let r=i(`talisman${t+1}`),n=i(`talisman${t+1}level`),a=e.talismanRarity[t];a===1&&(r.style.border="4px solid white",n.style.color="white"),a===2&&(r.style.border="4px solid limegreen",n.style.color="limegreen"),a===3&&(r.style.border="4px solid lightblue",n.style.color="lightblue"),a===4&&(r.style.border="4px solid plum",n.style.color="plum"),a===5&&(r.style.border="4px solid orange",n.style.color="orange"),a===6&&(r.style.border="4px solid crimson",n.style.color="var(--crimson-text-color)")},Vi=(t,r=!1)=>{let n=1;e.ascensionCount>0&&(n=30),e.highestSingularityCount>0&&(n=180);let a=!1;for(let s=1;s<=n;s++){let l=0,c=o.talismanLevelCostMultiplier[t];if(e.talismanLevels[t]>=120&&(c*=(e.talismanLevels[t]-90)/30),e.talismanLevels[t]>=150&&(c*=(e.talismanLevels[t]-120)/30),e.talismanLevels[t]>=180&&(c*=(e.talismanLevels[t]-170)/10),e.talismanLevels[t]=c*Math.max(0,Math.floor(1+1/8*Math.pow(e.talismanLevels[t],3)))&&l++,e.commonFragments>=c*Math.max(0,Math.floor(1+1/32*Math.pow(e.talismanLevels[t]-30,3)))&&l++,e.uncommonFragments>=c*Math.max(0,Math.floor(1+1/384*Math.pow(e.talismanLevels[t]-60,3)))&&l++,e.rareFragments>=c*Math.max(0,Math.floor(1+1/500*Math.pow(e.talismanLevels[t]-90,3)))&&l++,e.epicFragments>=c*Math.max(0,Math.floor(1+1/375*Math.pow(e.talismanLevels[t]-120,3)))&&l++,e.legendaryFragments>=c*Math.max(0,Math.floor(1+1/192*Math.pow(e.talismanLevels[t]-150,3)))&&l++,e.mythicalFragments>=c*Math.max(0,Math.floor(1+1/1280*Math.pow(e.talismanLevels[t]-150,3)))&&l++),l===7)e.talismanShards-=c*Math.max(0,Math.floor(1+1/8*Math.pow(e.talismanLevels[t],3))),e.commonFragments-=c*Math.max(0,Math.floor(1+1/32*Math.pow(e.talismanLevels[t]-30,3))),e.uncommonFragments-=c*Math.max(0,Math.floor(1+1/384*Math.pow(e.talismanLevels[t]-60,3))),e.rareFragments-=c*Math.max(0,Math.floor(1+1/500*Math.pow(e.talismanLevels[t]-90,3))),e.epicFragments-=c*Math.max(0,Math.floor(1+1/375*Math.pow(e.talismanLevels[t]-120,3))),e.legendaryFragments-=c*Math.max(0,Math.floor(1+1/192*Math.pow(e.talismanLevels[t]-150,3))),e.mythicalFragments-=c*Math.max(0,Math.floor(1+1/1280*Math.pow(e.talismanLevels[t]-150,3))),e.talismanLevels[t]+=1,a=!0;else break}return!r&&a&&(iu(t),Kt(),He()),a},Wi=(t,r=!1)=>{let n=0;if(e.talismanRarity[t]<6){let a=o.talismanLevelCostMultiplier[t],s=[o.commonTalismanEnhanceCost,o.uncommonTalismanEnchanceCost,o.rareTalismanEnchanceCost,o.epicTalismanEnhanceCost,o.legendaryTalismanEnchanceCost,o.mythicalTalismanEnchanceCost],l=e.talismanRarity[t]-1,c=s[l];if(e.commonFragments>=a*c[2]&&n++,e.uncommonFragments>=a*c[3]&&n++,e.rareFragments>=a*c[4]&&n++,e.epicFragments>=a*c[5]&&n++,e.legendaryFragments>=a*c[6]&&n++,e.mythicalFragments>=a*c[7]&&n++,n===6)return e.commonFragments-=a*c[2],e.uncommonFragments-=a*c[3],e.rareFragments-=a*c[4],e.epicFragments-=a*c[5],e.legendaryFragments-=a*c[6],e.mythicalFragments-=a*c[7],e.talismanRarity[t]+=1,ct(t),r||(lu(t),Kt(),He()),!0}return!1};var zi=(t=!1,r=1,n=!1)=>{var l;let a=i("theme"),s=document.body;n?(localStorage.setItem("theme",`${r}`),s.style.setProperty("--transition","750ms"),s.style.setProperty("--transition-extra","600ms")):r=Number((l=localStorage.getItem("theme"))!=null?l:1),t?r===4&&i("logo").setAttribute("src","Pictures/logoLight.png"):(s.style.removeProperty("--header-color"),s.style.removeProperty("--bg-color"),s.style.removeProperty("--alert-color"),s.style.removeProperty("--history-lines"),s.style.removeProperty("--text-color"),s.style.removeProperty("--green-text-color"),s.style.removeProperty("--lightseagreen-text-color"),s.style.removeProperty("--crimson-text-color"),s.style.removeProperty("--red-text-color"),s.style.removeProperty("--maroon-text-color"),s.style.removeProperty("--orchid-text-color"),s.style.removeProperty("--darkorchid-text-color"),s.style.removeProperty("--darkcyan-text-color"),s.style.removeProperty("--gray-text-color"),s.style.removeProperty("--orangered-text-color"),s.style.removeProperty("--box-color"),s.style.removeProperty("--boxmain-bordercolor"),s.style.removeProperty("--button-color"),s.style.removeProperty("--hover-color"),s.style.removeProperty("--blackbtn-color"),s.style.removeProperty("--purplebtn-color"),s.style.removeProperty("--purplehover-color"),s.style.removeProperty("--buttonbuy-color"),s.style.removeProperty("--buildings-canbuy-color"),s.style.removeProperty("--buildings-hover-color"),s.style.removeProperty("--blessings-canbuy-color"),s.style.removeProperty("--blessings-hover-color"),s.style.removeProperty("--tab-color"),s.style.removeProperty("--singtab-color"),s.style.removeProperty("--hoversing-color"),s.style.removeProperty("--shoptab-color"),s.style.removeProperty("--hovershop-color"),s.style.removeProperty("--hepteract-bar-empty"),s.style.removeProperty("--hepteract-bar-red"),s.style.removeProperty("--hepteract-bar-yellow"),s.style.removeProperty("--hepteract-bar-green"),s.classList.remove("textOutline"),i("actualPotionShop").style.backgroundColor="",i("actualPotionShop").style.borderColor="",i("themeBox").style.backgroundColor="",i("themeBox").style.borderColor="",i("c15Rewards").style.backgroundColor="",i("c15Rewards").style.borderColor="",i("platonicUpgradeDescriptions").style.backgroundColor="",i("platonicUpgradeDescriptions").style.borderColor="",i("platonicUpgradePics").style.backgroundColor="",i("platonicUpgradePics").style.borderColor="",i("actualShop").style.backgroundColor="",i("actualShop").style.borderColor="",i("corruptionStatsLoadouts").style.backgroundColor="",i("corruptionStatsLoadouts").style.borderColor="",i("heptGrid").style.backgroundColor="",i("heptGrid").style.borderColor="",i("exportgame").style.backgroundColor="",i("importFileButton").style.backgroundColor="",i("switchTheme2").style.borderColor="darkslategray",i("bonussummation").style.color="orangered",i("corruptionDescription").style.color="darkviolet",i("versionnumber").style.color="fuchsia",i("singularitytab").style.color="red",i("traitstab").style.color="red",i("cubetab").style.color="red",i("ascTimeAccel").style.color="royalblue",i("buildinghotkeys").style.color="lightgray",i("buildinghotkeys2").style.color="lightgray",i("antspecies").style.color="royalblue",i("achievementcolorcode2").style.color="purple",i("corruptionTesseracts").style.color="darkviolet",i("antwelcome").style.color="lightslategrey",i("confirmationToggleTitle").style.color="pink",i("specialActionsTitle").style.color="pink",i("themesTitle").style.color="pink",i("notationTitle").style.color="pink",i("hepteractWelcome").style.color="pink",i("confirmationdisclaimer").style.color="plum",i("cube6Bonus").style.color="brown",i("tesseract6Bonus").style.color="brown",i("hypercube6Bonus").style.color="brown",i("runeshowpower5").style.color="tomato",i("hypercubeWelcome").style.color="#ff004c",i("hypercubeQuantity").style.color="#ff004c",i("hypercubeBlessingsTotal").style.color="#ff004c"),r===1?(localStorage.removeItem("theme"),a.textContent="Dark Mode"):r===2?(s.style.setProperty("--header-color","black"),s.style.setProperty("--bg-color","#0c0c0f"),s.style.setProperty("--alert-color","#040406"),s.style.setProperty("--history-lines","#1b1b22"),s.style.setProperty("--box-color","#060606"),s.style.setProperty("--boxmain-bordercolor","#d487d4"),s.style.setProperty("--button-color","#040406"),s.style.setProperty("--hover-color","#1b1b22"),s.style.setProperty("--purplebtn-color","#6f006f"),s.style.setProperty("--buttonbuy-color","#040406"),s.style.setProperty("--buildings-canbuy-color","#2c2c44"),s.style.setProperty("--buildings-hover-color","#3a3a58"),s.style.setProperty("--blessings-canbuy-color","#262639"),s.style.setProperty("--blessings-hover-color","#33334e"),s.style.setProperty("--tab-color","black"),s.style.setProperty("--singtab-color","#002"),s.style.setProperty("--hoversing-color","#00007d"),s.style.setProperty("--shoptab-color","#6f006f"),s.style.setProperty("--hepteract-bar-empty","#3a3a58"),s.style.setProperty("--hepteract-bar-red","darkred"),s.style.setProperty("--hepteract-bar-yellow","#997a00"),s.style.setProperty("--hepteract-bar-green","darkgreen"),i("corruptionStatsLoadouts").style.borderColor="#dd8f00",i("actualPotionShop").style.borderColor="#dd0",i("exportgame").style.backgroundColor="black",i("importFileButton").style.backgroundColor="black",a.textContent="Darker Mode"):r===3?(s.style.setProperty("--header-color","#18171c"),s.style.setProperty("--bg-color","#1c1b22"),s.style.setProperty("--alert-color","#141319"),s.style.setProperty("--history-lines","#083a3a"),s.style.setProperty("--box-color","#141319"),s.style.setProperty("--boxmain-bordercolor","#dda0dd"),s.style.setProperty("--button-color","#101828"),s.style.setProperty("--hover-color","#006"),s.style.setProperty("--blackbtn-color","#101828"),s.style.setProperty("--buttonbuy-color","#0b111c"),s.style.setProperty("--buildings-canbuy-color","#2d4471"),s.style.setProperty("--buildings-hover-color","#3c5a95"),s.style.setProperty("--blessings-canbuy-color","#1e2e4d"),s.style.setProperty("--blessings-hover-color","#2d4471"),s.style.setProperty("--tab-color","#101828"),s.style.setProperty("--hoversing-color","#005"),s.style.setProperty("--hepteract-bar-empty","#535064"),i("corruptionStatsLoadouts").style.borderColor="#ffa500",i("actualPotionShop").style.borderColor="#dd0",i("actualShop").style.backgroundColor="#0c0c0f",i("actualShop").style.borderColor="#d487d4",i("platonicUpgradePics").style.backgroundColor="#0c0c0f",s.style.setProperty("--maroon-text-color","#a90000"),a.textContent="Lighter Dark Mode"):r===4?(s.classList.add("textOutline"),s.style.setProperty("--header-color","#736e8d"),s.style.setProperty("--bg-color","#7c7891"),s.style.setProperty("--alert-color","#646175"),s.style.setProperty("--history-lines","#156e71"),s.style.setProperty("--box-color","#646175"),s.style.setProperty("--boxmain-bordercolor","#d894d8"),s.style.setProperty("--button-color","#136062"),s.style.setProperty("--hover-color","#187c7f"),s.style.setProperty("--blackbtn-color","#105254"),s.style.setProperty("--buttonbuy-color","#4c495a"),s.style.setProperty("--buildings-canbuy-color","#9794a8"),s.style.setProperty("--buildings-hover-color","#b2b0bf"),s.style.setProperty("--blessings-canbuy-color","#6c687f"),s.style.setProperty("--blessings-hover-color","#7c7990"),s.style.setProperty("--tab-color","#105254"),s.style.setProperty("--singtab-color","#00d"),s.style.setProperty("--hoversing-color","#1052B6"),s.style.setProperty("--hepteract-bar-empty","#858199"),s.style.setProperty("--hepteract-bar-red","#ea1741"),s.style.setProperty("--hepteract-bar-yellow","#cc0"),s.style.setProperty("--hepteract-bar-green","limegreen"),i("corruptionStatsLoadouts").style.borderColor="#dd8f00",i("actualPotionShop").style.borderColor="#dd0",i("switchTheme2").style.borderColor="#284242",s.style.setProperty("--green-text-color","limegreen"),s.style.setProperty("--red-text-color","#f55"),s.style.setProperty("--maroon-text-color","#ff5656"),s.style.setProperty("--crimson-text-color","#f7617d"),s.style.setProperty("--orchid-text-color","#dd7dda"),s.style.setProperty("--darkorchid-text-color","#cf9ee8"),s.style.setProperty("--darkcyan-text-color","turquoise"),s.style.setProperty("--lightseagreen-text-color","limegreen"),s.style.setProperty("--orangered-text-color","#f74"),s.style.setProperty("--gray-text-color","#a5a5a5"),i("achievementcolorcode2").style.color="#dc7dff",i("corruptionDescription").style.color="#d272ff",i("corruptionTesseracts").style.color="#d272ff",i("antwelcome").style.color="#b1b1b1",i("versionnumber").style.color="#ff5aff",i("singularitytab").style.color="#ff5252",i("traitstab").style.color="#ff5252",i("cubetab").style.color="#ff5252",i("antspecies").style.color="#8da9ff",i("ascTimeAccel").style.color="#97b0ff",i("cube6Bonus").style.color="#a5a5a5",i("tesseract6Bonus").style.color="#a5a5a5",i("hypercube6Bonus").style.color="#a5a5a5",i("hypercubeWelcome").style.color="#f58",i("hypercubeQuantity").style.color="#f58",i("hypercubeBlessingsTotal").style.color="#f58",i("runeshowpower5").style.color="#ff7158",a.textContent="Light Mode"):r===5&&(s.style.setProperty("--header-color","#0a0a11"),s.style.setProperty("--bg-color","#131319"),s.style.setProperty("--alert-color","#2a1035"),s.style.setProperty("--history-lines","#012d1c"),s.style.setProperty("--text-color","#ac47ff"),s.style.setProperty("--maroon-text-color","#c30000"),s.style.setProperty("--crimson-text-color","#eb0000"),s.style.setProperty("--orchid-text-color","#fd59f7"),s.style.setProperty("--darkorchid-text-color","#c205ff"),s.style.setProperty("--gray-text-color","#8f8f8f"),s.style.setProperty("--box-color","#000000"),s.style.setProperty("--boxmain-bordercolor","#b341e0"),s.style.setProperty("--button-color","#21003f"),s.style.setProperty("--hover-color","#00056a"),s.style.setProperty("--blackbtn-color","#28002a"),s.style.setProperty("--purplebtn-color","#5800a0"),s.style.setProperty("--purplehover-color","#680927"),s.style.setProperty("--buttonbuy-color","#005e00"),s.style.setProperty("--buildings-canbuy-color","#a00"),s.style.setProperty("--buildings-hover-color","#e00"),s.style.setProperty("--blessings-canbuy-color","#004d00"),s.style.setProperty("--blessings-hover-color","#800"),s.style.setProperty("--tab-color","#1a0030"),s.style.setProperty("--singtab-color","#000230"),s.style.setProperty("--hoversing-color","#000463"),s.style.setProperty("--shoptab-color","#5800a0"),s.style.setProperty("--hovershop-color","#7400d3"),s.style.setProperty("--hepteract-bar-empty","#4a4a60"),s.style.setProperty("--hepteract-bar-red","#c90000"),s.style.setProperty("--hepteract-bar-yellow","#919100"),s.style.setProperty("--hepteract-bar-green","#007f3b"),i("themeBox").style.backgroundColor="#0a0a11",i("themeBox").style.borderColor="#3c006d",i("c15Rewards").style.backgroundColor="#2e001b",i("c15Rewards").style.borderColor="#186e83",i("platonicUpgradeDescriptions").style.backgroundColor="#2e001b",i("platonicUpgradeDescriptions").style.borderColor="#186e83",i("platonicUpgradePics").style.backgroundColor="#720505",i("platonicUpgradePics").style.borderColor="#410303",i("actualPotionShop").style.backgroundColor="#01192c",i("actualPotionShop").style.borderColor="#04d481",i("actualShop").style.backgroundColor="#11111b",i("actualShop").style.borderColor="#038ba8",i("corruptionStatsLoadouts").style.backgroundColor="#0a0a11",i("corruptionStatsLoadouts").style.borderColor="#04d481",i("heptGrid").style.backgroundColor="#11111b",i("heptGrid").style.borderColor="#9b7306",i("achievementcolorcode2").style.color="#ef00e4",i("corruptionDescription").style.color="#c205ff",i("corruptionTesseracts").style.color="#c205ff",i("antwelcome").style.color="darkgrey",i("confirmationToggleTitle").style.color="#eb0000",i("specialActionsTitle").style.color="#eb0000",i("themesTitle").style.color="#eb0000",i("notationTitle").style.color="#eb0000",i("hepteractWelcome").style.color="#ac47ff",i("confirmationdisclaimer").style.color="#bb68ff",i("antspecies").style.color="#184ff3",i("bonussummation").style.color="#eb0000",i("buildinghotkeys").style.color="#838383",i("buildinghotkeys2").style.color="#838383",a.textContent="Dracula Mode"),n&&setTimeout(()=>{s.style.removeProperty("--transition"),s.style.removeProperty("--transition-extra")},750)};var om=(t=!0)=>{let r=i("notation"),n=e.notation,a;switch(n){case"Pure Scientific":r.textContent=u.t("settings.notation.pureEngineering"),a="Pure Engineering";break;case"Pure Engineering":r.textContent=u.t("settings.notation.default"),a="Default";break;default:r.textContent=u.t("settings.notation.pureScientific"),a="Pure Scientific"}t&&(e.notation=a)},im=()=>{let t=i("notation");switch(e.notation){case"Pure Scientific":t.textContent=u.t("settings.notation.pureScientific");break;case"Pure Engineering":t.textContent=u.t("settings.notation.pureEngineering");break;default:t.textContent=u.t("settings.notation.default")}},Be=[["Legacy",-1],["Default",0],["Simplified",1],["Monotonous",1]],Ki=/Default|Simplified|Monotonous|Legacy/,Xi=(t=e.iconSet)=>{(t>Be.length-1||t<0)&&(t=0),e.iconSet=t,Array.from(document.getElementsByTagName("img")).forEach(r=>{r.src=r.src.replace(Ki,Be[e.iconSet][0])}),i("iconSet").textContent=u.t(`settings.iconSets.${Be[e.iconSet][0].toLowerCase()}`)};function lm(t){if(t instanceof ErrorEvent&&console.log("error: ",t.error),!t.target||!(t.target instanceof HTMLImageElement))return;let r=t.target,n=Be[e.iconSet][0],a=Be[e.iconSet][1],s="Legacy";a>=0&&at.method!==void 0&&t.method==="call";var pm=t=>t.error===null&&typeof t.id=="number";var gm=t=>{let r=new Map([[0,()=>{}]]),n=new Map([[0,()=>{}]]),a=new Map,s=new Worker(t);return s.addEventListener("message",({data:m})=>{if(dm(m)){let{params:{timerId:h,timerType:b}}=m;if(b==="interval"){let C=r.get(h);if(typeof C=="number"){let v=a.get(C);if(v===void 0||v.timerId!==h||v.timerType!==b)throw new Error("The timer is in an undefined state.")}else if(typeof C<"u")C();else throw new Error("The timer is in an undefined state.")}else if(b==="timeout"){let C=n.get(h);if(typeof C=="number"){let v=a.get(C);if(v===void 0||v.timerId!==h||v.timerType!==b)throw new Error("The timer is in an undefined state.")}else if(typeof C<"u")C(),n.delete(h);else throw new Error("The timer is in an undefined state.")}}else if(pm(m)){let{id:h}=m,b=a.get(h);if(b===void 0)throw new Error("The timer is in an undefined state.");let{timerId:C,timerType:v}=b;a.delete(h),v==="interval"?r.delete(C):n.delete(C)}else{let{error:{message:h}}=m;throw new Error(h)}}),{clearInterval:m=>{let h=(0,fo.generateUniqueNumber)(a);a.set(h,{timerId:m,timerType:"interval"}),r.set(m,h),s.postMessage({id:h,method:"clear",params:{timerId:m,timerType:"interval"}})},clearTimeout:m=>{let h=(0,fo.generateUniqueNumber)(a);a.set(h,{timerId:m,timerType:"timeout"}),n.set(m,h),s.postMessage({id:h,method:"clear",params:{timerId:m,timerType:"timeout"}})},setInterval:(m,h=0)=>{let b=(0,fo.generateUniqueNumber)(r);return r.set(b,()=>{m(),typeof r.get(b)=="function"&&s.postMessage({id:null,method:"set",params:{delay:h,now:performance.now(),timerId:b,timerType:"interval"}})}),s.postMessage({id:null,method:"set",params:{delay:h,now:performance.now(),timerId:b,timerType:"interval"}}),b},setTimeout:(m,h=0)=>{let b=(0,fo.generateUniqueNumber)(n);return n.set(b,m),s.postMessage({id:null,method:"set",params:{delay:h,now:performance.now(),timerId:b,timerType:"timeout"}}),b}}};var mm=(t,r)=>{let n=null;return()=>{if(n!==null)return n;let a=new Blob([r],{type:"application/javascript; charset=utf-8"}),s=URL.createObjectURL(a);return n=t(s),setTimeout(()=>URL.revokeObjectURL(s)),n}};var fm=`(()=>{"use strict";const e=new Map,t=new Map,r=(e,t)=>{let r,o;const i=performance.now();r=i,o=e-Math.max(0,i-t);return{expected:r+o,remainingDelay:o}},o=(e,t,r,i)=>{const s=performance.now();s>r?postMessage({id:null,method:"call",params:{timerId:t,timerType:i}}):e.set(t,setTimeout(o,r-s,e,t,r,i))};addEventListener("message",(i=>{let{data:s}=i;try{if("clear"===s.method){const{id:r,params:{timerId:o,timerType:i}}=s;if("interval"===i)(t=>{const r=e.get(t);if(void 0===r)throw new Error('There is no interval scheduled with the given id "'.concat(t,'".'));clearTimeout(r),e.delete(t)})(o),postMessage({error:null,id:r});else{if("timeout"!==i)throw new Error('The given type "'.concat(i,'" is not supported'));(e=>{const r=t.get(e);if(void 0===r)throw new Error('There is no timeout scheduled with the given id "'.concat(e,'".'));clearTimeout(r),t.delete(e)})(o),postMessage({error:null,id:r})}}else{if("set"!==s.method)throw new Error('The given method "'.concat(s.method,'" is not supported'));{const{params:{delay:i,now:n,timerId:a,timerType:d}}=s;if("interval"===d)((t,i,s)=>{const{expected:n,remainingDelay:a}=r(t,s);e.set(i,setTimeout(o,a,e,i,n,"interval"))})(i,a,n);else{if("timeout"!==d)throw new Error('The given type "'.concat(d,'" is not supported'));((e,i,s)=>{const{expected:n,remainingDelay:a}=r(e,s);t.set(i,setTimeout(o,a,t,i,n,"timeout"))})(i,a,n)}}}}catch(e){postMessage({error:{message:e.message},id:s.id,result:null})}}))})();`;var Yi=mm(gm,fm),hm=t=>Yi().clearInterval(t),bm=t=>Yi().clearTimeout(t),ym=(...t)=>Yi().setInterval(...t),vm=(...t)=>Yi().setTimeout(...t);var mn=[],It=(t,r)=>{let n=ym(t,r);return mn.push({id:n,type:"interval"}),n},Ba=t=>{for(let r of mn)if(r.type==="interval"&&r.id===t){hm(t),mn.splice(mn.indexOf(r),1);return}},Ji=(t,r)=>{let n=vm(t,r);return mn.push({id:n,type:"timeout"}),n},uu=t=>{for(let r of mn)if(r.type==="timeout"&&r.id===t){bm(t),mn.splice(mn.indexOf(r),1);return}},du=()=>{for(let{id:t,type:r}of mn)r==="interval"?Ba(t):uu(t)};var Xy="756419583941804072",Zy="758859750070026241",Yy="758861068188647444",Jy="832099983389097995",ev="677272036820910098",tv="1177364773986386021",rv="1311161342987603979",nv="1178131525049520138",av="1311164406209450064",sv="983484264865730560",ov="1045560188574380042",iv="1045560846169935922",lv="1045562390995009606",cv="1178125584061173800",uv="1311165096378105906",wm=!1,ys=()=>wm;async function xm(){var g,m,h,b,C,v,x,B,U,k,L,E,T;let t=document.querySelector("#accountSubTab > div.scrollbarX"),r=i("currentBonus"),n=document.getElementById("logoutButton");n!==null&&(n.addEventListener("click",dv,{once:!0}),(g=document.getElementById("accountSubTab"))==null||g.appendChild(n));let a=await fetch("https://synergism.cc/api/v1/users/me").catch(()=>new Response(JSON.stringify({member:null,globalBonus:0,personalBonus:0})));if(!a.ok){r.textContent=`Oh no! I couldn't fetch the bonus... Please send this to Khafra in the Discord: ${await a.text()}.`;return}let{globalBonus:s,member:l,personalBonus:c,accountType:p}=await a.json();if(Sp(100*(1+s/100)*(1+c/100)-100),e.worlds=new Un(Number(e.worlds)),wm=l!==null,r.textContent=`Generous patrons give you a bonus of ${s}% more Quarks!`,location.hostname!=="synergism.cc")t.textContent="Login is not available here, go to https://synergism.cc instead!";else if(l!==null){r.textContent+=` You also receive an extra ${c}% bonus for being a Patreon member and/or boosting the Discord server! Multiplicative with global bonus!`;let S;p==="discord"?S=(v=(C=(h=l.nick)!=null?h:(m=l.user)==null?void 0:m.username)!=null?C:(b=l.user)==null?void 0:b.global_name)!=null?v:null:S=l.user.username;let I=p==="discord"&&(!!(l!=null&&l.premium_since)||(l==null?void 0:l.roles.includes(ev))),N=(x=l.roles.includes(Xy))!=null?x:!1,X=(B=l.roles.includes(Zy))!=null?B:!1,re=(U=l.roles.includes(Yy))!=null?U:!1,w=(k=l.roles.includes(Jy))!=null?k:!1,H=Ct=>`[\u2714] {+${Ct}%}`,J='[\u2716] {+0%}';t.innerHTML=` +Type -1 in Buy: ANY to buy equal amounts of both Potions.`:"";if(e.shopBuyMaxToggle==="ANY"&&!c){let b=await Ee(`You can afford to purchase up to ${p} of ${Na(t)} for ${l.toLocaleString()} Quarks. How many would you like to buy?${m+g}`),C;if(Number(b)===-1&&r.type==="consume"){let x=t==="offeringPotion"?"obtainiumPotion":"offeringPotion",B=Math.max(+e.worlds/2,+e.worlds-l),U=sr(e.shopUpgrades[x],pe[x].price,B,pe[x].priceIncrease/pe[x].price,pe[x].maxLevel-e.shopUpgrades[x]);e.worlds.sub(U.cost),e.shopUpgrades[x]=U.levelCanBuy,C=s}else{if(C=Math.floor(Number(b)),C===0)return;if(Number.isNaN(C)||!Number.isFinite(C)||C<0)return P("Amount must be a finite, positive integer.")}let v=sr(e.shopUpgrades[t],r.price,+e.worlds,r.priceIncrease/r.price,Math.min(C,s));e.worlds.sub(v.cost),e.shopUpgrades[t]=v.levelCanBuy,Oe(),o.ambrosiaCurrStats.ambrosiaLuck=Ge().value,o.ambrosiaCurrStats.ambrosiaAdditiveLuckMult=zr().value,o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value;return}let h=!0;(e.shopConfirmationToggle||!r.refundable&&e.shopBuyMaxToggle!==!1)&&(h=await ye(`You are about to ${c?"unlock":`purchase ${p} of`} ${Na(t)} for ${l.toLocaleString()} Quarks. Press 'OK' to finalize purchase.${m+g}`)),h&&(e.worlds.sub(l),e.shopUpgrades[t]+=s,o.ambrosiaCurrStats.ambrosiaLuck=Ge().value,o.ambrosiaCurrStats.ambrosiaAdditiveLuckMult=zr().value,o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value,Oe())};var gn=async(t,r=!1,n=1,a=!0)=>{let s=xe.AUTO_POTION_FREE_POTIONS_QOL;if(e.shopConfirmationToggle&&!r?await ye("Would you like to use some of this potion?"):!0){let c=+e.singularityUpgrades.potionBuff.getEffect().bonus*+e.singularityUpgrades.potionBuff2.getEffect().bonus*+e.singularityUpgrades.potionBuff3.getEffect().bonus*+e.octeractUpgrades.octeractAutoPotionEfficiency.getEffect().bonus*n;t==="offeringPotion"?s&&r?(e.runeshards+=Math.floor(7200*e.offeringpersecond*qe().mult*c),e.runeshards=Math.min(1e300,e.runeshards)):(e.shopUpgrades.offeringPotion>=n||!a)&&(e.shopUpgrades.offeringPotion-=a?n:0,e.runeshards+=Math.floor(7200*e.offeringpersecond*qe().mult*c),e.runeshards=Math.min(1e300,e.runeshards)):t==="obtainiumPotion"&&(s&&r?(e.researchPoints+=Math.floor(7200*e.maxobtainiumpersecond*qe().mult*c),e.researchPoints=Math.min(1e300,e.researchPoints)):(e.shopUpgrades.obtainiumPotion>=n||!a)&&(e.shopUpgrades.obtainiumPotion-=a?n:0,e.researchPoints+=Math.floor(7200*e.maxobtainiumpersecond*qe().mult*c),e.researchPoints=Math.min(1e300,e.researchPoints)))}},Wi=async(t=!1)=>{let r=!1;if(t||(r=e.shopConfirmationToggle?await ye("This will fully refund most of your permanent upgrades for an upfront cost of 15 Quarks. Would you like to do this?"):!0),r||t){let n=e.quarksThisSingularity,a=!1;for(let s in pe){let l=s,c=pe[l];if(c.refundable&&e.shopUpgrades[l]>c.refundMinimumLevel){a=!0;let p=c.price*c.refundMinimumLevel+c.priceIncrease*c.refundMinimumLevel*(c.refundMinimumLevel-1)/2;e.worlds.add(c.price*e.shopUpgrades[l]+c.priceIncrease*e.shopUpgrades[l]*(e.shopUpgrades[l]-1)/2-p,!1),e.shopUpgrades[l]=c.refundMinimumLevel}}a?e.worlds.sub(15):!t&&e.shopConfirmationToggle&&P("Nothing to Refund!"),e.quarksThisSingularity=n}};var xs=t=>{switch(t){case"offeringPotion":return!0;case"obtainiumPotion":return!0;case"offeringEX":return e.reincarnationCount>0||e.highestSingularityCount>0;case"offeringAuto":return e.reincarnationCount>0||e.highestSingularityCount>0;case"obtainiumEX":return e.reincarnationCount>0||e.highestSingularityCount>0;case"obtainiumAuto":return e.reincarnationCount>0||e.highestSingularityCount>0;case"instantChallenge":return e.reincarnationCount>0||e.highestSingularityCount>0;case"antSpeed":return e.highestchallengecompletions[8]>0||e.ascensionCount>0||e.highestSingularityCount>0;case"cashGrab":return e.highestchallengecompletions[8]>0||e.ascensionCount>0||e.highestSingularityCount>0;case"shopTalisman":return e.highestchallengecompletions[9]>0||e.ascensionCount>0||e.highestSingularityCount>0;case"seasonPass":return e.ascensionCount>0||e.highestSingularityCount>0;case"challengeExtension":return e.ascensionCount>0||e.highestSingularityCount>0;case"challengeTome":return e.ascensionCount>0||e.highestSingularityCount>0;case"cubeToQuark":return e.ascensionCount>0||e.highestSingularityCount>0;case"tesseractToQuark":return e.highestchallengecompletions[11]>0||e.highestSingularityCount>0;case"hypercubeToQuark":return e.highestchallengecompletions[13]>0||e.highestSingularityCount>0;case"seasonPass2":return e.highestchallengecompletions[14]>0||e.highestSingularityCount>0;case"seasonPass3":return e.highestchallengecompletions[14]>0||e.highestSingularityCount>0;case"chronometer":return e.highestchallengecompletions[12]>0||e.highestSingularityCount>0;case"infiniteAscent":return e.highestchallengecompletions[14]>0||e.highestSingularityCount>0;case"calculator":return e.ascensionCount>0||e.highestSingularityCount>0;case"calculator2":return e.highestchallengecompletions[11]>0||e.highestSingularityCount>0;case"calculator3":return e.highestchallengecompletions[13]>0||e.highestSingularityCount>0;case"calculator4":return!!e.singularityUpgrades.wowPass.getEffect().bonus;case"calculator5":return!!e.singularityUpgrades.wowPass2.getEffect().bonus;case"calculator6":return!!e.singularityUpgrades.wowPass3.getEffect().bonus;case"calculator7":return!!e.singularityChallenges.limitedAscensions.rewards.shopUpgrade;case"constantEX":return e.highestchallengecompletions[14]>0||e.highestSingularityCount>0;case"powderEX":return e.challenge15Exponent>=1e15||e.highestSingularityCount>0;case"chronometer2":return e.challenge15Exponent>=1e15||e.highestSingularityCount>0;case"chronometer3":return!!e.singularityUpgrades.wowPass.getEffect().bonus;case"seasonPassY":return e.challenge15Exponent>=1e15||e.highestSingularityCount>0;case"seasonPassZ":return!!e.singularityUpgrades.wowPass.getEffect().bonus;case"challengeTome2":return!!e.singularityUpgrades.wowPass.getEffect().bonus;case"instantChallenge2":return!!e.singularityUpgrades.wowPass.getEffect().bonus;case"cashGrab2":return!!e.singularityUpgrades.wowPass2.getEffect().bonus;case"cubeToQuarkAll":return!!e.singularityUpgrades.wowPass2.getEffect().bonus;case"chronometerZ":return!!e.singularityUpgrades.wowPass2.getEffect().bonus;case"offeringEX2":return!!e.singularityUpgrades.wowPass2.getEffect().bonus;case"obtainiumEX2":return!!e.singularityUpgrades.wowPass2.getEffect().bonus;case"powderAuto":return!!e.singularityUpgrades.wowPass2.getEffect().bonus;case"seasonPassLost":return!!e.singularityUpgrades.wowPass2.getEffect().bonus;case"challenge15Auto":return!!e.singularityUpgrades.wowPass3.getEffect().bonus;case"extraWarp":return!!e.singularityUpgrades.wowPass3.getEffect().bonus;case"autoWarp":return!!e.singularityUpgrades.wowPass3.getEffect().bonus;case"improveQuarkHept":return e.challenge15Exponent>=1e15||e.highestSingularityCount>0;case"improveQuarkHept2":return!!e.singularityUpgrades.wowPass.getEffect().bonus;case"improveQuarkHept3":return!!e.singularityUpgrades.wowPass2.getEffect().bonus;case"improveQuarkHept4":return!!e.singularityUpgrades.wowPass3.getEffect().bonus;case"shopImprovedDaily":return e.highestchallengecompletions[14]>0||e.highestSingularityCount>0;case"shopImprovedDaily2":return!!e.singularityUpgrades.wowPass.getEffect().bonus;case"shopImprovedDaily3":return!!e.singularityUpgrades.wowPass2.getEffect().bonus;case"shopImprovedDaily4":return!!e.singularityUpgrades.wowPass3.getEffect().bonus;case"offeringEX3":return!!e.singularityUpgrades.wowPass4.getEffect().bonus;case"obtainiumEX3":return!!e.singularityUpgrades.wowPass4.getEffect().bonus;case"improveQuarkHept5":return!!e.singularityUpgrades.wowPass4.getEffect().bonus;case"chronometerInfinity":return!!e.singularityUpgrades.wowPass4.getEffect().bonus;case"seasonPassInfinity":return!!e.singularityUpgrades.wowPass4.getEffect().bonus;case"shopSingularityPenaltyDebuff":return!!e.singularityChallenges.noSingularityUpgrades.rewards.shopUpgrade;case"shopAmbrosiaLuckMultiplier4":return!!e.singularityChallenges.oneChallengeCap.rewards.shopUpgrade;case"shopOcteractAmbrosiaLuck":return!!e.singularityChallenges.noOcteracts.rewards.shopUpgrade;case"shopAmbrosiaGeneration1":return!!e.singularityUpgrades.wowPass2.getEffect().bonus;case"shopAmbrosiaGeneration2":return!!e.singularityUpgrades.wowPass3.getEffect().bonus;case"shopAmbrosiaGeneration3":return!!e.singularityUpgrades.wowPass4.getEffect().bonus;case"shopAmbrosiaGeneration4":return!!e.singularityUpgrades.wowPass4.getEffect().bonus;case"shopAmbrosiaLuck1":return!!e.singularityUpgrades.wowPass2.getEffect().bonus;case"shopAmbrosiaLuck2":return!!e.singularityUpgrades.wowPass3.getEffect().bonus;case"shopAmbrosiaLuck3":return!!e.singularityUpgrades.wowPass4.getEffect().bonus;case"shopAmbrosiaLuck4":return!!e.singularityUpgrades.wowPass4.getEffect().bonus;case"shopCashGrabUltra":return!!e.singularityChallenges.noSingularityUpgrades.rewards.shopUpgrade2;case"shopAmbrosiaAccelerator":return!!e.singularityChallenges.noAmbrosiaUpgrades.rewards.shopUpgrade;case"shopEXUltra":return!!e.singularityChallenges.noAmbrosiaUpgrades.rewards.shopUpgrade2;case"shopChronometerS":return!!e.singularityChallenges.limitedTime.rewards.tier1Upgrade;case"shopAmbrosiaUltra":return!!e.singularityChallenges.limitedTime.rewards.tier2Upgrade;case"shopSingularitySpeedup":return!!e.singularityChallenges.sadisticPrequel.rewards.shopUpgrade;case"shopSingularityPotency":return!!e.singularityChallenges.sadisticPrequel.rewards.shopUpgrade2;case"shopSadisticRune":return!!e.singularityChallenges.sadisticPrequel.rewards.shopUpgrade3}};var cm={shard:{obtainium:1e13,offerings:100},commonFragment:{obtainium:1e14,offerings:1e4},uncommonFragment:{obtainium:1e16,offerings:1e5},rareFragment:{obtainium:1e18,offerings:1e6},epicFragment:{obtainium:1e20,offerings:1e7},legendaryFragment:{obtainium:1e22,offerings:1e8},mythicalFragment:{obtainium:1e24,offerings:1e9}},pu=["One","Two","Three","Four","Five","Six","Seven"],yo=t=>{let r=30*e.talismanRarity[t];return r+=6*_("ascension",e.challengecompletions[13]),r+=Math.floor(e.researches[200]/400),t===6&&(r+=xe.INSTANT_UNLOCK_1?10:0),e.cubeUpgrades[67]>0&&t===3&&(r+=1337),r},um=(t,r=e.buyTalismanShardPercent)=>{let n=cm[t].obtainium,a=cm[t].offerings,s=Math.max(1,Math.floor(e.researchPoints/n)),l=Math.max(1,Math.floor(e.runeshards/a)),c=Math.max(1,Math.floor(r/100*Math.min(s,l)));return{canBuy:n<=e.researchPoints&&a<=e.runeshards,buyAmount:c,obtainiumCost:n*c,offeringCost:a*c}},zi=(t,r=e.buyTalismanShardPercent)=>{let n=i("talismanFragmentCost");if(t){let a=um(t,r),s=u.t(`runes.talismans.shards.${t}`);n.textContent=u.t("runes.talismans.costToBuy",{name:s,buyAmount:d(a.buyAmount),obtainium:d(a.obtainiumCost),offerings:d(a.offeringCost)})}else n.textContent=u.t("runes.talismans.clickBuyEveryType")},Ms=(t=e.buyTalismanShardPercent)=>{i("talismanTen").style.backgroundColor="",i("talismanTwentyFive").style.backgroundColor="",i("talismanFifty").style.backgroundColor="",i("talismanHundred").style.backgroundColor="",e.buyTalismanShardPercent=t;let r="Ten";t===25&&(r="TwentyFive"),t===50&&(r="Fifty"),t===100&&(r="Hundred"),i(`talisman${r}`).style.backgroundColor="green"},Zt=()=>{i("talismanShardInventory").textContent=d(e.talismanShards),i("commonFragmentInventory").textContent=d(e.commonFragments),i("uncommonFragmentInventory").textContent=d(e.uncommonFragments),i("rareFragmentInventory").textContent=d(e.rareFragments),i("epicFragmentInventory").textContent=d(e.epicFragments),i("legendaryFragmentInventory").textContent=d(e.legendaryFragments),i("mythicalFragmentInventory").textContent=d(e.mythicalFragments)},Xi=()=>{let t=["shard","commonFragment","uncommonFragment","rareFragment","epicFragment","legendaryFragment","mythicalFragment"];for(let r=t.length-1;r>=0;r--)gu(t[r])},gu=(t,r=e.buyTalismanShardPercent)=>{let n=um(t,r);n.canBuy&&(t==="shard"?e.talismanShards+=n.buyAmount:e[`${t}s`]+=n.buyAmount,t==="mythicalFragment"&&e.mythicalFragments>=1e25&&e.achievements[239]<1&&R(239),e.researchPoints-=n.obtainiumCost,e.runeshards-=n.offeringCost,e.researchPoints<0&&(e.researchPoints=0),e.runeshards<0&&(e.runeshards=0)),zi(t,r),Zt()},Zi=t=>{i("talismanlevelup").style.display="none",i("talismanEffect").style.display="block",i("talismanrespec").style.display="none";let r=i("talismanSummary"),n=i("talismanBonus"),a=i("talismanRune1Effect"),s=i("talismanRune2Effect"),l=i("talismanRune3Effect"),c=i("talismanRune4Effect"),p=i("talismanRune5Effect"),g=i("talismanMythicEffect"),m="",h="";switch(t){case 0:m="exemption",h=d(10*(e.talismanRarity[0]-1));break;case 1:m="chronos",h=d(10*(e.talismanRarity[1]-1));break;case 2:m="midas",h=d(10*(e.talismanRarity[2]-1));break;case 3:m="metaphysics",h=d(.02*(e.talismanRarity[3]-1),2);break;case 4:m="polymath",h=d(1*(e.talismanRarity[4]-1));break;case 5:m="mortuus",h=d(2*(e.talismanRarity[5]-1));break;case 6:m="plastic";break}let b=`talisman${t+1}Effect`;r.textContent=u.t(`runes.talismans.summaries.${m}`),n.textContent=u.t(`runes.talismans.effects.${m}`,{x:h}),a.textContent=u.t("runes.talismans.bonusRuneLevels.speed",{x:d(o[b][1],2,!0)}),s.textContent=u.t("runes.talismans.bonusRuneLevels.duplication",{x:d(o[b][2],2,!0)}),l.textContent=u.t("runes.talismans.bonusRuneLevels.prism",{x:d(o[b][3],2,!0)}),c.textContent=u.t("runes.talismans.bonusRuneLevels.thrift",{x:d(o[b][4],2,!0)}),p.textContent=u.t("runes.talismans.bonusRuneLevels.SI",{x:d(o[b][5],2,!0)}),g.textContent=u.t(`runes.talismans.mythicEffects.${m}`),e.talismanRarity[t]!==6&&(g.textContent=u.t("runes.talismans.maxEnhance"))},mu=t=>{i("talismanEffect").style.display="none",i("talismanlevelup").style.display="block",i("talismanrespec").style.display="none";let r=i("talismanShardCost"),n=i("talismanCommonFragmentCost"),a=i("talismanUncommonFragmentCost"),s=i("talismanRareFragmentCost"),l=i("talismanEpicFragmentCost"),c=i("talismanLegendaryFragmentCost"),p=i("talismanMythicalFragmentCost");i("talismanLevelUpSummary").textContent=u.t("runes.resourcesToLevelup"),i("talismanLevelUpSummary").style.color="silver";let g=o.talismanLevelCostMultiplier[t];e.talismanLevels[t]>=120&&(g*=(e.talismanLevels[t]-90)/30),e.talismanLevels[t]>=150&&(g*=(e.talismanLevels[t]-120)/30),e.talismanLevels[t]>=180&&(g*=(e.talismanLevels[t]-170)/10),r.textContent=d(g*Math.max(0,Math.floor(1+1/8*Math.pow(e.talismanLevels[t],3)))),n.textContent=d(g*Math.max(0,Math.floor(1+1/32*Math.pow(e.talismanLevels[t]-30,3)))),a.textContent=d(g*Math.max(0,Math.floor(1+1/384*Math.pow(e.talismanLevels[t]-60,3)))),s.textContent=d(g*Math.max(0,Math.floor(1+1/500*Math.pow(e.talismanLevels[t]-90,3)))),l.textContent=d(g*Math.max(0,Math.floor(1+1/375*Math.pow(e.talismanLevels[t]-120,3)))),c.textContent=d(g*Math.max(0,Math.floor(1+1/192*Math.pow(e.talismanLevels[t]-150,3)))),p.textContent=d(g*Math.max(0,Math.floor(1+1/1280*Math.pow(e.talismanLevels[t]-150,3))))},fu=t=>{i("talismanEffect").style.display="none",i("talismanlevelup").style.display="block",i("talismanrespec").style.display="none";let r=i("talismanShardCost"),n=i("talismanCommonFragmentCost"),a=i("talismanUncommonFragmentCost"),s=i("talismanRareFragmentCost"),l=i("talismanEpicFragmentCost"),c=i("talismanLegendaryFragmentCost"),p=i("talismanMythicalFragmentCost");i("talismanLevelUpSummary").textContent=u.t("runes.resourcesToEnhance"),i("talismanLevelUpSummary").style.color="gold";let g=[o.commonTalismanEnhanceCost,o.uncommonTalismanEnchanceCost,o.rareTalismanEnchanceCost,o.epicTalismanEnhanceCost,o.legendaryTalismanEnchanceCost,o.mythicalTalismanEnchanceCost],m=e.talismanRarity[t],h=g[m-1],b=o.talismanLevelCostMultiplier[t];r.textContent=d(b*h[1]),n.textContent=d(b*h[2]),a.textContent=d(b*h[3]),s.textContent=d(b*h[4]),l.textContent=d(b*h[5]),c.textContent=d(b*h[6]),p.textContent=d(b*h[7])},hu=t=>{o.talismanRespec=t,i("talismanEffect").style.display="none",i("talismanlevelup").style.display="none",i("talismanrespec").style.display="block";let r=["speed","duplication","prism","thrift","SI"],n=["positive","positive","positive","positive","positive"];if(t<=6){for(let a=1;a<=5;a++)o.mirrorTalismanStats[a]=e[`talisman${pu[t]}`][a];i("confirmTalismanRespec").textContent=u.t("runes.talismans.respecConfirm")}if(t===7){for(let a=1;a<=5;a++)o.mirrorTalismanStats[a]=1;i("confirmTalismanRespec").textContent=u.t("runes.talismans.respecConfirmAll")}for(let a=1;a<=5;a++){let s=i(`talismanRespecButton${a}`);o.mirrorTalismanStats[a]===1?(s.style.border="2px solid limegreen",n[a-1]="positive"):o.mirrorTalismanStats[a]===-1&&(s.style.border="2px solid crimson",n[a-1]="negative"),s.textContent=u.t(`runes.talismans.modifiers.${n[a-1]}`,{name:u.t(`runes.names.${r[a-1]}`)})}i("confirmTalismanRespec").style.display="none"},dm=t=>{let r=[null,"speed","duplication","prism","thrift","SI"],n=i(`talismanRespecButton${t}`);o.mirrorTalismanStats[t]===1?(o.mirrorTalismanStats[t]=-1,n.textContent=u.t("runes.talismans.modifiers.negative",{name:u.t(`runes.names.${r[t]}`)}),n.style.border="2px solid crimson"):(o.mirrorTalismanStats[t]=1,n.textContent=u.t("runes.talismans.modifiers.positive",{name:u.t(`runes.names.${r[t]}`)}),n.style.border="2px solid limegreen"),o.mirrorTalismanStats.reduce((s,l)=>s+l,0)===1?i("confirmTalismanRespec").style.display="block":i("confirmTalismanRespec").style.display="none"},pm=t=>{if(e.runeshards>=1e5&&t<7){for(let r=1;r<=5;r++)e[`talisman${pu[t]}`][r]=o.mirrorTalismanStats[r];e.runeshards-=1e5,i("confirmTalismanRespec").style.display="none",i("talismanrespec").style.display="none",i("talismanEffect").style.display="block",Zi(t)}else if(e.runeshards>=4e5&&t===7){e.runeshards-=4e5;for(let r=0;r<7;r++)for(let n=1;n<=5;n++)e[`talisman${pu[r]}`][n]=o.mirrorTalismanStats[n];i("confirmTalismanRespec").style.display="none"}He()},gm=t=>{i("talismanrespec").style.display="none",t<7&&(i("talismanEffect").style.display="block",Zi(t))},dt=t=>{let r=i(`talisman${t+1}`),n=i(`talisman${t+1}level`),a=e.talismanRarity[t];a===1&&(r.style.border="4px solid white",n.style.color="white"),a===2&&(r.style.border="4px solid limegreen",n.style.color="limegreen"),a===3&&(r.style.border="4px solid lightblue",n.style.color="lightblue"),a===4&&(r.style.border="4px solid plum",n.style.color="plum"),a===5&&(r.style.border="4px solid orange",n.style.color="orange"),a===6&&(r.style.border="4px solid crimson",n.style.color="var(--crimson-text-color)")},Yi=(t,r=!1)=>{let n=1;e.ascensionCount>0&&(n=30),e.highestSingularityCount>0&&(n=180);let a=!1;for(let s=1;s<=n;s++){let l=0,c=o.talismanLevelCostMultiplier[t];if(e.talismanLevels[t]>=120&&(c*=(e.talismanLevels[t]-90)/30),e.talismanLevels[t]>=150&&(c*=(e.talismanLevels[t]-120)/30),e.talismanLevels[t]>=180&&(c*=(e.talismanLevels[t]-170)/10),e.talismanLevels[t]=c*Math.max(0,Math.floor(1+1/8*Math.pow(e.talismanLevels[t],3)))&&l++,e.commonFragments>=c*Math.max(0,Math.floor(1+1/32*Math.pow(e.talismanLevels[t]-30,3)))&&l++,e.uncommonFragments>=c*Math.max(0,Math.floor(1+1/384*Math.pow(e.talismanLevels[t]-60,3)))&&l++,e.rareFragments>=c*Math.max(0,Math.floor(1+1/500*Math.pow(e.talismanLevels[t]-90,3)))&&l++,e.epicFragments>=c*Math.max(0,Math.floor(1+1/375*Math.pow(e.talismanLevels[t]-120,3)))&&l++,e.legendaryFragments>=c*Math.max(0,Math.floor(1+1/192*Math.pow(e.talismanLevels[t]-150,3)))&&l++,e.mythicalFragments>=c*Math.max(0,Math.floor(1+1/1280*Math.pow(e.talismanLevels[t]-150,3)))&&l++),l===7)e.talismanShards-=c*Math.max(0,Math.floor(1+1/8*Math.pow(e.talismanLevels[t],3))),e.commonFragments-=c*Math.max(0,Math.floor(1+1/32*Math.pow(e.talismanLevels[t]-30,3))),e.uncommonFragments-=c*Math.max(0,Math.floor(1+1/384*Math.pow(e.talismanLevels[t]-60,3))),e.rareFragments-=c*Math.max(0,Math.floor(1+1/500*Math.pow(e.talismanLevels[t]-90,3))),e.epicFragments-=c*Math.max(0,Math.floor(1+1/375*Math.pow(e.talismanLevels[t]-120,3))),e.legendaryFragments-=c*Math.max(0,Math.floor(1+1/192*Math.pow(e.talismanLevels[t]-150,3))),e.mythicalFragments-=c*Math.max(0,Math.floor(1+1/1280*Math.pow(e.talismanLevels[t]-150,3))),e.talismanLevels[t]+=1,a=!0;else break}return!r&&a&&(mu(t),Zt(),He()),a},Ji=(t,r=!1)=>{let n=0;if(e.talismanRarity[t]<6){let a=o.talismanLevelCostMultiplier[t],s=[o.commonTalismanEnhanceCost,o.uncommonTalismanEnchanceCost,o.rareTalismanEnchanceCost,o.epicTalismanEnhanceCost,o.legendaryTalismanEnchanceCost,o.mythicalTalismanEnchanceCost],l=e.talismanRarity[t]-1,c=s[l];if(e.commonFragments>=a*c[2]&&n++,e.uncommonFragments>=a*c[3]&&n++,e.rareFragments>=a*c[4]&&n++,e.epicFragments>=a*c[5]&&n++,e.legendaryFragments>=a*c[6]&&n++,e.mythicalFragments>=a*c[7]&&n++,n===6)return e.commonFragments-=a*c[2],e.uncommonFragments-=a*c[3],e.rareFragments-=a*c[4],e.epicFragments-=a*c[5],e.legendaryFragments-=a*c[6],e.mythicalFragments-=a*c[7],e.talismanRarity[t]+=1,dt(t),r||(fu(t),Zt(),He()),!0}return!1};var tl=(t=!1,r=1,n=!1)=>{var l;let a=i("theme"),s=document.body;n?(localStorage.setItem("theme",`${r}`),s.style.setProperty("--transition","750ms"),s.style.setProperty("--transition-extra","600ms")):r=Number((l=localStorage.getItem("theme"))!=null?l:1),t?r===4&&i("logo").setAttribute("src","Pictures/logoLight.png"):(s.style.removeProperty("--header-color"),s.style.removeProperty("--bg-color"),s.style.removeProperty("--alert-color"),s.style.removeProperty("--history-lines"),s.style.removeProperty("--text-color"),s.style.removeProperty("--green-text-color"),s.style.removeProperty("--lightseagreen-text-color"),s.style.removeProperty("--crimson-text-color"),s.style.removeProperty("--red-text-color"),s.style.removeProperty("--maroon-text-color"),s.style.removeProperty("--orchid-text-color"),s.style.removeProperty("--darkorchid-text-color"),s.style.removeProperty("--darkcyan-text-color"),s.style.removeProperty("--gray-text-color"),s.style.removeProperty("--orangered-text-color"),s.style.removeProperty("--box-color"),s.style.removeProperty("--boxmain-bordercolor"),s.style.removeProperty("--button-color"),s.style.removeProperty("--hover-color"),s.style.removeProperty("--blackbtn-color"),s.style.removeProperty("--purplebtn-color"),s.style.removeProperty("--purplehover-color"),s.style.removeProperty("--buttonbuy-color"),s.style.removeProperty("--buildings-canbuy-color"),s.style.removeProperty("--buildings-hover-color"),s.style.removeProperty("--blessings-canbuy-color"),s.style.removeProperty("--blessings-hover-color"),s.style.removeProperty("--tab-color"),s.style.removeProperty("--singtab-color"),s.style.removeProperty("--hoversing-color"),s.style.removeProperty("--shoptab-color"),s.style.removeProperty("--hovershop-color"),s.style.removeProperty("--hepteract-bar-empty"),s.style.removeProperty("--hepteract-bar-red"),s.style.removeProperty("--hepteract-bar-yellow"),s.style.removeProperty("--hepteract-bar-green"),s.classList.remove("textOutline"),i("actualPotionShop").style.backgroundColor="",i("actualPotionShop").style.borderColor="",i("themeBox").style.backgroundColor="",i("themeBox").style.borderColor="",i("c15Rewards").style.backgroundColor="",i("c15Rewards").style.borderColor="",i("platonicUpgradeDescriptions").style.backgroundColor="",i("platonicUpgradeDescriptions").style.borderColor="",i("platonicUpgradePics").style.backgroundColor="",i("platonicUpgradePics").style.borderColor="",i("actualShop").style.backgroundColor="",i("actualShop").style.borderColor="",i("corruptionStatsLoadouts").style.backgroundColor="",i("corruptionStatsLoadouts").style.borderColor="",i("heptGrid").style.backgroundColor="",i("heptGrid").style.borderColor="",i("exportgame").style.backgroundColor="",i("importFileButton").style.backgroundColor="",i("switchTheme2").style.borderColor="darkslategray",i("bonussummation").style.color="orangered",i("corruptionDescription").style.color="darkviolet",i("versionnumber").style.color="fuchsia",i("singularitytab").style.color="red",i("traitstab").style.color="red",i("cubetab").style.color="red",i("ascTimeAccel").style.color="royalblue",i("buildinghotkeys").style.color="lightgray",i("buildinghotkeys2").style.color="lightgray",i("antspecies").style.color="royalblue",i("achievementcolorcode2").style.color="purple",i("corruptionTesseracts").style.color="darkviolet",i("antwelcome").style.color="lightslategrey",i("confirmationToggleTitle").style.color="pink",i("specialActionsTitle").style.color="pink",i("themesTitle").style.color="pink",i("notationTitle").style.color="pink",i("hepteractWelcome").style.color="pink",i("confirmationdisclaimer").style.color="plum",i("cube6Bonus").style.color="brown",i("tesseract6Bonus").style.color="brown",i("hypercube6Bonus").style.color="brown",i("runeshowpower5").style.color="tomato",i("hypercubeWelcome").style.color="#ff004c",i("hypercubeQuantity").style.color="#ff004c",i("hypercubeBlessingsTotal").style.color="#ff004c"),r===1?(localStorage.removeItem("theme"),a.textContent="Dark Mode"):r===2?(s.style.setProperty("--header-color","black"),s.style.setProperty("--bg-color","#0c0c0f"),s.style.setProperty("--alert-color","#040406"),s.style.setProperty("--history-lines","#1b1b22"),s.style.setProperty("--box-color","#060606"),s.style.setProperty("--boxmain-bordercolor","#d487d4"),s.style.setProperty("--button-color","#040406"),s.style.setProperty("--hover-color","#1b1b22"),s.style.setProperty("--purplebtn-color","#6f006f"),s.style.setProperty("--buttonbuy-color","#040406"),s.style.setProperty("--buildings-canbuy-color","#2c2c44"),s.style.setProperty("--buildings-hover-color","#3a3a58"),s.style.setProperty("--blessings-canbuy-color","#262639"),s.style.setProperty("--blessings-hover-color","#33334e"),s.style.setProperty("--tab-color","black"),s.style.setProperty("--singtab-color","#002"),s.style.setProperty("--hoversing-color","#00007d"),s.style.setProperty("--shoptab-color","#6f006f"),s.style.setProperty("--hepteract-bar-empty","#3a3a58"),s.style.setProperty("--hepteract-bar-red","darkred"),s.style.setProperty("--hepteract-bar-yellow","#997a00"),s.style.setProperty("--hepteract-bar-green","darkgreen"),i("corruptionStatsLoadouts").style.borderColor="#dd8f00",i("actualPotionShop").style.borderColor="#dd0",i("exportgame").style.backgroundColor="black",i("importFileButton").style.backgroundColor="black",a.textContent="Darker Mode"):r===3?(s.style.setProperty("--header-color","#18171c"),s.style.setProperty("--bg-color","#1c1b22"),s.style.setProperty("--alert-color","#141319"),s.style.setProperty("--history-lines","#083a3a"),s.style.setProperty("--box-color","#141319"),s.style.setProperty("--boxmain-bordercolor","#dda0dd"),s.style.setProperty("--button-color","#101828"),s.style.setProperty("--hover-color","#006"),s.style.setProperty("--blackbtn-color","#101828"),s.style.setProperty("--buttonbuy-color","#0b111c"),s.style.setProperty("--buildings-canbuy-color","#2d4471"),s.style.setProperty("--buildings-hover-color","#3c5a95"),s.style.setProperty("--blessings-canbuy-color","#1e2e4d"),s.style.setProperty("--blessings-hover-color","#2d4471"),s.style.setProperty("--tab-color","#101828"),s.style.setProperty("--hoversing-color","#005"),s.style.setProperty("--hepteract-bar-empty","#535064"),i("corruptionStatsLoadouts").style.borderColor="#ffa500",i("actualPotionShop").style.borderColor="#dd0",i("actualShop").style.backgroundColor="#0c0c0f",i("actualShop").style.borderColor="#d487d4",i("platonicUpgradePics").style.backgroundColor="#0c0c0f",s.style.setProperty("--maroon-text-color","#a90000"),a.textContent="Lighter Dark Mode"):r===4?(s.classList.add("textOutline"),s.style.setProperty("--header-color","#736e8d"),s.style.setProperty("--bg-color","#7c7891"),s.style.setProperty("--alert-color","#646175"),s.style.setProperty("--history-lines","#156e71"),s.style.setProperty("--box-color","#646175"),s.style.setProperty("--boxmain-bordercolor","#d894d8"),s.style.setProperty("--button-color","#136062"),s.style.setProperty("--hover-color","#187c7f"),s.style.setProperty("--blackbtn-color","#105254"),s.style.setProperty("--buttonbuy-color","#4c495a"),s.style.setProperty("--buildings-canbuy-color","#9794a8"),s.style.setProperty("--buildings-hover-color","#b2b0bf"),s.style.setProperty("--blessings-canbuy-color","#6c687f"),s.style.setProperty("--blessings-hover-color","#7c7990"),s.style.setProperty("--tab-color","#105254"),s.style.setProperty("--singtab-color","#00d"),s.style.setProperty("--hoversing-color","#1052B6"),s.style.setProperty("--hepteract-bar-empty","#858199"),s.style.setProperty("--hepteract-bar-red","#ea1741"),s.style.setProperty("--hepteract-bar-yellow","#cc0"),s.style.setProperty("--hepteract-bar-green","limegreen"),i("corruptionStatsLoadouts").style.borderColor="#dd8f00",i("actualPotionShop").style.borderColor="#dd0",i("switchTheme2").style.borderColor="#284242",s.style.setProperty("--green-text-color","limegreen"),s.style.setProperty("--red-text-color","#f55"),s.style.setProperty("--maroon-text-color","#ff5656"),s.style.setProperty("--crimson-text-color","#f7617d"),s.style.setProperty("--orchid-text-color","#dd7dda"),s.style.setProperty("--darkorchid-text-color","#cf9ee8"),s.style.setProperty("--darkcyan-text-color","turquoise"),s.style.setProperty("--lightseagreen-text-color","limegreen"),s.style.setProperty("--orangered-text-color","#f74"),s.style.setProperty("--gray-text-color","#a5a5a5"),i("achievementcolorcode2").style.color="#dc7dff",i("corruptionDescription").style.color="#d272ff",i("corruptionTesseracts").style.color="#d272ff",i("antwelcome").style.color="#b1b1b1",i("versionnumber").style.color="#ff5aff",i("singularitytab").style.color="#ff5252",i("traitstab").style.color="#ff5252",i("cubetab").style.color="#ff5252",i("antspecies").style.color="#8da9ff",i("ascTimeAccel").style.color="#97b0ff",i("cube6Bonus").style.color="#a5a5a5",i("tesseract6Bonus").style.color="#a5a5a5",i("hypercube6Bonus").style.color="#a5a5a5",i("hypercubeWelcome").style.color="#f58",i("hypercubeQuantity").style.color="#f58",i("hypercubeBlessingsTotal").style.color="#f58",i("runeshowpower5").style.color="#ff7158",a.textContent="Light Mode"):r===5&&(s.style.setProperty("--header-color","#0a0a11"),s.style.setProperty("--bg-color","#131319"),s.style.setProperty("--alert-color","#2a1035"),s.style.setProperty("--history-lines","#012d1c"),s.style.setProperty("--text-color","#ac47ff"),s.style.setProperty("--maroon-text-color","#c30000"),s.style.setProperty("--crimson-text-color","#eb0000"),s.style.setProperty("--orchid-text-color","#fd59f7"),s.style.setProperty("--darkorchid-text-color","#c205ff"),s.style.setProperty("--gray-text-color","#8f8f8f"),s.style.setProperty("--box-color","#000000"),s.style.setProperty("--boxmain-bordercolor","#b341e0"),s.style.setProperty("--button-color","#21003f"),s.style.setProperty("--hover-color","#00056a"),s.style.setProperty("--blackbtn-color","#28002a"),s.style.setProperty("--purplebtn-color","#5800a0"),s.style.setProperty("--purplehover-color","#680927"),s.style.setProperty("--buttonbuy-color","#005e00"),s.style.setProperty("--buildings-canbuy-color","#a00"),s.style.setProperty("--buildings-hover-color","#e00"),s.style.setProperty("--blessings-canbuy-color","#004d00"),s.style.setProperty("--blessings-hover-color","#800"),s.style.setProperty("--tab-color","#1a0030"),s.style.setProperty("--singtab-color","#000230"),s.style.setProperty("--hoversing-color","#000463"),s.style.setProperty("--shoptab-color","#5800a0"),s.style.setProperty("--hovershop-color","#7400d3"),s.style.setProperty("--hepteract-bar-empty","#4a4a60"),s.style.setProperty("--hepteract-bar-red","#c90000"),s.style.setProperty("--hepteract-bar-yellow","#919100"),s.style.setProperty("--hepteract-bar-green","#007f3b"),i("themeBox").style.backgroundColor="#0a0a11",i("themeBox").style.borderColor="#3c006d",i("c15Rewards").style.backgroundColor="#2e001b",i("c15Rewards").style.borderColor="#186e83",i("platonicUpgradeDescriptions").style.backgroundColor="#2e001b",i("platonicUpgradeDescriptions").style.borderColor="#186e83",i("platonicUpgradePics").style.backgroundColor="#720505",i("platonicUpgradePics").style.borderColor="#410303",i("actualPotionShop").style.backgroundColor="#01192c",i("actualPotionShop").style.borderColor="#04d481",i("actualShop").style.backgroundColor="#11111b",i("actualShop").style.borderColor="#038ba8",i("corruptionStatsLoadouts").style.backgroundColor="#0a0a11",i("corruptionStatsLoadouts").style.borderColor="#04d481",i("heptGrid").style.backgroundColor="#11111b",i("heptGrid").style.borderColor="#9b7306",i("achievementcolorcode2").style.color="#ef00e4",i("corruptionDescription").style.color="#c205ff",i("corruptionTesseracts").style.color="#c205ff",i("antwelcome").style.color="darkgrey",i("confirmationToggleTitle").style.color="#eb0000",i("specialActionsTitle").style.color="#eb0000",i("themesTitle").style.color="#eb0000",i("notationTitle").style.color="#eb0000",i("hepteractWelcome").style.color="#ac47ff",i("confirmationdisclaimer").style.color="#bb68ff",i("antspecies").style.color="#184ff3",i("bonussummation").style.color="#eb0000",i("buildinghotkeys").style.color="#838383",i("buildinghotkeys2").style.color="#838383",a.textContent="Dracula Mode"),n&&setTimeout(()=>{s.style.removeProperty("--transition"),s.style.removeProperty("--transition-extra")},750)};var mm=(t=!0)=>{let r=i("notation"),n=e.notation,a;switch(n){case"Pure Scientific":r.textContent=u.t("settings.notation.pureEngineering"),a="Pure Engineering";break;case"Pure Engineering":r.textContent=u.t("settings.notation.default"),a="Default";break;default:r.textContent=u.t("settings.notation.pureScientific"),a="Pure Scientific"}t&&(e.notation=a)},fm=()=>{let t=i("notation");switch(e.notation){case"Pure Scientific":t.textContent=u.t("settings.notation.pureScientific");break;case"Pure Engineering":t.textContent=u.t("settings.notation.pureEngineering");break;default:t.textContent=u.t("settings.notation.default")}},Be=[["Legacy",-1],["Default",0],["Simplified",1],["Monotonous",1]],el=/Default|Simplified|Monotonous|Legacy/,rl=(t=e.iconSet)=>{(t>Be.length-1||t<0)&&(t=0),e.iconSet=t,Array.from(document.getElementsByTagName("img")).forEach(r=>{r.src=r.src.replace(el,Be[e.iconSet][0])}),i("iconSet").textContent=u.t(`settings.iconSets.${Be[e.iconSet][0].toLowerCase()}`)};function hm(t){if(t instanceof ErrorEvent&&console.log("error: ",t.error),!t.target||!(t.target instanceof HTMLImageElement))return;let r=t.target,n=Be[e.iconSet][0],a=Be[e.iconSet][1],s="Legacy";a>=0&&at.method!==void 0&&t.method==="call";var Cm=t=>t.error===null&&typeof t.id=="number";var wm=t=>{let r=new Map([[0,()=>{}]]),n=new Map([[0,()=>{}]]),a=new Map,s=new Worker(t);return s.addEventListener("message",({data:m})=>{if(vm(m)){let{params:{timerId:h,timerType:b}}=m;if(b==="interval"){let C=r.get(h);if(typeof C=="number"){let v=a.get(C);if(v===void 0||v.timerId!==h||v.timerType!==b)throw new Error("The timer is in an undefined state.")}else if(typeof C<"u")C();else throw new Error("The timer is in an undefined state.")}else if(b==="timeout"){let C=n.get(h);if(typeof C=="number"){let v=a.get(C);if(v===void 0||v.timerId!==h||v.timerType!==b)throw new Error("The timer is in an undefined state.")}else if(typeof C<"u")C(),n.delete(h);else throw new Error("The timer is in an undefined state.")}}else if(Cm(m)){let{id:h}=m,b=a.get(h);if(b===void 0)throw new Error("The timer is in an undefined state.");let{timerId:C,timerType:v}=b;a.delete(h),v==="interval"?r.delete(C):n.delete(C)}else{let{error:{message:h}}=m;throw new Error(h)}}),{clearInterval:m=>{let h=(0,vo.generateUniqueNumber)(a);a.set(h,{timerId:m,timerType:"interval"}),r.set(m,h),s.postMessage({id:h,method:"clear",params:{timerId:m,timerType:"interval"}})},clearTimeout:m=>{let h=(0,vo.generateUniqueNumber)(a);a.set(h,{timerId:m,timerType:"timeout"}),n.set(m,h),s.postMessage({id:h,method:"clear",params:{timerId:m,timerType:"timeout"}})},setInterval:(m,h=0)=>{let b=(0,vo.generateUniqueNumber)(r);return r.set(b,()=>{m(),typeof r.get(b)=="function"&&s.postMessage({id:null,method:"set",params:{delay:h,now:performance.now(),timerId:b,timerType:"interval"}})}),s.postMessage({id:null,method:"set",params:{delay:h,now:performance.now(),timerId:b,timerType:"interval"}}),b},setTimeout:(m,h=0)=>{let b=(0,vo.generateUniqueNumber)(n);return n.set(b,m),s.postMessage({id:null,method:"set",params:{delay:h,now:performance.now(),timerId:b,timerType:"timeout"}}),b}}};var xm=(t,r)=>{let n=null;return()=>{if(n!==null)return n;let a=new Blob([r],{type:"application/javascript; charset=utf-8"}),s=URL.createObjectURL(a);return n=t(s),setTimeout(()=>URL.revokeObjectURL(s)),n}};var Mm=`(()=>{"use strict";const e=new Map,t=new Map,r=(e,t)=>{let r,o;const i=performance.now();r=i,o=e-Math.max(0,i-t);return{expected:r+o,remainingDelay:o}},o=(e,t,r,i)=>{const s=performance.now();s>r?postMessage({id:null,method:"call",params:{timerId:t,timerType:i}}):e.set(t,setTimeout(o,r-s,e,t,r,i))};addEventListener("message",(i=>{let{data:s}=i;try{if("clear"===s.method){const{id:r,params:{timerId:o,timerType:i}}=s;if("interval"===i)(t=>{const r=e.get(t);if(void 0===r)throw new Error('There is no interval scheduled with the given id "'.concat(t,'".'));clearTimeout(r),e.delete(t)})(o),postMessage({error:null,id:r});else{if("timeout"!==i)throw new Error('The given type "'.concat(i,'" is not supported'));(e=>{const r=t.get(e);if(void 0===r)throw new Error('There is no timeout scheduled with the given id "'.concat(e,'".'));clearTimeout(r),t.delete(e)})(o),postMessage({error:null,id:r})}}else{if("set"!==s.method)throw new Error('The given method "'.concat(s.method,'" is not supported'));{const{params:{delay:i,now:n,timerId:a,timerType:d}}=s;if("interval"===d)((t,i,s)=>{const{expected:n,remainingDelay:a}=r(t,s);e.set(i,setTimeout(o,a,e,i,n,"interval"))})(i,a,n);else{if("timeout"!==d)throw new Error('The given type "'.concat(d,'" is not supported'));((e,i,s)=>{const{expected:n,remainingDelay:a}=r(e,s);t.set(i,setTimeout(o,a,t,i,n,"timeout"))})(i,a,n)}}}}catch(e){postMessage({error:{message:e.message},id:s.id,result:null})}}))})();`;var al=xm(wm,Mm),Tm=t=>al().clearInterval(t),Sm=t=>al().clearTimeout(t),km=(...t)=>al().setInterval(...t),Lm=(...t)=>al().setTimeout(...t);var mn=[],$t=(t,r)=>{let n=km(t,r);return mn.push({id:n,type:"interval"}),n},_a=t=>{for(let r of mn)if(r.type==="interval"&&r.id===t){Tm(t),mn.splice(mn.indexOf(r),1);return}},sl=(t,r)=>{let n=Lm(t,r);return mn.push({id:n,type:"timeout"}),n},bu=t=>{for(let r of mn)if(r.type==="timeout"&&r.id===t){Sm(t),mn.splice(mn.indexOf(r),1);return}},yu=()=>{for(let{id:t,type:r}of mn)r==="interval"?_a(t):bu(t)};var lv="756419583941804072",cv="758859750070026241",uv="758861068188647444",dv="832099983389097995",pv="677272036820910098",gv="1177364773986386021",mv="1311161342987603979",fv="1178131525049520138",hv="1311164406209450064",bv="983484264865730560",yv="1045560188574380042",vv="1045560846169935922",Cv="1045562390995009606",wv="1178125584061173800",xv="1311165096378105906",Am=!1,Da=()=>Am;async function Em(){var g,m,h,b,C,v,x,B,U,k,L,E,T;let t=document.querySelector("#accountSubTab > div.scrollbarX"),r=i("currentBonus"),n=document.getElementById("logoutButton");n!==null&&(n.addEventListener("click",Mv,{once:!0}),(g=document.getElementById("accountSubTab"))==null||g.appendChild(n));let a=await fetch("https://synergism.cc/api/v1/users/me").catch(()=>new Response(JSON.stringify({member:null,globalBonus:0,personalBonus:0})));if(!a.ok){r.textContent=`Oh no! I couldn't fetch the bonus... Please send this to Khafra in the Discord: ${await a.text()}.`;return}let{globalBonus:s,member:l,personalBonus:c,accountType:p}=await a.json();if(Bp(100*(1+s/100)*(1+c/100)-100),e.worlds=new $n(Number(e.worlds)),Am=l!==null,r.textContent=`Generous patrons give you a bonus of ${s}% more Quarks!`,location.hostname!=="synergism.cc")t.textContent="Login is not available here, go to https://synergism.cc instead!";else if(l!==null){r.textContent+=` You also receive an extra ${c}% bonus for being a Patreon member and/or boosting the Discord server! Multiplicative with global bonus!`;let S;p==="discord"?S=(v=(C=(h=l.nick)!=null?h:(m=l.user)==null?void 0:m.username)!=null?C:(b=l.user)==null?void 0:b.global_name)!=null?v:null:S=l.user.username;let I=p==="discord"&&(!!(l!=null&&l.premium_since)||(l==null?void 0:l.roles.includes(pv))),N=(x=l.roles.includes(lv))!=null?x:!1,X=(B=l.roles.includes(cv))!=null?B:!1,re=(U=l.roles.includes(uv))!=null?U:!1,w=(k=l.roles.includes(dv))!=null?k:!1,H=xt=>`[\u2714] {+${xt}%}`,J='[\u2716] {+0%}';t.innerHTML=` ${S?`Hello, ${S}`:"Hello"}! Your personal Quark bonus is ${d(c,2,!0)}%, computed by the following: @@ -43,16 +43,16 @@ Type -1 in Buy: ANY to buy equal amounts of both Potions.`:"";if(e.shopBuyMaxTog Discord Server Booster [+1%] - ${I?H(1):J} Event Bonuses: - Thanksgiving 2023 [+0.2%] - ${l.roles.includes(tv)?H(.2):J} - Thanksgiving 2024 [+0.3%] - ${l.roles.includes(rv)?H(.3):J} - Conductor 2023 [+0.3%] - ${l.roles.includes(nv)?H(.3):J} - Conductor 2024 [+0.4%] - ${l.roles.includes(av)?H(.4):J} - Eight Leaf [+0.3%] - ${l.roles.includes(sv)?H(.3):J} - Ten Leaf [+0.4%] - ${l.roles.includes(ov)?H(.4):J} - Smith Incarnate [+0.6%] - ${l.roles.includes(iv)?H(.6):J} - Smith God [+0.7%] - ${l.roles.includes(lv)?H(.7):J} - Golden Smith God [+0.8%] - ${l.roles.includes(cv)?H(.8):J} - Diamond Smith Messiah [+1%] - ${l.roles.includes(uv)?H(1.2):J} + Thanksgiving 2023 [+0.2%] - ${l.roles.includes(gv)?H(.2):J} + Thanksgiving 2024 [+0.3%] - ${l.roles.includes(mv)?H(.3):J} + Conductor 2023 [+0.3%] - ${l.roles.includes(fv)?H(.3):J} + Conductor 2024 [+0.4%] - ${l.roles.includes(hv)?H(.4):J} + Eight Leaf [+0.3%] - ${l.roles.includes(bv)?H(.3):J} + Ten Leaf [+0.4%] - ${l.roles.includes(yv)?H(.4):J} + Smith Incarnate [+0.6%] - ${l.roles.includes(vv)?H(.6):J} + Smith God [+0.7%] - ${l.roles.includes(Cv)?H(.7):J} + Golden Smith God [+0.8%] - ${l.roles.includes(wv)?H(.8):J} + Diamond Smith Messiah [+1%] - ${l.roles.includes(xv)?H(1.2):J} And Finally... Being YOURSELF! [+1%] - ${H(1)} @@ -65,58 +65,105 @@ Type -1 in Buy: ANY to buy equal amounts of both Potions.`:"";if(e.shopBuyMaxTog --> PATREON <-- - `.trim();let Te=document.createElement("button"),lt=document.createElement("button");c>1&&(Te.addEventListener("click",pv),Te.style.cssText="border: 2px solid #5865F2; height: 25px; width: 150px;",Te.textContent="Save to Cloud \u2601",lt.addEventListener("click",gv),lt.style.cssText="border: 2px solid #5865F2; height: 25px; width: 150px;",lt.textContent="Load from Cloud \u263D");let gt=document.createElement("div");gt.style.cssText="display: flex; flex-direction: row; justify-content: space-evenly; padding: 5px; width: 45%; margin: 0 auto;",gt.appendChild(Te),gt.appendChild(lt),t.appendChild(gt)}else(L=t.querySelector("#open-register"))==null||L.addEventListener("click",()=>{var S,I,N;(S=t.querySelector("#register"))==null||S.style.setProperty("display","flex"),(I=t.querySelector("#login"))==null||I.style.setProperty("display","none"),(N=t.querySelector("#forgotpassword"))==null||N.style.setProperty("display","none"),ho()}),(E=t.querySelector("#open-signin"))==null||E.addEventListener("click",()=>{var S,I,N;(S=t.querySelector("#register"))==null||S.style.setProperty("display","none"),(I=t.querySelector("#login"))==null||I.style.setProperty("display","flex"),(N=t.querySelector("#forgotpassword"))==null||N.style.setProperty("display","none"),ho()}),(T=t.querySelector("#open-forgotpassword"))==null||T.addEventListener("click",()=>{var S,I,N;(S=t.querySelector("#register"))==null||S.style.setProperty("display","none"),(I=t.querySelector("#login"))==null||I.style.setProperty("display","none"),(N=t.querySelector("#forgotpassword"))==null||N.style.setProperty("display","flex"),ho()})}async function dv(){await fetch("https://synergism.cc/api/v1/users/logout"),await P(u.t("account.logout")),location.reload()}async function pv(){let t=localStorage.getItem("Synergysave2");if(typeof t!="string"){console.log("Yeah, no save here.");return}let r=new FormData;r.set("savefile",new File([t],"file.txt"),"file.txt");let n=await fetch("https://synergism.cc/api/v1/saves/upload",{method:"POST",body:r});if(!n.ok){await P(`Received an error: ${await n.text()}`);return}}async function gv(){var n;let r=await(await fetch("https://synergism.cc/api/v1/saves/get")).json();Ra((n=r==null?void 0:r.save)!=null?n:null)}var Cm=new WeakSet;function ho(){let r=Array.from(document.querySelectorAll(".turnstile")).find(n=>n.offsetParent!==null);r&&!Cm.has(r)&&(turnstile.render(r,{sitekey:r.getAttribute("data-sitekey"),"error-callback"(){},retry:"never"}),Cm.add(r))}var bo=(x=>(x[x.Quark=0]="Quark",x[x.GoldenQuark=1]="GoldenQuark",x[x.Cubes=2]="Cubes",x[x.PowderConversion=3]="PowderConversion",x[x.AscensionSpeed=4]="AscensionSpeed",x[x.GlobalSpeed=5]="GlobalSpeed",x[x.AscensionScore=6]="AscensionScore",x[x.AntSacrifice=7]="AntSacrifice",x[x.Offering=8]="Offering",x[x.Obtainium=9]="Obtainium",x[x.Octeract=10]="Octeract",x[x.BlueberryTime=11]="BlueberryTime",x[x.AmbrosiaLuck=12]="AmbrosiaLuck",x[x.OneMind=13]="OneMind",x))(bo||{}),ur=null,mv=()=>ur,pu=async()=>{if(!e.dayCheck)return;let t=await fetch("https://synergism.cc/api/v2/events/get");if(!t.ok)throw new Error("God fucking dammit");let r=await t.json();ur=null;let n=new Date(tl()).getTime();n>=r.start&&n<=r.end&&r.name.length&&(ur=r);let a=i("happyHolidays"),s=i("eventBuffs"),l=o.isEvent;if(ur){o.isEvent=!0;let c=[];for(let p=0;p0?c.push(`${g>=0?"+":"-"}${d(100*g,3,!0)}% ${Mm[p]}`):(el[p]!=="OneMind"||e.singularityUpgrades.oneMind.level===0)&&c.push(`${g>=0?"+":"-"}${d(100*g,2,!0)}% ${Mm[p]}`))}i("eventCurrent").textContent=u.t("settings.events.activeUntil",{x:new Date(ur.end)}),s.innerHTML=o.isEvent&&c.length?`Current Buffs: ${c.join(", ")}`:"",a.innerHTML=`(${ur.name.length}) ${ur.name.join(", ")}`,a.style.color=ur.color[Math.floor(Math.random()*ur.color.length)],a.href=ur.url.length>0?ur.url[Math.floor(Math.random()*ur.url.length)]:"#"}else o.isEvent=!1,i("eventCurrent").innerHTML=u.t("settings.events.inactive"),s.textContent="",s.style.color="var(--red-text-color)",a.innerHTML="",a.href="";o.isEvent!==l&&(Oe(),o.ambrosiaCurrStats.ambrosiaAdditiveLuckMult=zr().value,o.ambrosiaCurrStats.ambrosiaLuck=Ge().value,o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value)},el=["Quark","GoldenQuark","Cubes","PowderConversion","AscensionSpeed","GlobalSpeed","AscensionScore","AntSacrifice","Offering","Obtainium","Octeract","BlueberryTime","AmbrosiaLuck","OneMind"],Mm=["Quarks","Golden Quarks","Cubes from all type","Powder Conversion","Ascension Speed","Global Speed","Ascension Score","Ant Sacrifice rewards","Offering","Obtainium","Eight Dimensional Hypercubes","Blueberry Time Generation","Ambrosia Luck (Additive Mult)","One Mind Quark Bonus"],gu=t=>{var n,a,s,l,c,p,g,m,h,b,C,v,x;let r=mv();if(r===null)return 0;switch(t){case 0:return(n=r.quark)!=null?n:0;case 1:return(a=r.goldenQuark)!=null?a:0;case 2:return(s=r.cubes)!=null?s:0;case 3:return(l=r.powderConversion)!=null?l:0;case 4:return(c=r.ascensionSpeed)!=null?c:0;case 5:return(p=r.globalSpeed)!=null?p:0;case 6:return(g=r.ascensionScore)!=null?g:0;case 7:return(m=r.antSacrifice)!=null?m:0;case 8:return(h=r.offering)!=null?h:0;case 9:return(b=r.obtainium)!=null?b:0;case 10:return(C=r.octeract)!=null?C:0;case 13:return e.singularityUpgrades.oneMind.level>0?r.oneMind:0;case 11:return(v=r.blueberryTime)!=null?v:0;case 12:return(x=r.ambrosiaLuck)!=null?x:0}},Tm=()=>(o.eventClicked=!0,i("eventClicked").style.display="block",P(u.t("event.aprilFools.clicked")));var fv=new Map([["kMisc","miscStats"],["kFreeAccel","acceleratorStats"],["kFreeMult","multiplierStats"],["kOfferingMult","offeringMultiplierStats"],["kObtMult","obtainiumMultiplierStats"],["kGlobalCubeMult","globalCubeMultiplierStats"],["kQuarkMult","globalQuarkMultiplierStats"],["kGSpeedMult","globalSpeedMultiplierStats"],["kCubeMult","cubeMultiplierStats"],["kTessMult","tesseractMultiplierStats"],["kHypercubeMult","hypercubeMultiplierStats"],["kPlatMult","platonicMultiplierStats"],["kHeptMult","hepteractMultiplierStats"],["kOrbPowderMult","powderMultiplierStats"],["kOctMult","octeractMultiplierStats"],["kASCMult","ascensionSpeedMultiplierStats"],["kGQMult","goldenQuarkMultiplierStats"],["kAddStats","addCodeStats"],["kAmbrosiaLuck","ambrosiaLuckStats"],["kAmbrosiaGenMult","ambrosiaGenerationStats"]]),Sm=t=>{for(let r of Array.from(t.parentElement.children)){let n=i(fv.get(r.id));r.id!==t.id?(r.style.backgroundColor="",n.style.display="none",n.classList.remove("activeStats")):(r.style.backgroundColor="crimson",n.style.display="block",n.classList.add("activeStats"))}},km=()=>{let t=document.getElementsByClassName("activeStats");for(let r=0;r{i("sMisc1").textContent=d(e.prestigeCount,0,!0),i("sMisc2").textContent=`${d(1e3*e.fastestprestige)}ms`,i("sMisc3").textContent=d(e.maxofferings),i("sMisc4").textContent=d(o.runeSum),i("sMisc5").textContent=d(e.transcendCount,0,!0),i("sMisc6").textContent=`${d(1e3*e.fastesttranscend)}ms`,i("sMisc7").textContent=d(e.reincarnationCount,0,!0),i("sMisc8").textContent=`${d(1e3*e.fastestreincarnate)}ms`,i("sMisc9").textContent=d(e.maxobtainium),i("sMisc10").textContent=d(e.maxobtainiumpersecond,2,!0),i("sMisc11").textContent=d(e.obtainiumpersecond,2,!0),i("sMisc12").textContent=d(e.ascensionCount,0,!0),i("sMisc13").textContent=d(e.quarksThisSingularity,0,!0),i("sMisc14").textContent=d(e.totalQuarksEver+e.quarksThisSingularity,0,!0),i("sMisc15").textContent=`${Vt(e.quarkstimer)} / ${Vt(9e4+18e3*e.researches[195])}`,i("sMisc16").textContent=mu(0)},bv=()=>{i("sA1").textContent=`+${d(o.freeUpgradeAccelerator,0,!1)}`,i("sA2").textContent=`+${d(o.totalAcceleratorBoost*(4+2*e.researches[18]+2*e.researches[19]+3*e.researches[20]+o.cubeBonusMultiplier[1]),0,!1)}`,i("sA3").textContent=`+${d(Math.floor(Math.pow(o.rune1level*o.effectiveLevelMult/10,1.1)),0,!0)}`,i("sA4").textContent=`x${d(1+o.rune1level*1/200*o.effectiveLevelMult,3,!0)}`,i("sA5").textContent=`x${d(Math.pow(1.01,e.upgrades[21]+e.upgrades[22]+e.upgrades[23]+e.upgrades[24]+e.upgrades[25]),3,!0)}`,i("sA6").textContent=`x${d(Math.pow(1.01,e.achievements[60]+e.achievements[61]+e.achievements[62]),3,!0)}`,i("sA7").textContent=`x${d(1+1/5*e.researches[1],3,!0)}`,i("sA8").textContent=`x${d(1+1/20*e.researches[6]+1/25*e.researches[7]+1/40*e.researches[8]+3/200*e.researches[9]+1/200*e.researches[10],3,!0)}`,i("sA9").textContent=`x${d(1+1/20*e.researches[86],3,!0)}`,i("sA10").textContent=`x${d((e.currentChallenge.transcension!==0||e.currentChallenge.reincarnation!==0)&&e.upgrades[50]>.5?1.25:1,3,!0)}`,i("sA11").textContent=`^${d(Math.min(1,(1+e.platonicUpgrades[6]/30)*o.viscosityPower[e.usedCorruptions[2]]),3,!0)}`,i("sA12").textContent=d(o.freeAccelerator,0,!0)},yv=()=>{i("sM1").textContent=`+${d(o.freeUpgradeMultiplier,0,!0)}`,i("sM2").textContent=`+${d(Math.floor(Math.floor(o.rune2level/10*o.effectiveLevelMult)*Math.floor(10+o.rune2level/10*o.effectiveLevelMult)/2)*100/100,0,!0)}`,i("sM3").textContent=`x${d(1+o.rune2level/200*o.effectiveLevelMult,3,!0)}`,i("sM4").textContent=`x${d(Math.pow(1.01,e.upgrades[21]+e.upgrades[22]+e.upgrades[23]+e.upgrades[24]+e.upgrades[25])*(1+e.upgrades[34]*3/100)*(1+e.upgrades[34]*(2/103)),3,!0)}`,i("sM5").textContent=`x${d(Math.pow(1.01,e.achievements[57]+e.achievements[58]+e.achievements[59]),3,!0)}`,i("sM6").textContent=`x${d(1+1/5*e.researches[2],3,!0)}`,i("sM7").textContent=`x${d(1+1/20*e.researches[11]+1/25*e.researches[12]+1/40*e.researches[13]+3/200*e.researches[14]+1/200*e.researches[15],3,!0)}`,i("sM8").textContent=`x${d(1+1/20*e.researches[87],3,!0)}`,i("sM9").textContent=`x${d(Nt(40,(e.antUpgrades[4]+o.bonusant5)/1e3*40/39),2,!0)}`,i("sM10").textContent=`x${d(o.cubeBonusMultiplier[2],3,!0)}`,i("sM11").textContent=`x${d((e.currentChallenge.transcension!==0||e.currentChallenge.reincarnation!==0)&&e.upgrades[50]>.5?1.25:1,3,!0)}`,i("sM12").textContent=`^${d(Math.min(1,(1+e.platonicUpgrades[6]/30)*o.viscosityPower[e.usedCorruptions[2]]),3,!0)}`,i("sM13").textContent=d(o.freeMultiplier,3,!0)},vv=()=>{i("sGQM1").textContent=`x${d(1,3,!0)}`,i("sGQM2").textContent=`+${d(e.achievementPoints/25e3,3,!0)}`,i("sGQM3").textContent=`+${d(e.achievements[250]>0?.1:0,3,!0)}`,i("sGQM4").textContent=`+${d(e.achievements[251]>0?.1:0,3,!0)}`,i("sGQM5").textContent=`+${d(e.platonicUpgrades[5]>0?.2:0,3,!0)}`,i("sGQM6").textContent=`+${d(e.platonicUpgrades[10]>0?.25:0,3,!0)}`,i("sGQM7").textContent=`+${d(e.platonicUpgrades[15]>0?.3:0,3,!0)}`,i("sGQM8").textContent=`+${d(o.challenge15Rewards.quarks-1,3,!0)}`,i("sGQM9").textContent=`x${d(e.worlds.applyBonus(1/yi()),3,!0)}`,i("sGQM10").textContent=`x${d(o.isEvent?1+Ye(0)+Ye(13):1,3,!0)}`,i("sGQM11").textContent=`x${d($n()>0?1.1+.15/75*$n():1,3,!0)}`,i("sGQM12").textContent=`x${d(e.challenge15Exponent>=1e15?1+5/1e4*Ve("quark"):1,3,!0)}`,i("sGQM13").textContent=`x${d(ss(),3,!0)}`,i("sGQM14").textContent=`x${d(1+e.achievements[266]*Math.min(.1,e.ascensionCount/1e16),3,!0)}`,i("sGQM15").textContent=`x${d(1+e.singularityCount/10,3,!0)}`,i("sGQM16").textContent=`x${d(bu(),3,!0)}`,i("sGQM17").textContent=`x${d(1+.1*e.cubeUpgrades[53]/100,3,!0)}`,i("sGQM18").textContent=`x${d(1+1/1e4*e.cubeUpgrades[68]+.05*Math.floor(e.cubeUpgrades[68]/1e3),3,!0)}`,i("sGQM19").textContent=`x${d(1+.02*e.singularityUpgrades.intermediatePack.level+.04*e.singularityUpgrades.advancedPack.level+.06*e.singularityUpgrades.expertPack.level+.08*e.singularityUpgrades.masterPack.level+.1*e.singularityUpgrades.divinePack.level,3,!0)}`,i("sGQM20").textContent=`x${d(1+.4*+e.octeractUpgrades.octeractStarter.getEffect().bonus,3,!0)}`,i("sGQM21").textContent=`x${d(+e.octeractUpgrades.octeractQuarkGain.getEffect().bonus,3,!0)}`,i("sGQM22").textContent=`x${d(fn(),3,!0)}`,i("sGQM23").textContent=`x${d(1+ +e.singularityUpgrades.singQuarkImprover1.getEffect().bonus,3,!0)}`,i("sGQM24").textContent=`x${d(1+1/1e4*Math.floor(e.octeractUpgrades.octeractQuarkGain.level/199)*e.octeractUpgrades.octeractQuarkGain2.level*Math.floor(1+Math.log10(Math.max(1,e.hepteractCrafts.quark.BAL))),3,!0)}`,i("sGQM25").textContent=`x${d(Co(),2,!0)}`,i("sGQM26").textContent=`x${d(+e.blueberryUpgrades.ambrosiaTutorial.bonus.quarks,2,!0)}`,i("sGQM27").textContent=`x${d(+e.blueberryUpgrades.ambrosiaQuarks1.bonus.quarks,2,!0)}`,i("sGQM28").textContent=`x${d(+e.blueberryUpgrades.ambrosiaCubeQuark1.bonus.quarks,2,!0)}`,i("sGQM29").textContent=`x${d(+e.blueberryUpgrades.ambrosiaLuckQuark1.bonus.quarks,2,!0)}`,i("sGQM30").textContent=`x${d(+e.blueberryUpgrades.ambrosiaQuarks2.bonus.quarks,2,!0)}`,i("sGQM31").textContent=`x${d(go(),3,!0)}`,i("sGQM32").textContent=`x${d(1+ +e.singularityChallenges.limitedTime.rewards.quarkMult,2,!0)}`,i("sGQM33").textContent=`x${d(1+ +e.singularityChallenges.sadisticPrequel.rewards.quarkMult,2,!0)}`,i("sGQM34").textContent=`x${d(e.highestSingularityCount===0?1.25:1,2,!0)}`,i("sGQMT").textContent=`x${d(e.worlds.applyBonus(1),3,!0)}`},Cv=()=>{let t=qe(),r=t.preList;for(let s=0;s{var B,U;let t=Qn().list,r={1:{acc:2,desc:"PseudoCoin Upgrade:",color:"gold"},2:{acc:2,desc:"Ascension Time Multiplier:"},3:{acc:2,desc:"Sun and Moon Achievements:"},4:{acc:2,desc:"Speed Achievement:"},5:{acc:2,desc:"Challenge 15 All Cube Bonus:"},6:{acc:2,desc:"Rune 6 - Infinite Ascent:"},7:{acc:2,desc:"Platonic Beta:"},8:{acc:2,desc:"Platonic Omega:"},9:{acc:2,desc:"Overflux Powder:"},10:{acc:2,desc:"Event:"},11:{acc:2,desc:"Singularity Factor:"},12:{acc:2,desc:"Wow Pass Y"},13:{acc:2,desc:"Starter Pack:"},14:{acc:2,desc:"Cube Flame [GQ]:"},15:{acc:2,desc:"Cube Blaze [GQ]:"},16:{acc:2,desc:"Cube Inferno [GQ]:"},17:{acc:2,desc:"Wow Pass Z:"},18:{acc:2,desc:"Cookie Upgrade 16:"},19:{acc:2,desc:"Cookie Upgrade 8:"},20:{acc:2,desc:"Total Octeract Bonus:"},21:{acc:2,desc:"No Singularity Upgrades Challenge:"},22:{acc:2,desc:"Citadel [GQ]"},23:{acc:2,desc:"Citadel 2 [GQ]"},24:{acc:4,desc:"Platonic DELTA"},25:{acc:2,desc:"Wow Pass \u221E"},26:{acc:2,desc:"Unspent Ambrosia Bonus"},27:{acc:2,desc:"Module- Tutorial"},28:{acc:2,desc:"Module- Cubes 1"},29:{acc:2,desc:"Module- Luck-Cube 1"},30:{acc:2,desc:"Module- Quark-Cube 1"},31:{acc:2,desc:"Module- Cubes 2"},32:{acc:2,desc:"Module- Hyperflux"},33:{acc:2,desc:"20 Ascensions X20 Bonus [EXALT ONLY]"},34:{acc:2,desc:"Cash Grab ULTIMATE"},35:{acc:2,desc:"Shop EX ULTIMATE"},36:{acc:2,desc:"Exalt 6 Penalty (for being too slow!)"}};for(let k=0;k{let t=Qr("prestige",!1),r={1:{acc:3,desc:"Alchemy Achievement 5:"},2:{acc:3,desc:"Alchemy Achievement 6:"},3:{acc:3,desc:"Alchemy Achievement 7:"},4:{acc:3,desc:"Diamond Upgrade 4x3:"},5:{acc:3,desc:"Particle Upgrade 3x5:"},6:{acc:3,desc:"Auto Offering Shop Upgrade:"},7:{acc:3,desc:"Offering EX Shop Upgrade:"},8:{acc:3,desc:"Cash Grab Shop Upgrade:"},9:{acc:3,desc:"Research 4x10:"},10:{acc:3,desc:"Sacrificium Formicidae:"},11:{acc:3,desc:"Plutus Cube Tribute:"},12:{acc:3,desc:"Constant Upgrade 3:"},13:{acc:3,desc:"Research 6x24,8x4:"},14:{acc:3,desc:"Challenge 12:"},15:{acc:3,desc:"Research 8x25:"},16:{acc:3,desc:"Ascension Count Achievement:"},17:{acc:3,desc:"Sun and Moon Achievements:"},18:{acc:3,desc:"Cube Upgrade 5x6:"},19:{acc:3,desc:"Cube Upgrade 5x10:"},20:{acc:3,desc:"Platonic ALPHA:"},21:{acc:3,desc:"Platonic BETA:"},22:{acc:3,desc:"Platonic OMEGA:"},23:{acc:3,desc:"Challenge 15:"},24:{acc:3,desc:"Starter Pack:"},25:{acc:3,desc:"Offering Charge [GQ]:"},26:{acc:3,desc:"Offering Storm [GQ]:"},27:{acc:3,desc:"Offering Tempest [GQ]:"},28:{acc:3,desc:"Citadel [GQ]"},29:{acc:3,desc:"Citadel 2 [GQ]"},30:{acc:3,desc:"Cube Upgrade Cx4:"},31:{acc:3,desc:"Offering Electrolosis [OC]:"},32:{acc:3,desc:"RNG-based Offering Booster:"},33:{acc:3,desc:"Cube Upgrade Cx21:"},34:{acc:3,desc:"20 Ascensions X20 [EXALT ONLY]"},35:{acc:3,desc:"Shop EX ULTIMATE"},36:{acc:3,desc:"Event:"}};for(let n=0;n{i("sObt1").textContent=`x${d(e.upgrades[69]>0?Math.min(10,new f(f.pow(f.log(o.reincarnationPointGain.add(10),10),.5)).toNumber()):1,2)}`,i("sObt2").textContent=`x${d(e.upgrades[72]>0?Math.min(50,1+2*e.challengecompletions[6]+2*e.challengecompletions[7]+2*e.challengecompletions[8]+2*e.challengecompletions[9]+2*e.challengecompletions[10]):1,2)}`,i("sObt3").textContent=`x${d(e.upgrades[74]>0?1+4*Math.min(1,Math.pow(e.maxofferings/1e5,.5)):1,2)}`,i("sObt4").textContent=`x${d(1+e.researches[65]/5,2)}`,i("sObt5").textContent=`x${d(1+e.researches[76]/10,2)}`,i("sObt6").textContent=`x${d(1+e.researches[81]/10,2)}`,i("sObt7").textContent=`x${d(1+e.shopUpgrades.obtainiumAuto/50,3)}`,i("sObt8").textContent=`x${d(1+e.shopUpgrades.cashGrab/100,3)}`,i("sObt9").textContent=`x${d(1+e.shopUpgrades.obtainiumEX/50,3)}`,i("sObt10").textContent=`x${d(1+o.rune5level/200*o.effectiveLevelMult*(1+e.researches[84]/200*(1+1*o.effectiveRuneSpiritPower[5]*Xe()/400)),3)}`,i("sObt11").textContent=`x${d(1+.01*e.achievements[84]+.03*e.achievements[91]+.05*e.achievements[98]+.07*e.achievements[105]+.09*e.achievements[112]+.11*e.achievements[119]+.13*e.achievements[126]+.15*e.achievements[133]+.17*e.achievements[140]+.19*e.achievements[147],2)}`,i("sObt12").textContent=`x${d(1+2*Math.pow((e.antUpgrades[10-1]+o.bonusant10)/50,2/3),3)}`,i("sObt13").textContent=`x${d(1+e.achievements[188]*Math.min(2,e.ascensionCount/5e6),3)}`,i("sObt14").textContent=`x${d(1+.6*e.achievements[250]+1*e.achievements[251],2)}`,i("sObt15").textContent=`x${d(o.cubeBonusMultiplier[5],3)}`,i("sObt16").textContent=`x${d(1+.04*e.constantUpgrades[4],2)}`,i("sObt17").textContent=`x${d(1+.1*e.cubeUpgrades[3],2)}`,i("sObt18").textContent=`x${d(1+.1*e.cubeUpgrades[47],3)}`,i("sObt19").textContent=`x${d(1+.5*_("ascension",e.challengecompletions[12]),2)}`,i("sObt20").textContent=`x${d(1+Xe()/400*o.effectiveRuneSpiritPower[4],4)}`,i("sObt21").textContent=`x${d(1+.03*Math.log(e.uncommonFragments+1)/Math.log(4)*e.researches[144],3)}`,i("sObt22").textContent=`x${d(1+.02/100*e.cubeUpgrades[50],4)}`,i("sObt23").textContent=`x${d(e.achievements[53]>0?1+1/800*o.runeSum:1,3)}`,i("sObt24").textContent=`x${d((e.achievements[128]?1.5:1)*(e.achievements[129]?1.25:1),3)}`,i("sObt25").textContent=`+${d(e.achievements[51]>0?4:1,3)}`,i("sObt26").textContent=`+${d((e.reincarnationcounter>=2?1*e.researches[63]:1)+(e.reincarnationcounter>=5?2*e.researches[64]:1),2)}`,i("sObt27").textContent=`x${d((e.reincarnationcounter>=5?Math.max(1,e.reincarnationcounter/10):1)*Math.min(1,Math.pow(e.reincarnationcounter/10,2)),3)}`,i("sObt28").textContent=`x${d(Math.pow(f.log(e.transcendShards.add(1),10)/300,2),2)}`,i("sObt29").textContent=`^${d(Math.min(1,o.illiteracyPower[e.usedCorruptions[5]]*(1+9/100*e.platonicUpgrades[9]*Math.min(100,Math.log10(e.researchPoints+10)))),3)}`,i("sObt30").textContent=`x${d(1+4/100*e.cubeUpgrades[42]+1+3/100*e.cubeUpgrades[43],2)}`,i("sObt31").textContent=`x${d(1+e.platonicUpgrades[5],2)}`,i("sObt32").textContent=`x${d(1+1.5*e.platonicUpgrades[9],2)}`,i("sObt33").textContent=`x${d(1+2.5*e.platonicUpgrades[10],2)}`,i("sObt34").textContent=`x${d(1+5*e.platonicUpgrades[15],2)}`,i("sObt35").textContent=`x${d(o.challenge15Rewards.obtainium,3)}`,i("sObt36").textContent=`x${d(1+5*(e.singularityUpgrades.starterPack.getEffect().bonus?1:0),2)}`,i("sObt37").textContent=`x${d(+e.singularityUpgrades.singObtainium1.getEffect().bonus,2)}`,i("sObt38").textContent=`x${d(+e.singularityUpgrades.singObtainium2.getEffect().bonus,2)}`,i("sObt39").textContent=`x${d(+e.singularityUpgrades.singObtainium3.getEffect().bonus,2)}`,i("sObt40").textContent=`x${d(1+e.cubeUpgrades[55]/100,2)}`,i("sObt41").textContent=`x${d(1+1/200*e.shopUpgrades.cashGrab2,3)}`,i("sObt42").textContent=`x${d(1+1/100*e.shopUpgrades.obtainiumEX2*e.singularityCount,2)}`,i("sObt43").textContent=`x${d(1+Ye(9),2)}`,i("sObt44").textContent=`x${d(+e.singularityUpgrades.singCitadel.getEffect().bonus,2)}`,i("sObt45").textContent=`x${d(+e.singularityUpgrades.singCitadel2.getEffect().bonus,2)}`,i("sObt46").textContent=`x${d(+e.octeractUpgrades.octeractObtainium1.getEffect().bonus,2)}`,i("sObt47").textContent=`x${d(Math.pow(1.02,e.shopUpgrades.obtainiumEX3),2)}`,i("sObt48").textContent=`x${d(vo(),2)}`,i("sObt49").textContent=`x${d(e.currentChallenge.ascension===15?1+7*e.cubeUpgrades[62]:1,2)}`,i("sObt50").textContent=`x${d(1+.001*+e.blueberryUpgrades.ambrosiaObtainium1.bonus.obtainiumMult,2)}`,i("sObt51").textContent=`x${d(vu(),2)}`,i("sObt52").textContent=`x${d(wo(),2)}`,i("sObt53").textContent=`x${d(Math.pow(1.04,e.cubeUpgrades[71]*ae(e.talismanRarity)),2)}`,i("sObt54").textContent=`/${d(Le("Obtainium"),2)}`,i("sObt55").textContent=`^${d(e.usedCorruptions[5]>=15?1/4:1,2)}`,i("sObt56").textContent=`^${d(e.usedCorruptions[5]>=16?1/4:1,2)}`,i("sObt57").textContent=`x${d(e.currentChallenge.ascension===14?0:1,2)}`,i("sObtT").textContent=`x${d(o.obtainiumGain,3)}`},Tv=()=>{let t=Lr().list,r={1:{acc:2,desc:"Base:"},2:{acc:2,desc:"Challenge 15 Bonus:"},3:{acc:2,desc:"Powder EX:"},4:{acc:2,desc:"Achievement 256:"},5:{acc:2,desc:"Achievement 257:"},6:{acc:2,desc:"Platonic Upgrade 16 [4x1]:"},7:{acc:2,desc:"Event:"}};for(let n=0;n{let t=hu(),r={1:{acc:2,desc:"Chronometer:"},2:{acc:2,desc:"Chronometer 2:"},3:{acc:2,desc:"Chronometer 3:"},4:{acc:2,desc:"Chronos Hepteract:"},5:{acc:2,desc:"Achievement 262 Bonus:"},6:{acc:2,desc:"Achievement 263 Bonus:"},7:{acc:2,desc:"Platonic Omega:"},8:{acc:2,desc:"Challenge 15 Reward:"},9:{acc:2,desc:"Cookie Upgrade 9:"},10:{acc:2,desc:"Intermediate Pack:"},11:{acc:2,desc:"Chronometer Z:"},12:{acc:2,desc:"Abstract Photokinetics:"},13:{acc:2,desc:"Abstract Exokinetics:"},14:{acc:2,desc:"Event:"},15:{acc:2,desc:"Ascension Speedup 2 [GQ]:"},16:{acc:2,desc:"Chronometer INF:"},17:{acc:2,desc:"Limited Ascensions Penalty:"},18:{acc:2,desc:"Limited Ascensions Reward:"},19:{acc:2,desc:"Ascension Speedup [GQ]:"},20:{acc:2,desc:"Singularity Penalty:"},21:{acc:2,desc:"EXALT 6: The Great Singularity Speedrun:"},22:{acc:2,desc:"Shop Chronometer S:"}};for(let n=0;n{var n;let t=yu(),r={1:{acc:2,desc:"PseudoCoin Bonus:",color:"gold"},2:{acc:2,desc:"Challenge 15 Exponent:"},3:{acc:2,desc:"Patreon Bonus:"},4:{acc:2,desc:"Golden Quarks I:"},5:{acc:2,desc:"Cookie Upgrade 19:"},6:{acc:2,desc:"No Singularity Upgrades:"},7:{acc:2,desc:"Event:"},8:{acc:2,desc:"Singularity Fast Forwards:"},9:{acc:2,desc:"Golden Revolution II:"},10:{acc:2,desc:"Immaculate Alchemy:"},11:{acc:2,desc:"Total Quarks Coefficient:"}};for(let a=0;a{var g;let t=Ia(),r=yo(),n=qn(),a=ll(),s={1:{acc:0,desc:"Base:"},2:{acc:2,desc:"PL-AT \u03B4 calculator:"},3:{acc:2,desc:"PL-AT \u03A3 sing perk:"},4:{acc:2,desc:"Ascension of Ant God:"},5:{acc:2,desc:"Singularity factor:"}};t.list[0]/=1e3;for(let m=0;m=.5?i("s+eff1").textContent=`+${d(p*c.minQuarks,3)} ~ ${d(p*c.maxQuarks,3)}`:i("s+eff1").textContent=`+${d(p*c.quarks,3)}`,i("stat+eff2").childNodes[0].textContent="PL-AT X - bonus ascension time: ",i("s+eff2").textContent=`+${d(c.ascensionTimer,2)} sec`,i("stat+eff3").childNodes[0].textContent="PL-AT \u0393 - bonus GQ export time: ",i("s+eff3").textContent=`+${d(c.gqTimer,2)} sec`,i("stat+eff4").childNodes[0].textContent="PL-AT _ - bonus octeract time: ",i("s+eff4").textContent=`+${d(c.octeractTime,2)} sec`},Pv=()=>{var s;let t=Ge(),r=t.array,n={1:{acc:0,desc:"Base Value"},2:{acc:0,desc:"PseudoCoin Upgrade",color:"gold"},3:{acc:0,desc:"Irish Ants Singularity Perk"},4:{acc:1,desc:"Shop Upgrade Bonus"},5:{acc:0,desc:"Singularity Ambrosia Luck Upgrades"},6:{acc:0,desc:"Octeract Ambrosia Luck Upgrades"},7:{acc:0,desc:"Ambrosia Luck Module I"},8:{acc:1,desc:"Ambrosia Luck Module II"},9:{acc:2,desc:"Ambrosia Cube-Luck Hybrid Module I"},10:{acc:2,desc:"Ambrosia Quark-Luck Hybrid Module I"},11:{acc:0,desc:"Primal Power: One Hundred Thirty One!"},12:{acc:0,desc:"Primal Power: Two Hundred Sixty Nine!"},13:{acc:0,desc:"Shop: Octeract-Based Ambrosia Luck"},14:{acc:0,desc:"No Ambrosia Upgrades EXALT"},15:{acc:0,desc:"Cube Upgrade Cx27"},16:{acc:0,desc:"Red Bar Fills with Cx29"},17:{acc:0,desc:"ULTRA Upgrade: Ambrosia Exalter"}};for(let l=0;l{var s;let t=De(),r=t.array,n={1:{acc:4,desc:"Visited Ambrosia Subtab"},2:{acc:4,desc:"PseudoCoin Upgrade",color:"gold"},3:{acc:4,desc:"Number of Blueberries"},4:{acc:4,desc:"Shop Upgrade Bonus"},5:{acc:4,desc:"Singularity Ambrosia Generation Upgrades"},6:{acc:4,desc:"Octeract Ambrosia Generation Upgrades"},7:{acc:4,desc:"Patreon Bonus"},8:{acc:4,desc:"One Ascension Challenge EXALT"},9:{acc:4,desc:"No Ambrosia Upgrades EXALT"},10:{acc:4,desc:"Cube Upgrade Cx26"},11:{acc:4,desc:"Cash-Grab ULTIMATE"},12:{acc:4,desc:"Event Bonus"}};for(let l=0;l{let t=[750,1500,3e3,5e3,7500,7500,1e4,1e4,2e4,4e4,6e4,1e5,1e5,2e5,5e5,1e6,3e6,1e7,3e7,1e8,5e8,2e9,1e10,1e11,1e15,2e15,4e15,7e15,1e16,2e16,333e14,333e14,333e14,2e17,15e17],r=Object.keys(o.challenge15Rewards),n=e.challenge15Exponent;for(let a in o.challenge15Rewards)o.challenge15Rewards[a]=1;o.challenge15Rewards.freeOrbs=0,n>=t[0]&&(o.challenge15Rewards[r[0]]=1+1/50*Math.log(n/175)/Math.log(2)),n>=t[1]&&(o.challenge15Rewards[r[1]]=1+1/20*Math.log(n/375)/Math.log(2)),n>=t[2]&&(o.challenge15Rewards[r[2]]=1+1/150*Math.log(n/750)/Math.log(2)),n>=t[3]&&(o.challenge15Rewards[r[3]]=Math.pow(.98,Math.log(n/1250)/Math.log(2))),n>=t[4]&&(o.challenge15Rewards[r[4]]=1+1/5*Math.pow(n/7500,.75)),n>=t[5]&&(o.challenge15Rewards[r[5]]=1+1/5*Math.pow(n/7500,.75)),n>=t[6]&&(o.challenge15Rewards[r[6]]=1+1/20*Math.log(n/2500)/Math.log(2)),n>=t[7]&&(o.challenge15Rewards[r[7]]=1+1/20*Math.log(n/2500)/Math.log(2)),n>=t[8]&&(o.challenge15Rewards[r[8]]=1+Math.pow(n/2e4,1.5)),n>=t[9]&&(o.challenge15Rewards[r[9]]=1+1/33*Math.log(n/1e4)/Math.log(2)),n>=t[10]&&(o.challenge15Rewards[r[10]]=1+1/100*Math.log(n/15e3)/Math.log(2)),n>=t[11]&&(o.challenge15Rewards[r[11]]=Math.pow(.98,Math.log(n/25e3)/Math.log(2))),n>=t[12]&&(o.challenge15Rewards[r[12]]=Math.pow(.98,Math.log(n/25e3)/Math.log(2))),n>=t[13]&&(o.challenge15Rewards[r[13]]=Math.pow(1+Math.log(n/2e5)/Math.log(2),4)),n>=t[14]&&(o.challenge15Rewards[r[14]]=1+1/20*Math.log(n/15e4)/Math.log(2)),n>=t[15]&&(o.challenge15Rewards[r[15]]=1+1/150*Math.log(n/25e4)/Math.log(2)),n>=t[16]&&(o.challenge15Rewards[r[16]]=1+1/20*Math.log(n/75e4)/Math.log(2)),n>=t[17]&&(o.challenge15Rewards[r[17]]=1+1/20*Math.log(n/25e5)/Math.log(2)),n>=t[18]&&(o.challenge15Rewards[r[18]]=1+1/5*Math.pow(n/3e7,1/4)),n>=t[19]&&(o.challenge15Rewards[r[19]]=1+1/5*Math.pow(n/1e8,2/3)),n>=t[20]&&(o.challenge15Rewards[r[20]]=1+1/200*Math.log(n/125e6)/Math.log(2)),n>=t[21]&&(o.challenge15Rewards[r[21]]=1+1/5*Math.pow(n/2e9,1/4)),n>=t[22]&&(o.challenge15Rewards[r[22]]=1+1/4*Math.pow(n/1e10,1/4),n>=1e20&&(o.challenge15Rewards[r[22]]=1+1/4*Math.pow(n/1e10,1/8)*Math.pow(1e10,1/8))),n>=t[23]&&(o.challenge15Rewards[r[23]]=1+1/100*Math.log(n*32/1e11)/Math.log(2)),n>=t[24]&&(o.challenge15Rewards[r[24]]=2),n>=t[25]&&e.hepteractCrafts.challenge.unlock("the Hepteract of Challenge"),n>=t[26]&&(o.challenge15Rewards[r[25]]=1+1/300*Math.log2(n/(4e15/1024))),n>=t[27]&&(o.challenge15Rewards[r[26]]=1+1/50*Math.log2(n/(7e15/32))),n>=t[28]&&e.hepteractCrafts.abyss.unlock("the Hepteract of the Abyss"),n>=t[29]&&(o.challenge15Rewards[r[27]]=ut(1.05,n,1e18)),n>=t[30]&&e.hepteractCrafts.accelerator.unlock("the Hepteract of Way Too Many Accelerators"),n>=t[31]&&e.hepteractCrafts.acceleratorBoost.unlock("the Hepteract of Way Too Many Accelerator Boosts"),n>=t[32]&&e.hepteractCrafts.multiplier.unlock("the Hepteract of Way Too Many Multipliers"),n>=t[33]&&(o.challenge15Rewards.freeOrbs=Math.floor(200*Math.pow(n/2e17,.5))),n>=t[34]&&(o.challenge15Rewards.ascensionSpeed=1+5/100+2*Math.log2(n/15e17)/100),Ev()},Ev=()=>{i("c15Reward0Num").textContent=d(e.challenge15Exponent,3,!0),i("c15RequiredExponentNum").textContent=d(f.pow(10,e.challenge15Exponent/xo()),0,!0);let t=[750,1500,3e3,5e3,7500,7500,1e4,1e4,2e4,4e4,6e4,1e5,1e5,2e5,5e5,1e6,3e6,1e7,3e7,1e8,5e8,2e9,1e10,1e11,1e15,2e15,4e15,7e15,1e16,2e16,333e14,333e14,333e14,2e17,15e17],r={0:!0,1:!0,2:!0,3:!0,4:!0,5:!0,6:!0,7:!0,8:!0,9:!0,10:!0,11:!0,12:!0,13:!0,14:!0,15:!0,16:!0,17:!0,18:!0,19:!0,20:!0,21:!0,22:!0,23:!0,24:!1,25:!1,26:!0,27:!0,28:!1,29:!0,30:!1,31:!1,32:!1,33:!0,34:!0},n=Object.values(o.challenge15Rewards),a="None",s=0;for(let l=0;l=t[l]&&(i(`c15Reward${l+1}Num`).textContent=r[l]?d(100*n[l-s]-100,2,!0):u.t("wowCubes.unlocked"),!r[l]&&l!==24&&(s+=1),l===33&&(i("c15Reward34Num").textContent=d(n[l-s],0,!0))),i(`c15Reward${l+1}`).style.display=e.challenge15Exponent>=t[l]?"block":"none",i("c15RewardList").textContent=typeof a=="string"?"You have unlocked all reward types from Challenge 15!":`Next reward type requires ${d(a,0,!0)} exponent.`},Ov=()=>[{stage:0,tier:1,name:"start",unlocked:!0,reset:!0},{stage:1,tier:1,name:"start-prestige",unlocked:e.unlocks.prestige,reset:e.unlocks.prestige},{stage:2,tier:2,name:"prestige-transcend",unlocked:e.unlocks.transcend,reset:e.unlocks.transcend},{stage:3,tier:3,name:"transcend-reincarnate",unlocked:e.unlocks.reincarnate,reset:e.unlocks.reincarnate},{stage:4,tier:4,name:"reincarnate-ant",unlocked:e.firstOwnedAnts!==0,reset:e.unlocks.reincarnate},{stage:5,tier:4,name:"ant-sacrifice",unlocked:e.achievements[173]===1,reset:e.unlocks.reincarnate},{stage:6,tier:4,name:"sacrifice-ascension",unlocked:e.achievements[183]===1,reset:e.unlocks.reincarnate},{stage:7,tier:5,name:"ascension-challenge10",unlocked:e.ascensionCount>1,reset:e.achievements[183]===1},{stage:8,tier:5,name:"challenge10-challenge11",unlocked:e.achievements[197]===1,reset:e.achievements[183]===1},{stage:9,tier:5,name:"challenge11-challenge12",unlocked:e.achievements[204]===1,reset:e.achievements[183]===1},{stage:10,tier:5,name:"challenge12-challenge13",unlocked:e.achievements[211]===1,reset:e.achievements[183]===1},{stage:11,tier:5,name:"challenge13-challenge14",unlocked:e.achievements[218]===1,reset:e.achievements[183]===1},{stage:12,tier:5,name:"challenge14-w5x10max",unlocked:e.cubeUpgrades[50]>=1e5,reset:e.achievements[183]===1},{stage:13,tier:5,name:"w5x10max-alpha",unlocked:e.platonicUpgrades[5]>0,reset:e.achievements[183]===1},{stage:14,tier:5,name:"alpha-p2x1x10",unlocked:e.platonicUpgrades[6]>=10,reset:e.achievements[183]===1},{stage:15,tier:5,name:"p2x1x10-p3x1",unlocked:e.platonicUpgrades[11]>0,reset:e.achievements[183]===1},{stage:16,tier:5,name:"p3x1-beta",unlocked:e.platonicUpgrades[10]>0,reset:e.achievements[183]===1},{stage:17,tier:5,name:"beta-1e15-expo",unlocked:e.challenge15Exponent>=1e15,reset:e.achievements[183]===1},{stage:18,tier:5,name:"1e15-expo-omega",unlocked:e.platonicUpgrades[15]>0,reset:e.achievements[183]===1},{stage:19,tier:5,name:"omega-singularity",unlocked:e.singularityCount>0&&e.runelevels[6]>0,reset:e.achievements[183]===1},{stage:20,tier:6,name:"singularity-exalt1x1",unlocked:e.singularityChallenges.noSingularityUpgrades.completions>0,reset:e.highestSingularityCount>0},{stage:21,tier:6,name:"exalt1x1-onemind",unlocked:e.singularityUpgrades.oneMind.level>0,reset:e.highestSingularityCount>0},{stage:22,tier:6,name:"onemind-end",unlocked:e.singularityUpgrades.offeringAutomatic.level>0,reset:e.highestSingularityCount>0},{stage:23,tier:6,name:"end-pen",unlocked:e.singularityUpgrades.ultimatePen.level>0,reset:e.highestSingularityCount>0},{stage:24,tier:6,name:"pen",unlocked:!1,reset:e.highestSingularityCount>0}],mu=(t=e.singularityCount>0?5:0)=>{let r=Ov();for(let a=0;a{if(o.currentTab===0){if(o.buildingSubTab==="coin"){let t=["produceFirst","produceSecond","produceThird","produceFourth","produceFifth"],r=[null,"workers","investments","printers","coinMints","alchemies"],n=new f(o.produceTotal);n.equals(0)&&(n=new f(1));for(let s=1;s<=5;s++){let l=o[t[s-1]],c=o.ordinals[s-1];i(`buildtext${2*s-1}`).textContent=u.t(`buildings.names.${r[s]}`,{amount:d(e[`${c}OwnedCoin`],0,!0),gain:d(e[`${c}GeneratedCoin`])}),i(`buycoin${s}`).textContent=u.t("buildings.costCoins",{coins:d(e[`${c}CostCoin`])});let p=f.fromMantissaExponent(l.mantissa/n.mantissa,l.exponent-n.exponent).times(100);i(`buildtext${2*s}`).textContent=u.t("buildings.coinsPerSecond",{coins:d(l.dividedBy(o.taxdivisor).times(40),2),percent:d(p,3)})}i("buildtext11").textContent=u.t("buildings.names.accelerators",{amount:d(e.acceleratorBought,0,!0),gain:d(o.freeAccelerator,0,!0)}),i("buildtext12").textContent=u.t("buildings.acceleratorPower",{power:d((o.acceleratorPower-1)*100,2),mult:d(o.acceleratorEffect,2)}),i("buildtext13").textContent=u.t("buildings.names.multipliers",{amount:d(e.multiplierBought,0,!0),gain:d(o.freeMultiplier,0,!0)}),i("buildtext14").textContent=u.t("buildings.multiplierPower",{power:d(o.multiplierPower,2),mult:d(o.multiplierEffect,2)}),i("buildtext15").textContent=u.t("buildings.names.acceleratorBoost",{amount:d(e.acceleratorBoostBought,0,!0),gain:d(o.freeAcceleratorBoost,0,!1)}),i("buildtext16").textContent=u.t("buildings.acceleratorBoost",{amount:d(o.tuSevenMulti*(1+e.researches[16]/50)*(1+_("transcend",e.challengecompletions[2])/100),2)}),i("buyaccelerator").textContent=u.t("buildings.costCoins",{coins:d(e.acceleratorCost)}),i("buymultiplier").textContent=u.t("buildings.costCoins",{coins:d(e.multiplierCost)}),i("buyacceleratorboost").textContent=u.t("buildings.costDiamonds",{diamonds:d(e.acceleratorBoostCost)});let a="";e.reincarnationCount>.5&&(a=u.t("buildings.taxWarning",{gain:d(f.pow(10,o.maxexponent-f.log(o.taxdivisorcheck,10)))})),i("taxinfo").textContent=u.t("buildings.excessiveWealth",{div:d(o.taxdivisor,2),warning:a})}else if(o.buildingSubTab==="diamond"){let t=["produceFirstDiamonds","produceSecondDiamonds","produceThirdDiamonds","produceFourthDiamonds","produceFifthDiamonds"],r=["refineries","coalPlants","coalRigs","pickaxes","pandorasBoxes"],n=["crystal","ref","plants","rigs","pickaxes"];i("prestigeshardinfo").textContent=u.t("buildings.crystalMult",{crystals:d(e.prestigeShards,2),gain:d(o.prestigeMultiplier,2)});for(let a=1;a<=5;a++){let s=o[t[a-1]],l=o.ordinals[a-1];i(`prestigetext${2*a-1}`).textContent=u.t(`buildings.names.${r[a-1]}`,{amount:d(e[`${l}OwnedDiamonds`],0,!0),gain:d(e[`${l}GeneratedDiamonds`],2)}),i(`prestigetext${2*a}`).textContent=u.t(`buildings.per.${n[a-1]}`,{amount:d(s.times(40),2)}),i(`buydiamond${a}`).textContent=u.t("buildings.costDiamonds",{diamonds:d(e[`${l}CostDiamonds`],2)})}if(e.resettoggle1===1||e.resettoggle1===0){let a=f.pow(10,f.log(o.prestigePointGain.add(1),10)-f.log(e.prestigePoints.sub(1),10));i("autoprestige").textContent=u.t("buildings.autoPrestige",{name:"Diamonds",action:"Prestige",factor:d(f.pow(10,e.prestigeamount)),mult:d(a)})}else e.resettoggle1===2&&(i("autoprestige").textContent=u.t("buildings.autoReincarnate",{name:"Prestige",amount:e.prestigeamount,timer:d(o.autoResetTimers.prestige,1)}))}else if(o.buildingSubTab==="mythos"){let t=["produceFirstMythos","produceSecondMythos","produceThirdMythos","produceFourthMythos","produceFifthMythos"],r=["augments","enchantments","wizards","oracles","grandmasters"],n=["shards","augments","enchantments","wizards","oracles"];i("transcendshardinfo").textContent=u.t("buildings.mythosYouHave",{shards:d(e.transcendShards,2),mult:d(o.totalMultiplierBoost,0,!0)});for(let a=1;a<=5;a++){let s=o[t[a-1]],l=o.ordinals[a-1];i(`transcendtext${2*a-1}`).textContent=u.t(`buildings.names.${r[a-1]}`,{amount:d(e[`${l}OwnedMythos`],0,!0),gain:d(e[`${l}GeneratedMythos`],2)}),i(`transcendtext${2*a}`).textContent=u.t(`buildings.per.${n[a-1]}`,{amount:d(s.times(40),2)}),i(`buymythos${a}`).textContent=u.t("buildings.costMythos",{mythos:d(e[`${l}CostMythos`],2)})}(e.resettoggle2===1||e.resettoggle2===0)&&(i("autotranscend").textContent=u.t("buildings.autoPrestige",{name:"Mythos",action:"Prestige",factor:d(f.pow(10,e.transcendamount)),mult:d(f.pow(10,f.log(o.transcendPointGain.add(1),10)-f.log(e.transcendPoints.add(1),10)),2)})),e.resettoggle2===2&&(i("autotranscend").textContent=`Transcend when the autotimer is at least ${e.transcendamount} real-life seconds. [Toggle number above]. Current timer: ${d(o.autoResetTimers.transcension,1)}s.`)}else if(o.buildingSubTab==="particle"){let t=["FirstParticles","SecondParticles","ThirdParticles","FourthParticles","FifthParticles"],r=["protons","elements","pulsars","quasars","galacticNuclei"],n=["atoms","protons","elements","pulsars","quasars"];for(let a=1;a<=5;a++){let s=o.ordinals[a-1],l=o[`produce${t[a-1]}`];i(`reincarnationtext${a}`).textContent=u.t(`buildings.names.${r[a-1]}`,{amount:d(e[`${s}OwnedParticles`],0,!0),gain:d(e[`${s}GeneratedParticles`],2)}),i(`reincarnationtext${a+5}`).textContent=u.t(`buildings.per.${n[a-1]}`,{amount:d(l.times(40),2)}),i(`buyparticles${a}`).textContent=u.t("buildings.costParticles",{particles:d(e[`${s}CostParticles`],2)})}i("reincarnationshardinfo").textContent=u.t("buildings.atomsYouHave",{atoms:d(e.reincarnationShards,2),power:d(o.buildingPower,4),mult:d(o.reincarnationMultiplier)}),i("reincarnationCrystalInfo").textContent=u.t("buildings.thanksR2x14",{mult:d(f.pow(o.reincarnationMultiplier,1/50),3,!1)}),i("reincarnationMythosInfo").textContent=u.t("buildings.thanksR2x15",{mult:d(f.pow(o.reincarnationMultiplier,1/250),3,!1)}),e.resettoggle3===1||e.resettoggle3===0?i("autoreincarnate").textContent=u.t("buildings.autoPrestige",{name:"Particles",action:"Reincarnate",factor:d(f.pow(10,e.reincarnationamount)),mult:d(f.pow(10,f.log(o.reincarnationPointGain.add(1),10)-f.log(e.reincarnationPoints.add(1),10)),2)}):e.resettoggle3===2&&(i("autoreincarnate").textContent=u.t("buildings.autoReincarnate",{name:"Reincarnate",amount:e.reincarnationamount,timer:d(o.autoResetTimers.reincarnation,1)}))}else if(o.buildingSubTab==="tesseract"){let t=["dot","vector","threeSpace","bentTime","hilbertSpace"],r=["constant","dot","vector","threeSpace","bentTime"];for(let n=1;n<=5;n++){let a=`ascendBuilding${n}`;i(`ascendText${n}`).textContent=u.t(`buildings.names.${t[n-1]}`,{amount:d(e[a].owned,0,!0),gain:d(e[a].generated,2)}),i(`ascendText${5+n}`).textContent=u.t(`buildings.per.${r[n-1]}`,{amount:d(o.ascendBuildingProduction[o.ordinals[n-1]],2)}),i(`buyTesseracts${n}`).textContent=u.t("buildings.costTesseracts",{tesseracts:d(e[a].cost,0)})}i("tesseractInfo").textContent=u.t("buildings.tesseractsYouHave",{tesseracts:d(e.wowTesseracts)}),i("ascendShardInfo").textContent=u.t("buildings.constantYouHave",{const:d(e.ascendShards,2),amount:d(Math.pow(f.log(e.ascendShards.add(1),10)+1,1+.2/60*e.challengecompletions[10]*e.upgrades[125]+.1*e.platonicUpgrades[5]+.2*e.platonicUpgrades[10]+(o.platonicBonusMultiplier[5]-1)),4,!0)}),e.resettoggle4===1||e.resettoggle4===0?i("autotessbuyeramount").textContent=u.t("buildings.autoTesseract",{tesseracts:d(e.tesseractAutoBuyerAmount)}):e.resettoggle4===2&&(i("autotessbuyeramount").textContent=u.t("buildings.autoAscensionTesseract",{percent:d(Math.min(100,e.tesseractAutoBuyerAmount))}))}}},Em=()=>{},Om=()=>{},Um=()=>{if(o.currentTab===3){if(o.runescreen==="runes"){let t=["rune1Talisman","rune2Talisman","rune3Talisman","rune4Talisman","rune5Talisman"];i("offeringCount").textContent=u.t("runes.offeringsYouHave",{offerings:d(e.runeshards,0,!0)});for(let a=1;a<=7;a++){let s=o[t[a-1]];a>5&&(s=0);let l=e.runelevels[a-1],c=rt(a);i(`rune${a}level`).childNodes[0].textContent=u.t("cubes.cubeMetadata.level",{value1:d(l),value2:d(c)}),l0?"":"Level "} ${d(e.talismanLevels[t])}/${d(r)}`}if(o.runescreen==="blessings"){let t=[0,8,10,6.66,2,1],r=0;for(let n=1;n<=5;n++){i(`runeBlessingLevel${n}Value`).innerHTML=u.t("runes.blessings.blessingLevel",{amount:d(e.runeBlessingLevels[n])}),i(`runeBlessingPower${n}Value1`).innerHTML=u.t("runes.blessings.blessingPower",{reward:u.t(`runes.blessings.rewards.${n-1}`),value:d(o.runeBlessings[n]),speed:d(1-r+t[n]*o.effectiveRuneBlessingPower[n],4,!0)});let a=jn(e.runeBlessingLevels[n],o.blessingBaseCost,e.runeshards,e.runeBlessingBuyAmount)[0]-e.runeBlessingLevels[n];a>0?i(`runeBlessingPurchase${n}`).classList.add("runeButtonsAvailable"):i(`runeBlessingPurchase${n}`).classList.remove("runeButtonsAvailable"),i(`runeBlessingPurchase${n}`).innerHTML=u.t("runes.blessings.increaseLevel",{amount:d(Math.max(1,a)),offerings:d(Math.max(o.blessingBaseCost*(1+e.runeBlessingLevels[n]),jn(e.runeBlessingLevels[n],o.blessingBaseCost,e.runeshards,e.runeBlessingBuyAmount)[1]))}),n===5&&(r=1)}}if(o.runescreen==="spirits"){let t=[0,1,1,20,1,100],r=[0,0,0,1,0,0];for(let n=1;n<=5;n++){t[n]*=Xe()/400,i(`runeSpiritLevel${n}Value`).innerHTML=u.t("runes.spirits.spiritLevel",{amount:d(e.runeSpiritLevels[n])}),i(`runeSpiritPower${n}Value1`).innerHTML=u.t("runes.spirits.spiritPower",{reward:u.t(`runes.spirits.rewards.${n-1}`),value:d(o.runeSpirits[n]),speed:d(1-r[n]+t[n]*o.effectiveRuneSpiritPower[n],4,!0)});let a=jn(e.runeSpiritLevels[n],o.spiritBaseCost,e.runeshards,e.runeSpiritBuyAmount)[0]-e.runeSpiritLevels[n];a>0?i(`runeSpiritPurchase${n}`).classList.add("runeButtonsAvailable"):i(`runeSpiritPurchase${n}`).classList.remove("runeButtonsAvailable"),i(`runeSpiritPurchase${n}`).innerHTML=u.t("runes.blessings.increaseLevel",{amount:d(Math.max(1,a)),offerings:d(Math.max(o.spiritBaseCost*(1+e.runeSpiritLevels[n]),jn(e.runeSpiritLevels[n],o.spiritBaseCost,e.runeshards,e.runeSpiritBuyAmount)[1]))})}}}},Bm=()=>{o.currentTab===4&&e.researches[150]>0&&(i("autoIncrementerAmount").innerHTML=u.t("challenges.autoTimer",{time:d(o.autoChallengeTimerIncrement,2)}))},cl=()=>{o.currentTab===5&&e.researches[61]>0&&(i("automaticobtainium").textContent=u.t("researches.thanksToResearches",{x:d(ko()*qe().mult,3,!0)}))},Rm=()=>{if(o.currentTab!==6)return;i("crumbcount").textContent=u.t("ants.youHaveGalacticCrumbs",{x:d(e.antPoints,2),y:d(o.antOneProduce,2),z:d(f.pow(f.max(1,e.antPoints),1e5+Nt(499e5,(e.antUpgrades[1]+o.bonusant2)/5e3*500/499)))});let t=e.autoAntSacrificeMode===2?u.t("ants.modeRealTime"):u.t("ants.modeInGameTime"),r=e.autoAntSacrificeMode===2?e.antSacrificeTimerReal:e.antSacrificeTimer;i("autoAntSacrifice").textContent=u.t("ants.sacrificeWhenTimer",{x:e.autoAntSacTimer,y:t,z:d(r,2)}),e.achievements[173]===1&&(i("antSacrificeTimer").textContent=Vt(e.antSacrificeTimer),Gm())},ul=()=>{if(o.currentTab!==7)return;let t=e.shopUpgrades.cubeToQuark?1.5:1,r=e.shopUpgrades.tesseractToQuark?1.5:1,n=e.shopUpgrades.hypercubeToQuark?1.5:1,a=1.5,s={cube:Number(e.wowCubes.checkCubesToNextQuark(5,t,e.cubeQuarkDaily,e.cubeOpenedDaily)),tesseract:Number(e.wowTesseracts.checkCubesToNextQuark(7,r,e.tesseractQuarkDaily,e.tesseractOpenedDaily)),hypercube:Number(e.wowHypercubes.checkCubesToNextQuark(10,n,e.hypercubeQuarkDaily,e.hypercubeOpenedDaily)),platonicCube:Number(e.wowPlatonicCubes.checkCubesToNextQuark(15,a,e.platonicCubeQuarkDaily,e.platonicCubeOpenedDaily))},l=Object.keys(s);for(let p of l)i(`${p}QuarksToday`).innerHTML=u.t(`wowCubes.quarks.${p}QuarksToday`,{amount:d(e[`${p}QuarkDaily`])}),i(`${p}QuarksOpenToday`).innerHTML=u.t(`wowCubes.quarks.${p}QuarksOpenToday`,{amount:d(e[`${p}OpenedDaily`])}),i(`${p}QuarksOpenRequirement`).innerHTML=u.t(`wowCubes.quarks.${p}QuarksOpenRequirement`,{amount:d(Math.max(1,s[p]))}),i(`${p}QuarksOpenRequirement`).style.color=Math.max(1,s[p])===1?"gold":"white";let c;switch(e.subtabNumber){case 0:{e.autoOpenCubes&&(i("openCubes").textContent=u.t("wowCubes.autoOn",{percent:d(e.openCubes,0)})),i("cubeQuantity").innerHTML=u.t("wowCubes.cubes.inventory",{amount:d(e.wowCubes,0,!0)});let p=[null,e.cubeBlessings.accelerator,e.cubeBlessings.multiplier,e.cubeBlessings.offering,e.cubeBlessings.runeExp,e.cubeBlessings.obtainium,e.cubeBlessings.antSpeed,e.cubeBlessings.antSacrifice,e.cubeBlessings.antELO,e.cubeBlessings.talismanBonus,e.cubeBlessings.globalSpeed];c=[null,2,2,2,2,2,2,2,1,4,3];for(let g=1;g<=10;g++){let m=0;p[g]>=1e3&&g!==6&&(m+=2);let h=g===1||g===8||g===9?1:100;i(`cube${g}Bonus`).innerHTML=u.t(`wowCubes.cubes.items.${g}`,{amount:d(p[g],0,!0),bonus:d(h*(o.cubeBonusMultiplier[g]-1),c[g]+m,!0)})}i("cubeBlessingsTotal").innerHTML=u.t("wowCubes.cubes.total",{amount:d(ae(p.slice(1)),0,!0)});break}case 1:{e.autoOpenTesseracts&&(i("openTesseracts").textContent=u.t("wowCubes.autoOn",{percent:d(e.openTesseracts,0)})),i("tesseractQuantity").innerHTML=u.t("wowCubes.tesseracts.inventory",{amount:d(e.wowTesseracts,0,!0)});let p=[null,e.tesseractBlessings.accelerator,e.tesseractBlessings.multiplier,e.tesseractBlessings.offering,e.tesseractBlessings.runeExp,e.tesseractBlessings.obtainium,e.tesseractBlessings.antSpeed,e.tesseractBlessings.antSacrifice,e.tesseractBlessings.antELO,e.tesseractBlessings.talismanBonus,e.tesseractBlessings.globalSpeed];c=[null,2,2,2,2,2,2,2,2,2,2];for(let g=1;g<=10;g++){let m=0;p[g]>=1e3&&g!==6&&(m+=2),i(`tesseract${g}Bonus`).innerHTML=u.t(`wowCubes.tesseracts.items.${g}`,{amount:d(p[g],0,!0),bonus:d(100*(o.tesseractBonusMultiplier[g]-1),c[g]+m,!0)})}i("tesseractBlessingsTotal").innerHTML=u.t("wowCubes.tesseracts.total",{amount:d(ae(p.slice(1)),0,!0)});break}case 2:{e.autoOpenHypercubes&&(i("openHypercubes").textContent=u.t("wowCubes.autoOn",{percent:d(e.openHypercubes,0)})),i("hypercubeQuantity").innerHTML=u.t("wowCubes.hypercubes.inventory",{amount:d(e.wowHypercubes,0,!0)});let p=[null,e.hypercubeBlessings.accelerator,e.hypercubeBlessings.multiplier,e.hypercubeBlessings.offering,e.hypercubeBlessings.runeExp,e.hypercubeBlessings.obtainium,e.hypercubeBlessings.antSpeed,e.hypercubeBlessings.antSacrifice,e.hypercubeBlessings.antELO,e.hypercubeBlessings.talismanBonus,e.hypercubeBlessings.globalSpeed];c=[null,2,2,2,2,2,2,2,2,2,2];for(let g=1;g<=10;g++){let m=0;p[g]>=1e3&&(m+=2),i(`hypercube${g}Bonus`).innerHTML=u.t(`wowCubes.hypercubes.items.${g}`,{amount:d(p[g],0,!0),bonus:d(100*(o.hypercubeBonusMultiplier[g]-1),c[g]+m,!0)})}i("hypercubeBlessingsTotal").innerHTML=u.t("wowCubes.hypercubes.total",{amount:d(ae(p.slice(1)),0,!0)});break}case 3:{e.autoOpenPlatonicsCubes&&(i("openPlatonicCube").textContent=u.t("wowCubes.autoOn",{percent:d(e.openPlatonicsCubes,0)})),i("platonicQuantity").innerHTML=u.t("wowCubes.platonics.inventory",{amount:d(e.wowPlatonicCubes,0,!0)});let p=[e.platonicBlessings.cubes,e.platonicBlessings.tesseracts,e.platonicBlessings.hypercubes,e.platonicBlessings.platonics,e.platonicBlessings.hypercubeBonus,e.platonicBlessings.taxes,e.platonicBlessings.scoreBonus,e.platonicBlessings.globalSpeed],g=[4e6,4e6,4e6,8e4,1e4,1e4,1e4,1e4];c=[5,5,5,5,2,3,3,2];for(let m=0;m=g[m]&&(h+=1),i(`platonicCube${m+1}Bonus`).innerHTML=u.t(`wowCubes.platonics.items.${m+1}`,{amount:d(p[m],0,!0),bonus:d(100*(o.platonicBonusMultiplier[m]-1),c[m]+h,!0)})}i("platonicBlessingsTotal").innerHTML=u.t("wowCubes.platonics.total",{amount:d(ae(p),0,!0)});break}case 4:i("cubeAmount2").textContent=`You have ${d(e.wowCubes,0,!0)} Wow! Cubes =)`;break;case 5:break;case 6:i("hepteractQuantity").innerHTML=u.t("wowCubes.hepteractForge.youPossessHepteracts",{x:d(e.wowAbyssals,0,!0)}),kg.forEach(p=>{Uv(p)}),i("heptGridOrbBalance").textContent=d(e.overfluxOrbs),i("heptGridOrbEffect").textContent=`${d(100*(-1+Bn()),2,!0)}%`,i("heptGridPowderBalance").textContent=d(e.overfluxPowder),i("heptGridPowderWarps").textContent=d(e.dailyPowderResetUses);break;default:break}},Uv=t=>{let r=`${t}ProgressBarText`,n=`${t}ProgressBar`,a=i(r),s=i(n);if(!e.hepteractCrafts[t].UNLOCKED)a.textContent="LOCKED",s.style.width="100%",s.style.backgroundColor="var(--hepteract-bar-red)";else{let c=e.hepteractCrafts[t].BAL,p=e.hepteractCrafts[t].computeActualCap(),g=Math.round(c/p*100),m="";g<34?m="var(--hepteract-bar-red)":g>=34&&g<68?m="var(--hepteract-bar-yellow)":m="var(--hepteract-bar-green)",a.textContent=`${d(c)} / ${d(p)}`,s.style.width=`${g}%`,s.style.backgroundColor=m}},Im=()=>{if(o.currentTab!==8)return;let t=Xr(),r=Mo();i("autoAscend").innerHTML=e.autoAscendMode==="c10Completions"?u.t("corruptions.autoAscend.c10Completions",{input:d(e.autoAscendThreshold),completions:d(e.challengecompletions[10])}):u.t("corruptions.autoAscend.realTime",{input:d(e.autoAscendThreshold),time:d(e.ascensionCounterRealReal)}),i("corruptionBank").innerHTML=u.t("corruptions.corruptionBank",{number:d(t[0],0,!0)}),i("corruptionScore").innerHTML=u.t("corruptions.corruptionScore",{ascScore:d(t[1],1,!0),corrMult:d(t[2],1,!0),bonusMult:d(t[9],2,!0),totalScore:d(t[3],1,!0)}),i("corruptionCubes").innerHTML=u.t("corruptions.corruptionCubes",{cubeAmount:d(t[4],0,!0)}),i("corruptionTesseracts").innerHTML=u.t("corruptions.corruptionTesseracts",{tesseractAmount:d(t[5],0,!0)}),i("corruptionHypercubes").innerHTML=u.t("corruptions.corruptionHypercubes",{hypercubeAmount:d(t[6],0,!0)}),i("corruptionPlatonicCubes").innerHTML=u.t("corruptions.corruptionPlatonics",{platonicAmount:d(t[7],0,!0)}),i("corruptionHepteracts").innerHTML=u.t("corruptions.corruptionHepteracts",{hepteractAmount:d(t[8],0,!0)}),i("corruptionAntExponent").innerHTML=u.t("corruptions.antExponent",{exponent:d((1-.9/90*ae(e.usedCorruptions))*o.extinctionMultiplier[e.usedCorruptions[7]],3)}),i("corruptionSpiritBonus").innerHTML=u.t("corruptions.spiritBonus",{multiplier:d(Xe()/400,2,!0)}),i("corruptionAscensionCount").style.display=r>1?"block":"none",r>1&&(i("corruptionAscensionCount").innerHTML=u.t("corruptions.ascensionCount",{ascCount:d(Mo())}))},Nm=()=>{if(o.currentTab===10){if(e.subtabNumber===0){i("saveString").textContent=u.t("settings.currently",{x:e.saveString.replace("$VERSION$",`v${Jt}`)});let t=Ut(),r=t.gain,n=t.capacity,a=1;a*=1+er()/100,a*=e.highestSingularityCount>=100?1+e.highestSingularityCount/50:1,i("quarktimerdisplay").textContent=u.t("settings.exportQuark",{x:d(3600/t.perHour-e.quarkstimer%(3600.00001/t.perHour),2),y:e.worlds.toString(1)}),i("quarktimeramount").textContent=u.t("settings.quarksOnExport",{x:e.worlds.toString(r),y:e.worlds.toString(n)}),i("goldenQuarkTimerDisplay").textContent=u.t("settings.exportGoldenQuark",{x:d(3600/Math.max(1,+e.singularityUpgrades.goldenQuarks3.getEffect().bonus)-e.goldenQuarksTimer%(3600.00001/Math.max(1,+e.singularityUpgrades.goldenQuarks3.getEffect().bonus))),y:d(a,2,!0)}),i("goldenQuarkTimerAmount").textContent=u.t("settings.goldenQuarksOnExport",{x:d(Math.floor(e.goldenQuarksTimer*+e.singularityUpgrades.goldenQuarks3.getEffect().bonus/3600)*a,2),y:d(Math.floor(168*+e.singularityUpgrades.goldenQuarks3.getEffect().bonus*a))})}e.subtabNumber===3&&km()}},$m=()=>{if(o.currentTab===9){if(e.subtabNumber===0){i("goldenQuarkamount").textContent=u.t("singularity.goldenQuarkAmount",{goldenQuarks:d(e.goldenQuarks,0,!0)});let t=Object.keys(e.singularityUpgrades),r=o.shopEnhanceVision;for(let n of t){if(n==="offeringAutomatic"||n==="WIP")continue;let a=e.singularityUpgrades[n],s=i(`${String(n)}`);a.maxLevel!==-1&&a.level>=a.computeMaxLevel()?s.style.filter=r?"brightness(.9)":"none":a.getCostTNL()>e.goldenQuarks||e.singularityCounta.level?s.style.filter=r?"blur(1px) invert(.9) saturate(200)":"none":s.style.filter=r?"invert(.9) brightness(1.1)":"none")}}if(e.subtabNumber===2){let t=Object.keys(e.octeractUpgrades),r=o.shopEnhanceVision;for(let n of t){let a=e.octeractUpgrades[n],s=i(`${String(n)}`);a.maxLevel!==-1&&a.level>=a.maxLevel?s.style.filter=r?"brightness(.9)":"none":a.getCostTNL()>e.wowOcteracts?s.style.filter=r?"grayscale(.9) brightness(.8)":"none":(a.maxLevel===-1||a.levela.level?s.style.filter=r?"blur(2px) invert(.9) saturate(200)":"none":s.style.filter=r?"invert(.9) brightness(1.1)":"none")}}}},So=t=>{o.shopEnhanceVision=t},dl=()=>{if(o.currentTab!==9)return;i("octeractAmount").innerHTML=u.t("octeract.amount",{octeracts:d(e.wowOcteracts,2,!0,!0,!0)});let t=Kr();i("secondsPerOcteract").style.display=t<1?"block":"none",i("secondsPerOcteract").innerHTML=u.t("octeract.secondsPerOcteract",{seconds:d(1/t,2,!0)}),i("octeractPerSeconds").style.display=t>=1?"block":"none",i("octeractPerSeconds").innerHTML=u.t("octeract.octeractsPerSecond",{octeracts:d(t,2,!0)});let r=(Lo()-1)*100,n=(fn()-1)*100,a=(xu()-1)*100,s=(vo()-1)*100;i("totalOcteractAmount").innerHTML=u.t("octeract.totalGenerated",{octeracts:d(e.totalWowOcteracts,2,!0,!0,!0)}),i("totalOcteractCubeBonus").style.display=r>=.001?"block":"none",i("totalOcteractQuarkBonus").style.display=n>=.001?"block":"none",i("totalOcteractOfferingBonus").style.display=a>=.001?"block":"none",i("totalOcteractObtainiumBonus").style.display=s>=.001?"block":"none",i("totalOcteractCubeBonus").innerHTML=u.t("octeract.generatedCubeBonus",{cubeBonus:d(r,3,!0)}),i("totalOcteractQuarkBonus").innerHTML=u.t("octeract.generatedQuarkBonus",{quarkBonus:d(n,3,!0)}),i("totalOcteractOfferingBonus").innerHTML=u.t("octeract.generatedOfferingBonus",{offeringBonus:d(a,3,!0)}),i("totalOcteractObtainiumBonus").innerHTML=u.t("octeract.generatedObtainiumBonus",{obtainiumBonus:d(s,3,!0)})},vs=()=>{if(o.currentTab!==9)return;let t=o.ambrosiaCurrStats.ambrosiaLuck,r=o.ambrosiaCurrStats.ambrosiaLuck/o.ambrosiaCurrStats.ambrosiaAdditiveLuckMult,n=100*(o.ambrosiaCurrStats.ambrosiaAdditiveLuckMult-1),a=Math.floor(t/100),s=t-100*Math.floor(t/100),l=Cs(),c=100*(pl()-1),p=100*(Co()-1),g=o.ambrosiaCurrStats.ambrosiaBlueberries-e.spentBlueberries,m=o.ambrosiaCurrStats.ambrosiaGenerationSpeed,h=Math.min(m,Math.pow(1e3*m,1/2)),b=100*Math.min(1,e.blueberryTime/l),C=100*Math.min(1,e.ultimateProgress/1e6);i("ambrosiaProgress").style.width=`${b}%`,i("ambrosiaProgressText").textContent=`${d(e.blueberryTime,0,!0)} / ${d(l,0,!0)} [+${d(m,0,!0)}/s]`,i("pixelProgress").style.width=`${C}%`,i("pixelProgressText").textContent=`${d(e.ultimateProgress,0,!0)} / ${d(1e6,0,!0)} [+${d(h,2,!0)}/s]`;let v=n>.01?`[\u2618${d(r,0,!0)} +${d(n,2,!0)}%]`:"";i("ambrosiaAmount").innerHTML=u.t("ambrosia.amount",{ambrosia:d(e.ambrosia,0,!0),lifetimeAmbrosia:d(e.lifetimeAmbrosia,0,!0)}),i("ambrosiaAmountPerGeneration").innerHTML=u.t("ambrosia.perGen",{guaranteed:d(a,0,!0),extraChance:d(s,0,!0),ambrosiaLuck:d(t,0,!0),extra:v}),i("ambrosiaRewards").innerHTML=u.t("ambrosia.bonuses",{cube:d(c,0,!0),quark:d(p,0,!0)}),i("ambrosiaBlueberries").innerHTML=u.t("ambrosia.availableBlueberries",{availableBlueberries:g}),e.cubeUpgrades[76]>0?(i("cubeUpgradeThresholds").style.display="block",i("cubeUpgradeThresholds").innerHTML=u.t("ambrosia.cubeUpgradeThresholds",{threshold:To(),percent:e.cubeUpgrades[76]*To()})):i("cubeUpgradeThresholds").style.display="none",e.cubeUpgradeRedBarFilled>0?(i("cubeUpgradeRedBarFills").style.display="block",i("cubeUpgradeRedBarFills").innerHTML=u.t("ambrosia.cubeUpgradeRedBarFills",{amount:d(e.cubeUpgradeRedBarFilled,0,!0),luck:d(Math.min(100,e.cubeUpgradeRedBarFilled/50),2,!0)})):i("cubeUpgradeRedBarFills").style.display="none"},Cu=()=>{if(o.currentTab!==11)return;i("quarkamount").textContent=u.t("shop.youHaveQuarks",{x:d(e.worlds,0,!0)}),i("offeringpotionowned").textContent=d(e.shopUpgrades.offeringPotion,0,!0),i("obtainiumpotionowned").textContent=d(e.shopUpgrades.obtainiumPotion,0,!0);let t=Object.keys(e.shopUpgrades);for(let r of t){let n=pe[r];if(n.type==="consume"){let a=Math.min(Math.floor(Number(e.worlds)/Ua(r)),n.maxLevel-e.shopUpgrades[r]),s=i(`buy${r.toLowerCase()}`);switch(e.shopBuyMaxToggle){case!1:s.textContent="BUY: 100 Quarks Each";break;case"TEN":s.textContent=`+${Math.min(10,a)} for ${d(Ua(r)*Math.min(10,a),0,!0)} Quarks`;break;default:s.textContent=`+${a} for ${d(Ua(r)*a)} Quarks`}}if(n.type==="upgrade"){if(e.shopHideToggle&&e.shopUpgrades[r]>=n.maxLevel&&!n.refundable){i(`${r}Hide`).style.display="none";continue}else i(`${r}Hide`).style.display=hs(r)?"block":"none";n.maxLevel===1?i(`${r}Level`).textContent=e.shopUpgrades[r]>=n.maxLevel?"Bought!":"Not Bought!":i(`${r}Level`).textContent=`${e.highestSingularityCount>0||e.ascensionCount>0?"":"Level "}${d(e.shopUpgrades[r])}/${d(n.maxLevel)}`;let a=n.maxLevel-e.shopUpgrades[r],s;switch(e.shopBuyMaxToggle){case!1:i(`${r}Button`).textContent=e.shopUpgrades[r]>=n.maxLevel?u.t("shop.maxed"):u.t("shop.upgradeFor",{x:d(Ua(r))});break;case"TEN":s=rr(e.shopUpgrades[r],n.price,+e.worlds,n.priceIncrease/n.price,Math.min(10,a)),i(`${r}Button`).textContent=e.shopUpgrades[r]>=n.maxLevel?u.t("shop.maxed"):u.t("shop.plusForQuarks",{x:d(s.levelCanBuy-e.shopUpgrades[r],0,!0),y:d(s.cost)});break;default:s=rr(e.shopUpgrades[r],n.price,+e.worlds,n.priceIncrease/n.price,a),i(`${r}Button`).textContent=e.shopUpgrades[r]>=n.maxLevel?u.t("shop.maxed"):u.t("shop.plusForQuarks",{x:d(s.levelCanBuy-e.shopUpgrades[r],0,!0),y:d(s.cost)})}}}i("buySingularityQuarksAmount").textContent=`${e.goldenQuarks<1e3?"Owned: ":""}${d(e.goldenQuarks)}`,i("buySingularityQuarksButton").textContent=`Buy! ${d(Bc().cost)} Quarks Each`},_m=()=>{},Dm=()=>{};var Hm=t=>{var a;let r=(a=t.getAttribute("toggleId"))!=null?a:1;e.toggles[+r]?e.toggles[+r]=!1:e.toggles[+r]=!0;let n=t.getAttribute("format");if(n==="$"||n==="[$]"){let s=e.toggles[+r]?u.t("general.on"):u.t("general.off");t.textContent=n==="[$]"?`[${s}]`:s}else if(n==="Auto Catalyze: $"){let s=e.toggles[+r]?u.t("shop.autoCatalyzeOn"):u.t("shop.autoCatalyzeOff");t.textContent=s}else if(n==="Hover-to-Buy [$]"){let s=e.toggles[+r]?u.t("researches.hoverToBuyOn"):u.t("researches.hoverToBuyOff");t.textContent=s}else if(n==="Auto: $"){let s=e.toggles[+r]?u.t("general.autoOnColon"):u.t("general.autoOffColon");t.textContent=s}else if(n){let s=n.replace("$",e.toggles[+r]?"ON":"OFF");t.textContent=s}else t.textContent=e.toggles[+r]?u.t("general.autoOnBracket"):u.t("general.autoOffBracket");t.style.border=`2px solid ${e.toggles[+r]?"green":"red"}`},gr=(t,r=!1)=>{t<=5&&((e.currentChallenge.ascension!==15||e.ascensionCounter>=2)&&(e.currentChallenge.transcension=t,Pe("transcensionChallenge",!1,"enterChallenge"),e.transcendCount-=1),!e.currentChallenge.reincarnation&&!document.querySelector(".resetbtn.hover")&&at("transcensionChallenge")),t>=6&&t<11&&((e.currentChallenge.ascension!==15||e.ascensionCounter>=2)&&(e.currentChallenge.reincarnation=t,Pe("reincarnationChallenge",!1,"enterChallenge"),e.reincarnationCount-=1),document.querySelector(".resetbtn.hover")||at("reincarnationChallenge")),t>=11&&(!r&&!e.toggles[31]||e.challengecompletions[10]>0||e.currentChallenge.transcension===0&&e.currentChallenge.reincarnation===0&&e.currentChallenge.ascension===0)&&(e.currentChallenge.ascension===15&&Ae("ascensionChallenge",!1,!0),e.currentChallenge.ascension=t,Pe("ascensionChallenge",!1,"enterChallenge")),Sr(),bl(t),t<=10&&!r&&e.autoChallengeRunning&&Ao(),e.currentChallenge.transcension!==0&&e.currentChallenge.reincarnation!==0&&e.currentChallenge.ascension!==0&&e.achievements[238]<1&&R(238)},Fm=(t,r)=>{e[`${r}buyamount`]=t;let n=["one","ten","hundred","thousand","10k","100k"][t.toString().length-1];i(`${r}${n}`).style.backgroundColor="Green",t!==1&&(i(`${r}one`).style.backgroundColor=""),t!==10&&(i(`${r}ten`).style.backgroundColor=""),t!==100&&(i(`${r}hundred`).style.backgroundColor=""),t!==1e3&&(i(`${r}thousand`).style.backgroundColor=""),t!==1e4&&(i(`${r}10k`).style.backgroundColor=""),t!==1e5&&(i(`${r}100k`).style.backgroundColor="")},Vn=t=>{if(t)e.shoptoggles[t]=!e.shoptoggles[t],i(`${t}AutoUpgrade`).style.borderColor=e.shoptoggles[t]?"green":"red",e.shoptoggles[t]?i(`${t}AutoUpgrade`).textContent=u.t("general.autoOnColon"):i(`${t}AutoUpgrade`).textContent=u.t("general.autoOffColon");else{let r=Object.keys(e.shoptoggles);for(let n of r){let a=e.shoptoggles[n]?"green":"red";e.shoptoggles[n]?i(`${n}AutoUpgrade`).textContent=u.t("general.autoOnColon"):i(`${n}AutoUpgrade`).textContent=u.t("general.autoOffColon"),i(`${n}AutoUpgrade`).style.borderColor=a}}},Po=t=>{t===1?e.resettoggle1===1||e.resettoggle1===0?(e.resettoggle1=2,i("prestigeautotoggle").textContent=u.t("toggles.modeTime")):(e.resettoggle1=1,i("prestigeautotoggle").textContent=u.t("toggles.modeAmount")):t===2?e.resettoggle2===1||e.resettoggle2===0?(e.resettoggle2=2,i("transcendautotoggle").textContent=u.t("toggles.modeTime")):(e.resettoggle2=1,i("transcendautotoggle").textContent=u.t("toggles.modeAmount")):t===3?e.resettoggle3===1||e.resettoggle3===0?(e.resettoggle3=2,i("reincarnateautotoggle").textContent=u.t("toggles.modeTime")):(e.resettoggle3=1,i("reincarnateautotoggle").textContent=u.t("toggles.modeAmount")):t===4&&(e.resettoggle4===1||e.resettoggle4===0?(e.resettoggle4=2,i("tesseractautobuymode").textContent=u.t("toggles.modePercentage")):(e.resettoggle4=1,i("tesseractautobuymode").textContent=u.t("toggles.modeAmount")))},Qm=()=>{e.tesseractAutoBuyerToggle===1||e.tesseractAutoBuyerToggle===0?(e.tesseractAutoBuyerToggle=2,i("tesseractautobuytoggle").textContent=u.t("runes.talismans.autoBuyOff"),i("tesseractautobuytoggle").style.border="2px solid red"):(e.tesseractAutoBuyerToggle=1,i("tesseractautobuytoggle").textContent=u.t("runes.talismans.autoBuyOn"),i("tesseractautobuytoggle").style.border="2px solid green")},Mu=()=>{var n;let t=Array.from(document.querySelectorAll(".auto[toggleid]"));for(let a of t){let s=a.getAttribute("format"),l=(n=a.getAttribute("toggleId"))!=null?n:1;if(s==="$"){let c=e.toggles[+l]?u.t("general.on"):u.t("general.off");a.textContent=c}else if(s==="Auto Catalyze: $"){let c=e.toggles[+l]?u.t("shop.autoCatalyzeOn"):u.t("shop.autoCatalyzeOff");a.textContent=c}else if(s==="Hover-to-Buy [$]"){let c=e.toggles[+l]?u.t("researches.hoverToBuyOn"):u.t("researches.hoverToBuyOff");a.textContent=c}else if(s==="Auto: $"){let c=e.toggles[+l]?u.t("general.autoOnColon"):u.t("general.autoOffColon");a.textContent=c}else if(s){let c=s.replace("$",e.toggles[+l]?"ON":"OFF");a.textContent=c}else a.textContent=e.toggles[+l]?u.t("general.autoOnBracket"):u.t("general.autoOffBracket");a.style.border=`2px solid ${e.toggles[+l]?"green":"red"}`}let r=Array.from(document.querySelectorAll('*[id^="tesseractAutoToggle"]'));for(let a=0;a{e.researchBuyMaxToggle?(e.researchBuyMaxToggle=!1,i("toggleresearchbuy").textContent=u.t("researches.upgradeOne")):(e.researchBuyMaxToggle=!0,i("toggleresearchbuy").textContent=u.t("researches.upgradeMax"))},jm=()=>{let t=i("toggleautoresearch");e.autoResearchToggle||e.shopUpgrades.obtainiumAuto<1?(e.autoResearchToggle=!1,t.textContent=u.t("researches.automaticOff"),i(`res${e.autoResearch||1}`).classList.remove("researchRoomba"),e.autoResearch=0):(e.autoResearchToggle=!0,t.textContent=u.t("researches.automaticOn")),e.autoResearchToggle&&Ht()&&e.autoResearchMode==="cheapest"&&(e.autoResearch=o.researchOrderByCost[e.roombaResearchIndex])},Vm=()=>{let t=i("toggleautoresearchmode");e.autoResearchMode==="cheapest"||!Ht()?(e.autoResearchMode="manual",t.textContent=u.t("researches.autoModeManual")):(e.autoResearchMode="cheapest",t.textContent=u.t("researches.autoModeCheapest")),i(`res${e.autoResearch||1}`).classList.remove("researchRoomba"),e.autoResearchToggle&&Ht()&&e.autoResearchMode==="cheapest"&&(e.autoResearch=o.researchOrderByCost[e.roombaResearchIndex])},Tu=t=>{let r=i("toggleautosacrifice");t===0?e.autoSacrificeToggle?(e.autoSacrificeToggle=!1,r.textContent=u.t("runes.blessings.autoRuneOff"),r.style.border="2px solid red",e.autoSacrifice=0):(e.autoSacrificeToggle=!0,e.saveOfferingToggle=!1,r.textContent=u.t("runes.blessings.autoRuneOn"),r.style.border="2px solid green",i("saveOffToggle").textContent=u.t("toggles.saveOfferingsOff"),i("saveOffToggle").style.color="white"):e.autoSacrificeToggle&&e.shopUpgrades.offeringAuto>.5&&(e.autoSacrifice===t?e.autoSacrifice=0:e.autoSacrifice=t);for(let n=1;n<=5;n++)i(`rune${n}`).style.backgroundColor=e.autoSacrifice===n?"orange":"";He()},Wm=()=>{let t=i("toggleautoBuyFragments");e.autoBuyFragment?(t.textContent=u.t("runes.talismans.autoBuyOff"),t.style.border="2px solid orange",t.style.color="white"):(t.textContent=u.t("runes.talismans.autoBuyOn"),t.style.border="2px solid white",t.style.color="orange"),e.autoBuyFragment=!e.autoBuyFragment},Km=t=>{o.buildingSubTab=t;let r={coin:{screen:"coinBuildings",button:"switchToCoinBuilding",subtabNumber:0},diamond:{screen:"prestige",button:"switchToDiamondBuilding",subtabNumber:1},mythos:{screen:"transcension",button:"switchToMythosBuilding",subtabNumber:2},particle:{screen:"reincarnation",button:"switchToParticleBuilding",subtabNumber:3},tesseract:{screen:"ascension",button:"switchToTesseractBuilding",subtabNumber:4}};for(let{screen:n}of Object.values(r))i(n).style.display="none";i(r[o.buildingSubTab].screen).style.display="flex",e.subtabNumber=r[o.buildingSubTab].subtabNumber},zm=t=>{let r=Number(t),n=["runes","talismans","blessings","spirits"];o.runescreen=n[r-1];for(let a=1;a<=4;a++){let s=i(`toggleRuneSubTab${a}`),l=i(`runeContainer${a}`);a===r?(s.style.border="2px solid gold",l.style.display="flex"):(s.style.border="2px solid silver",l.style.display="none")}e.subtabNumber=r-1},Xm=t=>{let r=Number(t);for(let n=1;n<=2;n++){let a=i(`challengesWrapper${n}`);n===r?a.style.display="block":a.style.display="none"}e.subtabNumber=r-1},Zm=()=>{let t=i("toggleautofortify");e.autoFortifyToggle?(t.textContent=u.t("runes.autoFortifyOff"),t.style.border="2px solid red"):(t.textContent=u.t("runes.autoFortifyOn"),t.style.border="2px solid green"),e.autoFortifyToggle=!e.autoFortifyToggle},Ym=()=>{let t=i("toggleautoenhance");e.autoEnhanceToggle?(t.textContent=u.t("runes.autoEnhanceOff"),t.style.border="2px solid red"):(t.textContent=u.t("runes.autoEnhanceOn"),t.style.border="2px solid green"),e.autoEnhanceToggle=!e.autoEnhanceToggle},Jm=()=>{let t=i("saveOffToggle"),r=i("toggleautosacrifice");e.saveOfferingToggle?(e.autoSacrificeToggle=!0,t.textContent=u.t("toggles.saveOfferingsOff"),t.style.color="white",r.textContent="Auto Runes: ON",r.style.border="2px solid green"):(e.autoSacrificeToggle=!1,t.textContent=u.t("toggles.saveOfferingsOn"),t.style.color="yellow",r.textContent="Auto Runes: OFF",r.style.border="2px solid red"),e.saveOfferingToggle=!e.saveOfferingToggle},ef=t=>{let r=Number(t);for(let n=1;n<=4;n++){let a=i(`singularityContainer${n}`);n===r?a.style.display="block":a.style.display="none"}e.subtabNumber=r-1,e.subtabNumber===2&&dl(),e.subtabNumber===3&&vs()},tf=async t=>{let r=i(t);if(!r.classList.contains("subtabActive"))if(r.parentNode.querySelectorAll(".subtabActive").forEach(n=>n.classList.remove("subtabActive")),r.classList.add("subtabActive"),t==="creditssubtab"){let n=i("creditList"),a=i("artistList");if(n.childElementCount>0||a.childElementCount>0)return;if(!navigator.onLine||document.hidden)return;try{let l=await(await fetch("https://api.github.com/repos/pseudo-corp/SynergismOfficial/contributors",{headers:{Accept:"application/vnd.github.v3+json"}})).json();for(let c of l){let p=document.createElement("div");p.classList.add("credit");let g=new Image(32,32);g.src=c.avatar_url,g.alt=c.login;let m=document.createElement("a");m.href=`https://github.com/Pseudo-Corp/SynergismOfficial/commits?author=${c.login}`,m.textContent=c.login,m.target="_blank",m.rel="noopener noreferrer nofollow",p.appendChild(g),p.appendChild(m),n.appendChild(p)}}catch(s){let l=s;n.appendChild(document.createTextNode(l.toString()))}try{let l=await(await fetch("https://api.github.com/gists/01917ff476d25a141c5bad38340cd756",{headers:{Accept:"application/vnd.github.v3+json"}})).json(),c=JSON.parse(l.files["synergism_artists.json"].content);for(let p of c){let g=document.createElement("p");g.textContent=p,a.appendChild(g)}}catch(s){let l=s;n.appendChild(document.createTextNode(l.toString()))}}else t==="accountSubTab"&&ho()},rf=()=>{let t=i("toggleConfirmShop");t.textContent=e.shopConfirmationToggle?u.t("shop.shopConfirmationOff"):u.t("shop.shopConfirmationOn"),e.shopConfirmationToggle=!e.shopConfirmationToggle},nf=t=>{let r=i("toggleBuyMaxShopText");if(t.shiftKey){r.textContent=u.t("shop.buyAny"),e.shopBuyMaxToggle="ANY";return}switch(e.shopBuyMaxToggle){case!1:r.innerHTML=u.t("shop.buy10"),e.shopBuyMaxToggle="TEN";break;case"TEN":r.innerHTML=u.t("shop.buyMax"),e.shopBuyMaxToggle=!0;break;default:r.innerHTML=u.t("shop.buy1"),e.shopBuyMaxToggle=!1}},af=()=>{let t=i("toggleHideShop");t.textContent=e.shopHideToggle?u.t("shop.hideMaxedOff"):u.t("shop.hideMaxedOn"),e.shopHideToggle=!e.shopHideToggle},gl=()=>{let t=i("toggleAntMax");t.textContent=e.antMax?u.t("general.buyMaxOff"):u.t("general.buyMaxOn"),e.antMax=!e.antMax},ws=(t=0)=>{if(t===0){let r=i("toggleAutoSacrificeAnt");e.autoAntSacrifice?(e.autoAntSacrifice=!1,r.textContent=u.t("ants.autoSacrificeOff")):(e.autoAntSacrifice=!0,r.textContent=u.t("ants.autoSacrificeOn"))}else if(t===1){let r=i("autoSacrificeAntMode");e.autoAntSacrificeMode===1||e.autoAntSacrificeMode===0?(e.autoAntSacrificeMode=2,r.textContent=u.t("ants.modeRealTime")):(e.autoAntSacrificeMode=1,r.textContent=u.t("ants.modeInGameTime"))}},sf=()=>{let t=i("toggleCubeBuy");e.cubeUpgradesBuyMaxToggle?(e.cubeUpgradesBuyMaxToggle=!1,t.textContent=u.t("toggles.upgradeOneLevelWow")):(e.cubeUpgradesBuyMaxToggle=!0,t.textContent=u.t("toggles.upgradeMaxIfPossible"))},ml=(t=!0)=>{t&&(e.autoCubeUpgradesToggle=!e.autoCubeUpgradesToggle);let r=i("toggleAutoCubeUpgrades");e.autoCubeUpgradesToggle?(r.textContent=u.t("toggles.autoUpgradeOn"),r.style.border="2px solid green"):(r.textContent=u.t("toggles.autoUpgradeOff"),r.style.border="2px solid red")},fl=(t=!0)=>{t&&(e.autoPlatonicUpgradesToggle=!e.autoPlatonicUpgradesToggle);let r=i("toggleAutoPlatonicUpgrades");e.autoPlatonicUpgradesToggle?(r.textContent=u.t("toggles.autoUpgradeOn"),r.style.border="2px solid green"):(r.textContent=u.t("toggles.autoUpgradeOff"),r.style.border="2px solid red")},of=t=>{let r=Number(t),n=gf(7);for(let a=1;a<=n;a++){let s=i(`cubeTab${a}`);s.style.display==="flex"&&a!==r&&(s.style.display="none"),s.style.display==="none"&&a===r&&(s.style.display="flex",e.subtabNumber=a-1)}ul()},Wn=t=>{switch(t){case 1:{let r=Number.parseFloat(i("startAutoChallengeTimerInput").value)||0;e.autoChallengeTimer.start=Math.max(r,0),i("startTimerValue").innerHTML=u.t("challenges.timeStartSweep",{time:d(e.autoChallengeTimer.start,2,!0)});return}case 2:{let r=Number.parseFloat(i("exitAutoChallengeTimerInput").value)||0;e.autoChallengeTimer.exit=Math.max(r,0),i("exitTimerValue").innerHTML=u.t("challenges.timeExitChallenge",{time:d(e.autoChallengeTimer.exit,2,!0)});return}case 3:{let r=Number.parseFloat(i("enterAutoChallengeTimerInput").value)||0;e.autoChallengeTimer.enter=Math.max(r,0),i("enterTimerValue").innerHTML=u.t("challenges.timeEnterChallenge",{time:d(e.autoChallengeTimer.enter,2,!0)});return}}},lf=t=>{if(t<=15){e.autoChallengeToggles[t]=!e.autoChallengeToggles[t];let r=i("toggleAutoChallengeIgnore");r.style.border=e.autoChallengeToggles[t]?"2px solid green":"2px solid red",t>=11&&t<=15?e.autoChallengeToggles[t]?r.textContent=u.t("challenges.autoAscRunChalOn",{x:t}):r.textContent=u.t("challenges.autoAscRunChalOff",{x:t}):e.autoChallengeToggles[t]?r.textContent=u.t("challenges.autoRunChalOn",{x:t}):r.textContent=u.t("challenges.autoRunChalOff",{x:t})}},Ao=()=>{let t=i("toggleAutoChallengeStart");e.autoChallengeRunning?(t.style.border="2px solid red",t.textContent=u.t("challenges.autoChallengeSweepOff"),o.autoChallengeTimerIncrement=0,pr("OFF")):(t.style.border="2px solid gold",t.textContent=u.t("challenges.autoChallengeSweepOn"),pr("START"),o.autoChallengeTimerIncrement=0),e.autoChallengeRunning=!e.autoChallengeRunning},pr=t=>{let r=i("autoChallengeType");r.textContent=u.t(`challenges.mode${t[0]+t.slice(1).toLowerCase()}`)},xs=(t=0)=>{if(t===0){let r=i("ascensionAutoEnable");e.autoAscend?(r.style.border="2px solid red",r.textContent=u.t("corruptions.autoAscend.off")):(r.style.border="2px solid green",r.textContent=u.t("corruptions.autoAscend.on")),e.autoAscend=!e.autoAscend}else if(t===1&&e.highestSingularityCount>=25){let r=i("ascensionAutoToggle");e.autoAscendMode==="c10Completions"?(e.autoAscendMode="realAscensionTime",r.textContent=u.t("corruptions.autoAscend.modeRealTime")):(e.autoAscendMode="c10Completions",r.textContent=u.t("corruptions.autoAscend.modeCompletions"))}},Eo=t=>{if(e.highestSingularityCount>=35){if(t===1){let r=i("openCubes"),n=i("cubeOpensInput");e.autoOpenCubes?(r.textContent=u.t("wowCubes.autoOff"),r.style.border="1px solid red",n.style.border="1px solid red"):(r.textContent=u.t("wowCubes.autoOn",{percent:d(e.openCubes,0)}),r.style.border="1px solid green",n.style.border="1px solid green"),e.autoOpenCubes=!e.autoOpenCubes}else if(t===2){let r=i("openTesseracts"),n=i("tesseractsOpensInput");e.autoOpenTesseracts?(r.textContent=u.t("wowCubes.autoOff"),r.style.border="1px solid red",n.style.border="1px solid red"):(r.textContent=u.t("wowCubes.autoOn",{percent:d(e.openTesseracts,0)}),r.style.border="1px solid green",n.style.border="1px solid green"),e.autoOpenTesseracts=!e.autoOpenTesseracts}else if(t===3){let r=i("openHypercubes"),n=i("hypercubesOpensInput");e.autoOpenHypercubes?(r.textContent=u.t("wowCubes.autoOff"),r.style.border="1px solid red",n.style.border="1px solid red"):(r.textContent=u.t("wowCubes.autoOn",{percent:d(e.openHypercubes,0)}),r.style.border="1px solid green",n.style.border="1px solid green"),e.autoOpenHypercubes=!e.autoOpenHypercubes}else if(t===4){let r=i("openPlatonicCube"),n=i("platonicCubeOpensInput");e.autoOpenPlatonicsCubes?(r.textContent=u.t("wowCubes.autoOff"),r.style.border="1px solid red",n.style.border="1px solid red"):(r.textContent=u.t("wowCubes.autoOn",{percent:d(e.openPlatonicsCubes,0)}),r.style.border="1px solid green",n.style.border="1px solid green"),e.autoOpenPlatonicsCubes=!e.autoOpenPlatonicsCubes}}},Ms=t=>{switch(t){case 1:{let r=Math.floor(Number.parseFloat(i("buyRuneBlessingInput").value))||1;e.runeBlessingBuyAmount=Math.max(r,1),i("buyRuneBlessingToggle").innerHTML=u.t("runes.blessings.buyUpTo",{amount:d(e.runeBlessingBuyAmount)});return}case 2:{let r=Math.floor(Number.parseFloat(i("buyRuneSpiritInput").value))||1;e.runeSpiritBuyAmount=Math.max(r,1),i("buyRuneSpiritToggleValue").innerHTML=u.t("runes.spirits.buyUpTo",{amount:d(e.runeSpiritBuyAmount)});return}}},cf=t=>{let r=i(`tesseractAutoToggle${t}`);e.autoTesseracts[t]?(r.textContent=u.t("general.autoOffBracket"),r.style.border="2px solid red"):(r.textContent=u.t("general.autoOnBracket"),r.style.border="2px solid green"),e.autoTesseracts[t]=!e.autoTesseracts[t]},hn=(t,r)=>{let n=e.prototypeCorruptions[t],a=$a();if(r>0&&n0&&01&&Na(s);Na(o.corruptionTrigger),i("corruptionCleanseConfirm").style.visibility="hidden",e.currentChallenge.ascension===15&&Ae("ascensionChallenge",!1,!0)}Na(t),_a()},uf=t=>{let r=t==="true";e.corruptionShowStats=r,hl()},Zr=t=>{let r=i(`unit${t}`);if(r===null){console.log(t,"platonic needs to fix");return}r.textContent=e.ascStatToggles[t]?"/s":"",t===6&&(r.textContent=""),e.ascStatToggles[t]=!e.ascStatToggles[t]},df=async()=>{let t=await Ee(u.t("wowCubes.hepteractForge.autoCraftPercentagePrompt"));if(t===null)return e.toggles[35]?P(u.t("toggles.percentKeptAt",{x:e.hepteractAutoCraftPercentage})):void 0;let r=t.endsWith("%"),n=Number(r?t.slice(0,-1):t);if(Number.isNaN(n)||!Number.isFinite(n)||!Number.isInteger(n))return P(u.t("general.validation.finiteInt"));if(n<0||n>100)return P(u.t("toggles.percentBetweenInclusive",{x:0,y:100}));if(n===e.hepteractAutoCraftPercentage&&e.toggles[35])return P(u.t("toggles.percentKeptAt",{x:e.hepteractAutoCraftPercentage}));if(e.hepteractAutoCraftPercentage=n,i("autoHepteractPercentage").textContent=u.t("wowCubes.hepteractForge.autoSetting",{x:`${e.hepteractAutoCraftPercentage}`}),e.toggles[35])return P(u.t("toggles.onAscensionHepteractsCraft",{x:e.hepteractAutoCraftPercentage}))},pf=()=>{e.blueberryLoadoutMode==="saveTree"?(e.blueberryLoadoutMode="loadTree",i("blueberryToggleMode").innerHTML=u.t("ambrosia.loadouts.load")):(e.blueberryLoadoutMode="saveTree",i("blueberryToggleMode").innerHTML=u.t("ambrosia.loadouts.save"))},Su=(t=!0)=>{i("alertWrapper").style.display==="block"&&i("ok_alert").click(),(i("confirmWrapper").style.display==="block"||i("promptWrapper").style.display==="block")&&(t?i("ok_confirm").click():i("cancel_confirm").click())};var mf,at=t=>{Ba(mf),mf=It(()=>Bv(t),50)},Bv=t=>{i("resetofferings1").style.display="block";let r=e.currentChallenge.transcension,n=e.currentChallenge.reincarnation,a=Qr(t),s=an("resetofferings1"),l=i("resetofferings2"),c=an("resetcurrency1"),p=i("resetobtainium"),g=i("resetobtainium2"),m=i("resetinfo"),h=i("resetcurrency2");switch(t==="reincarnation"?(p.style.display="block",g.textContent=d(Math.floor(o.obtainiumGain))):(p.style.display="none",g.textContent=""),t==="ascensionChallenge"||t==="ascension"||t==="singularity"?s.style.display=l.style.display="none":s.style.display=l.style.display="block",t){case"prestige":c.src.endsWith(`Pictures/${Be[e.iconSet][0]}/Diamond.png`)||(c.src=`Pictures/${Be[e.iconSet][0]}/Diamond.png`),c.style.display="block",h.textContent=`+${d(o.prestigePointGain)}`,m.textContent=u.t("reset.details.prestige",{amount:d(e.coinsThisPrestige),timeSpent:d(e.prestigecounter)}),m.style.color="turquoise";break;case"transcension":c.src.endsWith(`Pictures/${Be[e.iconSet][0]}/Mythos.png`)||(c.src=`Pictures/${Be[e.iconSet][0]}/Mythos.png`),c.style.display="block",h.textContent=`+${d(o.transcendPointGain)}`,m.textContent=u.t("reset.details.transcension",{amount:d(e.coinsThisTranscension),timeSpent:d(e.transcendcounter)}),m.style.color="var(--orchid-text-color)";break;case"reincarnation":c.src.endsWith(`Pictures/${Be[e.iconSet][0]}/Particle.png`)||(c.src=`Pictures/${Be[e.iconSet][0]}/Particle.png`),c.style.display="block",h.textContent=`+${d(o.reincarnationPointGain)}`,m.textContent=u.t("reset.details.reincarnation",{amount:d(e.transcendShards),timeSpent:d(e.reincarnationcounter)}),m.style.color="limegreen";break;case"acceleratorBoost":c.src.endsWith(`Pictures/${Be[e.iconSet][0]}/Diamond.png`)||(c.src=`Pictures/${Be[e.iconSet][0]}/Diamond.png`),c.style.display="block",h.textContent=`-${d(e.acceleratorBoostCost)}`,m.textContent=u.t("reset.details.acceleratorBoost",{amount:d(e.prestigePoints),required:d(e.acceleratorBoostCost)}),m.style.color="cyan";break;case"transcensionChallenge":c.style.display="none",h.textContent="",r!==0?(m.style.color="aquamarine",m.textContent=u.t("reset.details.transcensionChallenge.in",{n:r,amount:d(e.coinsThisTranscension),required:d(Lt(r,e.challengecompletions[r])),timeSpent:d(e.transcendcounter)})):(m.style.color="var(--crimson-text-color)",m.textContent=u.t("reset.details.transcensionChallenge.out"));break;case"reincarnationChallenge":if(c.style.display="none",h.textContent="",n!==0){let b=n>=9?"coins":"transcendShards";m.style.color="silver",m.textContent=u.t(`reset.details.reincarnationChallenge.in.${b}`,{n,amount:d(e[b]),required:d(Lt(n,e.challengecompletions[n],n)),timeSpent:d(e.reincarnationcounter)})}else m.style.color="var(--crimson-text-color)",m.textContent=u.t("reset.details.reincarnationChallenge.out");break;case"ascensionChallenge":c.style.display="none",h.textContent="",m.textContent=u.t("reset.details.ascensionChallenge"),m.style.color="gold";break;case"ascension":c.style.display="none",h.textContent="",m.textContent=u.t("reset.details.ascension",{cubeAmount:d(Xr()[4],0,!0),timeSpent:d(e.ascensionCounter,0,!1),realTimeSpent:d(e.ascensionCounterRealReal,0,!1)}),m.style.color="gold";break;case"singularity":c.style.display="none",h.textContent="",m.textContent=u.t("reset.details.singularity",{gqAmount:d(Wt(),2,!0),timeSpent:d(e.singularityCounter,0,!1)}),m.style.color="lightgoldenrodyellow"}i("resetofferings2").textContent=`+${d(a)}`},mr=t=>{let r=null;t===1?(r=Number.parseFloat(i("prestigeamount").value)||0,e.prestigeamount=Math.max(r,0)):t===2?(r=Number.parseFloat(i("transcendamount").value)||0,e.transcendamount=Math.max(r,0)):t===3?(r=Number.parseFloat(i("reincarnationamount").value)||0,e.reincarnationamount=Math.max(r,0)):t===4?(r=Math.floor(Number.parseFloat(i("ascensionAmount").value))||1,e.autoAscendThreshold=Math.max(r,1)):t===5&&(r=Number.parseFloat(i("autoAntSacrificeAmount").value)||0,e.autoAntSacTimer=Math.max(r,0))},vl=()=>{let t=Math.floor(Number.parseFloat(i("tesseractAmount").value))||0;e.tesseractAutoBuyerAmount=Math.max(t,0)},Yr=t=>{let r=null;t===1?(r=Number(i("cubeOpensInput").value)||0,e.openCubes=Math.max(Math.min(r,100),0)):t===2?(r=Number(i("tesseractsOpensInput").value)||0,e.openTesseracts=Math.max(Math.min(r,100),0)):t===3?(r=Number(i("hypercubesOpensInput").value)||0,e.openHypercubes=Math.max(Math.min(r,100),0)):t===4&&(r=Number(i("platonicCubeOpensInput").value)||0,e.openPlatonicsCubes=Math.max(Math.min(r,100),0))},Rv=(t,r="unknown")=>{let n=Qr(t),a=["enterChallenge","leaveChallenge"].includes(r);if(t==="prestige"){let s={seconds:e.prestigecounter,date:Date.now(),offerings:n,kind:"prestige",diamonds:o.prestigePointGain.toString()};yt.emit("historyAdd","reset",s)}else if(t==="transcension"||t==="transcensionChallenge"){let s={seconds:e.transcendcounter,date:Date.now(),offerings:n,kind:"transcend",mythos:o.transcendPointGain.toString()};yt.emit("historyAdd","reset",s)}else if(t==="reincarnation"||t==="reincarnationChallenge"){if(!a||o.reincarnationPointGain.gte(e.reincarnationPoints.div(10))){let s={seconds:e.reincarnationcounter,date:Date.now(),offerings:n,kind:"reincarnate",particles:o.reincarnationPointGain.toString(),obtainium:o.obtainiumGain};yt.emit("historyAdd","reset",s)}}else if((t==="ascension"||t==="ascensionChallenge")&&e.challengecompletions[10]>0){let s=Xr(),l={seconds:e.ascensionCounter,date:Date.now(),c10Completions:e.challengecompletions[10],usedCorruptions:e.usedCorruptions.slice(0),corruptionScore:s[3],wowCubes:s[4],wowTesseracts:s[5],wowHypercubes:s[6],wowPlatonicCubes:s[7],wowHepteracts:s[8],kind:"ascend"};r!=="enterChallenge"&&e.currentChallenge.ascension!==0&&(l.currentChallenge=e.currentChallenge.ascension),yt.emit("historyAdd","ascend",l)}},Pe=(t,r=!1,n="unknown")=>{if(Rv(t,n),Gg(t),yl(1),e.coins=new f("102"),e.coinsThisPrestige=new f("100"),e.firstOwnedCoin=0,e.firstGeneratedCoin=new f("0"),e.firstCostCoin=new f("100"),e.secondOwnedCoin=0,e.secondGeneratedCoin=new f("0"),e.secondCostCoin=new f("1e3"),e.thirdOwnedCoin=0,e.thirdGeneratedCoin=new f("0"),e.thirdCostCoin=new f("2e4"),e.fourthOwnedCoin=0,e.fourthGeneratedCoin=new f("0"),e.fourthCostCoin=new f("4e5"),e.fifthOwnedCoin=0,e.fifthGeneratedCoin=new f("0"),e.fifthCostCoin=new f("8e6"),e.firstGeneratedDiamonds=new f("0"),e.secondGeneratedDiamonds=new f("0"),e.thirdGeneratedDiamonds=new f("0"),e.fourthGeneratedDiamonds=new f("0"),e.fifthGeneratedDiamonds=new f("0"),e.multiplierCost=new f("1e4"),e.multiplierBought=0,e.acceleratorCost=new f("500"),e.acceleratorBought=0,e.prestigeCount+=1,e.prestigePoints=e.prestigePoints.add(o.prestigePointGain),e.prestigeShards=new f("0"),e.prestigenoaccelerator=!0,e.prestigenomultiplier=!0,e.prestigenocoinupgrades=!0,e.highestSingularityCount===0&&(t==="prestige"&&!e.unlocks.prestige&&(i("prestigebtn").style.boxShadow=""),t==="transcension"&&!e.unlocks.transcend&&(i("transcendbtn").style.boxShadow=""),t==="reincarnation"&&!e.unlocks.reincarnate&&(i("reincarnatebtn").style.boxShadow=""),t==="ascension"&&e.ascensionCount===0&&(i("ascendbtn").style.boxShadow="")),e.unlocks.prestige=!0,e.prestigecounter.5&&(e.firstOwnedDiamonds+=1),e.achievements[85]>.5&&(e.secondOwnedDiamonds+=1),e.achievements[92]>.5&&(e.thirdOwnedDiamonds+=1),e.achievements[99]>.5&&(e.fourthOwnedDiamonds+=1),e.achievements[106]>.5&&(e.fifthOwnedDiamonds+=1),e.achievements[4]>.5&&(e.upgrades[81]=1),e.achievements[11]>.5&&(e.upgrades[82]=1),e.achievements[18]>.5&&(e.upgrades[83]=1),e.achievements[25]>.5&&(e.upgrades[84]=1),e.achievements[32]>.5&&(e.upgrades[85]=1),e.achievements[80]>.5&&(e.upgrades[87]=1),e.transcendcounter10&&e.platonicUpgrades[11]>0&&(e.prestigePoints=e.prestigePoints.add(o.reincarnationPointGain)),t==="reincarnation"||t==="reincarnationChallenge"||t==="ascension"||t==="ascensionChallenge"||t==="singularity"){e.ascensionCount>0&&e.achievements[183]<1&&Ts(1),e.researchPoints=Math.min(1e300,e.researchPoints+Math.floor(o.obtainiumGain));let s=o.obtainiumGain/(1+e.reincarnationcounter);if(s>e.obtainiumpersecond&&(e.obtainiumpersecond=s),e.currentChallenge.transcension=0,yl(3),e.coinsThisReincarnation=new f("100"),e.firstOwnedMythos=0,e.firstCostMythos=new f("1"),e.secondOwnedMythos=0,e.secondCostMythos=new f("1e2"),e.thirdOwnedMythos=0,e.thirdCostMythos=new f("1e4"),e.fourthOwnedMythos=0,e.fourthCostMythos=new f("1e8"),e.fifthOwnedMythos=0,e.fifthCostMythos=new f("1e16"),e.firstGeneratedParticles=new f("0"),e.secondGeneratedParticles=new f("0"),e.thirdGeneratedParticles=new f("0"),e.fourthGeneratedParticles=new f("0"),e.fifthGeneratedParticles=new f("0"),e.reincarnationCount+=1,e.transcendPoints=new f("0"),e.reincarnationPoints=e.reincarnationPoints.add(o.reincarnationPointGain),e.reincarnationShards=new f("0"),e.challengecompletions[1]=0,e.challengecompletions[2]=0,e.challengecompletions[3]=0,e.challengecompletions[4]=0,e.challengecompletions[5]=0,o.reincarnationPointGain=new f("0"),e.shopUpgrades.instantChallenge>0&&e.currentChallenge.reincarnation===0&&(e.challengecompletions[1]=e.highestchallengecompletions[1],e.challengecompletions[2]=e.highestchallengecompletions[2],e.challengecompletions[3]=e.highestchallengecompletions[3],e.challengecompletions[4]=e.highestchallengecompletions[4],e.challengecompletions[5]=e.highestchallengecompletions[5]),e.reincarnatenocoinupgrades=!0,e.reincarnatenocoinorprestigeupgrades=!0,e.reincarnatenocoinprestigeortranscendupgrades=!0,e.reincarnatenocoinprestigetranscendorgeneratorupgrades=!0,e.reincarnatenoaccelerator=!0,e.reincarnatenomultiplier=!0,e.reincarnationcounter.5){let l=e.autoResearch===200?.01:0;Fr(e.autoResearch,!0,l)}He(),Bt()}if(t==="ascension"||t==="ascensionChallenge"||t==="singularity"){let s=Xr();e.challengecompletions[10]>0&&Ts(3,s[3]),e.currentChallenge.transcension=0,e.currentChallenge.reincarnation=0,t==="ascensionChallenge"&&e.currentChallenge.ascension>10&&e.highestSingularityCount>=2&&e.autoChallengeToggles[10]?e.autoChallengeIndex=10:e.autoChallengeIndex=1,pr("START"),o.autoChallengeTimerIncrement=0,Iv(),Lu(),Nv(),e.reincarnationPoints=new f("0"),e.reincarnationShards=new f("0"),e.obtainiumpersecond=0,e.maxobtainiumpersecond=0,e.offeringpersecond=0,e.antSacrificePoints=0,e.antSacrificeTimer=0,e.antSacrificeTimerReal=0,e.antUpgrades[12-1]=0;for(let c=61;c<=80;c++)e.upgrades[c]=0;for(let c=94;c<=100;c++)e.upgrades[c]=0;e.firstOwnedParticles=0,e.secondOwnedParticles=0,e.thirdOwnedParticles=0,e.fourthOwnedParticles=0,e.fifthOwnedParticles=0,e.firstCostParticles=new f("1"),e.secondCostParticles=new f("100"),e.thirdCostParticles=new f("1e4"),e.fourthCostParticles=new f("1e8"),e.fifthCostParticles=new f("1e16"),e.runeexp=[0,0,0,0,0,e.runeexp[5],e.runeexp[6]],e.runelevels=[0,0,0,0,0,e.runelevels[5],e.runelevels[6]],e.runeshards=0,e.crystalUpgrades=[0,0,0,0,0,0,0,0],e.runelevels[0]=3*e.cubeUpgrades[26],e.runelevels[1]=3*e.cubeUpgrades[26],e.runelevels[2]=3*e.cubeUpgrades[26],e.runelevels[3]=3*e.cubeUpgrades[26],e.runelevels[4]=3*e.cubeUpgrades[26],e.cubeUpgrades[27]===1&&(e.firstOwnedParticles=1,e.secondOwnedParticles=1,e.thirdOwnedParticles=1,e.fourthOwnedParticles=1,e.fifthOwnedParticles=1),e.challengecompletions[10]>0&&e.ascensionCounter>0&&(e.ascensionCount+=Mo(),isFinite(s[4])&&isFinite(s[5])&&isFinite(s[6])&&isFinite(s[7])&&isFinite(s[8])&&(e.wowCubes.add(s[4]),e.wowTesseracts.add(s[5]),e.wowHypercubes.add(s[6]),e.wowPlatonicCubes.add(s[7]),e.wowAbyssals=Math.min(1e300,e.wowAbyssals+s[8])));for(let c=1;c<=10;c++)e.challengecompletions[c]=0,e.highestchallengecompletions[c]=0;e.challengecompletions[6]=e.highestchallengecompletions[6]=e.cubeUpgrades[49],e.challengecompletions[7]=e.highestchallengecompletions[7]=e.cubeUpgrades[49],e.challengecompletions[8]=e.highestchallengecompletions[8]=e.cubeUpgrades[49],i(`res${e.autoResearch||1}`).classList.remove("researchRoomba"),e.roombaResearchIndex=0,e.autoResearch=1;for(let c=1;c<=200;c++){let p=`res${c}`;e.researches[c]>.5&&e.researches[c].5&&e.researches[c]>=o.researchMaxLevels[c]?Tt(p,["researchMaxed"],["researchAvailable","researchPurchased","researchPurchasedAvailable","researchUnpurchased"]):Tt(p,["researchUnpurchased"],["researchAvailable","researchPurchased","researchPurchasedAvailable","researchMaxed"])}Bt(),He(),Kn(),Pu(),Ar(),Ts(1),e.ascensionCounter=0,e.ascensionCounterReal=0,e.ascensionCounterRealReal=0,Kt(),ct(0),ct(1),ct(2),ct(3),ct(4),ct(5),ct(6),Gt(),ra(),ta(),e.cubeUpgrades[4]===1&&(e.upgrades[94]=1,e.upgrades[95]=1,e.upgrades[96]=1,e.upgrades[97]=1,e.upgrades[98]=1),e.cubeUpgrades[5]===1&&(e.upgrades[99]=1),e.cubeUpgrades[6]===1&&(e.upgrades[100]=1);for(let c=61;c<=80;c++)i(`upg${c}`).style.backgroundColor="";for(let c=94;c<=100;c++)e.upgrades[c]===0&&(i(`upg${c}`).style.backgroundColor="");let l=$a();if(e.usedCorruptions=e.prototypeCorruptions.map((c,p)=>p>=2&&p<=9?Math.min(l*(e.challengecompletions[wl(p)]>0||e.singularityUpgrades.platonicTau.getEffect().bonus?1:0),c):c),e.usedCorruptions[1]=0,e.prototypeCorruptions[1]=0,e.currentChallenge.ascension===15&&(t==="ascension"||t==="ascensionChallenge")){e.usedCorruptions[0]=0,e.prototypeCorruptions[0]=0;for(let c=2;c<=9;c++)e.usedCorruptions[c]=11}Ga(),hf(!1)}if(t==="ascension"||t==="ascensionChallenge"){let s=Eg(),l=s.length+(e.overfluxOrbsAutoBuy?1:0);if(e.highestSingularityCount>=1&&l>0){let c=Math.floor(e.wowAbyssals/l*(e.hepteractAutoCraftPercentage/100));for(let p of s)p.autoCraft(c);if(e.overfluxOrbsAutoBuy){let p=Math.floor(c/25e4);e.wowAbyssals-25e4*p>=0&&(e.overfluxOrbs+=p,e.overfluxPowder+=e.shopUpgrades.powderAuto*Lr().mult*p/100,e.wowAbyssals-=25e4*p),e.wowAbyssals<0&&(e.wowAbyssals=0)}}if(e.researches[190]>0&&e.tesseractAutoBuyerToggle===1&&e.resettoggle4===2){let c=[null,null,null,null,null];for(let h=1;h<=5;h++)e.autoTesseracts[h]&&(c[h-1]=e[`ascendBuilding${h}`].owned);let p=100-Math.min(100,e.tesseractAutoBuyerAmount),g=Number(e.wowTesseracts)*p/100,m=Cl(c,g);for(let h=5;h>=1;h--){let b=c[h-1],C=m[h-1];b!==null&&C!==null&&C!==b&&Da(h,C-b)}}Dg(),Tg(),e.highestSingularityCount>=35&&(e.autoOpenCubes&&e.openCubes!==0&&e.cubeUpgrades[51]>0&&e.wowCubes.open(Math.floor(Number(e.wowCubes)*e.openCubes/100),!1),e.autoOpenTesseracts&&e.openTesseracts!==0&&e.challengecompletions[11]>0&&(e.tesseractAutoBuyerToggle!==1||e.resettoggle4===2)&&e.wowTesseracts.open(Math.floor(Number(e.wowTesseracts)*e.openTesseracts/100),!1),e.autoOpenHypercubes&&e.openHypercubes!==0&&e.challengecompletions[13]>0&&e.wowHypercubes.open(Math.floor(Number(e.wowHypercubes)*e.openHypercubes/100),!1),e.autoOpenPlatonicsCubes&&e.openPlatonicsCubes!==0&&e.challengecompletions[14]>0&&e.wowPlatonicCubes.open(Math.floor(Number(e.wowPlatonicCubes)*e.openPlatonicsCubes/100),!1))}if(e.unlocks.prestige=!0,(t==="transcension"||t==="transcensionChallenge")&&(e.unlocks.transcend=!0),(t==="reincarnation"||t==="reincarnationChallenge")&&(e.unlocks.reincarnate=!0),t==="singularity"){e.unlocks.coinone=!1,e.unlocks.cointwo=!1,e.unlocks.cointhree=!1,e.unlocks.coinfour=!1,e.unlocks.generation=!1,e.unlocks.prestige=!1,e.unlocks.transcend=!1,e.unlocks.reincarnate=!1,e.unlocks.rrow1=!1,e.unlocks.rrow2=!1,e.unlocks.rrow3=!1,e.unlocks.rrow4=!1,e.ascendBuilding1.owned=0,e.ascendBuilding1.generated=new f("0"),e.ascendBuilding2.owned=0,e.ascendBuilding2.generated=new f("0"),e.ascendBuilding3.owned=0,e.ascendBuilding3.generated=new f("0"),e.ascendBuilding4.owned=0,e.ascendBuilding4.generated=new f("0"),e.ascendBuilding5.owned=0,e.ascendBuilding5.generated=new f("0"),e.constantUpgrades=[null,0,0,0,0,0,0,0,0,0,0],e.wowCubes=new tr(0),e.wowTesseracts=new tr(0),e.wowHypercubes=new tr(0),e.wowTesseracts=new tr(0),e.wowAbyssals=0;for(let s=1;s<=50;s++)e.cubeUpgrades[s]=0}r||Oe(),(t==="transcensionChallenge"||t==="reincarnationChallenge"||t==="ascensionChallenge")&&Sr(),Oo()},ff=()=>{e.highestSingularityCount>=1&&R(274),e.highestSingularityCount>=2&&R(275),e.highestSingularityCount>=3&&R(276),e.highestSingularityCount>=4&&R(277),e.highestSingularityCount>=5&&R(278),e.highestSingularityCount>=7&&R(279),e.highestSingularityCount>=10&&R(280)},hf=(t=!0)=>{if(e.achievements[275]>0){t&&(e.prestigeCount=1,e.transcendCount=1),e.transcendPoints=new f("1001"),e.unlocks.coinone=!0,e.unlocks.cointwo=!0,e.unlocks.cointhree=!0,e.unlocks.coinfour=!0,e.unlocks.prestige=!0,e.unlocks.generation=!0,e.unlocks.transcend=!0;for(let s=0;s<5;s++)R(4+7*s);R(36),R(43)}if(e.achievements[276]>0){e.currentChallenge.ascension!==12&&(t&&(e.reincarnationCount=1),e.reincarnationPoints=new f("10")),e.unlocks.reincarnate=!0,e.unlocks.rrow1=!0,e.researches[47]=1;for(let s=0;s<2;s++)for(let l=0;l<5;l++)R(78+s+7*l);for(let s=0;s<7;s++)R(57+s),R(64+s),R(71+s);R(37),R(38),R(44),R(50),R(80),R(87)}e.achievements[277]>0&&(e.currentChallenge.ascension!==14&&(e.researchPoints=Math.floor(500*Le("Offering")*Le("Researches"))),e.currentChallenge.ascension!==12&&(e.reincarnationPoints=new f("1e16")),e.challengecompletions[6]=1,e.highestchallengecompletions[6]=1,R(113));let r=["offeringAuto","offeringEX","obtainiumAuto","obtainiumEX","antSpeed","cashGrab"];if(e.achievements[278]>0&&t){for(let s of r)e.shopUpgrades[s]=10;e.cubeUpgrades[7]=1}if(e.achievements[279]>0&&(e.challengecompletions[7]=1,e.highestchallengecompletions[7]=1,R(120),e.currentChallenge.ascension!==12&&(e.reincarnationPoints=new f("1e100"))),e.achievements[280]>0){R(124),R(127),e.challengecompletions[8]=1,e.highestchallengecompletions[8]=1,e.cubeUpgrades[8]=1,e.cubeUpgrades[4]=1,e.cubeUpgrades[5]=1,e.cubeUpgrades[6]=1,e.firstOwnedAnts=1;for(let s=0;s<7;s++)R(176+s)}if(e.highestSingularityCount>10&&(e.cubeUpgrades[9]=1),e.highestSingularityCount>=15&&(e.challengecompletions[8]=5,e.highestchallengecompletions[8]=5,e.currentChallenge.ascension!==12&&(e.reincarnationPoints=new f("2.22e2222")),e.fifthOwnedAnts=1,e.cubeUpgrades[20]=1),e.highestSingularityCount>=20){let s=["offeringAuto","offeringEX","obtainiumAuto","obtainiumEX","antSpeed","cashGrab"];e.challengecompletions[9]=1,e.highestchallengecompletions[9]=1,R(134),e.antPoints=new f("1e100"),e.antUpgrades[11]=1;for(let l of s)e.shopUpgrades[l]=pe[l].maxLevel}if(e.highestSingularityCount>=25&&(e.eighthOwnedAnts=1),e.highestSingularityCount>=30&&(e.researches[130]=1,e.researches[135]=1,e.researches[145]=1),e.highestSingularityCount>=100&&t&&(e.cubeUpgrades[51]=1,qc()),e.highestSingularityCount>=244&&(e.cubeUpgrades[71]=1,e.cubeUpgrades[72]=1),e.singularityUpgrades.platonicAlpha.getEffect().bonus&&e.platonicUpgrades[5]===0&&(e.platonicUpgrades[5]=1,no(5)),t)for(let s=1;s<=15;s++)fr(s);if(yl(3),t)for(let s=1;s0&&ns(s);ku(),Oe()},ku=()=>{let t=e.achievements[278]>0,r=["offeringAuto","offeringEX","obtainiumAuto","obtainiumEX","antSpeed","cashGrab"];for(let c of r)pe[c].refundMinimumLevel=t?10:c.endsWith("Auto")?1:0;let n=e.highestSingularityCount>=20,a=["offeringAuto","offeringEX","obtainiumAuto","obtainiumEX","antSpeed","cashGrab"];for(let c of a)pe[c].refundable=!n;let s=e.highestSingularityCount>=51,l=["seasonPass","seasonPass2","seasonPass3","seasonPassY","chronometer","chronometer2"];for(let c of l)pe[c].refundable=!s},ms=async(t=-1)=>{var h,b,C,v,x,B,U,k,L;if(e.runelevels[6]===0&&t===-1)return P("You nearly triggered a double singularity bug! Oh no! Luckily, our staff prevented this from happening.");if(t===-1){let E=Object.values(e.cubeBlessings),T=Object.values(e.tesseractBlessings),S=Object.values(e.hypercubeBlessings),I=Object.values(e.platonicBlessings),N={seconds:e.singularityCounter,date:Date.now(),singularityCount:e.singularityCount,quarks:e.quarksThisSingularity,c15Score:e.challenge15Exponent,goldenQuarks:Wt(),wowTribs:ae(E),tessTribs:ae(T),hyperTribs:ae(S),platTribs:ae(I),octeracts:e.totalWowOcteracts,quarkHept:e.hepteractCrafts.quark.BAL,kind:"singularity"};yt.emit("historyAdd","singularity",N)}if(e.runelevels[6]=0,e.goldenQuarks+=Wt(),t===-1){let E=1+ua();e.singularityCount+=E,e.singularityCount>=e.highestSingularityCount&&(e.highestSingularityCount=e.singularityCount,e.highestSingularityCount===5&&(e.singularityUpgrades.goldenQuarks3.freeLevels+=1),e.highestSingularityCount===10&&(e.singularityUpgrades.goldenQuarks3.freeLevels+=2))}else e.singularityCount=t;e.totalQuarksEver+=e.quarksThisSingularity,await Hi(!0);let{data:r,success:n}=fs.safeParse(M);Nn(n),bn(0),ve(0,{page:0}),ve(3,{page:0}),ve(4,{page:0}),ve(7,{page:0}),ve(8,{page:0}),ve(9,{page:0}),ve(10,{page:0}),r.history.singularity=e.history.singularity,r.totalQuarksEver=e.totalQuarksEver,r.singularityCount=e.singularityCount,r.highestSingularityCount=e.highestSingularityCount,r.goldenQuarks=e.goldenQuarks,r.shopUpgrades=e.shopUpgrades,e.singularityChallenges.limitedTime.rewards.preserveQuarks?r.worlds=Number(e.worlds):(e.worlds.reset(),r.worlds=Number(r.worlds)),r.singularityUpgrades=Object.fromEntries(Object.entries(e.singularityUpgrades).map(([E,T])=>[E,{level:T.level,goldenQuarksInvested:T.goldenQuarksInvested,toggleBuy:T.toggleBuy,freeLevels:T.freeLevels}])),r.octeractUpgrades=Object.fromEntries(Object.entries(e.octeractUpgrades).map(([E,T])=>[E,{level:T.level,octeractsInvested:T.octeractsInvested,toggleBuy:T.toggleBuy,freeLevels:T.freeLevels}])),r.blueberryUpgrades=Object.fromEntries(Object.entries(e.blueberryUpgrades).map(([E,T])=>[E,{level:T.level,ambrosiaInvested:T.ambrosiaInvested,blueberriesInvested:T.blueberriesInvested,toggleBuy:T.toggleBuy,freeLevels:T.freeLevels}])),r.spentBlueberries=e.spentBlueberries,r.autoChallengeToggles=e.autoChallengeToggles,r.autoChallengeTimer=e.autoChallengeTimer,r.saveString=e.saveString,r.corruptionLoadouts=e.corruptionLoadouts,r.corruptionLoadoutNames=e.corruptionLoadoutNames,r.corruptionShowStats=e.corruptionShowStats,r.toggles=e.toggles,r.retrychallenges=e.retrychallenges,r.resettoggle1=e.resettoggle1,r.resettoggle2=e.resettoggle2,r.resettoggle3=e.resettoggle3,r.resettoggle4=e.resettoggle4,r.coinbuyamount=e.coinbuyamount,r.crystalbuyamount=e.crystalbuyamount,r.mythosbuyamount=e.mythosbuyamount,r.particlebuyamount=e.particlebuyamount,r.offeringbuyamount=e.offeringbuyamount,r.tesseractbuyamount=e.tesseractbuyamount,r.shoptoggles=e.shoptoggles,r.autoSacrificeToggle=e.autoSacrificeToggle,r.autoBuyFragment=e.autoBuyFragment,r.autoFortifyToggle=e.autoFortifyToggle,r.autoEnhanceToggle=e.autoEnhanceToggle,r.autoResearchToggle=e.autoResearchToggle,r.autoResearchMode=e.autoResearchMode,r.dailyCodeUsed=e.dailyCodeUsed,r.runeBlessingBuyAmount=e.runeBlessingBuyAmount,r.runeSpiritBuyAmount=e.runeSpiritBuyAmount,r.prestigeamount=e.prestigeamount,r.transcendamount=e.transcendamount,r.reincarnationamount=e.reincarnationamount,r.talismanOne=e.talismanOne,r.talismanTwo=e.talismanTwo,r.talismanThree=e.talismanThree,r.talismanFour=e.talismanFour,r.talismanFive=e.talismanFive,r.talismanSix=e.talismanSix,r.talismanSeven=e.talismanSeven,r.buyTalismanShardPercent=e.buyTalismanShardPercent,r.antMax=e.antMax,r.autoAntSacrifice=e.autoAntSacrifice,r.autoAntSacrificeMode=e.autoAntSacrificeMode,r.autoAntSacTimer=e.autoAntSacTimer,r.autoAscend=e.autoAscend,r.autoAscendMode=e.autoAscendMode,r.autoAscendThreshold=e.autoAscendThreshold,r.autoResearch=0,r.autoTesseracts=e.autoTesseracts,r.tesseractAutoBuyerToggle=e.tesseractAutoBuyerToggle,r.tesseractAutoBuyerAmount=e.tesseractAutoBuyerAmount,r.autoOpenCubes=e.autoOpenCubes,r.openCubes=e.openCubes,r.autoOpenTesseracts=e.autoOpenTesseracts,r.openTesseracts=e.openTesseracts,r.autoOpenHypercubes=e.autoOpenHypercubes,r.openHypercubes=e.openHypercubes,r.autoOpenPlatonicsCubes=e.autoOpenPlatonicsCubes,r.openPlatonicsCubes=e.openPlatonicsCubes,r.historyShowPerSecond=e.historyShowPerSecond,r.exporttest=typeof e.exporttest=="boolean"?e.exporttest:e.exporttest==="YES!",r.dayTimer=e.dayTimer,r.dayCheck=(b=(h=e.dayCheck)==null?void 0:h.toISOString())!=null?b:null,r.ascStatToggles=e.ascStatToggles,r.hepteractAutoCraftPercentage=e.hepteractAutoCraftPercentage,r.autoWarpCheck=e.autoWarpCheck,r.shopBuyMaxToggle=e.shopBuyMaxToggle,r.shopHideToggle=e.shopHideToggle,r.shopConfirmationToggle=e.shopConfirmationToggle,r.researchBuyMaxToggle=e.researchBuyMaxToggle,r.cubeUpgradesBuyMaxToggle=e.cubeUpgradesBuyMaxToggle,r.wowOcteracts=e.wowOcteracts,r.totalWowOcteracts=e.totalWowOcteracts,r.overfluxOrbsAutoBuy=e.overfluxOrbsAutoBuy,r.hotkeys=e.hotkeys,r.theme=e.theme,r.notation=e.notation,r.firstPlayed=e.firstPlayed,r.autoCubeUpgradesToggle=e.autoCubeUpgradesToggle,r.autoPlatonicUpgradesToggle=e.autoPlatonicUpgradesToggle,r.insideSingularityChallenge=e.insideSingularityChallenge,r.ultimatePixels=e.ultimatePixels,r.ultimateProgress=e.ultimateProgress,r.cubeUpgradeRedBarFilled=e.cubeUpgradeRedBarFilled,r.singularityChallenges=Object.fromEntries(Object.entries(e.singularityChallenges).map(([E,T])=>[E,{completions:T.completions,highestSingularityCompleted:T.highestSingularityCompleted,enabled:T.enabled}])),r.iconSet=e.iconSet,r.hepteractCrafts.quark=e.hepteractCrafts.quark;for(let E of Object.keys(e.hepteractCrafts))if(E!=="quark"){let T=E;r.hepteractCrafts[T].AUTO=e.hepteractCrafts[T].AUTO}r.ambrosia=e.ambrosia,r.lifetimeAmbrosia=e.lifetimeAmbrosia,r.visitedAmbrosiaSubtab=e.visitedAmbrosiaSubtab,r.blueberryTime=e.blueberryTime,r.blueberryLoadouts=e.blueberryLoadouts,r.blueberryLoadoutMode=e.blueberryLoadoutMode,r.wowCubes=Number(e.wowCubes),r.wowTesseracts=Number(e.wowTesseracts),r.wowHypercubes=Number(e.wowHypercubes),r.wowPlatonicCubes=Number(e.wowPlatonicCubes);let a=(C=e.codes.get(42))!=null?C:!1,s=(v=e.codes.get(43))!=null?v:!1,l=(x=e.codes.get(44))!=null?x:!1,c=(B=e.codes.get(45))!=null?B:!1,p=(U=e.codes.get(46))!=null?U:!1,g=(k=e.codes.get(47))!=null?k:!1,m=(L=e.codes.get(48))!=null?L:!1;Ra(btoa(JSON.stringify(r)),!0),e.codes.set(39,!0),e.codes.set(40,!0),e.codes.set(41,!0),e.codes.set(42,a),e.codes.set(43,s),e.codes.set(44,l),e.codes.set(45,c),e.codes.set(46,p),e.codes.set(47,g),e.codes.set(48,m),hf(),e.rngCode=Date.now(),e.promoCodeTiming.time=Date.now(),hr()},yl=t=>{if(t>2.5){for(let r=41;r<61;r++)r!==46&&(e.upgrades[r]=0);e.researches[41]===0&&(e.upgrades[46]=0),e.researches[41]<.5&&(e.upgrades[88]=0),e.achievements[50]===0&&(e.upgrades[89]=0),e.researches[42]<.5&&(e.upgrades[90]=0),e.researches[43]<.5&&(e.upgrades[91]=0),e.researches[44]<.5&&(e.upgrades[92]=0),e.researches[45]<.5&&(e.upgrades[93]=0),e.upgrades[116]=0,e.upgrades[117]=0,e.upgrades[118]=0,e.upgrades[119]=0,e.upgrades[120]=0}for(let r=1;r<=20;r++)e.upgrades[r]=0;for(let r=121,n=106;r<=125;r++,n++)e.upgrades[r]=0,e.upgrades[n]=0;if(t>1.5&&(e.achievements[4]<.5&&(e.upgrades[81]=0),e.achievements[11]<.5&&(e.upgrades[82]=0),e.achievements[18]<.5&&(e.upgrades[83]=0),e.achievements[25]<.5&&(e.upgrades[84]=0),e.achievements[32]<.5&&(e.upgrades[85]=0),e.achievements[87]<.5&&(e.upgrades[86]=0),e.achievements[80]<.5&&(e.upgrades[87]=0),e.upgrades[101]=0,e.upgrades[102]=0,e.upgrades[103]=0,e.upgrades[104]=0,e.upgrades[105]=0),t>1.5){for(let r=21;r<41;r++)e.upgrades[r]=0;e.upgrades[111]=0,e.upgrades[112]=0,e.upgrades[113]=0,e.upgrades[114]=0,e.upgrades[115]=0}if(t>1.5){e.crystalUpgrades=[0,0,0,0,0,0,0,0],e.crystalUpgradesCost=[7,15,20,40,100,200,500,1e3],Au();let r=0;r+=Math.floor(o.rune3level*o.effectiveLevelMult/16)*100/100,e.upgrades[73]>.5&&e.currentChallenge.reincarnation!==0&&(r+=10),e.crystalUpgrades=[r,r,r,r,r,r,r,r]}e.achievements[87]>.5&&(e.upgrades[86]=1);for(let r=1;r<=125;r++)Ft(r,!0)},Lu=()=>{e.firstOwnedAnts=0,e.secondOwnedAnts=0,e.thirdOwnedAnts=0,e.fourthOwnedAnts=0,e.fifthOwnedAnts=0,e.sixthOwnedAnts=0,e.seventhOwnedAnts=0,e.eighthOwnedAnts=0,e.firstGeneratedAnts=new f("0"),e.secondGeneratedAnts=new f("0"),e.thirdGeneratedAnts=new f("0"),e.fourthGeneratedAnts=new f("0"),e.fifthGeneratedAnts=new f("0"),e.sixthGeneratedAnts=new f("0"),e.seventhGeneratedAnts=new f("0"),e.eighthGeneratedAnts=new f("0"),e.firstCostAnts=new f("1e700"),e.secondCostAnts=new f("3"),e.thirdCostAnts=new f("100"),e.fourthCostAnts=new f("1e4"),e.fifthCostAnts=new f("1e12"),e.sixthCostAnts=new f("1e36"),e.seventhCostAnts=new f("1e100"),e.eighthCostAnts=new f("1e300"),e.cubeUpgrades[48]>0&&(e.firstOwnedAnts=1,e.firstCostAnts=new f("1e741"));let t=e.antUpgrades[12-1];e.antUpgrades=[0,0,0,0,0,0,0,0,0,0,0,t],e.antPoints=new f("1"),e.currentChallenge.ascension===12&&(e.antPoints=new f("7")),Bt(),He()},Iv=()=>{e.researchPoints=0;let t=[6,7,8,9,10,11,12,13,14,15,16,17,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,51,52,53,54,55,56,57,58,59,60,62,63,64,65,66,67,68,69,70,76,81,85,86,87,88,89,90,91,92,93,94,96,97,98,101,102,103,104,106,107,108,109,110,116,117,118,121,122,123,126,127,128,129,131,132,133,134,136,137,139,141,142,143,144,146,147,148,149,151,152,154,156,157,158,159,161,162,163,164,166,167,169,171,172,173,174,176,177,178,179,181,182,184,186,187,188,189,191,192,193,194,196,197,199];e.highestSingularityCount<25&&t.push(138,153,168,183,198);for(let r of t)e.researches[r]=0},Nv=()=>{e.talismanLevels=[0,0,0,0,0,0,0],e.talismanRarity=[1,1,1,1,1,1,1],e.talismanShards=0,e.commonFragments=0,e.uncommonFragments=0,e.rareFragments=0,e.epicFragments=0,e.legendaryFragments=0,e.mythicalFragments=0};var xl=()=>{let t=1;return t+=Math.min(1e15,o.rune4level*o.effectiveLevelMult/160),t+=(e.researches[56]+e.researches[57]+e.researches[58]+e.researches[59]+e.researches[60])/200,t+=_("transcend",e.challengecompletions[4])/200,t+=Math.min(99999.9,3*(e.antUpgrades[7-1]+o.bonusant7)/100),t},yn=t=>{--t;let r=500,n=new f(r);if(n=n.times(f.pow(4/o.costDivisor,t)),t>125+5*_("transcend",e.challengecompletions[4])){let s=t-125-5*_("transcend",e.challengecompletions[4]),l=new f(s).factorial(),c=f.pow(4,s);n=n.times(c.times(l))}if(t>2e3+5*_("transcend",e.challengecompletions[4])){let s=t-2e3-5*_("transcend",e.challengecompletions[4]),l=s*(s+1)/2;n=n.times(f.pow(2,l))}if(e.currentChallenge.transcension===4){let s=t*(t+1)/2;n=n.times(f.pow(10,s))}if(e.currentChallenge.reincarnation===8){let s=t*(t+1)/2;n=n.times(f.pow(1e50,s))}let a=Math.pow(10,15);if(t>a){let c=yn(a).pow(Math.pow(t/a,1/.125)),p=c.exponent-Math.floor(c.exponent);return c.exponent=Math.floor(c.exponent),c.mantissa*=Math.pow(10,p),c.normalize(),f.max(n,c)}return n},Ss=t=>{let r=e.acceleratorBought,n=Math.pow(10,15);if(r>=n){let h=f.log10(e.coins),b=f.log10(yn(n)),C=Math.floor(n*Math.max(1,Math.pow(h/b,.125))),v=n;for(;C-v>.5;){let U=Math.floor(v+(C-v)/2);if(U===v||U===C)break;e.coins.gte(yn(U))?v=U:C=U}let x=v,B=yn(x);e.acceleratorBought=x,e.acceleratorCost=B;return}let a=r+Ce(r),s=a,l=yn(s);for(;e.coins.gte(l);)s=s*4,l=yn(s);let c=Math.floor(s/8);for(;c>=Ce(s);)yn(s-c).lte(e.coins)?c=Math.floor(c/2):s=s-Math.max(Ce(s),c);!t&&e.coinbuyamount!=="max"&&e.acceleratorBought+e.coinbuyamount=n&&(p=n),e.coins=e.coins.sub(g),e.acceleratorBought=p,p=p+Ce(p),g=yn(p),e.acceleratorCost=g,p>=n)return;e.prestigenoaccelerator=!1,e.transcendnoaccelerator=!1,e.reincarnatenoaccelerator=!1,Uu(),e.acceleratorBought>=5&&e.achievements[148]===0&&R(148),e.acceleratorBought>=25&&e.achievements[149]===0&&R(149),e.acceleratorBought>=100&&e.achievements[150]===0&&R(150),e.acceleratorBought>=666&&e.achievements[151]===0&&R(151),e.acceleratorBought>=2e3&&e.achievements[152]===0&&R(152),e.acceleratorBought>=12500&&e.achievements[153]===0&&R(153),e.acceleratorBought>=1e5&&e.achievements[154]===0&&R(154)},vn=t=>{--t;let r=1e4,n=new f(r);if(n=n.times(f.pow(10,t/o.costDivisor)),t>75+2*_("transcend",e.challengecompletions[4])){let s=t-75-2*_("transcend",e.challengecompletions[4]),l=new f(s).factorial(),c=f.pow(10,s);n=n.times(l.times(c))}if(t>2e3+2*_("transcend",e.challengecompletions[4])){let s=t-2e3-2*_("transcend",e.challengecompletions[4]),l=s*(s+1)/2;n=n.times(f.pow(2,l))}if(e.currentChallenge.transcension===4){let s=t*(t+1)/2;n=n.times(f.pow(10,s))}if(e.currentChallenge.reincarnation===8){let s=t*(t+1)/2;n=n.times(f.pow(1e50,s))}let a=Math.pow(10,15);if(t>a){let c=vn(a).pow(Math.pow(t/a,1/.125)),p=c.exponent-Math.floor(c.exponent);return c.exponent=Math.floor(c.exponent),c.mantissa*=Math.pow(10,p),c.normalize(),f.max(n,c)}return n},ks=t=>{let r=e.multiplierBought,n=Math.pow(10,15);if(r>=n){let h=f.log10(e.coins),b=f.log10(vn(n)),C=Math.floor(n*Math.max(1,Math.pow(h/b,.125))),v=n;for(;C-v>.5;){let U=Math.floor(v+(C-v)/2);if(U===v||U===C)break;e.coins.gte(vn(U))?v=U:C=U}let x=v,B=vn(x);e.multiplierBought=x,e.multiplierCost=B;return}let a=r+Ce(r),s=a,l=vn(s);for(;e.coins.gte(l);)s=s*4,l=vn(s);let c=Math.floor(s/8);for(;c>=Ce(s);)vn(s-c).lte(e.coins)?c=Math.floor(c/2):s=s-Math.max(Ce(s),c);!t&&e.coinbuyamount!=="max"&&e.multiplierBought+e.coinbuyamount=n&&(p=n),e.coins=e.coins.sub(g),e.multiplierBought=p,p=p+Ce(p),g=vn(p),e.multiplierCost=g,p>=n)return;e.prestigenomultiplier=!1,e.transcendnomultiplier=!1,e.reincarnatenomultiplier=!1,Bu(),e.multiplierBought>=2&&e.achievements[155]===0&&R(155),e.multiplierBought>=20&&e.achievements[156]===0&&R(156),e.multiplierBought>=100&&e.achievements[157]===0&&R(157),e.multiplierBought>=500&&e.achievements[158]===0&&R(158),e.multiplierBought>=2e3&&e.achievements[159]===0&&R(159),e.multiplierBought>=12500&&e.achievements[160]===0&&R(160),e.multiplierBought>=1e5&&e.achievements[161]===0&&R(161)},$v=Math.log10(2*Math.PI),_v=Math.log10(Math.E),Uo=t=>++t===0?0:(Math.log10(t*Math.sqrt(t*Math.sinh(1/t)+1/(810*Math.pow(t,6))))-_v)*t+($v-Math.log10(t))/2,Dv=Math.log10(9332621544394e145),Gv=188.582,Bo=(()=>{let t=[1.03,1.25],r=[1,2,3,4,5,6,10,15];for(let s of r)t.push(100+100*s),t.push(10+10*s);let n=1e3;for(let s=0;s"u"&&(a[s]=Math.log10(s));return a})(),Hv=[100,1e3,2e4,4e5,8e6],Fv=[100,1e5,1e15,1e40,1e100],bf=[1,100,1e4,1e8,1e16],Er=(t,r,n,a,s)=>{--r;let l=Math.pow(10,15),c=new f(t),p=a*r;r=s*1e3&&(++g,c.exponent-=Uo(m),c.exponent+=(-3+Math.log10(1+a/2))*(r-m)),m=Math.floor(s*5e3),r>=s*5e3&&(++g,c.exponent-=Uo(m),c.exponent+=(Bo[10+a*10]+1)*(r-m-1)+1),m=Math.floor(s*2e4),r>=s*2e4&&(g+=3,c.exponent-=Uo(m)*3,c.exponent+=(Bo[100+100*a]+5)*(r-m)),m=Math.floor(s*25e4),r>=s*25e4&&(c.exponent+=Math.log10(1.03)*(r-m)*((r-m+1)/2)),c.exponent+=Uo(r)*g;let h=0;e.currentChallenge.transcension===4&&(n==="Coin"||n==="Diamonds")&&(++h,r>=1e3-10*e.challengecompletions[4]&&(p+=r*(r+1)/2)),e.currentChallenge.reincarnation===10&&(n==="Coin"||n==="Diamonds")&&(++h,r>=s*25e3&&(p+=r*(r+1)/2)),c.exponent+=h*((Uo(r+100)-Dv+2*r)*(1.25+e.challengecompletions[4]/4)),c.exponent+=Bo[1.25]*p,m=Math.floor(s*1e3*e.challengecompletions[8]),e.currentChallenge.reincarnation===8&&(n==="Coin"||n==="Diamonds"||n==="Mythos")&&r>=1e3*e.challengecompletions[8]*s&&(c.exponent+=(Bo[2]*((r-m+1)/2)-Bo[1+e.challengecompletions[8]/2])*(r-m));let b=c.exponent-Math.floor(c.exponent);if(c.exponent=Math.floor(c.exponent),c.mantissa*=Math.pow(10,b),c.normalize(),r>l){let x=Er(t,l,n,a,s).pow(Math.pow(r/l,1/.125)),B=x.exponent-Math.floor(x.exponent);return x.exponent=Math.floor(x.exponent),x.mantissa*=Math.pow(10,B),x.normalize(),f.max(c,x)}return c},yf=(t,r)=>{let n=r==="Coin"?Hv:r==="Diamonds"?Fv:bf,a=r==="Coin"?t:t*(t+1)/2;return[n[t-1],a]},vf=(t,r,n,a)=>{let[s,l]=yf(t,r);return Er(s,n,r,l,a!=null?a:xl())},dt=(t,r)=>{let n=t-1,a=o.ordinals[n],[s,l]=yf(t,r),c=Math.pow(10,15),p=1e99,g=xl(),m=Cf[r][0],h=`${a}Owned${r}`,b=e[h];if(b>=c){let E=f.log10(e[m]),T=f.log10(Er(s,c,r,l,g)),S=Math.floor(c*Math.max(1,Math.pow(E/T,.125))),I=c;for(;S-I>.5;){let re=Math.floor(I+(S-I)/2);if(re===I||re===S)break;e[m].gte(Er(s,re,r,l,g))?I=re:S=re}let N=I,X=Er(s,N,r,l,g);e[h]=N,e[`${a}Cost${r}`]=X;return}let C=b+Ce(b),v=1,x=Er(s,b+v,r,l,g);if(x.exponent>=p||!e[m].gte(x))return;for(;x.exponent=Ce(v);)Er(s,b+v-B,r,l,g).lte(e[m])?B=Math.floor(B/2):v=v-Math.max(Ce(v),B);if(b+v>=c){e[h]=c,e[`${a}Cost${r}`]=Er(s,c,r,l,g);return}let U=Math.max(b+v-6-Ce(v),C),k=Er(s,U,r,l,g);for(;U<=b+v&&e[m].gte(k);)e[m]=e[m].sub(k),e[h]=U,U=U+Ce(U),k=Er(s,U,r,l,g),e[`${a}Cost${r}`]=k},Cf={Diamonds:["prestigePoints","crystal"],Mythos:["transcendPoints","mythos"],Particles:["reincarnationPoints","particle"],Coin:["coins","coin"]},wf=(t,r,n,a)=>{let[s,l]=Cf[r],c=a?500:e[`${l}buyamount`],p=1;p+=o.rune4level*o.effectiveLevelMult/160,p+=(e.researches[56]+e.researches[57]+e.researches[58]+e.researches[59]+e.researches[60])/200,p+=_("transcend",e.challengecompletions[4])/200,p+=3*(o.bonusant7+e.antUpgrades[7-1])/100;let g=`${t}Cost${r}`,m=`${t}Owned${r}`;for(;e[s].gte(e[g])&&o.ticker=1e3*p&&(e[g]=e[g].times(e[m]).dividedBy(1e3).times(1+n/2)),e[m]>=5e3*p&&(e[g]=e[g].times(e[m]).times(10).times(10+n*10)),e[m]>=2e4*p&&(e[g]=e[g].times(f.pow(e[m],3)).times(1e5).times(100+n*100)),e[m]>=25e4*p&&(e[g]=e[g].times(f.pow(1.03,e[m]-25e4*p))),e.currentChallenge.transcension===4&&(r==="Coin"||r==="Diamonds")&&(e[g]=e[g].times(Math.pow(100*e[m]+1e4,1.25+1/4*e.challengecompletions[4])),e[m]>=1e3-10*e.challengecompletions[4]&&(e[g]=e[g].times(f.pow(1.25,e[m])))),e.currentChallenge.reincarnation===8&&(r==="Coin"||r==="Diamonds"||r==="Mythos")&&e[m]>=1e3*e.challengecompletions[8]*p&&(e[g]=e[g].times(f.pow(2,(e[m]-1e3*e.challengecompletions[8]*p)/(1+e.challengecompletions[8]/2)))),o.ticker+=1;o.ticker=0},nr=(t,r,n)=>{let a=t;e[a].gte(f.pow(10,o.upgradeCosts[r]))&&e.upgrades[r]===0&&(e[a]=e[a].sub(f.pow(10,o.upgradeCosts[r])),e.upgrades[r]=1,Ft(r,n)),t==="transcendPoints"&&(e.reincarnatenocoinprestigeortranscendupgrades=!1,e.reincarnatenocoinprestigetranscendorgeneratorupgrades=!1),t==="prestigePoints"&&(e.transcendnocoinorprestigeupgrades=!1,e.reincarnatenocoinorprestigeupgrades=!1,e.reincarnatenocoinprestigeortranscendupgrades=!1,e.reincarnatenocoinprestigetranscendorgeneratorupgrades=!1),t==="coins"&&(e.prestigenocoinupgrades=!1,e.transcendnocoinupgrades=!1,e.transcendnocoinorprestigeupgrades=!1,e.reincarnatenocoinupgrades=!1,e.reincarnatenocoinorprestigeupgrades=!1,e.reincarnatenocoinprestigeortranscendupgrades=!1,e.reincarnatenocoinprestigetranscendorgeneratorupgrades=!1)},Qv=t=>{let r=t-1,n=f.log(e.prestigeShards.add(1),10);return Math.floor(Math.pow(Math.max(0,2*(n-o.crystalUpgradesCost[r])/o.crystalUpgradeCostIncrement[r]+1/4),1/2)+1/2)},zt=(t,r=!1)=>{let n=t-1,a=0;a+=Math.floor(o.rune3level/16*o.effectiveLevelMult)*100/100,e.upgrades[73]>.5&&e.currentChallenge.reincarnation!==0&&(a+=10);let s=Qv(t);s+a>e.crystalUpgrades[n]&&(e.crystalUpgrades[n]=100/100*(s+a),s>0&&(e.prestigeShards=e.prestigeShards.sub(f.pow(10,o.crystalUpgradesCost[n]+o.crystalUpgradeCostIncrement[n]*(1/2*Math.pow(s-1/2,2)-1/8))),r||Ei(t)))},Fa=t=>{let r=1;if(e.upgrades[46]===1&&(r=t?9999:e.coinbuyamount),e.upgrades[46]<1){for(;e.prestigePoints.gte(e.acceleratorBoostCost)&&o.ticker1e3*(1+2*o.effectiveRuneBlessingPower[4])&&(e.acceleratorBoostCost=e.acceleratorBoostCost.times(f.pow(10,Math.pow(e.acceleratorBoostBought-1e3*(1+2*o.effectiveRuneBlessingPower[4]),2)/(1+2*o.effectiveRuneBlessingPower[4])))),e.transcendnoaccelerator=!1,e.reincarnatenoaccelerator=!1,e.upgrades[46]<.5)){for(let n=21;n<41;n++)e.upgrades[n]=0;Pe("prestige"),e.prestigePoints=new f(0)}}else{let n=e.acceleratorBoostBought,a=Math.pow(10,15);if(n>=a){let b=f.log10(e.prestigePoints),C=f.log10(Jr(a)),v=Math.floor(a*Math.max(1,Math.pow(b/C,.125))),x=a;for(;v-x>.5;){let k=Math.floor(x+(v-x)/2);if(k===x||k===v)break;e.prestigePoints.gte(Jr(k))?x=k:v=k}let B=x,U=Jr(B);e.acceleratorBoostBought=B,e.acceleratorBoostCost=U;return}let s=n+Ce(n),l=1,c=Jr(n+l);for(;e.prestigePoints.gte(c);)l*=4,c=Jr(n+l);let p=Math.floor(l/8);for(;p>=Ce(l);)Jr(n+l-p).lte(e.prestigePoints)?p=Math.floor(p/2):l=l-Math.max(Ce(l),p);let g=Math.max(n+l-6-Ce(l),s),m=Jr(e.acceleratorBoostBought);for(;g<=n+l&&e.prestigePoints.gte(Jr(g));)if(e.prestigePoints=e.prestigePoints.sub(m),g>=a&&(g=a),e.acceleratorBoostBought=g,g=g+Ce(g),m=Jr(g),e.acceleratorBoostCost=m,e.transcendnoaccelerator=!1,e.reincarnatenoaccelerator=!1,g>=a)return}o.ticker=0,e.acceleratorBoostBought>=2&&e.achievements[162]===0&&R(162),e.acceleratorBoostBought>=10&&e.achievements[163]===0&&R(163),e.acceleratorBoostBought>=50&&e.achievements[164]===0&&R(164),e.acceleratorBoostBought>=200&&e.achievements[165]===0&&R(165),e.acceleratorBoostBought>=1e3&&e.achievements[166]===0&&R(166),e.acceleratorBoostBought>=5e3&&e.achievements[167]===0&&R(167),e.acceleratorBoostBought>=15e3&&e.achievements[168]===0&&R(168)},Jr=(t=1)=>{t--;let r=Math.pow(10,15),n=new f(1e3),a=1+2*o.effectiveRuneBlessingPower[4],s=p=>p*(p+1)/2,l=p=>p*(p+1)*(2*p+1)/6,c=n;if(t>1e3*a?c=n.times(f.pow(10,10*t+s(t)+l(t-1e3*a)/a)):c=n.times(f.pow(10,10*t+s(t))),t>r){let m=Jr(r).pow(Math.pow(t/r,1/.125)),h=m.exponent-Math.floor(m.exponent);return m.exponent=Math.floor(m.exponent),m.mantissa*=Math.pow(10,h),m.normalize(),f.max(c,m)}return c},Cn=(t,r)=>{--r,t=new f(t);let n=t.times(f.pow(2,r)),a=e.currentChallenge.ascension!==15?325e3:1e3;r>a&&(n=n.times(f.pow(1.001,(r-a)*((r-a+1)/2))));let s=Math.pow(10,15);if(r>s){let p=Cn(t,s).pow(Math.pow(r/s,1/.125)),g=p.exponent-Math.floor(p.exponent);return p.exponent=Math.floor(p.exponent),p.mantissa*=Math.pow(10,g),p.normalize(),f.max(n,p)}return n},wn=(t,r=!1)=>{let n=t-1,a=bf[n],s=o.ordinals[n],l=`${s}OwnedParticles`,c=e[l],p=Math.pow(10,15);if(c>=p){let B=f.log10(e.reincarnationPoints),U=f.log10(Cn(a,p)),k=Math.floor(p*Math.max(1,Math.pow(B/U,.125))),L=p;for(;k-L>.5;){let S=Math.floor(L+(k-L)/2);if(S===L||S===k)break;e.reincarnationPoints.gte(Cn(a,S))?L=S:k=S}let E=L,T=Cn(a,E);e[l]=E,e[`${s}CostParticles`]=T;return}let g=c+Ce(c),m=g,h=Cn(a,m);for(;e.reincarnationPoints.gte(h);)m=m*4,h=Cn(a,m);let b=Math.floor(m/8);for(;b>=Ce(m);)Cn(a,m-b).lte(e.reincarnationPoints)?b=Math.floor(b/2):m=m-Math.max(Ce(m),b);r||e.particlebuyamount+c{let n=t.map((s,l)=>{if(s===null)return null;let c=Math.ceil(Math.pow(r/Ha[l],1/3)-1);return Math.max(s,c)}),a=0;for(let s=0;s{let n=null;for(let m=0;mr)return t;let a=n,s=a*2;for(;Eu(t,s)[0]<=r;)a=s,s*=2;for(;s-a>.5;){let m=a+(s-a)/2;if(m===a||m===s)break;Eu(t,m)[0]<=r?a=m:s=m}let[l,c]=Eu(t,a),p=r-l,g=c.map((m,h)=>m===null?null:Ha[h]*Math.pow(m+1,3));for(let m=1;m<=5;m++){let h=null;for(let b=0;b{r!=null||(r=e.tesseractbuyamount),a!=null||(a=e[`ascendBuilding${t}`].owned);let s=Ha[t-1],l=s*Math.pow(a*(a+1)/2,2),c;if(n){let g=Math.floor(-.5+.5*Math.pow(1+8*Math.pow((Number(e.wowTesseracts)+l)/s,.5),.5));c=Math.min(g,a+r)}else c=a+r;let p=s*Math.pow(c*(c+1)/2,2)-l;return[c,p]},Da=(t,r=e.tesseractbuyamount)=>{let n=Ha[t-1],a=`ascendBuilding${t}`,[s,l]=qv(t,r);e[a].owned=s,e.wowTesseracts.sub(l),e[a].cost=n*Math.pow(1+s,3)},Ls=(t,r)=>{if((t==="Spirits"?e.challengecompletions[12]>0:e.achievements[134]===1)&&isFinite(e.runeshards)&&e.runeshards>0){let a,s,l;t==="Spirits"?(a=o.spiritBaseCost,s=e.runeSpiritLevels[r],l=e.runeSpiritBuyAmount):(a=o.blessingBaseCost,s=e.runeBlessingLevels[r],l=e.runeBlessingBuyAmount);let[c,p]=jn(s,a,e.runeshards,l);t==="Spirits"?e.runeSpiritLevels[r]=c:e.runeBlessingLevels[r]=c,e.runeshards-=p,e.runeshards<0&&(e.runeshards=0),xf(t,r)}},xf=(t,r)=>{if(r===1){let n=[0,1e5,1e8,1e11];for(let a=1;a<=3;a++)e.runeBlessingLevels[1]>=n[a]&&e.achievements[231+a]<1&&R(231+a),e.runeSpiritLevels[1]>=10*n[a]&&e.achievements[234+a]<1&&R(234+a);e.runeBlessingLevels[1]>=1e22&&e.achievements[245]<1&&R(245)}if(Ou(),t==="Blessings"){let n=[0,8,10,6.66,2,1],a=r===5?1:0;i(`runeBlessingPower${r}Value1`).innerHTML=u.t("runes.blessings.blessingPower",{reward:u.t(`runes.blessings.rewards.${r-1}`),value:d(o.runeBlessings[r]),speed:d(1-a+n[r]*o.effectiveRuneBlessingPower[r],4,!0)})}else if(t==="Spirits"){let n=[0,1,1,20,1,100];n[r]*=Xe()/400;let a=r===3?1:0;i(`runeSpiritPower${r}Value1`).innerHTML=u.t("runes.spirits.spiritPower",{reward:u.t(`runes.spirits.rewards.${r-1}`),value:d(o.runeSpirits[r]),speed:d(1-a+n[r]*o.effectiveRuneSpiritPower[r],4,!0)})}},Ps=(t,r=100,n=!1)=>{if(t==="Spirits"?e.challengecompletions[12]>0:e.achievements[134]===1){let s=Math.floor(e.runeshards/100*r/5);for(let l=1;l<6;l++)if(isFinite(e.runeshards)&&e.runeshards>0){let c,p;t==="Spirits"?(c=o.spiritBaseCost,p=e.runeSpiritLevels[l]):(c=o.blessingBaseCost,p=e.runeBlessingLevels[l]);let[m,h]=jn(p,c,s,1e300);m>p&&(!n||(m-p)*1e4>p)&&(t==="Spirits"?e.runeSpiritLevels[l]=m:e.runeBlessingLevels[l]=m,e.runeshards-=h,e.runeshards<0&&(e.runeshards=0),xf(t,l))}}};var Ml=new Map([["A",["Buy Accelerators",()=>Ss(),!1]],["B",["Boost Accelerator",()=>Fa(),!1]],["C",["Auto Challenge",()=>{Mf()},!1]],["E",["Exit T / R Challenge",()=>{e.autoChallengeRunning?Mf():Tf()},!1]],["M",["Multipliers",()=>ks(),!1]],["N",["No (Cancel)",()=>Su(!1),!0]],["P",["Reset Prestige",()=>Ae("prestige"),!1]],["R",["Reset Reincarnate",()=>Ae("reincarnation"),!1]],["S",["Sacrifice Ants",()=>As(),!1]],["T",["Reset Transcend",()=>Ae("transcension"),!1]],["Y",["Yes (OK)",()=>Su(!0),!0]],["ARROWLEFT",["Back a tab",()=>Ro(-1),!1]],["ARROWRIGHT",["Next tab",()=>Ro(1),!1]],["ARROWUP",["Back a subtab",()=>Ro(-1,!0),!1]],["ARROWDOWN",["Next subtab",()=>Ro(1,!0),!1]],["SHIFT+A",["Reset Ascend",()=>Ae("ascension"),!1]],["SHIFT+C",["Cleanse Corruptions",()=>hn(10,999),!1]],["SHIFT+D",["Spec. Action Add x1",()=>xn("add",1),!1]],["SHIFT+E",["Exit Asc. Challenge",()=>Ae("ascensionChallenge"),!1]],["SHIFT+O",["Use Off. Potion",()=>gn("offeringPotion"),!1]],["SHIFT+P",["Use Obt. Potion",()=>gn("obtainiumPotion"),!1]],["SHIFT+S",["Reset Singularity",()=>Ae("singularity"),!1]],["CTRL+B",["Un-hide Tabs",()=>ze.reappend(),!1]]]),Ru=!1,st=new Map(Ml),Mf=()=>{e.researches[150]>0&&(Ao(),e.autoChallengeRunning||Tf())},Tf=()=>{e.currentChallenge.reincarnation!==0&&Ae("reincarnationChallenge",void 0,!0),e.currentChallenge.transcension!==0&&Ae("transcensionChallenge",void 0,!0)},jv=t=>{var s;if(!Ru||!e.toggles[39])return;if(((s=document.activeElement)==null?void 0:s.localName)==="input"){t.stopPropagation();return}kf(t,t.code.replace(/^(Digit|Numpad)/,"").toUpperCase());let r="";t.ctrlKey&&(r+="CTRL+"),t.shiftKey&&(r+="SHIFT+"),t.altKey&&(r+="ALT+");let n=r+t.key.toUpperCase();if(n==="TAB"&&t.preventDefault(),n!=="ENTER"&&i("transparentBG").style.display==="block"&&st.has(n)&&!st.get(n)[2])return;let a="";st.has(n)&&(a=`${st.get(n)[0]}`,st.get(n)[1](),t.preventDefault()),o.currentTab===10&&e.subtabNumber===6&&(i("lastHotkey").textContent=n,i("lastHotkeyName").textContent=a)},Vv=(t,r)=>{let n=document.createElement("div");n.classList.add("hotkeyItem");let a=document.createElement("span");a.id="actualHotkey",a.textContent=t,a.addEventListener("click",async l=>{var b,C,v;let c=l.target,p=c.textContent.toUpperCase(),g=(v=(b=st.get(p))==null?void 0:b[0])!=null?v:(C=c.nextSibling)==null?void 0:C.textContent,m=await Ee(` + `.trim();let Te=document.createElement("button"),ut=document.createElement("button");c>1&&(Te.addEventListener("click",Tv),Te.style.cssText="border: 2px solid #5865F2; height: 25px; width: 150px;",Te.textContent="Save to Cloud \u2601",ut.addEventListener("click",Sv),ut.style.cssText="border: 2px solid #5865F2; height: 25px; width: 150px;",ut.textContent="Load from Cloud \u263D");let ft=document.createElement("div");ft.style.cssText="display: flex; flex-direction: row; justify-content: space-evenly; padding: 5px; width: 45%; margin: 0 auto;",ft.appendChild(Te),ft.appendChild(ut),t.appendChild(ft)}else(L=t.querySelector("#open-register"))==null||L.addEventListener("click",()=>{var S,I,N;(S=t.querySelector("#register"))==null||S.style.setProperty("display","flex"),(I=t.querySelector("#login"))==null||I.style.setProperty("display","none"),(N=t.querySelector("#forgotpassword"))==null||N.style.setProperty("display","none"),Co()}),(E=t.querySelector("#open-signin"))==null||E.addEventListener("click",()=>{var S,I,N;(S=t.querySelector("#register"))==null||S.style.setProperty("display","none"),(I=t.querySelector("#login"))==null||I.style.setProperty("display","flex"),(N=t.querySelector("#forgotpassword"))==null||N.style.setProperty("display","none"),Co()}),(T=t.querySelector("#open-forgotpassword"))==null||T.addEventListener("click",()=>{var S,I,N;(S=t.querySelector("#register"))==null||S.style.setProperty("display","none"),(I=t.querySelector("#login"))==null||I.style.setProperty("display","none"),(N=t.querySelector("#forgotpassword"))==null||N.style.setProperty("display","flex"),Co()})}async function Mv(){await fetch("https://synergism.cc/api/v1/users/logout"),await P(u.t("account.logout")),location.reload()}async function Tv(){let t=localStorage.getItem("Synergysave2");if(typeof t!="string"){console.log("Yeah, no save here.");return}let r=new FormData;r.set("savefile",new File([t],"file.txt"),"file.txt");let n=await fetch("https://synergism.cc/api/v1/saves/upload",{method:"POST",body:r});if(!n.ok){await P(`Received an error: ${await n.text()}`);return}}async function Sv(){var n;let r=await(await fetch("https://synergism.cc/api/v1/saves/get")).json();Ga((n=r==null?void 0:r.save)!=null?n:null)}var Pm=new WeakSet;function Co(){let r=Array.from(document.querySelectorAll(".turnstile")).find(n=>n.offsetParent!==null);r&&!Pm.has(r)&&(turnstile.render(r,{sitekey:r.getAttribute("data-sitekey"),"error-callback"(){},retry:"never"}),Pm.add(r))}var wo=(x=>(x[x.Quark=0]="Quark",x[x.GoldenQuark=1]="GoldenQuark",x[x.Cubes=2]="Cubes",x[x.PowderConversion=3]="PowderConversion",x[x.AscensionSpeed=4]="AscensionSpeed",x[x.GlobalSpeed=5]="GlobalSpeed",x[x.AscensionScore=6]="AscensionScore",x[x.AntSacrifice=7]="AntSacrifice",x[x.Offering=8]="Offering",x[x.Obtainium=9]="Obtainium",x[x.Octeract=10]="Octeract",x[x.BlueberryTime=11]="BlueberryTime",x[x.AmbrosiaLuck=12]="AmbrosiaLuck",x[x.OneMind=13]="OneMind",x))(wo||{}),gr=null,kv=()=>gr,vu=async()=>{if(!e.dayCheck)return;let t=await fetch("https://synergism.cc/api/v2/events/get");if(!t.ok)throw new Error("God fucking dammit");let r=await t.json();gr=null;let n=new Date(il()).getTime();n>=r.start&&n<=r.end&&r.name.length&&(gr=r);let a=i("happyHolidays"),s=i("eventBuffs"),l=o.isEvent;if(gr){o.isEvent=!0;let c=[];for(let p=0;p0?c.push(`${g>=0?"+":"-"}${d(100*g,3,!0)}% ${Om[p]}`):(ol[p]!=="OneMind"||e.singularityUpgrades.oneMind.level===0)&&c.push(`${g>=0?"+":"-"}${d(100*g,2,!0)}% ${Om[p]}`))}i("eventCurrent").textContent=u.t("settings.events.activeUntil",{x:new Date(gr.end)}),s.innerHTML=o.isEvent&&c.length?`Current Buffs: ${c.join(", ")}`:"",a.innerHTML=`(${gr.name.length}) ${gr.name.join(", ")}`,a.style.color=gr.color[Math.floor(Math.random()*gr.color.length)],a.href=gr.url.length>0?gr.url[Math.floor(Math.random()*gr.url.length)]:"#"}else o.isEvent=!1,i("eventCurrent").innerHTML=u.t("settings.events.inactive"),s.textContent="",s.style.color="var(--red-text-color)",a.innerHTML="",a.href="";o.isEvent!==l&&(Oe(),o.ambrosiaCurrStats.ambrosiaAdditiveLuckMult=zr().value,o.ambrosiaCurrStats.ambrosiaLuck=Ge().value,o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value)},ol=["Quark","GoldenQuark","Cubes","PowderConversion","AscensionSpeed","GlobalSpeed","AscensionScore","AntSacrifice","Offering","Obtainium","Octeract","BlueberryTime","AmbrosiaLuck","OneMind"],Om=["Quarks","Golden Quarks","Cubes from all type","Powder Conversion","Ascension Speed","Global Speed","Ascension Score","Ant Sacrifice rewards","Offering","Obtainium","Eight Dimensional Hypercubes","Blueberry Time Generation","Ambrosia Luck (Additive Mult)","One Mind Quark Bonus"],Cu=t=>{var n,a,s,l,c,p,g,m,h,b,C,v,x;let r=kv();if(r===null)return 0;switch(t){case 0:return(n=r.quark)!=null?n:0;case 1:return(a=r.goldenQuark)!=null?a:0;case 2:return(s=r.cubes)!=null?s:0;case 3:return(l=r.powderConversion)!=null?l:0;case 4:return(c=r.ascensionSpeed)!=null?c:0;case 5:return(p=r.globalSpeed)!=null?p:0;case 6:return(g=r.ascensionScore)!=null?g:0;case 7:return(m=r.antSacrifice)!=null?m:0;case 8:return(h=r.offering)!=null?h:0;case 9:return(b=r.obtainium)!=null?b:0;case 10:return(C=r.octeract)!=null?C:0;case 13:return e.singularityUpgrades.oneMind.level>0?r.oneMind:0;case 11:return(v=r.blueberryTime)!=null?v:0;case 12:return(x=r.ambrosiaLuck)!=null?x:0}},Um=()=>(o.eventClicked=!0,i("eventClicked").style.display="block",P(u.t("event.aprilFools.clicked")));var Lv=new Map([["kMisc","miscStats"],["kFreeAccel","acceleratorStats"],["kFreeMult","multiplierStats"],["kOfferingMult","offeringMultiplierStats"],["kObtMult","obtainiumMultiplierStats"],["kGlobalCubeMult","globalCubeMultiplierStats"],["kQuarkMult","globalQuarkMultiplierStats"],["kGSpeedMult","globalSpeedMultiplierStats"],["kCubeMult","cubeMultiplierStats"],["kTessMult","tesseractMultiplierStats"],["kHypercubeMult","hypercubeMultiplierStats"],["kPlatMult","platonicMultiplierStats"],["kHeptMult","hepteractMultiplierStats"],["kOrbPowderMult","powderMultiplierStats"],["kOctMult","octeractMultiplierStats"],["kASCMult","ascensionSpeedMultiplierStats"],["kGQMult","goldenQuarkMultiplierStats"],["kAddStats","addCodeStats"],["kAmbrosiaLuck","ambrosiaLuckStats"],["kAmbrosiaGenMult","ambrosiaGenerationStats"]]),Bm=t=>{for(let r of Array.from(t.parentElement.children)){let n=i(Lv.get(r.id));r.id!==t.id?(r.style.backgroundColor="",n.style.display="none",n.classList.remove("activeStats")):(r.style.backgroundColor="crimson",n.style.display="block",n.classList.add("activeStats"))}},Rm=()=>{let t=document.getElementsByClassName("activeStats");for(let r=0;r{i("sMisc1").textContent=d(e.prestigeCount,0,!0),i("sMisc2").textContent=`${d(1e3*e.fastestprestige)}ms`,i("sMisc3").textContent=d(e.maxofferings),i("sMisc4").textContent=d(o.runeSum),i("sMisc5").textContent=d(e.transcendCount,0,!0),i("sMisc6").textContent=`${d(1e3*e.fastesttranscend)}ms`,i("sMisc7").textContent=d(e.reincarnationCount,0,!0),i("sMisc8").textContent=`${d(1e3*e.fastestreincarnate)}ms`,i("sMisc9").textContent=d(e.maxobtainium),i("sMisc10").textContent=d(e.maxobtainiumpersecond,2,!0),i("sMisc11").textContent=d(e.obtainiumpersecond,2,!0),i("sMisc12").textContent=d(e.ascensionCount,0,!0),i("sMisc13").textContent=d(e.quarksThisSingularity,0,!0),i("sMisc14").textContent=d(e.totalQuarksEver+e.quarksThisSingularity,0,!0),i("sMisc15").textContent=`${zt(e.quarkstimer)} / ${zt(9e4+18e3*e.researches[195])}`,i("sMisc16").textContent=wu(0)},Av=()=>{i("sA1").textContent=`+${d(o.freeUpgradeAccelerator,0,!1)}`,i("sA2").textContent=`+${d(o.totalAcceleratorBoost*(4+2*e.researches[18]+2*e.researches[19]+3*e.researches[20]+o.cubeBonusMultiplier[1]),0,!1)}`,i("sA3").textContent=`+${d(Math.floor(Math.pow(o.rune1level*o.effectiveLevelMult/10,1.1)),0,!0)}`,i("sA4").textContent=`x${d(1+o.rune1level*1/200*o.effectiveLevelMult,3,!0)}`,i("sA5").textContent=`x${d(Math.pow(1.01,e.upgrades[21]+e.upgrades[22]+e.upgrades[23]+e.upgrades[24]+e.upgrades[25]),3,!0)}`,i("sA6").textContent=`x${d(Math.pow(1.01,e.achievements[60]+e.achievements[61]+e.achievements[62]),3,!0)}`,i("sA7").textContent=`x${d(1+1/5*e.researches[1],3,!0)}`,i("sA8").textContent=`x${d(1+1/20*e.researches[6]+1/25*e.researches[7]+1/40*e.researches[8]+3/200*e.researches[9]+1/200*e.researches[10],3,!0)}`,i("sA9").textContent=`x${d(1+1/20*e.researches[86],3,!0)}`,i("sA10").textContent=`x${d((e.currentChallenge.transcension!==0||e.currentChallenge.reincarnation!==0)&&e.upgrades[50]>.5?1.25:1,3,!0)}`,i("sA11").textContent=`^${d(Math.min(1,(1+e.platonicUpgrades[6]/30)*o.viscosityPower[e.usedCorruptions[2]]),3,!0)}`,i("sA12").textContent=d(o.freeAccelerator,0,!0)},Ev=()=>{i("sM1").textContent=`+${d(o.freeUpgradeMultiplier,0,!0)}`,i("sM2").textContent=`+${d(Math.floor(Math.floor(o.rune2level/10*o.effectiveLevelMult)*Math.floor(10+o.rune2level/10*o.effectiveLevelMult)/2)*100/100,0,!0)}`,i("sM3").textContent=`x${d(1+o.rune2level/200*o.effectiveLevelMult,3,!0)}`,i("sM4").textContent=`x${d(Math.pow(1.01,e.upgrades[21]+e.upgrades[22]+e.upgrades[23]+e.upgrades[24]+e.upgrades[25])*(1+e.upgrades[34]*3/100)*(1+e.upgrades[34]*(2/103)),3,!0)}`,i("sM5").textContent=`x${d(Math.pow(1.01,e.achievements[57]+e.achievements[58]+e.achievements[59]),3,!0)}`,i("sM6").textContent=`x${d(1+1/5*e.researches[2],3,!0)}`,i("sM7").textContent=`x${d(1+1/20*e.researches[11]+1/25*e.researches[12]+1/40*e.researches[13]+3/200*e.researches[14]+1/200*e.researches[15],3,!0)}`,i("sM8").textContent=`x${d(1+1/20*e.researches[87],3,!0)}`,i("sM9").textContent=`x${d(_t(40,(e.antUpgrades[4]+o.bonusant5)/1e3*40/39),2,!0)}`,i("sM10").textContent=`x${d(o.cubeBonusMultiplier[2],3,!0)}`,i("sM11").textContent=`x${d((e.currentChallenge.transcension!==0||e.currentChallenge.reincarnation!==0)&&e.upgrades[50]>.5?1.25:1,3,!0)}`,i("sM12").textContent=`^${d(Math.min(1,(1+e.platonicUpgrades[6]/30)*o.viscosityPower[e.usedCorruptions[2]]),3,!0)}`,i("sM13").textContent=d(o.freeMultiplier,3,!0)},Ov=()=>{i("sGQM1").textContent=`x${d(1,3,!0)}`,i("sGQM2").textContent=`+${d(e.achievementPoints/25e3,3,!0)}`,i("sGQM3").textContent=`+${d(e.achievements[250]>0?.1:0,3,!0)}`,i("sGQM4").textContent=`+${d(e.achievements[251]>0?.1:0,3,!0)}`,i("sGQM5").textContent=`+${d(e.platonicUpgrades[5]>0?.2:0,3,!0)}`,i("sGQM6").textContent=`+${d(e.platonicUpgrades[10]>0?.25:0,3,!0)}`,i("sGQM7").textContent=`+${d(e.platonicUpgrades[15]>0?.3:0,3,!0)}`,i("sGQM8").textContent=`+${d(o.challenge15Rewards.quarks-1,3,!0)}`,i("sGQM9").textContent=`x${d(e.worlds.applyBonus(1/Ti()),3,!0)}`,i("sGQM10").textContent=`x${d(o.isEvent?1+Ye(0)+Ye(13):1,3,!0)}`,i("sGQM11").textContent=`x${d(Qn()>0?1.1+.15/75*Qn():1,3,!0)}`,i("sGQM12").textContent=`x${d(e.challenge15Exponent>=1e15?1+5/1e4*Ve("quark"):1,3,!0)}`,i("sGQM13").textContent=`x${d(ds(),3,!0)}`,i("sGQM14").textContent=`x${d(1+e.achievements[266]*Math.min(.1,e.ascensionCount/1e16),3,!0)}`,i("sGQM15").textContent=`x${d(1+e.singularityCount/10,3,!0)}`,i("sGQM16").textContent=`x${d(Tu(),3,!0)}`,i("sGQM17").textContent=`x${d(1+.1*e.cubeUpgrades[53]/100,3,!0)}`,i("sGQM18").textContent=`x${d(1+1/1e4*e.cubeUpgrades[68]+.05*Math.floor(e.cubeUpgrades[68]/1e3),3,!0)}`,i("sGQM19").textContent=`x${d(1+.02*e.singularityUpgrades.intermediatePack.level+.04*e.singularityUpgrades.advancedPack.level+.06*e.singularityUpgrades.expertPack.level+.08*e.singularityUpgrades.masterPack.level+.1*e.singularityUpgrades.divinePack.level,3,!0)}`,i("sGQM20").textContent=`x${d(1+.4*+e.octeractUpgrades.octeractStarter.getEffect().bonus,3,!0)}`,i("sGQM21").textContent=`x${d(+e.octeractUpgrades.octeractQuarkGain.getEffect().bonus,3,!0)}`,i("sGQM22").textContent=`x${d(fn(),3,!0)}`,i("sGQM23").textContent=`x${d(1+ +e.singularityUpgrades.singQuarkImprover1.getEffect().bonus,3,!0)}`,i("sGQM24").textContent=`x${d(1+1/1e4*Math.floor(e.octeractUpgrades.octeractQuarkGain.level/199)*e.octeractUpgrades.octeractQuarkGain2.level*Math.floor(1+Math.log10(Math.max(1,e.hepteractCrafts.quark.BAL))),3,!0)}`,i("sGQM25").textContent=`x${d(To(),2,!0)}`,i("sGQM26").textContent=`x${d(+e.blueberryUpgrades.ambrosiaTutorial.bonus.quarks,2,!0)}`,i("sGQM27").textContent=`x${d(+e.blueberryUpgrades.ambrosiaQuarks1.bonus.quarks,2,!0)}`,i("sGQM28").textContent=`x${d(+e.blueberryUpgrades.ambrosiaCubeQuark1.bonus.quarks,2,!0)}`,i("sGQM29").textContent=`x${d(+e.blueberryUpgrades.ambrosiaLuckQuark1.bonus.quarks,2,!0)}`,i("sGQM30").textContent=`x${d(+e.blueberryUpgrades.ambrosiaQuarks2.bonus.quarks,2,!0)}`,i("sGQM31").textContent=`x${d(bo(),3,!0)}`,i("sGQM32").textContent=`x${d(1+ +e.singularityChallenges.limitedTime.rewards.quarkMult,2,!0)}`,i("sGQM33").textContent=`x${d(1+ +e.singularityChallenges.sadisticPrequel.rewards.quarkMult,2,!0)}`,i("sGQM34").textContent=`x${d(e.highestSingularityCount===0?1.25:1,2,!0)}`,i("sGQMT").textContent=`x${d(e.worlds.applyBonus(1),3,!0)}`},Uv=()=>{let t=qe(),r=t.preList;for(let s=0;s{var B,U;let t=zn().list,r={1:{acc:2,desc:"PseudoCoin Upgrade:",color:"gold"},2:{acc:2,desc:"Ascension Time Multiplier:"},3:{acc:2,desc:"Sun and Moon Achievements:"},4:{acc:2,desc:"Speed Achievement:"},5:{acc:2,desc:"Challenge 15 All Cube Bonus:"},6:{acc:2,desc:"Rune 6 - Infinite Ascent:"},7:{acc:2,desc:"Platonic Beta:"},8:{acc:2,desc:"Platonic Omega:"},9:{acc:2,desc:"Overflux Powder:"},10:{acc:2,desc:"Event:"},11:{acc:2,desc:"Singularity Factor:"},12:{acc:2,desc:"Wow Pass Y"},13:{acc:2,desc:"Starter Pack:"},14:{acc:2,desc:"Cube Flame [GQ]:"},15:{acc:2,desc:"Cube Blaze [GQ]:"},16:{acc:2,desc:"Cube Inferno [GQ]:"},17:{acc:2,desc:"Wow Pass Z:"},18:{acc:2,desc:"Cookie Upgrade 16:"},19:{acc:2,desc:"Cookie Upgrade 8:"},20:{acc:2,desc:"Total Octeract Bonus:"},21:{acc:2,desc:"No Singularity Upgrades Challenge:"},22:{acc:2,desc:"Citadel [GQ]"},23:{acc:2,desc:"Citadel 2 [GQ]"},24:{acc:4,desc:"Platonic DELTA"},25:{acc:2,desc:"Wow Pass \u221E"},26:{acc:2,desc:"Unspent Ambrosia Bonus"},27:{acc:2,desc:"Module- Tutorial"},28:{acc:2,desc:"Module- Cubes 1"},29:{acc:2,desc:"Module- Luck-Cube 1"},30:{acc:2,desc:"Module- Quark-Cube 1"},31:{acc:2,desc:"Module- Cubes 2"},32:{acc:2,desc:"Module- Hyperflux"},33:{acc:2,desc:"20 Ascensions X20 Bonus [EXALT ONLY]"},34:{acc:2,desc:"Cash Grab ULTIMATE"},35:{acc:2,desc:"Shop EX ULTIMATE"},36:{acc:2,desc:"Exalt 6 Penalty (for being too slow!)"}};for(let k=0;k{let t=Qr("prestige",!1),r={1:{acc:3,desc:"Alchemy Achievement 5:"},2:{acc:3,desc:"Alchemy Achievement 6:"},3:{acc:3,desc:"Alchemy Achievement 7:"},4:{acc:3,desc:"Diamond Upgrade 4x3:"},5:{acc:3,desc:"Particle Upgrade 3x5:"},6:{acc:3,desc:"Auto Offering Shop Upgrade:"},7:{acc:3,desc:"Offering EX Shop Upgrade:"},8:{acc:3,desc:"Cash Grab Shop Upgrade:"},9:{acc:3,desc:"Research 4x10:"},10:{acc:3,desc:"Sacrificium Formicidae:"},11:{acc:3,desc:"Plutus Cube Tribute:"},12:{acc:3,desc:"Constant Upgrade 3:"},13:{acc:3,desc:"Research 6x24,8x4:"},14:{acc:3,desc:"Challenge 12:"},15:{acc:3,desc:"Research 8x25:"},16:{acc:3,desc:"Ascension Count Achievement:"},17:{acc:3,desc:"Sun and Moon Achievements:"},18:{acc:3,desc:"Cube Upgrade 5x6:"},19:{acc:3,desc:"Cube Upgrade 5x10:"},20:{acc:3,desc:"Platonic ALPHA:"},21:{acc:3,desc:"Platonic BETA:"},22:{acc:3,desc:"Platonic OMEGA:"},23:{acc:3,desc:"Challenge 15:"},24:{acc:3,desc:"Starter Pack:"},25:{acc:3,desc:"Offering Charge [GQ]:"},26:{acc:3,desc:"Offering Storm [GQ]:"},27:{acc:3,desc:"Offering Tempest [GQ]:"},28:{acc:3,desc:"Citadel [GQ]"},29:{acc:3,desc:"Citadel 2 [GQ]"},30:{acc:3,desc:"Cube Upgrade Cx4:"},31:{acc:3,desc:"Offering Electrolosis [OC]:"},32:{acc:3,desc:"RNG-based Offering Booster:"},33:{acc:3,desc:"Cube Upgrade Cx21:"},34:{acc:3,desc:"20 Ascensions X20 [EXALT ONLY]"},35:{acc:3,desc:"Shop EX ULTIMATE"},36:{acc:3,desc:"Event:"}};for(let n=0;n{i("sObt1").textContent=`x${d(e.upgrades[69]>0?Math.min(10,new f(f.pow(f.log(o.reincarnationPointGain.add(10),10),.5)).toNumber()):1,2)}`,i("sObt2").textContent=`x${d(e.upgrades[72]>0?Math.min(50,1+2*e.challengecompletions[6]+2*e.challengecompletions[7]+2*e.challengecompletions[8]+2*e.challengecompletions[9]+2*e.challengecompletions[10]):1,2)}`,i("sObt3").textContent=`x${d(e.upgrades[74]>0?1+4*Math.min(1,Math.pow(e.maxofferings/1e5,.5)):1,2)}`,i("sObt4").textContent=`x${d(1+e.researches[65]/5,2)}`,i("sObt5").textContent=`x${d(1+e.researches[76]/10,2)}`,i("sObt6").textContent=`x${d(1+e.researches[81]/10,2)}`,i("sObt7").textContent=`x${d(1+e.shopUpgrades.obtainiumAuto/50,3)}`,i("sObt8").textContent=`x${d(1+e.shopUpgrades.cashGrab/100,3)}`,i("sObt9").textContent=`x${d(1+e.shopUpgrades.obtainiumEX/50,3)}`,i("sObt10").textContent=`x${d(1+o.rune5level/200*o.effectiveLevelMult*(1+e.researches[84]/200*(1+1*o.effectiveRuneSpiritPower[5]*Xe()/400)),3)}`,i("sObt11").textContent=`x${d(1+.01*e.achievements[84]+.03*e.achievements[91]+.05*e.achievements[98]+.07*e.achievements[105]+.09*e.achievements[112]+.11*e.achievements[119]+.13*e.achievements[126]+.15*e.achievements[133]+.17*e.achievements[140]+.19*e.achievements[147],2)}`,i("sObt12").textContent=`x${d(1+2*Math.pow((e.antUpgrades[10-1]+o.bonusant10)/50,2/3),3)}`,i("sObt13").textContent=`x${d(1+e.achievements[188]*Math.min(2,e.ascensionCount/5e6),3)}`,i("sObt14").textContent=`x${d(1+.6*e.achievements[250]+1*e.achievements[251],2)}`,i("sObt15").textContent=`x${d(o.cubeBonusMultiplier[5],3)}`,i("sObt16").textContent=`x${d(1+.04*e.constantUpgrades[4],2)}`,i("sObt17").textContent=`x${d(1+.1*e.cubeUpgrades[3],2)}`,i("sObt18").textContent=`x${d(1+.1*e.cubeUpgrades[47],3)}`,i("sObt19").textContent=`x${d(1+.5*_("ascension",e.challengecompletions[12]),2)}`,i("sObt20").textContent=`x${d(1+Xe()/400*o.effectiveRuneSpiritPower[4],4)}`,i("sObt21").textContent=`x${d(1+.03*Math.log(e.uncommonFragments+1)/Math.log(4)*e.researches[144],3)}`,i("sObt22").textContent=`x${d(1+.02/100*e.cubeUpgrades[50],4)}`,i("sObt23").textContent=`x${d(e.achievements[53]>0?1+1/800*o.runeSum:1,3)}`,i("sObt24").textContent=`x${d((e.achievements[128]?1.5:1)*(e.achievements[129]?1.25:1),3)}`,i("sObt25").textContent=`+${d(e.achievements[51]>0?4:1,3)}`,i("sObt26").textContent=`+${d((e.reincarnationcounter>=2?1*e.researches[63]:1)+(e.reincarnationcounter>=5?2*e.researches[64]:1),2)}`,i("sObt27").textContent=`x${d((e.reincarnationcounter>=5?Math.max(1,e.reincarnationcounter/10):1)*Math.min(1,Math.pow(e.reincarnationcounter/10,2)),3)}`,i("sObt28").textContent=`x${d(Math.pow(f.log(e.transcendShards.add(1),10)/300,2),2)}`,i("sObt29").textContent=`^${d(Math.min(1,o.illiteracyPower[e.usedCorruptions[5]]*(1+9/100*e.platonicUpgrades[9]*Math.min(100,Math.log10(e.researchPoints+10)))),3)}`,i("sObt30").textContent=`x${d(1+4/100*e.cubeUpgrades[42]+1+3/100*e.cubeUpgrades[43],2)}`,i("sObt31").textContent=`x${d(1+e.platonicUpgrades[5],2)}`,i("sObt32").textContent=`x${d(1+1.5*e.platonicUpgrades[9],2)}`,i("sObt33").textContent=`x${d(1+2.5*e.platonicUpgrades[10],2)}`,i("sObt34").textContent=`x${d(1+5*e.platonicUpgrades[15],2)}`,i("sObt35").textContent=`x${d(o.challenge15Rewards.obtainium,3)}`,i("sObt36").textContent=`x${d(1+5*(e.singularityUpgrades.starterPack.getEffect().bonus?1:0),2)}`,i("sObt37").textContent=`x${d(+e.singularityUpgrades.singObtainium1.getEffect().bonus,2)}`,i("sObt38").textContent=`x${d(+e.singularityUpgrades.singObtainium2.getEffect().bonus,2)}`,i("sObt39").textContent=`x${d(+e.singularityUpgrades.singObtainium3.getEffect().bonus,2)}`,i("sObt40").textContent=`x${d(1+e.cubeUpgrades[55]/100,2)}`,i("sObt41").textContent=`x${d(1+1/200*e.shopUpgrades.cashGrab2,3)}`,i("sObt42").textContent=`x${d(1+1/100*e.shopUpgrades.obtainiumEX2*e.singularityCount,2)}`,i("sObt43").textContent=`x${d(1+Ye(9),2)}`,i("sObt44").textContent=`x${d(+e.singularityUpgrades.singCitadel.getEffect().bonus,2)}`,i("sObt45").textContent=`x${d(+e.singularityUpgrades.singCitadel2.getEffect().bonus,2)}`,i("sObt46").textContent=`x${d(+e.octeractUpgrades.octeractObtainium1.getEffect().bonus,2)}`,i("sObt47").textContent=`x${d(Math.pow(1.02,e.shopUpgrades.obtainiumEX3),2)}`,i("sObt48").textContent=`x${d(Mo(),2)}`,i("sObt49").textContent=`x${d(e.currentChallenge.ascension===15?1+7*e.cubeUpgrades[62]:1,2)}`,i("sObt50").textContent=`x${d(1+.001*+e.blueberryUpgrades.ambrosiaObtainium1.bonus.obtainiumMult,2)}`,i("sObt51").textContent=`x${d(ku(),2)}`,i("sObt52").textContent=`x${d(So(),2)}`,i("sObt53").textContent=`x${d(Math.pow(1.04,e.cubeUpgrades[71]*ae(e.talismanRarity)),2)}`,i("sObt54").textContent=`/${d(Le("Obtainium"),2)}`,i("sObt55").textContent=`^${d(e.usedCorruptions[5]>=15?1/4:1,2)}`,i("sObt56").textContent=`^${d(e.usedCorruptions[5]>=16?1/4:1,2)}`,i("sObt57").textContent=`x${d(e.currentChallenge.ascension===14?0:1,2)}`,i("sObtT").textContent=`x${d(o.obtainiumGain,3)}`},Nv=()=>{let t=Ar().list,r={1:{acc:2,desc:"Base:"},2:{acc:2,desc:"Challenge 15 Bonus:"},3:{acc:2,desc:"Powder EX:"},4:{acc:2,desc:"Achievement 256:"},5:{acc:2,desc:"Achievement 257:"},6:{acc:2,desc:"Platonic Upgrade 16 [4x1]:"},7:{acc:2,desc:"Event:"}};for(let n=0;n{let t=Mu(),r={1:{acc:2,desc:"Chronometer:"},2:{acc:2,desc:"Chronometer 2:"},3:{acc:2,desc:"Chronometer 3:"},4:{acc:2,desc:"Chronos Hepteract:"},5:{acc:2,desc:"Achievement 262 Bonus:"},6:{acc:2,desc:"Achievement 263 Bonus:"},7:{acc:2,desc:"Platonic Omega:"},8:{acc:2,desc:"Challenge 15 Reward:"},9:{acc:2,desc:"Cookie Upgrade 9:"},10:{acc:2,desc:"Intermediate Pack:"},11:{acc:2,desc:"Chronometer Z:"},12:{acc:2,desc:"Abstract Photokinetics:"},13:{acc:2,desc:"Abstract Exokinetics:"},14:{acc:2,desc:"Event:"},15:{acc:2,desc:"Ascension Speedup 2 [GQ]:"},16:{acc:2,desc:"Chronometer INF:"},17:{acc:2,desc:"Limited Ascensions Penalty:"},18:{acc:2,desc:"Limited Ascensions Reward:"},19:{acc:2,desc:"Ascension Speedup [GQ]:"},20:{acc:2,desc:"Singularity Penalty:"},21:{acc:2,desc:"EXALT 6: The Great Singularity Speedrun:"},22:{acc:2,desc:"Shop Chronometer S:"}};for(let n=0;n{var n;let t=Su(),r={1:{acc:2,desc:"PseudoCoin Bonus:",color:"gold"},2:{acc:2,desc:"Challenge 15 Exponent:"},3:{acc:2,desc:"Patreon Bonus:"},4:{acc:2,desc:"Golden Quarks I:"},5:{acc:2,desc:"Cookie Upgrade 19:"},6:{acc:2,desc:"No Singularity Upgrades:"},7:{acc:2,desc:"Event:"},8:{acc:2,desc:"Singularity Fast Forwards:"},9:{acc:2,desc:"Golden Revolution II:"},10:{acc:2,desc:"Immaculate Alchemy:"},11:{acc:2,desc:"Total Quarks Coefficient:"}};for(let a=0;a{var g;let t=Ha(),r=xo(),n=Xn(),a=ml(),s={1:{acc:0,desc:"Base:"},2:{acc:2,desc:"PL-AT \u03B4 calculator:"},3:{acc:2,desc:"PL-AT \u03A3 sing perk:"},4:{acc:2,desc:"Ascension of Ant God:"},5:{acc:2,desc:"Singularity factor:"}};t.list[0]/=1e3;for(let m=0;m=.5?i("s+eff1").textContent=`+${d(p*c.minQuarks,3)} ~ ${d(p*c.maxQuarks,3)}`:i("s+eff1").textContent=`+${d(p*c.quarks,3)}`,i("stat+eff2").childNodes[0].textContent="PL-AT X - bonus ascension time: ",i("s+eff2").textContent=`+${d(c.ascensionTimer,2)} sec`,i("stat+eff3").childNodes[0].textContent="PL-AT \u0393 - bonus GQ export time: ",i("s+eff3").textContent=`+${d(c.gqTimer,2)} sec`,i("stat+eff4").childNodes[0].textContent="PL-AT _ - bonus octeract time: ",i("s+eff4").textContent=`+${d(c.octeractTime,2)} sec`},Gv=()=>{var s;let t=Ge(),r=t.array,n={1:{acc:0,desc:"Base Value"},2:{acc:0,desc:"PseudoCoin Upgrade",color:"gold"},3:{acc:0,desc:"Irish Ants Singularity Perk"},4:{acc:1,desc:"Shop Upgrade Bonus"},5:{acc:0,desc:"Singularity Ambrosia Luck Upgrades"},6:{acc:0,desc:"Octeract Ambrosia Luck Upgrades"},7:{acc:0,desc:"Ambrosia Luck Module I"},8:{acc:1,desc:"Ambrosia Luck Module II"},9:{acc:2,desc:"Ambrosia Cube-Luck Hybrid Module I"},10:{acc:2,desc:"Ambrosia Quark-Luck Hybrid Module I"},11:{acc:0,desc:"Primal Power: One Hundred Thirty One!"},12:{acc:0,desc:"Primal Power: Two Hundred Sixty Nine!"},13:{acc:0,desc:"Shop: Octeract-Based Ambrosia Luck"},14:{acc:0,desc:"No Ambrosia Upgrades EXALT"},15:{acc:0,desc:"Cube Upgrade Cx27"},16:{acc:0,desc:"Red Bar Fills with Cx29"},17:{acc:0,desc:"ULTRA Upgrade: Ambrosia Exalter"}};for(let l=0;l{var s;let t=De(),r=t.array,n={1:{acc:4,desc:"Visited Ambrosia Subtab"},2:{acc:4,desc:"PseudoCoin Upgrade",color:"gold"},3:{acc:4,desc:"Number of Blueberries"},4:{acc:4,desc:"Shop Upgrade Bonus"},5:{acc:4,desc:"Singularity Ambrosia Generation Upgrades"},6:{acc:4,desc:"Octeract Ambrosia Generation Upgrades"},7:{acc:4,desc:"Patreon Bonus"},8:{acc:4,desc:"One Ascension Challenge EXALT"},9:{acc:4,desc:"No Ambrosia Upgrades EXALT"},10:{acc:4,desc:"Cube Upgrade Cx26"},11:{acc:4,desc:"Cash-Grab ULTIMATE"},12:{acc:4,desc:"Event Bonus"}};for(let l=0;l{let t=[750,1500,3e3,5e3,7500,7500,1e4,1e4,2e4,4e4,6e4,1e5,1e5,2e5,5e5,1e6,3e6,1e7,3e7,1e8,5e8,2e9,1e10,1e11,1e15,2e15,4e15,7e15,1e16,2e16,333e14,333e14,333e14,2e17,15e17],r=Object.keys(o.challenge15Rewards),n=e.challenge15Exponent;for(let a in o.challenge15Rewards)o.challenge15Rewards[a]=1;o.challenge15Rewards.freeOrbs=0,n>=t[0]&&(o.challenge15Rewards[r[0]]=1+1/50*Math.log(n/175)/Math.log(2)),n>=t[1]&&(o.challenge15Rewards[r[1]]=1+1/20*Math.log(n/375)/Math.log(2)),n>=t[2]&&(o.challenge15Rewards[r[2]]=1+1/150*Math.log(n/750)/Math.log(2)),n>=t[3]&&(o.challenge15Rewards[r[3]]=Math.pow(.98,Math.log(n/1250)/Math.log(2))),n>=t[4]&&(o.challenge15Rewards[r[4]]=1+1/5*Math.pow(n/7500,.75)),n>=t[5]&&(o.challenge15Rewards[r[5]]=1+1/5*Math.pow(n/7500,.75)),n>=t[6]&&(o.challenge15Rewards[r[6]]=1+1/20*Math.log(n/2500)/Math.log(2)),n>=t[7]&&(o.challenge15Rewards[r[7]]=1+1/20*Math.log(n/2500)/Math.log(2)),n>=t[8]&&(o.challenge15Rewards[r[8]]=1+Math.pow(n/2e4,1.5)),n>=t[9]&&(o.challenge15Rewards[r[9]]=1+1/33*Math.log(n/1e4)/Math.log(2)),n>=t[10]&&(o.challenge15Rewards[r[10]]=1+1/100*Math.log(n/15e3)/Math.log(2)),n>=t[11]&&(o.challenge15Rewards[r[11]]=Math.pow(.98,Math.log(n/25e3)/Math.log(2))),n>=t[12]&&(o.challenge15Rewards[r[12]]=Math.pow(.98,Math.log(n/25e3)/Math.log(2))),n>=t[13]&&(o.challenge15Rewards[r[13]]=Math.pow(1+Math.log(n/2e5)/Math.log(2),4)),n>=t[14]&&(o.challenge15Rewards[r[14]]=1+1/20*Math.log(n/15e4)/Math.log(2)),n>=t[15]&&(o.challenge15Rewards[r[15]]=1+1/150*Math.log(n/25e4)/Math.log(2)),n>=t[16]&&(o.challenge15Rewards[r[16]]=1+1/20*Math.log(n/75e4)/Math.log(2)),n>=t[17]&&(o.challenge15Rewards[r[17]]=1+1/20*Math.log(n/25e5)/Math.log(2)),n>=t[18]&&(o.challenge15Rewards[r[18]]=1+1/5*Math.pow(n/3e7,1/4)),n>=t[19]&&(o.challenge15Rewards[r[19]]=1+1/5*Math.pow(n/1e8,2/3)),n>=t[20]&&(o.challenge15Rewards[r[20]]=1+1/200*Math.log(n/125e6)/Math.log(2)),n>=t[21]&&(o.challenge15Rewards[r[21]]=1+1/5*Math.pow(n/2e9,1/4)),n>=t[22]&&(o.challenge15Rewards[r[22]]=1+1/4*Math.pow(n/1e10,1/4),n>=1e20&&(o.challenge15Rewards[r[22]]=1+1/4*Math.pow(n/1e10,1/8)*Math.pow(1e10,1/8))),n>=t[23]&&(o.challenge15Rewards[r[23]]=1+1/100*Math.log(n*32/1e11)/Math.log(2)),n>=t[24]&&(o.challenge15Rewards[r[24]]=2),n>=t[25]&&e.hepteractCrafts.challenge.unlock("the Hepteract of Challenge"),n>=t[26]&&(o.challenge15Rewards[r[25]]=1+1/300*Math.log2(n/(4e15/1024))),n>=t[27]&&(o.challenge15Rewards[r[26]]=1+1/50*Math.log2(n/(7e15/32))),n>=t[28]&&e.hepteractCrafts.abyss.unlock("the Hepteract of the Abyss"),n>=t[29]&&(o.challenge15Rewards[r[27]]=pt(1.05,n,1e18)),n>=t[30]&&e.hepteractCrafts.accelerator.unlock("the Hepteract of Way Too Many Accelerators"),n>=t[31]&&e.hepteractCrafts.acceleratorBoost.unlock("the Hepteract of Way Too Many Accelerator Boosts"),n>=t[32]&&e.hepteractCrafts.multiplier.unlock("the Hepteract of Way Too Many Multipliers"),n>=t[33]&&(o.challenge15Rewards.freeOrbs=Math.floor(200*Math.pow(n/2e17,.5))),n>=t[34]&&(o.challenge15Rewards.ascensionSpeed=1+5/100+2*Math.log2(n/15e17)/100),Fv()},Fv=()=>{i("c15Reward0Num").textContent=d(e.challenge15Exponent,3,!0),i("c15RequiredExponentNum").textContent=d(f.pow(10,e.challenge15Exponent/ko()),0,!0);let t=[750,1500,3e3,5e3,7500,7500,1e4,1e4,2e4,4e4,6e4,1e5,1e5,2e5,5e5,1e6,3e6,1e7,3e7,1e8,5e8,2e9,1e10,1e11,1e15,2e15,4e15,7e15,1e16,2e16,333e14,333e14,333e14,2e17,15e17],r={0:!0,1:!0,2:!0,3:!0,4:!0,5:!0,6:!0,7:!0,8:!0,9:!0,10:!0,11:!0,12:!0,13:!0,14:!0,15:!0,16:!0,17:!0,18:!0,19:!0,20:!0,21:!0,22:!0,23:!0,24:!1,25:!1,26:!0,27:!0,28:!1,29:!0,30:!1,31:!1,32:!1,33:!0,34:!0},n=Object.values(o.challenge15Rewards),a="None",s=0;for(let l=0;l=t[l]&&(i(`c15Reward${l+1}Num`).textContent=r[l]?d(100*n[l-s]-100,2,!0):u.t("wowCubes.unlocked"),!r[l]&&l!==24&&(s+=1),l===33&&(i("c15Reward34Num").textContent=d(n[l-s],0,!0))),i(`c15Reward${l+1}`).style.display=e.challenge15Exponent>=t[l]?"block":"none",i("c15RewardList").textContent=typeof a=="string"?"You have unlocked all reward types from Challenge 15!":`Next reward type requires ${d(a,0,!0)} exponent.`},Qv=()=>[{stage:0,tier:1,name:"start",unlocked:!0,reset:!0},{stage:1,tier:1,name:"start-prestige",unlocked:e.unlocks.prestige,reset:e.unlocks.prestige},{stage:2,tier:2,name:"prestige-transcend",unlocked:e.unlocks.transcend,reset:e.unlocks.transcend},{stage:3,tier:3,name:"transcend-reincarnate",unlocked:e.unlocks.reincarnate,reset:e.unlocks.reincarnate},{stage:4,tier:4,name:"reincarnate-ant",unlocked:e.firstOwnedAnts!==0,reset:e.unlocks.reincarnate},{stage:5,tier:4,name:"ant-sacrifice",unlocked:e.achievements[173]===1,reset:e.unlocks.reincarnate},{stage:6,tier:4,name:"sacrifice-ascension",unlocked:e.achievements[183]===1,reset:e.unlocks.reincarnate},{stage:7,tier:5,name:"ascension-challenge10",unlocked:e.ascensionCount>1,reset:e.achievements[183]===1},{stage:8,tier:5,name:"challenge10-challenge11",unlocked:e.achievements[197]===1,reset:e.achievements[183]===1},{stage:9,tier:5,name:"challenge11-challenge12",unlocked:e.achievements[204]===1,reset:e.achievements[183]===1},{stage:10,tier:5,name:"challenge12-challenge13",unlocked:e.achievements[211]===1,reset:e.achievements[183]===1},{stage:11,tier:5,name:"challenge13-challenge14",unlocked:e.achievements[218]===1,reset:e.achievements[183]===1},{stage:12,tier:5,name:"challenge14-w5x10max",unlocked:e.cubeUpgrades[50]>=1e5,reset:e.achievements[183]===1},{stage:13,tier:5,name:"w5x10max-alpha",unlocked:e.platonicUpgrades[5]>0,reset:e.achievements[183]===1},{stage:14,tier:5,name:"alpha-p2x1x10",unlocked:e.platonicUpgrades[6]>=10,reset:e.achievements[183]===1},{stage:15,tier:5,name:"p2x1x10-p3x1",unlocked:e.platonicUpgrades[11]>0,reset:e.achievements[183]===1},{stage:16,tier:5,name:"p3x1-beta",unlocked:e.platonicUpgrades[10]>0,reset:e.achievements[183]===1},{stage:17,tier:5,name:"beta-1e15-expo",unlocked:e.challenge15Exponent>=1e15,reset:e.achievements[183]===1},{stage:18,tier:5,name:"1e15-expo-omega",unlocked:e.platonicUpgrades[15]>0,reset:e.achievements[183]===1},{stage:19,tier:5,name:"omega-singularity",unlocked:e.singularityCount>0&&e.runelevels[6]>0,reset:e.achievements[183]===1},{stage:20,tier:6,name:"singularity-exalt1x1",unlocked:e.singularityChallenges.noSingularityUpgrades.completions>0,reset:e.highestSingularityCount>0},{stage:21,tier:6,name:"exalt1x1-onemind",unlocked:e.singularityUpgrades.oneMind.level>0,reset:e.highestSingularityCount>0},{stage:22,tier:6,name:"onemind-end",unlocked:e.singularityUpgrades.offeringAutomatic.level>0,reset:e.highestSingularityCount>0},{stage:23,tier:6,name:"end-pen",unlocked:e.singularityUpgrades.ultimatePen.level>0,reset:e.highestSingularityCount>0},{stage:24,tier:6,name:"pen",unlocked:!1,reset:e.highestSingularityCount>0}],wu=(t=e.singularityCount>0?5:0)=>{let r=Qv();for(let a=0;a{if(o.currentTab===0){if(o.buildingSubTab==="coin"){let t=["produceFirst","produceSecond","produceThird","produceFourth","produceFifth"],r=[null,"workers","investments","printers","coinMints","alchemies"],n=new f(o.produceTotal);n.equals(0)&&(n=new f(1));for(let s=1;s<=5;s++){let l=o[t[s-1]],c=o.ordinals[s-1];i(`buildtext${2*s-1}`).textContent=u.t(`buildings.names.${r[s]}`,{amount:d(e[`${c}OwnedCoin`],0,!0),gain:d(e[`${c}GeneratedCoin`])}),i(`buycoin${s}`).textContent=u.t("buildings.costCoins",{coins:d(e[`${c}CostCoin`])});let p=f.fromMantissaExponent(l.mantissa/n.mantissa,l.exponent-n.exponent).times(100);i(`buildtext${2*s}`).textContent=u.t("buildings.coinsPerSecond",{coins:d(l.dividedBy(o.taxdivisor).times(40),2),percent:d(p,3)})}i("buildtext11").textContent=u.t("buildings.names.accelerators",{amount:d(e.acceleratorBought,0,!0),gain:d(o.freeAccelerator,0,!0)}),i("buildtext12").textContent=u.t("buildings.acceleratorPower",{power:d((o.acceleratorPower-1)*100,2),mult:d(o.acceleratorEffect,2)}),i("buildtext13").textContent=u.t("buildings.names.multipliers",{amount:d(e.multiplierBought,0,!0),gain:d(o.freeMultiplier,0,!0)}),i("buildtext14").textContent=u.t("buildings.multiplierPower",{power:d(o.multiplierPower,2),mult:d(o.multiplierEffect,2)}),i("buildtext15").textContent=u.t("buildings.names.acceleratorBoost",{amount:d(e.acceleratorBoostBought,0,!0),gain:d(o.freeAcceleratorBoost,0,!1)}),i("buildtext16").textContent=u.t("buildings.acceleratorBoost",{amount:d(o.tuSevenMulti*(1+e.researches[16]/50)*(1+_("transcend",e.challengecompletions[2])/100),2)}),i("buyaccelerator").textContent=u.t("buildings.costCoins",{coins:d(e.acceleratorCost)}),i("buymultiplier").textContent=u.t("buildings.costCoins",{coins:d(e.multiplierCost)}),i("buyacceleratorboost").textContent=u.t("buildings.costDiamonds",{diamonds:d(e.acceleratorBoostCost)});let a="";e.reincarnationCount>.5&&(a=u.t("buildings.taxWarning",{gain:d(f.pow(10,o.maxexponent-f.log(o.taxdivisorcheck,10)))})),i("taxinfo").textContent=u.t("buildings.excessiveWealth",{div:d(o.taxdivisor,2),warning:a})}else if(o.buildingSubTab==="diamond"){let t=["produceFirstDiamonds","produceSecondDiamonds","produceThirdDiamonds","produceFourthDiamonds","produceFifthDiamonds"],r=["refineries","coalPlants","coalRigs","pickaxes","pandorasBoxes"],n=["crystal","ref","plants","rigs","pickaxes"];i("prestigeshardinfo").textContent=u.t("buildings.crystalMult",{crystals:d(e.prestigeShards,2),gain:d(o.prestigeMultiplier,2)});for(let a=1;a<=5;a++){let s=o[t[a-1]],l=o.ordinals[a-1];i(`prestigetext${2*a-1}`).textContent=u.t(`buildings.names.${r[a-1]}`,{amount:d(e[`${l}OwnedDiamonds`],0,!0),gain:d(e[`${l}GeneratedDiamonds`],2)}),i(`prestigetext${2*a}`).textContent=u.t(`buildings.per.${n[a-1]}`,{amount:d(s.times(40),2)}),i(`buydiamond${a}`).textContent=u.t("buildings.costDiamonds",{diamonds:d(e[`${l}CostDiamonds`],2)})}if(e.resettoggle1===1||e.resettoggle1===0){let a=f.pow(10,f.log(o.prestigePointGain.add(1),10)-f.log(e.prestigePoints.sub(1),10));i("autoprestige").textContent=u.t("buildings.autoPrestige",{name:"Diamonds",action:"Prestige",factor:d(f.pow(10,e.prestigeamount)),mult:d(a)})}else e.resettoggle1===2&&(i("autoprestige").textContent=u.t("buildings.autoReincarnate",{name:"Prestige",amount:e.prestigeamount,timer:d(o.autoResetTimers.prestige,1)}))}else if(o.buildingSubTab==="mythos"){let t=["produceFirstMythos","produceSecondMythos","produceThirdMythos","produceFourthMythos","produceFifthMythos"],r=["augments","enchantments","wizards","oracles","grandmasters"],n=["shards","augments","enchantments","wizards","oracles"];i("transcendshardinfo").textContent=u.t("buildings.mythosYouHave",{shards:d(e.transcendShards,2),mult:d(o.totalMultiplierBoost,0,!0)});for(let a=1;a<=5;a++){let s=o[t[a-1]],l=o.ordinals[a-1];i(`transcendtext${2*a-1}`).textContent=u.t(`buildings.names.${r[a-1]}`,{amount:d(e[`${l}OwnedMythos`],0,!0),gain:d(e[`${l}GeneratedMythos`],2)}),i(`transcendtext${2*a}`).textContent=u.t(`buildings.per.${n[a-1]}`,{amount:d(s.times(40),2)}),i(`buymythos${a}`).textContent=u.t("buildings.costMythos",{mythos:d(e[`${l}CostMythos`],2)})}(e.resettoggle2===1||e.resettoggle2===0)&&(i("autotranscend").textContent=u.t("buildings.autoPrestige",{name:"Mythos",action:"Prestige",factor:d(f.pow(10,e.transcendamount)),mult:d(f.pow(10,f.log(o.transcendPointGain.add(1),10)-f.log(e.transcendPoints.add(1),10)),2)})),e.resettoggle2===2&&(i("autotranscend").textContent=`Transcend when the autotimer is at least ${e.transcendamount} real-life seconds. [Toggle number above]. Current timer: ${d(o.autoResetTimers.transcension,1)}s.`)}else if(o.buildingSubTab==="particle"){let t=["FirstParticles","SecondParticles","ThirdParticles","FourthParticles","FifthParticles"],r=["protons","elements","pulsars","quasars","galacticNuclei"],n=["atoms","protons","elements","pulsars","quasars"];for(let a=1;a<=5;a++){let s=o.ordinals[a-1],l=o[`produce${t[a-1]}`];i(`reincarnationtext${a}`).textContent=u.t(`buildings.names.${r[a-1]}`,{amount:d(e[`${s}OwnedParticles`],0,!0),gain:d(e[`${s}GeneratedParticles`],2)}),i(`reincarnationtext${a+5}`).textContent=u.t(`buildings.per.${n[a-1]}`,{amount:d(l.times(40),2)}),i(`buyparticles${a}`).textContent=u.t("buildings.costParticles",{particles:d(e[`${s}CostParticles`],2)})}i("reincarnationshardinfo").textContent=u.t("buildings.atomsYouHave",{atoms:d(e.reincarnationShards,2),power:d(o.buildingPower,4),mult:d(o.reincarnationMultiplier)}),i("reincarnationCrystalInfo").textContent=u.t("buildings.thanksR2x14",{mult:d(f.pow(o.reincarnationMultiplier,1/50),3,!1)}),i("reincarnationMythosInfo").textContent=u.t("buildings.thanksR2x15",{mult:d(f.pow(o.reincarnationMultiplier,1/250),3,!1)}),e.resettoggle3===1||e.resettoggle3===0?i("autoreincarnate").textContent=u.t("buildings.autoPrestige",{name:"Particles",action:"Reincarnate",factor:d(f.pow(10,e.reincarnationamount)),mult:d(f.pow(10,f.log(o.reincarnationPointGain.add(1),10)-f.log(e.reincarnationPoints.add(1),10)),2)}):e.resettoggle3===2&&(i("autoreincarnate").textContent=u.t("buildings.autoReincarnate",{name:"Reincarnate",amount:e.reincarnationamount,timer:d(o.autoResetTimers.reincarnation,1)}))}else if(o.buildingSubTab==="tesseract"){let t=["dot","vector","threeSpace","bentTime","hilbertSpace"],r=["constant","dot","vector","threeSpace","bentTime"];for(let n=1;n<=5;n++){let a=`ascendBuilding${n}`;i(`ascendText${n}`).textContent=u.t(`buildings.names.${t[n-1]}`,{amount:d(e[a].owned,0,!0),gain:d(e[a].generated,2)}),i(`ascendText${5+n}`).textContent=u.t(`buildings.per.${r[n-1]}`,{amount:d(o.ascendBuildingProduction[o.ordinals[n-1]],2)}),i(`buyTesseracts${n}`).textContent=u.t("buildings.costTesseracts",{tesseracts:d(e[a].cost,0)})}i("tesseractInfo").textContent=u.t("buildings.tesseractsYouHave",{tesseracts:d(e.wowTesseracts)}),i("ascendShardInfo").textContent=u.t("buildings.constantYouHave",{const:d(e.ascendShards,2),amount:d(Math.pow(f.log(e.ascendShards.add(1),10)+1,1+.2/60*e.challengecompletions[10]*e.upgrades[125]+.1*e.platonicUpgrades[5]+.2*e.platonicUpgrades[10]+(o.platonicBonusMultiplier[5]-1)),4,!0)}),e.resettoggle4===1||e.resettoggle4===0?i("autotessbuyeramount").textContent=u.t("buildings.autoTesseract",{tesseracts:d(e.tesseractAutoBuyerAmount)}):e.resettoggle4===2&&(i("autotessbuyeramount").textContent=u.t("buildings.autoAscensionTesseract",{percent:d(Math.min(100,e.tesseractAutoBuyerAmount))}))}}},_m=()=>{},Dm=()=>{},Gm=()=>{if(o.currentTab===3){if(o.runescreen==="runes"){let t=["rune1Talisman","rune2Talisman","rune3Talisman","rune4Talisman","rune5Talisman"];i("offeringCount").textContent=u.t("runes.offeringsYouHave",{offerings:d(e.runeshards,0,!0)});for(let a=1;a<=7;a++){let s=o[t[a-1]];a>5&&(s=0);let l=e.runelevels[a-1],c=rt(a);i(`rune${a}level`).childNodes[0].textContent=u.t("cubes.cubeMetadata.level",{value1:d(l),value2:d(c)}),l0?"":"Level "} ${d(e.talismanLevels[t])}/${d(r)}`}if(o.runescreen==="blessings"){let t=[0,8,10,6.66,2,1],r=0;for(let n=1;n<=5;n++){i(`runeBlessingLevel${n}Value`).innerHTML=u.t("runes.blessings.blessingLevel",{amount:d(e.runeBlessingLevels[n])}),i(`runeBlessingPower${n}Value1`).innerHTML=u.t("runes.blessings.blessingPower",{reward:u.t(`runes.blessings.rewards.${n-1}`),value:d(o.runeBlessings[n]),speed:d(1-r+t[n]*o.effectiveRuneBlessingPower[n],4,!0)});let a=Zn(e.runeBlessingLevels[n],o.blessingBaseCost,e.runeshards,e.runeBlessingBuyAmount)[0]-e.runeBlessingLevels[n];a>0?i(`runeBlessingPurchase${n}`).classList.add("runeButtonsAvailable"):i(`runeBlessingPurchase${n}`).classList.remove("runeButtonsAvailable"),i(`runeBlessingPurchase${n}`).innerHTML=u.t("runes.blessings.increaseLevel",{amount:d(Math.max(1,a)),offerings:d(Math.max(o.blessingBaseCost*(1+e.runeBlessingLevels[n]),Zn(e.runeBlessingLevels[n],o.blessingBaseCost,e.runeshards,e.runeBlessingBuyAmount)[1]))}),n===5&&(r=1)}}if(o.runescreen==="spirits"){let t=[0,1,1,20,1,100],r=[0,0,0,1,0,0];for(let n=1;n<=5;n++){t[n]*=Xe()/400,i(`runeSpiritLevel${n}Value`).innerHTML=u.t("runes.spirits.spiritLevel",{amount:d(e.runeSpiritLevels[n])}),i(`runeSpiritPower${n}Value1`).innerHTML=u.t("runes.spirits.spiritPower",{reward:u.t(`runes.spirits.rewards.${n-1}`),value:d(o.runeSpirits[n]),speed:d(1-r[n]+t[n]*o.effectiveRuneSpiritPower[n],4,!0)});let a=Zn(e.runeSpiritLevels[n],o.spiritBaseCost,e.runeshards,e.runeSpiritBuyAmount)[0]-e.runeSpiritLevels[n];a>0?i(`runeSpiritPurchase${n}`).classList.add("runeButtonsAvailable"):i(`runeSpiritPurchase${n}`).classList.remove("runeButtonsAvailable"),i(`runeSpiritPurchase${n}`).innerHTML=u.t("runes.blessings.increaseLevel",{amount:d(Math.max(1,a)),offerings:d(Math.max(o.spiritBaseCost*(1+e.runeSpiritLevels[n]),Zn(e.runeSpiritLevels[n],o.spiritBaseCost,e.runeshards,e.runeSpiritBuyAmount)[1]))})}}}},Hm=()=>{o.currentTab===4&&e.researches[150]>0&&(i("autoIncrementerAmount").innerHTML=u.t("challenges.autoTimer",{time:d(o.autoChallengeTimerIncrement,2)}))},fl=()=>{o.currentTab===5&&e.researches[61]>0&&(i("automaticobtainium").textContent=u.t("researches.thanksToResearches",{x:d(Eo()*qe().mult,3,!0)}))},Fm=()=>{if(o.currentTab!==6)return;i("crumbcount").textContent=u.t("ants.youHaveGalacticCrumbs",{x:d(e.antPoints,2),y:d(o.antOneProduce,2),z:d(f.pow(f.max(1,e.antPoints),1e5+_t(499e5,(e.antUpgrades[1]+o.bonusant2)/5e3*500/499)))});let t=e.autoAntSacrificeMode===2?u.t("ants.modeRealTime"):u.t("ants.modeInGameTime"),r=e.autoAntSacrificeMode===2?e.antSacrificeTimerReal:e.antSacrificeTimer;i("autoAntSacrifice").textContent=u.t("ants.sacrificeWhenTimer",{x:e.autoAntSacTimer,y:t,z:d(r,2)}),e.achievements[173]===1&&(i("antSacrificeTimer").textContent=zt(e.antSacrificeTimer),Km())},hl=()=>{if(o.currentTab!==7)return;let t=e.shopUpgrades.cubeToQuark?1.5:1,r=e.shopUpgrades.tesseractToQuark?1.5:1,n=e.shopUpgrades.hypercubeToQuark?1.5:1,a=1.5,s={cube:Number(e.wowCubes.checkCubesToNextQuark(5,t,e.cubeQuarkDaily,e.cubeOpenedDaily)),tesseract:Number(e.wowTesseracts.checkCubesToNextQuark(7,r,e.tesseractQuarkDaily,e.tesseractOpenedDaily)),hypercube:Number(e.wowHypercubes.checkCubesToNextQuark(10,n,e.hypercubeQuarkDaily,e.hypercubeOpenedDaily)),platonicCube:Number(e.wowPlatonicCubes.checkCubesToNextQuark(15,a,e.platonicCubeQuarkDaily,e.platonicCubeOpenedDaily))},l=Object.keys(s);for(let p of l)i(`${p}QuarksToday`).innerHTML=u.t(`wowCubes.quarks.${p}QuarksToday`,{amount:d(e[`${p}QuarkDaily`])}),i(`${p}QuarksOpenToday`).innerHTML=u.t(`wowCubes.quarks.${p}QuarksOpenToday`,{amount:d(e[`${p}OpenedDaily`])}),i(`${p}QuarksOpenRequirement`).innerHTML=u.t(`wowCubes.quarks.${p}QuarksOpenRequirement`,{amount:d(Math.max(1,s[p]))}),i(`${p}QuarksOpenRequirement`).style.color=Math.max(1,s[p])===1?"gold":"white";let c;switch(e.subtabNumber){case 0:{e.autoOpenCubes&&(i("openCubes").textContent=u.t("wowCubes.autoOn",{percent:d(e.openCubes,0)})),i("cubeQuantity").innerHTML=u.t("wowCubes.cubes.inventory",{amount:d(e.wowCubes,0,!0)});let p=[null,e.cubeBlessings.accelerator,e.cubeBlessings.multiplier,e.cubeBlessings.offering,e.cubeBlessings.runeExp,e.cubeBlessings.obtainium,e.cubeBlessings.antSpeed,e.cubeBlessings.antSacrifice,e.cubeBlessings.antELO,e.cubeBlessings.talismanBonus,e.cubeBlessings.globalSpeed];c=[null,2,2,2,2,2,2,2,1,4,3];for(let g=1;g<=10;g++){let m=0;p[g]>=1e3&&g!==6&&(m+=2);let h=g===1||g===8||g===9?1:100;i(`cube${g}Bonus`).innerHTML=u.t(`wowCubes.cubes.items.${g}`,{amount:d(p[g],0,!0),bonus:d(h*(o.cubeBonusMultiplier[g]-1),c[g]+m,!0)})}i("cubeBlessingsTotal").innerHTML=u.t("wowCubes.cubes.total",{amount:d(ae(p.slice(1)),0,!0)});break}case 1:{e.autoOpenTesseracts&&(i("openTesseracts").textContent=u.t("wowCubes.autoOn",{percent:d(e.openTesseracts,0)})),i("tesseractQuantity").innerHTML=u.t("wowCubes.tesseracts.inventory",{amount:d(e.wowTesseracts,0,!0)});let p=[null,e.tesseractBlessings.accelerator,e.tesseractBlessings.multiplier,e.tesseractBlessings.offering,e.tesseractBlessings.runeExp,e.tesseractBlessings.obtainium,e.tesseractBlessings.antSpeed,e.tesseractBlessings.antSacrifice,e.tesseractBlessings.antELO,e.tesseractBlessings.talismanBonus,e.tesseractBlessings.globalSpeed];c=[null,2,2,2,2,2,2,2,2,2,2];for(let g=1;g<=10;g++){let m=0;p[g]>=1e3&&g!==6&&(m+=2),i(`tesseract${g}Bonus`).innerHTML=u.t(`wowCubes.tesseracts.items.${g}`,{amount:d(p[g],0,!0),bonus:d(100*(o.tesseractBonusMultiplier[g]-1),c[g]+m,!0)})}i("tesseractBlessingsTotal").innerHTML=u.t("wowCubes.tesseracts.total",{amount:d(ae(p.slice(1)),0,!0)});break}case 2:{e.autoOpenHypercubes&&(i("openHypercubes").textContent=u.t("wowCubes.autoOn",{percent:d(e.openHypercubes,0)})),i("hypercubeQuantity").innerHTML=u.t("wowCubes.hypercubes.inventory",{amount:d(e.wowHypercubes,0,!0)});let p=[null,e.hypercubeBlessings.accelerator,e.hypercubeBlessings.multiplier,e.hypercubeBlessings.offering,e.hypercubeBlessings.runeExp,e.hypercubeBlessings.obtainium,e.hypercubeBlessings.antSpeed,e.hypercubeBlessings.antSacrifice,e.hypercubeBlessings.antELO,e.hypercubeBlessings.talismanBonus,e.hypercubeBlessings.globalSpeed];c=[null,2,2,2,2,2,2,2,2,2,2];for(let g=1;g<=10;g++){let m=0;p[g]>=1e3&&(m+=2),i(`hypercube${g}Bonus`).innerHTML=u.t(`wowCubes.hypercubes.items.${g}`,{amount:d(p[g],0,!0),bonus:d(100*(o.hypercubeBonusMultiplier[g]-1),c[g]+m,!0)})}i("hypercubeBlessingsTotal").innerHTML=u.t("wowCubes.hypercubes.total",{amount:d(ae(p.slice(1)),0,!0)});break}case 3:{e.autoOpenPlatonicsCubes&&(i("openPlatonicCube").textContent=u.t("wowCubes.autoOn",{percent:d(e.openPlatonicsCubes,0)})),i("platonicQuantity").innerHTML=u.t("wowCubes.platonics.inventory",{amount:d(e.wowPlatonicCubes,0,!0)});let p=[e.platonicBlessings.cubes,e.platonicBlessings.tesseracts,e.platonicBlessings.hypercubes,e.platonicBlessings.platonics,e.platonicBlessings.hypercubeBonus,e.platonicBlessings.taxes,e.platonicBlessings.scoreBonus,e.platonicBlessings.globalSpeed],g=[4e6,4e6,4e6,8e4,1e4,1e4,1e4,1e4];c=[5,5,5,5,2,3,3,2];for(let m=0;m=g[m]&&(h+=1),i(`platonicCube${m+1}Bonus`).innerHTML=u.t(`wowCubes.platonics.items.${m+1}`,{amount:d(p[m],0,!0),bonus:d(100*(o.platonicBonusMultiplier[m]-1),c[m]+h,!0)})}i("platonicBlessingsTotal").innerHTML=u.t("wowCubes.platonics.total",{amount:d(ae(p),0,!0)});break}case 4:i("cubeAmount2").textContent=`You have ${d(e.wowCubes,0,!0)} Wow! Cubes =)`;break;case 5:break;case 6:i("hepteractQuantity").innerHTML=u.t("wowCubes.hepteractForge.youPossessHepteracts",{x:d(e.wowAbyssals,0,!0)}),Rg.forEach(p=>{qv(p)}),i("heptGridOrbBalance").textContent=d(e.overfluxOrbs),i("heptGridOrbEffect").textContent=`${d(100*(-1+_n()),2,!0)}%`,i("heptGridPowderBalance").textContent=d(e.overfluxPowder),i("heptGridPowderWarps").textContent=d(e.dailyPowderResetUses);break;default:break}},qv=t=>{let r=`${t}ProgressBarText`,n=`${t}ProgressBar`,a=i(r),s=i(n);if(!e.hepteractCrafts[t].UNLOCKED)a.textContent="LOCKED",s.style.width="100%",s.style.backgroundColor="var(--hepteract-bar-red)";else{let c=e.hepteractCrafts[t].BAL,p=e.hepteractCrafts[t].computeActualCap(),g=Math.round(c/p*100),m="";g<34?m="var(--hepteract-bar-red)":g>=34&&g<68?m="var(--hepteract-bar-yellow)":m="var(--hepteract-bar-green)",a.textContent=`${d(c)} / ${d(p)}`,s.style.width=`${g}%`,s.style.backgroundColor=m}},Qm=()=>{if(o.currentTab!==8)return;let t=Xr(),r=Lo();i("autoAscend").innerHTML=e.autoAscendMode==="c10Completions"?u.t("corruptions.autoAscend.c10Completions",{input:d(e.autoAscendThreshold),completions:d(e.challengecompletions[10])}):u.t("corruptions.autoAscend.realTime",{input:d(e.autoAscendThreshold),time:d(e.ascensionCounterRealReal)}),i("corruptionBank").innerHTML=u.t("corruptions.corruptionBank",{number:d(t[0],0,!0)}),i("corruptionScore").innerHTML=u.t("corruptions.corruptionScore",{ascScore:d(t[1],1,!0),corrMult:d(t[2],1,!0),bonusMult:d(t[9],2,!0),totalScore:d(t[3],1,!0)}),i("corruptionCubes").innerHTML=u.t("corruptions.corruptionCubes",{cubeAmount:d(t[4],0,!0)}),i("corruptionTesseracts").innerHTML=u.t("corruptions.corruptionTesseracts",{tesseractAmount:d(t[5],0,!0)}),i("corruptionHypercubes").innerHTML=u.t("corruptions.corruptionHypercubes",{hypercubeAmount:d(t[6],0,!0)}),i("corruptionPlatonicCubes").innerHTML=u.t("corruptions.corruptionPlatonics",{platonicAmount:d(t[7],0,!0)}),i("corruptionHepteracts").innerHTML=u.t("corruptions.corruptionHepteracts",{hepteractAmount:d(t[8],0,!0)}),i("corruptionAntExponent").innerHTML=u.t("corruptions.antExponent",{exponent:d((1-.9/90*ae(e.usedCorruptions))*o.extinctionMultiplier[e.usedCorruptions[7]],3)}),i("corruptionSpiritBonus").innerHTML=u.t("corruptions.spiritBonus",{multiplier:d(Xe()/400,2,!0)}),i("corruptionAscensionCount").style.display=r>1?"block":"none",r>1&&(i("corruptionAscensionCount").innerHTML=u.t("corruptions.ascensionCount",{ascCount:d(Lo())}))},qm=()=>{if(o.currentTab===10){if(e.subtabNumber===0){i("saveString").textContent=u.t("settings.currently",{x:e.saveString.replace("$VERSION$",`v${tr}`)});let t=Rt(),r=t.gain,n=t.capacity,a=1;a*=1+rr()/100,a*=e.highestSingularityCount>=100?1+e.highestSingularityCount/50:1,i("quarktimerdisplay").textContent=u.t("settings.exportQuark",{x:d(3600/t.perHour-e.quarkstimer%(3600.00001/t.perHour),2),y:e.worlds.toString(1)}),i("quarktimeramount").textContent=u.t("settings.quarksOnExport",{x:e.worlds.toString(r),y:e.worlds.toString(n)}),i("goldenQuarkTimerDisplay").textContent=u.t("settings.exportGoldenQuark",{x:d(3600/Math.max(1,+e.singularityUpgrades.goldenQuarks3.getEffect().bonus)-e.goldenQuarksTimer%(3600.00001/Math.max(1,+e.singularityUpgrades.goldenQuarks3.getEffect().bonus))),y:d(a,2,!0)}),i("goldenQuarkTimerAmount").textContent=u.t("settings.goldenQuarksOnExport",{x:d(Math.floor(e.goldenQuarksTimer*+e.singularityUpgrades.goldenQuarks3.getEffect().bonus/3600)*a,2),y:d(Math.floor(168*+e.singularityUpgrades.goldenQuarks3.getEffect().bonus*a))})}e.subtabNumber===3&&Rm()}},jm=()=>{if(o.currentTab===9){if(e.subtabNumber===0){i("goldenQuarkamount").textContent=u.t("singularity.goldenQuarkAmount",{goldenQuarks:d(e.goldenQuarks,0,!0)});let t=Object.keys(e.singularityUpgrades),r=o.shopEnhanceVision;for(let n of t){if(n==="offeringAutomatic"||n==="WIP")continue;let a=e.singularityUpgrades[n],s=i(`${String(n)}`);a.maxLevel!==-1&&a.level>=a.computeMaxLevel()?s.style.filter=r?"brightness(.9)":"none":a.getCostTNL()>e.goldenQuarks||e.singularityCounta.level?s.style.filter=r?"blur(1px) invert(.9) saturate(200)":"none":s.style.filter=r?"invert(.9) brightness(1.1)":"none")}}if(e.subtabNumber===2){let t=Object.keys(e.octeractUpgrades),r=o.shopEnhanceVision;for(let n of t){let a=e.octeractUpgrades[n],s=i(`${String(n)}`);a.maxLevel!==-1&&a.level>=a.maxLevel?s.style.filter=r?"brightness(.9)":"none":a.getCostTNL()>e.wowOcteracts?s.style.filter=r?"grayscale(.9) brightness(.8)":"none":(a.maxLevel===-1||a.levela.level?s.style.filter=r?"blur(2px) invert(.9) saturate(200)":"none":s.style.filter=r?"invert(.9) brightness(1.1)":"none")}}}},Ao=t=>{o.shopEnhanceVision=t},bl=()=>{if(o.currentTab!==9)return;i("octeractAmount").innerHTML=u.t("octeract.amount",{octeracts:d(e.wowOcteracts,2,!0,!0,!0)});let t=Kr();i("secondsPerOcteract").style.display=t<1?"block":"none",i("secondsPerOcteract").innerHTML=u.t("octeract.secondsPerOcteract",{seconds:d(1/t,2,!0)}),i("octeractPerSeconds").style.display=t>=1?"block":"none",i("octeractPerSeconds").innerHTML=u.t("octeract.octeractsPerSecond",{octeracts:d(t,2,!0)});let r=(Oo()-1)*100,n=(fn()-1)*100,a=(Au()-1)*100,s=(Mo()-1)*100;i("totalOcteractAmount").innerHTML=u.t("octeract.totalGenerated",{octeracts:d(e.totalWowOcteracts,2,!0,!0,!0)}),i("totalOcteractCubeBonus").style.display=r>=.001?"block":"none",i("totalOcteractQuarkBonus").style.display=n>=.001?"block":"none",i("totalOcteractOfferingBonus").style.display=a>=.001?"block":"none",i("totalOcteractObtainiumBonus").style.display=s>=.001?"block":"none",i("totalOcteractCubeBonus").innerHTML=u.t("octeract.generatedCubeBonus",{cubeBonus:d(r,3,!0)}),i("totalOcteractQuarkBonus").innerHTML=u.t("octeract.generatedQuarkBonus",{quarkBonus:d(n,3,!0)}),i("totalOcteractOfferingBonus").innerHTML=u.t("octeract.generatedOfferingBonus",{offeringBonus:d(a,3,!0)}),i("totalOcteractObtainiumBonus").innerHTML=u.t("octeract.generatedObtainiumBonus",{obtainiumBonus:d(s,3,!0)})},Ts=()=>{if(o.currentTab!==9)return;let t=o.ambrosiaCurrStats.ambrosiaLuck,r=o.ambrosiaCurrStats.ambrosiaLuck/o.ambrosiaCurrStats.ambrosiaAdditiveLuckMult,n=100*(o.ambrosiaCurrStats.ambrosiaAdditiveLuckMult-1),a=Math.floor(t/100),s=t-100*Math.floor(t/100),l=Ss(),c=100*(yl()-1),p=100*(To()-1),g=o.ambrosiaCurrStats.ambrosiaBlueberries-e.spentBlueberries,m=o.ambrosiaCurrStats.ambrosiaGenerationSpeed,h=Math.min(m,Math.pow(1e3*m,1/2)),b=100*Math.min(1,e.blueberryTime/l),C=100*Math.min(1,e.ultimateProgress/1e6);i("ambrosiaProgress").style.width=`${b}%`,i("ambrosiaProgressText").textContent=`${d(e.blueberryTime,0,!0)} / ${d(l,0,!0)} [+${d(m,0,!0)}/s]`,i("pixelProgress").style.width=`${C}%`,i("pixelProgressText").textContent=`${d(e.ultimateProgress,0,!0)} / ${d(1e6,0,!0)} [+${d(h,2,!0)}/s]`;let v=n>.01?`[\u2618${d(r,0,!0)} +${d(n,2,!0)}%]`:"";i("ambrosiaAmount").innerHTML=u.t("ambrosia.amount",{ambrosia:d(e.ambrosia,0,!0),lifetimeAmbrosia:d(e.lifetimeAmbrosia,0,!0)}),i("ambrosiaAmountPerGeneration").innerHTML=u.t("ambrosia.perGen",{guaranteed:d(a,0,!0),extraChance:d(s,0,!0),ambrosiaLuck:d(t,0,!0),extra:v}),i("ambrosiaRewards").innerHTML=u.t("ambrosia.bonuses",{cube:d(c,0,!0),quark:d(p,0,!0)}),i("ambrosiaBlueberries").innerHTML=u.t("ambrosia.availableBlueberries",{availableBlueberries:g}),e.cubeUpgrades[76]>0?(i("cubeUpgradeThresholds").style.display="block",i("cubeUpgradeThresholds").innerHTML=u.t("ambrosia.cubeUpgradeThresholds",{threshold:Po(),percent:e.cubeUpgrades[76]*Po()})):i("cubeUpgradeThresholds").style.display="none",e.cubeUpgradeRedBarFilled>0?(i("cubeUpgradeRedBarFills").style.display="block",i("cubeUpgradeRedBarFills").innerHTML=u.t("ambrosia.cubeUpgradeRedBarFills",{amount:d(e.cubeUpgradeRedBarFilled,0,!0),luck:d(Math.min(100,e.cubeUpgradeRedBarFilled/50),2,!0)})):i("cubeUpgradeRedBarFills").style.display="none"},Lu=()=>{if(o.currentTab!==11)return;i("quarkamount").textContent=u.t("shop.youHaveQuarks",{x:d(e.worlds,0,!0)}),i("offeringpotionowned").textContent=d(e.shopUpgrades.offeringPotion,0,!0),i("obtainiumpotionowned").textContent=d(e.shopUpgrades.obtainiumPotion,0,!0);let t=Object.keys(e.shopUpgrades);for(let r of t){let n=pe[r];if(n.type==="consume"){let a=Math.min(Math.floor(Number(e.worlds)/$a(r)),n.maxLevel-e.shopUpgrades[r]),s=i(`buy${r.toLowerCase()}`);switch(e.shopBuyMaxToggle){case!1:s.textContent="BUY: 100 Quarks Each";break;case"TEN":s.textContent=`+${Math.min(10,a)} for ${d($a(r)*Math.min(10,a),0,!0)} Quarks`;break;default:s.textContent=`+${a} for ${d($a(r)*a)} Quarks`}}if(n.type==="upgrade"){if(e.shopHideToggle&&e.shopUpgrades[r]>=n.maxLevel&&!n.refundable){i(`${r}Hide`).style.display="none";continue}else i(`${r}Hide`).style.display=xs(r)?"block":"none";n.maxLevel===1?i(`${r}Level`).textContent=e.shopUpgrades[r]>=n.maxLevel?"Bought!":"Not Bought!":i(`${r}Level`).textContent=`${e.highestSingularityCount>0||e.ascensionCount>0?"":"Level "}${d(e.shopUpgrades[r])}/${d(n.maxLevel)}`;let a=n.maxLevel-e.shopUpgrades[r],s;switch(e.shopBuyMaxToggle){case!1:i(`${r}Button`).textContent=e.shopUpgrades[r]>=n.maxLevel?u.t("shop.maxed"):u.t("shop.upgradeFor",{x:d($a(r))});break;case"TEN":s=sr(e.shopUpgrades[r],n.price,+e.worlds,n.priceIncrease/n.price,Math.min(10,a)),i(`${r}Button`).textContent=e.shopUpgrades[r]>=n.maxLevel?u.t("shop.maxed"):u.t("shop.plusForQuarks",{x:d(s.levelCanBuy-e.shopUpgrades[r],0,!0),y:d(s.cost)});break;default:s=sr(e.shopUpgrades[r],n.price,+e.worlds,n.priceIncrease/n.price,a),i(`${r}Button`).textContent=e.shopUpgrades[r]>=n.maxLevel?u.t("shop.maxed"):u.t("shop.plusForQuarks",{x:d(s.levelCanBuy-e.shopUpgrades[r],0,!0),y:d(s.cost)})}}}i("buySingularityQuarksAmount").textContent=`${e.goldenQuarks<1e3?"Owned: ":""}${d(e.goldenQuarks)}`,i("buySingularityQuarksButton").textContent=`Buy! ${d(Gc().cost)} Quarks Each`},Vm=()=>{},Wm=()=>{};var zm=t=>{var a;let r=(a=t.getAttribute("toggleId"))!=null?a:1;e.toggles[+r]?e.toggles[+r]=!1:e.toggles[+r]=!0;let n=t.getAttribute("format");if(n==="$"||n==="[$]"){let s=e.toggles[+r]?u.t("general.on"):u.t("general.off");t.textContent=n==="[$]"?`[${s}]`:s}else if(n==="Auto Catalyze: $"){let s=e.toggles[+r]?u.t("shop.autoCatalyzeOn"):u.t("shop.autoCatalyzeOff");t.textContent=s}else if(n==="Hover-to-Buy [$]"){let s=e.toggles[+r]?u.t("researches.hoverToBuyOn"):u.t("researches.hoverToBuyOff");t.textContent=s}else if(n==="Auto: $"){let s=e.toggles[+r]?u.t("general.autoOnColon"):u.t("general.autoOffColon");t.textContent=s}else if(n){let s=n.replace("$",e.toggles[+r]?"ON":"OFF");t.textContent=s}else t.textContent=e.toggles[+r]?u.t("general.autoOnBracket"):u.t("general.autoOffBracket");t.style.border=`2px solid ${e.toggles[+r]?"green":"red"}`},hr=(t,r=!1)=>{t<=5&&((e.currentChallenge.ascension!==15||e.ascensionCounter>=2)&&(e.currentChallenge.transcension=t,Pe("transcensionChallenge",!1,"enterChallenge"),e.transcendCount-=1),!e.currentChallenge.reincarnation&&!document.querySelector(".resetbtn.hover")&&st("transcensionChallenge")),t>=6&&t<11&&((e.currentChallenge.ascension!==15||e.ascensionCounter>=2)&&(e.currentChallenge.reincarnation=t,Pe("reincarnationChallenge",!1,"enterChallenge"),e.reincarnationCount-=1),document.querySelector(".resetbtn.hover")||st("reincarnationChallenge")),t>=11&&(!r&&!e.toggles[31]||e.challengecompletions[10]>0||e.currentChallenge.transcension===0&&e.currentChallenge.reincarnation===0&&e.currentChallenge.ascension===0)&&(e.currentChallenge.ascension===15&&Ae("ascensionChallenge",!1,!0),e.currentChallenge.ascension=t,Pe("ascensionChallenge",!1,"enterChallenge")),Lr(),Ml(t),t<=10&&!r&&e.autoChallengeRunning&&Bo(),e.currentChallenge.transcension!==0&&e.currentChallenge.reincarnation!==0&&e.currentChallenge.ascension!==0&&e.achievements[238]<1&&R(238)},Xm=(t,r)=>{e[`${r}buyamount`]=t;let n=["one","ten","hundred","thousand","10k","100k"][t.toString().length-1];i(`${r}${n}`).style.backgroundColor="Green",t!==1&&(i(`${r}one`).style.backgroundColor=""),t!==10&&(i(`${r}ten`).style.backgroundColor=""),t!==100&&(i(`${r}hundred`).style.backgroundColor=""),t!==1e3&&(i(`${r}thousand`).style.backgroundColor=""),t!==1e4&&(i(`${r}10k`).style.backgroundColor=""),t!==1e5&&(i(`${r}100k`).style.backgroundColor="")},Yn=t=>{if(t)e.shoptoggles[t]=!e.shoptoggles[t],i(`${t}AutoUpgrade`).style.borderColor=e.shoptoggles[t]?"green":"red",e.shoptoggles[t]?i(`${t}AutoUpgrade`).textContent=u.t("general.autoOnColon"):i(`${t}AutoUpgrade`).textContent=u.t("general.autoOffColon");else{let r=Object.keys(e.shoptoggles);for(let n of r){let a=e.shoptoggles[n]?"green":"red";e.shoptoggles[n]?i(`${n}AutoUpgrade`).textContent=u.t("general.autoOnColon"):i(`${n}AutoUpgrade`).textContent=u.t("general.autoOffColon"),i(`${n}AutoUpgrade`).style.borderColor=a}}},Uo=t=>{t===1?e.resettoggle1===1||e.resettoggle1===0?(e.resettoggle1=2,i("prestigeautotoggle").textContent=u.t("toggles.modeTime")):(e.resettoggle1=1,i("prestigeautotoggle").textContent=u.t("toggles.modeAmount")):t===2?e.resettoggle2===1||e.resettoggle2===0?(e.resettoggle2=2,i("transcendautotoggle").textContent=u.t("toggles.modeTime")):(e.resettoggle2=1,i("transcendautotoggle").textContent=u.t("toggles.modeAmount")):t===3?e.resettoggle3===1||e.resettoggle3===0?(e.resettoggle3=2,i("reincarnateautotoggle").textContent=u.t("toggles.modeTime")):(e.resettoggle3=1,i("reincarnateautotoggle").textContent=u.t("toggles.modeAmount")):t===4&&(e.resettoggle4===1||e.resettoggle4===0?(e.resettoggle4=2,i("tesseractautobuymode").textContent=u.t("toggles.modePercentage")):(e.resettoggle4=1,i("tesseractautobuymode").textContent=u.t("toggles.modeAmount")))},Zm=()=>{e.tesseractAutoBuyerToggle===1||e.tesseractAutoBuyerToggle===0?(e.tesseractAutoBuyerToggle=2,i("tesseractautobuytoggle").textContent=u.t("runes.talismans.autoBuyOff"),i("tesseractautobuytoggle").style.border="2px solid red"):(e.tesseractAutoBuyerToggle=1,i("tesseractautobuytoggle").textContent=u.t("runes.talismans.autoBuyOn"),i("tesseractautobuytoggle").style.border="2px solid green")},Eu=()=>{var n;let t=Array.from(document.querySelectorAll(".auto[toggleid]"));for(let a of t){let s=a.getAttribute("format"),l=(n=a.getAttribute("toggleId"))!=null?n:1;if(s==="$"){let c=e.toggles[+l]?u.t("general.on"):u.t("general.off");a.textContent=c}else if(s==="Auto Catalyze: $"){let c=e.toggles[+l]?u.t("shop.autoCatalyzeOn"):u.t("shop.autoCatalyzeOff");a.textContent=c}else if(s==="Hover-to-Buy [$]"){let c=e.toggles[+l]?u.t("researches.hoverToBuyOn"):u.t("researches.hoverToBuyOff");a.textContent=c}else if(s==="Auto: $"){let c=e.toggles[+l]?u.t("general.autoOnColon"):u.t("general.autoOffColon");a.textContent=c}else if(s){let c=s.replace("$",e.toggles[+l]?"ON":"OFF");a.textContent=c}else a.textContent=e.toggles[+l]?u.t("general.autoOnBracket"):u.t("general.autoOffBracket");a.style.border=`2px solid ${e.toggles[+l]?"green":"red"}`}let r=Array.from(document.querySelectorAll('*[id^="tesseractAutoToggle"]'));for(let a=0;a{e.researchBuyMaxToggle?(e.researchBuyMaxToggle=!1,i("toggleresearchbuy").textContent=u.t("researches.upgradeOne")):(e.researchBuyMaxToggle=!0,i("toggleresearchbuy").textContent=u.t("researches.upgradeMax"))},Jm=()=>{let t=i("toggleautoresearch");e.autoResearchToggle||e.shopUpgrades.obtainiumAuto<1?(e.autoResearchToggle=!1,t.textContent=u.t("researches.automaticOff"),i(`res${e.autoResearch||1}`).classList.remove("researchRoomba"),e.autoResearch=0):(e.autoResearchToggle=!0,t.textContent=u.t("researches.automaticOn")),e.autoResearchToggle&&qt()&&e.autoResearchMode==="cheapest"&&(e.autoResearch=o.researchOrderByCost[e.roombaResearchIndex])},ef=()=>{let t=i("toggleautoresearchmode");e.autoResearchMode==="cheapest"||!qt()?(e.autoResearchMode="manual",t.textContent=u.t("researches.autoModeManual")):(e.autoResearchMode="cheapest",t.textContent=u.t("researches.autoModeCheapest")),i(`res${e.autoResearch||1}`).classList.remove("researchRoomba"),e.autoResearchToggle&&qt()&&e.autoResearchMode==="cheapest"&&(e.autoResearch=o.researchOrderByCost[e.roombaResearchIndex])},Ou=t=>{let r=i("toggleautosacrifice");t===0?e.autoSacrificeToggle?(e.autoSacrificeToggle=!1,r.textContent=u.t("runes.blessings.autoRuneOff"),r.style.border="2px solid red",e.autoSacrifice=0):(e.autoSacrificeToggle=!0,e.saveOfferingToggle=!1,r.textContent=u.t("runes.blessings.autoRuneOn"),r.style.border="2px solid green",i("saveOffToggle").textContent=u.t("toggles.saveOfferingsOff"),i("saveOffToggle").style.color="white"):e.autoSacrificeToggle&&e.shopUpgrades.offeringAuto>.5&&(e.autoSacrifice===t?e.autoSacrifice=0:e.autoSacrifice=t);for(let n=1;n<=5;n++)i(`rune${n}`).style.backgroundColor=e.autoSacrifice===n?"orange":"";He()},tf=()=>{let t=i("toggleautoBuyFragments");e.autoBuyFragment?(t.textContent=u.t("runes.talismans.autoBuyOff"),t.style.border="2px solid orange",t.style.color="white"):(t.textContent=u.t("runes.talismans.autoBuyOn"),t.style.border="2px solid white",t.style.color="orange"),e.autoBuyFragment=!e.autoBuyFragment},rf=t=>{o.buildingSubTab=t;let r={coin:{screen:"coinBuildings",button:"switchToCoinBuilding",subtabNumber:0},diamond:{screen:"prestige",button:"switchToDiamondBuilding",subtabNumber:1},mythos:{screen:"transcension",button:"switchToMythosBuilding",subtabNumber:2},particle:{screen:"reincarnation",button:"switchToParticleBuilding",subtabNumber:3},tesseract:{screen:"ascension",button:"switchToTesseractBuilding",subtabNumber:4}};for(let{screen:n}of Object.values(r))i(n).style.display="none";i(r[o.buildingSubTab].screen).style.display="flex",e.subtabNumber=r[o.buildingSubTab].subtabNumber},nf=t=>{let r=Number(t),n=["runes","talismans","blessings","spirits"];o.runescreen=n[r-1];for(let a=1;a<=4;a++){let s=i(`toggleRuneSubTab${a}`),l=i(`runeContainer${a}`);a===r?(s.style.border="2px solid gold",l.style.display="flex"):(s.style.border="2px solid silver",l.style.display="none")}e.subtabNumber=r-1},af=t=>{let r=Number(t);for(let n=1;n<=2;n++){let a=i(`challengesWrapper${n}`);n===r?a.style.display="block":a.style.display="none"}e.subtabNumber=r-1},sf=()=>{let t=i("toggleautofortify");e.autoFortifyToggle?(t.textContent=u.t("runes.autoFortifyOff"),t.style.border="2px solid red"):(t.textContent=u.t("runes.autoFortifyOn"),t.style.border="2px solid green"),e.autoFortifyToggle=!e.autoFortifyToggle},of=()=>{let t=i("toggleautoenhance");e.autoEnhanceToggle?(t.textContent=u.t("runes.autoEnhanceOff"),t.style.border="2px solid red"):(t.textContent=u.t("runes.autoEnhanceOn"),t.style.border="2px solid green"),e.autoEnhanceToggle=!e.autoEnhanceToggle},lf=()=>{let t=i("saveOffToggle"),r=i("toggleautosacrifice");e.saveOfferingToggle?(e.autoSacrificeToggle=!0,t.textContent=u.t("toggles.saveOfferingsOff"),t.style.color="white",r.textContent="Auto Runes: ON",r.style.border="2px solid green"):(e.autoSacrificeToggle=!1,t.textContent=u.t("toggles.saveOfferingsOn"),t.style.color="yellow",r.textContent="Auto Runes: OFF",r.style.border="2px solid red"),e.saveOfferingToggle=!e.saveOfferingToggle},cf=t=>{let r=Number(t);for(let n=1;n<=4;n++){let a=i(`singularityContainer${n}`);n===r?a.style.display="block":a.style.display="none"}e.subtabNumber=r-1,e.subtabNumber===2&&bl(),e.subtabNumber===3&&Ts()},uf=async t=>{let r=i(t);if(!r.classList.contains("subtabActive"))if(r.parentNode.querySelectorAll(".subtabActive").forEach(n=>n.classList.remove("subtabActive")),r.classList.add("subtabActive"),t==="creditssubtab"){let n=i("creditList"),a=i("artistList");if(n.childElementCount>0||a.childElementCount>0)return;if(!navigator.onLine||document.hidden)return;try{let l=await(await fetch("https://api.github.com/repos/pseudo-corp/SynergismOfficial/contributors",{headers:{Accept:"application/vnd.github.v3+json"}})).json();for(let c of l){let p=document.createElement("div");p.classList.add("credit");let g=new Image(32,32);g.src=c.avatar_url,g.alt=c.login;let m=document.createElement("a");m.href=`https://github.com/Pseudo-Corp/SynergismOfficial/commits?author=${c.login}`,m.textContent=c.login,m.target="_blank",m.rel="noopener noreferrer nofollow",p.appendChild(g),p.appendChild(m),n.appendChild(p)}}catch(s){let l=s;n.appendChild(document.createTextNode(l.toString()))}try{let l=await(await fetch("https://api.github.com/gists/01917ff476d25a141c5bad38340cd756",{headers:{Accept:"application/vnd.github.v3+json"}})).json(),c=JSON.parse(l.files["synergism_artists.json"].content);for(let p of c){let g=document.createElement("p");g.textContent=p,a.appendChild(g)}}catch(s){let l=s;n.appendChild(document.createTextNode(l.toString()))}}else t==="accountSubTab"&&Co()},df=()=>{let t=i("toggleConfirmShop");t.textContent=e.shopConfirmationToggle?u.t("shop.shopConfirmationOff"):u.t("shop.shopConfirmationOn"),e.shopConfirmationToggle=!e.shopConfirmationToggle},pf=t=>{let r=i("toggleBuyMaxShopText");if(t.shiftKey){r.textContent=u.t("shop.buyAny"),e.shopBuyMaxToggle="ANY";return}switch(e.shopBuyMaxToggle){case!1:r.innerHTML=u.t("shop.buy10"),e.shopBuyMaxToggle="TEN";break;case"TEN":r.innerHTML=u.t("shop.buyMax"),e.shopBuyMaxToggle=!0;break;default:r.innerHTML=u.t("shop.buy1"),e.shopBuyMaxToggle=!1}},gf=()=>{let t=i("toggleHideShop");t.textContent=e.shopHideToggle?u.t("shop.hideMaxedOff"):u.t("shop.hideMaxedOn"),e.shopHideToggle=!e.shopHideToggle},vl=()=>{let t=i("toggleAntMax");t.textContent=e.antMax?u.t("general.buyMaxOff"):u.t("general.buyMaxOn"),e.antMax=!e.antMax},ks=(t=0)=>{if(t===0){let r=i("toggleAutoSacrificeAnt");e.autoAntSacrifice?(e.autoAntSacrifice=!1,r.textContent=u.t("ants.autoSacrificeOff")):(e.autoAntSacrifice=!0,r.textContent=u.t("ants.autoSacrificeOn"))}else if(t===1){let r=i("autoSacrificeAntMode");e.autoAntSacrificeMode===1||e.autoAntSacrificeMode===0?(e.autoAntSacrificeMode=2,r.textContent=u.t("ants.modeRealTime")):(e.autoAntSacrificeMode=1,r.textContent=u.t("ants.modeInGameTime"))}},mf=()=>{let t=i("toggleCubeBuy");e.cubeUpgradesBuyMaxToggle?(e.cubeUpgradesBuyMaxToggle=!1,t.textContent=u.t("toggles.upgradeOneLevelWow")):(e.cubeUpgradesBuyMaxToggle=!0,t.textContent=u.t("toggles.upgradeMaxIfPossible"))},Cl=(t=!0)=>{t&&(e.autoCubeUpgradesToggle=!e.autoCubeUpgradesToggle);let r=i("toggleAutoCubeUpgrades");e.autoCubeUpgradesToggle?(r.textContent=u.t("toggles.autoUpgradeOn"),r.style.border="2px solid green"):(r.textContent=u.t("toggles.autoUpgradeOff"),r.style.border="2px solid red")},wl=(t=!0)=>{t&&(e.autoPlatonicUpgradesToggle=!e.autoPlatonicUpgradesToggle);let r=i("toggleAutoPlatonicUpgrades");e.autoPlatonicUpgradesToggle?(r.textContent=u.t("toggles.autoUpgradeOn"),r.style.border="2px solid green"):(r.textContent=u.t("toggles.autoUpgradeOff"),r.style.border="2px solid red")},ff=t=>{let r=Number(t),n=wf(7);for(let a=1;a<=n;a++){let s=i(`cubeTab${a}`);s.style.display==="flex"&&a!==r&&(s.style.display="none"),s.style.display==="none"&&a===r&&(s.style.display="flex",e.subtabNumber=a-1)}hl()},Jn=t=>{switch(t){case 1:{let r=Number.parseFloat(i("startAutoChallengeTimerInput").value)||0;e.autoChallengeTimer.start=Math.max(r,0),i("startTimerValue").innerHTML=u.t("challenges.timeStartSweep",{time:d(e.autoChallengeTimer.start,2,!0)});return}case 2:{let r=Number.parseFloat(i("exitAutoChallengeTimerInput").value)||0;e.autoChallengeTimer.exit=Math.max(r,0),i("exitTimerValue").innerHTML=u.t("challenges.timeExitChallenge",{time:d(e.autoChallengeTimer.exit,2,!0)});return}case 3:{let r=Number.parseFloat(i("enterAutoChallengeTimerInput").value)||0;e.autoChallengeTimer.enter=Math.max(r,0),i("enterTimerValue").innerHTML=u.t("challenges.timeEnterChallenge",{time:d(e.autoChallengeTimer.enter,2,!0)});return}}},hf=t=>{if(t<=15){e.autoChallengeToggles[t]=!e.autoChallengeToggles[t];let r=i("toggleAutoChallengeIgnore");r.style.border=e.autoChallengeToggles[t]?"2px solid green":"2px solid red",t>=11&&t<=15?e.autoChallengeToggles[t]?r.textContent=u.t("challenges.autoAscRunChalOn",{x:t}):r.textContent=u.t("challenges.autoAscRunChalOff",{x:t}):e.autoChallengeToggles[t]?r.textContent=u.t("challenges.autoRunChalOn",{x:t}):r.textContent=u.t("challenges.autoRunChalOff",{x:t})}},Bo=()=>{let t=i("toggleAutoChallengeStart");e.autoChallengeRunning?(t.style.border="2px solid red",t.textContent=u.t("challenges.autoChallengeSweepOff"),o.autoChallengeTimerIncrement=0,fr("OFF")):(t.style.border="2px solid gold",t.textContent=u.t("challenges.autoChallengeSweepOn"),fr("START"),o.autoChallengeTimerIncrement=0),e.autoChallengeRunning=!e.autoChallengeRunning},fr=t=>{let r=i("autoChallengeType");r.textContent=u.t(`challenges.mode${t[0]+t.slice(1).toLowerCase()}`)},Ls=(t=0)=>{if(t===0){let r=i("ascensionAutoEnable");e.autoAscend?(r.style.border="2px solid red",r.textContent=u.t("corruptions.autoAscend.off")):(r.style.border="2px solid green",r.textContent=u.t("corruptions.autoAscend.on")),e.autoAscend=!e.autoAscend}else if(t===1&&e.highestSingularityCount>=25){let r=i("ascensionAutoToggle");e.autoAscendMode==="c10Completions"?(e.autoAscendMode="realAscensionTime",r.textContent=u.t("corruptions.autoAscend.modeRealTime")):(e.autoAscendMode="c10Completions",r.textContent=u.t("corruptions.autoAscend.modeCompletions"))}},Ro=t=>{if(e.highestSingularityCount>=35){if(t===1){let r=i("openCubes"),n=i("cubeOpensInput");e.autoOpenCubes?(r.textContent=u.t("wowCubes.autoOff"),r.style.border="1px solid red",n.style.border="1px solid red"):(r.textContent=u.t("wowCubes.autoOn",{percent:d(e.openCubes,0)}),r.style.border="1px solid green",n.style.border="1px solid green"),e.autoOpenCubes=!e.autoOpenCubes}else if(t===2){let r=i("openTesseracts"),n=i("tesseractsOpensInput");e.autoOpenTesseracts?(r.textContent=u.t("wowCubes.autoOff"),r.style.border="1px solid red",n.style.border="1px solid red"):(r.textContent=u.t("wowCubes.autoOn",{percent:d(e.openTesseracts,0)}),r.style.border="1px solid green",n.style.border="1px solid green"),e.autoOpenTesseracts=!e.autoOpenTesseracts}else if(t===3){let r=i("openHypercubes"),n=i("hypercubesOpensInput");e.autoOpenHypercubes?(r.textContent=u.t("wowCubes.autoOff"),r.style.border="1px solid red",n.style.border="1px solid red"):(r.textContent=u.t("wowCubes.autoOn",{percent:d(e.openHypercubes,0)}),r.style.border="1px solid green",n.style.border="1px solid green"),e.autoOpenHypercubes=!e.autoOpenHypercubes}else if(t===4){let r=i("openPlatonicCube"),n=i("platonicCubeOpensInput");e.autoOpenPlatonicsCubes?(r.textContent=u.t("wowCubes.autoOff"),r.style.border="1px solid red",n.style.border="1px solid red"):(r.textContent=u.t("wowCubes.autoOn",{percent:d(e.openPlatonicsCubes,0)}),r.style.border="1px solid green",n.style.border="1px solid green"),e.autoOpenPlatonicsCubes=!e.autoOpenPlatonicsCubes}}},Ps=t=>{switch(t){case 1:{let r=Math.floor(Number.parseFloat(i("buyRuneBlessingInput").value))||1;e.runeBlessingBuyAmount=Math.max(r,1),i("buyRuneBlessingToggle").innerHTML=u.t("runes.blessings.buyUpTo",{amount:d(e.runeBlessingBuyAmount)});return}case 2:{let r=Math.floor(Number.parseFloat(i("buyRuneSpiritInput").value))||1;e.runeSpiritBuyAmount=Math.max(r,1),i("buyRuneSpiritToggleValue").innerHTML=u.t("runes.spirits.buyUpTo",{amount:d(e.runeSpiritBuyAmount)});return}}},bf=t=>{let r=i(`tesseractAutoToggle${t}`);e.autoTesseracts[t]?(r.textContent=u.t("general.autoOffBracket"),r.style.border="2px solid red"):(r.textContent=u.t("general.autoOnBracket"),r.style.border="2px solid green"),e.autoTesseracts[t]=!e.autoTesseracts[t]},hn=(t,r)=>{let n=e.prototypeCorruptions[t],a=Qa();if(r>0&&n0&&01&&Fa(s);Fa(o.corruptionTrigger),i("corruptionCleanseConfirm").style.visibility="hidden",e.currentChallenge.ascension===15&&Ae("ascensionChallenge",!1,!0)}Fa(t),qa()},yf=t=>{let r=t==="true";e.corruptionShowStats=r,xl()},Zr=t=>{let r=i(`unit${t}`);if(r===null){console.log(t,"platonic needs to fix");return}r.textContent=e.ascStatToggles[t]?"/s":"",t===6&&(r.textContent=""),e.ascStatToggles[t]=!e.ascStatToggles[t]},vf=async()=>{let t=await Ee(u.t("wowCubes.hepteractForge.autoCraftPercentagePrompt"));if(t===null)return e.toggles[35]?P(u.t("toggles.percentKeptAt",{x:e.hepteractAutoCraftPercentage})):void 0;let r=t.endsWith("%"),n=Number(r?t.slice(0,-1):t);if(Number.isNaN(n)||!Number.isFinite(n)||!Number.isInteger(n))return P(u.t("general.validation.finiteInt"));if(n<0||n>100)return P(u.t("toggles.percentBetweenInclusive",{x:0,y:100}));if(n===e.hepteractAutoCraftPercentage&&e.toggles[35])return P(u.t("toggles.percentKeptAt",{x:e.hepteractAutoCraftPercentage}));if(e.hepteractAutoCraftPercentage=n,i("autoHepteractPercentage").textContent=u.t("wowCubes.hepteractForge.autoSetting",{x:`${e.hepteractAutoCraftPercentage}`}),e.toggles[35])return P(u.t("toggles.onAscensionHepteractsCraft",{x:e.hepteractAutoCraftPercentage}))},Cf=()=>{e.blueberryLoadoutMode==="saveTree"?(e.blueberryLoadoutMode="loadTree",i("blueberryToggleMode").innerHTML=u.t("ambrosia.loadouts.load")):(e.blueberryLoadoutMode="saveTree",i("blueberryToggleMode").innerHTML=u.t("ambrosia.loadouts.save"))},Uu=(t=!0)=>{i("alertWrapper").style.display==="block"&&i("ok_alert").click(),(i("confirmWrapper").style.display==="block"||i("promptWrapper").style.display==="block")&&(t?i("ok_confirm").click():i("cancel_confirm").click())};var xf,st=t=>{_a(xf),xf=$t(()=>jv(t),50)},jv=t=>{i("resetofferings1").style.display="block";let r=e.currentChallenge.transcension,n=e.currentChallenge.reincarnation,a=Qr(t),s=an("resetofferings1"),l=i("resetofferings2"),c=an("resetcurrency1"),p=i("resetobtainium"),g=i("resetobtainium2"),m=i("resetinfo"),h=i("resetcurrency2");switch(t==="reincarnation"?(p.style.display="block",g.textContent=d(Math.floor(o.obtainiumGain))):(p.style.display="none",g.textContent=""),t==="ascensionChallenge"||t==="ascension"||t==="singularity"?s.style.display=l.style.display="none":s.style.display=l.style.display="block",t){case"prestige":c.src.endsWith(`Pictures/${Be[e.iconSet][0]}/Diamond.png`)||(c.src=`Pictures/${Be[e.iconSet][0]}/Diamond.png`),c.style.display="block",h.textContent=`+${d(o.prestigePointGain)}`,m.textContent=u.t("reset.details.prestige",{amount:d(e.coinsThisPrestige),timeSpent:d(e.prestigecounter)}),m.style.color="turquoise";break;case"transcension":c.src.endsWith(`Pictures/${Be[e.iconSet][0]}/Mythos.png`)||(c.src=`Pictures/${Be[e.iconSet][0]}/Mythos.png`),c.style.display="block",h.textContent=`+${d(o.transcendPointGain)}`,m.textContent=u.t("reset.details.transcension",{amount:d(e.coinsThisTranscension),timeSpent:d(e.transcendcounter)}),m.style.color="var(--orchid-text-color)";break;case"reincarnation":c.src.endsWith(`Pictures/${Be[e.iconSet][0]}/Particle.png`)||(c.src=`Pictures/${Be[e.iconSet][0]}/Particle.png`),c.style.display="block",h.textContent=`+${d(o.reincarnationPointGain)}`,m.textContent=u.t("reset.details.reincarnation",{amount:d(e.transcendShards),timeSpent:d(e.reincarnationcounter)}),m.style.color="limegreen";break;case"acceleratorBoost":c.src.endsWith(`Pictures/${Be[e.iconSet][0]}/Diamond.png`)||(c.src=`Pictures/${Be[e.iconSet][0]}/Diamond.png`),c.style.display="block",h.textContent=`-${d(e.acceleratorBoostCost)}`,m.textContent=u.t("reset.details.acceleratorBoost",{amount:d(e.prestigePoints),required:d(e.acceleratorBoostCost)}),m.style.color="cyan";break;case"transcensionChallenge":c.style.display="none",h.textContent="",r!==0?(m.style.color="aquamarine",m.textContent=u.t("reset.details.transcensionChallenge.in",{n:r,amount:d(e.coinsThisTranscension),required:d(Et(r,e.challengecompletions[r])),timeSpent:d(e.transcendcounter)})):(m.style.color="var(--crimson-text-color)",m.textContent=u.t("reset.details.transcensionChallenge.out"));break;case"reincarnationChallenge":if(c.style.display="none",h.textContent="",n!==0){let b=n>=9?"coins":"transcendShards";m.style.color="silver",m.textContent=u.t(`reset.details.reincarnationChallenge.in.${b}`,{n,amount:d(e[b]),required:d(Et(n,e.challengecompletions[n],n)),timeSpent:d(e.reincarnationcounter)})}else m.style.color="var(--crimson-text-color)",m.textContent=u.t("reset.details.reincarnationChallenge.out");break;case"ascensionChallenge":c.style.display="none",h.textContent="",m.textContent=u.t("reset.details.ascensionChallenge"),m.style.color="gold";break;case"ascension":c.style.display="none",h.textContent="",m.textContent=u.t("reset.details.ascension",{cubeAmount:d(Xr()[4],0,!0),timeSpent:d(e.ascensionCounter,0,!1),realTimeSpent:d(e.ascensionCounterRealReal,0,!1)}),m.style.color="gold";break;case"singularity":c.style.display="none",h.textContent="",m.textContent=u.t("reset.details.singularity",{gqAmount:d(Xt(),2,!0),timeSpent:d(e.singularityCounter,0,!1)}),m.style.color="lightgoldenrodyellow"}i("resetofferings2").textContent=`+${d(a)}`},br=t=>{let r=null;t===1?(r=Number.parseFloat(i("prestigeamount").value)||0,e.prestigeamount=Math.max(r,0)):t===2?(r=Number.parseFloat(i("transcendamount").value)||0,e.transcendamount=Math.max(r,0)):t===3?(r=Number.parseFloat(i("reincarnationamount").value)||0,e.reincarnationamount=Math.max(r,0)):t===4?(r=Math.floor(Number.parseFloat(i("ascensionAmount").value))||1,e.autoAscendThreshold=Math.max(r,1)):t===5&&(r=Number.parseFloat(i("autoAntSacrificeAmount").value)||0,e.autoAntSacTimer=Math.max(r,0))},Sl=()=>{let t=Math.floor(Number.parseFloat(i("tesseractAmount").value))||0;e.tesseractAutoBuyerAmount=Math.max(t,0)},Yr=t=>{let r=null;t===1?(r=Number(i("cubeOpensInput").value)||0,e.openCubes=Math.max(Math.min(r,100),0)):t===2?(r=Number(i("tesseractsOpensInput").value)||0,e.openTesseracts=Math.max(Math.min(r,100),0)):t===3?(r=Number(i("hypercubesOpensInput").value)||0,e.openHypercubes=Math.max(Math.min(r,100),0)):t===4&&(r=Number(i("platonicCubeOpensInput").value)||0,e.openPlatonicsCubes=Math.max(Math.min(r,100),0))},Vv=(t,r="unknown")=>{let n=Qr(t),a=["enterChallenge","leaveChallenge"].includes(r);if(t==="prestige"){let s={seconds:e.prestigecounter,date:Date.now(),offerings:n,kind:"prestige",diamonds:o.prestigePointGain.toString()};Ct.emit("historyAdd","reset",s)}else if(t==="transcension"||t==="transcensionChallenge"){let s={seconds:e.transcendcounter,date:Date.now(),offerings:n,kind:"transcend",mythos:o.transcendPointGain.toString()};Ct.emit("historyAdd","reset",s)}else if(t==="reincarnation"||t==="reincarnationChallenge"){if(!a||o.reincarnationPointGain.gte(e.reincarnationPoints.div(10))){let s={seconds:e.reincarnationcounter,date:Date.now(),offerings:n,kind:"reincarnate",particles:o.reincarnationPointGain.toString(),obtainium:o.obtainiumGain};Ct.emit("historyAdd","reset",s)}}else if((t==="ascension"||t==="ascensionChallenge")&&e.challengecompletions[10]>0){let s=Xr(),l={seconds:e.ascensionCounter,date:Date.now(),c10Completions:e.challengecompletions[10],usedCorruptions:e.usedCorruptions.slice(0),corruptionScore:s[3],wowCubes:s[4],wowTesseracts:s[5],wowHypercubes:s[6],wowPlatonicCubes:s[7],wowHepteracts:s[8],kind:"ascend"};r!=="enterChallenge"&&e.currentChallenge.ascension!==0&&(l.currentChallenge=e.currentChallenge.ascension),Ct.emit("historyAdd","ascend",l)}},Pe=(t,r=!1,n="unknown")=>{if(Vv(t,n),Kg(t),Tl(1),e.coins=new f("102"),e.coinsThisPrestige=new f("100"),e.firstOwnedCoin=0,e.firstGeneratedCoin=new f("0"),e.firstCostCoin=new f("100"),e.secondOwnedCoin=0,e.secondGeneratedCoin=new f("0"),e.secondCostCoin=new f("1e3"),e.thirdOwnedCoin=0,e.thirdGeneratedCoin=new f("0"),e.thirdCostCoin=new f("2e4"),e.fourthOwnedCoin=0,e.fourthGeneratedCoin=new f("0"),e.fourthCostCoin=new f("4e5"),e.fifthOwnedCoin=0,e.fifthGeneratedCoin=new f("0"),e.fifthCostCoin=new f("8e6"),e.firstGeneratedDiamonds=new f("0"),e.secondGeneratedDiamonds=new f("0"),e.thirdGeneratedDiamonds=new f("0"),e.fourthGeneratedDiamonds=new f("0"),e.fifthGeneratedDiamonds=new f("0"),e.multiplierCost=new f("1e4"),e.multiplierBought=0,e.acceleratorCost=new f("500"),e.acceleratorBought=0,e.prestigeCount+=1,e.prestigePoints=e.prestigePoints.add(o.prestigePointGain),e.prestigeShards=new f("0"),e.prestigenoaccelerator=!0,e.prestigenomultiplier=!0,e.prestigenocoinupgrades=!0,e.highestSingularityCount===0&&(t==="prestige"&&!e.unlocks.prestige&&(i("prestigebtn").style.boxShadow=""),t==="transcension"&&!e.unlocks.transcend&&(i("transcendbtn").style.boxShadow=""),t==="reincarnation"&&!e.unlocks.reincarnate&&(i("reincarnatebtn").style.boxShadow=""),t==="ascension"&&e.ascensionCount===0&&(i("ascendbtn").style.boxShadow="")),e.unlocks.prestige=!0,e.prestigecounter.5&&(e.firstOwnedDiamonds+=1),e.achievements[85]>.5&&(e.secondOwnedDiamonds+=1),e.achievements[92]>.5&&(e.thirdOwnedDiamonds+=1),e.achievements[99]>.5&&(e.fourthOwnedDiamonds+=1),e.achievements[106]>.5&&(e.fifthOwnedDiamonds+=1),e.achievements[4]>.5&&(e.upgrades[81]=1),e.achievements[11]>.5&&(e.upgrades[82]=1),e.achievements[18]>.5&&(e.upgrades[83]=1),e.achievements[25]>.5&&(e.upgrades[84]=1),e.achievements[32]>.5&&(e.upgrades[85]=1),e.achievements[80]>.5&&(e.upgrades[87]=1),e.transcendcounter10&&e.platonicUpgrades[11]>0&&(e.prestigePoints=e.prestigePoints.add(o.reincarnationPointGain)),t==="reincarnation"||t==="reincarnationChallenge"||t==="ascension"||t==="ascensionChallenge"||t==="singularity"){e.ascensionCount>0&&e.achievements[183]<1&&As(1),e.researchPoints=Math.min(1e300,e.researchPoints+Math.floor(o.obtainiumGain));let s=o.obtainiumGain/(1+e.reincarnationcounter);if(s>e.obtainiumpersecond&&(e.obtainiumpersecond=s),e.currentChallenge.transcension=0,Tl(3),e.coinsThisReincarnation=new f("100"),e.firstOwnedMythos=0,e.firstCostMythos=new f("1"),e.secondOwnedMythos=0,e.secondCostMythos=new f("1e2"),e.thirdOwnedMythos=0,e.thirdCostMythos=new f("1e4"),e.fourthOwnedMythos=0,e.fourthCostMythos=new f("1e8"),e.fifthOwnedMythos=0,e.fifthCostMythos=new f("1e16"),e.firstGeneratedParticles=new f("0"),e.secondGeneratedParticles=new f("0"),e.thirdGeneratedParticles=new f("0"),e.fourthGeneratedParticles=new f("0"),e.fifthGeneratedParticles=new f("0"),e.reincarnationCount+=1,e.transcendPoints=new f("0"),e.reincarnationPoints=e.reincarnationPoints.add(o.reincarnationPointGain),e.reincarnationShards=new f("0"),e.challengecompletions[1]=0,e.challengecompletions[2]=0,e.challengecompletions[3]=0,e.challengecompletions[4]=0,e.challengecompletions[5]=0,o.reincarnationPointGain=new f("0"),e.shopUpgrades.instantChallenge>0&&e.currentChallenge.reincarnation===0&&(e.challengecompletions[1]=e.highestchallengecompletions[1],e.challengecompletions[2]=e.highestchallengecompletions[2],e.challengecompletions[3]=e.highestchallengecompletions[3],e.challengecompletions[4]=e.highestchallengecompletions[4],e.challengecompletions[5]=e.highestchallengecompletions[5]),e.reincarnatenocoinupgrades=!0,e.reincarnatenocoinorprestigeupgrades=!0,e.reincarnatenocoinprestigeortranscendupgrades=!0,e.reincarnatenocoinprestigetranscendorgeneratorupgrades=!0,e.reincarnatenoaccelerator=!0,e.reincarnatenomultiplier=!0,e.reincarnationcounter.5){let l=e.autoResearch===200?.01:0;Fr(e.autoResearch,!0,l)}He(),It()}if(t==="ascension"||t==="ascensionChallenge"||t==="singularity"){let s=Xr();e.challengecompletions[10]>0&&As(3,s[3]),e.currentChallenge.transcension=0,e.currentChallenge.reincarnation=0,t==="ascensionChallenge"&&e.currentChallenge.ascension>10&&e.highestSingularityCount>=2&&e.autoChallengeToggles[10]?e.autoChallengeIndex=10:e.autoChallengeIndex=1,fr("START"),o.autoChallengeTimerIncrement=0,Wv(),Ru(),Kv(),e.reincarnationPoints=new f("0"),e.reincarnationShards=new f("0"),e.obtainiumpersecond=0,e.maxobtainiumpersecond=0,e.offeringpersecond=0,e.antSacrificePoints=0,e.antSacrificeTimer=0,e.antSacrificeTimerReal=0,e.antUpgrades[12-1]=0;for(let c=61;c<=80;c++)e.upgrades[c]=0;for(let c=94;c<=100;c++)e.upgrades[c]=0;e.firstOwnedParticles=0,e.secondOwnedParticles=0,e.thirdOwnedParticles=0,e.fourthOwnedParticles=0,e.fifthOwnedParticles=0,e.firstCostParticles=new f("1"),e.secondCostParticles=new f("100"),e.thirdCostParticles=new f("1e4"),e.fourthCostParticles=new f("1e8"),e.fifthCostParticles=new f("1e16"),e.runeexp=[0,0,0,0,0,e.runeexp[5],e.runeexp[6]],e.runelevels=[0,0,0,0,0,e.runelevels[5],e.runelevels[6]],e.runeshards=0,e.crystalUpgrades=[0,0,0,0,0,0,0,0],e.runelevels[0]=3*e.cubeUpgrades[26],e.runelevels[1]=3*e.cubeUpgrades[26],e.runelevels[2]=3*e.cubeUpgrades[26],e.runelevels[3]=3*e.cubeUpgrades[26],e.runelevels[4]=3*e.cubeUpgrades[26],e.cubeUpgrades[27]===1&&(e.firstOwnedParticles=1,e.secondOwnedParticles=1,e.thirdOwnedParticles=1,e.fourthOwnedParticles=1,e.fifthOwnedParticles=1),e.challengecompletions[10]>0&&e.ascensionCounter>0&&(e.ascensionCount+=Lo(),isFinite(s[4])&&isFinite(s[5])&&isFinite(s[6])&&isFinite(s[7])&&isFinite(s[8])&&(e.wowCubes.add(s[4]),e.wowTesseracts.add(s[5]),e.wowHypercubes.add(s[6]),e.wowPlatonicCubes.add(s[7]),e.wowAbyssals=Math.min(1e300,e.wowAbyssals+s[8])));for(let c=1;c<=10;c++)e.challengecompletions[c]=0,e.highestchallengecompletions[c]=0;e.challengecompletions[6]=e.highestchallengecompletions[6]=e.cubeUpgrades[49],e.challengecompletions[7]=e.highestchallengecompletions[7]=e.cubeUpgrades[49],e.challengecompletions[8]=e.highestchallengecompletions[8]=e.cubeUpgrades[49],i(`res${e.autoResearch||1}`).classList.remove("researchRoomba"),e.roombaResearchIndex=0,e.autoResearch=1;for(let c=1;c<=200;c++){let p=`res${c}`;e.researches[c]>.5&&e.researches[c].5&&e.researches[c]>=o.researchMaxLevels[c]?Lt(p,["researchMaxed"],["researchAvailable","researchPurchased","researchPurchasedAvailable","researchUnpurchased"]):Lt(p,["researchUnpurchased"],["researchAvailable","researchPurchased","researchPurchasedAvailable","researchMaxed"])}It(),He(),ea(),Iu(),Or(),As(1),e.ascensionCounter=0,e.ascensionCounterReal=0,e.ascensionCounterRealReal=0,Zt(),dt(0),dt(1),dt(2),dt(3),dt(4),dt(5),dt(6),Qt(),la(),ia(),e.cubeUpgrades[4]===1&&(e.upgrades[94]=1,e.upgrades[95]=1,e.upgrades[96]=1,e.upgrades[97]=1,e.upgrades[98]=1),e.cubeUpgrades[5]===1&&(e.upgrades[99]=1),e.cubeUpgrades[6]===1&&(e.upgrades[100]=1);for(let c=61;c<=80;c++)i(`upg${c}`).style.backgroundColor="";for(let c=94;c<=100;c++)e.upgrades[c]===0&&(i(`upg${c}`).style.backgroundColor="");let l=Qa();if(e.usedCorruptions=e.prototypeCorruptions.map((c,p)=>p>=2&&p<=9?Math.min(l*(e.challengecompletions[Ll(p)]>0||e.singularityUpgrades.platonicTau.getEffect().bonus?1:0),c):c),e.usedCorruptions[1]=0,e.prototypeCorruptions[1]=0,e.currentChallenge.ascension===15&&(t==="ascension"||t==="ascensionChallenge")){e.usedCorruptions[0]=0,e.prototypeCorruptions[0]=0;for(let c=2;c<=9;c++)e.usedCorruptions[c]=11}Va(),Tf(!1)}if(t==="ascension"||t==="ascensionChallenge"){let s=_g(),l=s.length+(e.overfluxOrbsAutoBuy?1:0);if(e.highestSingularityCount>=1&&l>0){let c=Math.floor(e.wowAbyssals/l*(e.hepteractAutoCraftPercentage/100));for(let p of s)p.autoCraft(c);if(e.overfluxOrbsAutoBuy){let p=Math.floor(c/25e4);e.wowAbyssals-25e4*p>=0&&(e.overfluxOrbs+=p,e.overfluxPowder+=e.shopUpgrades.powderAuto*Ar().mult*p/100,e.wowAbyssals-=25e4*p),e.wowAbyssals<0&&(e.wowAbyssals=0)}}if(e.researches[190]>0&&e.tesseractAutoBuyerToggle===1&&e.resettoggle4===2){let c=[null,null,null,null,null];for(let h=1;h<=5;h++)e.autoTesseracts[h]&&(c[h-1]=e[`ascendBuilding${h}`].owned);let p=100-Math.min(100,e.tesseractAutoBuyerAmount),g=Number(e.wowTesseracts)*p/100,m=kl(c,g);for(let h=5;h>=1;h--){let b=c[h-1],C=m[h-1];b!==null&&C!==null&&C!==b&&ja(h,C-b)}}Wg(),Ug(),e.highestSingularityCount>=35&&(e.autoOpenCubes&&e.openCubes!==0&&e.cubeUpgrades[51]>0&&e.wowCubes.open(Math.floor(Number(e.wowCubes)*e.openCubes/100),!1),e.autoOpenTesseracts&&e.openTesseracts!==0&&e.challengecompletions[11]>0&&(e.tesseractAutoBuyerToggle!==1||e.resettoggle4===2)&&e.wowTesseracts.open(Math.floor(Number(e.wowTesseracts)*e.openTesseracts/100),!1),e.autoOpenHypercubes&&e.openHypercubes!==0&&e.challengecompletions[13]>0&&e.wowHypercubes.open(Math.floor(Number(e.wowHypercubes)*e.openHypercubes/100),!1),e.autoOpenPlatonicsCubes&&e.openPlatonicsCubes!==0&&e.challengecompletions[14]>0&&e.wowPlatonicCubes.open(Math.floor(Number(e.wowPlatonicCubes)*e.openPlatonicsCubes/100),!1))}if(e.unlocks.prestige=!0,(t==="transcension"||t==="transcensionChallenge")&&(e.unlocks.transcend=!0),(t==="reincarnation"||t==="reincarnationChallenge")&&(e.unlocks.reincarnate=!0),t==="singularity"){e.unlocks.coinone=!1,e.unlocks.cointwo=!1,e.unlocks.cointhree=!1,e.unlocks.coinfour=!1,e.unlocks.generation=!1,e.unlocks.prestige=!1,e.unlocks.transcend=!1,e.unlocks.reincarnate=!1,e.unlocks.rrow1=!1,e.unlocks.rrow2=!1,e.unlocks.rrow3=!1,e.unlocks.rrow4=!1,e.ascendBuilding1.owned=0,e.ascendBuilding1.generated=new f("0"),e.ascendBuilding2.owned=0,e.ascendBuilding2.generated=new f("0"),e.ascendBuilding3.owned=0,e.ascendBuilding3.generated=new f("0"),e.ascendBuilding4.owned=0,e.ascendBuilding4.generated=new f("0"),e.ascendBuilding5.owned=0,e.ascendBuilding5.generated=new f("0"),e.constantUpgrades=[null,0,0,0,0,0,0,0,0,0,0],e.wowCubes=new nr(0),e.wowTesseracts=new nr(0),e.wowHypercubes=new nr(0),e.wowTesseracts=new nr(0),e.wowAbyssals=0;for(let s=1;s<=50;s++)e.cubeUpgrades[s]=0}r||Oe(),(t==="transcensionChallenge"||t==="reincarnationChallenge"||t==="ascensionChallenge")&&Lr(),Io()},Mf=()=>{e.highestSingularityCount>=1&&R(274),e.highestSingularityCount>=2&&R(275),e.highestSingularityCount>=3&&R(276),e.highestSingularityCount>=4&&R(277),e.highestSingularityCount>=5&&R(278),e.highestSingularityCount>=7&&R(279),e.highestSingularityCount>=10&&R(280)},Tf=(t=!0)=>{if(e.achievements[275]>0){t&&(e.prestigeCount=1,e.transcendCount=1),e.transcendPoints=new f("1001"),e.unlocks.coinone=!0,e.unlocks.cointwo=!0,e.unlocks.cointhree=!0,e.unlocks.coinfour=!0,e.unlocks.prestige=!0,e.unlocks.generation=!0,e.unlocks.transcend=!0;for(let s=0;s<5;s++)R(4+7*s);R(36),R(43)}if(e.achievements[276]>0){e.currentChallenge.ascension!==12&&(t&&(e.reincarnationCount=1),e.reincarnationPoints=new f("10")),e.unlocks.reincarnate=!0,e.unlocks.rrow1=!0,e.researches[47]=1;for(let s=0;s<2;s++)for(let l=0;l<5;l++)R(78+s+7*l);for(let s=0;s<7;s++)R(57+s),R(64+s),R(71+s);R(37),R(38),R(44),R(50),R(80),R(87)}e.achievements[277]>0&&(e.currentChallenge.ascension!==14&&(e.researchPoints=Math.floor(500*Le("Offering")*Le("Researches"))),e.currentChallenge.ascension!==12&&(e.reincarnationPoints=new f("1e16")),e.challengecompletions[6]=1,e.highestchallengecompletions[6]=1,R(113));let r=["offeringAuto","offeringEX","obtainiumAuto","obtainiumEX","antSpeed","cashGrab"];if(e.achievements[278]>0&&t){for(let s of r)e.shopUpgrades[s]=10;e.cubeUpgrades[7]=1}if(e.achievements[279]>0&&(e.challengecompletions[7]=1,e.highestchallengecompletions[7]=1,R(120),e.currentChallenge.ascension!==12&&(e.reincarnationPoints=new f("1e100"))),e.achievements[280]>0){R(124),R(127),e.challengecompletions[8]=1,e.highestchallengecompletions[8]=1,e.cubeUpgrades[8]=1,e.cubeUpgrades[4]=1,e.cubeUpgrades[5]=1,e.cubeUpgrades[6]=1,e.firstOwnedAnts=1;for(let s=0;s<7;s++)R(176+s)}if(e.highestSingularityCount>10&&(e.cubeUpgrades[9]=1),e.highestSingularityCount>=15&&(e.challengecompletions[8]=5,e.highestchallengecompletions[8]=5,e.currentChallenge.ascension!==12&&(e.reincarnationPoints=new f("2.22e2222")),e.fifthOwnedAnts=1,e.cubeUpgrades[20]=1),e.highestSingularityCount>=20){let s=["offeringAuto","offeringEX","obtainiumAuto","obtainiumEX","antSpeed","cashGrab"];e.challengecompletions[9]=1,e.highestchallengecompletions[9]=1,R(134),e.antPoints=new f("1e100"),e.antUpgrades[11]=1;for(let l of s)e.shopUpgrades[l]=pe[l].maxLevel}if(e.highestSingularityCount>=25&&(e.eighthOwnedAnts=1),e.highestSingularityCount>=30&&(e.researches[130]=1,e.researches[135]=1,e.researches[145]=1),e.highestSingularityCount>=100&&t&&(e.cubeUpgrades[51]=1,Zc()),e.highestSingularityCount>=244&&(e.cubeUpgrades[71]=1,e.cubeUpgrades[72]=1),e.singularityUpgrades.platonicAlpha.getEffect().bonus&&e.platonicUpgrades[5]===0&&(e.platonicUpgrades[5]=1,io(5)),t)for(let s=1;s<=15;s++)yr(s);if(Tl(3),t)for(let s=1;s0&&cs(s);Bu(),Oe()},Bu=()=>{let t=e.achievements[278]>0,r=["offeringAuto","offeringEX","obtainiumAuto","obtainiumEX","antSpeed","cashGrab"];for(let c of r)pe[c].refundMinimumLevel=t?10:c.endsWith("Auto")?1:0;let n=e.highestSingularityCount>=20,a=["offeringAuto","offeringEX","obtainiumAuto","obtainiumEX","antSpeed","cashGrab"];for(let c of a)pe[c].refundable=!n;let s=e.highestSingularityCount>=51,l=["seasonPass","seasonPass2","seasonPass3","seasonPassY","chronometer","chronometer2"];for(let c of l)pe[c].refundable=!s},Cs=async(t=-1)=>{var h,b,C,v,x,B,U,k,L;if(e.runelevels[6]===0&&t===-1)return P("You nearly triggered a double singularity bug! Oh no! Luckily, our staff prevented this from happening.");if(t===-1){let E=Object.values(e.cubeBlessings),T=Object.values(e.tesseractBlessings),S=Object.values(e.hypercubeBlessings),I=Object.values(e.platonicBlessings),N={seconds:e.singularityCounter,date:Date.now(),singularityCount:e.singularityCount,quarks:e.quarksThisSingularity,c15Score:e.challenge15Exponent,goldenQuarks:Xt(),wowTribs:ae(E),tessTribs:ae(T),hyperTribs:ae(S),platTribs:ae(I),octeracts:e.totalWowOcteracts,quarkHept:e.hepteractCrafts.quark.BAL,kind:"singularity"};Ct.emit("historyAdd","singularity",N)}if(e.runelevels[6]=0,e.goldenQuarks+=Xt(),t===-1){let E=1+fa();e.singularityCount+=E,e.singularityCount>=e.highestSingularityCount&&(e.highestSingularityCount=e.singularityCount,e.highestSingularityCount===5&&(e.singularityUpgrades.goldenQuarks3.freeLevels+=1),e.highestSingularityCount===10&&(e.singularityUpgrades.goldenQuarks3.freeLevels+=2))}else e.singularityCount=t;e.totalQuarksEver+=e.quarksThisSingularity,await Wi(!0);let{data:r,success:n}=ws.safeParse(M);Hn(n),bn(0),Ce(0,{page:0}),Ce(3,{page:0}),Ce(4,{page:0}),Ce(7,{page:0}),Ce(8,{page:0}),Ce(9,{page:0}),Ce(10,{page:0}),r.history.singularity=e.history.singularity,r.totalQuarksEver=e.totalQuarksEver,r.singularityCount=e.singularityCount,r.highestSingularityCount=e.highestSingularityCount,r.goldenQuarks=e.goldenQuarks,r.shopUpgrades=e.shopUpgrades,e.singularityChallenges.limitedTime.rewards.preserveQuarks?r.worlds=Number(e.worlds):(e.worlds.reset(),r.worlds=Number(r.worlds)),r.singularityUpgrades=Object.fromEntries(Object.entries(e.singularityUpgrades).map(([E,T])=>[E,{level:T.level,goldenQuarksInvested:T.goldenQuarksInvested,toggleBuy:T.toggleBuy,freeLevels:T.freeLevels}])),r.octeractUpgrades=Object.fromEntries(Object.entries(e.octeractUpgrades).map(([E,T])=>[E,{level:T.level,octeractsInvested:T.octeractsInvested,toggleBuy:T.toggleBuy,freeLevels:T.freeLevels}])),r.blueberryUpgrades=Object.fromEntries(Object.entries(e.blueberryUpgrades).map(([E,T])=>[E,{level:T.level,ambrosiaInvested:T.ambrosiaInvested,blueberriesInvested:T.blueberriesInvested,toggleBuy:T.toggleBuy,freeLevels:T.freeLevels}])),r.spentBlueberries=e.spentBlueberries,r.autoChallengeToggles=e.autoChallengeToggles,r.autoChallengeTimer=e.autoChallengeTimer,r.saveString=e.saveString,r.corruptionLoadouts=e.corruptionLoadouts,r.corruptionLoadoutNames=e.corruptionLoadoutNames,r.corruptionShowStats=e.corruptionShowStats,r.toggles=e.toggles,r.retrychallenges=e.retrychallenges,r.resettoggle1=e.resettoggle1,r.resettoggle2=e.resettoggle2,r.resettoggle3=e.resettoggle3,r.resettoggle4=e.resettoggle4,r.coinbuyamount=e.coinbuyamount,r.crystalbuyamount=e.crystalbuyamount,r.mythosbuyamount=e.mythosbuyamount,r.particlebuyamount=e.particlebuyamount,r.offeringbuyamount=e.offeringbuyamount,r.tesseractbuyamount=e.tesseractbuyamount,r.shoptoggles=e.shoptoggles,r.autoSacrificeToggle=e.autoSacrificeToggle,r.autoBuyFragment=e.autoBuyFragment,r.autoFortifyToggle=e.autoFortifyToggle,r.autoEnhanceToggle=e.autoEnhanceToggle,r.autoResearchToggle=e.autoResearchToggle,r.autoResearchMode=e.autoResearchMode,r.dailyCodeUsed=e.dailyCodeUsed,r.runeBlessingBuyAmount=e.runeBlessingBuyAmount,r.runeSpiritBuyAmount=e.runeSpiritBuyAmount,r.prestigeamount=e.prestigeamount,r.transcendamount=e.transcendamount,r.reincarnationamount=e.reincarnationamount,r.talismanOne=e.talismanOne,r.talismanTwo=e.talismanTwo,r.talismanThree=e.talismanThree,r.talismanFour=e.talismanFour,r.talismanFive=e.talismanFive,r.talismanSix=e.talismanSix,r.talismanSeven=e.talismanSeven,r.buyTalismanShardPercent=e.buyTalismanShardPercent,r.antMax=e.antMax,r.autoAntSacrifice=e.autoAntSacrifice,r.autoAntSacrificeMode=e.autoAntSacrificeMode,r.autoAntSacTimer=e.autoAntSacTimer,r.autoAscend=e.autoAscend,r.autoAscendMode=e.autoAscendMode,r.autoAscendThreshold=e.autoAscendThreshold,r.autoResearch=0,r.autoTesseracts=e.autoTesseracts,r.tesseractAutoBuyerToggle=e.tesseractAutoBuyerToggle,r.tesseractAutoBuyerAmount=e.tesseractAutoBuyerAmount,r.autoOpenCubes=e.autoOpenCubes,r.openCubes=e.openCubes,r.autoOpenTesseracts=e.autoOpenTesseracts,r.openTesseracts=e.openTesseracts,r.autoOpenHypercubes=e.autoOpenHypercubes,r.openHypercubes=e.openHypercubes,r.autoOpenPlatonicsCubes=e.autoOpenPlatonicsCubes,r.openPlatonicsCubes=e.openPlatonicsCubes,r.historyShowPerSecond=e.historyShowPerSecond,r.exporttest=typeof e.exporttest=="boolean"?e.exporttest:e.exporttest==="YES!",r.dayTimer=e.dayTimer,r.dayCheck=(b=(h=e.dayCheck)==null?void 0:h.toISOString())!=null?b:null,r.ascStatToggles=e.ascStatToggles,r.hepteractAutoCraftPercentage=e.hepteractAutoCraftPercentage,r.autoWarpCheck=e.autoWarpCheck,r.shopBuyMaxToggle=e.shopBuyMaxToggle,r.shopHideToggle=e.shopHideToggle,r.shopConfirmationToggle=e.shopConfirmationToggle,r.researchBuyMaxToggle=e.researchBuyMaxToggle,r.cubeUpgradesBuyMaxToggle=e.cubeUpgradesBuyMaxToggle,r.wowOcteracts=e.wowOcteracts,r.totalWowOcteracts=e.totalWowOcteracts,r.overfluxOrbsAutoBuy=e.overfluxOrbsAutoBuy,r.hotkeys=e.hotkeys,r.theme=e.theme,r.notation=e.notation,r.firstPlayed=e.firstPlayed,r.autoCubeUpgradesToggle=e.autoCubeUpgradesToggle,r.autoPlatonicUpgradesToggle=e.autoPlatonicUpgradesToggle,r.insideSingularityChallenge=e.insideSingularityChallenge,r.ultimatePixels=e.ultimatePixels,r.ultimateProgress=e.ultimateProgress,r.cubeUpgradeRedBarFilled=e.cubeUpgradeRedBarFilled,r.singularityChallenges=Object.fromEntries(Object.entries(e.singularityChallenges).map(([E,T])=>[E,{completions:T.completions,highestSingularityCompleted:T.highestSingularityCompleted,enabled:T.enabled}])),r.iconSet=e.iconSet,r.hepteractCrafts.quark=e.hepteractCrafts.quark;for(let E of Object.keys(e.hepteractCrafts))if(E!=="quark"){let T=E;r.hepteractCrafts[T].AUTO=e.hepteractCrafts[T].AUTO}r.ambrosia=e.ambrosia,r.lifetimeAmbrosia=e.lifetimeAmbrosia,r.visitedAmbrosiaSubtab=e.visitedAmbrosiaSubtab,r.blueberryTime=e.blueberryTime,r.blueberryLoadouts=e.blueberryLoadouts,r.blueberryLoadoutMode=e.blueberryLoadoutMode,r.wowCubes=Number(e.wowCubes),r.wowTesseracts=Number(e.wowTesseracts),r.wowHypercubes=Number(e.wowHypercubes),r.wowPlatonicCubes=Number(e.wowPlatonicCubes);let a=(C=e.codes.get(42))!=null?C:!1,s=(v=e.codes.get(43))!=null?v:!1,l=(x=e.codes.get(44))!=null?x:!1,c=(B=e.codes.get(45))!=null?B:!1,p=(U=e.codes.get(46))!=null?U:!1,g=(k=e.codes.get(47))!=null?k:!1,m=(L=e.codes.get(48))!=null?L:!1;Ga(btoa(JSON.stringify(r)),!0),e.codes.set(39,!0),e.codes.set(40,!0),e.codes.set(41,!0),e.codes.set(42,a),e.codes.set(43,s),e.codes.set(44,l),e.codes.set(45,c),e.codes.set(46,p),e.codes.set(47,g),e.codes.set(48,m),Tf(),e.rngCode=Date.now(),e.promoCodeTiming.time=Date.now(),vr()},Tl=t=>{if(t>2.5){for(let r=41;r<61;r++)r!==46&&(e.upgrades[r]=0);e.researches[41]===0&&(e.upgrades[46]=0),e.researches[41]<.5&&(e.upgrades[88]=0),e.achievements[50]===0&&(e.upgrades[89]=0),e.researches[42]<.5&&(e.upgrades[90]=0),e.researches[43]<.5&&(e.upgrades[91]=0),e.researches[44]<.5&&(e.upgrades[92]=0),e.researches[45]<.5&&(e.upgrades[93]=0),e.upgrades[116]=0,e.upgrades[117]=0,e.upgrades[118]=0,e.upgrades[119]=0,e.upgrades[120]=0}for(let r=1;r<=20;r++)e.upgrades[r]=0;for(let r=121,n=106;r<=125;r++,n++)e.upgrades[r]=0,e.upgrades[n]=0;if(t>1.5&&(e.achievements[4]<.5&&(e.upgrades[81]=0),e.achievements[11]<.5&&(e.upgrades[82]=0),e.achievements[18]<.5&&(e.upgrades[83]=0),e.achievements[25]<.5&&(e.upgrades[84]=0),e.achievements[32]<.5&&(e.upgrades[85]=0),e.achievements[87]<.5&&(e.upgrades[86]=0),e.achievements[80]<.5&&(e.upgrades[87]=0),e.upgrades[101]=0,e.upgrades[102]=0,e.upgrades[103]=0,e.upgrades[104]=0,e.upgrades[105]=0),t>1.5){for(let r=21;r<41;r++)e.upgrades[r]=0;e.upgrades[111]=0,e.upgrades[112]=0,e.upgrades[113]=0,e.upgrades[114]=0,e.upgrades[115]=0}if(t>1.5){e.crystalUpgrades=[0,0,0,0,0,0,0,0],e.crystalUpgradesCost=[7,15,20,40,100,200,500,1e3],Nu();let r=0;r+=Math.floor(o.rune3level*o.effectiveLevelMult/16)*100/100,e.upgrades[73]>.5&&e.currentChallenge.reincarnation!==0&&(r+=10),e.crystalUpgrades=[r,r,r,r,r,r,r,r]}e.achievements[87]>.5&&(e.upgrades[86]=1);for(let r=1;r<=125;r++)jt(r,!0)},Ru=()=>{e.firstOwnedAnts=0,e.secondOwnedAnts=0,e.thirdOwnedAnts=0,e.fourthOwnedAnts=0,e.fifthOwnedAnts=0,e.sixthOwnedAnts=0,e.seventhOwnedAnts=0,e.eighthOwnedAnts=0,e.firstGeneratedAnts=new f("0"),e.secondGeneratedAnts=new f("0"),e.thirdGeneratedAnts=new f("0"),e.fourthGeneratedAnts=new f("0"),e.fifthGeneratedAnts=new f("0"),e.sixthGeneratedAnts=new f("0"),e.seventhGeneratedAnts=new f("0"),e.eighthGeneratedAnts=new f("0"),e.firstCostAnts=new f("1e700"),e.secondCostAnts=new f("3"),e.thirdCostAnts=new f("100"),e.fourthCostAnts=new f("1e4"),e.fifthCostAnts=new f("1e12"),e.sixthCostAnts=new f("1e36"),e.seventhCostAnts=new f("1e100"),e.eighthCostAnts=new f("1e300"),e.cubeUpgrades[48]>0&&(e.firstOwnedAnts=1,e.firstCostAnts=new f("1e741"));let t=e.antUpgrades[12-1];e.antUpgrades=[0,0,0,0,0,0,0,0,0,0,0,t],e.antPoints=new f("1"),e.currentChallenge.ascension===12&&(e.antPoints=new f("7")),It(),He()},Wv=()=>{e.researchPoints=0;let t=[6,7,8,9,10,11,12,13,14,15,16,17,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,51,52,53,54,55,56,57,58,59,60,62,63,64,65,66,67,68,69,70,76,81,85,86,87,88,89,90,91,92,93,94,96,97,98,101,102,103,104,106,107,108,109,110,116,117,118,121,122,123,126,127,128,129,131,132,133,134,136,137,139,141,142,143,144,146,147,148,149,151,152,154,156,157,158,159,161,162,163,164,166,167,169,171,172,173,174,176,177,178,179,181,182,184,186,187,188,189,191,192,193,194,196,197,199];e.highestSingularityCount<25&&t.push(138,153,168,183,198);for(let r of t)e.researches[r]=0},Kv=()=>{e.talismanLevels=[0,0,0,0,0,0,0],e.talismanRarity=[1,1,1,1,1,1,1],e.talismanShards=0,e.commonFragments=0,e.uncommonFragments=0,e.rareFragments=0,e.epicFragments=0,e.legendaryFragments=0,e.mythicalFragments=0};var Pl=()=>{let t=1;return t+=Math.min(1e15,o.rune4level*o.effectiveLevelMult/160),t+=(e.researches[56]+e.researches[57]+e.researches[58]+e.researches[59]+e.researches[60])/200,t+=_("transcend",e.challengecompletions[4])/200,t+=Math.min(99999.9,3*(e.antUpgrades[7-1]+o.bonusant7)/100),t},yn=t=>{--t;let r=500,n=new f(r);if(n=n.times(f.pow(4/o.costDivisor,t)),t>125+5*_("transcend",e.challengecompletions[4])){let s=t-125-5*_("transcend",e.challengecompletions[4]),l=new f(s).factorial(),c=f.pow(4,s);n=n.times(c.times(l))}if(t>2e3+5*_("transcend",e.challengecompletions[4])){let s=t-2e3-5*_("transcend",e.challengecompletions[4]),l=s*(s+1)/2;n=n.times(f.pow(2,l))}if(e.currentChallenge.transcension===4){let s=t*(t+1)/2;n=n.times(f.pow(10,s))}if(e.currentChallenge.reincarnation===8){let s=t*(t+1)/2;n=n.times(f.pow(1e50,s))}let a=Math.pow(10,15);if(t>a){let c=yn(a).pow(Math.pow(t/a,1/.125)),p=c.exponent-Math.floor(c.exponent);return c.exponent=Math.floor(c.exponent),c.mantissa*=Math.pow(10,p),c.normalize(),f.max(n,c)}return n},Es=t=>{let r=e.acceleratorBought,n=Math.pow(10,15);if(r>=n){let h=f.log10(e.coins),b=f.log10(yn(n)),C=Math.floor(n*Math.max(1,Math.pow(h/b,.125))),v=n;for(;C-v>.5;){let U=Math.floor(v+(C-v)/2);if(U===v||U===C)break;e.coins.gte(yn(U))?v=U:C=U}let x=v,B=yn(x);e.acceleratorBought=x,e.acceleratorCost=B;return}let a=r+we(r),s=a,l=yn(s);for(;e.coins.gte(l);)s=s*4,l=yn(s);let c=Math.floor(s/8);for(;c>=we(s);)yn(s-c).lte(e.coins)?c=Math.floor(c/2):s=s-Math.max(we(s),c);!t&&e.coinbuyamount!=="max"&&e.acceleratorBought+e.coinbuyamount=n&&(p=n),e.coins=e.coins.sub(g),e.acceleratorBought=p,p=p+we(p),g=yn(p),e.acceleratorCost=g,p>=n)return;e.prestigenoaccelerator=!1,e.transcendnoaccelerator=!1,e.reincarnatenoaccelerator=!1,Du(),e.acceleratorBought>=5&&e.achievements[148]===0&&R(148),e.acceleratorBought>=25&&e.achievements[149]===0&&R(149),e.acceleratorBought>=100&&e.achievements[150]===0&&R(150),e.acceleratorBought>=666&&e.achievements[151]===0&&R(151),e.acceleratorBought>=2e3&&e.achievements[152]===0&&R(152),e.acceleratorBought>=12500&&e.achievements[153]===0&&R(153),e.acceleratorBought>=1e5&&e.achievements[154]===0&&R(154)},vn=t=>{--t;let r=1e4,n=new f(r);if(n=n.times(f.pow(10,t/o.costDivisor)),t>75+2*_("transcend",e.challengecompletions[4])){let s=t-75-2*_("transcend",e.challengecompletions[4]),l=new f(s).factorial(),c=f.pow(10,s);n=n.times(l.times(c))}if(t>2e3+2*_("transcend",e.challengecompletions[4])){let s=t-2e3-2*_("transcend",e.challengecompletions[4]),l=s*(s+1)/2;n=n.times(f.pow(2,l))}if(e.currentChallenge.transcension===4){let s=t*(t+1)/2;n=n.times(f.pow(10,s))}if(e.currentChallenge.reincarnation===8){let s=t*(t+1)/2;n=n.times(f.pow(1e50,s))}let a=Math.pow(10,15);if(t>a){let c=vn(a).pow(Math.pow(t/a,1/.125)),p=c.exponent-Math.floor(c.exponent);return c.exponent=Math.floor(c.exponent),c.mantissa*=Math.pow(10,p),c.normalize(),f.max(n,c)}return n},Os=t=>{let r=e.multiplierBought,n=Math.pow(10,15);if(r>=n){let h=f.log10(e.coins),b=f.log10(vn(n)),C=Math.floor(n*Math.max(1,Math.pow(h/b,.125))),v=n;for(;C-v>.5;){let U=Math.floor(v+(C-v)/2);if(U===v||U===C)break;e.coins.gte(vn(U))?v=U:C=U}let x=v,B=vn(x);e.multiplierBought=x,e.multiplierCost=B;return}let a=r+we(r),s=a,l=vn(s);for(;e.coins.gte(l);)s=s*4,l=vn(s);let c=Math.floor(s/8);for(;c>=we(s);)vn(s-c).lte(e.coins)?c=Math.floor(c/2):s=s-Math.max(we(s),c);!t&&e.coinbuyamount!=="max"&&e.multiplierBought+e.coinbuyamount=n&&(p=n),e.coins=e.coins.sub(g),e.multiplierBought=p,p=p+we(p),g=vn(p),e.multiplierCost=g,p>=n)return;e.prestigenomultiplier=!1,e.transcendnomultiplier=!1,e.reincarnatenomultiplier=!1,Gu(),e.multiplierBought>=2&&e.achievements[155]===0&&R(155),e.multiplierBought>=20&&e.achievements[156]===0&&R(156),e.multiplierBought>=100&&e.achievements[157]===0&&R(157),e.multiplierBought>=500&&e.achievements[158]===0&&R(158),e.multiplierBought>=2e3&&e.achievements[159]===0&&R(159),e.multiplierBought>=12500&&e.achievements[160]===0&&R(160),e.multiplierBought>=1e5&&e.achievements[161]===0&&R(161)},zv=Math.log10(2*Math.PI),Xv=Math.log10(Math.E),No=t=>++t===0?0:(Math.log10(t*Math.sqrt(t*Math.sinh(1/t)+1/(810*Math.pow(t,6))))-Xv)*t+(zv-Math.log10(t))/2,Zv=Math.log10(9332621544394e145),Yv=188.582,$o=(()=>{let t=[1.03,1.25],r=[1,2,3,4,5,6,10,15];for(let s of r)t.push(100+100*s),t.push(10+10*s);let n=1e3;for(let s=0;s"u"&&(a[s]=Math.log10(s));return a})(),Jv=[100,1e3,2e4,4e5,8e6],eC=[100,1e5,1e15,1e40,1e100],Sf=[1,100,1e4,1e8,1e16],Ur=(t,r,n,a,s)=>{--r;let l=Math.pow(10,15),c=new f(t),p=a*r;r=s*1e3&&(++g,c.exponent-=No(m),c.exponent+=(-3+Math.log10(1+a/2))*(r-m)),m=Math.floor(s*5e3),r>=s*5e3&&(++g,c.exponent-=No(m),c.exponent+=($o[10+a*10]+1)*(r-m-1)+1),m=Math.floor(s*2e4),r>=s*2e4&&(g+=3,c.exponent-=No(m)*3,c.exponent+=($o[100+100*a]+5)*(r-m)),m=Math.floor(s*25e4),r>=s*25e4&&(c.exponent+=Math.log10(1.03)*(r-m)*((r-m+1)/2)),c.exponent+=No(r)*g;let h=0;e.currentChallenge.transcension===4&&(n==="Coin"||n==="Diamonds")&&(++h,r>=1e3-10*e.challengecompletions[4]&&(p+=r*(r+1)/2)),e.currentChallenge.reincarnation===10&&(n==="Coin"||n==="Diamonds")&&(++h,r>=s*25e3&&(p+=r*(r+1)/2)),c.exponent+=h*((No(r+100)-Zv+2*r)*(1.25+e.challengecompletions[4]/4)),c.exponent+=$o[1.25]*p,m=Math.floor(s*1e3*e.challengecompletions[8]),e.currentChallenge.reincarnation===8&&(n==="Coin"||n==="Diamonds"||n==="Mythos")&&r>=1e3*e.challengecompletions[8]*s&&(c.exponent+=($o[2]*((r-m+1)/2)-$o[1+e.challengecompletions[8]/2])*(r-m));let b=c.exponent-Math.floor(c.exponent);if(c.exponent=Math.floor(c.exponent),c.mantissa*=Math.pow(10,b),c.normalize(),r>l){let x=Ur(t,l,n,a,s).pow(Math.pow(r/l,1/.125)),B=x.exponent-Math.floor(x.exponent);return x.exponent=Math.floor(x.exponent),x.mantissa*=Math.pow(10,B),x.normalize(),f.max(c,x)}return c},kf=(t,r)=>{let n=r==="Coin"?Jv:r==="Diamonds"?eC:Sf,a=r==="Coin"?t:t*(t+1)/2;return[n[t-1],a]},Lf=(t,r,n,a)=>{let[s,l]=kf(t,r);return Ur(s,n,r,l,a!=null?a:Pl())},gt=(t,r)=>{let n=t-1,a=o.ordinals[n],[s,l]=kf(t,r),c=Math.pow(10,15),p=1e99,g=Pl(),m=Pf[r][0],h=`${a}Owned${r}`,b=e[h];if(b>=c){let E=f.log10(e[m]),T=f.log10(Ur(s,c,r,l,g)),S=Math.floor(c*Math.max(1,Math.pow(E/T,.125))),I=c;for(;S-I>.5;){let re=Math.floor(I+(S-I)/2);if(re===I||re===S)break;e[m].gte(Ur(s,re,r,l,g))?I=re:S=re}let N=I,X=Ur(s,N,r,l,g);e[h]=N,e[`${a}Cost${r}`]=X;return}let C=b+we(b),v=1,x=Ur(s,b+v,r,l,g);if(x.exponent>=p||!e[m].gte(x))return;for(;x.exponent=we(v);)Ur(s,b+v-B,r,l,g).lte(e[m])?B=Math.floor(B/2):v=v-Math.max(we(v),B);if(b+v>=c){e[h]=c,e[`${a}Cost${r}`]=Ur(s,c,r,l,g);return}let U=Math.max(b+v-6-we(v),C),k=Ur(s,U,r,l,g);for(;U<=b+v&&e[m].gte(k);)e[m]=e[m].sub(k),e[h]=U,U=U+we(U),k=Ur(s,U,r,l,g),e[`${a}Cost${r}`]=k},Pf={Diamonds:["prestigePoints","crystal"],Mythos:["transcendPoints","mythos"],Particles:["reincarnationPoints","particle"],Coin:["coins","coin"]},Af=(t,r,n,a)=>{let[s,l]=Pf[r],c=a?500:e[`${l}buyamount`],p=1;p+=o.rune4level*o.effectiveLevelMult/160,p+=(e.researches[56]+e.researches[57]+e.researches[58]+e.researches[59]+e.researches[60])/200,p+=_("transcend",e.challengecompletions[4])/200,p+=3*(o.bonusant7+e.antUpgrades[7-1])/100;let g=`${t}Cost${r}`,m=`${t}Owned${r}`;for(;e[s].gte(e[g])&&o.ticker=1e3*p&&(e[g]=e[g].times(e[m]).dividedBy(1e3).times(1+n/2)),e[m]>=5e3*p&&(e[g]=e[g].times(e[m]).times(10).times(10+n*10)),e[m]>=2e4*p&&(e[g]=e[g].times(f.pow(e[m],3)).times(1e5).times(100+n*100)),e[m]>=25e4*p&&(e[g]=e[g].times(f.pow(1.03,e[m]-25e4*p))),e.currentChallenge.transcension===4&&(r==="Coin"||r==="Diamonds")&&(e[g]=e[g].times(Math.pow(100*e[m]+1e4,1.25+1/4*e.challengecompletions[4])),e[m]>=1e3-10*e.challengecompletions[4]&&(e[g]=e[g].times(f.pow(1.25,e[m])))),e.currentChallenge.reincarnation===8&&(r==="Coin"||r==="Diamonds"||r==="Mythos")&&e[m]>=1e3*e.challengecompletions[8]*p&&(e[g]=e[g].times(f.pow(2,(e[m]-1e3*e.challengecompletions[8]*p)/(1+e.challengecompletions[8]/2)))),o.ticker+=1;o.ticker=0},or=(t,r,n)=>{let a=t;e[a].gte(f.pow(10,o.upgradeCosts[r]))&&e.upgrades[r]===0&&(e[a]=e[a].sub(f.pow(10,o.upgradeCosts[r])),e.upgrades[r]=1,jt(r,n)),t==="transcendPoints"&&(e.reincarnatenocoinprestigeortranscendupgrades=!1,e.reincarnatenocoinprestigetranscendorgeneratorupgrades=!1),t==="prestigePoints"&&(e.transcendnocoinorprestigeupgrades=!1,e.reincarnatenocoinorprestigeupgrades=!1,e.reincarnatenocoinprestigeortranscendupgrades=!1,e.reincarnatenocoinprestigetranscendorgeneratorupgrades=!1),t==="coins"&&(e.prestigenocoinupgrades=!1,e.transcendnocoinupgrades=!1,e.transcendnocoinorprestigeupgrades=!1,e.reincarnatenocoinupgrades=!1,e.reincarnatenocoinorprestigeupgrades=!1,e.reincarnatenocoinprestigeortranscendupgrades=!1,e.reincarnatenocoinprestigetranscendorgeneratorupgrades=!1)},tC=t=>{let r=t-1,n=f.log(e.prestigeShards.add(1),10);return Math.floor(Math.pow(Math.max(0,2*(n-o.crystalUpgradesCost[r])/o.crystalUpgradeCostIncrement[r]+1/4),1/2)+1/2)},Yt=(t,r=!1)=>{let n=t-1,a=0;a+=Math.floor(o.rune3level/16*o.effectiveLevelMult)*100/100,e.upgrades[73]>.5&&e.currentChallenge.reincarnation!==0&&(a+=10);let s=tC(t);s+a>e.crystalUpgrades[n]&&(e.crystalUpgrades[n]=100/100*(s+a),s>0&&(e.prestigeShards=e.prestigeShards.sub(f.pow(10,o.crystalUpgradesCost[n]+o.crystalUpgradeCostIncrement[n]*(1/2*Math.pow(s-1/2,2)-1/8))),r||Ni(t)))},Ka=t=>{let r=1;if(e.upgrades[46]===1&&(r=t?9999:e.coinbuyamount),e.upgrades[46]<1){for(;e.prestigePoints.gte(e.acceleratorBoostCost)&&o.ticker1e3*(1+2*o.effectiveRuneBlessingPower[4])&&(e.acceleratorBoostCost=e.acceleratorBoostCost.times(f.pow(10,Math.pow(e.acceleratorBoostBought-1e3*(1+2*o.effectiveRuneBlessingPower[4]),2)/(1+2*o.effectiveRuneBlessingPower[4])))),e.transcendnoaccelerator=!1,e.reincarnatenoaccelerator=!1,e.upgrades[46]<.5)){for(let n=21;n<41;n++)e.upgrades[n]=0;Pe("prestige"),e.prestigePoints=new f(0)}}else{let n=e.acceleratorBoostBought,a=Math.pow(10,15);if(n>=a){let b=f.log10(e.prestigePoints),C=f.log10(Jr(a)),v=Math.floor(a*Math.max(1,Math.pow(b/C,.125))),x=a;for(;v-x>.5;){let k=Math.floor(x+(v-x)/2);if(k===x||k===v)break;e.prestigePoints.gte(Jr(k))?x=k:v=k}let B=x,U=Jr(B);e.acceleratorBoostBought=B,e.acceleratorBoostCost=U;return}let s=n+we(n),l=1,c=Jr(n+l);for(;e.prestigePoints.gte(c);)l*=4,c=Jr(n+l);let p=Math.floor(l/8);for(;p>=we(l);)Jr(n+l-p).lte(e.prestigePoints)?p=Math.floor(p/2):l=l-Math.max(we(l),p);let g=Math.max(n+l-6-we(l),s),m=Jr(e.acceleratorBoostBought);for(;g<=n+l&&e.prestigePoints.gte(Jr(g));)if(e.prestigePoints=e.prestigePoints.sub(m),g>=a&&(g=a),e.acceleratorBoostBought=g,g=g+we(g),m=Jr(g),e.acceleratorBoostCost=m,e.transcendnoaccelerator=!1,e.reincarnatenoaccelerator=!1,g>=a)return}o.ticker=0,e.acceleratorBoostBought>=2&&e.achievements[162]===0&&R(162),e.acceleratorBoostBought>=10&&e.achievements[163]===0&&R(163),e.acceleratorBoostBought>=50&&e.achievements[164]===0&&R(164),e.acceleratorBoostBought>=200&&e.achievements[165]===0&&R(165),e.acceleratorBoostBought>=1e3&&e.achievements[166]===0&&R(166),e.acceleratorBoostBought>=5e3&&e.achievements[167]===0&&R(167),e.acceleratorBoostBought>=15e3&&e.achievements[168]===0&&R(168)},Jr=(t=1)=>{t--;let r=Math.pow(10,15),n=new f(1e3),a=1+2*o.effectiveRuneBlessingPower[4],s=p=>p*(p+1)/2,l=p=>p*(p+1)*(2*p+1)/6,c=n;if(t>1e3*a?c=n.times(f.pow(10,10*t+s(t)+l(t-1e3*a)/a)):c=n.times(f.pow(10,10*t+s(t))),t>r){let m=Jr(r).pow(Math.pow(t/r,1/.125)),h=m.exponent-Math.floor(m.exponent);return m.exponent=Math.floor(m.exponent),m.mantissa*=Math.pow(10,h),m.normalize(),f.max(c,m)}return c},Cn=(t,r)=>{--r,t=new f(t);let n=t.times(f.pow(2,r)),a=e.currentChallenge.ascension!==15?325e3:1e3;r>a&&(n=n.times(f.pow(1.001,(r-a)*((r-a+1)/2))));let s=Math.pow(10,15);if(r>s){let p=Cn(t,s).pow(Math.pow(r/s,1/.125)),g=p.exponent-Math.floor(p.exponent);return p.exponent=Math.floor(p.exponent),p.mantissa*=Math.pow(10,g),p.normalize(),f.max(n,p)}return n},wn=(t,r=!1)=>{let n=t-1,a=Sf[n],s=o.ordinals[n],l=`${s}OwnedParticles`,c=e[l],p=Math.pow(10,15);if(c>=p){let B=f.log10(e.reincarnationPoints),U=f.log10(Cn(a,p)),k=Math.floor(p*Math.max(1,Math.pow(B/U,.125))),L=p;for(;k-L>.5;){let S=Math.floor(L+(k-L)/2);if(S===L||S===k)break;e.reincarnationPoints.gte(Cn(a,S))?L=S:k=S}let E=L,T=Cn(a,E);e[l]=E,e[`${s}CostParticles`]=T;return}let g=c+we(c),m=g,h=Cn(a,m);for(;e.reincarnationPoints.gte(h);)m=m*4,h=Cn(a,m);let b=Math.floor(m/8);for(;b>=we(m);)Cn(a,m-b).lte(e.reincarnationPoints)?b=Math.floor(b/2):m=m-Math.max(we(m),b);r||e.particlebuyamount+c{let n=t.map((s,l)=>{if(s===null)return null;let c=Math.ceil(Math.pow(r/Wa[l],1/3)-1);return Math.max(s,c)}),a=0;for(let s=0;s{let n=null;for(let m=0;mr)return t;let a=n,s=a*2;for(;$u(t,s)[0]<=r;)a=s,s*=2;for(;s-a>.5;){let m=a+(s-a)/2;if(m===a||m===s)break;$u(t,m)[0]<=r?a=m:s=m}let[l,c]=$u(t,a),p=r-l,g=c.map((m,h)=>m===null?null:Wa[h]*Math.pow(m+1,3));for(let m=1;m<=5;m++){let h=null;for(let b=0;b{r!=null||(r=e.tesseractbuyamount),a!=null||(a=e[`ascendBuilding${t}`].owned);let s=Wa[t-1],l=s*Math.pow(a*(a+1)/2,2),c;if(n){let g=Math.floor(-.5+.5*Math.pow(1+8*Math.pow((Number(e.wowTesseracts)+l)/s,.5),.5));c=Math.min(g,a+r)}else c=a+r;let p=s*Math.pow(c*(c+1)/2,2)-l;return[c,p]},ja=(t,r=e.tesseractbuyamount)=>{let n=Wa[t-1],a=`ascendBuilding${t}`,[s,l]=rC(t,r);e[a].owned=s,e.wowTesseracts.sub(l),e[a].cost=n*Math.pow(1+s,3)},Us=(t,r)=>{if((t==="Spirits"?e.challengecompletions[12]>0:e.achievements[134]===1)&&isFinite(e.runeshards)&&e.runeshards>0){let a,s,l;t==="Spirits"?(a=o.spiritBaseCost,s=e.runeSpiritLevels[r],l=e.runeSpiritBuyAmount):(a=o.blessingBaseCost,s=e.runeBlessingLevels[r],l=e.runeBlessingBuyAmount);let[c,p]=Zn(s,a,e.runeshards,l);t==="Spirits"?e.runeSpiritLevels[r]=c:e.runeBlessingLevels[r]=c,e.runeshards-=p,e.runeshards<0&&(e.runeshards=0),Ef(t,r)}},Ef=(t,r)=>{if(r===1){let n=[0,1e5,1e8,1e11];for(let a=1;a<=3;a++)e.runeBlessingLevels[1]>=n[a]&&e.achievements[231+a]<1&&R(231+a),e.runeSpiritLevels[1]>=10*n[a]&&e.achievements[234+a]<1&&R(234+a);e.runeBlessingLevels[1]>=1e22&&e.achievements[245]<1&&R(245)}if(_u(),t==="Blessings"){let n=[0,8,10,6.66,2,1],a=r===5?1:0;i(`runeBlessingPower${r}Value1`).innerHTML=u.t("runes.blessings.blessingPower",{reward:u.t(`runes.blessings.rewards.${r-1}`),value:d(o.runeBlessings[r]),speed:d(1-a+n[r]*o.effectiveRuneBlessingPower[r],4,!0)})}else if(t==="Spirits"){let n=[0,1,1,20,1,100];n[r]*=Xe()/400;let a=r===3?1:0;i(`runeSpiritPower${r}Value1`).innerHTML=u.t("runes.spirits.spiritPower",{reward:u.t(`runes.spirits.rewards.${r-1}`),value:d(o.runeSpirits[r]),speed:d(1-a+n[r]*o.effectiveRuneSpiritPower[r],4,!0)})}},Bs=(t,r=100,n=!1)=>{if(t==="Spirits"?e.challengecompletions[12]>0:e.achievements[134]===1){let s=Math.floor(e.runeshards/100*r/5);for(let l=1;l<6;l++)if(isFinite(e.runeshards)&&e.runeshards>0){let c,p;t==="Spirits"?(c=o.spiritBaseCost,p=e.runeSpiritLevels[l]):(c=o.blessingBaseCost,p=e.runeBlessingLevels[l]);let[m,h]=Zn(p,c,s,1e300);m>p&&(!n||(m-p)*1e4>p)&&(t==="Spirits"?e.runeSpiritLevels[l]=m:e.runeBlessingLevels[l]=m,e.runeshards-=h,e.runeshards<0&&(e.runeshards=0),Ef(t,l))}}};var Al=new Map([["A",["Buy Accelerators",()=>Es(),!1]],["B",["Boost Accelerator",()=>Ka(),!1]],["C",["Auto Challenge",()=>{Of()},!1]],["E",["Exit T / R Challenge",()=>{e.autoChallengeRunning?Of():Uf()},!1]],["M",["Multipliers",()=>Os(),!1]],["N",["No (Cancel)",()=>Uu(!1),!0]],["P",["Reset Prestige",()=>Ae("prestige"),!1]],["R",["Reset Reincarnate",()=>Ae("reincarnation"),!1]],["S",["Sacrifice Ants",()=>Rs(),!1]],["T",["Reset Transcend",()=>Ae("transcension"),!1]],["Y",["Yes (OK)",()=>Uu(!0),!0]],["ARROWLEFT",["Back a tab",()=>_o(-1),!1]],["ARROWRIGHT",["Next tab",()=>_o(1),!1]],["ARROWUP",["Back a subtab",()=>_o(-1,!0),!1]],["ARROWDOWN",["Next subtab",()=>_o(1,!0),!1]],["SHIFT+A",["Reset Ascend",()=>Ae("ascension"),!1]],["SHIFT+C",["Cleanse Corruptions",()=>hn(10,999),!1]],["SHIFT+D",["Spec. Action Add x1",()=>xn("add",1),!1]],["SHIFT+E",["Exit Asc. Challenge",()=>Ae("ascensionChallenge"),!1]],["SHIFT+O",["Use Off. Potion",()=>gn("offeringPotion"),!1]],["SHIFT+P",["Use Obt. Potion",()=>gn("obtainiumPotion"),!1]],["SHIFT+S",["Reset Singularity",()=>Ae("singularity"),!1]],["CTRL+B",["Un-hide Tabs",()=>ze.reappend(),!1]]]),Hu=!1,ot=new Map(Al),Of=()=>{e.researches[150]>0&&(Bo(),e.autoChallengeRunning||Uf())},Uf=()=>{e.currentChallenge.reincarnation!==0&&Ae("reincarnationChallenge",void 0,!0),e.currentChallenge.transcension!==0&&Ae("transcensionChallenge",void 0,!0)},nC=t=>{var s;if(!Hu||!e.toggles[39])return;if(((s=document.activeElement)==null?void 0:s.localName)==="input"){t.stopPropagation();return}Rf(t,t.code.replace(/^(Digit|Numpad)/,"").toUpperCase());let r="";t.ctrlKey&&(r+="CTRL+"),t.shiftKey&&(r+="SHIFT+"),t.altKey&&(r+="ALT+");let n=r+t.key.toUpperCase();if(n==="TAB"&&t.preventDefault(),n!=="ENTER"&&i("transparentBG").style.display==="block"&&ot.has(n)&&!ot.get(n)[2])return;let a="";ot.has(n)&&(a=`${ot.get(n)[0]}`,ot.get(n)[1](),t.preventDefault()),o.currentTab===10&&e.subtabNumber===6&&(i("lastHotkey").textContent=n,i("lastHotkeyName").textContent=a)},aC=(t,r)=>{let n=document.createElement("div");n.classList.add("hotkeyItem");let a=document.createElement("span");a.id="actualHotkey",a.textContent=t,a.addEventListener("click",async l=>{var b,C,v;let c=l.target,p=c.textContent.toUpperCase(),g=(v=(b=ot.get(p))==null?void 0:b[0])!=null?v:(C=c.nextSibling)==null?void 0:C.textContent,m=await Ee(` Enter the new key you want to activate ${g} with. MDN has a list of values for "special keys" if you would like to use one: https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key/Key_Values You can also prefix your hotkey with [Ctrl,Shift,Alt]+ - `);if(typeof m!="string")return;let h=m.toUpperCase();if(m.length===0)return void P("You didn't enter anything, canceled!");if(!isNaN(Number(m)))return void P("Number keys are currently unavailable!");if(st.has(h)||p===h)return void P("That key is already binded to an action, use another key instead!");if(st.has(p)){let x=st.get(p);st.set(h,x),st.delete(p);let B=Object.keys(e.hotkeys);e.hotkeys[B.length]=[p,h],c.textContent=h,Io()}else return void P(`No hotkey is triggered by ${p}!`)});let s=document.createElement("p");return s.id="hotKeyDesc",s.textContent=r,n.appendChild(a),n.appendChild(s),n},Tl=()=>Ru=!1,Io=()=>{Wv();let t=document.querySelector(".hotkeys");for(let r of Array.from(t.children))t.removeChild(r);for(let[r,[n]]of[...st.entries()]){let a=Vv(r,n);t.appendChild(a)}Ru=!0},Wv=()=>{st=new Map(Ml);for(let t in e.hotkeys){let r=e.hotkeys[t][0],n=e.hotkeys[t][1];if(st.has(r)){let a=st.get(r);st.set(n,a),st.delete(r)}else Reflect.deleteProperty(e.hotkeys,t)}},Sf=async()=>{if(Io(),Object.keys(e.hotkeys).length===0)return await P("You haven't changed the hotkey");let r="",n=new Map(Ml);for(let s in e.hotkeys){let l=e.hotkeys[s][0],c=e.hotkeys[s][1];if(n.has(l)){let p=n.get(l);r+=` ${l}[${p[0]}] to ${c}, `,n.set(c,p),n.delete(l)}}await we(`Are you sure you want to default all the changed hotkeys? + `);if(typeof m!="string")return;let h=m.toUpperCase();if(m.length===0)return void P("You didn't enter anything, canceled!");if(!isNaN(Number(m)))return void P("Number keys are currently unavailable!");if(ot.has(h)||p===h)return void P("That key is already binded to an action, use another key instead!");if(ot.has(p)){let x=ot.get(p);ot.set(h,x),ot.delete(p);let B=Object.keys(e.hotkeys);e.hotkeys[B.length]=[p,h],c.textContent=h,Do()}else return void P(`No hotkey is triggered by ${p}!`)});let s=document.createElement("p");return s.id="hotKeyDesc",s.textContent=r,n.appendChild(a),n.appendChild(s),n},El=()=>Hu=!1,Do=()=>{sC();let t=document.querySelector(".hotkeys");for(let r of Array.from(t.children))t.removeChild(r);for(let[r,[n]]of[...ot.entries()]){let a=aC(r,n);t.appendChild(a)}Hu=!0},sC=()=>{ot=new Map(Al);for(let t in e.hotkeys){let r=e.hotkeys[t][0],n=e.hotkeys[t][1];if(ot.has(r)){let a=ot.get(r);ot.set(n,a),ot.delete(r)}else Reflect.deleteProperty(e.hotkeys,t)}},Bf=async()=>{if(Do(),Object.keys(e.hotkeys).length===0)return await P("You haven't changed the hotkey");let r="",n=new Map(Al);for(let s in e.hotkeys){let l=e.hotkeys[s][0],c=e.hotkeys[s][1];if(n.has(l)){let p=n.get(l);r+=` ${l}[${p[0]}] to ${c}, `,n.set(c,p),n.delete(l)}}await ye(`Are you sure you want to default all the changed hotkeys? Below is a history of hotkeys you have changed -${r}`)&&(st=new Map(Ml),e.hotkeys={},Io())},No=new Set;document.addEventListener("keydown",t=>{jv(t),No.add(t.code)});document.addEventListener("keyup",t=>No.delete(t.code));var Es=new Map,Sl=0;var Lf=()=>{let t=document.getElementById("notification-count");Sl===0?t.style.display="none":t.style.display="unset",t.textContent=`${Sl}`},Pf=t=>{for(let r of t){let n=r,{id:a,price:s}=n,l=jd(n,["id","price"]);Es.set(a,{quantity:0,price:s,rest:l})}},kl=t=>{let r=Es.get(t);r.quantity++,Sl++,Lf()},Af=t=>{let r=Es.get(t);r.quantity--,Sl--,Lf()},Ef=()=>{let t=0;for(let{price:r,quantity:n}of Es.values())n>0&&(t+=r*n);return t},Of=t=>Es.get(t).quantity,Iu=()=>{let t=[];for(let[r,{quantity:n,price:a,rest:s}]of Es)n>0&&t.push(O({id:r,quantity:n,price:a},s));return t};var Du=document.querySelector("#pseudoCoins > #cartContainer"),Go=Du.querySelector("div.cartList"),$o=Go.querySelector("button#checkout"),Nu=Go.querySelector("button#closeCart"),Uf=Go.querySelector('section > input[type="radio"]'),Kv=Go.querySelector("p#totalCost"),Do=Go.querySelector("#itemList"),_o=!1,zv=Intl.NumberFormat("en-US",{style:"currency",currency:"USD"}),Xv=Hr(t=>{Nu==null||Nu.addEventListener("click",()=>{ve(13,{page:0})}),Uf.addEventListener("click",()=>{_o=!_o,Uf.checked=_o}),Do.insertAdjacentHTML("afterend",t.map(r=>` -
+${r}`)&&(ot=new Map(Al),e.hotkeys={},Do())},Go=new Set;document.addEventListener("keydown",t=>{nC(t),Go.add(t.code)});document.addEventListener("keyup",t=>Go.delete(t.code));var Is=new Map,Ol=0;var If=()=>{let t=document.getElementById("notification-count");Ol===0?t.style.display="none":t.style.display="unset",t.textContent=`${Ol}`},Nf=t=>{for(let r of t){let n=r,{id:a,price:s}=n,l=Jd(n,["id","price"]);Is.set(a,{quantity:0,price:s,rest:l})}},Ns=t=>{let r=Is.get(t);r.quantity++,Ol++,If()},$f=t=>{let r=Is.get(t);r.quantity--,Ol--,If()},_f=()=>{let t=0;for(let{price:r,quantity:n}of Is.values())n>0&&(t+=r*n);return t},Ho=t=>Is.get(t).quantity,Fu=()=>{let t=[];for(let[r,{quantity:n,price:a,rest:s}]of Is)n>0&&t.push(O({id:r,quantity:n,price:a},s));return t};var Vu=document.querySelector("#pseudoCoins > #cartContainer"),jo=Vu.querySelector("div.cartList"),Fo=jo.querySelector("button#checkout"),Qu=jo.querySelector("button#closeCart"),Df=jo.querySelector('section > input[type="radio"]'),oC=jo.querySelector("p#totalCost"),qo=jo.querySelector("#itemList"),Qo=!1,iC=Intl.NumberFormat("en-US",{style:"currency",currency:"USD"}),lC=ar(()=>{Qu==null||Qu.addEventListener("click",()=>{Ce(13,{page:0})}),Df.addEventListener("click",()=>{Qo=!Qo,Df.checked=Qo}),qo.insertAdjacentHTML("afterend",za.map(t=>` +
- `).join("")),$o==null||$o.addEventListener("click",()=>{if(!_o){br("You must accept the terms of service first!");return}let r=new FormData;for(let n of Iu())r.set(`product-${n.id}`,`${n.quantity}`);r.set("tosAgree",_o?"on":"off"),$o.setAttribute("disabled",""),fetch("https://synergism.cc/stripe/create-checkout-session",{method:"POST",body:r}).then(n=>n.json()).then(n=>{n.redirect?window.location.href=n.redirect:br(n.error)}).finally(()=>{$o.removeAttribute("disabled")})})});function $u(t){var n;t.preventDefault();let r=Number((n=t.target.closest("div[key]"))==null?void 0:n.getAttribute("key"));if(Number.isNaN(r)||!Number.isSafeInteger(r)){P("Stop fucking touching the html! We do server-side validation!");return}kl(r),Gu(),Hu()}function _u(t){var n;t.preventDefault();let r=Number((n=t.target.closest("div[key]"))==null?void 0:n.getAttribute("key"));if(Number.isNaN(r)||!Number.isSafeInteger(r)){P("Stop fucking touching the html! We do server-side validation!");return}Af(r),Gu(),Hu()}function Gu(){Do.querySelectorAll(".cartListElementContainer > button").forEach(t=>{t.removeEventListener("click",t.id==="add"?$u:_u)}),Do.innerHTML=Iu().map(t=>` + `).join("")),Fo==null||Fo.addEventListener("click",()=>{if(!Qo){Dt("You must accept the terms of service first!");return}let t=new FormData;for(let n of Fu())t.set(n.id,`${n.quantity}`);t.set("tosAgree",Qo?"on":"off"),Fo.setAttribute("disabled",""),fetch(nt?"https://synergism.cc/stripe/create-checkout-session":"https://synergism.cc/stripe/test/create-checkout-session",{method:"POST",body:t}).then(n=>n.json()).then(n=>{n.redirect?window.location.href=n.redirect:Dt(n.error)}).finally(()=>{Fo.removeAttribute("disabled")})})});function qu(t){var n;t.preventDefault();let r=(n=t.target.closest("div[key]"))==null?void 0:n.getAttribute("key");if(r==null||!za.some(a=>a.id===r)){P("Stop fucking touching the html! We do server-side validation!");return}else if(Mn.some(a=>Ho(a.id)!==0)){P("You can only subscribe to 1 subscription tier!");return}Ns(r),Wu(),Ku()}function ju(t){var n;t.preventDefault();let r=(n=t.target.closest("div[key]"))==null?void 0:n.getAttribute("key");if(r==null||!za.some(a=>a.id===r)){P("Stop fucking touching the html! We do server-side validation!");return}$f(r),Wu(),Ku()}function Wu(){qo.querySelectorAll(".cartListElementContainer > button").forEach(t=>{t.removeEventListener("click",t.id==="add"?qu:ju)}),qo.innerHTML=Fu().map(t=>`
Backed Quark ${t.name} ${t.quantity>0?`x${t.quantity}`:""} - +
- `).join(""),Do.querySelectorAll(".cartListElementContainer > button").forEach(t=>{t.addEventListener("click",t.id==="add"?$u:_u)})}var Bf=t=>{Xv(t),Hu(),Gu(),Du.style.display="flex"},Rf=()=>{Du.style.display="none",Do.querySelectorAll(".cartListElementContainer > button").forEach(t=>{t.removeEventListener("click",t.id==="add"?$u:_u)})},Hu=()=>{Kv.textContent=`${zv.format(Ef()/100)} USD`};var Fu=document.querySelector("#pseudoCoins > #merchContainer"),Zv=Hr(()=>{(async()=>{let r=await(await fetch("https://synergism.cc/api/merch/products")).json();for(let n=0;n1){let c=0,p=a.getElementsByClassName("slide");s.addEventListener("click",()=>{var g,m;(g=p.item(c))==null||g.classList.remove("active"),--c<0&&(c=p.length-1),(m=p.item(c))==null||m.classList.add("active")}),l.addEventListener("click",()=>{var g,m;(g=p.item(c))==null||g.classList.remove("active"),++c>p.length-1&&(c=0),(m=p.item(c))==null||m.classList.add("active")})}a.appendChild(s),a.appendChild(l),a.querySelector(".slide").classList.add("active"),Fu.querySelector("#slideshows").appendChild(a)}})()}),If=()=>{Zv(),Fu.style.display="flex"},Nf=()=>{Fu.style.display="none"};var Ll=document.querySelector("#pseudoCoins > #productContainer"),Yv=Intl.NumberFormat("en-US",{style:"currency",currency:"USD"}),Jv=t=>{let r=Number(t.target.getAttribute("data-id")),n=t.target.getAttribute("data-name");if(Number.isNaN(r)||!Number.isSafeInteger(r)){P("Stop fucking touching the html! We do server-side validation!");return}kl(r),br(`Added ${n} to the cart!`)},eC=Hr(t=>{Ll.innerHTML=t.map(r=>` -
+ `).join(""),qo.querySelectorAll(".cartListElementContainer > button").forEach(t=>{t.addEventListener("click",t.id==="add"?qu:ju)})}var Gf=()=>{lC(),Ku(),Wu(),Vu.style.display="flex"},Hf=()=>{Vu.style.display="none",qo.querySelectorAll(".cartListElementContainer > button").forEach(t=>{t.removeEventListener("click",t.id==="add"?qu:ju)})},Ku=()=>{oC.textContent=`${iC.format(_f()/100)} USD`};var zu=document.querySelector("#pseudoCoins > #merchContainer"),cC=ar(()=>{(async()=>{let r=await(await fetch("https://synergism.cc/api/merch/products")).json();for(let n=0;n1){let c=0,p=a.getElementsByClassName("slide");s.addEventListener("click",()=>{var g,m;(g=p.item(c))==null||g.classList.remove("active"),--c<0&&(c=p.length-1),(m=p.item(c))==null||m.classList.add("active")}),l.addEventListener("click",()=>{var g,m;(g=p.item(c))==null||g.classList.remove("active"),++c>p.length-1&&(c=0),(m=p.item(c))==null||m.classList.add("active")})}a.appendChild(s),a.appendChild(l),a.querySelector(".slide").classList.add("active"),zu.querySelector("#slideshows").appendChild(a)}})()}),Ff=()=>{cC(),zu.style.display="flex"},Qf=()=>{zu.style.display="none"};var Ul=document.querySelector("#pseudoCoins > #productContainer"),uC=Intl.NumberFormat("en-US",{style:"currency",currency:"USD"}),dC=t=>{let r=t.target.getAttribute("data-id"),n=t.target.getAttribute("data-name");if(r===null||!Bl.some(a=>a.id===r)){P("Stop fucking touching the html! We do server-side validation!");return}Ns(r),Dt(`Added ${n} to the cart!`)},pC=ar(()=>{Ul.innerHTML=Bl.map(t=>` +
- ${r.name} + ${t.name}

- ${r.name} [${d(r.coins)} PseudoCoins] + ${t.name} [${d(t.coins)} PseudoCoins]

-
- `).join(""),Ll.style.display="grid",document.querySelectorAll(".pseudoCoinContainer > div > button[data-id]").forEach(r=>{r.addEventListener("click",Jv)})}),$f=()=>{Ll.style.display="none"},_f=t=>{eC(t),Ll.style.display="grid"};var Qa=document.querySelector("#pseudoCoins > #upgradesContainer"),Qu,tC=y.object({upgradeId:y.number(),level:y.number()});function Df(t){var p,g;Qu=t;let r=u.t(`pseudoCoins.upgradeNames.${t==null?void 0:t.internalName}`);i("pCoinUpgradeName").textContent=`${r!=null?r:"???"}`,i("description").textContent=`${(p=t==null?void 0:t.description)!=null?p:"???"}`,i("pCoinUpgradeIcon").setAttribute("src",`Pictures/PseudoShop/${(g=t==null?void 0:t.internalName)!=null?g:"PseudoCoins"}.png`);let n=i("buy"),a=i("pCoinEffectCurr"),s=i("pCoinEffectNext");a.innerHTML=`${u.t("pseudoCoins.currEffect")} ${u.t(qu(t.internalName,t.playerLevel))}`,s.innerHTML=`${u.t("pseudoCoins.nextEffect")} ${u.t(qu(t.internalName,t.playerLevel+1))}`;let l=i("pCoinScalingCosts"),c=i("pCoinScalingEffect");if(t&&t.playerLevel===t.maxLevel)n==null||n.setAttribute("disabled",""),n.setAttribute("style","display: none"),s.setAttribute("style","display: none");else{n==null||n.removeAttribute("disabled"),n.removeAttribute("style"),s.removeAttribute("style"),n.innerHTML=t?`${u.t("pseudoCoins.buyButton",{amount:Intl.NumberFormat().format(t.cost[t.playerLevel])})}`:"Cannot buy. Sorry!";let m=Qf(t.internalName);l.innerHTML=m.cost,c.innerHTML=m.effect}}async function rC(t){if(!Qu){P("Click on an upgrade to buy it.");return}let n=await(await fetch(`https://synergism.cc/stripe/buy-upgrade/${Qu.upgradeId}`,{method:"PUT"})).json(),a=tC.safeParse(n);if(!a.success){P(`Didn't buy the upgrade... try again? ${JSON.stringify(n)}`);return}let s=t==null?void 0:t.get(a.data.upgradeId);if(s){s.playerLevel=a.data.level,P(`Upgraded ${s.name} (${s.description}) to ${a.data.level}!`),Qa.querySelector("#upgradeGrid > .active > p#a").textContent=`${s.playerLevel}/${s.maxLevel}`,Qa.querySelector("#upgradeGrid > .active > p#b").textContent=s.playerLevel===s.maxLevel?"\u2714\uFE0F":"",Df(s);let c=await(await fetch("https://synergism.cc/stripe/coins")).json();Qa.querySelector("#pseudoCoinAmounts > #currentCoinBalance").innerHTML=`${u.t("pseudoCoins.coinCount",{amount:Intl.NumberFormat().format(c.coins)})}`,Ff(s.internalName,a.data.level)}else P("Upgrades did not load. Please refresh the page.")}var nC=Hr(()=>{(async()=>{let r=await(await fetch("https://synergism.cc/stripe/upgrades")).json();i("currentCoinBalance").innerHTML=`${u.t("pseudoCoins.coinCount",{amount:Intl.NumberFormat().format(r.coins)})}`;let n=r.upgrades.reduce((s,l)=>{var g;let c=s.get(l.upgradeId),p=r.playerUpgrades.find(m=>m.upgradeId===l.upgradeId);return c?(c.maxLevel=Math.max(c.maxLevel,l.maxLevel),c.cost.push(l.cost),c.level.push(l.level)):s.set(l.upgradeId,ee(O({},l),{cost:[l.cost],level:[l.level],playerLevel:(g=p==null?void 0:p.level)!=null?g:0})),s},new Map);Qa.querySelector("#upgradeGrid").innerHTML=[...n.values()].map(s=>` -
- ${s.internalName} -

${s.playerLevel}/${s.maxLevel}

- ${s.playerLevel===s.maxLevel?'

\u2714\uFE0F

':'

'} + `).join(""),Ul.style.display="grid",document.querySelectorAll(".pseudoCoinContainer > div > button[data-id]").forEach(t=>{t.addEventListener("click",dC)})}),qf=()=>{Ul.style.display="none"},jf=()=>{pC(),Ul.style.display="grid"};var Rl=document.querySelector("#pseudoCoins > #subscriptionsContainer"),Vf=Rl.querySelector("#sub-section-holder"),Vo=Intl.NumberFormat("en-US",{style:"currency",currency:"USD"}),Kf=[0,300,600,1e3,2e3];async function Wf(t,r){var b;let n=Tn.tier,a=(b=Kf[n])!=null?b:0,s=Mn.find(C=>C.id===t),l=s.price,c=s.name;if(!(r==="downgrade"?await ye(`You are downgrading to ${c}, which costs ${Vo.format((a-l)/100)} less per month. New cost: ${Vo.format(l/100)} per month. Downgrading takes effect immediately!`):await ye(`You are upgrading to ${c}, which costs ${Vo.format((l-a)/100)} more per month. New cost: ${Vo.format(l/100)} per month`)))return;let g=nt?`https://synergism.cc/stripe/subscription/${r}`:`https://synergism.cc/stripe/test/subscription/${r}`,m=new URL(g);m.searchParams.set("key",t);let h=await fetch(m,{method:"POST"});return console.log(h,h.text()),P(`You are now subscribed to ${c}!`)}function gC(t){let r=t.target.getAttribute("data-id"),n=t.target.getAttribute("data-name");if(r===null||!Mn.some(a=>a.id===r)){P("Stop fucking touching the html! We do server-side validation!");return}else if(Mn.some(a=>Ho(a.id)!==0)){P("You can only subscribe to 1 subscription tier!");return}if(Tn.tier!==0){if(this.hasAttribute("data-downgrade")){Wf(r,"downgrade");return}else if(this.hasAttribute("data-upgrade")){Wf(r,"upgrade");return}}Ns(r),Dt(`Added ${n} to the cart!`)}var Xu=t=>{let[r,n]=t.split(" and "),a=n.charAt(0).toUpperCase()+n.slice(1);return`${r} +
+ ${a}`},mC=(t,r)=>t.price +
+ ${t.name} +

+ ${t.name.split(" - ").join("
")} +

+

+ ${Xu(t.description)} +

+ +
+
+ `:t.price===r?` +
+
+ ${t.name} +

+ ${t.name.split(" - ").join("
")} +

+

+ ${Xu(t.description)} +

+
- `).join("");let a=Qa.querySelectorAll("#upgradeGrid > div[data-id]");a.forEach(s=>{s.addEventListener("click",l=>{var p;let c=Number((p=l.target.closest("div"))==null?void 0:p.getAttribute("data-id"));if(Number.isNaN(c)||!Number.isSafeInteger(c)){P("Stop touching the fucking html! We do server-side validations!");return}Df([...n.values()].find(g=>g.upgradeId===c)),a.forEach(g=>g.classList.remove("active")),s.classList.add("active")})}),i("buy").addEventListener("click",()=>{rC(n)})})()}),Gf=()=>{nC(),Qa.style.display="flex"},Hf=()=>{Qa.style.display="none"};var Os={Coins:0,Upgrades:1,Checkout:2,Merch:3},aC=document.getElementById("pseudoCoins");function*qf(t){let r=aC.querySelectorAll(t);for(let n=0;nr.json()).then(r=>{var n;te(Xt,Us).push(...r),Pf(r),(n=te(Xt,Mn))==null||n.resolve(void 0)},te(Xt,Mn).reject)),te(Xt,Mn).promise}static applySubtabListeners(){for(let[r,n]of qf(".subtabSwitcher button"))n.addEventListener("click",()=>{ys()||!Dr?ve(13,{page:r}):P("Note: you must be logged in to view this tab!")})}},qa=Xt;Mn=new WeakMap,Us=new WeakMap,Pl=new WeakSet,jf=function(){for(let[r,n]of qf(".subtabSwitcher button"))e.subtabNumber===r?n.classList.add("active-subtab"):n.classList.remove("active-subtab");switch($f(),Hf(),Rf(),Nf(),e.subtabNumber){case Os.Coins:Xt.fetchProducts().then(()=>{e.subtabNumber===Os.Coins&&_f(te(Xt,Us))});break;case Os.Upgrades:Gf();break;case Os.Checkout:Xt.fetchProducts().then(()=>{e.subtabNumber===Os.Checkout&&Bf(te(Xt,Us))});break;case Os.Merch:If();break}},xt(qa,Mn,void 0),xt(qa,Us,[]);var sC=Hr(()=>{qa.fetchProducts(),qa.applySubtabListeners(),(!ys()||!Dr)&&ve(13,{step:1})}),Al=()=>{sC(),new qa};var Wf={[10]:{tabSwitcher:()=>tf,subTabList:[{subTabID:"settingsubtab",unlocked:!0,buttonID:"switchSettingSubTab1"},{subTabID:"languagesubtab",unlocked:!0,buttonID:"switchSettingSubTab2"},{subTabID:"creditssubtab",unlocked:!0,buttonID:"switchSettingSubTab3"},{subTabID:"statisticsSubTab",unlocked:!0,buttonID:"switchSettingSubTab4"},{subTabID:"resetHistorySubTab",get unlocked(){return e.unlocks.prestige},buttonID:"switchSettingSubTab5"},{subTabID:"ascendHistorySubTab",get unlocked(){return e.ascensionCount>0},buttonID:"switchSettingSubTab6"},{subTabID:"singularityHistorySubTab",get unlocked(){return e.highestSingularityCount>0},buttonID:"switchSettingSubTab7"},{subTabID:"hotkeys",unlocked:!0,buttonID:"switchSettingSubTab8"},{subTabID:"accountSubTab",unlocked:!0,buttonID:"switchSettingSubTab9"}]},[11]:{subTabList:[]},[0]:{tabSwitcher:()=>Km,subTabList:[{subTabID:"coin",unlocked:!0,buttonID:"switchToCoinBuilding"},{subTabID:"diamond",get unlocked(){return e.unlocks.prestige},buttonID:"switchToDiamondBuilding"},{subTabID:"mythos",get unlocked(){return e.unlocks.transcend},buttonID:"switchToMythosBuilding"},{subTabID:"particle",get unlocked(){return e.unlocks.reincarnate},buttonID:"switchToParticleBuilding"},{subTabID:"tesseract",get unlocked(){return e.achievements[183]>0},buttonID:"switchToTesseractBuilding"}]},[1]:{subTabList:[]},[2]:{subTabList:[]},[3]:{tabSwitcher:()=>zm,subTabList:[{subTabID:"1",get unlocked(){return e.unlocks.prestige},buttonID:"toggleRuneSubTab1"},{subTabID:"2",get unlocked(){return e.achievements[134]>0},buttonID:"toggleRuneSubTab2"},{subTabID:"3",get unlocked(){return e.achievements[134]>0},buttonID:"toggleRuneSubTab3"},{subTabID:"4",get unlocked(){return e.achievements[204]>0},buttonID:"toggleRuneSubTab4"}]},[4]:{tabSwitcher:()=>Xm,subTabList:[{subTabID:"1",unlocked:!0,buttonID:"toggleChallengesSubTab1"},{subTabID:"2",get unlocked(){return e.highestSingularityCount>=25},buttonID:"toggleChallengesSubTab2"}]},[5]:{subTabList:[]},[6]:{subTabList:[]},[7]:{tabSwitcher:()=>of,subTabList:[{subTabID:"1",get unlocked(){return e.achievements[141]>0},buttonID:"switchCubeSubTab1"},{subTabID:"2",get unlocked(){return e.achievements[197]>0},buttonID:"switchCubeSubTab2"},{subTabID:"3",get unlocked(){return e.achievements[211]>0},buttonID:"switchCubeSubTab3"},{subTabID:"4",get unlocked(){return e.achievements[218]>0},buttonID:"switchCubeSubTab4"},{subTabID:"5",get unlocked(){return e.achievements[141]>0},buttonID:"switchCubeSubTab5"},{subTabID:"6",get unlocked(){return e.achievements[218]>0},buttonID:"switchCubeSubTab6"},{subTabID:"7",get unlocked(){return e.challenge15Exponent>=1e15},buttonID:"switchCubeSubTab7"}]},[8]:{tabSwitcher:()=>uf,subTabList:[{subTabID:"true",get unlocked(){return e.achievements[141]>0},buttonID:"corrStatsBtn"},{subTabID:"false",get unlocked(){return e.achievements[141]>0},buttonID:"corrLoadoutsBtn"}]},[9]:{tabSwitcher:()=>ef,subTabList:[{subTabID:"1",get unlocked(){return e.highestSingularityCount>0},buttonID:"toggleSingularitySubTab1"},{subTabID:"2",get unlocked(){return e.highestSingularityCount>0},buttonID:"toggleSingularitySubTab2"},{subTabID:"3",get unlocked(){return!!e.singularityUpgrades.octeractUnlock.getEffect().bonus},buttonID:"toggleSingularitySubTab3"},{subTabID:"4",get unlocked(){return e.singularityChallenges.noSingularityUpgrades.completions>=1},buttonID:"toggleSingularitySubTab4"}]},[12]:{subTabList:[]},[13]:{tabSwitcher:()=>Al,subTabList:[{subTabID:"productContainer",get unlocked(){return ys()||!Dr},buttonID:"cartSubTab1"},{subTabID:"upgradesContainer",unlocked:!0,buttonID:"cartSubTab2"},{subTabID:"cartContainer",get unlocked(){return ys()||!Dr},buttonID:"cartSubTab3"},{subTabID:"merchContainer",unlocked:!0,buttonID:"cartSubTab4"}]}},Re,Zt,Ol,Kf,El=class extends HTMLDivElement{constructor(){super();xt(this,Ol);xt(this,Re,[]);xt(this,Zt,void 0);this.id="tabrow",this.style.cssText=` +
+ `:` +
+
+ ${t.name} +

+ ${t.name.split(" - ").join("
")} +

+

+ ${Xu(t.description)} +

+ +
+
+ `,fC=ar(()=>{var n;{let a=document.createElement("form");a.action=nt?"https://synergism.cc/stripe/manage-subscription":"https://synergism.cc/stripe/test/manage-subscription";let s=document.createElement("input");s.type="submit",s.value="Manage Subscription",a.appendChild(s),Rl.prepend(a)}let t=Tn.tier,r=(n=Kf[t])!=null?n:0;Vf.innerHTML=Mn.map(a=>mC(a,r)).join(""),Vf.style.display="grid",document.querySelectorAll(".subscriptionContainer > div > button[data-id]").forEach(a=>{a.addEventListener("click",gC)})}),zf=()=>{Rl.style.display="none"},Xf=()=>{fC(),Rl.style.display="flex"};var Xa=document.querySelector("#pseudoCoins > #upgradesContainer"),Zu,hC=y.object({upgradeId:y.number(),level:y.number()});function Zf(t){var p,g;Zu=t;let r=u.t(`pseudoCoins.upgradeNames.${t==null?void 0:t.internalName}`);i("pCoinUpgradeName").textContent=`${r!=null?r:"???"}`,i("description").textContent=`${(p=t==null?void 0:t.description)!=null?p:"???"}`,i("pCoinUpgradeIcon").setAttribute("src",`Pictures/PseudoShop/${(g=t==null?void 0:t.internalName)!=null?g:"PseudoCoins"}.png`);let n=i("buy"),a=i("pCoinEffectCurr"),s=i("pCoinEffectNext");a.innerHTML=`${u.t("pseudoCoins.currEffect")} ${u.t(Yu(t.internalName,t.playerLevel))}`,s.innerHTML=`${u.t("pseudoCoins.nextEffect")} ${u.t(Yu(t.internalName,t.playerLevel+1))}`;let l=i("pCoinScalingCosts"),c=i("pCoinScalingEffect");if(t&&t.playerLevel===t.maxLevel)n==null||n.setAttribute("disabled",""),n.setAttribute("style","display: none"),s.setAttribute("style","display: none");else{n==null||n.removeAttribute("disabled"),n.removeAttribute("style"),s.removeAttribute("style"),n.innerHTML=t?`${u.t("pseudoCoins.buyButton",{amount:Intl.NumberFormat().format(t.cost[t.playerLevel])})}`:"Cannot buy. Sorry!";let m=t0(t.internalName);l.innerHTML=m.cost,c.innerHTML=m.effect}}async function bC(t){if(!Zu){P("Click on an upgrade to buy it.");return}let n=await(await fetch(`https://synergism.cc/stripe/buy-upgrade/${Zu.upgradeId}`,{method:"PUT"})).json(),a=hC.safeParse(n);if(!a.success){P(`Didn't buy the upgrade... try again? ${JSON.stringify(n)}`);return}let s=t==null?void 0:t.get(a.data.upgradeId);if(s){s.playerLevel=a.data.level,P(`Upgraded ${s.name} (${s.description}) to ${a.data.level}!`),Xa.querySelector("#upgradeGrid > .active > p#a").textContent=`${s.playerLevel}/${s.maxLevel}`,Xa.querySelector("#upgradeGrid > .active > p#b").textContent=s.playerLevel===s.maxLevel?"\u2714\uFE0F":"",Zf(s);let c=await(await fetch("https://synergism.cc/stripe/coins")).json();Xa.querySelector("#pseudoCoinAmounts > #currentCoinBalance").innerHTML=`${u.t("pseudoCoins.coinCount",{amount:Intl.NumberFormat().format(c.coins)})}`,e0(s.internalName,a.data.level)}else P("Upgrades did not load. Please refresh the page.")}var yC=ar(()=>{i("currentCoinBalance").innerHTML=`${u.t("pseudoCoins.coinCount",{amount:Intl.NumberFormat().format(Tn.coins)})}`;let t=Tn.upgrades.reduce((n,a)=>{var c;let s=n.get(a.upgradeId),l=Tn.playerUpgrades.find(p=>p.upgradeId===a.upgradeId);return s?(s.maxLevel=Math.max(s.maxLevel,a.maxLevel),s.cost.push(a.cost),s.level.push(a.level)):n.set(a.upgradeId,te(O({},a),{cost:[a.cost],level:[a.level],playerLevel:(c=l==null?void 0:l.level)!=null?c:0})),n},new Map);Xa.querySelector("#upgradeGrid").innerHTML=[...t.values()].map(n=>` +
+ ${n.internalName} +

${n.playerLevel}/${n.maxLevel}

+ ${n.playerLevel===n.maxLevel?'

\u2714\uFE0F

':'

'} +
+ `).join("");let r=Xa.querySelectorAll("#upgradeGrid > div[data-id]");r.forEach(n=>{n.addEventListener("click",a=>{var l;let s=Number((l=a.target.closest("div"))==null?void 0:l.getAttribute("data-id"));if(Number.isNaN(s)||!Number.isSafeInteger(s)){P("Stop touching the fucking html! We do server-side validations!");return}Zf([...t.values()].find(c=>c.upgradeId===s)),r.forEach(c=>c.classList.remove("active")),n.classList.add("active")})}),i("buy").addEventListener("click",()=>{bC(t)})}),Yf=()=>{yC(),Xa.style.display="flex"},Jf=()=>{Xa.style.display="none"};var za=[],Bl=[],Mn=[],Tn,Sn={Coins:0,Subscriptions:1,Upgrades:2,Checkout:3,Merch:4},vC=document.getElementById("pseudoCoins");function*r0(t){let r=vC.querySelectorAll(t);for(let n=0;nn.json()).then(n=>{var a;za.push(...n),Nf(n),Bl=za.filter(s=>!s.subscription),Mn=za.filter(s=>s.subscription),Mn.sort((s,l)=>s.price-l.price),(a=ee(it,kn))==null||a.resolve(void 0)},ee(it,kn).reject)),ee(it,kn).promise}static fetchUpgrades(){return ee(it,Ln)||(St(it,Ln,Fn()),fetch(nt?"https://synergism.cc/stripe/upgrades":"https://synergism.cc/stripe/test/upgrades").then(n=>n.json()).then(n=>{ee(it,Ln).resolve(n),Tn=n},ee(it,Ln).reject)),ee(it,Ln).promise}static applySubtabListeners(){for(let[r,n]of r0(".subtabSwitcher button"))n.addEventListener("click",()=>{Da()||!nt?Ce(13,{page:r}):P("Note: you must be logged in to view this tab!")})}},Pn=it;kn=new WeakMap,Ln=new WeakMap,Il=new WeakSet,n0=function(){for(let[r,n]of r0(".subtabSwitcher button"))e.subtabNumber===r?n.classList.add("active-subtab"):n.classList.remove("active-subtab");switch(qf(),zf(),Jf(),Hf(),Qf(),e.subtabNumber){case Sn.Coins:it.fetchProducts().then(()=>{e.subtabNumber===Sn.Coins&&jf()});break;case Sn.Subscriptions:it.fetchProducts().then(()=>{e.subtabNumber===Sn.Subscriptions&&Xf()});break;case Sn.Upgrades:it.fetchUpgrades().then(()=>{e.subtabNumber===Sn.Upgrades&&Yf()});break;case Sn.Checkout:it.fetchProducts().then(()=>{e.subtabNumber===Sn.Checkout&&Gf()});break;case Sn.Merch:Ff();break}},Tt(Pn,kn,void 0),Tt(Pn,Ln,void 0);var CC=ar(()=>{Pn.fetchProducts(),Pn.applySubtabListeners(),(!Da()||!nt)&&Ce(13,{step:1})}),Nl=()=>{CC(),new Pn};var s0={[10]:{tabSwitcher:()=>uf,subTabList:[{subTabID:"settingsubtab",unlocked:!0,buttonID:"switchSettingSubTab1"},{subTabID:"languagesubtab",unlocked:!0,buttonID:"switchSettingSubTab2"},{subTabID:"creditssubtab",unlocked:!0,buttonID:"switchSettingSubTab3"},{subTabID:"statisticsSubTab",unlocked:!0,buttonID:"switchSettingSubTab4"},{subTabID:"resetHistorySubTab",get unlocked(){return e.unlocks.prestige},buttonID:"switchSettingSubTab5"},{subTabID:"ascendHistorySubTab",get unlocked(){return e.ascensionCount>0},buttonID:"switchSettingSubTab6"},{subTabID:"singularityHistorySubTab",get unlocked(){return e.highestSingularityCount>0},buttonID:"switchSettingSubTab7"},{subTabID:"hotkeys",unlocked:!0,buttonID:"switchSettingSubTab8"},{subTabID:"accountSubTab",unlocked:!0,buttonID:"switchSettingSubTab9"}]},[11]:{subTabList:[]},[0]:{tabSwitcher:()=>rf,subTabList:[{subTabID:"coin",unlocked:!0,buttonID:"switchToCoinBuilding"},{subTabID:"diamond",get unlocked(){return e.unlocks.prestige},buttonID:"switchToDiamondBuilding"},{subTabID:"mythos",get unlocked(){return e.unlocks.transcend},buttonID:"switchToMythosBuilding"},{subTabID:"particle",get unlocked(){return e.unlocks.reincarnate},buttonID:"switchToParticleBuilding"},{subTabID:"tesseract",get unlocked(){return e.achievements[183]>0},buttonID:"switchToTesseractBuilding"}]},[1]:{subTabList:[]},[2]:{subTabList:[]},[3]:{tabSwitcher:()=>nf,subTabList:[{subTabID:"1",get unlocked(){return e.unlocks.prestige},buttonID:"toggleRuneSubTab1"},{subTabID:"2",get unlocked(){return e.achievements[134]>0},buttonID:"toggleRuneSubTab2"},{subTabID:"3",get unlocked(){return e.achievements[134]>0},buttonID:"toggleRuneSubTab3"},{subTabID:"4",get unlocked(){return e.achievements[204]>0},buttonID:"toggleRuneSubTab4"}]},[4]:{tabSwitcher:()=>af,subTabList:[{subTabID:"1",unlocked:!0,buttonID:"toggleChallengesSubTab1"},{subTabID:"2",get unlocked(){return e.highestSingularityCount>=25},buttonID:"toggleChallengesSubTab2"}]},[5]:{subTabList:[]},[6]:{subTabList:[]},[7]:{tabSwitcher:()=>ff,subTabList:[{subTabID:"1",get unlocked(){return e.achievements[141]>0},buttonID:"switchCubeSubTab1"},{subTabID:"2",get unlocked(){return e.achievements[197]>0},buttonID:"switchCubeSubTab2"},{subTabID:"3",get unlocked(){return e.achievements[211]>0},buttonID:"switchCubeSubTab3"},{subTabID:"4",get unlocked(){return e.achievements[218]>0},buttonID:"switchCubeSubTab4"},{subTabID:"5",get unlocked(){return e.achievements[141]>0},buttonID:"switchCubeSubTab5"},{subTabID:"6",get unlocked(){return e.achievements[218]>0},buttonID:"switchCubeSubTab6"},{subTabID:"7",get unlocked(){return e.challenge15Exponent>=1e15},buttonID:"switchCubeSubTab7"}]},[8]:{tabSwitcher:()=>yf,subTabList:[{subTabID:"true",get unlocked(){return e.achievements[141]>0},buttonID:"corrStatsBtn"},{subTabID:"false",get unlocked(){return e.achievements[141]>0},buttonID:"corrLoadoutsBtn"}]},[9]:{tabSwitcher:()=>cf,subTabList:[{subTabID:"1",get unlocked(){return e.highestSingularityCount>0},buttonID:"toggleSingularitySubTab1"},{subTabID:"2",get unlocked(){return e.highestSingularityCount>0},buttonID:"toggleSingularitySubTab2"},{subTabID:"3",get unlocked(){return!!e.singularityUpgrades.octeractUnlock.getEffect().bonus},buttonID:"toggleSingularitySubTab3"},{subTabID:"4",get unlocked(){return e.singularityChallenges.noSingularityUpgrades.completions>=1},buttonID:"toggleSingularitySubTab4"}]},[12]:{subTabList:[]},[13]:{tabSwitcher:()=>Nl,subTabList:[{subTabID:"productContainer",get unlocked(){return Da()||!nt},buttonID:"cartSubTab1"},{subTabID:"subscriptionContainer",get unlocked(){return Da()||!nt},buttonID:"cartSubTab2"},{subTabID:"upgradesContainer",unlocked:!0,buttonID:"cartSubTab3"},{subTabID:"cartContainer",get unlocked(){return Da()||!nt},buttonID:"cartSubTab4"},{subTabID:"merchContainer",unlocked:!0,buttonID:"cartSubTab5"}]}},Re,Jt,_l,o0,$l=class extends HTMLDivElement{constructor(){super();Tt(this,_l);Tt(this,Re,[]);Tt(this,Jt,void 0);this.id="tabrow",this.style.cssText=` text-align: center; width: 100%; list-style: none; @@ -127,21 +174,21 @@ ${r}`)&&(st=new Map(Ml),e.hotkeys={},Io())},No=new Set;document.addEventListener display: flex; justify-content: center; gap: 0 5px; - `}getSubs(){return te(this,Re)}appendButton(...n){for(let a of n)te(this,Re).push(a),this.appendChild(a);Et(this,Zt,te(this,Re)[0]),ni(this,Ol,Kf).call(this)}getCurrentTab(){return te(this,Zt)}setNextTab(){var a;let n=te(this,Re).indexOf(te(this,Zt));return Et(this,Zt,(a=te(this,Re)[n+1])!=null?a:te(this,Re)[0]),te(this,Zt)}setPreviousTab(){var a;let n=te(this,Re).indexOf(te(this,Zt));return Et(this,Zt,(a=te(this,Re)[n-1])!=null?a:te(this,Re)[te(this,Re).length-1]),te(this,Zt)}getNextTab(n=te(this,Zt)){var s;let a=te(this,Re).indexOf(n);return(s=te(this,Re)[a+1])!=null?s:te(this,Re)[0]}getPreviousTab(n=te(this,Zt)){var s;let a=te(this,Re).indexOf(n);return(s=te(this,Re)[a-1])!=null?s:te(this,Re)[te(this,Re).length-1]}reappend(){this.replaceChildren();for(let n of te(this,Re))this.appendChild(n);te(this,Re).forEach(n=>n.resetHidden())}};Re=new WeakMap,Zt=new WeakMap,Ol=new WeakSet,Kf=function(){let n=null,a=g=>{Nn(g.target instanceof HTMLElement),g.target.style.opacity="0.4",n=g.target,g.dataTransfer.effectAllowed="move"},s=g=>{g.target instanceof HTMLElement&&g.target.classList.add("over")},l=g=>{g.target instanceof HTMLElement&&g.target.classList.remove("over")},c=g=>{if(g.stopPropagation(),n!==g.target&&n!==null){this.insertBefore(n,g.target);let m=te(this,Re).indexOf(n),h=te(this,Re).indexOf(g.target);te(this,Re).splice(h,0,te(this,Re)[m]),te(this,Re).splice(te(this,Re).indexOf(n,m),1)}return!1},p=g=>{Nn(g.target instanceof HTMLElement),g.target.style.opacity="1",te(this,Re).forEach(m=>{m.classList.remove("over")})};te(this,Re).forEach(g=>{g.addEventListener("dragstart",a,!1),g.addEventListener("dragenter",s,!1),g.addEventListener("dragover",c,!1),g.addEventListener("dragleave",l,!1),g.addEventListener("drop",c,!1),g.addEventListener("dragend",p,!1)})};var Ho,zn,Fo,Bs,pt=class extends HTMLButtonElement{constructor(n){super();xt(this,Ho,()=>!0);xt(this,zn,void 0);xt(this,Fo,!1);xt(this,Bs,!1);this.id=n.id,n.class&&this.classList.add(n.class),n.i18n&&this.setAttribute("i18n",n.i18n),n.borderColor&&(this.style.borderColor=n.borderColor),this.addEventListener("click",()=>{te(this,Fo)&&No.has("ControlLeft")&&No.has("KeyX")?o.currentTab!==te(this,zn)&&(ze.removeChild(this),Et(this,Bs,!0)):(bn(te(this,zn)),Ul())})}setUnlockedState(n){return Et(this,Ho,n),this}isUnlocked(){return te(this,Ho).call(this)&&!te(this,Bs)}setType(n){return Et(this,zn,n),this}getType(){return te(this,zn)}getSubTabs(){return Wf[te(this,zn)]}makeDraggable(){return this.setAttribute("draggable","true"),this}makeRemoveable(){return Et(this,Fo,!0),this}resetHidden(){Et(this,Bs,!1)}};Ho=new WeakMap,zn=new WeakMap,Fo=new WeakMap,Bs=new WeakMap;customElements.define("tab-row",El,{extends:"div"});customElements.define("sub-tab",pt,{extends:"button"});var ze=new El,Vf;(Vf=document.getElementsByClassName("navbar").item(0))==null||Vf.appendChild(ze);ze.appendButton(new pt({id:"buildingstab",i18n:"tabs.main.buildings"}).setType(0).makeDraggable().makeRemoveable(),new pt({id:"upgradestab",i18n:"tabs.main.upgrades"}).setType(1).makeDraggable().makeRemoveable(),new pt({id:"achievementstab",i18n:"tabs.main.achievements",class:"coinunlock4"}).setUnlockedState(()=>e.unlocks.coinfour).setType(2).makeDraggable().makeRemoveable(),new pt({class:"prestigeunlock",id:"runestab",i18n:"tabs.main.runes"}).setUnlockedState(()=>e.unlocks.prestige).setType(3).makeDraggable().makeRemoveable(),new pt({class:"transcendunlock",id:"challengetab",i18n:"tabs.main.challenges"}).setUnlockedState(()=>e.unlocks.transcend).setType(4).makeDraggable().makeRemoveable(),new pt({class:"reincarnationunlock",id:"researchtab",i18n:"tabs.main.research"}).setUnlockedState(()=>e.unlocks.reincarnate).setType(5).makeDraggable().makeRemoveable(),new pt({class:"chal8",id:"anttab",i18n:"tabs.main.antHill"}).setUnlockedState(()=>e.achievements[127]>0).setType(6).makeDraggable().makeRemoveable(),new pt({class:"chal10",id:"cubetab",i18n:"tabs.main.wowCubes"}).setUnlockedState(()=>e.achievements[141]>0).setType(7).makeDraggable().makeRemoveable(),new pt({class:"chal11",id:"traitstab",i18n:"tabs.main.corruption"}).setUnlockedState(()=>e.challengecompletions[11]>0).setType(8).makeDraggable().makeRemoveable(),new pt({class:"singularity",id:"singularitytab",i18n:"tabs.main.singularity"}).setUnlockedState(()=>e.highestSingularityCount>0).setType(9).makeDraggable().makeRemoveable(),new pt({id:"settingstab",i18n:"tabs.main.settings"}).setType(10).makeDraggable(),new pt({class:"reincarnationunlock",id:"shoptab",i18n:"tabs.main.shop"}).setUnlockedState(()=>e.unlocks.reincarnate||e.highestSingularityCount>0).setType(11).makeDraggable().makeRemoveable(),new pt({class:"isEvent",id:"eventtab",i18n:"tabs.main.unsmith"}).setUnlockedState(()=>o.isEvent).setType(12).makeDraggable().makeRemoveable(),new pt({id:"pseudoCoinstab",i18n:"tabs.main.purchase"}).setType(13).makeDraggable());var Ro=(t=1,r=!1)=>{let n=t===1?ze.getNextTab():ze.getPreviousTab();for(;!(n!=null&&n.isUnlocked());)n=t===1?ze.getNextTab(n):ze.getPreviousTab(n);r?ve(n.getType(),{step:t}):bn(n.getType(),t)},bn=(t,r)=>{var a;if(r===1)ze.setNextTab();else if(r===-1)ze.setPreviousTab();else for(;ze.getCurrentTab().getType()!==t;)ze.setNextTab();for(;!ze.getCurrentTab().isUnlocked();)r===1||r===void 0?ze.setNextTab():ze.setPreviousTab();o.currentTab=ze.getCurrentTab().getType(),e.tabnumber=0,Oe(),zf(),(a=document.activeElement)==null||a.blur();let n=Wf[o.currentTab].subTabList;for(let s=0;s{var c;let a=ze.getCurrentTab();a.getType()!==t&&(bn(a.getType()),a=ze.getCurrentTab());let s=a.getSubTabs();if(!a.isUnlocked()||s.subTabList.length===0)return;r!==void 0?e.subtabNumber=Pi(r,0,s.subTabList.length-1):e.subtabNumber=Pi(e.subtabNumber+n,0,s.subTabList.length-1);let l=s.subTabList[e.subtabNumber];for(;!l.unlocked;)Nn(r===void 0),e.subtabNumber=Pi(e.subtabNumber+n,0,s.subTabList.length-1),l=s.subTabList[e.subtabNumber];if(l.unlocked){for(let p of s.subTabList){if(!p.buttonID)continue;let g=i(p.buttonID);p===l?g.classList.add("active-subtab"):g.classList.remove("active-subtab")}(c=s.tabSwitcher)==null||c.call(s)(l.subTabID),a.getType()===9&&r===3&&(e.visitedAmbrosiaSubtab=!0,o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value)}};function gf(t){let r=ze.getCurrentTab();for(;r.getType()!==t;)r=ze.setNextTab();return r.getSubTabs().subTabList.length}var o={runediv:[1.5,2,3,5,8,1,1],runeexpbase:[1,4,9,16,1e3,1e75,1e256],runeMaxLvl:4e4,upgradeCosts:[0,6,7,8,10,12,20,25,30,35,45,55,75,110,150,200,250,500,750,1e3,1500,2,3,4,5,6,7,10,13,20,30,150,400,800,1600,3200,1e4,2e4,5e4,1e5,2e5,1,2,3,5,6,7,42,65,87,150,300,500,1e3,1500,2e3,3e3,6e3,12e3,25e3,75e3,0,1,2,2,3,5,6,10,15,22,30,37,45,52,60,1900,2500,3e3,7482,21397,3,6,9,12,15,20,30,6,8,8,10,13,60,1,2,4,8,16,25,40,12,16,20,30,50,500,1250,5e3,25e3,125e3,1500,7500,3e4,15e4,1e6,250,1e3,5e3,25e3,125e3,1e3,1e6,1e9,1e12,1e15],crystalUpgradesCost:[6,15,20,40,100,200,500,1e3],crystalUpgradeCostIncrement:[8,15,20,40,100,200,500,1e3],researchBaseCosts:[1e200,1,1,1,1,1,1,100,1e4,1e6,1e8,2,200,2e4,2e6,2e8,4e4,4e8,10,1e5,1e9,100,100,1e4,2e3,2e5,40,200,50,5e3,2e7,777,7777,5e4,5e5,5e6,2e3,2e6,2e9,1e5,1e9,1,1,5,25,125,2,5,320,1280,25e8,10,2e3,4e5,8e7,2e9,5,400,1e4,3e6,9e8,100,2500,100,2e3,2e5,1,20,3e3,4e5,5e7,10,40,160,1e3,1e4,4e9,7e9,1e10,12e9,15e9,1e12,1e13,3e12,2e13,2e13,2e14,6e14,2e15,6e15,2e16,1e16,2e16,2e17,4e17,1e18,1e13,1e14,1e15,7777e15,7777e17,1e16,3e16,1e17,3e17,1e20,1e18,3e18,1e19,3e19,1e20,1e20,2e20,4e20,8e20,1e21,2e21,4e21,8e21,2e22,4e22,32e20,2e23,4e23,1e21,7777e29,5e8,5e12,5e16,5e20,5e24,1e25,2e25,4e25,8e25,1e26,4e26,8e26,1e27,2e27,1e28,5e9,5e15,5e21,5e27,1e28,1e29,2e29,4e29,8e29,1e27,2e30,4e30,8e30,1e31,2e31,5e31,1e32,2e32,4e32,8e32,1e33,2e33,4e33,8e33,1e34,3e34,1e35,3e35,6e35,1e36,3e36,1e37,3e37,1e38,3e38,1e39,3e39,1e40,3e40,1e50,3e41,1e42,3e42,6e42,1e43,3e43,1e44,3e44,1e45,3e45,2e46,6e46,2e47,6e47,1e64,6e48,2e49,1e50,1e51,4e56],researchMaxLevels:[0,1,1,1,1,1,10,10,10,10,10,10,10,10,10,10,10,10,1,1,1,25,25,25,20,20,10,10,10,10,10,12,12,10,10,10,10,10,10,1,1,1,1,1,1,1,1,1,1,1,1,10,10,10,10,10,20,20,20,20,20,1,5,4,5,5,10,10,10,10,10,1,1,1,1,1,10,50,50,50,50,10,1,20,20,20,20,20,20,20,10,20,20,20,20,1,20,5,5,3,2,10,10,10,10,1,10,10,20,25,25,50,50,50,50,100,10,10,10,100,100,25,25,25,1,5,10,10,10,10,1,10,10,10,1,1,25,25,25,15,1,10,10,10,10,1,10,1,6,10,1,25,25,1,15,1,10,10,10,1,1,10,10,10,10,1,25,25,25,15,1,10,10,10,1,1,10,3,6,10,5,25,25,1,15,1,20,20,20,1,1,20,1,50,50,10,25,25,25,15,1e5],ticker:0,costDivisor:1,freeAccelerator:0,totalAccelerator:0,freeAcceleratorBoost:0,totalAcceleratorBoost:0,acceleratorPower:1.1,acceleratorEffect:new f(1),acceleratorEffectDisplay:new f(1),generatorPower:new f(1),freeMultiplier:0,totalMultiplier:0,multiplierPower:2,multiplierEffect:new f(1),challengeOneLog:3,freeMultiplierBoost:0,totalMultiplierBoost:0,globalCoinMultiplier:new f(1),totalCoinOwned:0,prestigeMultiplier:new f(1),buildingPower:1,reincarnationMultiplier:new f(1),coinOneMulti:new f(1),coinTwoMulti:new f(1),coinThreeMulti:new f(1),coinFourMulti:new f(1),coinFiveMulti:new f(1),globalCrystalMultiplier:new f(1),globalMythosMultiplier:new f(.01),grandmasterMultiplier:new f(1),atomsMultiplier:new f(1),mythosBuildingPower:1,challengeThreeMultiplier:new f(1),totalMythosOwned:0,prestigePointGain:new f(0),challengeFivePower:1/3,transcendPointGain:new f(0),reincarnationPointGain:new f(0),produceFirst:new f(0),produceSecond:new f(0),produceThird:new f(0),produceFourth:new f(0),produceFifth:new f(0),produceTotal:new f(0),produceFirstDiamonds:new f(0),produceSecondDiamonds:new f(0),produceThirdDiamonds:new f(0),produceFourthDiamonds:new f(0),produceFifthDiamonds:new f(0),produceDiamonds:new f(0),produceFirstMythos:new f(0),produceSecondMythos:new f(0),produceThirdMythos:new f(0),produceFourthMythos:new f(0),produceFifthMythos:new f(0),produceMythos:new f(0),produceFirstParticles:new f(0),produceSecondParticles:new f(0),produceThirdParticles:new f(0),produceFourthParticles:new f(0),produceFifthParticles:new f(0),produceParticles:new f(0),producePerSecond:new f(0),producePerSecondDiamonds:new f(0),producePerSecondMythos:new f(0),producePerSecondParticles:new f(0),uFourteenMulti:new f(1),uFifteenMulti:new f(1),tuSevenMulti:1,currentTab:0,researchfiller1:"Hover over the grid to get details about researches!",researchfiller2:"Level: ",ordinals:["first","second","third","fourth","fifth","sixth","seventh","eighth","ninth","tenth","eleventh","twelfth","thirteenth","fourteenth","fifteenth","sixteenth","seventeenth","eighteenth","nineteenth","twentieth"],cardinals:["one","two","three","four","five","six","seven","eight","nine","ten","eleven","twelve","thirteen","fourteen","fifteen","sixteen","seventeen","eighteen","nineteen","twenty","twentyone","twentytwo","twentythree","twentyfour","twentyfive","twentysix","twentyseven","twentyeight","twentynine","thirty","thirtyone","thirtytwo","thirtythree","thirtyfour"],challengeBaseRequirements:[10,20,60,100,200,125,500,7500,2e8,35e8],prestigeamount:1,taxdivisor:new f("1"),taxdivisorcheck:new f("1"),runemultiplierincrease:{one:1,two:1,three:1,four:1,five:1},mythosupgrade13:new f("1"),mythosupgrade14:new f("1"),mythosupgrade15:new f("1"),challengefocus:0,maxexponent:1e4,effectiveLevelMult:1,optimalOfferingTimer:600,optimalObtainiumTimer:3600,runeSum:0,globalAntMult:new f("1"),antMultiplier:new f("1"),antOneProduce:new f("1"),antTwoProduce:new f("1"),antThreeProduce:new f("1"),antFourProduce:new f("1"),antFiveProduce:new f("1"),antSixProduce:new f("1"),antSevenProduce:new f("1"),antEightProduce:new f("1"),antCostGrowth:[1e41,3,10,100,1e4,1e8,1e16,1e32],antUpgradeBaseCost:[100,100,1e3,1e3,1e5,1e6,1e8,1e11,1e15,1e20,1e40,1e100],antUpgradeCostIncreases:[10,10,10,10,100,100,100,100,1e3,1e3,1e3,1e100],bonusant1:0,bonusant2:0,bonusant3:0,bonusant4:0,bonusant5:0,bonusant6:0,bonusant7:0,bonusant8:0,bonusant9:0,bonusant10:0,bonusant11:0,bonusant12:0,rune1level:1,rune2level:1,rune3level:1,rune4level:1,rune5level:1,rune1Talisman:0,rune2Talisman:0,rune3Talisman:0,rune4Talisman:0,rune5Talisman:0,talisman1Effect:[null,0,0,0,0,0],talisman2Effect:[null,0,0,0,0,0],talisman3Effect:[null,0,0,0,0,0],talisman4Effect:[null,0,0,0,0,0],talisman5Effect:[null,0,0,0,0,0],talisman6Effect:[null,0,0,0,0,0],talisman7Effect:[null,0,0,0,0,0],talisman6Power:0,talisman7Quarks:0,runescreen:"runes",settingscreen:"settings",talismanResourceObtainiumCosts:[1e13,1e14,1e16,1e18,1e20,1e22,1e24],talismanResourceOfferingCosts:[100,1e4,1e5,1e6,1e7,1e8,1e9],talismanLevelCostMultiplier:[1,4,1e4,1e8,1e13,10,100],talismanPositiveModifier:[null,.75,1.5,2.25,3,3.75,4.5],talismanNegativeModifier:[null,0,0,0,0,0,0],commonTalismanEnhanceCost:[null,0,3e3,1e3,0,0,0,0],uncommonTalismanEnchanceCost:[null,0,1e4,3e3,1e3,0,0,0],rareTalismanEnchanceCost:[null,0,1e5,2e4,2e3,500,0,0],epicTalismanEnhanceCost:[null,0,2e6,2e5,2e4,2e3,1e3,0],legendaryTalismanEnchanceCost:[null,0,4e7,2e6,1e5,2e4,2500,200],mythicalTalismanEnchanceCost:[null,0,0,0,0,0,0,0],talismanRespec:1,obtainiumGain:0,mirrorTalismanStats:[null,1,1,1,1,1],antELO:0,effectiveELO:0,timeWarp:!1,blessingMultiplier:1,spiritMultiplier:1,runeBlessings:[0,0,0,0,0,0],runeSpirits:[0,0,0,0,0,0],effectiveRuneBlessingPower:[0,0,0,0,0,0],effectiveRuneSpiritPower:[0,0,0,0,0,0],blessingBaseCost:1e6,spiritBaseCost:1e20,triggerChallenge:0,prevReductionValue:-1,buildingSubTab:"coin",blessingbase:[null,1/500,1/5e3,1/2e3,1/750,1/200,1/1e4,1/5e3,1/10,1/1e4,1/1e3],blessingDRPower:[null,1/3,1/3,2/3,1/2,2/3,2,1/3,1/3,1/16,1/16],giftbase:[1/1e3,1/1e3,1/1e3,1/1e3,1/1e3,1/1e3,1/1e3,1/1e3,1/1e3,1/1e3],giftDRPower:[1/6,1/6,1/3,1/4,1/3,1,1/6,1/6,1/32,1/32],benedictionbase:[null,1/1e3,1/1e3,1/1e3,1/1e3,1/1e3,1/1e3,1/1e3,1/1e3,1/1e3,1/1e3],benedictionDRPower:[null,1/12,1/12,1/6,1/8,1/6,1/2,1/12,1/12,1/64,1/64],platonicCubeBase:[2/4e6,1.5/4e6,1/4e6,1/8e4,1/1e4,1/1e5,1/1e4,1/1e4],platonicDRPower:[1/5,1/5,1/5,1/5,1/16,1/16,1/4,1/8],cubeBonusMultiplier:[null,1,1,1,1,1,1,1,1,1,1],tesseractBonusMultiplier:[null,1,1,1,1,1,1,1,1,1,1],hypercubeBonusMultiplier:[null,1,1,1,1,1,1,1,1,1,1],platonicBonusMultiplier:[1,1,1,1,1,1,1,1],autoOfferingCounter:0,researchOrderByCost:[],viscosityPower:[1,.87,.8,.75,.7,.6,.54,.45,.39,.33,.3,.2,.1,.05,0,0,0],lazinessMultiplier:[1,1/3,1/10,1/40,1/200,1/1e5,1/1e7,1/1e10,1/1e13,1/1e16,1/1e20,1/1e25,1/1e35,1/1e50,1/1e65,1/1e80,1/1e100],hyperchallengedMultiplier:[1,1.2,1.5,1.7,3,5,8,13,21,34,55,100,400,1600,7777,18888,88888],illiteracyPower:[1,.8,.7,.6,.5,.3,.2,.15,.1,.06,.04,.02,.01,.005,0,0,0],deflationMultiplier:[1,.3,.1,.03,.01,1/1e6,1/1e8,1/1e10,1/1e12,1/1e15,1/1e18,1/1e25,1/1e35,1/1e50,1/1e77,0,0],extinctionMultiplier:[1,.92,.86,.8,.74,.65,.55,.5,.45,.4,.35,.3,.1,0,0,0,0],droughtMultiplier:[1,5,25,200,1e4,1e7,1e11,1e16,1e22,1e30,1e40,1e55,1e80,1e120,1e177,1e200,1e250],financialcollapsePower:[1,.9,.7,.6,.5,.37,.3,.23,.18,.15,.12,.09,.03,.01,.007,7e-4,7e-5],corruptionPointMultipliers:[1,3,4,5,6,7,7.75,8.5,9.25,10,10.75,11.5,12.25,13,16,20,25,33,35],ascendBuildingProduction:{first:new f("0"),second:new f("0"),third:new f("0"),fourth:new f("0"),fifth:new f("0")},freeUpgradeAccelerator:0,freeUpgradeMultiplier:0,acceleratorMultiplier:1,multiplierMultiplier:1,constUpgradeCosts:[null,1,13,17,237,316,4216,5623,74989,1e10,1e24],globalConstantMult:new f("1"),autoTalismanTimer:0,autoChallengeTimerIncrement:0,corruptionTrigger:1,challenge15Rewards:{cube1:1,ascensions:1,coinExponent:1,taxes:1,obtainium:1,offering:1,accelerator:1,multiplier:1,runeExp:1,runeBonus:1,cube2:1,transcendChallengeReduction:1,reincarnationChallengeReduction:1,antSpeed:1,bonusAntLevel:1,cube3:1,talismanBonus:1,globalSpeed:1,blessingBonus:1,constantBonus:1,cube4:1,spiritBonus:1,score:1,quarks:1,hepteractUnlocked:0,cube5:1,powder:1,exponent:1,freeOrbs:0,ascensionSpeed:1},autoResetTimers:{prestige:0,transcension:0,reincarnation:0,ascension:0},timeMultiplier:1,upgradeMultiplier:1,historyCountMax:20,isEvent:!1,shopEnhanceVision:!1,eventClicked:!1,ambrosiaTimer:0,TIME_PER_AMBROSIA:600,ambrosiaCurrStats:{ambrosiaAdditiveLuckMult:1,ambrosiaLuck:100,ambrosiaBlueberries:0,ambrosiaGenerationSpeed:1},currentSingChallenge:void 0},Xf=O({},o);var oC={antspecies1:"Inceptus Formicidae",antspecies2:"Fortunae Formicidae",antspecies3:"Tributum Formicidae",antspecies4:"Celeritas Formicidae",antspecies5:"Multa Formicidae",antspecies6:"Sacrificium Formicidae",antspecies7:"Hic Formicidae",antspecies8:"Experientia Formicidae",antspecies9:"Praemoenio Formicidae",antspecies10:"Scientia Formicidae",antspecies11:"Phylacterium Formicidae",antspecies12:"Mortuus Est Formicidae"},ju=()=>e.currentChallenge.ascension!==15?1e5+Nt(499e5,(e.antUpgrades[1]+o.bonusant2)/5e3*500/499):1e-4*(1e5+Nt(499e5,(e.antUpgrades[1]+o.bonusant2)/5e3*500/499)),iC=[()=>d(f.pow(1.12+1/1e3*e.researches[101],e.antUpgrades[1-1]+o.bonusant1),2),()=>d(ju()),()=>d(.005+.995*Math.pow(.99,e.antUpgrades[3-1]+o.bonusant3),4),()=>d(100*(Nt(20,(e.antUpgrades[4-1]+o.bonusant4)/1e3*20/19)-1),3),()=>d(100*(Nt(40,(e.antUpgrades[5-1]+o.bonusant5)/1e3*40/39)-1),3),()=>d(1+Math.pow(e.antUpgrades[6-1]+o.bonusant6,.66),4),()=>d(Math.min(9999999,3*e.antUpgrades[7-1]+3*o.bonusant7),0,!0),()=>d(Nt(999,1/1e4*Math.pow(e.antUpgrades[8-1]+o.bonusant8,1.1)),3),()=>d(1*Math.min(1e7,e.antUpgrades[9-1]+o.bonusant9),0,!0),()=>d(1+2*Math.pow((e.antUpgrades[10-1]+o.bonusant10)/50,.75),4),()=>d(1+2*(1-Math.pow(2,-(e.antUpgrades[11-1]+o.bonusant11)/125)),4),()=>d(ut(2,e.antUpgrades[12-1]+o.bonusant12,69),4)],Zf,Yf=t=>{Ba(Zf),Zf=It(()=>Vu(t),50)},Vu=t=>{if(o.currentTab!==6)return;let r=i("anttierdescription"),n=i("antprice"),a=i("antquantity"),s=i("generateant"),l="ants.costGalacticCrumbs",c="first",p;switch(r.textContent=u.t(`ants.descriptions.${t}`),t){case 1:l="ants.costParticles",c="first",p=d(o.antOneProduce,5);break;case 2:c="second",p=d(o.antTwoProduce,5);break;case 3:c="third",p=d(o.antThreeProduce,5);break;case 4:c="fourth",p=d(o.antFourProduce,5);break;case 5:c="fifth",p=d(o.antFiveProduce,5);break;case 6:c="sixth",p=d(o.antSixProduce,5);break;case 7:c="seventh",p=d(o.antSevenProduce,5);break;case 8:c="eighth",p=d(o.antEightProduce,5);break}s.textContent=u.t(`ants.generates.${t}`,{x:p}),n.textContent=u.t(l,{x:d(e[`${c}CostAnts`])}),a.textContent=u.t("ants.owned",{x:d(e[`${c}OwnedAnts`]),y:d(e[`${c}GeneratedAnts`],2)})},Qo=(t,r,n)=>(--r,t.times(f.pow(o.antCostGrowth[n-1],r)).add(1*r)),Rs=(t,r,n)=>(--r,t.times(f.pow(o.antUpgradeCostIncreases[n-1],r))),Wu=(t,r,n)=>{let a=Xn(e.antSacrificePoints);r=new f(r);let s=n===1?"reincarnationPoints":"antPoints",l=`${t}OwnedAnts`,c=e[l]+Ce(e[l]),p=c,g=Qo(r,p,n);for(;e[s].gte(g);)p=p*4,g=Qo(r,p,n);let m=Math.floor(p/8);for(;m>=Ce(p);)Qo(r,p-m,n).lte(e[s])?m=Math.floor(m/2):p=p-Math.max(Ce(p),m);e.antMax||cC[v]&&e[`${o.ordinals[v+1]}OwnedAnts`]>0&&R(176+v);e.firstOwnedAnts>69e6&&(e.firstOwnedAnts=69e6)},Ku=(t,r,n)=>{if(e.currentChallenge.ascension!==11){t=new f(t);let a=e.antUpgrades[n-1]+Ce(e.antUpgrades[n-1]),s=a,l=Rs(t,s,n);for(;e.antPoints.gte(l);)s=s*4,l=Rs(t,s,n);let c=Math.floor(s/8);for(;c>=Ce(s);)Rs(t,s-c,n).lte(e.antPoints)?c=Math.floor(c/2):s=s-Math.max(Ce(s),c);e.antMax||a{let r=i("antspecies"),n=i("antlevelbonus"),a=i("antupgradedescription"),s=i("antupgradecost"),l=i("antupgradeeffect"),c=oC[`antspecies${t}`],p=u.t(`ants.upgrades.${t}`),g=o[`bonusant${t}`],m=e.currentChallenge.ascension===11?999:0;r.childNodes[0].textContent=`${c} Level ${d(e.antUpgrades[t-1])}`,n.textContent=` [+${d(Math.min(e.antUpgrades[t-1]+m,g))}]`,a.textContent=p,s.textContent=u.t("ants.costGalacticCrumbs",{x:d(f.pow(o.antUpgradeCostIncreases[t-1],e.antUpgrades[t-1]*o.extinctionMultiplier[e.usedCorruptions[10]]).times(o.antUpgradeBaseCost[t-1]))}),l.textContent=u.t(`ants.rewards.${t}`,{x:iC[t-1]()})},Xn=t=>{let r=Math.pow(1+t/5e3,2);return r*=1+.2*Math.log(1+t)/Math.log(10),e.achievements[174]>0&&(r*=1+.4*Math.log(1+t)/Math.log(10)),Math.min(1e300,r)},Gm=()=>{let t=Xu();i("antSacrificeSummary").style.display="block",i("ELO").innerHTML=u.t("ants.yourAntELO",{x:d(o.antELO,2),y:d(o.effectiveELO,2,!1)}),i("SacrificeMultiplier").innerHTML=u.t("ants.antSacMultiplier",{y:d(Xn(e.antSacrificePoints),3,!1),x:d(Xn(e.antSacrificePoints+t.antSacrificePoints),3,!1)}),i("SacrificeUpgradeMultiplier").innerHTML=u.t("ants.upgradeMultiplier",{x:d(o.upgradeMultiplier,3,!0)}),i("SacrificeTimeMultiplier").innerHTML=u.t("ants.timeMultiplier",{x:d(o.timeMultiplier,3,!0)}),i("antSacrificeOffering").textContent=`+${d(t.offerings)}`,i("antSacrificeObtainium").textContent=`+${d(t.obtainium)}`,e.challengecompletions[9]>0&&(i("antSacrificeTalismanShard").textContent=u.t("ants.elo",{x:d(t.talismanShards),y:500}),i("antSacrificeCommonFragment").textContent=u.t("ants.elo",{x:d(t.commonFragments),y:750}),i("antSacrificeUncommonFragment").textContent=u.t("ants.elo",{x:d(t.uncommonFragments),y:1e3}),i("antSacrificeRareFragment").textContent=u.t("ants.elo",{x:d(t.rareFragments),y:1500}),i("antSacrificeEpicFragment").textContent=u.t("ants.elo",{x:d(t.epicFragments),y:2e3}),i("antSacrificeLegendaryFragment").textContent=u.t("ants.elo",{x:d(t.legendaryFragments),y:3e3}),i("antSacrificeMythicalFragment").textContent=u.t("ants.elo",{x:d(t.mythicalFragments),y:5e3}))},As=async(t=!1)=>{let r=!0;if(e.antPoints.gte("1e40")&&(!t&&e.toggles[32]&&(r=await we(u.t("ants.autoReset"))),r)){let n=e.antSacrificePoints,a=Xu();e.antSacrificePoints+=a.antSacrificePoints,e.runeshards+=a.offerings,e.currentChallenge.ascension!==14&&(e.researchPoints+=a.obtainium);let s={date:Date.now(),seconds:e.antSacrificeTimer,kind:"antsacrifice",offerings:a.offerings,obtainium:a.obtainium,antSacrificePointsBefore:n,antSacrificePointsAfter:e.antSacrificePoints,baseELO:o.antELO,effectiveELO:o.effectiveELO,crumbs:e.antPoints.toString(),crumbsPerSecond:o.antOneProduce.toString()};if(e.challengecompletions[9]>0&&(e.talismanShards=Math.min(1e300,e.talismanShards+a.talismanShards),e.commonFragments=Math.min(1e300,e.commonFragments+a.commonFragments),e.uncommonFragments=Math.min(1e300,e.uncommonFragments+a.uncommonFragments),e.rareFragments=Math.min(1e300,e.rareFragments+a.rareFragments),e.epicFragments=Math.min(1e300,e.epicFragments+a.epicFragments),e.legendaryFragments=Math.min(1e300,e.legendaryFragments+a.legendaryFragments),e.mythicalFragments=Math.min(1e300,e.mythicalFragments+a.mythicalFragments)),Lu(),e.antSacrificeTimer=0,e.antSacrificeTimerReal=0,Kt(),e.autoResearch>0&&e.autoResearchToggle){let l=e.autoResearch===200?.01:0;Fr(e.autoResearch,!0,l)}Kn(),yt.emit("historyAdd","ants",s)}e.mythicalFragments>=1e11&&e.currentChallenge.ascension===14&&e.achievements[248]<1&&R(248)},Jf=()=>{let t=(l,c)=>e.antPoints.gte(Rs(new f(o.antUpgradeBaseCost[l-1]),e.antUpgrades[l-1]+1,l).times(c)),r=[176,176,177,178,178,179,180,180,181,182,182,145],n=["100","100","1000","1000","1e5","1e6","1e8","1e11","1e15","1e20","1e40","1e100"];if(e.currentChallenge.ascension!==11)for(let l=1;l<=r.length;l++)(l===12?e.researches[r[l-1]]:e.achievements[r[l-1]])&&t(l,2)&&Ku(n[l-1],!0,l);let a=[173,176,177,178,179,180,181,182],s=["1e700","3","100","10000","1e12","1e36","1e100","1e300"];for(let l=1;l<=a.length;l++){let c=l===1?e.reincarnationPoints:e.antPoints,p=l===1?1:2;e.achievements[a[l-1]]&&c.gte(e[`${o.ordinals[l-1]}CostAnts`].times(p))&&Wu(o.ordinals[l-1],s[l-1],l)}};function e0(t){var r;for(let n=0;n<227;n++)r=t[n]&2147483648|t[n+1]&2147483647,t[n]=t[n+397]^r>>>1^(r&1)*2567483615;for(let n=227;n<623;n++)r=t[n]&2147483648|t[n+1]&2147483647,t[n]=t[n-227]^r>>>1^(r&1)*2567483615;return r=t[623]&2147483648|t[0]&2147483647,t[623]=t[396]^r>>>1^(r&1)*2567483615,t}function lC(t){for(var r=t0(19650218),n=t.length,a=1,s=0,l=624>n?624:n;l;l--){let c=r[a-1]^r[a-1]>>>30;r[a]=(r[a]^(((c&4294901760)>>>16)*1664525<<16)+(c&65535)*1664525)+t[s]+s,a++,s++,a>=624&&(r[0]=r[623],a=1),s>=n&&(s=0)}for(l=623;l;l--){let c=r[a-1]^r[a-1]>>>30;r[a]=(r[a]^(((c&4294901760)>>>16)*1566083941<<16)+(c&65535)*1566083941)-a,a++,a>=624&&(r[0]=r[623],a=1)}return r[0]=2147483648,r}function t0(t){var r=new Array(624);r[0]=t;for(let n=1;n<624;n++){let a=r[n-1]^r[n-1]>>>30;r[n]=(((a&4294901760)>>>16)*1812433253<<16)+(a&65535)*1812433253+n}return r}function cC(t=Date.now()){var r;return Array.isArray(t)?r=lC(t):r=t0(t),e0(r)}function r0(t){var r=cC(t),n=0,a=()=>{let l;return n>=624&&(r=e0(r),n=0),l=r[n++],l^=l>>>11,l^=l<<7&2636928640,l^=l<<15&4022730752,l^=l>>>18,l>>>0},s={genrand_int32:()=>a(),genrand_int31:()=>a()>>>1,genrand_real1:()=>a()*(1/4294967295),genrand_real2:()=>a()*(1/4294967296),genrand_real3:()=>(a()+.5)*(1/4294967296),genrand_res53:()=>{let l=a()>>>5,c=a()>>>6;return(l*67108864+c)*(1/9007199254740992)},randomNumber:()=>a(),random31Bit:()=>s.genrand_int31(),randomInclusive:()=>s.genrand_real1(),random:()=>s.genrand_real2(),randomExclusive:()=>s.genrand_real3(),random53Bit:()=>s.genrand_res53()};return s}var ja=t=>r0(e.seed[t]++).random(),Zu=(t,r,n)=>Math.floor(ja(t)*(n-r+1)+r),Zn={PromoCodes:0,Ambrosia:1};var Ie=(t,r=0)=>{let n=t==="ascension"||t==="quarks"||t==="goldenQuarks"||t==="singularity"||t==="octeracts"||t==="autoPotion"||t==="ambrosia"?1:qe().mult;switch(t){case"prestige":{e.prestigecounter+=r*n;break}case"transcension":{e.transcendcounter+=r*n;break}case"reincarnation":{e.reincarnationcounter+=r*n;break}case"ascension":{let a=e.singularityUpgrades.oneMind.getEffect().bonus?10:Ur();e.ascensionCounter+=r*n*a,e.ascensionCounterReal+=r*n;break}case"singularity":{e.ascensionCounterRealReal+=r,e.singularityCounter+=r*n,e.insideSingularityChallenge?e.singChallengeTimer+=r*n:e.singChallengeTimer=0;break}case"quarks":{let a=Ut().maxTime;e.quarkstimer+=r*n,e.quarkstimer=e.quarkstimer>a?a:e.quarkstimer;break}case"goldenQuarks":{if(+e.singularityUpgrades.goldenQuarks3.getEffect().bonus==0)return;e.goldenQuarksTimer+=r*n,e.goldenQuarksTimer=e.goldenQuarksTimer>3600*168?3600*168:e.goldenQuarksTimer;break}case"octeracts":{if(e.singularityUpgrades.octeractUnlock.getEffect().bonus)e.octeractTimer+=r*n;else return;if(e.octeractTimer>=1){let a=e.octeractTimer-e.octeractTimer%1;e.octeractTimer%=1;let s=Kr();if(e.wowOcteracts+=a*s,e.totalWowOcteracts+=a*s,e.highestSingularityCount>=160){let l=[160,173,185,194,204,210,219,229,240,249],c=1e-6,p=0;for(let g of l)e.highestSingularityCount>=g&&(p+=1);for(let g=0;g0,s=e.toggles[43]&&e.shopUpgrades.obtainiumPotion>0;e.autoPotionTimer+=r*n,e.autoPotionTimerObtainium+=r*n;let l=180*Math.pow(1.03,-e.highestSingularityCount)/+e.octeractUpgrades.octeractAutoPotionSpeed.getEffect().bonus,c=a?Math.min(1,l)/20:l,p=s?Math.min(1,l)/20:l;if(e.autoPotionTimer>=c){let g=(e.autoPotionTimer-e.autoPotionTimer%c)/c;e.autoPotionTimer%=c,gn("offeringPotion",!0,g,a)}if(e.autoPotionTimerObtainium>=p){let g=(e.autoPotionTimerObtainium-e.autoPotionTimerObtainium%p)/p;e.autoPotionTimerObtainium%=p,gn("obtainiumPotion",!0,g,s)}}break}case"ambrosia":{if(o.ambrosiaCurrStats.ambrosiaGenerationSpeed===0||(o.ambrosiaTimer+=r*n,o.ambrosiaTimer<.125))break;let s=o.ambrosiaCurrStats.ambrosiaLuck,l=o.ambrosiaCurrStats.ambrosiaGenerationSpeed;e.blueberryTime+=Math.floor(8*o.ambrosiaTimer)/8*l,e.ultimateProgress+=Math.floor(8*o.ambrosiaTimer)/8*Math.min(l,Math.pow(1e3*l,1/2)),o.ambrosiaTimer%=.125;let c=Cs(),p=1/2+(3/5-1/2)*+(e.singularityChallenges.noAmbrosiaUpgrades.completions>=15)+(2/3-3/5)*+(e.singularityChallenges.noAmbrosiaUpgrades.completions>=19)+(3/4-2/3)*+(e.singularityChallenges.noAmbrosiaUpgrades.completions>=20);for(;e.blueberryTime>=c;){let g=ja(Zn.Ambrosia),m=Math.floor(s/100),h=g1e6&&(e.ultimatePixels+=Math.floor(e.ultimateProgress/1e6),e.cubeUpgrades[79]>0&&(e.cubeUpgradeRedBarFilled+=Math.floor(e.ultimateProgress/1e6)),e.ultimateProgress-=1e6*Math.floor(e.ultimateProgress/1e6)),vs()}}},Or=(t,r)=>{let n=t==="runeSacrifice"||t==="addOfferings"?1:qe().mult;switch(t){case"addObtainium":{if(e.currentChallenge.ascension===14)break;Ar();let a=ko();e.researchPoints=Math.min(1e300,e.researchPoints+a*r*n),o.currentTab===5&&cl();break}case"addOfferings":o.autoOfferingCounter+=r,e.runeshards=Math.min(1e300,e.runeshards+Math.floor(o.autoOfferingCounter)),o.autoOfferingCounter%=1;break;case"runeSacrifice":if(e.sacrificeTimer+=r,e.sacrificeTimer>=1&&isFinite(e.runeshards)&&e.runeshards>0){if(e.highestSingularityCount>=15){let a=4;e.toggles[36]&&(Ps("Blessings",100/a,!0),a--),e.toggles[37]&&(Ps("Spirits",100/a,!0),a--)}if(e.autoBuyFragment&&e.highestSingularityCount>=40&&e.cubeUpgrades[51]>0&&qi(),e.cubeUpgrades[20]===1){let a=e.highestSingularityCount>=50?7:e.highestSingularityCount>=30?6:5,s=a-Hg(a);if(s>0){let l=Math.floor(e.runeshards/s/2);for(let c=0;c=rt(c+1)||fa(c+1,!0,l)}}else{let a=e.autoSacrifice;fa(a,!0,0)}e.sacrificeTimer%=1}break;case"antSacrifice":{e.antSacrificeTimer+=r*n,e.antSacrificeTimerReal+=r,(e.autoAntSacrificeMode===2?e.antSacrificeTimerReal:e.antSacrificeTimer)>=e.autoAntSacTimer&&e.antSacrificeTimerReal>.1&&e.researches[124]===1&&e.autoAntSacrifice&&e.antPoints.gte("1e40")&&As(!0);break}}};var uC=new Intl.DateTimeFormat("EN-GB",{year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",hour12:!1,minute:"2-digit",second:"2-digit"}),dC=new Intl.DateTimeFormat("EN-GB",{year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",hour12:!0,minute:"2-digit",second:"2-digit"}),pC=36e5,Je=(t="default",r=!1)=>{let a=(r?dC:uC).formatToParts(new Date).filter(p=>p.type!=="literal").map(p=>({[p.type]:p.value})),s=Object.assign({},...a),l=r?` ${s.dayPeriod.toUpperCase()}`:"",c=["sun","mon","tue","wed","thu","fri","sat"];switch(t){case"default":return`${s.year}-${s.month}-${s.day} ${s.hour}_${s.minute}_${s.second}${l}`;case"short":return`${s.year}${s.month}${s.day}${s.hour}${s.minute}${s.second}`;case"year":return`${s.year}`;case"month":return`${s.month}`;case"day":return`${s.day}`;case"hour":return`${s.hour}`;case"minute":return`${s.minute}`;case"second":return`${s.second}`;case"period":return`${s.dayPeriod.toUpperCase()}`;case"weekday":return`${c[new Date().getUTCDay()]}`;default:return t}},s0=t=>{let r=t.value.slice(0,100);e.saveString=r===""?M.saveString:Zs(r),i("saveStringInput").value=e.saveString},gC=()=>{var t,r;return(r=(t=/[\d?=.]+/.exec(Jt))==null?void 0:t[0])!=null?r:Jt},qo=()=>{let r=e.saveString.replace(/\$(.*?)\$/g,(n,a)=>{switch(a){case"VERSION":return`v${Jt}`;case"TIME":return Je();case"TIME12":return Je(void 0,!0);case"SING":return`Singularity ${e.singularityCount}`;case"SINGS":return`${e.singularityCount}`;case"VER":return gC();case"TIMES":return Je("short");case"YEAR":return Je("year");case"Y":return Je("year");case"MONTH":return Je("month");case"M":return Je("month");case"DAY":return Je("day");case"D":return Je("day");case"HOUR":return Je("hour");case"H":return Je("hour");case"H12":return Je("hour",!0);case"MINUTE":return Je("minute");case"MI":return Je("minute");case"SECOND":return Je("second");case"S":return Je("second");case"PERIOD":return Je("period",!0);case"P":return Je("period",!0);case"WEEKDAY":return Je("weekday");case"W":return Je("weekday");case"DATE":return`${Date.now()}`;case"DATES":return`${Math.floor(Date.now()/1e3)}`;case"QUARK":return`${Math.floor(Number(e.worlds))}`;case"QUARKS":return d(Number(e.worlds));case"GQ":return`${Math.floor(e.goldenQuarks)}`;case"GQS":return d(e.goldenQuarks);case"STAGE":return mu(0);default:return`${a}`}});return Zs(r)},Yu=async(t,r)=>{if(an("saveType").checked)try{await navigator.clipboard.writeText(t),i("exportinfo").textContent=u.t("importexport.copiedSave")}catch(a){let s=document.createElement("textarea");s.setAttribute("style","top: 0; left: 0; position: fixed;"),s.setAttribute("data-clipboard-text",t),document.body.appendChild(s),s.focus(),s.select();let l=new n0.default(s),c=()=>{l.destroy(),document.body.removeChild(s)};l.on("success",()=>{i("exportinfo").textContent=u.t("importexport.copiedSave"),c()}),l.on("error",()=>{i("exportinfo").textContent=u.t("importexport.exportFailed"),P(u.t("importexport.unableCopySave")).finally(c)})}else{let a=document.createElement("a");a.setAttribute("href",`data:text/plain;charset=utf-8,${t}`),a.setAttribute("download",r),a.setAttribute("id","downloadSave"),document.body.appendChild(a),a.click(),document.body.removeChild(a),i("exportinfo").textContent=u.t("importexport.copiedFile")}setTimeout(()=>i("exportinfo").textContent="",15e3)},o0=async(t=!0)=>{if(e.offlinetick=Date.now(),t){e.lastExportedSave=Date.now();let n=Ut(),a=1;a*=1+er()/100,a*=e.highestSingularityCount>=100?1+e.highestSingularityCount/50:1,+e.singularityUpgrades.goldenQuarks3.getEffect().bonus>0&&(e.goldenQuarks+=Math.floor(e.goldenQuarksTimer/(3600/+e.singularityUpgrades.goldenQuarks3.getEffect().bonus))*a,e.goldenQuarksTimer=e.goldenQuarksTimer%(3600/+e.singularityUpgrades.goldenQuarks3.getEffect().bonus)),n.gain>=1&&(e.worlds.add(n.gain),e.quarkstimer=e.quarkstimer%(3600/n.perHour))}if(!hr())return;let r=localStorage.getItem("Synergysave2");if(!r)return P("How?");await Yu(r,qo()),setTimeout(()=>i("exportinfo").textContent="",15e3)},i0=async()=>{await P(u.t("importexport.reloadDeletePrompt")),await Ju(!0)},Ju=async(t=!0)=>{if(!t){let n=window.crypto.getRandomValues(new Uint16Array(1))[0]%16,a=window.crypto.getRandomValues(new Uint16Array(1))[0]%16,s=await Ee(u.t("importexport.resetPrompt",{a:n,b:a,sum:n+a}));if(s===null||Number(s)!==n+a)return P(u.t("importexport.wrongAnswer"))}let r=fs.safeParse(M);bn(0),ve(0,{page:0}),ve(3,{page:0}),ve(4,{page:0}),ve(7,{page:0}),ve(8,{page:0}),ve(9,{page:0}),ve(10,{page:0}),Ra(rs(JSON.stringify(r.data)),!0)},ed=async(t,r)=>{let n=t.target,a=n.files[0],s="";if(typeof Blob.prototype.text=="function")s=await a.text();else{let l=new FileReader;l.readAsText(a),s=await new Promise(p=>{l.addEventListener("load",()=>p(l.result.toString()))})}return n.value="",bC(a.lastModified),r(s)},Ra=(t,r=!1)=>{if(typeof t!="string")return P(u.t("importexport.unableImport"));let n=a0.default.decompressFromBase64(t),a=JSON.parse(n||atob(t));if(a.exporttest==="YES!"||a.exporttest===!0||a.exporttest===!1&&!1||a.exporttest==="NO!"&&!1){let s=rs(JSON.stringify(a));if(s===null)return P(u.t("importexport.unableImport"));localStorage.setItem("Synergysave2",s),td(r);return}else return P(u.t("importexport.loadTestInLive"))},jo=t=>{let r=i("promocodeinfo"),n=`'${t}': `,a=0;switch(t){case"daily":e.dailyCodeUsed?n+=u.t("importexport.daily0Uses"):n+=u.t("importexport.daily1Uses");break;case"add":a=qn(),a===0?n+=u.t("importexport.add0Uses",{x:0,y:d(ll(),0)}):a!==1?n+=u.t("importexport.addUses",{x:a}):n+=u.t("importexport.add1Uses",{x:a});break;case"time":a=c0(),a===0?n+=u.t("importexport.add0Uses",{x:0,y:d(mC(),0)}):n+=u.t("importexport.timeMultiplier",{x:a,y:d(u0(),2,!0)});break;default:n=""}r.textContent=n},l0=async()=>{let t=await Ee(u.t("importexport.promocodePrompt"));xn(t)},xn=async(t,r)=>{let n=i("promocodeinfo");if(t===null)return P(u.t("importexport.comeBackSoon"));if(t==="23andme"&&!e.codes.get(48)&&o.isEvent)return e.dailyCodeUsed?(e.codes.set(48,!0),e.quarkstimer=Ut().maxTime,e.goldenQuarksTimer=3600*24,Ie("ascension",8*3600),e.dailyCodeUsed=!1,(e.challenge15Exponent>=1e15||e.highestSingularityCount>0)&&(e.hepteractCrafts.quark.CAP*=2,e.hepteractCrafts.quark.BAL+=Math.min(1e13,e.hepteractCrafts.quark.CAP/2)),e.highestSingularityCount>0&&(e.singularityUpgrades.goldenQuarks1.freeLevels+=1+Math.floor(e.highestSingularityCount/10),e.singularityUpgrades.goldenQuarks2.freeLevels+=1+Math.floor(e.highestSingularityCount/10),e.singularityUpgrades.goldenQuarks3.freeLevels+=1+Math.floor(e.highestSingularityCount/10),e.singularityUpgrades.octeractUnlock.getEffect().bonus&&(e.octeractUpgrades.octeractImprovedQuarkHept.freeLevels+=.05)),P(`Not sponsored by the company! Your Quark timer(s) have been replenished and you have been given 8 real life hours of Ascension progress! Your daily code has also been reset for you. + `}getSubs(){return ee(this,Re)}appendButton(...n){for(let a of n)ee(this,Re).push(a),this.appendChild(a);St(this,Jt,ee(this,Re)[0]),ci(this,_l,o0).call(this)}getCurrentTab(){return ee(this,Jt)}setNextTab(){var a;let n=ee(this,Re).indexOf(ee(this,Jt));return St(this,Jt,(a=ee(this,Re)[n+1])!=null?a:ee(this,Re)[0]),ee(this,Jt)}setPreviousTab(){var a;let n=ee(this,Re).indexOf(ee(this,Jt));return St(this,Jt,(a=ee(this,Re)[n-1])!=null?a:ee(this,Re)[ee(this,Re).length-1]),ee(this,Jt)}getNextTab(n=ee(this,Jt)){var s;let a=ee(this,Re).indexOf(n);return(s=ee(this,Re)[a+1])!=null?s:ee(this,Re)[0]}getPreviousTab(n=ee(this,Jt)){var s;let a=ee(this,Re).indexOf(n);return(s=ee(this,Re)[a-1])!=null?s:ee(this,Re)[ee(this,Re).length-1]}reappend(){this.replaceChildren();for(let n of ee(this,Re))this.appendChild(n);ee(this,Re).forEach(n=>n.resetHidden())}};Re=new WeakMap,Jt=new WeakMap,_l=new WeakSet,o0=function(){let n=null,a=g=>{Hn(g.target instanceof HTMLElement),g.target.style.opacity="0.4",n=g.target,g.dataTransfer.effectAllowed="move"},s=g=>{g.target instanceof HTMLElement&&g.target.classList.add("over")},l=g=>{g.target instanceof HTMLElement&&g.target.classList.remove("over")},c=g=>{if(g.stopPropagation(),n!==g.target&&n!==null){this.insertBefore(n,g.target);let m=ee(this,Re).indexOf(n),h=ee(this,Re).indexOf(g.target);ee(this,Re).splice(h,0,ee(this,Re)[m]),ee(this,Re).splice(ee(this,Re).indexOf(n,m),1)}return!1},p=g=>{Hn(g.target instanceof HTMLElement),g.target.style.opacity="1",ee(this,Re).forEach(m=>{m.classList.remove("over")})};ee(this,Re).forEach(g=>{g.addEventListener("dragstart",a,!1),g.addEventListener("dragenter",s,!1),g.addEventListener("dragover",c,!1),g.addEventListener("dragleave",l,!1),g.addEventListener("drop",c,!1),g.addEventListener("dragend",p,!1)})};var Wo,ta,Ko,$s,mt=class extends HTMLButtonElement{constructor(n){super();Tt(this,Wo,()=>!0);Tt(this,ta,void 0);Tt(this,Ko,!1);Tt(this,$s,!1);this.id=n.id,n.class&&this.classList.add(n.class),n.i18n&&this.setAttribute("i18n",n.i18n),n.borderColor&&(this.style.borderColor=n.borderColor),this.addEventListener("click",()=>{ee(this,Ko)&&Go.has("ControlLeft")&&Go.has("KeyX")?o.currentTab!==ee(this,ta)&&(ze.removeChild(this),St(this,$s,!0)):(bn(ee(this,ta)),Dl())})}setUnlockedState(n){return St(this,Wo,n),this}isUnlocked(){return ee(this,Wo).call(this)&&!ee(this,$s)}setType(n){return St(this,ta,n),this}getType(){return ee(this,ta)}getSubTabs(){return s0[ee(this,ta)]}makeDraggable(){return this.setAttribute("draggable","true"),this}makeRemoveable(){return St(this,Ko,!0),this}resetHidden(){St(this,$s,!1)}};Wo=new WeakMap,ta=new WeakMap,Ko=new WeakMap,$s=new WeakMap;customElements.define("tab-row",$l,{extends:"div"});customElements.define("sub-tab",mt,{extends:"button"});var ze=new $l,a0;(a0=document.getElementsByClassName("navbar").item(0))==null||a0.appendChild(ze);ze.appendButton(new mt({id:"buildingstab",i18n:"tabs.main.buildings"}).setType(0).makeDraggable().makeRemoveable(),new mt({id:"upgradestab",i18n:"tabs.main.upgrades"}).setType(1).makeDraggable().makeRemoveable(),new mt({id:"achievementstab",i18n:"tabs.main.achievements",class:"coinunlock4"}).setUnlockedState(()=>e.unlocks.coinfour).setType(2).makeDraggable().makeRemoveable(),new mt({class:"prestigeunlock",id:"runestab",i18n:"tabs.main.runes"}).setUnlockedState(()=>e.unlocks.prestige).setType(3).makeDraggable().makeRemoveable(),new mt({class:"transcendunlock",id:"challengetab",i18n:"tabs.main.challenges"}).setUnlockedState(()=>e.unlocks.transcend).setType(4).makeDraggable().makeRemoveable(),new mt({class:"reincarnationunlock",id:"researchtab",i18n:"tabs.main.research"}).setUnlockedState(()=>e.unlocks.reincarnate).setType(5).makeDraggable().makeRemoveable(),new mt({class:"chal8",id:"anttab",i18n:"tabs.main.antHill"}).setUnlockedState(()=>e.achievements[127]>0).setType(6).makeDraggable().makeRemoveable(),new mt({class:"chal10",id:"cubetab",i18n:"tabs.main.wowCubes"}).setUnlockedState(()=>e.achievements[141]>0).setType(7).makeDraggable().makeRemoveable(),new mt({class:"chal11",id:"traitstab",i18n:"tabs.main.corruption"}).setUnlockedState(()=>e.challengecompletions[11]>0).setType(8).makeDraggable().makeRemoveable(),new mt({class:"singularity",id:"singularitytab",i18n:"tabs.main.singularity"}).setUnlockedState(()=>e.highestSingularityCount>0).setType(9).makeDraggable().makeRemoveable(),new mt({id:"settingstab",i18n:"tabs.main.settings"}).setType(10).makeDraggable(),new mt({class:"reincarnationunlock",id:"shoptab",i18n:"tabs.main.shop"}).setUnlockedState(()=>e.unlocks.reincarnate||e.highestSingularityCount>0).setType(11).makeDraggable().makeRemoveable(),new mt({class:"isEvent",id:"eventtab",i18n:"tabs.main.unsmith"}).setUnlockedState(()=>o.isEvent).setType(12).makeDraggable().makeRemoveable(),new mt({id:"pseudoCoinstab",i18n:"tabs.main.purchase"}).setType(13).makeDraggable());var _o=(t=1,r=!1)=>{let n=t===1?ze.getNextTab():ze.getPreviousTab();for(;!(n!=null&&n.isUnlocked());)n=t===1?ze.getNextTab(n):ze.getPreviousTab(n);r?Ce(n.getType(),{step:t}):bn(n.getType(),t)},bn=(t,r)=>{var a;if(r===1)ze.setNextTab();else if(r===-1)ze.setPreviousTab();else for(;ze.getCurrentTab().getType()!==t;)ze.setNextTab();for(;!ze.getCurrentTab().isUnlocked();)r===1||r===void 0?ze.setNextTab():ze.setPreviousTab();o.currentTab=ze.getCurrentTab().getType(),e.tabnumber=0,Oe(),i0(),(a=document.activeElement)==null||a.blur();let n=s0[o.currentTab].subTabList;for(let s=0;s{var c;let a=ze.getCurrentTab();a.getType()!==t&&(bn(a.getType()),a=ze.getCurrentTab());let s=a.getSubTabs();if(!a.isUnlocked()||s.subTabList.length===0)return;r!==void 0?e.subtabNumber=Ri(r,0,s.subTabList.length-1):e.subtabNumber=Ri(e.subtabNumber+n,0,s.subTabList.length-1);let l=s.subTabList[e.subtabNumber];for(;!l.unlocked;)Hn(r===void 0),e.subtabNumber=Ri(e.subtabNumber+n,0,s.subTabList.length-1),l=s.subTabList[e.subtabNumber];if(l.unlocked){for(let p of s.subTabList){if(!p.buttonID)continue;let g=i(p.buttonID);p===l?g.classList.add("active-subtab"):g.classList.remove("active-subtab")}(c=s.tabSwitcher)==null||c.call(s)(l.subTabID),a.getType()===9&&r===3&&(e.visitedAmbrosiaSubtab=!0,o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value)}};function wf(t){let r=ze.getCurrentTab();for(;r.getType()!==t;)r=ze.setNextTab();return r.getSubTabs().subTabList.length}var o={runediv:[1.5,2,3,5,8,1,1],runeexpbase:[1,4,9,16,1e3,1e75,1e256],runeMaxLvl:4e4,upgradeCosts:[0,6,7,8,10,12,20,25,30,35,45,55,75,110,150,200,250,500,750,1e3,1500,2,3,4,5,6,7,10,13,20,30,150,400,800,1600,3200,1e4,2e4,5e4,1e5,2e5,1,2,3,5,6,7,42,65,87,150,300,500,1e3,1500,2e3,3e3,6e3,12e3,25e3,75e3,0,1,2,2,3,5,6,10,15,22,30,37,45,52,60,1900,2500,3e3,7482,21397,3,6,9,12,15,20,30,6,8,8,10,13,60,1,2,4,8,16,25,40,12,16,20,30,50,500,1250,5e3,25e3,125e3,1500,7500,3e4,15e4,1e6,250,1e3,5e3,25e3,125e3,1e3,1e6,1e9,1e12,1e15],crystalUpgradesCost:[6,15,20,40,100,200,500,1e3],crystalUpgradeCostIncrement:[8,15,20,40,100,200,500,1e3],researchBaseCosts:[1e200,1,1,1,1,1,1,100,1e4,1e6,1e8,2,200,2e4,2e6,2e8,4e4,4e8,10,1e5,1e9,100,100,1e4,2e3,2e5,40,200,50,5e3,2e7,777,7777,5e4,5e5,5e6,2e3,2e6,2e9,1e5,1e9,1,1,5,25,125,2,5,320,1280,25e8,10,2e3,4e5,8e7,2e9,5,400,1e4,3e6,9e8,100,2500,100,2e3,2e5,1,20,3e3,4e5,5e7,10,40,160,1e3,1e4,4e9,7e9,1e10,12e9,15e9,1e12,1e13,3e12,2e13,2e13,2e14,6e14,2e15,6e15,2e16,1e16,2e16,2e17,4e17,1e18,1e13,1e14,1e15,7777e15,7777e17,1e16,3e16,1e17,3e17,1e20,1e18,3e18,1e19,3e19,1e20,1e20,2e20,4e20,8e20,1e21,2e21,4e21,8e21,2e22,4e22,32e20,2e23,4e23,1e21,7777e29,5e8,5e12,5e16,5e20,5e24,1e25,2e25,4e25,8e25,1e26,4e26,8e26,1e27,2e27,1e28,5e9,5e15,5e21,5e27,1e28,1e29,2e29,4e29,8e29,1e27,2e30,4e30,8e30,1e31,2e31,5e31,1e32,2e32,4e32,8e32,1e33,2e33,4e33,8e33,1e34,3e34,1e35,3e35,6e35,1e36,3e36,1e37,3e37,1e38,3e38,1e39,3e39,1e40,3e40,1e50,3e41,1e42,3e42,6e42,1e43,3e43,1e44,3e44,1e45,3e45,2e46,6e46,2e47,6e47,1e64,6e48,2e49,1e50,1e51,4e56],researchMaxLevels:[0,1,1,1,1,1,10,10,10,10,10,10,10,10,10,10,10,10,1,1,1,25,25,25,20,20,10,10,10,10,10,12,12,10,10,10,10,10,10,1,1,1,1,1,1,1,1,1,1,1,1,10,10,10,10,10,20,20,20,20,20,1,5,4,5,5,10,10,10,10,10,1,1,1,1,1,10,50,50,50,50,10,1,20,20,20,20,20,20,20,10,20,20,20,20,1,20,5,5,3,2,10,10,10,10,1,10,10,20,25,25,50,50,50,50,100,10,10,10,100,100,25,25,25,1,5,10,10,10,10,1,10,10,10,1,1,25,25,25,15,1,10,10,10,10,1,10,1,6,10,1,25,25,1,15,1,10,10,10,1,1,10,10,10,10,1,25,25,25,15,1,10,10,10,1,1,10,3,6,10,5,25,25,1,15,1,20,20,20,1,1,20,1,50,50,10,25,25,25,15,1e5],ticker:0,costDivisor:1,freeAccelerator:0,totalAccelerator:0,freeAcceleratorBoost:0,totalAcceleratorBoost:0,acceleratorPower:1.1,acceleratorEffect:new f(1),acceleratorEffectDisplay:new f(1),generatorPower:new f(1),freeMultiplier:0,totalMultiplier:0,multiplierPower:2,multiplierEffect:new f(1),challengeOneLog:3,freeMultiplierBoost:0,totalMultiplierBoost:0,globalCoinMultiplier:new f(1),totalCoinOwned:0,prestigeMultiplier:new f(1),buildingPower:1,reincarnationMultiplier:new f(1),coinOneMulti:new f(1),coinTwoMulti:new f(1),coinThreeMulti:new f(1),coinFourMulti:new f(1),coinFiveMulti:new f(1),globalCrystalMultiplier:new f(1),globalMythosMultiplier:new f(.01),grandmasterMultiplier:new f(1),atomsMultiplier:new f(1),mythosBuildingPower:1,challengeThreeMultiplier:new f(1),totalMythosOwned:0,prestigePointGain:new f(0),challengeFivePower:1/3,transcendPointGain:new f(0),reincarnationPointGain:new f(0),produceFirst:new f(0),produceSecond:new f(0),produceThird:new f(0),produceFourth:new f(0),produceFifth:new f(0),produceTotal:new f(0),produceFirstDiamonds:new f(0),produceSecondDiamonds:new f(0),produceThirdDiamonds:new f(0),produceFourthDiamonds:new f(0),produceFifthDiamonds:new f(0),produceDiamonds:new f(0),produceFirstMythos:new f(0),produceSecondMythos:new f(0),produceThirdMythos:new f(0),produceFourthMythos:new f(0),produceFifthMythos:new f(0),produceMythos:new f(0),produceFirstParticles:new f(0),produceSecondParticles:new f(0),produceThirdParticles:new f(0),produceFourthParticles:new f(0),produceFifthParticles:new f(0),produceParticles:new f(0),producePerSecond:new f(0),producePerSecondDiamonds:new f(0),producePerSecondMythos:new f(0),producePerSecondParticles:new f(0),uFourteenMulti:new f(1),uFifteenMulti:new f(1),tuSevenMulti:1,currentTab:0,researchfiller1:"Hover over the grid to get details about researches!",researchfiller2:"Level: ",ordinals:["first","second","third","fourth","fifth","sixth","seventh","eighth","ninth","tenth","eleventh","twelfth","thirteenth","fourteenth","fifteenth","sixteenth","seventeenth","eighteenth","nineteenth","twentieth"],cardinals:["one","two","three","four","five","six","seven","eight","nine","ten","eleven","twelve","thirteen","fourteen","fifteen","sixteen","seventeen","eighteen","nineteen","twenty","twentyone","twentytwo","twentythree","twentyfour","twentyfive","twentysix","twentyseven","twentyeight","twentynine","thirty","thirtyone","thirtytwo","thirtythree","thirtyfour"],challengeBaseRequirements:[10,20,60,100,200,125,500,7500,2e8,35e8],prestigeamount:1,taxdivisor:new f("1"),taxdivisorcheck:new f("1"),runemultiplierincrease:{one:1,two:1,three:1,four:1,five:1},mythosupgrade13:new f("1"),mythosupgrade14:new f("1"),mythosupgrade15:new f("1"),challengefocus:0,maxexponent:1e4,effectiveLevelMult:1,optimalOfferingTimer:600,optimalObtainiumTimer:3600,runeSum:0,globalAntMult:new f("1"),antMultiplier:new f("1"),antOneProduce:new f("1"),antTwoProduce:new f("1"),antThreeProduce:new f("1"),antFourProduce:new f("1"),antFiveProduce:new f("1"),antSixProduce:new f("1"),antSevenProduce:new f("1"),antEightProduce:new f("1"),antCostGrowth:[1e41,3,10,100,1e4,1e8,1e16,1e32],antUpgradeBaseCost:[100,100,1e3,1e3,1e5,1e6,1e8,1e11,1e15,1e20,1e40,1e100],antUpgradeCostIncreases:[10,10,10,10,100,100,100,100,1e3,1e3,1e3,1e100],bonusant1:0,bonusant2:0,bonusant3:0,bonusant4:0,bonusant5:0,bonusant6:0,bonusant7:0,bonusant8:0,bonusant9:0,bonusant10:0,bonusant11:0,bonusant12:0,rune1level:1,rune2level:1,rune3level:1,rune4level:1,rune5level:1,rune1Talisman:0,rune2Talisman:0,rune3Talisman:0,rune4Talisman:0,rune5Talisman:0,talisman1Effect:[null,0,0,0,0,0],talisman2Effect:[null,0,0,0,0,0],talisman3Effect:[null,0,0,0,0,0],talisman4Effect:[null,0,0,0,0,0],talisman5Effect:[null,0,0,0,0,0],talisman6Effect:[null,0,0,0,0,0],talisman7Effect:[null,0,0,0,0,0],talisman6Power:0,talisman7Quarks:0,runescreen:"runes",settingscreen:"settings",talismanResourceObtainiumCosts:[1e13,1e14,1e16,1e18,1e20,1e22,1e24],talismanResourceOfferingCosts:[100,1e4,1e5,1e6,1e7,1e8,1e9],talismanLevelCostMultiplier:[1,4,1e4,1e8,1e13,10,100],talismanPositiveModifier:[null,.75,1.5,2.25,3,3.75,4.5],talismanNegativeModifier:[null,0,0,0,0,0,0],commonTalismanEnhanceCost:[null,0,3e3,1e3,0,0,0,0],uncommonTalismanEnchanceCost:[null,0,1e4,3e3,1e3,0,0,0],rareTalismanEnchanceCost:[null,0,1e5,2e4,2e3,500,0,0],epicTalismanEnhanceCost:[null,0,2e6,2e5,2e4,2e3,1e3,0],legendaryTalismanEnchanceCost:[null,0,4e7,2e6,1e5,2e4,2500,200],mythicalTalismanEnchanceCost:[null,0,0,0,0,0,0,0],talismanRespec:1,obtainiumGain:0,mirrorTalismanStats:[null,1,1,1,1,1],antELO:0,effectiveELO:0,timeWarp:!1,blessingMultiplier:1,spiritMultiplier:1,runeBlessings:[0,0,0,0,0,0],runeSpirits:[0,0,0,0,0,0],effectiveRuneBlessingPower:[0,0,0,0,0,0],effectiveRuneSpiritPower:[0,0,0,0,0,0],blessingBaseCost:1e6,spiritBaseCost:1e20,triggerChallenge:0,prevReductionValue:-1,buildingSubTab:"coin",blessingbase:[null,1/500,1/5e3,1/2e3,1/750,1/200,1/1e4,1/5e3,1/10,1/1e4,1/1e3],blessingDRPower:[null,1/3,1/3,2/3,1/2,2/3,2,1/3,1/3,1/16,1/16],giftbase:[1/1e3,1/1e3,1/1e3,1/1e3,1/1e3,1/1e3,1/1e3,1/1e3,1/1e3,1/1e3],giftDRPower:[1/6,1/6,1/3,1/4,1/3,1,1/6,1/6,1/32,1/32],benedictionbase:[null,1/1e3,1/1e3,1/1e3,1/1e3,1/1e3,1/1e3,1/1e3,1/1e3,1/1e3,1/1e3],benedictionDRPower:[null,1/12,1/12,1/6,1/8,1/6,1/2,1/12,1/12,1/64,1/64],platonicCubeBase:[2/4e6,1.5/4e6,1/4e6,1/8e4,1/1e4,1/1e5,1/1e4,1/1e4],platonicDRPower:[1/5,1/5,1/5,1/5,1/16,1/16,1/4,1/8],cubeBonusMultiplier:[null,1,1,1,1,1,1,1,1,1,1],tesseractBonusMultiplier:[null,1,1,1,1,1,1,1,1,1,1],hypercubeBonusMultiplier:[null,1,1,1,1,1,1,1,1,1,1],platonicBonusMultiplier:[1,1,1,1,1,1,1,1],autoOfferingCounter:0,researchOrderByCost:[],viscosityPower:[1,.87,.8,.75,.7,.6,.54,.45,.39,.33,.3,.2,.1,.05,0,0,0],lazinessMultiplier:[1,1/3,1/10,1/40,1/200,1/1e5,1/1e7,1/1e10,1/1e13,1/1e16,1/1e20,1/1e25,1/1e35,1/1e50,1/1e65,1/1e80,1/1e100],hyperchallengedMultiplier:[1,1.2,1.5,1.7,3,5,8,13,21,34,55,100,400,1600,7777,18888,88888],illiteracyPower:[1,.8,.7,.6,.5,.3,.2,.15,.1,.06,.04,.02,.01,.005,0,0,0],deflationMultiplier:[1,.3,.1,.03,.01,1/1e6,1/1e8,1/1e10,1/1e12,1/1e15,1/1e18,1/1e25,1/1e35,1/1e50,1/1e77,0,0],extinctionMultiplier:[1,.92,.86,.8,.74,.65,.55,.5,.45,.4,.35,.3,.1,0,0,0,0],droughtMultiplier:[1,5,25,200,1e4,1e7,1e11,1e16,1e22,1e30,1e40,1e55,1e80,1e120,1e177,1e200,1e250],financialcollapsePower:[1,.9,.7,.6,.5,.37,.3,.23,.18,.15,.12,.09,.03,.01,.007,7e-4,7e-5],corruptionPointMultipliers:[1,3,4,5,6,7,7.75,8.5,9.25,10,10.75,11.5,12.25,13,16,20,25,33,35],ascendBuildingProduction:{first:new f("0"),second:new f("0"),third:new f("0"),fourth:new f("0"),fifth:new f("0")},freeUpgradeAccelerator:0,freeUpgradeMultiplier:0,acceleratorMultiplier:1,multiplierMultiplier:1,constUpgradeCosts:[null,1,13,17,237,316,4216,5623,74989,1e10,1e24],globalConstantMult:new f("1"),autoTalismanTimer:0,autoChallengeTimerIncrement:0,corruptionTrigger:1,challenge15Rewards:{cube1:1,ascensions:1,coinExponent:1,taxes:1,obtainium:1,offering:1,accelerator:1,multiplier:1,runeExp:1,runeBonus:1,cube2:1,transcendChallengeReduction:1,reincarnationChallengeReduction:1,antSpeed:1,bonusAntLevel:1,cube3:1,talismanBonus:1,globalSpeed:1,blessingBonus:1,constantBonus:1,cube4:1,spiritBonus:1,score:1,quarks:1,hepteractUnlocked:0,cube5:1,powder:1,exponent:1,freeOrbs:0,ascensionSpeed:1},autoResetTimers:{prestige:0,transcension:0,reincarnation:0,ascension:0},timeMultiplier:1,upgradeMultiplier:1,historyCountMax:20,isEvent:!1,shopEnhanceVision:!1,eventClicked:!1,ambrosiaTimer:0,TIME_PER_AMBROSIA:600,ambrosiaCurrStats:{ambrosiaAdditiveLuckMult:1,ambrosiaLuck:100,ambrosiaBlueberries:0,ambrosiaGenerationSpeed:1},currentSingChallenge:void 0},l0=O({},o);var wC={antspecies1:"Inceptus Formicidae",antspecies2:"Fortunae Formicidae",antspecies3:"Tributum Formicidae",antspecies4:"Celeritas Formicidae",antspecies5:"Multa Formicidae",antspecies6:"Sacrificium Formicidae",antspecies7:"Hic Formicidae",antspecies8:"Experientia Formicidae",antspecies9:"Praemoenio Formicidae",antspecies10:"Scientia Formicidae",antspecies11:"Phylacterium Formicidae",antspecies12:"Mortuus Est Formicidae"},Ju=()=>e.currentChallenge.ascension!==15?1e5+_t(499e5,(e.antUpgrades[1]+o.bonusant2)/5e3*500/499):1e-4*(1e5+_t(499e5,(e.antUpgrades[1]+o.bonusant2)/5e3*500/499)),xC=[()=>d(f.pow(1.12+1/1e3*e.researches[101],e.antUpgrades[1-1]+o.bonusant1),2),()=>d(Ju()),()=>d(.005+.995*Math.pow(.99,e.antUpgrades[3-1]+o.bonusant3),4),()=>d(100*(_t(20,(e.antUpgrades[4-1]+o.bonusant4)/1e3*20/19)-1),3),()=>d(100*(_t(40,(e.antUpgrades[5-1]+o.bonusant5)/1e3*40/39)-1),3),()=>d(1+Math.pow(e.antUpgrades[6-1]+o.bonusant6,.66),4),()=>d(Math.min(9999999,3*e.antUpgrades[7-1]+3*o.bonusant7),0,!0),()=>d(_t(999,1/1e4*Math.pow(e.antUpgrades[8-1]+o.bonusant8,1.1)),3),()=>d(1*Math.min(1e7,e.antUpgrades[9-1]+o.bonusant9),0,!0),()=>d(1+2*Math.pow((e.antUpgrades[10-1]+o.bonusant10)/50,.75),4),()=>d(1+2*(1-Math.pow(2,-(e.antUpgrades[11-1]+o.bonusant11)/125)),4),()=>d(pt(2,e.antUpgrades[12-1]+o.bonusant12,69),4)],c0,u0=t=>{_a(c0),c0=$t(()=>ed(t),50)},ed=t=>{if(o.currentTab!==6)return;let r=i("anttierdescription"),n=i("antprice"),a=i("antquantity"),s=i("generateant"),l="ants.costGalacticCrumbs",c="first",p;switch(r.textContent=u.t(`ants.descriptions.${t}`),t){case 1:l="ants.costParticles",c="first",p=d(o.antOneProduce,5);break;case 2:c="second",p=d(o.antTwoProduce,5);break;case 3:c="third",p=d(o.antThreeProduce,5);break;case 4:c="fourth",p=d(o.antFourProduce,5);break;case 5:c="fifth",p=d(o.antFiveProduce,5);break;case 6:c="sixth",p=d(o.antSixProduce,5);break;case 7:c="seventh",p=d(o.antSevenProduce,5);break;case 8:c="eighth",p=d(o.antEightProduce,5);break}s.textContent=u.t(`ants.generates.${t}`,{x:p}),n.textContent=u.t(l,{x:d(e[`${c}CostAnts`])}),a.textContent=u.t("ants.owned",{x:d(e[`${c}OwnedAnts`]),y:d(e[`${c}GeneratedAnts`],2)})},zo=(t,r,n)=>(--r,t.times(f.pow(o.antCostGrowth[n-1],r)).add(1*r)),_s=(t,r,n)=>(--r,t.times(f.pow(o.antUpgradeCostIncreases[n-1],r))),td=(t,r,n)=>{let a=ra(e.antSacrificePoints);r=new f(r);let s=n===1?"reincarnationPoints":"antPoints",l=`${t}OwnedAnts`,c=e[l]+we(e[l]),p=c,g=zo(r,p,n);for(;e[s].gte(g);)p=p*4,g=zo(r,p,n);let m=Math.floor(p/8);for(;m>=we(p);)zo(r,p-m,n).lte(e[s])?m=Math.floor(m/2):p=p-Math.max(we(p),m);e.antMax||cC[v]&&e[`${o.ordinals[v+1]}OwnedAnts`]>0&&R(176+v);e.firstOwnedAnts>69e6&&(e.firstOwnedAnts=69e6)},rd=(t,r,n)=>{if(e.currentChallenge.ascension!==11){t=new f(t);let a=e.antUpgrades[n-1]+we(e.antUpgrades[n-1]),s=a,l=_s(t,s,n);for(;e.antPoints.gte(l);)s=s*4,l=_s(t,s,n);let c=Math.floor(s/8);for(;c>=we(s);)_s(t,s-c,n).lte(e.antPoints)?c=Math.floor(c/2):s=s-Math.max(we(s),c);e.antMax||a{let r=i("antspecies"),n=i("antlevelbonus"),a=i("antupgradedescription"),s=i("antupgradecost"),l=i("antupgradeeffect"),c=wC[`antspecies${t}`],p=u.t(`ants.upgrades.${t}`),g=o[`bonusant${t}`],m=e.currentChallenge.ascension===11?999:0;r.childNodes[0].textContent=`${c} Level ${d(e.antUpgrades[t-1])}`,n.textContent=` [+${d(Math.min(e.antUpgrades[t-1]+m,g))}]`,a.textContent=p,s.textContent=u.t("ants.costGalacticCrumbs",{x:d(f.pow(o.antUpgradeCostIncreases[t-1],e.antUpgrades[t-1]*o.extinctionMultiplier[e.usedCorruptions[10]]).times(o.antUpgradeBaseCost[t-1]))}),l.textContent=u.t(`ants.rewards.${t}`,{x:xC[t-1]()})},ra=t=>{let r=Math.pow(1+t/5e3,2);return r*=1+.2*Math.log(1+t)/Math.log(10),e.achievements[174]>0&&(r*=1+.4*Math.log(1+t)/Math.log(10)),Math.min(1e300,r)},Km=()=>{let t=ad();i("antSacrificeSummary").style.display="block",i("ELO").innerHTML=u.t("ants.yourAntELO",{x:d(o.antELO,2),y:d(o.effectiveELO,2,!1)}),i("SacrificeMultiplier").innerHTML=u.t("ants.antSacMultiplier",{y:d(ra(e.antSacrificePoints),3,!1),x:d(ra(e.antSacrificePoints+t.antSacrificePoints),3,!1)}),i("SacrificeUpgradeMultiplier").innerHTML=u.t("ants.upgradeMultiplier",{x:d(o.upgradeMultiplier,3,!0)}),i("SacrificeTimeMultiplier").innerHTML=u.t("ants.timeMultiplier",{x:d(o.timeMultiplier,3,!0)}),i("antSacrificeOffering").textContent=`+${d(t.offerings)}`,i("antSacrificeObtainium").textContent=`+${d(t.obtainium)}`,e.challengecompletions[9]>0&&(i("antSacrificeTalismanShard").textContent=u.t("ants.elo",{x:d(t.talismanShards),y:500}),i("antSacrificeCommonFragment").textContent=u.t("ants.elo",{x:d(t.commonFragments),y:750}),i("antSacrificeUncommonFragment").textContent=u.t("ants.elo",{x:d(t.uncommonFragments),y:1e3}),i("antSacrificeRareFragment").textContent=u.t("ants.elo",{x:d(t.rareFragments),y:1500}),i("antSacrificeEpicFragment").textContent=u.t("ants.elo",{x:d(t.epicFragments),y:2e3}),i("antSacrificeLegendaryFragment").textContent=u.t("ants.elo",{x:d(t.legendaryFragments),y:3e3}),i("antSacrificeMythicalFragment").textContent=u.t("ants.elo",{x:d(t.mythicalFragments),y:5e3}))},Rs=async(t=!1)=>{let r=!0;if(e.antPoints.gte("1e40")&&(!t&&e.toggles[32]&&(r=await ye(u.t("ants.autoReset"))),r)){let n=e.antSacrificePoints,a=ad();e.antSacrificePoints+=a.antSacrificePoints,e.runeshards+=a.offerings,e.currentChallenge.ascension!==14&&(e.researchPoints+=a.obtainium);let s={date:Date.now(),seconds:e.antSacrificeTimer,kind:"antsacrifice",offerings:a.offerings,obtainium:a.obtainium,antSacrificePointsBefore:n,antSacrificePointsAfter:e.antSacrificePoints,baseELO:o.antELO,effectiveELO:o.effectiveELO,crumbs:e.antPoints.toString(),crumbsPerSecond:o.antOneProduce.toString()};if(e.challengecompletions[9]>0&&(e.talismanShards=Math.min(1e300,e.talismanShards+a.talismanShards),e.commonFragments=Math.min(1e300,e.commonFragments+a.commonFragments),e.uncommonFragments=Math.min(1e300,e.uncommonFragments+a.uncommonFragments),e.rareFragments=Math.min(1e300,e.rareFragments+a.rareFragments),e.epicFragments=Math.min(1e300,e.epicFragments+a.epicFragments),e.legendaryFragments=Math.min(1e300,e.legendaryFragments+a.legendaryFragments),e.mythicalFragments=Math.min(1e300,e.mythicalFragments+a.mythicalFragments)),Ru(),e.antSacrificeTimer=0,e.antSacrificeTimerReal=0,Zt(),e.autoResearch>0&&e.autoResearchToggle){let l=e.autoResearch===200?.01:0;Fr(e.autoResearch,!0,l)}ea(),Ct.emit("historyAdd","ants",s)}e.mythicalFragments>=1e11&&e.currentChallenge.ascension===14&&e.achievements[248]<1&&R(248)},d0=()=>{let t=(l,c)=>e.antPoints.gte(_s(new f(o.antUpgradeBaseCost[l-1]),e.antUpgrades[l-1]+1,l).times(c)),r=[176,176,177,178,178,179,180,180,181,182,182,145],n=["100","100","1000","1000","1e5","1e6","1e8","1e11","1e15","1e20","1e40","1e100"];if(e.currentChallenge.ascension!==11)for(let l=1;l<=r.length;l++)(l===12?e.researches[r[l-1]]:e.achievements[r[l-1]])&&t(l,2)&&rd(n[l-1],!0,l);let a=[173,176,177,178,179,180,181,182],s=["1e700","3","100","10000","1e12","1e36","1e100","1e300"];for(let l=1;l<=a.length;l++){let c=l===1?e.reincarnationPoints:e.antPoints,p=l===1?1:2;e.achievements[a[l-1]]&&c.gte(e[`${o.ordinals[l-1]}CostAnts`].times(p))&&td(o.ordinals[l-1],s[l-1],l)}};function p0(t){var r;for(let n=0;n<227;n++)r=t[n]&2147483648|t[n+1]&2147483647,t[n]=t[n+397]^r>>>1^(r&1)*2567483615;for(let n=227;n<623;n++)r=t[n]&2147483648|t[n+1]&2147483647,t[n]=t[n-227]^r>>>1^(r&1)*2567483615;return r=t[623]&2147483648|t[0]&2147483647,t[623]=t[396]^r>>>1^(r&1)*2567483615,t}function MC(t){for(var r=g0(19650218),n=t.length,a=1,s=0,l=624>n?624:n;l;l--){let c=r[a-1]^r[a-1]>>>30;r[a]=(r[a]^(((c&4294901760)>>>16)*1664525<<16)+(c&65535)*1664525)+t[s]+s,a++,s++,a>=624&&(r[0]=r[623],a=1),s>=n&&(s=0)}for(l=623;l;l--){let c=r[a-1]^r[a-1]>>>30;r[a]=(r[a]^(((c&4294901760)>>>16)*1566083941<<16)+(c&65535)*1566083941)-a,a++,a>=624&&(r[0]=r[623],a=1)}return r[0]=2147483648,r}function g0(t){var r=new Array(624);r[0]=t;for(let n=1;n<624;n++){let a=r[n-1]^r[n-1]>>>30;r[n]=(((a&4294901760)>>>16)*1812433253<<16)+(a&65535)*1812433253+n}return r}function TC(t=Date.now()){var r;return Array.isArray(t)?r=MC(t):r=g0(t),p0(r)}function m0(t){var r=TC(t),n=0,a=()=>{let l;return n>=624&&(r=p0(r),n=0),l=r[n++],l^=l>>>11,l^=l<<7&2636928640,l^=l<<15&4022730752,l^=l>>>18,l>>>0},s={genrand_int32:()=>a(),genrand_int31:()=>a()>>>1,genrand_real1:()=>a()*(1/4294967295),genrand_real2:()=>a()*(1/4294967296),genrand_real3:()=>(a()+.5)*(1/4294967296),genrand_res53:()=>{let l=a()>>>5,c=a()>>>6;return(l*67108864+c)*(1/9007199254740992)},randomNumber:()=>a(),random31Bit:()=>s.genrand_int31(),randomInclusive:()=>s.genrand_real1(),random:()=>s.genrand_real2(),randomExclusive:()=>s.genrand_real3(),random53Bit:()=>s.genrand_res53()};return s}var Za=t=>m0(e.seed[t]++).random(),sd=(t,r,n)=>Math.floor(Za(t)*(n-r+1)+r),na={PromoCodes:0,Ambrosia:1};var Ie=(t,r=0)=>{let n=t==="ascension"||t==="quarks"||t==="goldenQuarks"||t==="singularity"||t==="octeracts"||t==="autoPotion"||t==="ambrosia"?1:qe().mult;switch(t){case"prestige":{e.prestigecounter+=r*n;break}case"transcension":{e.transcendcounter+=r*n;break}case"reincarnation":{e.reincarnationcounter+=r*n;break}case"ascension":{let a=e.singularityUpgrades.oneMind.getEffect().bonus?10:Rr();e.ascensionCounter+=r*n*a,e.ascensionCounterReal+=r*n;break}case"singularity":{e.ascensionCounterRealReal+=r,e.singularityCounter+=r*n,e.insideSingularityChallenge?e.singChallengeTimer+=r*n:e.singChallengeTimer=0;break}case"quarks":{let a=Rt().maxTime;e.quarkstimer+=r*n,e.quarkstimer=e.quarkstimer>a?a:e.quarkstimer;break}case"goldenQuarks":{if(+e.singularityUpgrades.goldenQuarks3.getEffect().bonus==0)return;e.goldenQuarksTimer+=r*n,e.goldenQuarksTimer=e.goldenQuarksTimer>3600*168?3600*168:e.goldenQuarksTimer;break}case"octeracts":{if(e.singularityUpgrades.octeractUnlock.getEffect().bonus)e.octeractTimer+=r*n;else return;if(e.octeractTimer>=1){let a=e.octeractTimer-e.octeractTimer%1;e.octeractTimer%=1;let s=Kr();if(e.wowOcteracts+=a*s,e.totalWowOcteracts+=a*s,e.highestSingularityCount>=160){let l=[160,173,185,194,204,210,219,229,240,249],c=1e-6,p=0;for(let g of l)e.highestSingularityCount>=g&&(p+=1);for(let g=0;g0,s=e.toggles[43]&&e.shopUpgrades.obtainiumPotion>0;e.autoPotionTimer+=r*n,e.autoPotionTimerObtainium+=r*n;let l=180*Math.pow(1.03,-e.highestSingularityCount)/+e.octeractUpgrades.octeractAutoPotionSpeed.getEffect().bonus,c=a?Math.min(1,l)/20:l,p=s?Math.min(1,l)/20:l;if(e.autoPotionTimer>=c){let g=(e.autoPotionTimer-e.autoPotionTimer%c)/c;e.autoPotionTimer%=c,gn("offeringPotion",!0,g,a)}if(e.autoPotionTimerObtainium>=p){let g=(e.autoPotionTimerObtainium-e.autoPotionTimerObtainium%p)/p;e.autoPotionTimerObtainium%=p,gn("obtainiumPotion",!0,g,s)}}break}case"ambrosia":{if(o.ambrosiaCurrStats.ambrosiaGenerationSpeed===0||(o.ambrosiaTimer+=r*n,o.ambrosiaTimer<.125))break;let s=o.ambrosiaCurrStats.ambrosiaLuck,l=o.ambrosiaCurrStats.ambrosiaGenerationSpeed;e.blueberryTime+=Math.floor(8*o.ambrosiaTimer)/8*l,e.ultimateProgress+=Math.floor(8*o.ambrosiaTimer)/8*Math.min(l,Math.pow(1e3*l,1/2)),o.ambrosiaTimer%=.125;let c=Ss(),p=1/2+(3/5-1/2)*+(e.singularityChallenges.noAmbrosiaUpgrades.completions>=15)+(2/3-3/5)*+(e.singularityChallenges.noAmbrosiaUpgrades.completions>=19)+(3/4-2/3)*+(e.singularityChallenges.noAmbrosiaUpgrades.completions>=20);for(;e.blueberryTime>=c;){let g=Za(na.Ambrosia),m=Math.floor(s/100),h=g1e6&&(e.ultimatePixels+=Math.floor(e.ultimateProgress/1e6),e.cubeUpgrades[79]>0&&(e.cubeUpgradeRedBarFilled+=Math.floor(e.ultimateProgress/1e6)),e.ultimateProgress-=1e6*Math.floor(e.ultimateProgress/1e6)),Ts()}}},Br=(t,r)=>{let n=t==="runeSacrifice"||t==="addOfferings"?1:qe().mult;switch(t){case"addObtainium":{if(e.currentChallenge.ascension===14)break;Or();let a=Eo();e.researchPoints=Math.min(1e300,e.researchPoints+a*r*n),o.currentTab===5&&fl();break}case"addOfferings":o.autoOfferingCounter+=r,e.runeshards=Math.min(1e300,e.runeshards+Math.floor(o.autoOfferingCounter)),o.autoOfferingCounter%=1;break;case"runeSacrifice":if(e.sacrificeTimer+=r,e.sacrificeTimer>=1&&isFinite(e.runeshards)&&e.runeshards>0){if(e.highestSingularityCount>=15){let a=4;e.toggles[36]&&(Bs("Blessings",100/a,!0),a--),e.toggles[37]&&(Bs("Spirits",100/a,!0),a--)}if(e.autoBuyFragment&&e.highestSingularityCount>=40&&e.cubeUpgrades[51]>0&&Xi(),e.cubeUpgrades[20]===1){let a=e.highestSingularityCount>=50?7:e.highestSingularityCount>=30?6:5,s=a-zg(a);if(s>0){let l=Math.floor(e.runeshards/s/2);for(let c=0;c=rt(c+1)||Ca(c+1,!0,l)}}else{let a=e.autoSacrifice;Ca(a,!0,0)}e.sacrificeTimer%=1}break;case"antSacrifice":{e.antSacrificeTimer+=r*n,e.antSacrificeTimerReal+=r,(e.autoAntSacrificeMode===2?e.antSacrificeTimerReal:e.antSacrificeTimer)>=e.autoAntSacTimer&&e.antSacrificeTimerReal>.1&&e.researches[124]===1&&e.autoAntSacrifice&&e.antPoints.gte("1e40")&&Rs(!0);break}}};var SC=new Intl.DateTimeFormat("EN-GB",{year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",hour12:!1,minute:"2-digit",second:"2-digit"}),kC=new Intl.DateTimeFormat("EN-GB",{year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",hour12:!0,minute:"2-digit",second:"2-digit"}),LC=36e5,Je=(t="default",r=!1)=>{let a=(r?kC:SC).formatToParts(new Date).filter(p=>p.type!=="literal").map(p=>({[p.type]:p.value})),s=Object.assign({},...a),l=r?` ${s.dayPeriod.toUpperCase()}`:"",c=["sun","mon","tue","wed","thu","fri","sat"];switch(t){case"default":return`${s.year}-${s.month}-${s.day} ${s.hour}_${s.minute}_${s.second}${l}`;case"short":return`${s.year}${s.month}${s.day}${s.hour}${s.minute}${s.second}`;case"year":return`${s.year}`;case"month":return`${s.month}`;case"day":return`${s.day}`;case"hour":return`${s.hour}`;case"minute":return`${s.minute}`;case"second":return`${s.second}`;case"period":return`${s.dayPeriod.toUpperCase()}`;case"weekday":return`${c[new Date().getUTCDay()]}`;default:return t}},b0=t=>{let r=t.value.slice(0,100);e.saveString=r===""?M.saveString:to(r),i("saveStringInput").value=e.saveString},PC=()=>{var t,r;return(r=(t=/[\d?=.]+/.exec(tr))==null?void 0:t[0])!=null?r:tr},Xo=()=>{let r=e.saveString.replace(/\$(.*?)\$/g,(n,a)=>{switch(a){case"VERSION":return`v${tr}`;case"TIME":return Je();case"TIME12":return Je(void 0,!0);case"SING":return`Singularity ${e.singularityCount}`;case"SINGS":return`${e.singularityCount}`;case"VER":return PC();case"TIMES":return Je("short");case"YEAR":return Je("year");case"Y":return Je("year");case"MONTH":return Je("month");case"M":return Je("month");case"DAY":return Je("day");case"D":return Je("day");case"HOUR":return Je("hour");case"H":return Je("hour");case"H12":return Je("hour",!0);case"MINUTE":return Je("minute");case"MI":return Je("minute");case"SECOND":return Je("second");case"S":return Je("second");case"PERIOD":return Je("period",!0);case"P":return Je("period",!0);case"WEEKDAY":return Je("weekday");case"W":return Je("weekday");case"DATE":return`${Date.now()}`;case"DATES":return`${Math.floor(Date.now()/1e3)}`;case"QUARK":return`${Math.floor(Number(e.worlds))}`;case"QUARKS":return d(Number(e.worlds));case"GQ":return`${Math.floor(e.goldenQuarks)}`;case"GQS":return d(e.goldenQuarks);case"STAGE":return wu(0);default:return`${a}`}});return to(r)},od=async(t,r)=>{if(an("saveType").checked)try{await navigator.clipboard.writeText(t),i("exportinfo").textContent=u.t("importexport.copiedSave")}catch(a){let s=document.createElement("textarea");s.setAttribute("style","top: 0; left: 0; position: fixed;"),s.setAttribute("data-clipboard-text",t),document.body.appendChild(s),s.focus(),s.select();let l=new f0.default(s),c=()=>{l.destroy(),document.body.removeChild(s)};l.on("success",()=>{i("exportinfo").textContent=u.t("importexport.copiedSave"),c()}),l.on("error",()=>{i("exportinfo").textContent=u.t("importexport.exportFailed"),P(u.t("importexport.unableCopySave")).finally(c)})}else{let a=document.createElement("a");a.setAttribute("href",`data:text/plain;charset=utf-8,${t}`),a.setAttribute("download",r),a.setAttribute("id","downloadSave"),document.body.appendChild(a),a.click(),document.body.removeChild(a),i("exportinfo").textContent=u.t("importexport.copiedFile")}setTimeout(()=>i("exportinfo").textContent="",15e3)},y0=async(t=!0)=>{if(e.offlinetick=Date.now(),t){e.lastExportedSave=Date.now();let n=Rt(),a=1;a*=1+rr()/100,a*=e.highestSingularityCount>=100?1+e.highestSingularityCount/50:1,+e.singularityUpgrades.goldenQuarks3.getEffect().bonus>0&&(e.goldenQuarks+=Math.floor(e.goldenQuarksTimer/(3600/+e.singularityUpgrades.goldenQuarks3.getEffect().bonus))*a,e.goldenQuarksTimer=e.goldenQuarksTimer%(3600/+e.singularityUpgrades.goldenQuarks3.getEffect().bonus)),n.gain>=1&&(e.worlds.add(n.gain),e.quarkstimer=e.quarkstimer%(3600/n.perHour))}if(!vr())return;let r=localStorage.getItem("Synergysave2");if(!r)return P("How?");await od(r,Xo()),setTimeout(()=>i("exportinfo").textContent="",15e3)},v0=async()=>{await P(u.t("importexport.reloadDeletePrompt")),await id(!0)},id=async(t=!0)=>{if(!t){let n=window.crypto.getRandomValues(new Uint16Array(1))[0]%16,a=window.crypto.getRandomValues(new Uint16Array(1))[0]%16,s=await Ee(u.t("importexport.resetPrompt",{a:n,b:a,sum:n+a}));if(s===null||Number(s)!==n+a)return P(u.t("importexport.wrongAnswer"))}let r=ws.safeParse(M);bn(0),Ce(0,{page:0}),Ce(3,{page:0}),Ce(4,{page:0}),Ce(7,{page:0}),Ce(8,{page:0}),Ce(9,{page:0}),Ce(10,{page:0}),Ga(ls(JSON.stringify(r.data)),!0)},ld=async(t,r)=>{let n=t.target,a=n.files[0],s="";if(typeof Blob.prototype.text=="function")s=await a.text();else{let l=new FileReader;l.readAsText(a),s=await new Promise(p=>{l.addEventListener("load",()=>p(l.result.toString()))})}return n.value="",UC(a.lastModified),r(s)},Ga=(t,r=!1)=>{if(typeof t!="string")return P(u.t("importexport.unableImport"));let n=h0.default.decompressFromBase64(t),a=JSON.parse(n||atob(t));if(a.exporttest==="YES!"||a.exporttest===!0||a.exporttest===!1&&!1||a.exporttest==="NO!"&&!1){let s=ls(JSON.stringify(a));if(s===null)return P(u.t("importexport.unableImport"));localStorage.setItem("Synergysave2",s),cd(r);return}else return P(u.t("importexport.loadTestInLive"))},Zo=t=>{let r=i("promocodeinfo"),n=`'${t}': `,a=0;switch(t){case"daily":e.dailyCodeUsed?n+=u.t("importexport.daily0Uses"):n+=u.t("importexport.daily1Uses");break;case"add":a=Xn(),a===0?n+=u.t("importexport.add0Uses",{x:0,y:d(ml(),0)}):a!==1?n+=u.t("importexport.addUses",{x:a}):n+=u.t("importexport.add1Uses",{x:a});break;case"time":a=w0(),a===0?n+=u.t("importexport.add0Uses",{x:0,y:d(AC(),0)}):n+=u.t("importexport.timeMultiplier",{x:a,y:d(x0(),2,!0)});break;default:n=""}r.textContent=n},C0=async()=>{let t=await Ee(u.t("importexport.promocodePrompt"));xn(t)},xn=async(t,r)=>{let n=i("promocodeinfo");if(t===null)return P(u.t("importexport.comeBackSoon"));if(t==="23andme"&&!e.codes.get(48)&&o.isEvent)return e.dailyCodeUsed?(e.codes.set(48,!0),e.quarkstimer=Rt().maxTime,e.goldenQuarksTimer=3600*24,Ie("ascension",8*3600),e.dailyCodeUsed=!1,(e.challenge15Exponent>=1e15||e.highestSingularityCount>0)&&(e.hepteractCrafts.quark.CAP*=2,e.hepteractCrafts.quark.BAL+=Math.min(1e13,e.hepteractCrafts.quark.CAP/2)),e.highestSingularityCount>0&&(e.singularityUpgrades.goldenQuarks1.freeLevels+=1+Math.floor(e.highestSingularityCount/10),e.singularityUpgrades.goldenQuarks2.freeLevels+=1+Math.floor(e.highestSingularityCount/10),e.singularityUpgrades.goldenQuarks3.freeLevels+=1+Math.floor(e.highestSingularityCount/10),e.singularityUpgrades.octeractUnlock.getEffect().bonus&&(e.octeractUpgrades.octeractImprovedQuarkHept.freeLevels+=.05)),P(`Not sponsored by the company! Your Quark timer(s) have been replenished and you have been given 8 real life hours of Ascension progress! Your daily code has also been reset for you. ${e.challenge15Exponent>=1e15||e.highestSingularityCount>0?"Derpsmith also hacked your save to expand Quark Hepteract for free, and (to a limit) automatically filled the extra amount! What a generous, handsome gigachad.":""} ${e.highestSingularityCount>0?"You were also given free levels of GQ1-3!":""} - ${e.singularityUpgrades.octeractUnlock.getEffect().bonus?"Finally, you were given a tiny amount of free Octeract Quark Hepteract Improver upgrade!":""}`)):P("This event code gives you another usage of code 'daily'. Please use that code and try this event code again.");if(t==="synergism2021"&&!e.codes.get(1))e.codes.set(1,!0),e.runeshards+=25,e.worlds.add(50),n.textContent=u.t("importexport.promocodes.synergism2021");else if(t===":unsmith:"&&e.achievements[243]<1)R(243),n.textContent=u.t("importexport.promocodes.unsmith");else if(t===":antismith:"&&e.achievements[244]<1)R(244),n.textContent=u.t("importexport.promocodes.antismith");else if(t==="Khafra"&&!e.codes.get(26)){e.codes.set(26,!0);let a=Math.floor(ja(Zn.PromoCodes)*(400-100+1)+100);e.worlds.add(a),n.textContent=u.t("importexport.promocodes.khafra",{x:e.worlds.applyBonus(a)})}else if(t==="alonso bribe"&&!e.codes.get(47)){let a=e.hepteractCrafts.quark;return a.UNLOCKED?a.computeActualCap()>=1e300?P(u.t("importexport.promocodes.bribe.overCapacity")):(e.codes.set(47,!0),a.CAP=Math.min(1e300,a.CAP*2),P(u.t("importexport.promocodes.bribe.thanks"))):P(u.t("importexport.promocodes.bribe.notUnlocked"))}else if(t.toLowerCase()==="daily"&&!e.dailyCodeUsed){e.dailyCodeUsed=!0;let a=u.t("importexport.promocodes.daily.message"),s=hC(),l=1+Math.min(49,e.highestSingularityCount),c=e.worlds.applyBonus(s.quarks*l);if(c>1e5&&(c=Math.pow(1e5,.75)*Math.pow(c,.25)),e.worlds.add(c,!1),e.goldenQuarks+=s.goldenQuarks,a+=` + ${e.singularityUpgrades.octeractUnlock.getEffect().bonus?"Finally, you were given a tiny amount of free Octeract Quark Hepteract Improver upgrade!":""}`)):P("This event code gives you another usage of code 'daily'. Please use that code and try this event code again.");if(t==="synergism2021"&&!e.codes.get(1))e.codes.set(1,!0),e.runeshards+=25,e.worlds.add(50),n.textContent=u.t("importexport.promocodes.synergism2021");else if(t===":unsmith:"&&e.achievements[243]<1)R(243),n.textContent=u.t("importexport.promocodes.unsmith");else if(t===":antismith:"&&e.achievements[244]<1)R(244),n.textContent=u.t("importexport.promocodes.antismith");else if(t==="Khafra"&&!e.codes.get(26)){e.codes.set(26,!0);let a=Math.floor(Za(na.PromoCodes)*(400-100+1)+100);e.worlds.add(a),n.textContent=u.t("importexport.promocodes.khafra",{x:e.worlds.applyBonus(a)})}else if(t==="alonso bribe"&&!e.codes.get(47)){let a=e.hepteractCrafts.quark;return a.UNLOCKED?a.computeActualCap()>=1e300?P(u.t("importexport.promocodes.bribe.overCapacity")):(e.codes.set(47,!0),a.CAP=Math.min(1e300,a.CAP*2),P(u.t("importexport.promocodes.bribe.thanks"))):P(u.t("importexport.promocodes.bribe.notUnlocked"))}else if(t.toLowerCase()==="daily"&&!e.dailyCodeUsed){e.dailyCodeUsed=!0;let a=u.t("importexport.promocodes.daily.message"),s=OC(),l=1+Math.min(49,e.highestSingularityCount),c=e.worlds.applyBonus(s.quarks*l);if(c>1e5&&(c=Math.pow(1e5,.75)*Math.pow(c,.25)),e.worlds.add(c,!1),e.goldenQuarks+=s.goldenQuarks,a+=` ${d(c,0,!0)} Quarks`,s.goldenQuarks>0&&(a+=` -${d(s.goldenQuarks,0,!0)} Golden Quarks`),await P(a),e.highestSingularityCount>0){let p={goldenQuarks3:{value:.2,pdf:b=>0<=b&&b<=1},goldenQuarks2:{value:.2,pdf:b=>1<=b&&b<=3},goldenQuarks1:{value:.2,pdf:b=>3<=b&&b<=10},singCubes3:{value:.25,pdf:b=>1015202580140200400600800=200&&(g*=2),g*=xe.FREE_UPGRADE_PROMOCODE_BUFF,g=Math.floor(g);let m=Object.keys(e.singularityUpgrades).filter(b=>b in p);a=u.t("importexport.promocodes.daily.message2");let h={};for(let b=0;b=20&&(e.singularityUpgrades.goldenQuarks1.freeLevels+=.2,h.goldenQuarks1?h.goldenQuarks1+=.2:h.goldenQuarks1=.2,e.singularityUpgrades.goldenQuarks2.freeLevels+=.2,h.goldenQuarks2?h.goldenQuarks2+=.2:h.goldenQuarks2=.2,e.singularityUpgrades.goldenQuarks3.freeLevels+=1,h.goldenQuarks3?h.goldenQuarks3+=1:h.goldenQuarks3=1),e.highestSingularityCount>=200&&e.highestSingularityCount<205){let b=Math.max(e.octeractUpgrades.octeractGain.level/100,Math.pow(e.octeractUpgrades.octeractGain.level*e.octeractUpgrades.octeractGain.freeLevels/1e3,.5));e.octeractUpgrades.octeractGain.freeLevels+=b,h.octeractGain=b}else if(e.highestSingularityCount>=205){let b=Math.max(e.octeractUpgrades.octeractGain.level/100,Math.pow(e.octeractUpgrades.octeractGain.level*e.octeractUpgrades.octeractGain.freeLevels/640,.5)),C=Math.max(e.octeractUpgrades.octeractGain2.level/100,Math.pow(Math.pow(e.octeractUpgrades.octeractGain2.level,2)*e.octeractUpgrades.octeractGain2.freeLevels/125e3,.333));e.octeractUpgrades.octeractGain.freeLevels+=b,e.octeractUpgrades.octeractGain2.freeLevels+=C,h.octeractGain=b,h.octeractGain2=C}for(let b of Object.keys(h))a+=fC(b,h[b]);await P(a)}return}else if(t.toLowerCase()==="add"){let a=qn(),s=yo().total,l=d(ll(),0),c=Ia().time;if(a<1){n.textContent=u.t("importexport.noAddCodes",{x:l});return}let p=null;if(r?p=r.toString():p=await Ee(u.t("importexport.useXAdds",{x:a}),a.toString()),p===null)return P(u.t("importexport.cancelAdd"));let g=Number(p);if(Number.isNaN(g)||!Number.isInteger(g)||g===0||g<0&&-g>=a)return P(u.t("general.validation.invalidNumber"));let m=fu(),h=g>0?Math.min(a,g):a+g,b=Math.floor(m.quarks*h),[C,v]=window.crypto.getRandomValues(new Uint8Array(2)),x=Math.max(Date.now()-(s-h)*c,e.rngCode+c*h),B=Math.floor((Date.now()-x)/c),U=Math.floor((c-(Date.now()-x-c*B))/1e3),k=h*m.ascensionTimer,L=e.shopUpgrades.calculator3>0?u.t("importexport.promocodes.add.calculator3",{x:d(k)}):"",E=h*m.gqTimer,T=e.shopUpgrades.calculator5>0?u.t("importexport.promocodes.add.calculator5",{x:d(E)}):"",S=h*m.octeractTime,I=e.shopUpgrades.calculator6>0?u.t("importexport.promocodes.add.calculator6",{x:d(S)}):"",N=h*m.blueberryTime,X=e.shopUpgrades.calculator7>0?u.t("importexport.promocodes.add.calculator7",{x:d(N,2,!0)}):"",re=e.highestSingularityCount>=150?u.t("importexport.promocodes.add.freeLevel",{x:d(.01*h,2),y:d(.05*h,2)}):"";if(e.shopUpgrades.calculator===pe.calculator.maxLevel)if(e.worlds.add(b),Ie("ascension",k),e.goldenQuarksTimer+=E,Ie("octeracts",S),Ie("ambrosia",N),e.highestSingularityCount>=150&&(e.singularityUpgrades.goldenQuarks1.freeLevels+=.01*h,e.singularityUpgrades.goldenQuarks3.freeLevels+=.05*h),e.rngCode=x,r){jo("add");return}else return P(u.t("importexport.promocodes.add.calculatorMaxed",{a:C,b:v,c:C+v,d:e.worlds.toString(b),e:L,f:T,g:I,h:re,i:X,j:B,k:U.toLocaleString()}));let w={w:e.worlds.toString(b),x:C,y:v,z:C+v},H=e.shopUpgrades.calculator>0?u.t("importexport.promocodes.add.calculatorSolution",w):u.t("importexport.promocodes.add.calculatorPrompt",w),J=await Ee(H);if(J===null)return P(u.t("importexport.promocodes.add.cancelled"));e.rngCode=x,C+v===+J?(e.worlds.add(b),Ie("ascension",k),e.goldenQuarksTimer+=E,Ie("octeracts",S),Ie("ambrosia",N),await P(u.t("importexport.promocodes.add.reward",{a:e.worlds.toString(b),b:L,c:T,d:I,e:B,f:U.toLocaleString(navigator.language)}))):await P(u.t("importexport.promocodes.add.wrong",{w:J,x:C+v,y:B,z:U.toLocaleString(navigator.language)}))}else if(t==="sub"){let a=1+window.crypto.getRandomValues(new Uint16Array(1))[0]%16,s=Number(e.worlds);await P(u.t("importexport.promocodes.sub.subbed",{x:a})),s1e4)return n.textContent=u.t("importexport.promocodes.gamble.cheaters");if(Number(e.worlds)66666&&(h=Math.pow(h,.35)*Math.pow(66666,.65)),e.visitedAmbrosiaSubtab&&(b=1800*s),e.worlds.add(h*s,!1),o.ambrosiaTimer+=b;let C=u.t("importexport.promocodes.time.won",{x:d(h*s,0,!0)}),v=b>0?u.t("importexport.promocodes.time.ambrosia",{blueberryTime:b}):"";return P(C+v)}else return P(u.t("importexport.promocodes.time.lost"))}}else if(t==="spoiler"){let a=Kr();return a>1?P(u.t("importexport.promocodes.spoiler.moreThan1",{x:d(a,2,!0)})):P(u.t("importexport.promocodes.spoiler.one",{x:d(1/a,2,!0)}))}else n.textContent=u.t("importexport.promocodes.invalid");hr()&&(yt.emit("promocode",t),setTimeout(()=>n.textContent="",15e3))},Bl=()=>{let t=[10,16,25,36,49,64,81,100,121,144,169,196,225,235,240],r=0;for(let n=0;n=t[n];n++)r+=1;return 1+r/5},yo=()=>{let t=Math.floor(e.shopUpgrades.calculator5/10);e.shopUpgrades.calculator5===pe.calculator5.maxLevel&&(t+=6);let r=[24,2*e.shopUpgrades.calculator2,e.shopUpgrades.calculator4===pe.calculator4.maxLevel?32:0,t,e.shopUpgrades.calculator6===pe.calculator6.maxLevel?24:0,e.shopUpgrades.calculator7===pe.calculator7.maxLevel?48:0],n=ae(r);return n*=xe.ADD_CODE_CAP_BUFF,r.push(Bl()),n*=Bl(),{list:r,total:Math.ceil(n)}},Ia=()=>{let t=[pC,1-.04*e.shopUpgrades.calculator4,1-Math.min(.6,(e.highestSingularityCount>=125?e.highestSingularityCount/800:0)+(e.highestSingularityCount>=200?e.highestSingularityCount/800:0)),e.runelevels[6]>0?.8:1,1/Bl()];return{list:t,time:be(t)}},qn=()=>{let t=yo().total,r=Ia().time;return Math.floor(Math.min(t,(Date.now()-e.rngCode)/r))},ll=()=>{let t=Math.floor(Ia().time+e.rngCode-Date.now())/1e3;if(t>0)return t;if(qn()===yo().total)return 0;{let n=Date.now()-e.rngCode-Ia().time*qn();return Math.floor(Ia().time-n)/1e3}},fu=()=>{let t=Bl(),r=1+.14*e.shopUpgrades.calculator;r*=e.shopUpgrades.calculator2===pe.calculator2.maxLevel?1.25:1,r/=t;let n=Math.max(.4+.02*e.shopUpgrades.calculator3,2/5+Zu(Zn.PromoCodes,0,127)/640),a=.4+.02*e.shopUpgrades.calculator3,s=.6,l=r*Ut().perHour,c=e.singularityUpgrades.expertPack.level>0?1.2:1,p=60*e.shopUpgrades.calculator3*c/t,g=6*e.shopUpgrades.calculator5/t,m=e.shopUpgrades.calculator6/t,h=e.shopUpgrades.calculator7/t;return{quarks:n*l,minQuarks:a*l,maxQuarks:s*l,ascensionTimer:p,gqTimer:g,octeractTime:m,blueberryTime:h}},c0=()=>(Date.now()-e.promoCodeTiming.time)/1e3<900?0:1,mC=()=>900-(Date.now()-e.promoCodeTiming.time)/1e3,u0=()=>Math.min(24,(Date.now()-e.promoCodeTiming.time)/(1e3*3600)),fC=(t,r)=>{let n=t in F?u.t(`singularity.data.${t}.name`):u.t(`octeract.data.${t}.name`);return` -+${d(r,0,!0)} extra levels of '${n}'`},hC=()=>{let t=0,r=0,n=e.ascensionCount>0,a=e.highestSingularityCount>0;return(e.reincarnationCount>0||n||a)&&(t+=20),(e.challengecompletions[6]>0||n||a)&&(t+=20),(e.challengecompletions[7]>0||n||a)&&(t+=30),(e.challengecompletions[8]>0||n||a)&&(t+=30),(e.challengecompletions[9]>0||n||a)&&(t+=40),(e.challengecompletions[10]>0||n||a)&&(t+=60),(n||a)&&(t+=50),(e.challengecompletions[11]>0||a)&&(t+=50),(e.challengecompletions[12]>0||a)&&(t+=50),(e.challengecompletions[13]>0||a)&&(t+=50),(e.challengecompletions[14]>0||a)&&(t+=100),e.researches[200]===o.researchMaxLevels[200]&&(t+=250),e.cubeUpgrades[50]===1e5&&(t+=250),e.platonicUpgrades[5]>0&&(t+=250),e.platonicUpgrades[10]>0&&(t+=500),e.platonicUpgrades[15]>0&&(t+=750),e.challenge15Exponent>1e18&&(t+=Math.floor(1e3*(Math.log10(e.challenge15Exponent)-18))),e.platonicUpgrades[20]>0&&(t+=2500),t*=1+.05*e.shopUpgrades.shopImprovedDaily,t=Math.floor(t),a&&(r+=2+3*e.highestSingularityCount,r*=1+.2*e.shopUpgrades.shopImprovedDaily2,r*=1+.15*e.shopUpgrades.shopImprovedDaily3,r*=1+e.shopUpgrades.shopImprovedDaily4),{quarks:t,goldenQuarks:r}},bC=t=>{let r=localStorage.getItem("firstPlayed"),n=new Date(t);if(r===null){localStorage.setItem("firstPlayed",n.toISOString());return}new Date(r).getTime()>n.getTime()&&(e.firstPlayed=n.toISOString(),localStorage.setItem("firstPlayed",e.firstPlayed))};var Ke=class extends En{constructor(n,a){var c,p,g,m;let s=u.t(`ambrosia.data.${a}.name`),l=u.t(`ambrosia.data.${a}.description`);super(ee(O({},n),{name:s,description:l}));this.ambrosiaInvested=0;this.blueberriesInvested=0;this.blueberryCost=n.blueberryCost,this.costFormula=n.costFormula,this.rewards=n.rewards,this.ambrosiaInvested=(c=n.ambrosiaInvested)!=null?c:0,this.blueberriesInvested=(p=n.blueberriesInvested)!=null?p:0,this.preRequisites=(g=n.prerequisites)!=null?g:void 0,this.cacheUpdates=(m=n.cacheUpdates)!=null?m:void 0}getCostTNL(){return this.level===this.maxLevel?0:this.costFormula(this.level,this.costPerLevel)}async buyLevel(n){let a=0,s=1,l=e.ambrosia;if(!this.checkPrerequisites())return P(u.t("ambrosia.prereqNotMetAlert"));if(n.shiftKey){s=1e6;let c=Number(await Ee(u.t("ambrosia.ambrosiaBuyPrompt",{amount:d(e.ambrosia,0,!0)})));if(isNaN(c)||!isFinite(c)||!Number.isInteger(c))return P(u.t("general.validation.finite"));if(c===-1)l=e.ambrosia;else{if(c<=0)return P(u.t("octeract.buyLevel.cancelPurchase"));l=c}l=Math.min(e.ambrosia,l)}if(this.maxLevel>0&&(s=Math.min(s,this.maxLevel-this.level)),s===0)return P(u.t("octeract.buyLevel.alreadyMax"));for(;s>0;){let c=this.getCostTNL();if(e.ambrosia1)return P(`${u.t("octeract.buyLevel.multiBuy",{n:d(a)})}`);this.updateUpgradeHTML(),this.updateCaches()}toString(){let n=this.getCostTNL(),a=this.maxLevel===-1?"":`/${d(this.maxLevel,0,!0)}`,s=this.maxLevel===this.level,l=s?"plum":"white",c=this.freeLevels>0?` [+${d(this.freeLevels,1,!0)}]`:"";this.freeLevels>this.level&&(c=`${c}${u.t("general.softCapped")}`);let p=n<=e.ambrosia,g=s?` ${u.t("general.maxed")}`:p?` ${u.t("general.affordable")}`:` ${u.t("octeract.buyLevel.cannotAfford")}`,m=u.t("ambrosia.prerequisite");if(this.preRequisites!==void 0){for(let[h,b]of Object.entries(this.preRequisites)){let C=h,v=e.blueberryUpgrades[C].level>=b?"green":"red",x=e.blueberryUpgrades[C].level>=b?"":u.t("ambrosia.prereqNotMet");m=`${m} ${e.blueberryUpgrades[C].name} lv.${b} ${x} |`}m=m.slice(0,-1)}return`${this.name} +${d(s.goldenQuarks,0,!0)} Golden Quarks`),await P(a),e.highestSingularityCount>0){let p={goldenQuarks3:{value:.2,pdf:b=>0<=b&&b<=1},goldenQuarks2:{value:.2,pdf:b=>1<=b&&b<=3},goldenQuarks1:{value:.2,pdf:b=>3<=b&&b<=10},singCubes3:{value:.25,pdf:b=>1015202580140200400600800=200&&(g*=2),g*=xe.FREE_UPGRADE_PROMOCODE_BUFF,g=Math.floor(g);let m=Object.keys(e.singularityUpgrades).filter(b=>b in p);a=u.t("importexport.promocodes.daily.message2");let h={};for(let b=0;b=20&&(e.singularityUpgrades.goldenQuarks1.freeLevels+=.2,h.goldenQuarks1?h.goldenQuarks1+=.2:h.goldenQuarks1=.2,e.singularityUpgrades.goldenQuarks2.freeLevels+=.2,h.goldenQuarks2?h.goldenQuarks2+=.2:h.goldenQuarks2=.2,e.singularityUpgrades.goldenQuarks3.freeLevels+=1,h.goldenQuarks3?h.goldenQuarks3+=1:h.goldenQuarks3=1),e.highestSingularityCount>=200&&e.highestSingularityCount<205){let b=Math.max(e.octeractUpgrades.octeractGain.level/100,Math.pow(e.octeractUpgrades.octeractGain.level*e.octeractUpgrades.octeractGain.freeLevels/1e3,.5));e.octeractUpgrades.octeractGain.freeLevels+=b,h.octeractGain=b}else if(e.highestSingularityCount>=205){let b=Math.max(e.octeractUpgrades.octeractGain.level/100,Math.pow(e.octeractUpgrades.octeractGain.level*e.octeractUpgrades.octeractGain.freeLevels/640,.5)),C=Math.max(e.octeractUpgrades.octeractGain2.level/100,Math.pow(Math.pow(e.octeractUpgrades.octeractGain2.level,2)*e.octeractUpgrades.octeractGain2.freeLevels/125e3,.333));e.octeractUpgrades.octeractGain.freeLevels+=b,e.octeractUpgrades.octeractGain2.freeLevels+=C,h.octeractGain=b,h.octeractGain2=C}for(let b of Object.keys(h))a+=EC(b,h[b]);await P(a)}return}else if(t.toLowerCase()==="add"){let a=Xn(),s=xo().total,l=d(ml(),0),c=Ha().time;if(a<1){n.textContent=u.t("importexport.noAddCodes",{x:l});return}let p=null;if(r?p=r.toString():p=await Ee(u.t("importexport.useXAdds",{x:a}),a.toString()),p===null)return P(u.t("importexport.cancelAdd"));let g=Number(p);if(Number.isNaN(g)||!Number.isInteger(g)||g===0||g<0&&-g>=a)return P(u.t("general.validation.invalidNumber"));let m=xu(),h=g>0?Math.min(a,g):a+g,b=Math.floor(m.quarks*h),[C,v]=window.crypto.getRandomValues(new Uint8Array(2)),x=Math.max(Date.now()-(s-h)*c,e.rngCode+c*h),B=Math.floor((Date.now()-x)/c),U=Math.floor((c-(Date.now()-x-c*B))/1e3),k=h*m.ascensionTimer,L=e.shopUpgrades.calculator3>0?u.t("importexport.promocodes.add.calculator3",{x:d(k)}):"",E=h*m.gqTimer,T=e.shopUpgrades.calculator5>0?u.t("importexport.promocodes.add.calculator5",{x:d(E)}):"",S=h*m.octeractTime,I=e.shopUpgrades.calculator6>0?u.t("importexport.promocodes.add.calculator6",{x:d(S)}):"",N=h*m.blueberryTime,X=e.shopUpgrades.calculator7>0?u.t("importexport.promocodes.add.calculator7",{x:d(N,2,!0)}):"",re=e.highestSingularityCount>=150?u.t("importexport.promocodes.add.freeLevel",{x:d(.01*h,2),y:d(.05*h,2)}):"";if(e.shopUpgrades.calculator===pe.calculator.maxLevel)if(e.worlds.add(b),Ie("ascension",k),e.goldenQuarksTimer+=E,Ie("octeracts",S),Ie("ambrosia",N),e.highestSingularityCount>=150&&(e.singularityUpgrades.goldenQuarks1.freeLevels+=.01*h,e.singularityUpgrades.goldenQuarks3.freeLevels+=.05*h),e.rngCode=x,r){Zo("add");return}else return P(u.t("importexport.promocodes.add.calculatorMaxed",{a:C,b:v,c:C+v,d:e.worlds.toString(b),e:L,f:T,g:I,h:re,i:X,j:B,k:U.toLocaleString()}));let w={w:e.worlds.toString(b),x:C,y:v,z:C+v},H=e.shopUpgrades.calculator>0?u.t("importexport.promocodes.add.calculatorSolution",w):u.t("importexport.promocodes.add.calculatorPrompt",w),J=await Ee(H);if(J===null)return P(u.t("importexport.promocodes.add.cancelled"));e.rngCode=x,C+v===+J?(e.worlds.add(b),Ie("ascension",k),e.goldenQuarksTimer+=E,Ie("octeracts",S),Ie("ambrosia",N),await P(u.t("importexport.promocodes.add.reward",{a:e.worlds.toString(b),b:L,c:T,d:I,e:B,f:U.toLocaleString(navigator.language)}))):await P(u.t("importexport.promocodes.add.wrong",{w:J,x:C+v,y:B,z:U.toLocaleString(navigator.language)}))}else if(t==="sub"){let a=1+window.crypto.getRandomValues(new Uint16Array(1))[0]%16,s=Number(e.worlds);await P(u.t("importexport.promocodes.sub.subbed",{x:a})),s1e4)return n.textContent=u.t("importexport.promocodes.gamble.cheaters");if(Number(e.worlds)66666&&(h=Math.pow(h,.35)*Math.pow(66666,.65)),e.visitedAmbrosiaSubtab&&(b=1800*s),e.worlds.add(h*s,!1),o.ambrosiaTimer+=b;let C=u.t("importexport.promocodes.time.won",{x:d(h*s,0,!0)}),v=b>0?u.t("importexport.promocodes.time.ambrosia",{blueberryTime:b}):"";return P(C+v)}else return P(u.t("importexport.promocodes.time.lost"))}}else if(t==="spoiler"){let a=Kr();return a>1?P(u.t("importexport.promocodes.spoiler.moreThan1",{x:d(a,2,!0)})):P(u.t("importexport.promocodes.spoiler.one",{x:d(1/a,2,!0)}))}else n.textContent=u.t("importexport.promocodes.invalid");vr()&&(Ct.emit("promocode",t),setTimeout(()=>n.textContent="",15e3))},Gl=()=>{let t=[10,16,25,36,49,64,81,100,121,144,169,196,225,235,240],r=0;for(let n=0;n=t[n];n++)r+=1;return 1+r/5},xo=()=>{let t=Math.floor(e.shopUpgrades.calculator5/10);e.shopUpgrades.calculator5===pe.calculator5.maxLevel&&(t+=6);let r=[24,2*e.shopUpgrades.calculator2,e.shopUpgrades.calculator4===pe.calculator4.maxLevel?32:0,t,e.shopUpgrades.calculator6===pe.calculator6.maxLevel?24:0,e.shopUpgrades.calculator7===pe.calculator7.maxLevel?48:0],n=ae(r);return n*=xe.ADD_CODE_CAP_BUFF,r.push(Gl()),n*=Gl(),{list:r,total:Math.ceil(n)}},Ha=()=>{let t=[LC,1-.04*e.shopUpgrades.calculator4,1-Math.min(.6,(e.highestSingularityCount>=125?e.highestSingularityCount/800:0)+(e.highestSingularityCount>=200?e.highestSingularityCount/800:0)),e.runelevels[6]>0?.8:1,1/Gl()];return{list:t,time:be(t)}},Xn=()=>{let t=xo().total,r=Ha().time;return Math.floor(Math.min(t,(Date.now()-e.rngCode)/r))},ml=()=>{let t=Math.floor(Ha().time+e.rngCode-Date.now())/1e3;if(t>0)return t;if(Xn()===xo().total)return 0;{let n=Date.now()-e.rngCode-Ha().time*Xn();return Math.floor(Ha().time-n)/1e3}},xu=()=>{let t=Gl(),r=1+.14*e.shopUpgrades.calculator;r*=e.shopUpgrades.calculator2===pe.calculator2.maxLevel?1.25:1,r/=t;let n=Math.max(.4+.02*e.shopUpgrades.calculator3,2/5+sd(na.PromoCodes,0,127)/640),a=.4+.02*e.shopUpgrades.calculator3,s=.6,l=r*Rt().perHour,c=e.singularityUpgrades.expertPack.level>0?1.2:1,p=60*e.shopUpgrades.calculator3*c/t,g=6*e.shopUpgrades.calculator5/t,m=e.shopUpgrades.calculator6/t,h=e.shopUpgrades.calculator7/t;return{quarks:n*l,minQuarks:a*l,maxQuarks:s*l,ascensionTimer:p,gqTimer:g,octeractTime:m,blueberryTime:h}},w0=()=>(Date.now()-e.promoCodeTiming.time)/1e3<900?0:1,AC=()=>900-(Date.now()-e.promoCodeTiming.time)/1e3,x0=()=>Math.min(24,(Date.now()-e.promoCodeTiming.time)/(1e3*3600)),EC=(t,r)=>{let n=t in F?u.t(`singularity.data.${t}.name`):u.t(`octeract.data.${t}.name`);return` ++${d(r,0,!0)} extra levels of '${n}'`},OC=()=>{let t=0,r=0,n=e.ascensionCount>0,a=e.highestSingularityCount>0;return(e.reincarnationCount>0||n||a)&&(t+=20),(e.challengecompletions[6]>0||n||a)&&(t+=20),(e.challengecompletions[7]>0||n||a)&&(t+=30),(e.challengecompletions[8]>0||n||a)&&(t+=30),(e.challengecompletions[9]>0||n||a)&&(t+=40),(e.challengecompletions[10]>0||n||a)&&(t+=60),(n||a)&&(t+=50),(e.challengecompletions[11]>0||a)&&(t+=50),(e.challengecompletions[12]>0||a)&&(t+=50),(e.challengecompletions[13]>0||a)&&(t+=50),(e.challengecompletions[14]>0||a)&&(t+=100),e.researches[200]===o.researchMaxLevels[200]&&(t+=250),e.cubeUpgrades[50]===1e5&&(t+=250),e.platonicUpgrades[5]>0&&(t+=250),e.platonicUpgrades[10]>0&&(t+=500),e.platonicUpgrades[15]>0&&(t+=750),e.challenge15Exponent>1e18&&(t+=Math.floor(1e3*(Math.log10(e.challenge15Exponent)-18))),e.platonicUpgrades[20]>0&&(t+=2500),t*=1+.05*e.shopUpgrades.shopImprovedDaily,t=Math.floor(t),a&&(r+=2+3*e.highestSingularityCount,r*=1+.2*e.shopUpgrades.shopImprovedDaily2,r*=1+.15*e.shopUpgrades.shopImprovedDaily3,r*=1+e.shopUpgrades.shopImprovedDaily4),{quarks:t,goldenQuarks:r}},UC=t=>{let r=localStorage.getItem("firstPlayed"),n=new Date(t);if(r===null){localStorage.setItem("firstPlayed",n.toISOString());return}new Date(r).getTime()>n.getTime()&&(e.firstPlayed=n.toISOString(),localStorage.setItem("firstPlayed",e.firstPlayed))};var Ke=class extends In{constructor(n,a){var c,p,g,m;let s=u.t(`ambrosia.data.${a}.name`),l=u.t(`ambrosia.data.${a}.description`);super(te(O({},n),{name:s,description:l}));this.ambrosiaInvested=0;this.blueberriesInvested=0;this.blueberryCost=n.blueberryCost,this.costFormula=n.costFormula,this.rewards=n.rewards,this.ambrosiaInvested=(c=n.ambrosiaInvested)!=null?c:0,this.blueberriesInvested=(p=n.blueberriesInvested)!=null?p:0,this.preRequisites=(g=n.prerequisites)!=null?g:void 0,this.cacheUpdates=(m=n.cacheUpdates)!=null?m:void 0}getCostTNL(){return this.level===this.maxLevel?0:this.costFormula(this.level,this.costPerLevel)}async buyLevel(n){let a=0,s=1,l=e.ambrosia;if(!this.checkPrerequisites())return P(u.t("ambrosia.prereqNotMetAlert"));if(n.shiftKey){s=1e6;let c=Number(await Ee(u.t("ambrosia.ambrosiaBuyPrompt",{amount:d(e.ambrosia,0,!0)})));if(isNaN(c)||!isFinite(c)||!Number.isInteger(c))return P(u.t("general.validation.finite"));if(c===-1)l=e.ambrosia;else{if(c<=0)return P(u.t("octeract.buyLevel.cancelPurchase"));l=c}l=Math.min(e.ambrosia,l)}if(this.maxLevel>0&&(s=Math.min(s,this.maxLevel-this.level)),s===0)return P(u.t("octeract.buyLevel.alreadyMax"));for(;s>0;){let c=this.getCostTNL();if(e.ambrosia1)return P(`${u.t("octeract.buyLevel.multiBuy",{n:d(a)})}`);this.updateUpgradeHTML(),this.updateCaches()}toString(){let n=this.getCostTNL(),a=this.maxLevel===-1?"":`/${d(this.maxLevel,0,!0)}`,s=this.maxLevel===this.level,l=s?"plum":"white",c=this.freeLevels>0?` [+${d(this.freeLevels,1,!0)}]`:"";this.freeLevels>this.level&&(c=`${c}${u.t("general.softCapped")}`);let p=n<=e.ambrosia,g=s?` ${u.t("general.maxed")}`:p?` ${u.t("general.affordable")}`:` ${u.t("octeract.buyLevel.cannotAfford")}`,m=u.t("ambrosia.prerequisite");if(this.preRequisites!==void 0){for(let[h,b]of Object.entries(this.preRequisites)){let C=h,v=e.blueberryUpgrades[C].level>=b?"green":"red",x=e.blueberryUpgrades[C].level>=b?"":u.t("ambrosia.prereqNotMet");m=`${m} ${e.blueberryUpgrades[C].name} lv.${b} ${x} |`}m=m.slice(0,-1)}return`${this.name} ${m} ${this.description} ${u.t("general.level")} ${d(this.level,0,!0)}${a}${c} ${this.rewardDesc} ${u.t("octeract.toString.costNextLevel")}: ${d(n,2,!0,!0,!0)} ${u.t("ambrosia.ambrosia")} ${g} ${u.t("ambrosia.blueberryCost")} ${this.blueberryCost} - ${u.t("general.spent")} ${u.t("ambrosia.ambrosia")}: ${d(this.ambrosiaInvested,2,!0,!0,!0)}`}updateUpgradeHTML(){i("singularityAmbrosiaMultiline").innerHTML=this.toString(),vs()}checkPrerequisites(){if(this.preRequisites!==void 0)for(let[n,a]of Object.entries(this.preRequisites)){let s=n;if(e.blueberryUpgrades[s].levelr*(Math.pow(t+1,2)-Math.pow(t,2)),rewards:t=>{let r=1+.05*t,n=1+.01*t;return{quarks:n,cubes:r,desc:String(u.t("ambrosia.data.ambrosiaTutorial.effect",{cubeAmount:d(100*(r-1),0,!0),quarkAmount:d(100*(n-1),0,!0)}))}}},ambrosiaQuarks1:{maxLevel:100,costPerLevel:1,blueberryCost:0,costFormula:(t,r)=>r*(Math.pow(t+1,3)-Math.pow(t,3)),rewards:t=>{let r=1+.01*t;return{quarks:r,desc:String(u.t("ambrosia.data.ambrosiaQuarks1.effect",{amount:d(100*(r-1),0,!0)}))}},prerequisites:{ambrosiaTutorial:10}},ambrosiaCubes1:{maxLevel:100,costPerLevel:1,blueberryCost:0,costFormula:(t,r)=>r*(Math.pow(t+1,3)-Math.pow(t,3)),rewards:t=>{let r=(1+.05*t)*Math.pow(1.1,Math.floor(t/10));return{cubes:r,desc:String(u.t("ambrosia.data.ambrosiaCubes1.effect",{amount:d(100*(r-1),2,!0)}))}},prerequisites:{ambrosiaTutorial:10}},ambrosiaLuck1:{maxLevel:100,costPerLevel:1,blueberryCost:0,costFormula:(t,r)=>r*(Math.pow(t+1,3)-Math.pow(t,3)),rewards:t=>{let r=2*t+12*Math.floor(t/10);return{ambrosiaLuck:r,desc:String(u.t("ambrosia.data.ambrosiaLuck1.effect",{amount:d(r)}))}},prerequisites:{ambrosiaTutorial:10},cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaLuck=Ge().value}]},ambrosiaQuarkCube1:{maxLevel:25,costPerLevel:250,blueberryCost:1,costFormula:(t,r)=>r*(Math.pow(t+1,3)-Math.pow(t,3)),rewards:t=>{let n=1+5e-4*t*Math.floor(Math.pow(Math.log10(Number(e.worlds)+1)+1,2));return{cubes:n,desc:String(u.t("ambrosia.data.ambrosiaQuarkCube1.effect",{amount:d(100*(n-1),2,!0)}))}},prerequisites:{ambrosiaCubes1:30,ambrosiaQuarks1:20}},ambrosiaLuckCube1:{maxLevel:25,costPerLevel:250,blueberryCost:1,costFormula:(t,r)=>r*(Math.pow(t+1,3)-Math.pow(t,3)),rewards:t=>{let n=1+2e-4*t*o.ambrosiaCurrStats.ambrosiaLuck;return{cubes:n,desc:String(u.t("ambrosia.data.ambrosiaLuckCube1.effect",{amount:d(100*(n-1),2,!0)}))}},prerequisites:{ambrosiaCubes1:30,ambrosiaLuck1:20}},ambrosiaCubeQuark1:{maxLevel:25,costPerLevel:500,blueberryCost:1,costFormula:(t,r)=>r*(Math.pow(t+1,3)-Math.pow(t,3)),rewards:t=>{let n=1+1e-4*t*(Math.floor(Math.log10(Number(e.wowCubes)+1))+Math.floor(Math.log10(Number(e.wowTesseracts)+1))+Math.floor(Math.log10(Number(e.wowHypercubes)+1))+Math.floor(Math.log10(Number(e.wowPlatonicCubes)+1))+Math.floor(Math.log10(e.wowAbyssals+1))+Math.floor(Math.log10(e.wowOcteracts+1))+6);return{quarks:n,desc:String(u.t("ambrosia.data.ambrosiaCubeQuark1.effect",{amount:d(100*(n-1),2,!0)}))}},prerequisites:{ambrosiaQuarks1:30,ambrosiaCubes1:20}},ambrosiaLuckQuark1:{maxLevel:25,costPerLevel:500,blueberryCost:1,costFormula:(t,r)=>r*(Math.pow(t+1,3)-Math.pow(t,3)),rewards:t=>{let r=1e-4*t,n=Math.min(o.ambrosiaCurrStats.ambrosiaLuck,Math.pow(1e3,.5)*Math.pow(o.ambrosiaCurrStats.ambrosiaLuck,.5)),a=1+r*n;return{quarks:a,desc:String(u.t("ambrosia.data.ambrosiaLuckQuark1.effect",{amount:d(100*(a-1),2,!0)}))}},prerequisites:{ambrosiaQuarks1:30,ambrosiaLuck1:20}},ambrosiaCubeLuck1:{maxLevel:25,costPerLevel:100,blueberryCost:1,costFormula:(t,r)=>r*(Math.pow(t+1,3)-Math.pow(t,3)),rewards:t=>{let n=.02*t*(Math.floor(Math.log10(Number(e.wowCubes)+1))+Math.floor(Math.log10(Number(e.wowTesseracts)+1))+Math.floor(Math.log10(Number(e.wowHypercubes)+1))+Math.floor(Math.log10(Number(e.wowPlatonicCubes)+1))+Math.floor(Math.log10(e.wowAbyssals+1))+Math.floor(Math.log10(e.wowOcteracts+1))+6);return{ambrosiaLuck:n,desc:String(u.t("ambrosia.data.ambrosiaCubeLuck1.effect",{amount:d(n,2,!0)}))}},prerequisites:{ambrosiaLuck1:30,ambrosiaCubes1:20},cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaLuck=Ge().value}]},ambrosiaQuarkLuck1:{maxLevel:25,costPerLevel:100,blueberryCost:1,costFormula:(t,r)=>r*(Math.pow(t+1,3)-Math.pow(t,3)),rewards:t=>{let n=.02*t*Math.floor(Math.pow(Math.log10(Number(e.worlds)+1)+1,2));return{ambrosiaLuck:n,desc:String(u.t("ambrosia.data.ambrosiaQuarkLuck1.effect",{amount:d(n,2,!0)}))}},prerequisites:{ambrosiaLuck1:30,ambrosiaQuarks1:20},cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaLuck=Ge().value}]},ambrosiaQuarks2:{maxLevel:100,costPerLevel:500,blueberryCost:1,costFormula:(t,r)=>r*(Math.pow(t+1,2)-Math.pow(t,2)),rewards:t=>{let r=1+(.01+Math.floor(e.blueberryUpgrades.ambrosiaQuarks1.level/10)/1e3)*t;return{quarks:r,desc:String(u.t("ambrosia.data.ambrosiaQuarks2.effect",{amount:d(100*(r-1),0,!0)}))}},prerequisites:{ambrosiaQuarks1:40}},ambrosiaCubes2:{maxLevel:100,costPerLevel:500,blueberryCost:1,costFormula:(t,r)=>r*(Math.pow(t+1,2)-Math.pow(t,2)),rewards:t=>{let r=(1+(.06+6*(Math.floor(e.blueberryUpgrades.ambrosiaCubes1.level/10)/1e3))*t)*Math.pow(1.13,Math.floor(t/10));return{cubes:r,desc:String(u.t("ambrosia.data.ambrosiaCubes2.effect",{amount:d(100*(r-1),2,!0)}))}},prerequisites:{ambrosiaCubes1:40}},ambrosiaLuck2:{maxLevel:100,costPerLevel:250,blueberryCost:1,costFormula:(t,r)=>r*(Math.pow(t+1,2)-Math.pow(t,2)),rewards:t=>{let r=(3+.3*Math.floor(e.blueberryUpgrades.ambrosiaLuck1.level/10))*t+40*Math.floor(t/10);return{ambrosiaLuck:r,desc:String(u.t("ambrosia.data.ambrosiaLuck2.effect",{amount:d(r,1,!0)}))}},prerequisites:{ambrosiaLuck1:40},cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaLuck=Ge().value}]},ambrosiaPatreon:{maxLevel:1,costPerLevel:1,blueberryCost:0,costFormula:(t,r)=>r*(Math.pow(t+1,2)-Math.pow(t,2)),rewards:t=>{let r=1+t*er()/100;return{blueberryGeneration:r,desc:String(u.t("ambrosia.data.ambrosiaPatreon.effect",{amount:d(100*(r-1),0,!0)}))}},cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value}]},ambrosiaObtainium1:{maxLevel:2,costPerLevel:5e4,blueberryCost:1,costFormula:(t,r)=>r*Math.pow(25,t),rewards:t=>{let r=o.ambrosiaCurrStats.ambrosiaLuck;return{luckMult:t,obtainiumMult:t*r,desc:String(u.t("ambrosia.data.ambrosiaObtainium1.effect",{amount:d(t*r/10,1,!0)}))}}},ambrosiaOffering1:{maxLevel:2,costPerLevel:5e4,blueberryCost:1,costFormula:(t,r)=>r*Math.pow(25,t),rewards:t=>{let r=o.ambrosiaCurrStats.ambrosiaLuck;return{luckMult:t,offeringMult:t*r,desc:String(u.t("ambrosia.data.ambrosiaOffering1.effect",{amount:d(t*r/10,1,!0)}))}}},ambrosiaHyperflux:{maxLevel:7,costPerLevel:33333,blueberryCost:3,costFormula:(t,r)=>(r+33333*Math.min(4,t))*Math.max(1,Math.pow(3,t-4)),rewards:t=>{let r=t;return{hyperFlux:Math.pow(1+1/100*r,e.platonicUpgrades[19]),desc:String(u.t("ambrosia.data.ambrosiaHyperflux.effect",{amount:d(100*(Math.pow(1+r/100,e.platonicUpgrades[19])-1))}))}}}},Rl=()=>{let t=8+xe.AMBROSIA_LOADOUT_SLOT_QOL;Nn(t<=16,"Yeah. Nice try.");for(let r=1;r<=16;r++){let n=i(`blueberryLoadout${r}`);r<=t?n.style.display="flex":n.style.display="none"}},rd=async(t=!0)=>{for(let r of Object.keys(e.blueberryUpgrades)){let n=r;e.blueberryUpgrades[n].refund(),e.blueberryUpgrades[n].updateCaches()}if(t)return P(u.t("ambrosia.refund"))},yC=t=>{var g;if(Object.keys(t).length===0)return!1;let r=e.lifetimeAmbrosia,n=o.ambrosiaCurrStats.ambrosiaBlueberries,a=0,s=0,l=!0,c=!0,p=!0;for(let[m,h]of Object.entries(t)){let b=m;if(h<0||!Number.isFinite(h)||!Number.isInteger(h)||Number.isNaN(h)||e.blueberryUpgrades[b]===void 0)return!1;let C=Math.min(e.blueberryUpgrades[b].maxLevel,h),v=e.blueberryUpgrades[b].preRequisites;if(v!==void 0&&h>0)for(let[x,B]of Object.entries(v))((g=t[x])!=null?g:-1)0&&(s+=e.blueberryUpgrades[b].blueberryCost),C>0){let x=e.blueberryUpgrades[b].costFormula,B=e.blueberryUpgrades[b].costPerLevel,U=0;for(let k=0;k=a,p=n>=s,l&&c&&p},d0=()=>Object.fromEntries(Object.entries(e.blueberryUpgrades).map(([t,r])=>[t,r.level])),vC=t=>Object.fromEntries(Object.entries(t).map(([r,n])=>[r,Math.min(n,e.blueberryUpgrades[r].maxLevel)])),p0=()=>{let t=d0(),r=JSON.stringify(t),n=`BBTree-${qo()}`;Yu(r,n)},g0=async t=>{if(!yC(t)){P(u.t("ambrosia.importTree.failure"));return}await rd(!1);let n=vC(t);for(let[a,s]of Object.entries(n)){let l=a,{costFormula:c,costPerLevel:p,blueberryCost:g}=e.blueberryUpgrades[l];if(s>0){e.blueberryUpgrades[l].blueberriesInvested=g,e.spentBlueberries+=g;let m=0;for(let h=0;h{if(typeof t!="string")return P(u.t("importexport.unableImport"));try{let r=JSON.parse(t);await g0(r),Il(0,r)}catch(r){return P(u.t("ambrosia.importTree.error"))}},f0=async(t,r)=>{e.blueberryLoadoutMode==="saveTree"&&await CC(t,r),e.blueberryLoadoutMode==="loadTree"&&await g0(r)},nd=()=>{var r,n;let t=Object.keys($e);for(let a of Object.keys(e.blueberryLoadouts)){let s=Number.parseInt(a,10),l=e.blueberryLoadouts[s],c=`bbPurchasedLoadout${s}`;for(let p of t)l[p]?(r=i(p).parentElement)==null||r.classList.add(c):(n=i(p).parentElement)==null||n.classList.remove(c)}},CC=async(t,r)=>{Object.keys(r).length>0&&!await we(u.t("ambrosia.loadouts.confirmation"))||(e.blueberryLoadouts[t]=d0(),Il(t,e.blueberryLoadouts[t]),nd())},Il=(t,r)=>{let n="";for(let[s,l]of Object.entries(r)){if(!l)continue;let c=s,p=e.blueberryUpgrades[c].name;n=`${n}${p} lv${l} | `}Object.keys(r).length===0&&(n=u.t("ambrosia.loadouts.none"));let a=`${u.t("ambrosia.loadouts.loadout")} ${t}`;t===0&&(a=u.t("ambrosia.loadouts.imported")),i("singularityAmbrosiaMultiline").innerHTML=` ${a} - ${n}`},h0=()=>{let r=Object.keys(e.blueberryLoadouts).length;if(r<16)for(let n=r+1;n<=16;n++)e.blueberryLoadouts[n]={}};var Nl={INSTANT_UNLOCK_1:0,INSTANT_UNLOCK_2:0,CUBE_BUFF:0,AMBROSIA_LUCK_BUFF:0,AMBROSIA_GENERATION_BUFF:0,GOLDEN_QUARK_BUFF:0,FREE_UPGRADE_PROMOCODE_BUFF:0,CORRUPTION_LOADOUT_SLOT_QOL:0,AMBROSIA_LOADOUT_SLOT_QOL:0,AUTO_POTION_FREE_POTIONS_QOL:0,OFFLINE_TIMER_CAP_BUFF:0,ADD_CODE_CAP_BUFF:0},xe={INSTANT_UNLOCK_1:0,INSTANT_UNLOCK_2:0,CUBE_BUFF:1,AMBROSIA_LUCK_BUFF:0,AMBROSIA_GENERATION_BUFF:1,GOLDEN_QUARK_BUFF:1,FREE_UPGRADE_PROMOCODE_BUFF:1,CORRUPTION_LOADOUT_SLOT_QOL:0,AMBROSIA_LOADOUT_SLOT_QOL:0,AUTO_POTION_FREE_POTIONS_QOL:0,OFFLINE_TIMER_CAP_BUFF:1,ADD_CODE_CAP_BUFF:1},b0=async()=>{let r=await(await fetch("https://synergism.cc/stripe/upgrades")).json();for(let n of Object.keys(Nl))Nl[n]=0,ad(n,0);for(let n of r.playerUpgrades)Nl[n.internalName]=n.level,ad(n.internalName,n.level)},Ff=async(t,r)=>{Nl[t]=r,ad(t,r)},ad=(t,r)=>{switch(t){case"INSTANT_UNLOCK_1":xe.INSTANT_UNLOCK_1=r>0?1:0;break;case"INSTANT_UNLOCK_2":xe.INSTANT_UNLOCK_2=r>0?1:0;break;case"CUBE_BUFF":xe.CUBE_BUFF=1+r*.06;break;case"AMBROSIA_LUCK_BUFF":xe.AMBROSIA_LUCK_BUFF=r*20;break;case"AMBROSIA_GENERATION_BUFF":xe.AMBROSIA_GENERATION_BUFF=1+r*.05;break;case"GOLDEN_QUARK_BUFF":xe.GOLDEN_QUARK_BUFF=1+r*.04;break;case"FREE_UPGRADE_PROMOCODE_BUFF":xe.FREE_UPGRADE_PROMOCODE_BUFF=1+r*.02;break;case"CORRUPTION_LOADOUT_SLOT_QOL":xe.CORRUPTION_LOADOUT_SLOT_QOL=r,$l(),Is();break;case"AMBROSIA_LOADOUT_SLOT_QOL":xe.AMBROSIA_LOADOUT_SLOT_QOL=r,Rl();break;case"AUTO_POTION_FREE_POTIONS_QOL":xe.AUTO_POTION_FREE_POTIONS_QOL=r>0?1:0;break;case"OFFLINE_TIMER_CAP_BUFF":xe.OFFLINE_TIMER_CAP_BUFF=1+r;break;case"ADD_CODE_CAP_BUFF":xe.ADD_CODE_CAP_BUFF=1+r;break}},qu=(t,r)=>{switch(t){case"INSTANT_UNLOCK_1":return String(u.t("pseudoCoins.upgradeEffects.INSTANT_UNLOCK_1",{descriptor:r>0?"":"NOT",amount:10*r}));case"INSTANT_UNLOCK_2":return String(u.t("pseudoCoins.upgradeEffects.INSTANT_UNLOCK_2",{descriptor:r>0?"":"NOT",amount:6*r}));case"CUBE_BUFF":return String(u.t("pseudoCoins.upgradeEffects.CUBE_BUFF",{amount:d(1+.06*r,2,!0)}));case"AMBROSIA_LUCK_BUFF":return String(u.t("pseudoCoins.upgradeEffects.AMBROSIA_LUCK_BUFF",{amount:20*r}));case"AMBROSIA_GENERATION_BUFF":return String(u.t("pseudoCoins.upgradeEffects.AMBROSIA_GENERATION_BUFF",{amount:d(1+.05*r,2,!0)}));case"GOLDEN_QUARK_BUFF":return String(u.t("pseudoCoins.upgradeEffects.GOLDEN_QUARK_BUFF",{amount:d(1+.04*r,2,!0)}));case"FREE_UPGRADE_PROMOCODE_BUFF":return String(u.t("pseudoCoins.upgradeEffects.FREE_UPGRADE_PROMOCODE_BUFF",{amount:d(1+.02*r,2,!0)}));case"CORRUPTION_LOADOUT_SLOT_QOL":return String(u.t("pseudoCoins.upgradeEffects.CORRUPTION_LOADOUT_SLOT_QOL",{amount:r}));case"AMBROSIA_LOADOUT_SLOT_QOL":return String(u.t("pseudoCoins.upgradeEffects.AMBROSIA_LOADOUT_SLOT_QOL",{amount:r}));case"AUTO_POTION_FREE_POTIONS_QOL":return String(u.t("pseudoCoins.upgradeEffects.AUTO_POTION_FREE_POTIONS_QOL",{descriptor:r>0?"":"NOT"}));case"OFFLINE_TIMER_CAP_BUFF":return String(u.t("pseudoCoins.upgradeEffects.OFFLINE_TIMER_CAP_BUFF",{amount:r+1}));case"ADD_CODE_CAP_BUFF":return String(u.t("pseudoCoins.upgradeEffects.ADD_CODE_CAP_BUFF",{amount:r+1}))}},Qf=t=>{switch(t){case"INSTANT_UNLOCK_1":return{cost:"Cost: 400 PseudoCoins",effect:"Effect: +10 Levels"};case"INSTANT_UNLOCK_2":return{cost:"Cost: 600 PseudoCoins",effect:"Effect: +6 Levels"};case"CUBE_BUFF":return{cost:"Cost: 100/150/200/250/300 PseudoCoins",effect:"Effect: 1.06/1.12/1.18/1.24/1.30x Cubes"};case"AMBROSIA_LUCK_BUFF":return{cost:"Cost: 100/150/200/250/300 PseudoCoins",effect:"Effect: 20/40/60/80/100 Ambrosia Luck"};case"AMBROSIA_GENERATION_BUFF":return{cost:"Cost: 100/150/200/250/300 PseudoCoins",effect:"Effect: 1.05/1.10/1.15/1.20/1.25x Ambrosia Generation"};case"GOLDEN_QUARK_BUFF":return{cost:"Cost: 100/150/200/250/300 PseudoCoins",effect:"Effect: 1.04/1.08/1.12/1.16/1.20x Golden Quarks"};case"FREE_UPGRADE_PROMOCODE_BUFF":return{cost:"Cost: 100/150/200/250/300 PseudoCoins",effect:"Effect: 1.02/1.04/1.06/1.08/1.10x Free Upgrade Promocodes"};case"CORRUPTION_LOADOUT_SLOT_QOL":return{cost:"Cost: 125/per PseudoCoins",effect:"Effect: +1 Loadout Slot per level"};case"AMBROSIA_LOADOUT_SLOT_QOL":return{cost:"Cost: 125/per PseudoCoins",effect:"Effect: +1 Loadout Slot per level"};case"AUTO_POTION_FREE_POTIONS_QOL":return{cost:"Cost: 500 PseudoCoins",effect:"Effect: Auto Potion gives free potions"};case"OFFLINE_TIMER_CAP_BUFF":return{cost:"Cost: 400/600 PseudoCoins",effect:"Effect: 2x/3x Offline Time Cap"};case"ADD_CODE_CAP_BUFF":return{cost:"Cost: 400/600 PseudoCoins",effect:"Effect: 2x/3x Add Code Cap"}}};var $a=()=>{let t=0;return e.challengecompletions[11]>0&&(t+=5),e.challengecompletions[12]>0&&(t+=2),e.challengecompletions[13]>0&&(t+=2),e.challengecompletions[14]>0&&(t+=2),e.platonicUpgrades[5]>0&&(t+=1),e.platonicUpgrades[10]>0&&(t+=1),e.singularityUpgrades.platonicTau.getEffect().bonus&&(t=Math.max(13,t)),e.singularityUpgrades.corruptionFourteen.getEffect().bonus&&(t+=1),t+=+e.octeractUpgrades.octeractCorruption.getEffect().bonus,t},Na=t=>{i("corruptionDetails").style.visibility!=="visible"&&(i("corruptionDetails").style.visibility="visible"),i("corruptionSelectedPic").style.visibility!=="visible"&&(i("corruptionSelectedPic").style.visibility="visible"),o.corruptionTrigger=t;let r=t===2&&e.usedCorruptions[t]>=10?1+.04*e.platonicUpgrades[17]+2*Math.min(1,e.platonicUpgrades[17]):1,n=t===2&&e.prototypeCorruptions[t]>=10?1+.04*e.platonicUpgrades[17]+2*Math.min(1,e.platonicUpgrades[17]):1,a=e.singularityUpgrades.corruptionFifteen.level>0?1:0;a+=+e.singularityChallenges.oneChallengeCap.rewards.freeCorruptionLevel;let s=a>0?`[+${a}]`:"",l=[o.viscosityPower,o.lazinessMultiplier,o.hyperchallengedMultiplier,o.illiteracyPower,o.deflationMultiplier,o.extinctionMultiplier,o.droughtMultiplier,o.financialcollapsePower,[0]],c=["/CorruptViscocity.png","/CorruptSpatialDilation.png","/CorruptHyperchallenged.png","/CorruptScientificIlliteracy.png","/CorruptDeflation.png","/CorruptExtinction.png","/CorruptDrought.png","/CorruptFinancialCollapse.png"],p={name:u.t("corruptions.exitCorruption.name"),description:u.t("corruptions.exitCorruption.description"),current:u.t("corruptions.exitCorruption.current"),planned:u.t("corruptions.exitCorruption.planned"),multiplier:u.t("corruptions.exitCorruption.multiplier"),spiritContribution:"",image:`Pictures/${Be[e.iconSet][0]}/CorruptExit.png`};t<10&&(p={name:u.t(`corruptions.names.${t-1}`),description:u.t(`corruptions.descriptions.${t-1}`),current:u.t(`corruptions.currentLevel.${t-1}`,{level:d(e.usedCorruptions[t])+s,effect:d(l[t-2][e.usedCorruptions[t]],3)}),planned:u.t(`corruptions.prototypeLevel.${t-1}`,{level:d(e.prototypeCorruptions[t])+s,effect:d(l[t-2][e.prototypeCorruptions[t]],3)}),multiplier:u.t("corruptions.scoreMultiplier",{curr:d(Math.pow(o.corruptionPointMultipliers[e.usedCorruptions[t]+a],r),1),next:d(Math.pow(o.corruptionPointMultipliers[e.prototypeCorruptions[t]+a],n),1)}),spiritContribution:u.t("corruptions.spiritEffect",{curr:d(4*Math.pow(e.usedCorruptions[t]+a,2),1),next:d(4*Math.pow(e.prototypeCorruptions[t]+a,2),1)}),image:`Pictures/${Be[e.iconSet][0]}${c[t-2]}`}),i("corruptionName").textContent=p.name,i("corruptionDescription").textContent=p.description,i("corruptionLevelCurrent").textContent=p.current,i("corruptionLevelPlanned").textContent=p.planned,i("corruptionMultiplierContribution").textContent=p.multiplier,i("corruptionSpiritContribution").textContent=p.spiritContribution,i("corruptionSelectedPic").setAttribute("src",p.image),t<10&&(i(`corrCurrent${t}`).textContent=d(e.usedCorruptions[t]),i(`corrNext${t}`).textContent=d(e.prototypeCorruptions[t]))},Ga=()=>{for(let t=2;t<=9;t++){if(!fi(`corrCurrent${t}`))continue;let r=i(`corrCurrent${t}`),n=i(`corrNext${t}`);r.textContent=d(e.usedCorruptions[t]),n.textContent=d(e.prototypeCorruptions[t])}},y0=()=>{let t=document.getElementsByClassName("corruptionStatRow");for(let r=0;r=1;p--)n.children[p].remove();let a=document.createElement("p");a.className="corrDesc";let s=document.createTextNode(u.t("corruptions.current"));a.appendChild(s);let l=document.createElement("span");l.id=`corrCurrent${r+2}`,l.textContent=`${e.usedCorruptions[r+2]}`,a.appendChild(l),s=document.createTextNode(u.t("corruptions.next")),a.appendChild(s),l=document.createElement("span"),l.id=`corrNext${r+2}`,l.textContent=`${e.prototypeCorruptions[r+2]}`,a.appendChild(l),n.appendChild(a);let c;c=document.createElement("button"),c.className="corrBtn corruptionMax",c.textContent=`+${u.t("corruptions.max")}`,c.addEventListener("click",()=>hn(r+2,99)),n.appendChild(c),c=document.createElement("button"),c.className="corrBtn corruptionUp",c.textContent="+1",c.addEventListener("click",()=>hn(r+2,1)),n.appendChild(c),c=document.createElement("button"),c.className="corrBtn corruptionDown",c.textContent="-1",c.addEventListener("click",()=>hn(r+2,-1)),n.appendChild(c),c=document.createElement("button"),c.className="corrBtn corruptionReset",c.textContent=`-${u.t("corruptions.max")}`,c.addEventListener("click",()=>hn(r+2,-99)),n.appendChild(c),n.addEventListener("click",()=>Na(r+2))}},$l=()=>{let r=an("corruptionLoadoutTable");for(let a=r.rows.length-1;a>=1;a--)r.deleteRow(a);let n=8+xe.CORRUPTION_LOADOUT_SLOT_QOL;for(let a=0;avoid MC()),c.classList.add("corrLoadoutName"),c.title=u.t("corruptions.loadoutTable.firstRowTitle")):c.title=u.t("corruptions.loadoutTable.otherRowTitle",{value:a}):l<=8&&(a===0?c.textContent=e.prototypeCorruptions[l+1].toString():c.textContent=e.corruptionLoadouts[a][l+1].toString())}if(a===0){let l=s.insertCell(),c=document.createElement("button");c.className="corrImport",c.textContent=u.t("corruptions.loadoutTable.import"),c.addEventListener("click",()=>void wC()),l.appendChild(c),l.title=u.t("corruptions.importLoadoutInTextFormat"),l=s.insertCell(),c=document.createElement("button"),c.className="corrLoad",c.textContent=u.t("corruptions.loadoutTable.zero"),c.addEventListener("click",()=>Ns(!1,a)),l.appendChild(c),l.title=u.t("corruptions.loadoutTable.zeroTitle")}else{let l=s.insertCell(),c=document.createElement("button");c.className="corrSave",c.textContent=u.t("corruptions.loadoutTable.save"),c.addEventListener("click",()=>Ns(!0,a)),l.appendChild(c),l.title=u.t("corruptions.loadoutTable.saveTitle"),l=s.insertCell(),c=document.createElement("button"),c.className="corrLoad",c.textContent=u.t("corruptions.loadoutTable.load"),c.addEventListener("click",()=>Ns(!1,a)),l.appendChild(c)}}Is(),Ga()},_a=(t=0)=>{let r=an("corruptionLoadoutTable").rows[t+1].cells;for(let n=1;n8);n++)r[n].textContent=(t===0?e.prototypeCorruptions[n+1]:e.corruptionLoadouts[t][n+1]).toString()},Ns=(t=!0,r=1)=>{t?(e.corruptionLoadouts[r]=Array.from(e.prototypeCorruptions),_a(r)):(r===0?e.prototypeCorruptions=[0,0,0,0,0,0,0,0,0,0,0,0,0]:e.prototypeCorruptions=Array.from(e.corruptionLoadouts[r]),_a(),Ga())},sd=t=>{if(t.includes("/")&&t.split("/").length===13){let r=t.split("/").map(n=>Number(n));for(let n of r)if(!Number.isInteger(n)||Number.isNaN(n)||n<0||n>$a())return!1;return e.prototypeCorruptions=r,_a(),Ga(),!0}return!1};async function wC(){let t=await Ee(u.t("corruptions.importCorruptionsPrompt.import"));sd(`0/0/${t}/0/0/0`)||P(u.t("corruptions.importCorruptionsPrompt.importError"))}async function xC(t=0){let n=/^[\x00-\xFF]*$/,a=await Ee(u.t("corruptions.corruptionLoadoutName.loadoutPrompt",{loadNum:t+1,maxChars:9}));if(a){if(a.length>9)return P(u.t("corruptions.corruptionLoadoutName.errors.exceedsCharacterLimit"));if(n.test(a)){if(e.corruptionLoadoutNames[t]=a,Is(),a==="crazy")return P(u.t("corruptions.corruptionLoadoutName.errors.crazyJoke"))}else return P(u.t("corruptions.corruptionLoadoutName.errors.regexError"))}else return P(u.t("corruptions.corruptionLoadoutName.errors.noName"))}var Is=()=>{let t=an("corruptionLoadoutTable").rows,r=8+xe.CORRUPTION_LOADOUT_SLOT_QOL;for(let n=0;nvoid xC(n)),a[0].classList.add("corrLoadoutName")),a[0].textContent=`${e.corruptionLoadoutNames[n]}:`}},MC=async()=>{let t=e.prototypeCorruptions.slice(2,10).join("/");"clipboard"in navigator?await navigator.clipboard.writeText(t).catch(r=>P(u.t("corruptions.loadoutExport.saveErrorNavigator",{message:r.message}))):P(u.t("corruptions.loadoutExport.saveErrorNavigator",{message:t}))},v0=()=>{let r=Object.keys(e.corruptionLoadouts).length;if(r<16)for(let n=r+1;n<=16;n++)e.corruptionLoadouts[n]=Array(13).fill(0),e.corruptionLoadoutNames.push(`Loadout ${n}`)},C0=()=>{let t=i("corruptionCleanseConfirm");t.style.visibility="visible",setTimeout(()=>t.style.visibility="hidden",1e4)},w0=()=>{let t=document.getElementsByClassName("corruptionStatRow");for(let l=0;l0||e.singularityUpgrades.platonicTau.getEffect().bonus)for(let l=0;l0||e.singularityUpgrades.platonicTau.getEffect().bonus)for(let l=0;l0||e.singularityUpgrades.platonicTau.getEffect().bonus)for(let l=0;l0||e.singularityUpgrades.platonicTau.getEffect().bonus)for(let l=0;l{let t=document.getElementsByClassName("coinunlock1");for(let A=0;A0?L[A].style.display="block":L[A].style.display="none";let E=document.getElementsByClassName("chal10");for(let A=0;A0?"flex":"none":T[A].style.display=e.ascensionCount>0?"block":"none";let S=document.getElementsByClassName("chal11");for(let A=0;A0?S[A].style.display="block":S[A].style.display="none";let I=document.getElementsByClassName("chal12");for(let A=0;A0?I[A].style.display="block":I[A].style.display="none";let N=document.getElementsByClassName("chal13");for(let A=0;A0?N[A].style.display="block":N[A].style.display="none";let X=document.getElementsByClassName("chal14");for(let A=0;A0?X[A].style.display="block":X[A].style.display="none";let re=document.getElementsByClassName("ascendunlockib");for(let A=0;A0?"inline-block":"none";let w=document.getElementsByClassName("prestigeunlockib");for(let A=0;A0?"block":"none";let J=document.getElementsByClassName("cubeUpgrade10");for(let A=0;A0?"flex":"none";let Te=document.getElementsByClassName("cubeUpgrade19");for(let A=0;A0?"block":"none";let lt=document.getElementsByClassName("sacrificeAnts");for(let A of Array.from(lt))A.style.display=e.achievements[173]===1?"block":"none";let gt=document.getElementsByClassName("hepteracts");for(let A of Array.from(gt))A.style.display=e.challenge15Exponent>=1e15?"block":"none";let Ct=document.getElementsByClassName("singularity");for(let A of Array.from(Ct)){let Pt=Number(A.getAttribute("count"))||1;A.style.display=e.highestSingularityCount>=Pt?"block":"none"}let $t=document.getElementsByClassName("isEvent");for(let A of Array.from($t))A.style.display=o.isEvent?"block":"none";Cu();let Yt=i("corruptionHepteracts");Yt.style.display=e.achievements[255]>0?"block":"none";let _t=document.getElementsByClassName("assortedCookies1"),ce=document.getElementsByClassName("assortedCookies2"),z=document.getElementsByClassName("assortedCookies3"),Z=document.getElementsByClassName("assortedCookies4"),se=document.getElementsByClassName("assortedCookies5");for(let A of Array.from(_t))A.style.display=e.singularityUpgrades.cookies.getEffect().bonus?"block":"none";for(let A of Array.from(ce))A.style.display=e.singularityUpgrades.cookies2.getEffect().bonus?"block":"none";for(let A of Array.from(z))A.style.display=e.singularityUpgrades.cookies3.getEffect().bonus?"block":"none";for(let A of Array.from(Z))A.style.display=e.singularityUpgrades.cookies4.getEffect().bonus?"block":"none";for(let A of Array.from(se))A.style.display=e.singularityUpgrades.cookies5.getEffect().bonus?"block":"none";let ne=document.getElementsByClassName("goldenQuark3Upg");for(let A of Array.from(ne))A.style.display=e.singularityUpgrades.goldenQuarks3.getEffect().bonus>0?"block":"none";e.upgrades[89]===1?(i("transcendautotoggle").style.display="block",i("transcendamount").style.display="block",i("autotranscend").style.display="block"):(i("transcendautotoggle").style.display="none",i("transcendamount").style.display="none",i("autotranscend").style.display="none"),e.achievements[38]===1?(i("rune2area").style.display="flex",i("runeshowpower2").style.display="block"):(i("rune2area").style.display="none",i("runeshowpower2").style.display="none"),e.achievements[43]===1?(i("prestigeautotoggle").style.display="block",i("prestigeamount").style.display="block",i("autoprestige").style.display="block"):(i("prestigeautotoggle").style.display="none",i("prestigeamount").style.display="none",i("autoprestige").style.display="none"),e.achievements[44]===1?(i("rune3area").style.display="flex",i("runeshowpower3").style.display="block"):(i("rune3area").style.display="none",i("runeshowpower3").style.display="none"),e.achievements[102]===1?(i("rune4area").style.display="flex",i("runeshowpower4").style.display="block"):(i("rune4area").style.display="none",i("runeshowpower4").style.display="none"),e.achievements[119]===1?i("talisman1area").style.display="flex":i("talisman1area").style.display="none",e.achievements[126]===1?i("talisman2area").style.display="flex":i("talisman2area").style.display="none",e.achievements[133]===1?i("talisman3area").style.display="flex":i("talisman3area").style.display="none",e.achievements[134]===1?(i("toggleRuneSubTab2").style.display="block",i("toggleRuneSubTab3").style.display="block"):(i("toggleRuneSubTab2").style.display="none",i("toggleRuneSubTab3").style.display="none"),e.achievements[140]===1?i("talisman4area").style.display="flex":i("talisman4area").style.display="none",e.achievements[147]===1?i("talisman5area").style.display="flex":i("talisman5area").style.display="none",e.achievements[173]===1?i("sacrificeAnts").style.display="block":i("sacrificeAnts").style.display="none",e.researches[39]>0?i("reincarnationCrystalInfo").style.display="block":i("reincarnationCrystalInfo").style.display="none",e.researches[40]>0?i("reincarnationMythosInfo").style.display="block":i("reincarnationMythosInfo").style.display="none",e.researches[46]>0?i("reincarnateautomation").style.display="block":i("reincarnateautomation").style.display="none",e.researches[82]>0?(i("rune5area").style.display="flex",i("runeshowpower5").style.display="block"):(i("rune5area").style.display="none",i("runeshowpower5").style.display="none"),e.researches[124]>0?(i("antSacrificeButtons").style.display="flex",i("autoAntSacrifice").style.display="block"):(i("antSacrificeButtons").style.display="none",i("autoAntSacrifice").style.display="none"),e.researches[124]>0||e.highestSingularityCount>0?i("toggleAutoSacrificeAnt").style.display="block":i("toggleAutoSacrificeAnt").style.display="none",e.researches[130]>0?i("toggleautofortify").style.display="block":i("toggleautofortify").style.display="none",e.researches[135]>0?i("toggleautoenhance").style.display="block":i("toggleautoenhance").style.display="none";for(let A=1;A<=5;A++)e.researches[190]>0?i(`tesseractAutoToggle${A}`).style.display="block":i(`tesseractAutoToggle${A}`).style.display="none";e.researches[190]>0?i("tesseractautobuytoggle").style.display="block":i("tesseractautobuytoggle").style.display="none",e.researches[190]>0?i("tesseractautobuymode").style.display="block":i("tesseractautobuymode").style.display="none",e.researches[190]>0?i("tesseractAmount").style.display="block":i("tesseractAmount").style.display="none",e.researches[190]>0?i("autotessbuyeramount").style.display="block":i("autotessbuyeramount").style.display="none",e.antUpgrades[11]>0||e.ascensionCount>0?i("talisman6area").style.display="flex":i("talisman6area").style.display="none",e.shopUpgrades.offeringAuto>0?i("toggleautosacrifice").style.display="block":i("toggleautosacrifice").style.display="none",e.cubeUpgrades[51]>0&&e.highestSingularityCount>=40?i("toggleautoBuyFragments").style.display="block":i("toggleautoBuyFragments").style.display="none",e.shopUpgrades.obtainiumAuto>0?i("toggleautoresearch").style.display="block":i("toggleautoresearch").style.display="none",i("toggleautoresearchmode").style.display=e.shopUpgrades.obtainiumAuto>0&&Ht()?"block":"none",_l()?i("talisman7area").style.display="flex":i("talisman7area").style.display="none",e.cubeUpgrades[8]>0?i("reincarnateAutoUpgrade").style.display="block":i("reincarnateAutoUpgrade").style.display="none",ha()?(i("rune6area").style.display="flex",i("runeshowpower6").style.display="block"):(i("rune6area").style.display="none",i("runeshowpower6").style.display="none"),e.platonicUpgrades[20]>0?(i("rune7area").style.display="flex",i("runeshowpower7").style.display="block"):(i("rune7area").style.display="none",i("runeshowpower7").style.display="none"),e.highestSingularityCount>0?i("saveOffToggle").style.display="block":i("saveOffToggle").style.display="none",e.highestSingularityCount>=35?(i("openCubes").style.display="block",i("cubeOpensInput").style.display="block",i("openTesseracts").style.display="block",i("tesseractsOpensInput").style.display="block",i("openHypercubes").style.display="block",i("hypercubesOpensInput").style.display="block",i("openPlatonicCube").style.display="block",i("platonicCubeOpensInput").style.display="block"):(i("openCubes").style.display="none",i("cubeOpensInput").style.display="none",i("openTesseracts").style.display="none",i("tesseractsOpensInput").style.display="none",i("openHypercubes").style.display="none",i("hypercubesOpensInput").style.display="none",i("openPlatonicCube").style.display="none",i("platonicCubeOpensInput").style.display="none"),e.highestSingularityCount>=50&&e.singularityCount=150?i("toggleAutoCubeUpgrades").style.display="block":i("toggleAutoCubeUpgrades").style.display="none",e.highestSingularityCount>=100&&e.singularityCount=200?i("toggleAutoPlatonicUpgrades").style.display="block":i("toggleAutoPlatonicUpgrades").style.display="none",e.highestSingularityCount>0&&e.ascensionCount>0?i("settingpic6").style.display="block":i("settingpic6").style.display="none",e.highestSingularityCount>0&&e.challenge15Exponent>=1e15?i("heptnotificationpic").style.display="block":i("heptnotificationpic").style.display="none",i("warpAuto").style.display=e.shopUpgrades.autoWarp>0?"":"none";let he=document.getElementsByClassName("octeracts");for(let A of Array.from(he))A.style.display=e.singularityUpgrades.octeractUnlock.getEffect().bonus?"block":"none";let Fe=document.getElementsByClassName("singChallenges");for(let A of Array.from(Fe))A.style.display=e.highestSingularityCount>=25?"block":"none";i("toggleSingularitySubTab4").style.display=e.singularityChallenges.noSingularityUpgrades.completions>=1?"block":"none",i("challengesTabsToggle").style.display=e.highestSingularityCount>=25?"flex":"none",e.runelevels[6]>0||e.highestSingularityCount>0?i("singularitybtn").style.display="block":i("singularitybtn").style.display="none",e.highestSingularityCount>0&&e.ascensionCount>=1?i("totalQuarkCountStatisticSing").style.display="block":i("totalQuarkCountStatisticSing").style.display="none",i("ascensionStats").style.visibility=e.achievements[197]>0||e.highestSingularityCount>0?"visible":"hidden",i("ascHyperStats").style.display=e.challengecompletions[13]>0?"":"none",i("ascPlatonicStats").style.display=e.challengecompletions[14]>0?"":"none",i("ascHepteractStats").style.display=e.achievements[255]>0?"":"none";let wt={toggle1:e.upgrades[81]===1,toggle2:e.upgrades[82]===1,toggle3:e.upgrades[83]===1,toggle4:e.upgrades[84]===1,toggle5:e.upgrades[85]===1,toggle6:e.upgrades[86]===1,toggle7:e.upgrades[87]===1,toggle8:e.upgrades[88]===1,toggle10:e.achievements[78]===1,toggle11:e.achievements[85]===1,toggle12:e.achievements[92]===1,toggle13:e.achievements[99]===1,toggle14:e.achievements[106]===1,toggle15:e.achievements[43]===1,toggle16:e.upgrades[94]===1,toggle17:e.upgrades[95]===1,toggle18:e.upgrades[96]===1,toggle19:e.upgrades[97]===1,toggle20:e.upgrades[98]===1,toggle21:e.upgrades[89]===1,toggle22:e.cubeUpgrades[7]===1,toggle23:e.cubeUpgrades[7]===1,toggle24:e.cubeUpgrades[7]===1,toggle25:e.cubeUpgrades[7]===1,toggle26:e.cubeUpgrades[7]===1,toggle27:e.researches[46]===1,coinAutoUpgrade:e.upgrades[91]===1,prestigeAutoUpgrade:e.upgrades[92]===1,transcendAutoUpgrade:e.upgrades[99]===1,generatorsAutoUpgrade:e.upgrades[90]===1,toggle9:e.unlocks.prestige,toggle28:e.prestigeCount>.5||e.reincarnationCount>.5,toggle29:e.transcendCount>.5||e.reincarnationCount>.5,toggle30:e.reincarnationCount>.5,toggle31:e.ascensionCount>0,toggle32:e.achievements[173]>0,toggle33:e.highestSingularityCount>0&&e.ascensionCount>0,toggle34:e.unlocks.coinfour,toggle35:e.challenge15Exponent>=1e15&&e.highestSingularityCount>0,toggle36:e.highestSingularityCount>=15,toggle37:e.highestSingularityCount>=15,toggle38:e.highestSingularityCount>0,toggle39:e.unlocks.prestige,toggle40:e.unlocks.prestige,toggle41:e.challengecompletions[11]>0,toggle42:e.highestSingularityCount>=6,toggle43:e.highestSingularityCount>=6};Object.keys(wt).forEach(A=>{let Pt=i(A);if(Pt===null){console.error(`Automation unlock failed to find element with ID '${A}'.`);return}Pt.style.display=wt[A]?"block":"none"}),w0()},zf=()=>{var r,n;i("buildings").style.display="none",i("buildingstab").style.backgroundColor="",i("upgrades").style.display="none",i("upgradestab").style.backgroundColor="",i("settings").style.display="none",i("statistics").style.display="none",i("achievementstab").style.backgroundColor="",i("achievementstab").style.color="white",i("runes").style.display="none",i("runestab").style.backgroundColor="",i("challenges").style.display="none",i("challengetab").style.backgroundColor="",i("research").style.display="none",i("researchtab").style.backgroundColor="",i("shop").style.display="none",i("shoptab").style.backgroundColor="",i("ants").style.display="none",i("anttab").style.backgroundColor="",i("cubetab").style.backgroundColor="",i("traitstab").style.backgroundColor="",i("cubes").style.display="none",i("traits").style.display="none",i("singularity").style.display="none",i("singularitytab").style.backgroundColor="",i("event").style.display="none",i("eventtab").style.backgroundColor="",(r=document.getElementById("pseudoCoins"))==null||r.style.setProperty("display","none"),i("pseudoCoinstab").style.backgroundColor="";let t=i("settingstab");if(t.style.backgroundColor="",t.style.borderColor="white",o.currentTab===0&&(i("buildingstab").style.backgroundColor="orange",i("buildings").style.display="block"),o.currentTab===1&&(i("upgrades").style.display="block",i("upgradestab").style.backgroundColor="orange",i("upgradedescription").textContent=u.t("upgrades.hoverOverUpgrade")),o.currentTab===10){i("settings").style.display="block";let a=i("settingstab");a.style.backgroundColor="orange",a.style.borderColor="gold"}o.currentTab===2?(i("statistics").style.display="block",i("achievementstab").style.backgroundColor="white",i("achievementstab").style.color="black",i("achievementprogress").textContent=u.t("achievements.totalPoints",{x:d(e.achievementPoints),y:d(Yn),z:(100*e.achievementPoints/Yn).toPrecision(4)})):o.currentTab===3&&(i("runes").style.display="block",i("runestab").style.backgroundColor="blue",i("runeshowlevelup").textContent=u.t("runes.hover"),i("researchrunebonus").textContent=u.t("runes.thanksResearches",{percent:d(100*o.effectiveLevelMult-100,4,!0)}),Rt(1,!1),Rt(2,!1),Rt(3,!1),Rt(4,!1),Rt(5,!1),Rt(6,!1),Rt(7,!1)),o.currentTab===4&&(i("challenges").style.display="block",i("challengetab").style.backgroundColor="purple"),o.currentTab===5&&(i("research").style.display="block",i("researchtab").style.backgroundColor="green"),o.currentTab===11&&(i("shop").style.display="block",i("shoptab").style.backgroundColor="limegreen"),o.currentTab===6&&(i("ants").style.display="block",i("anttab").style.backgroundColor="brown"),o.currentTab===7&&(i("cubes").style.display="flex",i("cubetab").style.backgroundColor="white"),o.currentTab===8&&(i("traits").style.display="flex",i("traitstab").style.backgroundColor="white"),o.currentTab===9&&(i("singularity").style.display="block",i("singularitytab").style.backgroundColor="lightgoldenrodyellow",Ac(),Oc()),o.currentTab===12&&(i("event").style.display="block",i("eventtab").style.backgroundColor="gold"),o.currentTab===13&&(Al(),(n=document.getElementById("pseudoCoins"))==null||n.style.setProperty("display","unset"),i("pseudoCoinstab").style.backgroundColor="orange")},TC={[0]:Am,[1]:Em,[2]:Om,[3]:Um,[4]:Bm,[5]:cl,[10]:Nm,[11]:Cu,[6]:Rm,[7]:ul,[8]:Im,[9]:$m,[12]:_m,[13]:Dm},cd=()=>{let t=["coins","runeshards","prestigePoints","transcendPoints","transcendShards","reincarnationPoints","worlds","researchPoints"],r=["coinDisplay","offeringDisplay","diamondDisplay","mythosDisplay","mythosshardDisplay","particlesDisplay","quarkDisplay","obtainiumDisplay"];for(let n=0;n{if(i("prestigebtn").style.backgroundColor=e.toggles[15]&&e.achievements[43]===1?"green":"",i("transcendbtn").style.backgroundColor=e.toggles[21]&&e.upgrades[89]>.5&&e.currentChallenge.transcension===0?"green":"",i("reincarnatebtn").style.backgroundColor=e.toggles[27]&&e.researches[46]>.5&&e.currentChallenge.transcension===0&&e.currentChallenge.reincarnation===0?"green":"",i("acceleratorboostbtn").style.backgroundColor=e.toggles[8]&&e.upgrades[88]>.5?"green":"",i("challengebtn").style.backgroundColor=e.currentChallenge.transcension===0?"":"purple",i("reincarnatechallengebtn").style.backgroundColor=e.currentChallenge.reincarnation===0?"":"purple",i("ascendChallengeBtn").style.backgroundColor=e.currentChallenge.ascension===0?"":"purple",i("ascendbtn").style.backgroundColor=e.autoAscend&&e.challengecompletions[11]>0&&e.cubeUpgrades[10]>0?"green":"",i("singularitybtn").style.filter=e.runelevels[6]>0?"":"contrast(1.25) sepia(1) grayscale(0.25)",e.toggles[33]&&e.highestSingularityCount===0&&(e.toggles[28]&&!e.unlocks.prestige&&(i("prestigebtn").style.boxShadow=e.coinsThisPrestige.gte(1e16)?"cyan 0px 0px 10px 2px":""),e.toggles[29]&&!e.unlocks.transcend&&(i("transcendbtn").style.boxShadow=e.coinsThisTranscension.gte(1e100)?"plum 0px 0px 10px 2px":""),e.toggles[30]&&!e.unlocks.reincarnate&&(i("reincarnatebtn").style.boxShadow=e.transcendShards.gte(1e300)?"greenyellow 0px 0px 10px 2px":""),e.toggles[31]&&e.ascensionCount===0&&(i("ascendbtn").style.boxShadow=e.challengecompletions[10]>0?"orange 0px 0px 10px 2px":"")),o.currentTab===0&&o.buildingSubTab==="coin"){let t=i("buycoin1"),r=i("buycoin2"),n=i("buycoin3"),a=i("buycoin4"),s=i("buycoin5"),l=i("buyaccelerator"),c=i("buymultiplier"),p=i("buyacceleratorboost");(!e.toggles[1]||e.upgrades[81]===0)&&e.coins.gte(e.firstCostCoin)?t.classList.add("buildingPurchaseBtnAvailable"):t.classList.remove("buildingPurchaseBtnAvailable"),(!e.toggles[2]||e.upgrades[82]===0)&&e.coins.gte(e.secondCostCoin)?r.classList.add("buildingPurchaseBtnAvailable"):r.classList.remove("buildingPurchaseBtnAvailable"),(!e.toggles[3]||e.upgrades[83]===0)&&e.coins.gte(e.thirdCostCoin)?n.classList.add("buildingPurchaseBtnAvailable"):n.classList.remove("buildingPurchaseBtnAvailable"),(!e.toggles[4]||e.upgrades[84]===0)&&e.coins.gte(e.fourthCostCoin)?a.classList.add("buildingPurchaseBtnAvailable"):a.classList.remove("buildingPurchaseBtnAvailable"),(!e.toggles[5]||e.upgrades[85]===0)&&e.coins.gte(e.fifthCostCoin)?s.classList.add("buildingPurchaseBtnAvailable"):s.classList.remove("buildingPurchaseBtnAvailable"),(!e.toggles[6]||e.upgrades[86]===0)&&e.coins.gte(e.acceleratorCost)?l.classList.add("buildingPurchaseBtnAvailable"):l.classList.remove("buildingPurchaseBtnAvailable"),(!e.toggles[7]||e.upgrades[87]===0)&&e.coins.gte(e.multiplierCost)?c.classList.add("buildingPurchaseBtnAvailable"):c.classList.remove("buildingPurchaseBtnAvailable"),(!e.toggles[8]||e.upgrades[88]===0)&&e.prestigePoints.gte(e.acceleratorBoostCost)?p.classList.add("buildingPurchaseBtnAvailable"):p.classList.remove("buildingPurchaseBtnAvailable")}if(o.currentTab===0&&o.buildingSubTab==="diamond"){let t=i("buydiamond1"),r=i("buydiamond2"),n=i("buydiamond3"),a=i("buydiamond4"),s=i("buydiamond5"),l=i("buycrystalupgrade1"),c=i("buycrystalupgrade2"),p=i("buycrystalupgrade3"),g=i("buycrystalupgrade4"),m=i("buycrystalupgrade5");(!e.toggles[10]||e.achievements[78]===0)&&e.prestigePoints.gte(e.firstCostDiamonds)?t.classList.add("buildingPurchaseBtnAvailable"):t.classList.remove("buildingPurchaseBtnAvailable"),(!e.toggles[11]||e.achievements[85]===0)&&e.prestigePoints.gte(e.secondCostDiamonds)?r.classList.add("buildingPurchaseBtnAvailable"):r.classList.remove("buildingPurchaseBtnAvailable"),(!e.toggles[12]||e.achievements[92]===0)&&e.prestigePoints.gte(e.thirdCostDiamonds)?n.classList.add("buildingPurchaseBtnAvailable"):n.classList.remove("buildingPurchaseBtnAvailable"),(!e.toggles[13]||e.achievements[99]===0)&&e.prestigePoints.gte(e.fourthCostDiamonds)?a.classList.add("buildingPurchaseBtnAvailable"):a.classList.remove("buildingPurchaseBtnAvailable"),(!e.toggles[14]||e.achievements[106]===0)&&e.prestigePoints.gte(e.fifthCostDiamonds)?s.classList.add("buildingPurchaseBtnAvailable"):s.classList.remove("buildingPurchaseBtnAvailable");let h=0;h+=Math.floor(o.rune3level/16*o.effectiveLevelMult)*100/100,e.upgrades[73]===1&&e.currentChallenge.reincarnation!==0&&(h+=10),e.achievements[79]<1?e.prestigeShards.gte(f.pow(10,o.crystalUpgradesCost[0]+o.crystalUpgradeCostIncrement[0]*Math.floor(Math.pow(e.crystalUpgrades[0]+.5-h,2)/2)))?l.style.backgroundColor="purple":l.style.backgroundColor="":l.style.backgroundColor="green",e.achievements[86]<1?e.prestigeShards.gte(f.pow(10,o.crystalUpgradesCost[1]+o.crystalUpgradeCostIncrement[1]*Math.floor(Math.pow(e.crystalUpgrades[1]+.5-h,2)/2)))?c.style.backgroundColor="purple":c.style.backgroundColor="":c.style.backgroundColor="green",e.achievements[93]<1?e.prestigeShards.gte(f.pow(10,o.crystalUpgradesCost[2]+o.crystalUpgradeCostIncrement[2]*Math.floor(Math.pow(e.crystalUpgrades[2]+.5-h,2)/2)))?p.style.backgroundColor="purple":p.style.backgroundColor="":p.style.backgroundColor="green",e.achievements[100]<1?e.prestigeShards.gte(f.pow(10,o.crystalUpgradesCost[3]+o.crystalUpgradeCostIncrement[3]*Math.floor(Math.pow(e.crystalUpgrades[3]+.5-h,2)/2)))?g.style.backgroundColor="purple":g.style.backgroundColor="":g.style.backgroundColor="green",e.achievements[107]<1?e.prestigeShards.gte(f.pow(10,o.crystalUpgradesCost[4]+o.crystalUpgradeCostIncrement[4]*Math.floor(Math.pow(e.crystalUpgrades[4]+.5-h,2)/2)))?m.style.backgroundColor="purple":m.style.backgroundColor="":m.style.backgroundColor="green"}if(o.currentTab===3){if(o.runescreen==="runes")for(let t=1;t<=7;t++)e.runeshards>.5?i(`activaterune${t}`).classList.add("runeButtonAvailable"):i(`activaterune${t}`).classList.remove("runeButtonAvailable");if(o.runescreen==="talismans"){let t=i("buyTalismanItem1"),r=i("buyTalismanItem2"),n=i("buyTalismanItem3"),a=i("buyTalismanItem4"),s=i("buyTalismanItem5"),l=i("buyTalismanItem6"),c=i("buyTalismanItem7"),p=[t,r,n,a,s,l,c];for(let g=0;go.talismanResourceObtainiumCosts[g]&&e.runeshards>o.talismanResourceOfferingCosts[g]?p[g].classList.add("talisminBtnAvailable"):p[g].classList.remove("talisminBtnAvailable")}}if(o.currentTab===0&&o.buildingSubTab==="mythos")for(let t=1;t<=5;t++){let r=e.toggles[t+15],n=e[`${o.ordinals[t-1]}CostMythos`];(!r||!e.upgrades[93+t])&&e.transcendPoints.gte(n)?i(`buymythos${t}`).classList.add("buildingPurchaseBtnAvailable"):i(`buymythos${t}`).classList.remove("buildingPurchaseBtnAvailable")}if(o.currentTab===0&&o.buildingSubTab==="particle")for(let t=1;t<=5;t++){let r=e[`${o.ordinals[t-1]}CostParticles`];e.reincarnationPoints.gte(r)?i(`buyparticles${t}`).classList.add("buildingPurchaseBtnAvailable"):i(`buyparticles${t}`).classList.remove("buildingPurchaseBtnAvailable")}if(o.currentTab===0&&o.buildingSubTab==="tesseract"){for(let t=1;t<=5;t++){let r=e[`ascendBuilding${t}`].cost;Number(e.wowTesseracts)>=r?i(`buyTesseracts${t}`).classList.add("buildingPurchaseBtnAvailable"):i(`buyTesseracts${t}`).classList.remove("buildingPurchaseBtnAvailable")}for(let t=1;t<=8;t++)e.researches[175]>=1?(i(`buyConstantUpgrade${t}`).classList.remove("constUpgradeAvailable"),i(`buyConstantUpgrade${t}`).classList.add("constUpgradeAuto")):(i(`buyConstantUpgrade${t}`).classList.remove("constUpgradeAuto"),e.ascendShards.gte(f.pow(10,e.constantUpgrades[t]).times(o.constUpgradeCosts[t]))?i(`buyConstantUpgrade${t}`).classList.add("constUpgradeAvailable"):i(`buyConstantUpgrade${t}`).classList.remove("constUpgradeAvailable"));for(let t=9;t<=10;t++)e.researches[175]>=1||e.constantUpgrades[t]>=1?(i(`buyConstantUpgrade${t}`).classList.remove("constUpgradeAvailable"),i(`buyConstantUpgrade${t}`).classList.add("constUpgradeAuto")):(i(`buyConstantUpgrade${t}`).classList.remove("constUpgradeAuto"),e.ascendShards.gte(f.pow(10,e.constantUpgrades[t]).times(o.constUpgradeCosts[t]))?i(`buyConstantUpgrade${t}`).classList.add("constUpgradeAvailable"):i(`buyConstantUpgrade${t}`).classList.remove("constUpgradeAvailable"))}if(o.currentTab===6){e.reincarnationPoints.gte(e.firstCostAnts)?i("anttier1").classList.add("antTierBtnAvailable"):i("anttier1").classList.remove("antTierBtnAvailable");for(let t=2;t<=8;t++){let r=e[`${o.ordinals[t-1]}CostAnts`];e.antPoints.gte(r)?i(`anttier${t}`).classList.add("antTierBtnAvailable"):i(`anttier${t}`).classList.remove("antTierBtnAvailable")}for(let t=1;t<=12;t++)e.antPoints.gte(f.pow(o.antUpgradeCostIncreases[t-1],e.antUpgrades[t-1]*o.extinctionMultiplier[e.usedCorruptions[10]]).times(o.antUpgradeBaseCost[t-1]))?i(`antUpgrade${t}`).classList.add("antUpgradeBtnAvailable"):i(`antUpgrade${t}`).classList.remove("antUpgradeBtnAvailable")}},Sr=()=>{for(let t=1;t<=15;t++){let r=i(`challenge${t}`);r.classList.remove("challengeActive"),e.currentChallenge.transcension===t&&r.classList.add("challengeActive"),e.currentChallenge.reincarnation===t&&r.classList.add("challengeActive"),e.currentChallenge.ascension===t&&r.classList.add("challengeActive")}e.retrychallenges?i("retryChallenge").textContent=u.t("challenges.retryChallengesOn"):i("retryChallenge").textContent=u.t("challenges.retryChallengesOff");for(let t=1;t<=15;t++)Br(t)},Br=t=>{let r=i(`challenge${t}level`),n=je(t);t===15?r.textContent=d(e.challenge15Exponent,0,!0):r.textContent=`${e.challengecompletions[t]}/${n}`},M0=()=>{for(let n=1;n<=280;n++)i(`ach${n}`).style.backgroundColor="";let t=document.getElementsByClassName("purpleach"),r=document.getElementsByClassName("redach");for(let n=0;n.5&&R(n)},hl=()=>{let t=i("corrStatsBtn"),r=i("corrLoadoutsBtn");e.corruptionShowStats?(i("corruptionStats").style.display="flex",i("corruptionLoadouts").style.display="none",t.classList.add("subtab-active"),r.classList.remove("subtab-active")):(i("corruptionStats").style.display="none",i("corruptionLoadouts").style.display="flex",t.classList.remove("subtab-active"),r.classList.add("subtab-active"))},SC=()=>{let t=e.ascensionCounter;t===0&&(t=1);let[r,n,a,s,l]=Xr().slice(4),c=e.singularityUpgrades.oneMind.getEffect().bonus,p={ascLen:Vt(e.ascStatToggles[6]?e.ascensionCounter:e.ascensionCounterReal,0),ascCubes:d(r*(e.ascStatToggles[1]?1:1/t),2),ascTess:d(n*(e.ascStatToggles[2]?1:1/t),3),ascHyper:d(a*(e.ascStatToggles[3]?1:1/t),4),ascPlatonic:d(s*(e.ascStatToggles[4]?1:1/t),5),ascHepteract:d(l*(e.ascStatToggles[5]?1:1/t),3),ascC10:`${d(e.challengecompletions[10])}`,ascTimeAccel:`${d(qe().mult,3)}x`,ascAscensionTimeAccel:`${d(Ur(),3)}x${c?"*":""}`,ascSingularityCount:d(e.singularityCount),ascSingLen:Vt(e.singularityCounter),ascSingChallengeLen:Vt(e.singChallengeTimer)};for(let g in p){let m=i(g);m.textContent!==p[g]&&(m.textContent=p[g]),g==="ascSingChallengeLen"&&(e.singularityChallenges.limitedTime.enabled&&e.singChallengeTimer>600-20*e.singularityChallenges.limitedTime.completions?m.style.color="red":m.style.color="white")}},kC={[0]:"yellow",[1]:"yellow",[2]:"white",[3]:"cyan",[4]:"plum",[5]:"green",[6]:"brown",[7]:"purple",[8]:"orange",[10]:"white",[11]:"limegreen"},Ul=()=>{var n;let t=i("tabBorder"),r=(n=kC[o.currentTab])!=null?n:"yellow";t.style.backgroundColor=r},Vo,$s,ld=class{constructor(){xt(this,Vo,[]);xt(this,$s,!1)}enqueue(r){return new Promise((n,a)=>{te(this,Vo).push({action:r,resolve:n,reject:a}),this.dequeue()})}async dequeue(){if(te(this,$s))return!1;let r=te(this,Vo).shift();if(!r)return!1;try{Et(this,$s,!0);let n=await r.action();r.resolve(n)}catch(n){r.reject(n)}finally{Et(this,$s,!1),this.dequeue()}return!0}};Vo=new WeakMap,$s=new WeakMap;var ud=new ld,we=async t=>ud.enqueue(()=>{let r=i("confirmationBox"),n=i("confirmWrapper"),a=i("confirm"),s=i("transparentBG"),l=i("ok_confirm"),c=i("cancel_confirm");i("alertWrapper").style.display="none",i("promptWrapper").style.display="none",r.style.display="block",n.style.display="block",s.style.display="block",a.querySelector("p").textContent=t,a.focus();let p=ca(),g=({target:h})=>{let b=h;l.removeEventListener("click",g),c.removeEventListener("click",g),a.removeEventListener("keyup",m),r.style.display="none",n.style.display="none",s.style.display="none",p.resolve(b===l)},m=h=>h.key==="Enter"||h.key===" "?g({target:l}):h.key==="Escape"?g({target:c}):h.preventDefault();return l.addEventListener("click",g,{once:!0}),c.addEventListener("click",g,{once:!0}),a.addEventListener("keyup",m),p.promise}),P=t=>ud.enqueue(()=>{let r=i("confirmationBox"),n=i("alertWrapper"),a=i("transparentBG"),s=i("alert"),l=i("ok_alert");i("confirmWrapper").style.display="none",i("promptWrapper").style.display="none",r.style.display="block",n.style.display="block",a.style.display="block",s.querySelector("p").textContent=t,s.focus();let c=ca(),p=()=>{l.removeEventListener("click",p),s.removeEventListener("keyup",g),r.style.display="none",n.style.display="none",a.style.display="none",c.resolve()},g=m=>(m.key==="Enter"||m.key===" ")&&p();return l.addEventListener("click",p,{once:!0}),s.addEventListener("keyup",g),c.promise}),Ee=(t,r)=>ud.enqueue(()=>{let n=i("confirmationBox"),a=i("promptWrapper"),s=i("transparentBG"),l=i("prompt"),c=i("ok_prompt"),p=i("cancel_prompt");i("alertWrapper").style.display="none",i("confirmWrapper").style.display="none",n.style.display="block",a.style.display="block",s.style.display="block",l.querySelector("label").textContent=t,r&&(l.querySelector("input").placeholder=r),l.querySelector("input").focus();let g=ca(),m=({target:b})=>{let C=b,v=C.parentNode.querySelector("input");c.removeEventListener("click",m),p.removeEventListener("click",m),l.querySelector("input").removeEventListener("keyup",h),n.style.display="none",a.style.display="none",s.style.display="none",g.resolve(C.id===c.id?v.value||v.placeholder:null),v.value=v.textContent=v.placeholder="",l.querySelector("input").blur()},h=b=>b.key==="Enter"?m({target:c}):b.key==="Escape"?m({target:p}):b.preventDefault();return c.addEventListener("click",m,{once:!0}),p.addEventListener("click",m,{once:!0}),l.querySelector("input").addEventListener("keyup",h),g.promise}),od,id,br=(t,r=3e4)=>{let n=i("notification"),a=document.querySelector("#notification > p"),s=i("notifx");a.textContent=t,n.style.display="block",n.classList.remove("slide-out"),n.classList.add("slide-in");let l=ca(),c=()=>{n.style.display="none",a.textContent="",id=0},p=()=>{n.classList.add("slide-out"),n.classList.remove("slide-in"),od=0,s.removeEventListener("click",p),id=setTimeout(c,1e3),l.resolve()};return s.addEventListener("click",p),clearTimeout(od),clearTimeout(id),od=setTimeout(p,r),l.promise};var _s=[0,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,2,8,10,2,8,10,10,2,8,10,10,10,10,10,2,4,6,8,10,10,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,20,20,20,40,60,60,100,20,20,40,40,60,60,100,20,20,40,40,60,60,100,20,40,40,40,60,60,100,40,40,40,60,60,100,100,40,40,60,60,100,100,100,20,40,40,60,60,100,100,40,60,100,60,100,100,40,40,40,40,40,40,40,40,40,40,40,40,100,100,0,50,75,75,75,100,100,150,50,75,75,75,100,100,150,50,75,75,75,100,100,150,10,10,20,20,30,40,50],Yn=_s.reduce((t,r)=>t+r,0),LC=t=>{let r=Xr(),n={118:d(Math.pow(.9925,e.challengecompletions[6]+e.challengecompletions[7]+e.challengecompletions[8]+e.challengecompletions[9]+e.challengecompletions[10]),4),169:d(f.log(e.antPoints.add(10),10),2),174:d(.4*f.log(e.antPoints.add(1),10),2),187:{x:d(Math.max(1,Math.log10(r[3]+1)-7),2),y:d(Math.min(100,e.ascensionCount/1e4),2)},188:d(Math.min(100,e.ascensionCount/5e4),2),189:d(Math.min(200,e.ascensionCount/25e5),2),193:d(f.log(e.ascendShards.add(1),10)/4,2),195:d(Math.min(25e3,f.log(e.ascendShards.add(1),10)/4),2),196:d(Math.min(2e3,f.log(e.ascendShards.add(1),10)/50),2),202:d(Math.min(200,e.ascensionCount/5e6),2),216:d(Math.min(200,e.ascensionCount/1e7),2),223:d(Math.min(200,e.ascensionCount/1337e4),2),240:d(Math.min(1.5,1+Math.max(2,Math.log10(qe().mult))/20),2),254:d(Math.min(15,Math.log10(r[3]+1)*.6),2,!0),255:d(Math.min(15,Math.log10(r[3]+1)*.6),2,!0),256:d(Math.min(15,Math.log10(r[3]+1)*.6),2,!0),257:d(Math.min(15,Math.log10(r[3]+1)*.6),2,!0),258:d(Math.min(15,Math.log10(r[3]+1)*.6),2,!0),262:d(Math.min(10,Math.log10(e.ascensionCount+1)),2),263:d(Math.min(10,Math.log10(e.ascensionCount+1)),2),264:d(Math.min(40,e.ascensionCount/2e11),2),265:d(Math.min(20,e.ascensionCount/8e12),2),266:d(Math.min(10,e.ascensionCount/1e14),2),267:d(Math.min(100,f.log(e.ascendShards.add(1),10)/1e3),2),270:d(Math.min(100,f.log(e.ascendShards.add(1),10)/1e4),2),271:d(Math.max(0,Math.min(1,(f.log(e.ascendShards.add(1),10)-1e5)/9e5)),2,!0)};if([3,4,5,6,7,10,11,12,13,14,17,18,19,20,21,24,25,26,27,28,31,32,33,34,35,36,37,38,43,44,45,46,47,50,51,52,53,57,58,59,60,61,62,71,72,73,74,75,76,77,78,79,80,82,84,85,86,87,89,91,92,93,94,96,98,99,100,101,102,103,105,106,107,108,110,112,115,117,119,122,124,126,127,128,129,131,132,133,134,135,136,137,140,141,147,171,172,173,176,177,178,179,180,181,182,197,198,199,200,201,204,205,206,207,208,209,211,212,213,214,215,218,219,220,221,222,250,251,253,259,260,261].includes(t)||t in n){let s=n[t],l=typeof s=="object"?s:{x:s};return u.t(`achievements.rewards.${t}`,l)}return""},PC=async t=>{if(e.highestSingularityCount===0&&(t===36||t===38||t===255))return P(u.t(`achievements.alerts.${t}`))},vt=t=>{t===1&&(e.prestigenoaccelerator&&R(60),e.prestigenomultiplier&&R(57),e.prestigenocoinupgrades&&R(64),o.prestigePointGain.gte(1)&&R(36),o.prestigePointGain.gte(1e6)&&R(37),o.prestigePointGain.gte(1e100)&&R(38),o.prestigePointGain.gte("1e1000")&&R(39),o.prestigePointGain.gte("1e10000")&&R(40),o.prestigePointGain.gte("1e77777")&&R(41),o.prestigePointGain.gte("1e250000")&&R(42)),t===2&&(e.transcendnoaccelerator&&R(61),e.transcendnomultiplier&&R(58),e.transcendnocoinupgrades&&R(65),e.transcendnocoinorprestigeupgrades&&R(66),o.transcendPointGain.gte(1)&&R(43),o.transcendPointGain.gte(1e6)&&R(44),o.transcendPointGain.gte(1e50)&&R(45),o.transcendPointGain.gte(1e308)&&R(46),o.transcendPointGain.gte("1e1500")&&R(47),o.transcendPointGain.gte("1e25000")&&R(48),o.transcendPointGain.gte("1e100000")&&R(49)),t===3&&(e.reincarnatenoaccelerator&&R(62),e.reincarnatenomultiplier&&R(59),e.reincarnatenocoinupgrades&&R(67),e.reincarnatenocoinorprestigeupgrades&&R(68),e.reincarnatenocoinprestigeortranscendupgrades&&R(69),e.reincarnatenocoinprestigetranscendorgeneratorupgrades&&R(70),o.reincarnationPointGain.gte(1)&&R(50),o.reincarnationPointGain.gte(1e5)&&R(51),o.reincarnationPointGain.gte(1e30)&&R(52),o.reincarnationPointGain.gte(1e200)&&R(53),o.reincarnationPointGain.gte("1e1500")&&R(54),o.reincarnationPointGain.gte("1e5000")&&R(55),o.reincarnationPointGain.gte("1e7777")&&R(56))},AC=[[1,.5,78],[1,2.5,79],[1,4.5,80],[1,9.5,81],[1,19.5,82],[1,49.5,83],[1,74.5,84],[2,.5,85],[2,2.5,86],[2,4.5,87],[2,9.5,88],[2,19.5,89],[2,49.5,90],[2,74.5,91],[3,.5,92],[3,2.5,93],[3,4.5,94],[3,9.5,95],[3,19.5,96],[3,49.5,97],[3,74.5,98],[4,.5,99],[4,2.5,100],[4,4.5,101],[4,9.5,102],[4,19.5,103],[4,49.5,104],[4,74.5,105],[5,.5,106],[5,2.5,107],[5,4.5,108],[5,9.5,109],[5,19.5,110],[5,49.5,111],[5,74.5,112],[6,.5,113],[6,1.5,114],[6,2.5,115],[6,4.5,116],[6,9.5,117],[6,14.5,118],[6,24.5,119],[7,.5,120],[7,1.5,121],[7,2.5,122],[7,4.5,123],[7,9.5,124],[7,14.5,125],[7,24.5,126],[8,.5,127],[8,1.5,128],[8,2.5,129],[8,4.5,130],[8,9.5,131],[8,19.5,132],[8,24.5,133],[9,.5,134],[9,1.5,135],[9,2.5,136],[9,4.5,137],[9,9.5,138],[9,19.5,139],[9,24.5,140],[10,.5,141],[10,1.5,142],[10,2.5,143],[10,4.5,144],[10,9.5,145],[10,19.5,146],[10,24.5,147],[15,.5,252]],EC={1:["1e1000",75],2:["1e1000",76],3:["1e99999",77],5:["1e120000",63]},fr=(t,r)=>{let n=ae(e.upgrades.slice(101,106));for(let[,a,s]of AC.filter(([l])=>l===t))e.challengecompletions[t]>a&&e.achievements[s]<1&&R(s);if([1,2,3,5].includes(t)&&!r){let[a,s]=EC[t];t===5?e.coinsThisTranscension.gte(a)&&e.acceleratorBought===0&&e.acceleratorBoostBought===0&&R(s):e.coinsThisTranscension.gte(a)&&n===0&&R(s)}if(t>=11&&t<=14){let a=[0,1,2,3,5,10,20,30];for(let s=1;s<=7;s++)e.challengecompletions[t]>=a[s]&&e.achievements[119+7*t+s]<1&&R(119+7*t+s)}e.challengecompletions[10]>=50&&t===11&&e.usedCorruptions[7]>=5&&e.achievements[247]<1&&R(247)},T0=[()=>e.firstOwnedCoin>=1&&e.achievements[1]<.5,()=>e.firstOwnedCoin>=10&&e.achievements[2]<.5,()=>e.firstOwnedCoin>=100&&e.achievements[3]<.5,()=>e.firstOwnedCoin>=1e3&&e.achievements[4]<.5,()=>e.firstOwnedCoin>=5e3&&e.achievements[5]<.5,()=>e.firstOwnedCoin>=1e4&&e.achievements[6]<.5,()=>e.firstOwnedCoin>=2e4&&e.achievements[7]<.5,()=>e.secondOwnedCoin>=1&&e.achievements[8]<.5,()=>e.secondOwnedCoin>=10&&e.achievements[9]<.5,()=>e.secondOwnedCoin>=100&&e.achievements[10]<.5,()=>e.secondOwnedCoin>=1e3&&e.achievements[11]<.5,()=>e.secondOwnedCoin>=5e3&&e.achievements[12]<.5,()=>e.secondOwnedCoin>=1e4&&e.achievements[13]<.5,()=>e.secondOwnedCoin>=2e4&&e.achievements[14]<.5,()=>e.thirdOwnedCoin>=1&&e.achievements[15]<.5,()=>e.thirdOwnedCoin>=10&&e.achievements[16]<.5,()=>e.thirdOwnedCoin>=100&&e.achievements[17]<.5,()=>e.thirdOwnedCoin>=1e3&&e.achievements[18]<.5,()=>e.thirdOwnedCoin>=5e3&&e.achievements[19]<.5,()=>e.thirdOwnedCoin>=1e4&&e.achievements[20]<.5,()=>e.thirdOwnedCoin>=2e4&&e.achievements[21]<.5,()=>e.fourthOwnedCoin>=1&&e.achievements[22]<.5,()=>e.fourthOwnedCoin>=10&&e.achievements[23]<.5,()=>e.fourthOwnedCoin>=100&&e.achievements[24]<.5,()=>e.fourthOwnedCoin>=1e3&&e.achievements[25]<.5,()=>e.fourthOwnedCoin>=5e3&&e.achievements[26]<.5,()=>e.fourthOwnedCoin>=1e4&&e.achievements[27]<.5,()=>e.fourthOwnedCoin>=2e4&&e.achievements[28]<.5,()=>e.fifthOwnedCoin>=1&&e.achievements[29]<.5,()=>e.fifthOwnedCoin>=10&&e.achievements[30]<.5,()=>e.fifthOwnedCoin>=66&&e.achievements[31]<.5,()=>e.fifthOwnedCoin>=666&&e.achievements[32]<.5,()=>e.fifthOwnedCoin>=6666&&e.achievements[33]<.5,()=>e.fifthOwnedCoin>=17777&&e.achievements[34]<.5,()=>e.fifthOwnedCoin>=42777&&e.achievements[35]<.5],S0=()=>{for(let t of T0)if(t()){let r=T0.indexOf(t)+1;R(r)}},Ts=(t,r=0)=>{if(t===1){let n=[0,1,2,10,100,1e3,14142,141421,1414213,1e7,1e8,2e9,4e10,8e11,16e12,1e14];for(let a=1;a<=7;a++)e.ascensionCount>=n[a]&&e.achievements[182+a]<1&&R(182+a),e.ascensionCount>=n[a+8]&&e.achievements[259+a]<1&&R(259+a);e.ascensionCount>=n[8]&&e.achievements[240]<1&&R(240)}if(t===2){let n=[0,3.14,1e6,432e8,69e20,1509e30,1e66,"1.8e308","1e1000","1e5000","1e15000","1e50000","1e100000","1e300000","1e1000000"];for(let a=1;a<=7;a++)e.ascendShards.gte(n[a])&&e.achievements[189+a]<1&&R(189+a),e.ascendShards.gte(n[a+7])&&e.achievements[266+a]<1&&R(266+a)}if(t===3){let n=[0,1e5,1e6,1e7,1e8,1e9,5e9,25e9,1e12,1e14,1e17,2e18,4e19,1e21,1e23];for(let a=1;a<=7;a++)r>=n[a]&&e.achievements[224+a]<1&&R(224+a),r>=n[7+a]&&e.achievements[252+a]<1&&R(252+a)}},k0=t=>{let r=1;t>=183&&(r=5),t>=253&&(r=40);let n=e.worlds.applyBonus(1),a=r*n;return a>100&&(a=Math.pow(100,.6)*Math.pow(a,.4)),Math.floor(_s[t]*a)},L0=t=>{let r=u.t(`achievements.descriptions.${t}`,{number:`${t}`}),n=e.achievements[t]>.5?u.t("achievements.completed"):"",a=LC(t);i("achievementdescription").textContent=r+n,i("achievementreward").textContent=u.t("achievements.rewardGainMessage",{x:_s[t],y:d(k0(t),0,!0),z:a}),e.achievements[t]>.5?i("achievementdescription").style.color="gold":i("achievementdescription").style.color="white"},R=t=>{if(e.achievements[t]<1){if(e.toggles[34]){let r=u.t(`achievements.descriptions.${t}`,{number:`${t}`});br(u.t("achievements.notification",{m:r}))}PC(t),e.achievementPoints+=_s[t],e.worlds.add(k0(t),!1),i("achievementprogress").textContent=u.t("achievements.totalPoints",{x:d(e.achievementPoints),y:d(Yn),z:(100*e.achievementPoints/Yn).toPrecision(4)}),e.achievements[t]=1,Oe()}i(`ach${t}`).style.backgroundColor="Green",yt.emit("achievement",t)};var Wo=class{constructor(){this.totalVal=0}initialize(){this.totalVal=0;for(let r of Object.keys(this.vals))this.updateVal(r,!0)}updateTotal(r,n,a=!1){a?this.totalVal+=n:this.totalVal+=n-r}flatten(){let r=Object.values(this.vals);return r.push(this.totalVal),r}},dd=class{constructor(){this.totalVal=1}initialize(){this.totalVal=1;for(let r of Object.keys(this.vals))this.updateVal(r,!0)}updateTotal(r,n,a=!1){if(a)this.totalVal*=n;else if(this.totalVal!==0&&n!==0)this.totalVal*=n/r;else if(n===0)this.totalVal=0;else{let s=this.flatten();s.pop(),this.totalVal=be(s)}}flatten(){let r=Object.values(this.vals);return r.push(this.totalVal),r}},Dl=class extends Wo{constructor(){super();this.reset()}reset(){this.vals={Base:1,Exalt1:0,SingularityPerk:0,ShopUpgrades:0,Exalt5:0,Event:0},this.totalVal=1}updateVal(n,a=!1){let s=this.vals[n];switch(n){case"Base":{this.vals[n]=1;break}case"Exalt1":{this.vals[n]=+e.singularityChallenges.noSingularityUpgrades.rewards.luckBonus;break}case"SingularityPerk":{this.vals[n]=Cd();break}case"ShopUpgrades":{this.vals[n]=e.shopUpgrades.shopAmbrosiaLuckMultiplier4/100;break}case"Exalt5":{this.vals[n]=+e.singularityChallenges.noAmbrosiaUpgrades.rewards.luckBonus;break}case"Event":{this.vals[n]=o.isEvent?Ye(12):0;break}}let l=this.vals[n];this.updateTotal(s,l,a),e.caches.ambrosiaLuck.updateVal("Base")}},Gl=class extends Wo{constructor(){super();this.reset()}reset(){this.vals={Base:100,SingPerks:0,ShopUpgrades:0,SingularityBerries:0,OcteractBerries:0,BlueberryUpgrade1:0,BlueberryUpgrade2:0,BlueberryCubeLuck1:0,BlueberryQuarkLuck1:0,OneHundredThirtyOne:0,TwoHundredSixtyNine:0,ShopOcteractAmbrosiaLuck:0,Exalt5:0},this.totalVal=0,this.usedTotal=0}updateVal(n,a=!1){let s=this.vals[n];switch(n){case"Base":{this.vals[n]=100;break}case"SingPerks":{this.vals[n]=pd();break}case"ShopUpgrades":{this.vals[n]=md();break}case"SingularityBerries":{this.vals[n]=hd();break}case"OcteractBerries":{this.vals[n]=yd();break}case"BlueberryUpgrade1":{this.vals[n]=+e.blueberryUpgrades.ambrosiaLuck1.bonus.ambrosiaLuck;break}case"BlueberryUpgrade2":{this.vals[n]=+e.blueberryUpgrades.ambrosiaLuck2.bonus.ambrosiaLuck;break}case"BlueberryCubeLuck1":{this.vals[n]=+e.blueberryUpgrades.ambrosiaCubeLuck1.bonus.ambrosiaLuck;break}case"BlueberryQuarkLuck1":{this.vals[n]=+e.blueberryUpgrades.ambrosiaQuarkLuck1.bonus.ambrosiaLuck;break}case"OneHundredThirtyOne":{this.vals[n]=e.highestSingularityCount>=131?131:0;break}case"TwoHundredSixtyNine":{this.vals[n]=e.highestSingularityCount>=269?269:0;break}case"ShopOcteractAmbrosiaLuck":{this.vals[n]=e.shopUpgrades.shopOcteractAmbrosiaLuck*(1+Math.floor(Math.log10(e.totalWowOcteracts+1)));break}case"Exalt5":{this.vals[n]=+e.singularityChallenges.noAmbrosiaUpgrades.rewards.additiveLuck;break}}let l=this.vals[n];this.updateTotal(s,l,a),this.usedTotal=Math.floor(this.totalVal*e.caches.ambrosiaLuckAdditiveMult.totalVal)}},Hl=class extends dd{constructor(){super();this.reset()}reset(){this.vals={DefaultVal:1,Blueberries:1,ShopUpgrades:1,SingularityBerries:1,OcteractBerries:1,BlueberryPatreon:1,Exalt2:1,Exalt5:1,CashGrabUltra:1,Event:1},this.totalVal=0}updateVal(n,a=!1){let s=this.vals[n];switch(n){case"DefaultVal":{this.vals[n]=1*+e.visitedAmbrosiaSubtab;break}case"Blueberries":{this.vals[n]=e.caches.blueberryInventory.totalVal;break}case"ShopUpgrades":{this.vals[n]=gd();break}case"SingularityBerries":{this.vals[n]=fd();break}case"OcteractBerries":{this.vals[n]=bd();break}case"BlueberryPatreon":{this.vals[n]=+e.blueberryUpgrades.ambrosiaPatreon.bonus.blueberryGeneration;break}case"Exalt2":{this.vals[n]=+e.singularityChallenges.oneChallengeCap.rewards.blueberrySpeedMult;break}case"Exalt5":{this.vals[n]=+e.singularityChallenges.noAmbrosiaUpgrades.rewards.blueberrySpeedMult;break}case"Event":{this.vals[n]=o.isEvent?1+Ye(11):1;break}case"CashGrabUltra":{this.vals[n]=po();break}}let l=this.vals[n];this.updateTotal(s,l,a)}},Fl=class extends Wo{constructor(){super();this.reset()}reset(){this.vals={Exalt1:0,SingularityUpgrade:0,SingularityPerk:0,Exalt5:0},this.totalVal=0}updateVal(n,a=!1){let s=this.vals[n];switch(n){case"Exalt1":{this.vals[n]=+(e.singularityChallenges.noSingularityUpgrades.completions>0);break}case"SingularityUpgrade":{this.vals[n]=+e.singularityUpgrades.blueberries.getEffect().bonus;break}case"SingularityPerk":{this.vals[n]=vd();break}case"Exalt5":this.vals[n]=+e.singularityChallenges.noAmbrosiaUpgrades.rewards.blueberries}let l=this.vals[n];this.updateTotal(s,l,a),e.caches.ambrosiaGeneration.updateVal("Blueberries")}},Ql=()=>{o.ambrosiaCurrStats={ambrosiaAdditiveLuckMult:zr().value,ambrosiaLuck:Ge().value,ambrosiaBlueberries:da().value,ambrosiaGenerationSpeed:De().value}};var OC=.08,UC=1.2,BC=.15,RC=.125,IC=.125,NC=.125,A0=()=>{o.totalCoinOwned=e.firstOwnedCoin+e.secondOwnedCoin+e.thirdOwnedCoin+e.fourthOwnedCoin+e.fifthOwnedCoin},E0=()=>{let t=0;e.upgrades[26]>.5&&(t+=1),e.upgrades[31]>.5&&(t+=Math.floor(o.totalCoinOwned/2e3)*100/100),e.achievements[7]>.5&&(t+=Math.floor(e.firstOwnedCoin/2e3)),e.achievements[14]>.5&&(t+=Math.floor(e.secondOwnedCoin/2e3)),e.achievements[21]>.5&&(t+=Math.floor(e.thirdOwnedCoin/2e3)),e.achievements[28]>.5&&(t+=Math.floor(e.fourthOwnedCoin/2e3)),e.achievements[35]>.5&&(t+=Math.floor(e.fifthOwnedCoin/2e3)),t+=e.researches[93]*Math.floor(1/20*(o.rune1level+o.rune2level+o.rune3level+o.rune4level+o.rune5level)),t+=Math.floor((.01+o.rune1level)*o.effectiveLevelMult/20),t*=1+1/5*e.researches[3]*(1+1/2*_("ascension",e.challengecompletions[14])),t*=1+1/20*e.researches[16]+1/20*e.researches[17],t*=1+1/20*e.researches[88],t*=Nt(20,(e.antUpgrades[4-1]+o.bonusant4)/1e3*20/19),t*=1+1/100*e.researches[127],t*=1+.8/100*e.researches[142],t*=1+.6/100*e.researches[157],t*=1+.4/100*e.researches[172],t*=1+.2/100*e.researches[187],t*=1+.01/100*e.researches[200],t*=1+.01/100*e.cubeUpgrades[50],t*=1+1/1e3*Ve("acceleratorBoost"),e.upgrades[73]>.5&&e.currentChallenge.reincarnation!==0&&(t*=2),t=Math.min(1e100,Math.floor(t)),o.freeAcceleratorBoost=t,o.totalAcceleratorBoost=Math.floor(e.acceleratorBoostBought+o.freeAcceleratorBoost)*100/100},O0=()=>{o.acceleratorMultiplier=1,o.acceleratorMultiplier*=1+e.achievements[60]/100,o.acceleratorMultiplier*=1+e.achievements[61]/100,o.acceleratorMultiplier*=1+e.achievements[62]/100,o.acceleratorMultiplier*=1+1/5*e.researches[1]*(1+1/2*_("ascension",e.challengecompletions[14])),o.acceleratorMultiplier*=1+1/20*e.researches[6]+1/25*e.researches[7]+1/40*e.researches[8]+3/200*e.researches[9]+1/200*e.researches[10],o.acceleratorMultiplier*=1+1/20*e.researches[86],o.acceleratorMultiplier*=1+1/100*e.researches[126],o.acceleratorMultiplier*=1+.8/100*e.researches[141],o.acceleratorMultiplier*=1+.6/100*e.researches[156],o.acceleratorMultiplier*=1+.4/100*e.researches[171],o.acceleratorMultiplier*=1+.2/100*e.researches[186],o.acceleratorMultiplier*=1+.01/100*e.researches[200],o.acceleratorMultiplier*=1+.01/100*e.cubeUpgrades[50],o.acceleratorMultiplier*=Math.pow(1.01,e.upgrades[21]+e.upgrades[22]+e.upgrades[23]+e.upgrades[24]+e.upgrades[25]),(e.currentChallenge.transcension!==0||e.currentChallenge.reincarnation!==0)&&e.upgrades[50]>.5&&(o.acceleratorMultiplier*=1.25)},wu=()=>1/(1-ae([.05*e.achievements[80],.05*e.achievements[87],.05*e.achievements[94],.05*e.achievements[101],.05*e.achievements[108],.05*e.achievements[115],.075*e.achievements[122],.075*e.achievements[129],.05*e.upgrades[61],.25*Math.min(1,o.rune4level/400),.005*e.cubeUpgrades[2]]));function so(t,r=!1,n=e.runelevels[t],a=!1){let s=wu(),l=null;r?l=ae([1/100*e.highestchallengecompletions[3],1*e.upgrades[66]]):l=ae([1,Math.min(1,e.highestchallengecompletions[1]),.4/10*e.highestchallengecompletions[1],.6*e.researches[22],.3*e.researches[23],2*e.upgrades[61],e.upgrades[71]*n/25]);let c=be([1+e.researches[91]/20,1+e.researches[92]/20,Nt(999,1/1e4*Math.pow(e.antUpgrades[8-1]+o.bonusant8,1.1)),o.cubeBonusMultiplier[4],1+e.ascensionCounter/1e3*e.cubeUpgrades[32],1+1/10*e.constantUpgrades[8],o.challenge15Rewards.runeExp]),p=1/Math.pow(o.droughtMultiplier[e.usedCorruptions[8]],1-1/2*e.platonicUpgrades[13]),g=[be([1+e.researches[78]/50,1+e.researches[111]/100,1+_("reincarnation",e.challengecompletions[7])/10,p]),be([1+e.researches[80]/50,1+e.researches[112]/100,1+_("reincarnation",e.challengecompletions[7])/10,p]),be([1+e.researches[79]/50,1+e.researches[113]/100,1+_("reincarnation",e.challengecompletions[8])/5,p]),be([1+e.researches[77]/50,1+e.researches[114]/100,1+_("reincarnation",e.challengecompletions[6])/10,p]),be([1+e.researches[83]/20,1+e.researches[115]/100,1+_("reincarnation",e.challengecompletions[9])/5,p]),be([1]),be([1])],m=[l,c,s,g[t]];return a?m:Math.min(1e200,be(m))}var $C=t=>be([Math.pow((t+1)/2,3),(3.5*t+100)/500,Math.max(1,(t-200)/9),Math.max(1,(t-400)/12),Math.max(1,(t-600)/15),Math.max(1,Math.pow(1.03,(t-800)/4))]),ql=null,on=(t,r=e.runelevels[t])=>{ql!=null||(ql=Array.from({length:4e4+1},(a,s)=>$C(s)));let n=ql[r];return t===5&&(n=Math.pow(100,r)),t===6&&(n=Math.pow(1e25,r)*(e.highestSingularityCount+1)),n*o.runeexpbase[t]},rt=t=>{let r=1e3,n=20*(e.cubeUpgrades[16]+e.cubeUpgrades[37])+3*e.constantUpgrades[7]+80*_("ascension",e.challengecompletions[11])+200*_("ascension",e.challengecompletions[14])+Math.floor(.04*e.researches[200]+.04*e.cubeUpgrades[50]),a=[null,10*(e.researches[78]+e.researches[111])+n,10*(e.researches[80]+e.researches[112])+n,10*(e.researches[79]+e.researches[113])+n,10*(e.researches[77]+e.researches[114])+n,10*e.researches[115]+n,-901,-999];return r=a[t]>o.runeMaxLvl?o.runeMaxLvl:r+a[t],r},$n=()=>{let t=xe.INSTANT_UNLOCK_2?6:0;t+=e.cubeUpgrades[73];let r=e.runelevels[5]+t;return r+Math.max(0,r-74)+Math.max(0,r-98)};function Qr(t,r=!0,n=!1){if(t==="acceleratorBoost"||t==="ascension"||t==="ascensionChallenge")return 0;let a=0,s=0,l=0,c=0;(t==="reincarnation"||t==="reincarnationChallenge")&&(s+=3,e.achievements[52]>.5&&(s+=25*Math.min(e.reincarnationcounter/1800,1)),e.upgrades[62]>.5&&(s+=1/50*ae(e.challengecompletions)),s+=.6*e.researches[25],e.researches[95]===1&&(s+=4),s+=1/200*o.rune5level*o.effectiveLevelMult*(1+e.researches[85]/200),s*=1+Math.pow(f.log(e.reincarnationShards.add(1),10),2/3)/4,s*=Math.min(Math.pow(e.reincarnationcounter/10+1,2),1),e.reincarnationcounter>=5&&(s*=Math.max(1,e.reincarnationcounter/10))),(t==="transcension"||t==="transcensionChallenge"||t==="reincarnation"||t==="reincarnationChallenge")&&(l+=2,e.reincarnationCount>0&&(l+=2),e.achievements[44]>.5&&(l+=15*Math.min(e.transcendcounter/1800,1)),e.challengecompletions[2]>0&&(l+=1),l+=.2*e.researches[24],l+=1/200*o.rune5level*o.effectiveLevelMult*(1+e.researches[85]/200),l*=1+Math.pow(f.log(e.transcendShards.add(1),10),1/2)/5,l*=1+_("reincarnation",e.challengecompletions[8])/25,l*=Math.min(Math.pow(e.transcendcounter/10,2),1),e.transcendCount>=5&&(l*=Math.max(1,e.transcendcounter/10))),c+=1,(e.transcendCount>0||e.reincarnationCount>0)&&(c+=1),e.reincarnationCount>0&&(c+=2),e.achievements[37]>.5&&(c+=15*Math.min(e.prestigecounter/1800,1)),e.challengecompletions[2]>0&&(c+=1),c+=.2*e.researches[24],c+=1/200*o.rune5level*o.effectiveLevelMult*(1+e.researches[85]/200),c*=1+Math.pow(f.log(e.prestigeShards.add(1),10),1/2)/5,c*=1+_("reincarnation",e.challengecompletions[6])/50,c*=Math.min(Math.pow(e.prestigecounter/10,2),1),e.prestigeCount>=5&&(c*=Math.max(1,e.prestigecounter/10)),a=s+l+c;let p=[1+10*e.achievements[33]/100,1+15*e.achievements[34]/100,1+25*e.achievements[35]/100,1+20*e.upgrades[38]/100,1+e.upgrades[75]*2*Math.min(1,Math.pow(e.maxobtainium/3e7,.5)),1+1/50*e.shopUpgrades.offeringAuto,1+1/25*e.shopUpgrades.offeringEX,1+1/100*e.shopUpgrades.cashGrab,1+1/1e4*ae(e.challengecompletions)*e.researches[85],1+Math.pow(e.antUpgrades[6-1]+o.bonusant6,.66),o.cubeBonusMultiplier[3],1+.02*e.constantUpgrades[3],1+3e-4*e.talismanLevels[3-1]*e.researches[149]+4e-4*e.talismanLevels[3-1]*e.researches[179],1+.12*_("ascension",e.challengecompletions[12]),1+.01/100*e.researches[200],1+Math.min(1,e.ascensionCount/1e6)*e.achievements[187],1+.6*e.achievements[250]+1*e.achievements[251],1+.05*e.cubeUpgrades[46],1+.02/100*e.cubeUpgrades[50],1+e.platonicUpgrades[5],1+2.5*e.platonicUpgrades[10],1+5*e.platonicUpgrades[15],o.challenge15Rewards.offering,1+5*(e.singularityUpgrades.starterPack.getEffect().bonus?1:0),+e.singularityUpgrades.singOfferings1.getEffect().bonus,+e.singularityUpgrades.singOfferings2.getEffect().bonus,+e.singularityUpgrades.singOfferings3.getEffect().bonus,+e.singularityUpgrades.singCitadel.getEffect().bonus,+e.singularityUpgrades.singCitadel2.getEffect().bonus,1+e.cubeUpgrades[54]/100,+e.octeractUpgrades.octeractOfferings1.getEffect().bonus,1+.001*+e.blueberryUpgrades.ambrosiaOffering1.bonus.offeringMult,Math.pow(1.04,e.cubeUpgrades[72]*ae(e.talismanRarity)),wo(),FC(),1+Ye(8)];if(r)a*=be(p);else return p;if(n)return be(p);if(o.eventClicked&&o.isEvent&&(a*=1.05),a/=Le("Offering"),e.currentChallenge.ascension===15&&(a*=1+7*e.cubeUpgrades[62]),a*=1+1/200*e.shopUpgrades.cashGrab2,a*=1+1/100*e.shopUpgrades.offeringEX2*e.singularityCount,a*=Math.pow(1.02,e.shopUpgrades.offeringEX3),a*=xu(),e.singularityChallenges.limitedTime.enabled){let m=e.singularityChallenges.limitedTime.completions,h=e.singChallengeTimer;a*=Td(m,h)}a=Math.min(1e300,a);let g=0;return t==="prestige"&&(g=a/(1+e.prestigecounter)),(t==="transcension"||t==="transcensionChallenge")&&(g=a/(1+e.transcendcounter)),(t==="reincarnation"||t==="reincarnationChallenge")&&(g=a/(1+e.reincarnationcounter)),g>e.offeringpersecond&&(e.offeringpersecond=g),a}var Ar=()=>{if(o.obtainiumGain=1,e.upgrades[69]>0&&(o.obtainiumGain*=Math.min(10,new f(f.pow(f.log(o.reincarnationPointGain.add(10),10),.5)).toNumber())),e.upgrades[72]>0&&(o.obtainiumGain*=Math.min(50,1+2*e.challengecompletions[6]+2*e.challengecompletions[7]+2*e.challengecompletions[8]+2*e.challengecompletions[9]+2*e.challengecompletions[10])),e.upgrades[74]>0&&(o.obtainiumGain*=1+4*Math.min(1,Math.pow(e.maxofferings/1e5,.5))),o.obtainiumGain*=1+e.researches[65]/5,o.obtainiumGain*=1+e.researches[76]/10,o.obtainiumGain*=1+e.researches[81]/10,o.obtainiumGain*=1+e.shopUpgrades.obtainiumAuto/50,o.obtainiumGain*=1+e.shopUpgrades.cashGrab/100,o.obtainiumGain*=1+1/25*e.shopUpgrades.obtainiumEX,o.obtainiumGain*=1+o.rune5level/200*o.effectiveLevelMult*(1+e.researches[84]/200*(1+1*o.effectiveRuneSpiritPower[5]*Xe()/400)),o.obtainiumGain*=1+.01*e.achievements[84]+.03*e.achievements[91]+.05*e.achievements[98]+.07*e.achievements[105]+.09*e.achievements[112]+.11*e.achievements[119]+.13*e.achievements[126]+.15*e.achievements[133]+.17*e.achievements[140]+.19*e.achievements[147],o.obtainiumGain*=1+2*Math.pow((e.antUpgrades[10-1]+o.bonusant10)/50,2/3),o.obtainiumGain*=1+e.achievements[188]*Math.min(2,e.ascensionCount/5e6),o.obtainiumGain*=1+.6*e.achievements[250]+1*e.achievements[251],o.obtainiumGain*=o.cubeBonusMultiplier[5],o.obtainiumGain*=1+.04*e.constantUpgrades[4],o.obtainiumGain*=1+.1*e.cubeUpgrades[47],o.obtainiumGain*=1+.1*e.cubeUpgrades[3],o.obtainiumGain*=1+.5*_("ascension",e.challengecompletions[12]),o.obtainiumGain*=1+Xe()/400*o.effectiveRuneSpiritPower[4],o.obtainiumGain*=1+.03*Math.log(e.uncommonFragments+1)/Math.log(4)*e.researches[144],o.obtainiumGain*=1+.02/100*e.cubeUpgrades[50],e.achievements[53]>0&&(o.obtainiumGain*=1+1/800*o.runeSum),e.achievements[128]&&(o.obtainiumGain*=1.5),e.achievements[129]&&(o.obtainiumGain*=1.25),e.achievements[51]>0&&(o.obtainiumGain+=4),e.reincarnationcounter>=2&&(o.obtainiumGain+=1*e.researches[63]),e.reincarnationcounter>=5&&(o.obtainiumGain+=2*e.researches[64]),o.obtainiumGain*=Math.min(1,Math.pow(e.reincarnationcounter/10,2)),e.reincarnationCount>=5&&(o.obtainiumGain*=Math.max(1,e.reincarnationcounter/10)),o.obtainiumGain*=Math.pow(f.log(e.transcendShards.add(1),10)/300,2),o.obtainiumGain=Math.pow(o.obtainiumGain,Math.min(1,o.illiteracyPower[e.usedCorruptions[5]]*(1+9/100*e.platonicUpgrades[9]*Math.min(100,Math.log10(e.researchPoints+10))))),o.obtainiumGain*=1+4/100*e.cubeUpgrades[42],o.obtainiumGain*=1+3/100*e.cubeUpgrades[43],o.obtainiumGain*=1+e.platonicUpgrades[5],o.obtainiumGain*=1+1.5*e.platonicUpgrades[9],o.obtainiumGain*=1+2.5*e.platonicUpgrades[10],o.obtainiumGain*=1+5*e.platonicUpgrades[15],o.obtainiumGain*=o.challenge15Rewards.obtainium,o.obtainiumGain*=1+5*(e.singularityUpgrades.starterPack.getEffect().bonus?1:0),o.obtainiumGain*=+e.singularityUpgrades.singObtainium1.getEffect().bonus,o.obtainiumGain*=+e.singularityUpgrades.singObtainium2.getEffect().bonus,o.obtainiumGain*=+e.singularityUpgrades.singObtainium3.getEffect().bonus,o.obtainiumGain*=1+e.cubeUpgrades[55]/100,o.obtainiumGain*=1+1/200*e.shopUpgrades.cashGrab2,o.obtainiumGain*=1+1/100*e.shopUpgrades.obtainiumEX2*e.singularityCount,o.obtainiumGain*=1+Ye(9),o.obtainiumGain*=+e.singularityUpgrades.singCitadel.getEffect().bonus,o.obtainiumGain*=+e.singularityUpgrades.singCitadel2.getEffect().bonus,o.obtainiumGain*=+e.octeractUpgrades.octeractObtainium1.getEffect().bonus,o.obtainiumGain*=Math.pow(1.02,e.shopUpgrades.obtainiumEX3),o.obtainiumGain*=vo(),o.eventClicked&&o.isEvent&&(o.obtainiumGain*=1.05),e.currentChallenge.ascension===15&&(o.obtainiumGain+=1,o.obtainiumGain*=1+7*e.cubeUpgrades[62]),o.obtainiumGain*=1+.001*+e.blueberryUpgrades.ambrosiaObtainium1.bonus.obtainiumMult,o.obtainiumGain*=vu(),o.obtainiumGain*=wo(),e.singularityChallenges.limitedTime.enabled){let t=e.singularityChallenges.limitedTime.completions,r=e.singChallengeTimer;o.obtainiumGain*=Td(t,r)}o.obtainiumGain*=Math.pow(1.04,e.cubeUpgrades[71]*ae(e.talismanRarity)),isFinite(o.obtainiumGain)||(o.obtainiumGain=1e300),o.obtainiumGain=Math.min(1e300,o.obtainiumGain),o.obtainiumGain/=Le("Obtainium"),e.usedCorruptions[5]>=15&&(o.obtainiumGain=Math.pow(o.obtainiumGain,1/4)),e.usedCorruptions[5]>=16&&(o.obtainiumGain=Math.pow(o.obtainiumGain,1/3)),o.obtainiumGain=Math.max(1+e.singularityCount,o.obtainiumGain),e.currentChallenge.ascension===14&&(o.obtainiumGain=0),e.obtainiumpersecond=Math.min(1e300,o.obtainiumGain)/(.1+e.reincarnationcounter),e.maxobtainiumpersecond=Math.max(e.maxobtainiumpersecond,e.obtainiumpersecond)},ko=()=>.05*(10*e.researches[61]+2*e.researches[62])*e.maxobtainiumpersecond*(1+4*e.cubeUpgrades[3]/5),Pu=()=>{let t=0,r=0;if(e.achievements[135]===1&&(t+=.02),e.achievements[136]===1&&(t+=.02),t+=.02*(e.talismanRarity[4-1]-1),t+=3*e.researches[106]/100,t+=3*e.researches[107]/100,t+=3*e.researches[116]/200,t+=3*e.researches[117]/200,t+=o.cubeBonusMultiplier[9]-1,t+=4e-4*e.cubeUpgrades[50],r+=.06*e.researches[118],r+=4e-4*e.cubeUpgrades[50],e.highestSingularityCount>=7&&(t+=r,r=t),e.highestSingularityCount<7)for(let s=1;s<=5;s++)e.talismanOne[s]===1?o.talisman1Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[1-1]]+t)*e.talismanLevels[1-1]*o.challenge15Rewards.talismanBonus:o.talisman1Effect[s]=(o.talismanNegativeModifier[e.talismanRarity[1-1]]-r)*e.talismanLevels[1-1]*-1*o.challenge15Rewards.talismanBonus,e.talismanTwo[s]===1?o.talisman2Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[2-1]]+t)*e.talismanLevels[2-1]*o.challenge15Rewards.talismanBonus:o.talisman2Effect[s]=(o.talismanNegativeModifier[e.talismanRarity[2-1]]-r)*e.talismanLevels[2-1]*-1*o.challenge15Rewards.talismanBonus,e.talismanThree[s]===1?o.talisman3Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[3-1]]+t)*e.talismanLevels[3-1]*o.challenge15Rewards.talismanBonus:o.talisman3Effect[s]=(o.talismanNegativeModifier[e.talismanRarity[3-1]]-r)*e.talismanLevels[3-1]*-1*o.challenge15Rewards.talismanBonus,e.talismanFour[s]===1?o.talisman4Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[4-1]]+t)*e.talismanLevels[4-1]*o.challenge15Rewards.talismanBonus:o.talisman4Effect[s]=(o.talismanNegativeModifier[e.talismanRarity[4-1]]-r)*e.talismanLevels[4-1]*-1*o.challenge15Rewards.talismanBonus,e.talismanFive[s]===1?o.talisman5Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[5-1]]+t)*e.talismanLevels[5-1]*o.challenge15Rewards.talismanBonus:o.talisman5Effect[s]=(o.talismanNegativeModifier[e.talismanRarity[5-1]]-r)*e.talismanLevels[5-1]*-1*o.challenge15Rewards.talismanBonus,e.talismanSix[s]===1?o.talisman6Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[6-1]]+t)*e.talismanLevels[6-1]*o.challenge15Rewards.talismanBonus:o.talisman6Effect[s]=(o.talismanNegativeModifier[e.talismanRarity[6-1]]-r)*e.talismanLevels[6-1]*-1*o.challenge15Rewards.talismanBonus,e.talismanSeven[s]===1?o.talisman7Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[7-1]]+t)*e.talismanLevels[7-1]*o.challenge15Rewards.talismanBonus:o.talisman7Effect[s]=(o.talismanNegativeModifier[e.talismanRarity[7-1]]-r)*e.talismanLevels[7-1]*-1*o.challenge15Rewards.talismanBonus;else for(let s=1;s<=5;s++)o.talisman1Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[1-1]]+t)*e.talismanLevels[1-1]*o.challenge15Rewards.talismanBonus,o.talisman2Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[2-1]]+t)*e.talismanLevels[2-1]*o.challenge15Rewards.talismanBonus,o.talisman3Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[3-1]]+t)*e.talismanLevels[3-1]*o.challenge15Rewards.talismanBonus,o.talisman4Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[4-1]]+t)*e.talismanLevels[4-1]*o.challenge15Rewards.talismanBonus,o.talisman5Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[5-1]]+t)*e.talismanLevels[5-1]*o.challenge15Rewards.talismanBonus,o.talisman6Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[6-1]]+t)*e.talismanLevels[6-1]*o.challenge15Rewards.talismanBonus,o.talisman7Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[7-1]]+t)*e.talismanLevels[7-1]*o.challenge15Rewards.talismanBonus;let n=[o.talisman1Effect,o.talisman2Effect,o.talisman3Effect,o.talisman4Effect,o.talisman5Effect,o.talisman6Effect,o.talisman7Effect],a=[0,0,0,0,0,0];n.forEach(s=>{s.forEach((l,c)=>{a[c]+=l})}),[,o.rune1Talisman,o.rune2Talisman,o.rune3Talisman,o.rune4Talisman,o.rune5Talisman]=a,o.talisman6Power=0,o.talisman7Quarks=0,e.talismanRarity[1-1]===6&&(o.rune2Talisman+=400),e.talismanRarity[2-1]===6&&(o.rune1Talisman+=400),e.talismanRarity[3-1]===6&&(o.rune4Talisman+=400),e.talismanRarity[4-1]===6&&(o.rune3Talisman+=400),e.talismanRarity[5-1]===6&&(o.rune5Talisman+=400),e.talismanRarity[6-1]===6&&(o.talisman6Power=2.5),e.talismanRarity[7-1]===6&&(o.talisman7Quarks=2)},He=()=>{var t;if(Pu(),e.currentChallenge.reincarnation!==9){let r=(t=e.antUpgrades[8])!=null?t:0;o.rune1level=Math.max(1,e.runelevels[0]+Math.min(1e7,r+o.bonusant9)*1+o.rune1Talisman+7*e.constantUpgrades[7]),o.rune2level=Math.max(1,e.runelevels[1]+Math.min(1e7,r+o.bonusant9)*1+o.rune2Talisman+7*e.constantUpgrades[7]),o.rune3level=Math.max(1,e.runelevels[2]+Math.min(1e7,r+o.bonusant9)*1+o.rune3Talisman+7*e.constantUpgrades[7]),o.rune4level=Math.max(1,e.runelevels[3]+Math.min(1e7,r+o.bonusant9)*1+o.rune4Talisman+7*e.constantUpgrades[7]),o.rune5level=Math.max(1,e.runelevels[4]+Math.min(1e7,r+o.bonusant9)*1+o.rune5Talisman+7*e.constantUpgrades[7])}o.runeSum=ae([o.rune1level,o.rune2level,o.rune3level,o.rune4level,o.rune5level]),Ou()},Ou=()=>{o.blessingMultiplier=1,o.spiritMultiplier=1,o.blessingMultiplier*=1+6.9*e.researches[134]/100,o.blessingMultiplier*=1+(e.talismanRarity[3-1]-1)/10,o.blessingMultiplier*=1+.1*Math.log10(e.epicFragments+1)*e.researches[174],o.blessingMultiplier*=1+2*e.researches[194]/100,e.researches[160]>0&&(o.blessingMultiplier*=Math.pow(1.25,8)),o.spiritMultiplier*=1+8*e.researches[164]/100,e.researches[165]>0&&e.currentChallenge.ascension!==0&&(o.spiritMultiplier*=Math.pow(2,8)),o.spiritMultiplier*=1+.15*Math.log10(e.legendaryFragments+1)*e.researches[189],o.spiritMultiplier*=1+2*e.researches[194]/100,o.spiritMultiplier*=1+(e.talismanRarity[5-1]-1)/100;for(let t=1;t<=5;t++)o.runeBlessings[t]=o.blessingMultiplier*e.runelevels[t-1]*e.runeBlessingLevels[t],o.runeSpirits[t]=o.spiritMultiplier*e.runelevels[t-1]*e.runeSpiritLevels[t];for(let t=1;t<=5;t++)o.runeBlessings[t]<=1e30?o.effectiveRuneBlessingPower[t]=Math.pow(o.runeBlessings[t],1/8)/75*o.challenge15Rewards.blessingBonus:o.runeBlessings[t]>1e30&&(o.effectiveRuneBlessingPower[t]=Math.pow(10,5/2)*Math.pow(o.runeBlessings[t],1/24)/75*o.challenge15Rewards.blessingBonus),o.runeSpirits[t]<=1e25?o.effectiveRuneSpiritPower[t]=Math.pow(o.runeSpirits[t],1/8)/75*o.challenge15Rewards.spiritBonus:o.runeSpirits[t]>1e25&&(o.effectiveRuneSpiritPower[t]=Math.pow(10,25/12)*Math.pow(o.runeSpirits[t],1/24)/75*o.challenge15Rewards.spiritBonus)},Bt=()=>{let t=0;t+=2*(e.talismanRarity[6-1]-1),t+=_("reincarnation",e.challengecompletions[9]),t+=2*e.constantUpgrades[6],t+=12*_("ascension",e.challengecompletions[11]),t+=Math.floor(1/200*e.researches[200]),t*=o.challenge15Rewards.bonusAntLevel;let r=0,n=0;e.currentChallenge.ascension===11&&(r=999),e.currentChallenge.ascension===11&&(n=Math.floor((4*e.challengecompletions[8]+23*e.challengecompletions[9])*Math.max(0,1-e.challengecompletions[11]/10))),o.bonusant1=Math.min(e.antUpgrades[1-1]+r,4*e.researches[97]+t+e.researches[102]+2*e.researches[132]+n),o.bonusant2=Math.min(e.antUpgrades[2-1]+r,4*e.researches[97]+t+e.researches[102]+2*e.researches[132]+n),o.bonusant3=Math.min(e.antUpgrades[3-1]+r,4*e.researches[97]+t+e.researches[102]+2*e.researches[132]+n),o.bonusant4=Math.min(e.antUpgrades[4-1]+r,4*e.researches[97]+t+e.researches[102]+2*e.researches[132]+n),o.bonusant5=Math.min(e.antUpgrades[5-1]+r,4*e.researches[97]+t+e.researches[102]+2*e.researches[132]+n),o.bonusant6=Math.min(e.antUpgrades[6-1]+r,4*e.researches[97]+t+e.researches[102]+2*e.researches[132]+n),o.bonusant7=Math.min(e.antUpgrades[7-1]+r,4*e.researches[98]+t+e.researches[102]+2*e.researches[132]+n),o.bonusant8=Math.min(e.antUpgrades[8-1]+r,4*e.researches[98]+t+e.researches[102]+2*e.researches[132]+n),o.bonusant9=Math.min(e.antUpgrades[9-1]+r,4*e.researches[98]+t+e.researches[102]+2*e.researches[132]+n),o.bonusant10=Math.min(e.antUpgrades[10-1]+r,4*e.researches[98]+t+e.researches[102]+2*e.researches[132]+n),o.bonusant11=Math.min(e.antUpgrades[11-1]+r,4*e.researches[98]+t+e.researches[102]+2*e.researches[132]+n),o.bonusant12=Math.min(e.antUpgrades[12-1]+r,4*e.researches[98]+t+e.researches[102]+2*e.researches[132]+n)},Kn=()=>{o.antELO=0,o.effectiveELO=0;let t=ae(e.antUpgrades);e.antPoints.gte("1e40")&&(o.antELO+=f.log(e.antPoints,10),o.antELO+=1/2*t,o.antELO+=1/10*e.firstOwnedAnts,o.antELO+=1/5*e.secondOwnedAnts,o.antELO+=1/3*e.thirdOwnedAnts,o.antELO+=1/2*e.fourthOwnedAnts,o.antELO+=e.fifthOwnedAnts,o.antELO+=2*e.sixthOwnedAnts,o.antELO+=4*e.seventhOwnedAnts,o.antELO+=8*e.eighthOwnedAnts,o.antELO+=666*e.researches[178],o.antELO*=1+.01*e.achievements[180]+.02*e.achievements[181]+.03*e.achievements[182],o.antELO*=1+e.researches[110]/100,o.antELO*=1+2.5*e.researches[148]/100,e.achievements[176]===1&&(o.antELO+=25),e.achievements[177]===1&&(o.antELO+=50),e.achievements[178]===1&&(o.antELO+=75),e.achievements[179]===1&&(o.antELO+=100),o.antELO+=25*e.researches[108],o.antELO+=25*e.researches[109],o.antELO+=40*e.researches[123],o.antELO+=100*_("reincarnation",e.challengecompletions[10]),o.antELO+=75*e.upgrades[80],o.antELO=1/10*Math.floor(10*o.antELO),o.effectiveELO+=.5*Math.min(3500,o.antELO),o.effectiveELO+=.1*Math.min(4e3,o.antELO),o.effectiveELO+=.1*Math.min(6e3,o.antELO),o.effectiveELO+=.1*Math.min(1e4,o.antELO),o.effectiveELO+=.2*o.antELO,o.effectiveELO+=o.cubeBonusMultiplier[8]-1,o.effectiveELO+=1*e.cubeUpgrades[50],o.effectiveELO*=1+.03*e.upgrades[124])},_C=()=>{o.timeMultiplier=Math.min(1,Math.pow(e.antSacrificeTimer/10,2)),e.achievements[177]===0&&(o.timeMultiplier*=Math.min(1e3,Math.max(1,e.antSacrificeTimer/10))),e.achievements[177]>0&&(o.timeMultiplier*=Math.max(1,e.antSacrificeTimer/10)),o.upgradeMultiplier=1,o.upgradeMultiplier*=1+2*(1-Math.pow(2,-(e.antUpgrades[11-1]+o.bonusant11)/125)),o.upgradeMultiplier*=1+e.researches[103]/20,o.upgradeMultiplier*=1+e.researches[104]/20,e.achievements[132]===1&&(o.upgradeMultiplier*=1.25),e.achievements[137]===1&&(o.upgradeMultiplier*=1.25),o.upgradeMultiplier*=1+20/3*o.effectiveRuneBlessingPower[3],o.upgradeMultiplier*=1+1/50*_("reincarnation",e.challengecompletions[10]),o.upgradeMultiplier*=1+1/50*e.researches[122],o.upgradeMultiplier*=1+3/100*e.researches[133],o.upgradeMultiplier*=1+2/100*e.researches[163],o.upgradeMultiplier*=1+1/100*e.researches[193],o.upgradeMultiplier*=1+1/10*e.upgrades[79],o.upgradeMultiplier*=1+1/4*e.upgrades[40],o.upgradeMultiplier*=o.cubeBonusMultiplier[7],o.upgradeMultiplier*=1+Ye(7),o.upgradeMultiplier=Math.min(1e300,o.upgradeMultiplier)},Xu=()=>{Kn(),_C();let t=1e300,r=Math.min(t,o.timeMultiplier*o.upgradeMultiplier);return{antSacrificePoints:o.effectiveELO*r/85,offerings:Math.min(t,e.offeringpersecond*.15*o.effectiveELO*r/180),obtainium:Math.min(t,e.maxobtainiumpersecond*.24*o.effectiveELO*r/180),talismanShards:o.antELO>500?Math.min(t,Math.max(1,Math.floor(r/210*Math.pow(1/4*Math.max(0,o.effectiveELO-500),2)))):0,commonFragments:o.antELO>750?Math.min(t,Math.max(1,Math.floor(r/110*Math.pow(1/9*Math.max(0,o.effectiveELO-750),1.83)))):0,uncommonFragments:o.antELO>1e3?Math.min(t,Math.max(1,Math.floor(r/170*Math.pow(1/16*Math.max(0,o.effectiveELO-1e3),1.66)))):0,rareFragments:o.antELO>1500?Math.min(t,Math.max(1,Math.floor(r/200*Math.pow(1/25*Math.max(0,o.effectiveELO-1500),1.5)))):0,epicFragments:o.antELO>2e3?Math.min(t,Math.max(1,Math.floor(r/200*Math.pow(1/36*Math.max(0,o.effectiveELO-2e3),1.33)))):0,legendaryFragments:o.antELO>3e3?Math.min(t,Math.max(1,Math.floor(r/230*Math.pow(1/49*Math.max(0,o.effectiveELO-3e3),1.16)))):0,mythicalFragments:o.antELO>5e3?Math.min(t,Math.max(1,Math.floor(r/220*Math.pow(1/64*Math.max(0,o.effectiveELO-4150),1)))):0}},U0=async()=>{let t=await Ee(u.t("calculate.timePrompt")),r=Number(t);if(Number.isNaN(r)||r<=0)return P(u.t("calculate.timePromptError"));i("offlineContainer").style.display="flex",i("offlineBlur").style.display="",wd(r)},wd=async(t=0)=>{Tl(),o.timeWarp=!0;let r=(86400*3+7200*2*e.researches[31]+7200*2*e.researches[32])*xe.OFFLINE_TIMER_CAP_BUFF,n=Date.now(),a=Math.min(r,Math.max(t,(n-e.offlinetick)/1e3)),s=a/200,l=200;i("offlineTimer").textContent=u.t("calculate.offlineTimer",{value:d(a,0)}),bs(e.buyTalismanShardPercent),Kt();let c=e.offlinetick>0;e.offlinetick=e.offlinetick<15e11?Date.now():e.offlinetick,o.timeMultiplier=qe().mult,Ar();let p=ko(),g={prestige:a/Math.max(.01,e.fastestprestige),offering:Math.floor(a),transcension:a/Math.max(.01,e.fastesttranscend),reincarnation:a/Math.max(.01,e.fastestreincarnate),obtainium:a*p*o.timeMultiplier},m={prestige:a*o.timeMultiplier,transcension:a*o.timeMultiplier,reincarnation:a*o.timeMultiplier,ants:a*o.timeMultiplier,antsReal:a,ascension:e.ascensionCounter,quarks:Ut().gain};Ql(),Ie("ascension",a),Ie("quarks",a),Ie("goldenQuarks",a),Ie("singularity",a),Ie("octeracts",s),Ie("ambrosia",a),e.prestigeCount+=g.prestige,e.transcendCount+=g.transcension,e.reincarnationCount+=g.reincarnation,m.ascension=e.ascensionCounter-m.ascension,m.quarks=Ut().gain-m.quarks;let h=It(()=>{o.timeMultiplier=qe().mult,Ar(),Ie("prestige",s),Ie("transcension",s),Ie("reincarnation",s),Ie("octeracts",s),kd(s*o.timeMultiplier),e.researches[61]>0&&e.currentChallenge.ascension!==14&&Or("addObtainium",s),e.achievements[173]>0&&Or("antSacrifice",s),Or("addOfferings",s),e.shopUpgrades.offeringAuto>0&&e.autoSacrificeToggle&&Or("runeSacrifice",s),l%5===1&&Oo(),l-=1,l<1&&(Ba(h),o.timeWarp=!1)},0);if(i("offlinePrestigeCountNumber").textContent=d(g.prestige,0,!0),i("offlinePrestigeTimer").innerHTML=u.t("offlineProgress.currentPrestigeTimer",{value:d(m.prestige,2,!1)}),i("offlineOfferingCount").innerHTML=u.t("offlineProgress.offeringsGenerated",{value:d(g.offering,0,!0)}),i("offlineTranscensionCount").innerHTML=u.t("offlineProgress.transcensionCount",{value:d(g.transcension,0,!0)}),i("offlineTranscensionTimer").innerHTML=u.t("offlineProgress.currentTranscensionCounter",{value:d(m.transcension,2,!1)}),i("offlineReincarnationCount").innerHTML=u.t("offlineProgress.reincarnationCount",{value:d(g.reincarnation,0,!0)}),i("offlineReincarnationTimer").innerHTML=u.t("offlineProgress.currentReincarnationTimer",{value:d(m.reincarnation,2,!1)}),i("offlineObtainiumCount").innerHTML=u.t("offlineProgress.obtainiumGenerated",{value:d(g.obtainium,0,!0)}),i("offlineAntTimer").innerHTML=u.t("offlineProgress.ingameAntSacTimer",{value:d(m.ants,2,!1)}),i("offlineRealAntTimer").innerHTML=u.t("offlineProgress.realAntSacTimer",{value:d(m.antsReal,2,!0)}),i("offlineAscensionTimer").innerHTML=u.t("offlineProgress.currentAscensionTimer",{value:d(m.ascension,2,!0)}),i("offlineQuarkCount").innerHTML=u.t("offlineProgress.exportQuarks",{value:d(m.quarks,0,!0)}),i("progressbardescription").textContent=u.t("calculate.offlineEarnings"),e.offlinetick=n,!e.loadedNov13Vers){if(e.challengecompletions[14]>0||e.highestchallengecompletions[14]>0){let b=e.ascensionCount;Pe("ascensionChallenge"),e.ascensionCount=b+1}e.loadedNov13Vers=!0}if(hr(),Kt(),Ar(),Bt(),He(),c){let b=i("notification");b.classList.add("slide-out"),b.classList.remove("slide-in"),document.body.classList.remove("scrollbar"),document.body.classList.add("loading"),i("exitOffline").style.visibility="hidden",i("offlineContainer").style.display="flex",i("transparentBG").style.display="block"}else Ds()},Ds=()=>{document.body.classList.remove("loading"),document.body.classList.add("scrollbar"),i("transparentBG").style.display="none",i("offlineContainer").style.display="none",i("offlineBlur").style.display="none",Io()},ut=(t,r,n)=>1+(t-1)*(1-Math.pow(2,-r/n)),Nt=(t,r)=>1+(t-1)*(1-Math.exp(-r)),Gt=()=>{let t=[e.cubeBlessings.accelerator,e.cubeBlessings.multiplier,e.cubeBlessings.offering,e.cubeBlessings.runeExp,e.cubeBlessings.obtainium,e.cubeBlessings.antSpeed,e.cubeBlessings.antSacrifice,e.cubeBlessings.antELO,e.cubeBlessings.talismanBonus,e.cubeBlessings.globalSpeed],r=[e.cubeUpgrades[45]/100,e.cubeUpgrades[35]/100,e.cubeUpgrades[24]/100,e.cubeUpgrades[14]/100,e.cubeUpgrades[40]/100,e.cubeUpgrades[22]/40,e.cubeUpgrades[15]/100,e.cubeUpgrades[25]/100,e.cubeUpgrades[44]/100,e.cubeUpgrades[34]/100];for(let n=1;n<=10;n++){let a=1,s=1;t[n-1]>=1e3&&(a=o.blessingDRPower[n],s*=Math.pow(1e3,(1-o.blessingDRPower[n])*(1+r[n-1]))),n===6&&(a=2.25,s=1),o.cubeBonusMultiplier[n]=Math.min(1e300,1+s*o.blessingbase[n]*Math.pow(t[n-1],a*(1+r[n-1]))*o.tesseractBonusMultiplier[n])}He(),Kn(),Ar()},Lo=()=>{if(e.singularityChallenges.noOcteracts.enabled)return 1;if(e.totalWowOcteracts<1e3){let t=1+.002*e.totalWowOcteracts;return t>1.00001?t:1}else{let t=2+ +e.singularityChallenges.noOcteracts.rewards.octeractPow;return 3*Math.pow(Math.log10(e.totalWowOcteracts)-2,t)}},fn=()=>{if(e.singularityChallenges.noOcteracts.enabled)return 1;if(e.totalWowOcteracts<1e3){let t=1+2e-4*e.totalWowOcteracts;return t>1.00001?t:1}else return 1.1+.1*(Math.log10(e.totalWowOcteracts)-2)},xu=()=>e.singularityChallenges.noOcteracts.rewards.offeringBonus?Math.pow(fn(),1.5):1,vo=()=>e.singularityChallenges.noOcteracts.rewards.obtainiumBonus?Math.pow(fn(),1.4):1,Qn=()=>{let t=1;if(e.singularityChallenges.limitedTime.enabled){let a=e.singularityChallenges.limitedTime.completions,s=e.singChallengeTimer;t=Td(a,s)}let r=[xe.CUBE_BUFF,Math.pow(Math.min(1,e.ascensionCounter/10),2)*(1+(1/4*e.achievements[204]+1/4*e.achievements[211]+1/2*e.achievements[218])*Math.max(0,e.ascensionCounter/10-1)),1+6/100*e.achievements[250]+10/100*e.achievements[251],1+e.achievements[240]*Math.min(.5,Math.max(.1,1/20*Math.log10(qe().mult+.01))),o.challenge15Rewards.cube1*o.challenge15Rewards.cube2*o.challenge15Rewards.cube3*o.challenge15Rewards.cube4*o.challenge15Rewards.cube5,1+1/100*$n(),1+e.platonicUpgrades[10],Math.pow(1.01,e.platonicUpgrades[15]*e.challengecompletions[9]),Bi(),1+Ye(2),1/Le("Cubes"),1+.75*e.shopUpgrades.seasonPassY/100,1+4*(e.singularityUpgrades.starterPack.getEffect().bonus?1:0),+e.singularityUpgrades.singCubes1.getEffect().bonus,+e.singularityUpgrades.singCubes2.getEffect().bonus,+e.singularityUpgrades.singCubes3.getEffect().bonus,1+e.shopUpgrades.seasonPassZ*e.singularityCount/100,1+1*e.cubeUpgrades[66]*(1-e.platonicUpgrades[15]),1+.25*+o.isEvent*e.cubeUpgrades[58],Lo(),+e.singularityChallenges.noSingularityUpgrades.rewards.cubes,+e.singularityUpgrades.singCitadel.getEffect().bonus,+e.singularityUpgrades.singCitadel2.getEffect().bonus,1+ +e.singularityUpgrades.platonicDelta.getEffect().bonus*Math.min(9,e.shopUpgrades.shopSingularitySpeedup>0?e.singularityCounter*50/(3600*24):e.singularityCounter/(3600*24)),Math.pow(1.02,e.shopUpgrades.seasonPassInfinity),pl(),+e.blueberryUpgrades.ambrosiaTutorial.bonus.cubes,+e.blueberryUpgrades.ambrosiaCubes1.bonus.cubes,+e.blueberryUpgrades.ambrosiaLuckCube1.bonus.cubes,+e.blueberryUpgrades.ambrosiaQuarkCube1.bonus.cubes,+e.blueberryUpgrades.ambrosiaCubes2.bonus.cubes,+e.blueberryUpgrades.ambrosiaHyperflux.bonus.hyperFlux,+wo(),+Fi(),+R0(),t],n=o.isEvent&&o.eventClicked?1.05:1;return{mult:be(r)*n,list:r}},rl=(t=-1)=>{t<0&&(t=Tn().effectiveScore);let r=[Math.pow(t/3e3,1/4.1),Qn().mult,1+2.25*e.shopUpgrades.seasonPass/100,(1+e.researches[119]/400)*(1+e.researches[120]/400)*(1+e.researches[137]/100)*(1+.9*e.researches[152]/100)*(1+.8*e.researches[167]/100)*(1+.7*e.researches[182]/100)*(1+.03/100*e.researches[192]*e.antUpgrades[12-1])*(1+.6*e.researches[197]/100),1+.004/100*e.researches[200],(1+e.cubeUpgrades[1]/6)*(1+e.cubeUpgrades[11]/11)*(1+.4*e.cubeUpgrades[30]),1+.01*f.log(e.ascendShards.add(1),4)*Math.min(1,e.constantUpgrades[10]),1+e.achievements[189]*Math.min(2,e.ascensionCount/25e7),1+e.achievements[193]*f.log(e.ascendShards.add(1),10)/400,1+Math.min(250,e.achievements[195]*f.log(e.ascendShards.add(1),10)/400),1+4/100*(e.achievements[198]+e.achievements[199]+e.achievements[200])+3/100*e.achievements[201],1+Math.min(.15,.6/100*Math.log10(t+1))*e.achievements[254],1+Xe()/400*o.effectiveRuneSpiritPower[2],o.platonicBonusMultiplier[0],1+9e-5*ae(e.usedCorruptions)*e.platonicUpgrades[1],1+Math.pow(1.03,Math.log10(Math.max(1,e.wowAbyssals)))*e.cubeUpgrades[63]-e.cubeUpgrades[63]];return{list:r,mult:be(r)}},nl=(t=-1)=>{t<0&&(t=Tn().effectiveScore);let r=ae(e.usedCorruptions.slice(2,10)),n=[Math.pow(1+Math.max(0,t-1e5)/1e4,.35),Qn().mult,1+2.25*e.shopUpgrades.seasonPass/100,1+.01*f.log(e.ascendShards.add(1),4)*Math.min(1,e.constantUpgrades[10]),1+.4*e.cubeUpgrades[30],1+1/200*e.cubeUpgrades[38]*r,1+Math.min(250,e.achievements[195]*f.log(e.ascendShards.add(1),10)/400),1+e.achievements[202]*Math.min(2,e.ascensionCount/5e8),1+4/100*(e.achievements[205]+e.achievements[206]+e.achievements[207])+3/100*e.achievements[208],1+Math.min(.15,.6/100*Math.log10(t+1))*e.achievements[255],o.platonicBonusMultiplier[1],1+18e-5*r*e.platonicUpgrades[2]];return{list:n,mult:be(n)}},al=(t=-1)=>{t<0&&(t=Tn().effectiveScore);let r=[Math.pow(1+Math.max(0,t-1e9)/1e8,.5),Qn().mult,1+1.5*e.shopUpgrades.seasonPass2/100,1+4/100*(e.achievements[212]+e.achievements[213]+e.achievements[214])+3/100*e.achievements[215],1+e.achievements[216]*Math.min(2,e.ascensionCount/1e9),1+1/10*e.achievements[253],1+Math.min(.15,.6/100*Math.log10(t+1))*e.achievements[256],1+Math.min(2,e.ascensionCount/25e9)*e.achievements[265],o.platonicBonusMultiplier[2],1+54e-5*ae(e.usedCorruptions)*e.platonicUpgrades[3],1+.6/1e3*Ve("hyperrealism")];return{list:r,mult:be(r)}},sl=(t=-1)=>{t<0&&(t=Tn().effectiveScore);let r=[Math.pow(1+Math.max(0,t-2666e9)/2666e8,.75),Qn().mult,1+1.5*e.shopUpgrades.seasonPass2/100,1+Math.min(20,e.achievements[196]*1/5e3*f.log(e.ascendShards.add(1),10)),1+4/100*(e.achievements[219]+e.achievements[220]+e.achievements[221])+3/100*e.achievements[222],1+e.achievements[223]*Math.min(2,e.ascensionCount/1337e6),1+Math.min(.15,.6/100*Math.log10(t+1))*e.achievements[257],o.platonicBonusMultiplier[3],1+1.2*e.platonicUpgrades[4]/50];return{list:r,mult:be(r)}},ol=(t=-1)=>{t<0&&(t=Tn().effectiveScore);let r=[Math.pow(1+Math.max(0,t-1666e13)/333e14,.85),Qn().mult,1+1.5*e.shopUpgrades.seasonPass3/100,1+Math.min(.15,.6/100*Math.log10(t+1))*e.achievements[258],1+Math.min(.4,e.ascensionCount/2e13)*e.achievements[264],1+Math.min(.2,e.ascensionCount/8e14)*e.achievements[265],Math.min(2,1+1/1e6*f.log(e.ascendShards.add(1),10)*e.achievements[270])];return{list:r,mult:be(r)}},B0=()=>{let t=ae(e.usedCorruptions.slice(2,10));return[xe.CUBE_BUFF,1+1.5*e.shopUpgrades.seasonPass3/100,1+.75*e.shopUpgrades.seasonPassY/100,1+e.shopUpgrades.seasonPassZ*e.singularityCount/100,1+e.shopUpgrades.seasonPassLost/1e3,1+ +(t>=14*8)*e.cubeUpgrades[70]/1e4,1+ +(t>=14*8)*+e.singularityUpgrades.divinePack.getEffect().bonus,+e.singularityUpgrades.singCubes1.getEffect().bonus,+e.singularityUpgrades.singCubes2.getEffect().bonus,+e.singularityUpgrades.singCubes3.getEffect().bonus,+e.singularityUpgrades.singOcteractGain.getEffect().bonus,+e.singularityUpgrades.singOcteractGain2.getEffect().bonus,+e.singularityUpgrades.singOcteractGain3.getEffect().bonus,+e.singularityUpgrades.singOcteractGain4.getEffect().bonus,+e.singularityUpgrades.singOcteractGain5.getEffect().bonus,1+er()/100*+e.singularityUpgrades.singOcteractPatreonBonus.getEffect().bonus,1+.2*+e.octeractUpgrades.octeractStarter.getEffect().bonus,+e.octeractUpgrades.octeractGain.getEffect().bonus,+e.octeractUpgrades.octeractGain2.getEffect().bonus,QC(),Math.pow(1+ +e.octeractUpgrades.octeractAscensionsOcteractGain.getEffect().bonus,1+Math.floor(Math.log10(1+e.ascensionCount))),1+Ye(10),1+ +e.singularityUpgrades.platonicDelta.getEffect().bonus*Math.min(9,e.shopUpgrades.shopSingularitySpeedup>0?e.singularityCounter*50/(3600*24):e.singularityCounter/(3600*24)),+e.singularityChallenges.noSingularityUpgrades.rewards.cubes,Math.pow(1.02,e.shopUpgrades.seasonPassInfinity),pl(),+e.blueberryUpgrades.ambrosiaTutorial.bonus.cubes,+e.blueberryUpgrades.ambrosiaCubes1.bonus.cubes,+e.blueberryUpgrades.ambrosiaLuckCube1.bonus.cubes,+e.blueberryUpgrades.ambrosiaQuarkCube1.bonus.cubes,+e.blueberryUpgrades.ambrosiaCubes2.bonus.cubes,+Fi(),+R0()]},Kr=()=>{let r=Tn().effectiveScore,n=r>=1e23?r/1e23:0,a=B0(),s=e.singularityUpgrades.oneMind.getEffect().bonus?Math.pow(10,1/2):Math.pow(Ur(),1/2),l=e.singularityUpgrades.oneMind.getEffect().bonus?Math.pow(Ur()/10,+e.octeractUpgrades.octeractOneMindImprover.getEffect().bonus):1,c=o.isEvent&&o.eventClicked?1.05:1;return 1/(24*3600*365*1e15)*n*be(a)*s*l*c},Lm=(t=-1)=>{t<0&&(t=Tn().effectiveScore);let n=B0();n.unshift(t>=1e23?t/1e23:0);let a=Ur(),s=e.singularityUpgrades.oneMind.getEffect().bonus?Math.pow(10,1/2)*Math.pow(a/10,+e.octeractUpgrades.octeractOneMindImprover.getEffect().bonus):Math.pow(a,1/2);return n.push(s),{list:n,mult:be(n)}},qe=()=>{let t=[1+.0033333333333333335*Math.log10(e.maxobtainium+1)*e.upgrades[70],1+e.researches[121]/50,1+.015*e.researches[136],1+.012*e.researches[151],1+.009*e.researches[166],1+.006*e.researches[181],1+.003*e.researches[196],1+8*o.effectiveRuneBlessingPower[1],1+Xe()/400*o.effectiveRuneSpiritPower[1],o.cubeBonusMultiplier[10],1+e.cubeUpgrades[18]/5,ut(2,e.antUpgrades[11]+o.bonusant12,69),1+.1*(e.talismanRarity[1]-1),o.challenge15Rewards.globalSpeed,1+.01*e.cubeUpgrades[52]],r=[o.lazinessMultiplier[e.usedCorruptions[3]]],n=be(t)*r[0];if(n>100){let c=10*Math.sqrt(n)/n;r.push(c)}else r.push(1);if(n<1){let c=Math.pow(n,1-e.platonicUpgrades[7]/30)/n;r.push(c)}else r.push(1);r.push(1/Le("Global Speed"));let a=[o.platonicBonusMultiplier[7],1+(e.singularityUpgrades.intermediatePack.getEffect().bonus?1:0),1+ +e.octeractUpgrades.octeractImprovedGlobalSpeed.getEffect().bonus*e.singularityCount,1+ +e.singularityChallenges.limitedTime.rewards.globalSpeed,Math.max(Math.pow(1.01,(e.singularityCount-200)*e.shopUpgrades.shopChronometerS),1)],s=be(t)*be(r)*be(a);return e.usedCorruptions[3]>=6&&e.achievements[241]<1&&R(241),s>3600&&e.achievements[242]<1&&R(242),{preList:t,drList:r,postList:a,mult:s}},DC=()=>{if(e.singularityChallenges.limitedAscensions.enabled){let t=e.ascensionCount-Math.max(0,20-e.singularityChallenges.limitedAscensions.completions);return t=Math.max(0,t),Math.pow(2,t)}else return 1},hu=()=>{let t=[1+.012*e.shopUpgrades.chronometer,1+.006*e.shopUpgrades.chronometer2,1+.015*e.shopUpgrades.chronometer3,1+6e-4*Ve("chronos"),1+Math.min(.1,.01*Math.log10(e.ascensionCount+1))*e.achievements[262],1+Math.min(.1,.01*Math.log10(e.ascensionCount+1))*e.achievements[263],1+.002*ae(e.usedCorruptions)*e.platonicUpgrades[15],o.challenge15Rewards.ascensionSpeed,1+.0025*e.cubeUpgrades[59],1+.5*(e.singularityUpgrades.intermediatePack.getEffect().bonus?1:0),1+.001*e.singularityCount*e.shopUpgrades.chronometerZ,1+ +e.octeractUpgrades.octeractImprovedAscensionSpeed.getEffect().bonus*e.singularityCount,1+ +e.octeractUpgrades.octeractImprovedAscensionSpeed2.getEffect().bonus*e.singularityCount,1+Ye(4),e.singularityUpgrades.singAscensionSpeed2.level>0&&e.runelevels[6]<1?6:1,Math.pow(1.01,e.shopUpgrades.chronometerInfinity),1/DC(),Math.pow(1+ +e.singularityChallenges.limitedAscensions.rewards.ascensionSpeedMult,1+Math.max(0,Math.floor(Math.log10(e.ascensionCount)))),1+ +e.singularityChallenges.limitedTime.rewards.ascensionSpeed,Math.max(Math.pow(1.01,(e.singularityCount-200)*e.shopUpgrades.shopChronometerS),1)],r=be(t),n=e.singularityUpgrades.singAscensionSpeed.level>0?r>=1?1.03:.97:1;t.push(Math.pow(r,n)/r),t.push(1/Le("Ascension Speed"));let a=be(t);return isFinite(a)||(a=0),{list:t,mult:a}},Ur=()=>hu().mult,bu=()=>{let t=1,r=[5,7,10,20,35,50,65,80,90,100,121,144,150,160,166,169,170,175,180,190,196,200,201,202,203,204,205,210,212,214,216,218,220,225,250,255,260,261,262];for(let n of r)e.highestSingularityCount>=n&&(t*=1.05);return e.highestSingularityCount>=200&&(t*=Math.pow((e.highestSingularityCount-179)/20,2)),t},yi=()=>{let t=1;return e.achievementPoints>0&&(t+=e.achievementPoints/25e3),e.achievements[250]>0&&(t+=.1),e.achievements[251]>0&&(t+=.1),e.platonicUpgrades[5]>0&&(t+=.2),e.platonicUpgrades[10]>0&&(t+=.25),e.platonicUpgrades[15]>0&&(t+=.3),e.challenge15Exponent>=1e11&&(t+=o.challenge15Rewards.quarks-1),ha()&&(t*=1.1+.15/75*$n()),e.challenge15Exponent>=1e15&&(t*=1+5/1e4*Ve("quark")),e.overfluxPowder>0&&(t*=ss()),e.achievements[266]>0&&(t*=1+Math.min(.1,e.ascensionCount/1e16)),e.singularityCount>0&&(t*=1+e.singularityCount/10),o.isEvent&&(t*=1+Ye(0)+Ye(13)),e.cubeUpgrades[53]>0&&(t*=1+.1*e.cubeUpgrades[53]/100),e.cubeUpgrades[68]>0&&(t*=1+1/1e4*e.cubeUpgrades[68]+.05*Math.floor(e.cubeUpgrades[68]/1e3)),t*=bu(),t*=+e.octeractUpgrades.octeractQuarkGain.getEffect().bonus,t*=1+.4*+e.octeractUpgrades.octeractStarter.getEffect().bonus,t*=1+1/1e4*Math.floor(e.octeractUpgrades.octeractQuarkGain.level/111)*e.octeractUpgrades.octeractQuarkGain2.level*Math.floor(1+Math.log10(Math.max(1,e.hepteractCrafts.quark.BAL))),t*=1+.02*e.singularityUpgrades.intermediatePack.level+.04*e.singularityUpgrades.advancedPack.level+.06*e.singularityUpgrades.expertPack.level+.08*e.singularityUpgrades.masterPack.level+.1*e.singularityUpgrades.divinePack.level,t*=1+ +e.singularityUpgrades.singQuarkImprover1.getEffect().bonus,t*=fn(),t*=Co(),t*=+e.blueberryUpgrades.ambrosiaTutorial.bonus.quarks,t*=+e.blueberryUpgrades.ambrosiaQuarks1.bonus.quarks,t*=+e.blueberryUpgrades.ambrosiaCubeQuark1.bonus.quarks,t*=+e.blueberryUpgrades.ambrosiaLuckQuark1.bonus.quarks,t*=+e.blueberryUpgrades.ambrosiaQuarks2.bonus.quarks,t*=go(),t*=1+ +e.singularityChallenges.limitedTime.rewards.quarkMult,t*=1+ +e.singularityChallenges.sadisticPrequel.rewards.quarkMult,e.highestSingularityCount===0&&(t*=1.25),t},yu=(t=!1)=>{let r=2*e.singularityCount+10,n=e.singularityCount<10?200-10*e.singularityCount:0;e.singularityCount===0&&(n+=200);let a=1;e.highestSingularityCount>=200&&(a=3),e.highestSingularityCount>=208&&(a=5),e.highestSingularityCount>=221&&(a=8);let s=[xe.GOLDEN_QUARK_BUFF,1+Math.max(0,Math.log10(e.challenge15Exponent+1)-20)/2,1+er()/100,+e.singularityUpgrades.goldenQuarks1.getEffect().bonus,1+.12*e.cubeUpgrades[69],+e.singularityChallenges.noSingularityUpgrades.rewards.goldenQuarks,1+Ye(1),1+ua(),e.highestSingularityCount>=100?1+Math.min(1,e.highestSingularityCount/250):1,a];return s.push(t?1/1e5:((r+e.quarksThisSingularity/1e5)*be(s)+n)/be(s)),{list:s,mult:be(s)}},Wt=(t=!1)=>yu(t).mult,Xe=()=>{let t=400,r=e.singularityUpgrades.corruptionFifteen.getEffect().bonus?1:0;for(let n=1;n<=9;n++)t+=16*Math.pow(e.usedCorruptions[n]+r,2);return t},jn=(t,r,n,a=1e9)=>{let s=r*t*(1+t)/2,l=Math.min(t+a,Math.floor(-1/2+Math.sqrt(1/4+2*(n+s)/r))),c=r*l*(1+l)/2-s;return[l,c]},rr=(t,r,n,a,s)=>{let l=a/2;n=n||0;let c=r*(l*Math.pow(t,2)+t*(1-l));n+=c;let p=n/r,g=l>0?Math.max(0,Math.floor((l-1)/(2*l)+Math.pow(Math.pow(1-l,2)+4*l*p,1/2)/(2*l))):Math.floor(p);g=Math.min(g,s+t),g=Math.max(g,t);let m=r*(l*Math.pow(g,2)+g*(1-l))-c;return g===t&&(m=r*(1+2*l*t)),{levelCanBuy:g,cost:m}},P0=t=>t<0||!Number.isInteger(t)?-1:Math.pow(t*(t+1)/2,2),GC=(t,r,n,a)=>{if(t<0)throw new Error(String(u.t("calculate.quadraticImproperError")));let s=Math.pow(r,2)-4*t*n;if(s<0)throw new Error(String(u.t("calculate.quadraticDeterminantError")));if(s===0)return-r/(2*t);let l=-r+Math.sqrt(Math.pow(r,2)-4*t*n),c=-r-Math.sqrt(Math.pow(r,2)-4*t*n);return a?l/(2*t):c/(2*t)},Sg=(t,r,n,a)=>{if(t>=a)return{levelCanBuy:a,cost:0};let s=r*P0(t),l=s+n;if(l<0)throw new Error(String(u.t("calculate.cubicSumNegativeError")));let c=Math.pow(l/r,.5),p=GC(1,1,-2*c,!0),g=Math.max(Math.min(a,Math.floor(p)),t),m=g===t?r*Math.pow(t+1,3):r*P0(g)-s;return{levelCanBuy:g,cost:m}},HC=()=>{let t=1;return t*=o.challenge15Rewards.score,t*=o.platonicBonusMultiplier[6],e.cubeUpgrades[21]>0&&(t*=1+.05*e.cubeUpgrades[21]),e.cubeUpgrades[31]>0&&(t*=1+.05*e.cubeUpgrades[31]),e.cubeUpgrades[41]>0&&(t*=1+.05*e.cubeUpgrades[41]),e.achievements[267]>0&&(t*=1+Math.min(1,1/1e5*f.log(e.ascendShards.add(1),10))),e.achievements[259]>0&&(t*=Math.max(1,Math.pow(1.01,Math.log2(e.hepteractCrafts.abyss.CAP)))),o.isEvent&&(t*=1+Ye(6)),t},Tn=()=>{let t=0,r=1,n=0,a=e.singularityUpgrades.corruptionFifteen.getEffect().bonus?1:0;a+=+e.singularityChallenges.oneChallengeCap.rewards.freeCorruptionLevel;let s=[0,8,10,12,15,20,60,80,120,180,300],l=[0,10,12,15,20,30,80,120,180,300,450],c=[0,20,30,50,100,200,250,300,400,500,750],p=[0,1e4,1e4,1e4,1e4,1e4,2e3,3e3,4e3,5e3,7500];s[1]+=e.cubeUpgrades[56],s[2]+=e.cubeUpgrades[56],s[3]+=e.cubeUpgrades[56];for(let h=1;h<=10;h++)t+=s[h]*e.highestchallengecompletions[h],h<=5&&e.highestchallengecompletions[h]>=75&&(t+=l[h]*(e.highestchallengecompletions[h]-75),e.highestchallengecompletions[h]>=750&&(t+=c[h]*(e.highestchallengecompletions[h]-750)),e.highestchallengecompletions[h]>=9e3&&(t+=p[h]*(e.highestchallengecompletions[h]-9e3))),h<=10&&h>5&&e.highestchallengecompletions[h]>=25&&(t+=l[h]*(e.highestchallengecompletions[h]-25),e.highestchallengecompletions[h]>=60&&(t+=c[h]*(e.highestchallengecompletions[h]-60)));t*=Math.pow(1.03+.005*e.cubeUpgrades[39]+.0025*(e.platonicUpgrades[5]+e.platonicUpgrades[10]),e.highestchallengecompletions[10]);let g=e.singularityUpgrades.advancedPack.getEffect().bonus?.33:0;g+=+e.singularityChallenges.oneChallengeCap.rewards.corrScoreIncrease,g+=.3*e.cubeUpgrades[74];for(let h=2;h<10;h++){let b=h===2&&e.usedCorruptions[h]>=10?1+2*Math.min(1,e.platonicUpgrades[17])+.04*e.platonicUpgrades[17]:1;r*=Math.pow(o.corruptionPointMultipliers[e.usedCorruptions[h]+a],b)+g,e.usedCorruptions[h]>=14&&e.singularityUpgrades.masterPack.getEffect().bonus&&(r*=1.1)}let m=HC();return n=t*r*m,n>1e23&&(n=Math.pow(n,.5)*Math.pow(1e23,.5)),e.singularityUpgrades.expertPack.getEffect().bonus?n*=1.5:n*=1,{baseScore:t,corruptionMultiplier:r,bonusMultiplier:m,effectiveScore:n}},Xr=()=>{let t=0,r=1,n=Tn(),a=n.baseScore,s=n.corruptionMultiplier,l=n.bonusMultiplier,c=n.effectiveScore;for(let x=1;x<=10;x++)r=x>=6?2:1,t+=r*e.highestchallengecompletions[x];let p=e.singularityUpgrades.oneMind.getEffect().bonus?Ur()/10:1,g=t;g*=rl(c).mult,g*=p;let m=e.singularityUpgrades.platonicTau.getEffect().bonus?1.01:1;g=Math.pow(g,m);let h=1;c>=1e5&&(h+=.5),h*=nl(c).mult,h*=p;let b=c>=1e9?1:0;b*=al(c).mult,b*=p;let C=c>=2666e9?1:0;C*=sl(c).mult,C*=p;let v=o.challenge15Rewards.hepteractUnlocked&&c>=1666e14&&e.achievements[255]>0?1:0;return v*=ol(c).mult,v*=p,[t,Math.floor(a),s,Math.floor(c),Math.min(1e300,Math.floor(g)),Math.min(1e300,Math.max(e.singularityCount,Math.floor(h))),Math.min(1e300,Math.floor(b)),Math.min(1e300,Math.floor(C)),Math.min(1e300,Math.floor(v)),l]},Mo=()=>{let t=1;if(e.singularityChallenges.limitedAscensions.enabled)return t;if(e.challengecompletions[10]>0&&e.achievements[197]===1){let{effectiveScore:r}=Tn();e.ascensionCounter>=10&&(e.achievements[188]>0&&(t+=99),t*=1+(e.ascensionCounter/10-1)*.2*(e.achievements[189]+e.achievements[202]+e.achievements[209]+e.achievements[216]+e.achievements[223])),t*=e.achievements[187]&&Math.floor(r)>1e8?Math.log10(Math.floor(r)+1)-1:1,t*=o.challenge15Rewards.ascensions,t*=e.achievements[260]>0?1.1:1,t*=e.achievements[261]>0?1.1:1,t*=e.platonicUpgrades[15]>0?2:1,t*=1+.02*e.platonicUpgrades[16],t*=1+.02*e.platonicUpgrades[16]*Math.min(1,e.overfluxPowder/1e5),t*=1+e.singularityCount/10,t*=+e.singularityUpgrades.ascensions.getEffect().bonus,t*=+e.octeractUpgrades.octeractAscensions.getEffect().bonus,t*=+e.octeractUpgrades.octeractAscensions2.getEffect().bonus,t*=e.singularityUpgrades.oneMind.getEffect().bonus?Ur()/10:1}return Math.floor(t)},Lr=()=>{let t=[.01,o.challenge15Rewards.powder,1+e.shopUpgrades.powderEX/50,1+e.achievements[256]/20,1+e.achievements[257]/20,1+.01*e.platonicUpgrades[16],1+Ye(3)];return{list:t,mult:be(t)}},Bn=()=>(ut(2,Math.pow(e.overfluxOrbs,.5),40)+ut(1.5,Math.pow(e.overfluxOrbs,.5),160)+ut(1.5,Math.pow(e.overfluxOrbs,.5),640)+ut(1.15,+(e.highestSingularityCount>=1)*Math.pow(e.overfluxOrbs,.45),2560)+ut(1.15,+(e.highestSingularityCount>=2)*Math.pow(e.overfluxOrbs,.4),1e4)+ut(1.25,+(e.highestSingularityCount>=5)*Math.pow(e.overfluxOrbs,.35),4e4)+ut(1.25,+(e.highestSingularityCount>=10)*Math.pow(e.overfluxOrbs,.32),16e4)+ut(1.35,+(e.highestSingularityCount>=15)*Math.pow(e.overfluxOrbs,.27),64e4)+ut(1.45,+(e.highestSingularityCount>=20)*Math.pow(e.overfluxOrbs,.24),2e6)+ut(1.55,+(e.highestSingularityCount>=25)*Math.pow(e.overfluxOrbs,.21),1e7)+ut(1.85,+(e.highestSingularityCount>=30)*Math.pow(e.overfluxOrbs,.18),4e7)+ut(3,+(e.highestSingularityCount>=35)*Math.pow(e.overfluxOrbs,.15),1e8)-11)*(1+1/500*e.shopUpgrades.cubeToQuarkAll)*(e.autoWarpCheck?1+e.dailyPowderResetUses:1),Bi=()=>e.overfluxPowder>1e4?1+1/16*Math.pow(Math.log10(e.overfluxPowder),2):1+1/1e4*e.overfluxPowder,ss=()=>e.overfluxPowder>1e4?1+1/40*Math.log10(e.overfluxPowder):1+1/1e5*e.overfluxPowder,pd=()=>{let t=0,r=[35,42,49,56,63,70,77],n=[135,142,149,156,163,170,177];for(let a of r)e.highestSingularityCount>=a&&(t+=5);for(let a of n)e.highestSingularityCount>=a&&(t+=6);return t},gd=()=>{let t=[1+e.shopUpgrades.shopAmbrosiaGeneration1/100,1+e.shopUpgrades.shopAmbrosiaGeneration2/100,1+e.shopUpgrades.shopAmbrosiaGeneration3/100,1+e.shopUpgrades.shopAmbrosiaGeneration4/1e3];return be(t)},md=()=>{let t=[2*e.shopUpgrades.shopAmbrosiaLuck1,2*e.shopUpgrades.shopAmbrosiaLuck2,2*e.shopUpgrades.shopAmbrosiaLuck3,.6*e.shopUpgrades.shopAmbrosiaLuck4];return ae(t)},fd=()=>{let t=[+e.singularityUpgrades.singAmbrosiaGeneration.getEffect().bonus,+e.singularityUpgrades.singAmbrosiaGeneration2.getEffect().bonus,+e.singularityUpgrades.singAmbrosiaGeneration3.getEffect().bonus,+e.singularityUpgrades.singAmbrosiaGeneration4.getEffect().bonus];return be(t)},hd=()=>{let t=[+e.singularityUpgrades.singAmbrosiaLuck.getEffect().bonus,+e.singularityUpgrades.singAmbrosiaLuck2.getEffect().bonus,+e.singularityUpgrades.singAmbrosiaLuck3.getEffect().bonus,+e.singularityUpgrades.singAmbrosiaLuck4.getEffect().bonus];return ae(t)},bd=()=>{let t=[+e.octeractUpgrades.octeractAmbrosiaGeneration.getEffect().bonus,+e.octeractUpgrades.octeractAmbrosiaGeneration2.getEffect().bonus,+e.octeractUpgrades.octeractAmbrosiaGeneration3.getEffect().bonus,+e.octeractUpgrades.octeractAmbrosiaGeneration4.getEffect().bonus];return be(t)},yd=()=>{let t=[+e.octeractUpgrades.octeractAmbrosiaLuck.getEffect().bonus,+e.octeractUpgrades.octeractAmbrosiaLuck2.getEffect().bonus,+e.octeractUpgrades.octeractAmbrosiaLuck3.getEffect().bonus,+e.octeractUpgrades.octeractAmbrosiaLuck4.getEffect().bonus];return ae(t)},To=()=>{let t=[5e3,25e3,75e3,25e4,5e5,1e6,2e6,4e6,1e7,2e7,4e7,1e8,2e8,4e8,1e9],r=o.TIME_PER_AMBROSIA+Math.floor(e.lifetimeAmbrosia/30),n=0;for(let a of t)r>=a&&n++;return n},Cs=()=>{let t=o.TIME_PER_AMBROSIA;t+=Math.floor(e.lifetimeAmbrosia/30);let r=To();return Math.pow(2,r)*t},vd=()=>{let t=0;return e.highestSingularityCount>=270?t=5:e.highestSingularityCount>=256?t=4:e.highestSingularityCount>=192?t=3:e.highestSingularityCount>=128?t=2:e.highestSingularityCount>=64&&(t=1),t},pl=()=>{let t=e.singularityChallenges.noAmbrosiaUpgrades.enabled?0:e.lifetimeAmbrosia,r=1;return r+=Math.min(1.5,Math.floor(t/66)/100),t>=1e4&&(r+=Math.min(1.5,Math.floor(t/666)/100)),t>=1e5&&(r+=Math.floor(t/6666)/100),r},Co=()=>{let t=e.singularityChallenges.noAmbrosiaUpgrades.enabled?0:e.lifetimeAmbrosia,r=1;return r+=Math.min(.3,Math.floor(t/1666)/100),t>=5e4&&(r+=Math.min(.3,Math.floor(t/16666)/100)),t>=5e5&&(r+=Math.floor(t/166666)/100),r},xd=t=>1+e.shopUpgrades.shopCashGrabUltra*t*Math.min(1,Math.pow(e.lifetimeAmbrosia/1e7,1/3)),po=()=>xd(BC),Fi=()=>xd(UC),go=()=>xd(OC),Md=t=>1+t*Math.min(e.shopUpgrades.shopEXUltra,Math.floor(e.lifetimeAmbrosia/1e3)/125),FC=()=>Md(RC),vu=()=>Md(IC),R0=()=>Md(NC),wo=()=>e.singularityChallenges.limitedAscensions.rewards.exaltBonus&&o.currentSingChallenge!==void 0?Math.pow(1.04,e.singularityChallenges[o.currentSingChallenge].completions):1,Td=(t,r)=>{let n=Math.max(0,r-600+20*t);return n===0?1:Math.pow(10+t,-n/60)},Cd=()=>{let t=[100,150,200,225,250,255,260,265,269,272];for(let r=0;r{let t=[1,+e.singularityChallenges.noSingularityUpgrades.rewards.luckBonus,Cd(),e.shopUpgrades.shopAmbrosiaLuckMultiplier4/100,+e.singularityChallenges.noAmbrosiaUpgrades.rewards.luckBonus,.001*e.cubeUpgrades[77],o.isEvent?Ye(12):0];return{value:ae(t),array:t}},Ge=()=>{let t=[100,xe.AMBROSIA_LUCK_BUFF,pd(),md(),hd(),yd(),+e.blueberryUpgrades.ambrosiaLuck1.bonus.ambrosiaLuck,+e.blueberryUpgrades.ambrosiaLuck2.bonus.ambrosiaLuck,+e.blueberryUpgrades.ambrosiaCubeLuck1.bonus.ambrosiaLuck,+e.blueberryUpgrades.ambrosiaQuarkLuck1.bonus.ambrosiaLuck,e.highestSingularityCount>=131?131:0,e.highestSingularityCount>=269?269:0,e.shopUpgrades.shopOcteractAmbrosiaLuck*(1+Math.floor(Math.log10(e.totalWowOcteracts+1))),+e.singularityChallenges.noAmbrosiaUpgrades.rewards.additiveLuck,2*e.cubeUpgrades[77],Math.min(100,e.cubeUpgradeRedBarFilled/50),e.shopUpgrades.shopAmbrosiaUltra*au()],r=zr().value;return{value:ae(t)*r,array:t.concat(r)}},da=()=>{let t=[+(e.singularityChallenges.noSingularityUpgrades.completions>0),+e.singularityUpgrades.blueberries.getEffect().bonus,vd(),+e.singularityChallenges.noAmbrosiaUpgrades.rewards.blueberries];return{value:ae(t),array:t}},De=()=>{let t=[+e.visitedAmbrosiaSubtab,xe.AMBROSIA_GENERATION_BUFF,da().value,gd(),fd(),bd(),+e.blueberryUpgrades.ambrosiaPatreon.bonus.blueberryGeneration,+e.singularityChallenges.oneChallengeCap.rewards.blueberrySpeedMult,+e.singularityChallenges.noAmbrosiaUpgrades.rewards.blueberrySpeedMult,1+.01*e.cubeUpgrades[76]*To(),o.isEvent?1+Ye(11):1,po()];return{value:be(t),array:t}},Sd=()=>{if(!e.dayCheck)return;let t=new Date(tl()),r=new Date(t.getFullYear(),t.getMonth(),t.getDate()),n=t.getHours(),a=t.getMinutes(),s=t.getSeconds();e.dayTimer=60*60*24-60*60*n-60*a-s,r.getTime()-36e5>e.dayCheck.getTime()&&(e.dayCheck=r,ro(!0),e.dailyPowderResetUses=1+e.shopUpgrades.extraWarp,e.dailyCodeUsed=!1,i("cubeQuarksOpenRequirement").style.display="block",e.challengecompletions[11]>0&&(i("tesseractQuarksOpenRequirement").style.display="block"),e.challengecompletions[13]>0&&(i("hypercubeQuarksOpenRequirement").style.display="block"),e.challengecompletions[14]>0&&(i("platonicCubeQuarksOpenRequirement").style.display="block"))},ro=(t=!1)=>{e.cubeQuarkDaily=0,e.tesseractQuarkDaily=0,e.hypercubeQuarkDaily=0,e.platonicCubeQuarkDaily=0,e.cubeOpenedDaily=0,e.tesseractOpenedDaily=0,e.hypercubeOpenedDaily=0,e.platonicCubeOpenedDaily=0,t&&(e.overfluxPowder+=e.overfluxOrbs*Lr().mult,e.overfluxOrbs=o.challenge15Rewards.freeOrbs)},Ye=t=>o.isEvent?gu(t):0,QC=()=>{let t=0,r=[18,38,58,78,88,98,118,148,178,188,198,208,218,228,238,248];for(let n of r)e.highestSingularityCount>=n&&(t+=1);return 1+t*e.highestSingularityCount/100},ha=()=>e.shopUpgrades.infiniteAscent>0||xe.INSTANT_UNLOCK_2,_l=()=>e.shopUpgrades.shopTalisman>0||xe.INSTANT_UNLOCK_1;var au=()=>{let t=0;for(let r of Object.values(e.singularityChallenges))t+=r.completions;return t};var je=t=>{let r=0;return t<=5?e.singularityChallenges.oneChallengeCap.enabled?1:(r=25,e.researches[105]>0?9001:(r+=5*e.researches[65+t],r)):t<=10&&t>5?e.singularityChallenges.oneChallengeCap.enabled?1:(r=40,r+=4*e.cubeUpgrades[29],r+=2*e.shopUpgrades.challengeExtension,e.platonicUpgrades[5]>0&&(r+=10),e.platonicUpgrades[10]>0&&(r+=10),e.platonicUpgrades[15]>0&&(r+=30),r+=2*+e.singularityUpgrades.singChallengeExtension.getEffect().bonus,r+=2*+e.singularityUpgrades.singChallengeExtension2.getEffect().bonus,r+=2*+e.singularityUpgrades.singChallengeExtension3.getEffect().bonus,r+=+e.singularityChallenges.oneChallengeCap.rewards.capIncrease,r+=+e.singularityChallenges.oneChallengeCap.rewards.reinCapIncrease2,r):t<=15&&t>10?t===15?0:e.singularityChallenges.oneChallengeCap.enabled?1:(r=30,e.platonicUpgrades[5]>0&&(r+=5),e.platonicUpgrades[10]>0&&(r+=5),e.platonicUpgrades[15]>0&&(r+=20),r+=+e.singularityUpgrades.singChallengeExtension.getEffect().bonus,r+=+e.singularityUpgrades.singChallengeExtension2.getEffect().bonus,r+=+e.singularityUpgrades.singChallengeExtension3.getEffect().bonus,r+=+e.singularityChallenges.oneChallengeCap.rewards.ascCapIncrease2,r):r},ot=(t,r=!0)=>{let n=1;r&&(o.challengefocus=t,i("oneChallengeDetails").style.display="flex",i("startChallenge").style.display="block",i("retryChallenge").style.display="block",o.triggerChallenge=t);let a=je(t);t<=5&&r&&(e.challengecompletions[t]>=100?i("completionSoftcap").innerHTML=u.t("challenges.perCompletionBonus",{x:100,y:d(_("transcend",e.challengecompletions[t]),2,!0)}):i("completionSoftcap").textContent=u.t("challenges.perCompletionBonusEmpty")),t>5&&t<=10&&(n=10,e.challengecompletions[t]>=25&&r?i("completionSoftcap").innerHTML=u.t("challenges.perCompletionBonus",{x:25,y:d(_("reincarnation",e.challengecompletions[t]),2,!0)}):i("completionSoftcap").textContent=u.t("challenges.perCompletionBonusEmpty")),t>10&&(e.challengecompletions[t]>=10?i("completionSoftcap").innerHTML=u.t("challenges.perCompletionBonus",{x:10,y:d(_("ascension",e.challengecompletions[t]),2,!0)}):i("completionSoftcap").textContent=u.t("challenges.perCompletionBonusEmpty"));let s="",l=i("challengeName"),c=i("challengeFlavor"),p=i("challengeRestrictions"),g=i("challengeGoal"),m=i("challengePer1").childNodes[0],h=i("challengePer2").childNodes[0],b=i("challengePer3").childNodes[0],C=i("challengeFirst1"),v=i("challengeQuarkBonus"),x=i("startChallenge"),B=i("challengeCurrent1"),U=i("challengeCurrent2"),k=i("challengeCurrent3");if(t===o.challengefocus){let X=`${e.challengecompletions[t]}/${d(a)}`,re=t>=6&&t<=10||t===15,w=d(Lt(t,e.challengecompletions[t],re?t:0)),H="",J="",Te="";switch(t){case 1:{H=J=d(10*_("transcend",e.challengecompletions[1])),Te=d(.04*_("transcend",e.challengecompletions[1]),2,!0);break}case 2:{H=J=d(5*_("transcend",e.challengecompletions[2]));break}case 3:{H=d(.04*e.challengecompletions[3],2,!0),J=d(.5*_("transcend",e.challengecompletions[3]),2,!0),Te=d(.01*_("transcend",e.challengecompletions[3]),2,!0);break}case 4:{H=d(5*_("transcend",e.challengecompletions[4])),J=d(2*_("transcend",e.challengecompletions[4])),Te=d(.5*_("transcend",e.challengecompletions[4]),2,!0);break}case 5:{H=d(.5+_("transcend",e.challengecompletions[5])/100,2,!0),J=d(Math.pow(10,_("transcend",e.challengecompletions[5])));break}case 6:{H=d(Math.pow(.965,_("reincarnation",e.challengecompletions[6])),3,!0),J=d(10*_("reincarnation",e.challengecompletions[6])),Te=d(2*_("reincarnation",e.challengecompletions[6]));break}case 7:{H=d(1+.04*_("reincarnation",e.challengecompletions[7]),2,!0),J=Te=d(10*_("reincarnation",e.challengecompletions[7]));break}case 8:{H=d(.25*_("reincarnation",e.challengecompletions[8]),2,!0),J=d(20*_("reincarnation",e.challengecompletions[8]),2,!0),Te=d(4*_("reincarnation",e.challengecompletions[8]),2,!0);break}case 9:{H=d(_("reincarnation",e.challengecompletions[9])),J=d(Math.pow(1.1,_("reincarnation",e.challengecompletions[9])),2,!0),Te=d(20*_("reincarnation",e.challengecompletions[9]),2,!0);break}case 10:{H=d(100*_("reincarnation",e.challengecompletions[10])),J=d(2*_("reincarnation",e.challengecompletions[10])),Te=d(10*_("reincarnation",e.challengecompletions[10]),2,!0);break}case 11:{H=d(12*_("ascension",e.challengecompletions[11])),J=d(f.pow(1e5,_("ascension",e.challengecompletions[11]))),Te=d(80*_("ascension",e.challengecompletions[11]));break}case 12:{H=d(50*_("ascension",e.challengecompletions[12])),J=d(12*_("ascension",e.challengecompletions[12])),Te=d(_("ascension",e.challengecompletions[12]));break}case 13:{H=d(100-100*Math.pow(.966,_("ascension",e.challengecompletions[13])),3,!0),J=d(6*_("ascension",e.challengecompletions[13])),Te=d(3*_("ascension",e.challengecompletions[13]));break}case 14:{H=d(50*_("ascension",e.challengecompletions[14])),J=d(1*e.challengecompletions[14]),Te=d(200*_("ascension",e.challengecompletions[14]));break}}l.textContent=u.t(`challenges.${t}.name`,{value:X,completions:e.challengecompletions[t],max:a}),c.textContent=u.t(`challenges.${t}.flavor`),p.textContent=u.t(`challenges.${t}.restrictions`),g.textContent=u.t(`challenges.${t}.goal`,{value:w}),m.textContent=u.t(`challenges.${t}.per.1`),h.textContent=u.t(`challenges.${t}.per.2`),b.textContent=u.t(`challenges.${t}.per.3`),C.textContent=u.t(`challenges.${t}.first`),x.textContent=u.t(`challenges.${t}.start`),B.textContent=u.t(`challenges.${t}.current.1`,{value:H}),U.textContent=u.t(`challenges.${t}.current.2`,{value:J}),k.textContent=u.t(`challenges.${t}.current.3`,{value:Te})}t===15&&o.challengefocus===15&&a===0&&(g.textContent=u.t("challenges.15.noGoal"));let L=[0,8,10,12,15,20,60,80,120,180,300],E=[0,10,12,15,20,30,80,120,180,300,450],T=[0,20,30,50,100,200,250,300,400,500,750],S=[0,1e4,1e4,1e4,1e4,1e4,2e3,3e3,4e3,5e3,7500],I=0;if(t<=5&&(e.highestchallengecompletions[t]>=9e3?I=S[t]:e.highestchallengecompletions[t]>=750?I=T[t]:e.highestchallengecompletions[t]>=75?I=E[t]:I=L[t]),t>5&&t<=10&&(e.highestchallengecompletions[t]>=60?I=T[t]:e.highestchallengecompletions[t]>=25?I=E[t]:I=L[t]),r&&(v.textContent=""),e.ascensionCount===0&&(s="Quarks",v.style.color="cyan"),e.challengecompletions[t]>=e.highestchallengecompletions[t]&&e.highestchallengecompletions[t]=e.highestchallengecompletions[t]&&e.highestchallengecompletions[t]=1&&(v.textContent=u.t("challenges.ascensionBankAdd",{x:t>5?2:1,y:I})),e.challengecompletions[t]>=e.highestchallengecompletions[t]&&e.highestchallengecompletions[t]<10&&t>10&&(v.textContent=u.t("challenges.hypercubeOneTimeBonus")),r){let X=i("toggleAutoChallengeIgnore");X.style.display=t<=(zo()?15:10)&&e.researches[150]>0?"block":"none",X.style.border=e.autoChallengeToggles[t]?"2px solid green":"2px solid red",t>=11&&t<=15?e.autoChallengeToggles[t]?X.textContent=u.t("challenges.autoAscRunChalOn",{x:t}):X.textContent=u.t("challenges.autoAscRunChalOff",{x:t}):e.autoChallengeToggles[t]?X.textContent=u.t("challenges.autoRunChalOn",{x:t}):X.textContent=u.t("challenges.autoRunChalOff",{x:t})}let N=i("toggleAutoChallengeStart");e.autoChallengeRunning?(N.textContent=u.t("challenges.autoChallengeSweepOn"),N.style.border="2px solid gold"):(N.textContent=u.t("challenges.autoChallengeSweepOff"),N.style.border="2px solid red")},bl=t=>{e.currentChallenge.reincarnation===9&&(o.rune1level=1,o.rune2level=1,o.rune3level=1,o.rune4level=1,o.rune5level=1,e.crystalUpgrades=[0,0,0,0,0,0,0,0]),o.prestigePointGain=new f("0"),typeof t=="number"&&(t>=6&&(o.transcendPointGain=new f("0")),t>=11&&(o.reincarnationPointGain=new f("0"))),He()},I0=()=>{i("retryChallenge").textContent=e.retrychallenges?u.t("challenges.retryChallengesOff"):u.t("challenges.retryChallengesOn"),e.retrychallenges=!e.retrychallenges},Ld=(t,r)=>{let n=.1;t>=6&&(n=1),e.ascensionCount===0&&e.worlds.add(1+Math.floor(r*n)*100/100),Ht()&&e.ascensionCount===0&&t>=6&&t<=10&&(e.roombaResearchIndex=0,e.autoResearch=o.researchOrderByCost[e.roombaResearchIndex])},jl=(t,r,n=0)=>{let a=Math.max(1,o.hyperchallengedMultiplier[e.usedCorruptions[4]]/(1+e.platonicUpgrades[8]/2.5));switch(t==="ascension"&&(a=1),t){case"transcend":return a*=o.challenge15Rewards.transcendChallengeReduction,r>=75?a*=Math.pow(1+r,12)/Math.pow(75,8):a*=Math.pow(1+r,2),r>=1e3&&(a*=10*Math.pow(r/1e3,3)),r>=9e3&&(a*=1337),r>=9001&&(a*=r-8999),a;case"reincarnation":return r>=100&&(n===9||n===10)&&(a*=Math.pow(1.05,(r-100)*(1+(r-100)/20))),r>=90&&(n===6?a*=100:n===7?a*=50:n===8?a*=10:a*=4),r>=80&&(n===6?a*=50:n===7?a*=20:n===8?a*=4:a*=2),r>=70&&(n===6?a*=20:n===7?a*=10:n===8?a*=2:a*=1),r>=60&&(n===9||n===10)&&(a*=Math.pow(1e3,(r-60)*(1-.01*e.shopUpgrades.challengeTome-.01*e.shopUpgrades.challengeTome2)/10)),r>=25&&(a*=Math.pow(1+r,5)/625),r<25&&(a*=Math.min(Math.pow(1+r,2),Math.pow(1.3797,r))),a*=o.challenge15Rewards.reincarnationChallengeReduction,a;case"ascension":return n!==15?r>=10?a*=2*(1+r)-10:a*=1+r:a*=Math.pow(1e3,r),a}},_=(t,r)=>{let n=0;switch(t){case"transcend":return n+=Math.min(100,r),n+=1/20*(Math.min(1e3,Math.max(100,r))-100),n+=1/100*(Math.max(1e3,r)-1e3),n;case"reincarnation":return n+=Math.min(25,r),n+=1/2*(Math.min(75,Math.max(25,r))-25),n+=1/10*(Math.max(75,r)-75),n;case"ascension":return n+=Math.min(10,r),n+=1/2*(Math.max(10,r)-10),n}},Lt=(t,r,n=0)=>{let a=o.challengeBaseRequirements[t-1];if(t<=5)return f.pow(10,a*jl("transcend",r,n));if(t<=10){let s=0;return t===10&&(s=1e8*(e.researches[140]+e.researches[155]+e.researches[170]+e.researches[185])+2e7*(e.shopUpgrades.challengeTome+e.shopUpgrades.challengeTome2)),f.pow(10,(a-s)*jl("reincarnation",r,n))}else return t<=14?jl("ascension",r,n):t===15?f.pow(10,1*Math.pow(10,30)*jl("ascension",r,n)):0},N0=t=>{if(e.researches[150]===0||!e.autoChallengeRunning)return;o.autoChallengeTimerIncrement+=t;let r="none";if(e.currentChallenge.reincarnation!==0||e.currentChallenge.transcension!==0?r="exit":e.autoChallengeIndex===1?r="start":r="enter",zo()&&e.currentChallenge.ascension===15&&e.shopUpgrades.challenge15Auto===0&&(r==="start"||r==="enter")&&e.autoAscend&&e.challengecompletions[11]>0&&e.cubeUpgrades[10]>0&&e.autoAscendMode==="realAscensionTime"&&e.ascensionCounterRealReal>=Math.max(.1,e.autoAscendThreshold-5)){r="wait",pr("WAIT");return}if(o.autoChallengeTimerIncrement>=e.autoChallengeTimer.exit&&r==="exit"){let n=e.currentChallenge.reincarnation!==0?"reincarnation":"transcension";o.autoChallengeTimerIncrement=0;let a=e.autoChallengeIndex,s=Ko(a+1);n==="transcension"&&Ae("transcensionChallenge",void 0,!0),n==="reincarnation"&&Ae("reincarnationChallenge",void 0,!0),s<=10&&(s=e.autoChallengeTimer.start&&r==="start"||o.autoChallengeTimerIncrement>=e.autoChallengeTimer.enter&&r==="enter"){o.autoChallengeTimerIncrement=0;let n=e.autoChallengeIndex,a=Ko(n);if(a===11)return;e.autoChallengeIndex=a,gr(e.autoChallengeIndex,!0),pr("EXIT");return}},Ko=(t,r=!1,n=1,a=10)=>{let s=t;for(let l=s;l<=a&&(!e.autoChallengeToggles[l]||!r&&l!==15&&e.highestchallengecompletions[l]>=je(l));l++)s+=1;if(s>a){s=n;for(let l=s;l<=a&&(!e.autoChallengeToggles[l]||!r&&l!==15&&e.highestchallengecompletions[l]>=je(l));l++)s+=1}return s},zo=()=>e.highestSingularityCount>=101&&e.shopUpgrades.instantChallenge2>0,xo=()=>{let t=[1+5e-4*Ve("challenge"),1+.25*e.platonicUpgrades[15]];return be(t)};var it=t=>d(typeof t=="string"?new f(t):t),Xo=(t,r)=>typeof t=="string"?it(t):typeof t=="number"&&e.historyShowPerSecond&&r.seconds!==0?t===0?"0.000/s":`${d(t/r.seconds,3,t<1e3)}/s`:d(t),qC={offerings:{img:"Offering.png",formatter:it,imgTitle:"Offerings"},obtainium:{img:"Obtainium.png",formatter:it,imgTitle:"Obtainium"},particles:{img:"Particle.png",formatter:it,imgTitle:"Particles"},diamonds:{img:"Diamond.png",formatter:it,imgTitle:"Diamonds"},mythos:{img:"Mythos.png",formatter:it,imgTitle:"Mythos"},wowTesseracts:{img:"TinyWow4.png",formatter:Xo,imgTitle:"Wow! Tesseracts"},wowHypercubes:{img:"TinyWow5.png",formatter:Xo,imgTitle:"Wow! Hypercubes",onlyif:()=>e.challengecompletions[13]>0},wowCubes:{img:"TinyWow3.png",formatter:Xo,imgTitle:"Wow! Cubes"},wowPlatonicCubes:{img:"TinyWow6.png",formatter:Xo,imgTitle:"Platonic Cubes",onlyif:()=>e.challengecompletions[14]>0},wowHepteracts:{img:"TinyWow7.png",formatter:Xo,imgTitle:"Hepteracts",onlyif:()=>e.achievements[255]>0},singularityCount:{img:"TinyS.png",formatter:it,imgTitle:"Singularity Count",onlyif:()=>e.highestSingularityCount>0},quarks:{img:"Quark.png",formatter:it,imgTitle:"Quarks",onlyif:()=>e.highestSingularityCount>0},goldenQuarks:{img:"GoldenQuark.png",formatter:it,imgTitle:"Golden Quarks",onlyif:()=>e.highestSingularityCount>0},wowTribs:{img:"TinyWow3.png",formatter:it,imgTitle:"Cube Tributes",onlyif:()=>e.highestSingularityCount>0},tessTribs:{img:"TinyWow4.png",formatter:it,imgTitle:"Tesseract Gifts",onlyif:()=>e.highestSingularityCount>0},hyperTribs:{img:"TinyWow5.png",formatter:it,imgTitle:"Hypercube Bendictions",onlyif:()=>e.highestSingularityCount>0},platTribs:{img:"TinyWow6.png",formatter:it,imgTitle:"Platonics Opened",onlyif:()=>e.highestSingularityCount>0},octeracts:{img:"TinyWow8.png",formatter:it,imgTitle:"Octeracts",onlyif:()=>e.singularityUpgrades.octeractUnlock.getEffect().bonus>0},c15Score:{img:"TinyChallenge15.png",formatter:it,imgTitle:"C15 score",onlyif:()=>e.singularityCount>0},quarkHept:{img:"TinyQuarkHept.png",formatter:it,imgTitle:"Quark Hept",onlyif:()=>e.singularityCount>0}},jC=["offerings","obtainium","particles","diamonds","mythos","wowCubes","wowTesseracts","wowHypercubes","wowPlatonicCubes","wowHepteracts","singularityCount","quarks","goldenQuarks","wowTribs","tessTribs","hyperTribs","platTribs","octeracts","c15Score","quarkHept"],VC={antsacrifice:{img:"SacrificeNoBorder.png"},prestige:{img:"TinyP.png"},transcend:{img:"TinyT.png"},reincarnate:{img:"TinyR.png"},ascend:{img:"TinyA.png"},singularity:{img:"TinyS.png"}},Pd={ants:"historyAntsTable",reset:"historyResetTable",ascend:"historyAscendTable",singularity:"historySingularityTable"},$0=["CorruptViscocity.png","CorruptSpatialDilation.png","CorruptHyperchallenged.png","CorruptScientificIlliteracy.png","CorruptDeflation.png","CorruptExtinction.png","CorruptDrought.png","CorruptFinancialCollapse.png"],WC=["Viscosity [Accelerators and Multipliers]","Spacial Dilation [Time]","Hyperchallenged [Challenge Requirements]","Scientific Illiteracy [Obtainium]","Market Deflation [Diamonds]","Extinction [Ants]","Drought [Offering EXP]","Financial Recession [Coins]"],KC=t=>{let r;return(r=/e\+?(.+)/.exec(t))!==null?`e${r[1]}`:t},zC=(t,r)=>{for(;e.history[t].length>o.historyCountMax-1;)e.history[t].shift();e.history[t].push(r),XC(t,r)};yt.on("historyAdd",zC);var XC=(t,r)=>{let n=_0(t,r),s=i(Pd[t]).querySelector("tbody");for(s.insertBefore(n,s.childNodes[0]);s.childNodes.length>o.historyCountMax;)s.removeChild(s.lastChild);if(t==="ascend"){let l=Array.from(n.getElementsByClassName("ascendHistoryLoadCorruptions"));for(let c of l)c.addEventListener("click",p=>D0(p.target))}},_0=(t,r)=>{let n=1,a=document.createElement("tr"),s="",l=VC[r.kind],c=new Date(r.date).toLocaleString();s+=`${r.kind}${Vt(r.seconds,60)}`;let p=[],g=r;jC.forEach(h=>{var b;if(Object.prototype.hasOwnProperty.call(r,h)){let C=qC[h];if(C.onlyif&&!C.onlyif(r))return;let v=(b=C.formatter)!=null?b:()=>{},x=`${C.imgTitle}${v(g[h],r)}`;p.push(x)}});let m=[];if(r.kind==="antsacrifice"){let h=Xn(r.antSacrificePointsBefore),b=Xn(r.antSacrificePointsAfter),C=b-h;m.push(`Ant Multiplier+${d(C,3,!1)}`,`Crumbs${KC(it(r.crumbs))}`,`ELO${d(r.effectiveELO)}`)}else if(r.kind==="ascend"){m.push(`C10${r.c10Completions}`);let h=YC(r);m.push(h[0]),m.push(h[1]),m.push(h[2])}return n+=p.length,s+=p.reduce((h,b)=>`${h}${b}`,""),s+=``,s+=m.reduce((h,b)=>`${h}${b}`,""),s+=``,a.innerHTML=s,a},ZC=(t,r)=>{let n=r.querySelector("tbody");if(n.innerHTML="",e.history[t].length>0)for(let a=e.history[t].length-1;a>=0;--a){let s=_0(t,e.history[t][a]);n.appendChild(s)}if(t==="ascend"){let a=Array.from(document.getElementsByClassName("ascendHistoryLoadCorruptions"));for(let s of a)s.addEventListener("click",l=>D0(l.target))}};function D0(t){let r=t.getAttribute("data-corr");r&&(sd(r),br(u.t("corruptions.loadoutApplied"),5e3))}var Ad=()=>{Object.keys(Pd).forEach(t=>ZC(t,i(Pd[t])))},G0=()=>{e.historyShowPerSecond=!e.historyShowPerSecond,Ad();let t=i("historyTogglePerSecondButton");e.historyShowPerSecond?t.textContent=u.t("history.perSecondOn"):t.textContent=u.t("history.perSecondOff"),t.style.borderColor=e.historyShowPerSecond?"green":"red"},YC=t=>{let r=`Score: ${d(t.corruptionScore,0,!1)}`,n="",a="",s=0;for(let l=0;l<$0.length;++l){let c=l+2;c in t.usedCorruptions&&t.usedCorruptions[c]!==0?n+=`${s>0?${t.usedCorruptions[c]}`:n+=`${s>0?"/0":"0"}`,s++}return n&&(a+=``),t.currentChallenge!==void 0&&(r+=` / C${t.currentChallenge}`),[r,n,a]};var H0=Ln(pc());var F0=async()=>{let t="===== SUMMARY STATS =====",r=`Time Generated: ${new Date().toString()}`,n=`Version: ${Jt}`,a=`-----+----- + ${u.t("general.spent")} ${u.t("ambrosia.ambrosia")}: ${d(this.ambrosiaInvested,2,!0,!0,!0)}`}updateUpgradeHTML(){i("singularityAmbrosiaMultiline").innerHTML=this.toString(),Ts()}checkPrerequisites(){if(this.preRequisites!==void 0)for(let[n,a]of Object.entries(this.preRequisites)){let s=n;if(e.blueberryUpgrades[s].levelr*(Math.pow(t+1,2)-Math.pow(t,2)),rewards:t=>{let r=1+.05*t,n=1+.01*t;return{quarks:n,cubes:r,desc:String(u.t("ambrosia.data.ambrosiaTutorial.effect",{cubeAmount:d(100*(r-1),0,!0),quarkAmount:d(100*(n-1),0,!0)}))}}},ambrosiaQuarks1:{maxLevel:100,costPerLevel:1,blueberryCost:0,costFormula:(t,r)=>r*(Math.pow(t+1,3)-Math.pow(t,3)),rewards:t=>{let r=1+.01*t;return{quarks:r,desc:String(u.t("ambrosia.data.ambrosiaQuarks1.effect",{amount:d(100*(r-1),0,!0)}))}},prerequisites:{ambrosiaTutorial:10}},ambrosiaCubes1:{maxLevel:100,costPerLevel:1,blueberryCost:0,costFormula:(t,r)=>r*(Math.pow(t+1,3)-Math.pow(t,3)),rewards:t=>{let r=(1+.05*t)*Math.pow(1.1,Math.floor(t/10));return{cubes:r,desc:String(u.t("ambrosia.data.ambrosiaCubes1.effect",{amount:d(100*(r-1),2,!0)}))}},prerequisites:{ambrosiaTutorial:10}},ambrosiaLuck1:{maxLevel:100,costPerLevel:1,blueberryCost:0,costFormula:(t,r)=>r*(Math.pow(t+1,3)-Math.pow(t,3)),rewards:t=>{let r=2*t+12*Math.floor(t/10);return{ambrosiaLuck:r,desc:String(u.t("ambrosia.data.ambrosiaLuck1.effect",{amount:d(r)}))}},prerequisites:{ambrosiaTutorial:10},cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaLuck=Ge().value}]},ambrosiaQuarkCube1:{maxLevel:25,costPerLevel:250,blueberryCost:1,costFormula:(t,r)=>r*(Math.pow(t+1,3)-Math.pow(t,3)),rewards:t=>{let n=1+5e-4*t*Math.floor(Math.pow(Math.log10(Number(e.worlds)+1)+1,2));return{cubes:n,desc:String(u.t("ambrosia.data.ambrosiaQuarkCube1.effect",{amount:d(100*(n-1),2,!0)}))}},prerequisites:{ambrosiaCubes1:30,ambrosiaQuarks1:20}},ambrosiaLuckCube1:{maxLevel:25,costPerLevel:250,blueberryCost:1,costFormula:(t,r)=>r*(Math.pow(t+1,3)-Math.pow(t,3)),rewards:t=>{let n=1+2e-4*t*o.ambrosiaCurrStats.ambrosiaLuck;return{cubes:n,desc:String(u.t("ambrosia.data.ambrosiaLuckCube1.effect",{amount:d(100*(n-1),2,!0)}))}},prerequisites:{ambrosiaCubes1:30,ambrosiaLuck1:20}},ambrosiaCubeQuark1:{maxLevel:25,costPerLevel:500,blueberryCost:1,costFormula:(t,r)=>r*(Math.pow(t+1,3)-Math.pow(t,3)),rewards:t=>{let n=1+1e-4*t*(Math.floor(Math.log10(Number(e.wowCubes)+1))+Math.floor(Math.log10(Number(e.wowTesseracts)+1))+Math.floor(Math.log10(Number(e.wowHypercubes)+1))+Math.floor(Math.log10(Number(e.wowPlatonicCubes)+1))+Math.floor(Math.log10(e.wowAbyssals+1))+Math.floor(Math.log10(e.wowOcteracts+1))+6);return{quarks:n,desc:String(u.t("ambrosia.data.ambrosiaCubeQuark1.effect",{amount:d(100*(n-1),2,!0)}))}},prerequisites:{ambrosiaQuarks1:30,ambrosiaCubes1:20}},ambrosiaLuckQuark1:{maxLevel:25,costPerLevel:500,blueberryCost:1,costFormula:(t,r)=>r*(Math.pow(t+1,3)-Math.pow(t,3)),rewards:t=>{let r=1e-4*t,n=Math.min(o.ambrosiaCurrStats.ambrosiaLuck,Math.pow(1e3,.5)*Math.pow(o.ambrosiaCurrStats.ambrosiaLuck,.5)),a=1+r*n;return{quarks:a,desc:String(u.t("ambrosia.data.ambrosiaLuckQuark1.effect",{amount:d(100*(a-1),2,!0)}))}},prerequisites:{ambrosiaQuarks1:30,ambrosiaLuck1:20}},ambrosiaCubeLuck1:{maxLevel:25,costPerLevel:100,blueberryCost:1,costFormula:(t,r)=>r*(Math.pow(t+1,3)-Math.pow(t,3)),rewards:t=>{let n=.02*t*(Math.floor(Math.log10(Number(e.wowCubes)+1))+Math.floor(Math.log10(Number(e.wowTesseracts)+1))+Math.floor(Math.log10(Number(e.wowHypercubes)+1))+Math.floor(Math.log10(Number(e.wowPlatonicCubes)+1))+Math.floor(Math.log10(e.wowAbyssals+1))+Math.floor(Math.log10(e.wowOcteracts+1))+6);return{ambrosiaLuck:n,desc:String(u.t("ambrosia.data.ambrosiaCubeLuck1.effect",{amount:d(n,2,!0)}))}},prerequisites:{ambrosiaLuck1:30,ambrosiaCubes1:20},cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaLuck=Ge().value}]},ambrosiaQuarkLuck1:{maxLevel:25,costPerLevel:100,blueberryCost:1,costFormula:(t,r)=>r*(Math.pow(t+1,3)-Math.pow(t,3)),rewards:t=>{let n=.02*t*Math.floor(Math.pow(Math.log10(Number(e.worlds)+1)+1,2));return{ambrosiaLuck:n,desc:String(u.t("ambrosia.data.ambrosiaQuarkLuck1.effect",{amount:d(n,2,!0)}))}},prerequisites:{ambrosiaLuck1:30,ambrosiaQuarks1:20},cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaLuck=Ge().value}]},ambrosiaQuarks2:{maxLevel:100,costPerLevel:500,blueberryCost:1,costFormula:(t,r)=>r*(Math.pow(t+1,2)-Math.pow(t,2)),rewards:t=>{let r=1+(.01+Math.floor(e.blueberryUpgrades.ambrosiaQuarks1.level/10)/1e3)*t;return{quarks:r,desc:String(u.t("ambrosia.data.ambrosiaQuarks2.effect",{amount:d(100*(r-1),0,!0)}))}},prerequisites:{ambrosiaQuarks1:40}},ambrosiaCubes2:{maxLevel:100,costPerLevel:500,blueberryCost:1,costFormula:(t,r)=>r*(Math.pow(t+1,2)-Math.pow(t,2)),rewards:t=>{let r=(1+(.06+6*(Math.floor(e.blueberryUpgrades.ambrosiaCubes1.level/10)/1e3))*t)*Math.pow(1.13,Math.floor(t/10));return{cubes:r,desc:String(u.t("ambrosia.data.ambrosiaCubes2.effect",{amount:d(100*(r-1),2,!0)}))}},prerequisites:{ambrosiaCubes1:40}},ambrosiaLuck2:{maxLevel:100,costPerLevel:250,blueberryCost:1,costFormula:(t,r)=>r*(Math.pow(t+1,2)-Math.pow(t,2)),rewards:t=>{let r=(3+.3*Math.floor(e.blueberryUpgrades.ambrosiaLuck1.level/10))*t+40*Math.floor(t/10);return{ambrosiaLuck:r,desc:String(u.t("ambrosia.data.ambrosiaLuck2.effect",{amount:d(r,1,!0)}))}},prerequisites:{ambrosiaLuck1:40},cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaLuck=Ge().value}]},ambrosiaPatreon:{maxLevel:1,costPerLevel:1,blueberryCost:0,costFormula:(t,r)=>r*(Math.pow(t+1,2)-Math.pow(t,2)),rewards:t=>{let r=1+t*rr()/100;return{blueberryGeneration:r,desc:String(u.t("ambrosia.data.ambrosiaPatreon.effect",{amount:d(100*(r-1),0,!0)}))}},cacheUpdates:[()=>{o.ambrosiaCurrStats.ambrosiaGenerationSpeed=De().value}]},ambrosiaObtainium1:{maxLevel:2,costPerLevel:5e4,blueberryCost:1,costFormula:(t,r)=>r*Math.pow(25,t),rewards:t=>{let r=o.ambrosiaCurrStats.ambrosiaLuck;return{luckMult:t,obtainiumMult:t*r,desc:String(u.t("ambrosia.data.ambrosiaObtainium1.effect",{amount:d(t*r/10,1,!0)}))}}},ambrosiaOffering1:{maxLevel:2,costPerLevel:5e4,blueberryCost:1,costFormula:(t,r)=>r*Math.pow(25,t),rewards:t=>{let r=o.ambrosiaCurrStats.ambrosiaLuck;return{luckMult:t,offeringMult:t*r,desc:String(u.t("ambrosia.data.ambrosiaOffering1.effect",{amount:d(t*r/10,1,!0)}))}}},ambrosiaHyperflux:{maxLevel:7,costPerLevel:33333,blueberryCost:3,costFormula:(t,r)=>(r+33333*Math.min(4,t))*Math.max(1,Math.pow(3,t-4)),rewards:t=>{let r=t;return{hyperFlux:Math.pow(1+1/100*r,e.platonicUpgrades[19]),desc:String(u.t("ambrosia.data.ambrosiaHyperflux.effect",{amount:d(100*(Math.pow(1+r/100,e.platonicUpgrades[19])-1))}))}}}},Hl=()=>{let t=8+xe.AMBROSIA_LOADOUT_SLOT_QOL;Hn(t<=16,"Yeah. Nice try.");for(let r=1;r<=16;r++){let n=i(`blueberryLoadout${r}`);r<=t?n.style.display="flex":n.style.display="none"}},ud=async(t=!0)=>{for(let r of Object.keys(e.blueberryUpgrades)){let n=r;e.blueberryUpgrades[n].refund(),e.blueberryUpgrades[n].updateCaches()}if(t)return P(u.t("ambrosia.refund"))},BC=t=>{var g;if(Object.keys(t).length===0)return!1;let r=e.lifetimeAmbrosia,n=o.ambrosiaCurrStats.ambrosiaBlueberries,a=0,s=0,l=!0,c=!0,p=!0;for(let[m,h]of Object.entries(t)){let b=m;if(h<0||!Number.isFinite(h)||!Number.isInteger(h)||Number.isNaN(h)||e.blueberryUpgrades[b]===void 0)return!1;let C=Math.min(e.blueberryUpgrades[b].maxLevel,h),v=e.blueberryUpgrades[b].preRequisites;if(v!==void 0&&h>0)for(let[x,B]of Object.entries(v))((g=t[x])!=null?g:-1)0&&(s+=e.blueberryUpgrades[b].blueberryCost),C>0){let x=e.blueberryUpgrades[b].costFormula,B=e.blueberryUpgrades[b].costPerLevel,U=0;for(let k=0;k=a,p=n>=s,l&&c&&p},M0=()=>Object.fromEntries(Object.entries(e.blueberryUpgrades).map(([t,r])=>[t,r.level])),RC=t=>Object.fromEntries(Object.entries(t).map(([r,n])=>[r,Math.min(n,e.blueberryUpgrades[r].maxLevel)])),T0=()=>{let t=M0(),r=JSON.stringify(t),n=`BBTree-${Xo()}`;od(r,n)},S0=async t=>{if(!BC(t)){P(u.t("ambrosia.importTree.failure"));return}await ud(!1);let n=RC(t);for(let[a,s]of Object.entries(n)){let l=a,{costFormula:c,costPerLevel:p,blueberryCost:g}=e.blueberryUpgrades[l];if(s>0){e.blueberryUpgrades[l].blueberriesInvested=g,e.spentBlueberries+=g;let m=0;for(let h=0;h{if(typeof t!="string")return P(u.t("importexport.unableImport"));try{let r=JSON.parse(t);await S0(r),Fl(0,r)}catch(r){return P(u.t("ambrosia.importTree.error"))}},L0=async(t,r)=>{e.blueberryLoadoutMode==="saveTree"&&await IC(t,r),e.blueberryLoadoutMode==="loadTree"&&await S0(r)},dd=()=>{var r,n;let t=Object.keys($e);for(let a of Object.keys(e.blueberryLoadouts)){let s=Number.parseInt(a,10),l=e.blueberryLoadouts[s],c=`bbPurchasedLoadout${s}`;for(let p of t)l[p]?(r=i(p).parentElement)==null||r.classList.add(c):(n=i(p).parentElement)==null||n.classList.remove(c)}},IC=async(t,r)=>{Object.keys(r).length>0&&!await ye(u.t("ambrosia.loadouts.confirmation"))||(e.blueberryLoadouts[t]=M0(),Fl(t,e.blueberryLoadouts[t]),dd())},Fl=(t,r)=>{let n="";for(let[s,l]of Object.entries(r)){if(!l)continue;let c=s,p=e.blueberryUpgrades[c].name;n=`${n}${p} lv${l} | `}Object.keys(r).length===0&&(n=u.t("ambrosia.loadouts.none"));let a=`${u.t("ambrosia.loadouts.loadout")} ${t}`;t===0&&(a=u.t("ambrosia.loadouts.imported")),i("singularityAmbrosiaMultiline").innerHTML=` ${a} + ${n}`},P0=()=>{let r=Object.keys(e.blueberryLoadouts).length;if(r<16)for(let n=r+1;n<=16;n++)e.blueberryLoadouts[n]={}};var Ql={INSTANT_UNLOCK_1:0,INSTANT_UNLOCK_2:0,CUBE_BUFF:0,AMBROSIA_LUCK_BUFF:0,AMBROSIA_GENERATION_BUFF:0,GOLDEN_QUARK_BUFF:0,FREE_UPGRADE_PROMOCODE_BUFF:0,CORRUPTION_LOADOUT_SLOT_QOL:0,AMBROSIA_LOADOUT_SLOT_QOL:0,AUTO_POTION_FREE_POTIONS_QOL:0,OFFLINE_TIMER_CAP_BUFF:0,ADD_CODE_CAP_BUFF:0},xe={INSTANT_UNLOCK_1:0,INSTANT_UNLOCK_2:0,CUBE_BUFF:1,AMBROSIA_LUCK_BUFF:0,AMBROSIA_GENERATION_BUFF:1,GOLDEN_QUARK_BUFF:1,FREE_UPGRADE_PROMOCODE_BUFF:1,CORRUPTION_LOADOUT_SLOT_QOL:0,AMBROSIA_LOADOUT_SLOT_QOL:0,AUTO_POTION_FREE_POTIONS_QOL:0,OFFLINE_TIMER_CAP_BUFF:1,ADD_CODE_CAP_BUFF:1},A0=async()=>{let t=await Pn.fetchUpgrades();for(let r of Object.keys(Ql))Ql[r]=0,pd(r,0);for(let r of t.playerUpgrades)Ql[r.internalName]=r.level,pd(r.internalName,r.level)},e0=async(t,r)=>{Ql[t]=r,pd(t,r)},pd=(t,r)=>{switch(t){case"INSTANT_UNLOCK_1":xe.INSTANT_UNLOCK_1=r>0?1:0;break;case"INSTANT_UNLOCK_2":xe.INSTANT_UNLOCK_2=r>0?1:0;break;case"CUBE_BUFF":xe.CUBE_BUFF=1+r*.06;break;case"AMBROSIA_LUCK_BUFF":xe.AMBROSIA_LUCK_BUFF=r*20;break;case"AMBROSIA_GENERATION_BUFF":xe.AMBROSIA_GENERATION_BUFF=1+r*.05;break;case"GOLDEN_QUARK_BUFF":xe.GOLDEN_QUARK_BUFF=1+r*.04;break;case"FREE_UPGRADE_PROMOCODE_BUFF":xe.FREE_UPGRADE_PROMOCODE_BUFF=1+r*.02;break;case"CORRUPTION_LOADOUT_SLOT_QOL":xe.CORRUPTION_LOADOUT_SLOT_QOL=r,ql(),Ds();break;case"AMBROSIA_LOADOUT_SLOT_QOL":xe.AMBROSIA_LOADOUT_SLOT_QOL=r,Hl();break;case"AUTO_POTION_FREE_POTIONS_QOL":xe.AUTO_POTION_FREE_POTIONS_QOL=r>0?1:0;break;case"OFFLINE_TIMER_CAP_BUFF":xe.OFFLINE_TIMER_CAP_BUFF=1+r;break;case"ADD_CODE_CAP_BUFF":xe.ADD_CODE_CAP_BUFF=1+r;break}},Yu=(t,r)=>{switch(t){case"INSTANT_UNLOCK_1":return String(u.t("pseudoCoins.upgradeEffects.INSTANT_UNLOCK_1",{descriptor:r>0?"":"NOT",amount:10*r}));case"INSTANT_UNLOCK_2":return String(u.t("pseudoCoins.upgradeEffects.INSTANT_UNLOCK_2",{descriptor:r>0?"":"NOT",amount:6*r}));case"CUBE_BUFF":return String(u.t("pseudoCoins.upgradeEffects.CUBE_BUFF",{amount:d(1+.06*r,2,!0)}));case"AMBROSIA_LUCK_BUFF":return String(u.t("pseudoCoins.upgradeEffects.AMBROSIA_LUCK_BUFF",{amount:20*r}));case"AMBROSIA_GENERATION_BUFF":return String(u.t("pseudoCoins.upgradeEffects.AMBROSIA_GENERATION_BUFF",{amount:d(1+.05*r,2,!0)}));case"GOLDEN_QUARK_BUFF":return String(u.t("pseudoCoins.upgradeEffects.GOLDEN_QUARK_BUFF",{amount:d(1+.04*r,2,!0)}));case"FREE_UPGRADE_PROMOCODE_BUFF":return String(u.t("pseudoCoins.upgradeEffects.FREE_UPGRADE_PROMOCODE_BUFF",{amount:d(1+.02*r,2,!0)}));case"CORRUPTION_LOADOUT_SLOT_QOL":return String(u.t("pseudoCoins.upgradeEffects.CORRUPTION_LOADOUT_SLOT_QOL",{amount:r}));case"AMBROSIA_LOADOUT_SLOT_QOL":return String(u.t("pseudoCoins.upgradeEffects.AMBROSIA_LOADOUT_SLOT_QOL",{amount:r}));case"AUTO_POTION_FREE_POTIONS_QOL":return String(u.t("pseudoCoins.upgradeEffects.AUTO_POTION_FREE_POTIONS_QOL",{descriptor:r>0?"":"NOT"}));case"OFFLINE_TIMER_CAP_BUFF":return String(u.t("pseudoCoins.upgradeEffects.OFFLINE_TIMER_CAP_BUFF",{amount:r+1}));case"ADD_CODE_CAP_BUFF":return String(u.t("pseudoCoins.upgradeEffects.ADD_CODE_CAP_BUFF",{amount:r+1}))}},t0=t=>{switch(t){case"INSTANT_UNLOCK_1":return{cost:"Cost: 400 PseudoCoins",effect:"Effect: +10 Levels"};case"INSTANT_UNLOCK_2":return{cost:"Cost: 600 PseudoCoins",effect:"Effect: +6 Levels"};case"CUBE_BUFF":return{cost:"Cost: 100/150/200/250/300 PseudoCoins",effect:"Effect: 1.06/1.12/1.18/1.24/1.30x Cubes"};case"AMBROSIA_LUCK_BUFF":return{cost:"Cost: 100/150/200/250/300 PseudoCoins",effect:"Effect: 20/40/60/80/100 Ambrosia Luck"};case"AMBROSIA_GENERATION_BUFF":return{cost:"Cost: 100/150/200/250/300 PseudoCoins",effect:"Effect: 1.05/1.10/1.15/1.20/1.25x Ambrosia Generation"};case"GOLDEN_QUARK_BUFF":return{cost:"Cost: 100/150/200/250/300 PseudoCoins",effect:"Effect: 1.04/1.08/1.12/1.16/1.20x Golden Quarks"};case"FREE_UPGRADE_PROMOCODE_BUFF":return{cost:"Cost: 100/150/200/250/300 PseudoCoins",effect:"Effect: 1.02/1.04/1.06/1.08/1.10x Free Upgrade Promocodes"};case"CORRUPTION_LOADOUT_SLOT_QOL":return{cost:"Cost: 125/per PseudoCoins",effect:"Effect: +1 Loadout Slot per level"};case"AMBROSIA_LOADOUT_SLOT_QOL":return{cost:"Cost: 125/per PseudoCoins",effect:"Effect: +1 Loadout Slot per level"};case"AUTO_POTION_FREE_POTIONS_QOL":return{cost:"Cost: 500 PseudoCoins",effect:"Effect: Auto Potion gives free potions"};case"OFFLINE_TIMER_CAP_BUFF":return{cost:"Cost: 400/600 PseudoCoins",effect:"Effect: 2x/3x Offline Time Cap"};case"ADD_CODE_CAP_BUFF":return{cost:"Cost: 400/600 PseudoCoins",effect:"Effect: 2x/3x Add Code Cap"}}};var Qa=()=>{let t=0;return e.challengecompletions[11]>0&&(t+=5),e.challengecompletions[12]>0&&(t+=2),e.challengecompletions[13]>0&&(t+=2),e.challengecompletions[14]>0&&(t+=2),e.platonicUpgrades[5]>0&&(t+=1),e.platonicUpgrades[10]>0&&(t+=1),e.singularityUpgrades.platonicTau.getEffect().bonus&&(t=Math.max(13,t)),e.singularityUpgrades.corruptionFourteen.getEffect().bonus&&(t+=1),t+=+e.octeractUpgrades.octeractCorruption.getEffect().bonus,t},Fa=t=>{i("corruptionDetails").style.visibility!=="visible"&&(i("corruptionDetails").style.visibility="visible"),i("corruptionSelectedPic").style.visibility!=="visible"&&(i("corruptionSelectedPic").style.visibility="visible"),o.corruptionTrigger=t;let r=t===2&&e.usedCorruptions[t]>=10?1+.04*e.platonicUpgrades[17]+2*Math.min(1,e.platonicUpgrades[17]):1,n=t===2&&e.prototypeCorruptions[t]>=10?1+.04*e.platonicUpgrades[17]+2*Math.min(1,e.platonicUpgrades[17]):1,a=e.singularityUpgrades.corruptionFifteen.level>0?1:0;a+=+e.singularityChallenges.oneChallengeCap.rewards.freeCorruptionLevel;let s=a>0?`[+${a}]`:"",l=[o.viscosityPower,o.lazinessMultiplier,o.hyperchallengedMultiplier,o.illiteracyPower,o.deflationMultiplier,o.extinctionMultiplier,o.droughtMultiplier,o.financialcollapsePower,[0]],c=["/CorruptViscocity.png","/CorruptSpatialDilation.png","/CorruptHyperchallenged.png","/CorruptScientificIlliteracy.png","/CorruptDeflation.png","/CorruptExtinction.png","/CorruptDrought.png","/CorruptFinancialCollapse.png"],p={name:u.t("corruptions.exitCorruption.name"),description:u.t("corruptions.exitCorruption.description"),current:u.t("corruptions.exitCorruption.current"),planned:u.t("corruptions.exitCorruption.planned"),multiplier:u.t("corruptions.exitCorruption.multiplier"),spiritContribution:"",image:`Pictures/${Be[e.iconSet][0]}/CorruptExit.png`};t<10&&(p={name:u.t(`corruptions.names.${t-1}`),description:u.t(`corruptions.descriptions.${t-1}`),current:u.t(`corruptions.currentLevel.${t-1}`,{level:d(e.usedCorruptions[t])+s,effect:d(l[t-2][e.usedCorruptions[t]],3)}),planned:u.t(`corruptions.prototypeLevel.${t-1}`,{level:d(e.prototypeCorruptions[t])+s,effect:d(l[t-2][e.prototypeCorruptions[t]],3)}),multiplier:u.t("corruptions.scoreMultiplier",{curr:d(Math.pow(o.corruptionPointMultipliers[e.usedCorruptions[t]+a],r),1),next:d(Math.pow(o.corruptionPointMultipliers[e.prototypeCorruptions[t]+a],n),1)}),spiritContribution:u.t("corruptions.spiritEffect",{curr:d(4*Math.pow(e.usedCorruptions[t]+a,2),1),next:d(4*Math.pow(e.prototypeCorruptions[t]+a,2),1)}),image:`Pictures/${Be[e.iconSet][0]}${c[t-2]}`}),i("corruptionName").textContent=p.name,i("corruptionDescription").textContent=p.description,i("corruptionLevelCurrent").textContent=p.current,i("corruptionLevelPlanned").textContent=p.planned,i("corruptionMultiplierContribution").textContent=p.multiplier,i("corruptionSpiritContribution").textContent=p.spiritContribution,i("corruptionSelectedPic").setAttribute("src",p.image),t<10&&(i(`corrCurrent${t}`).textContent=d(e.usedCorruptions[t]),i(`corrNext${t}`).textContent=d(e.prototypeCorruptions[t]))},Va=()=>{for(let t=2;t<=9;t++){if(!wi(`corrCurrent${t}`))continue;let r=i(`corrCurrent${t}`),n=i(`corrNext${t}`);r.textContent=d(e.usedCorruptions[t]),n.textContent=d(e.prototypeCorruptions[t])}},E0=()=>{let t=document.getElementsByClassName("corruptionStatRow");for(let r=0;r=1;p--)n.children[p].remove();let a=document.createElement("p");a.className="corrDesc";let s=document.createTextNode(u.t("corruptions.current"));a.appendChild(s);let l=document.createElement("span");l.id=`corrCurrent${r+2}`,l.textContent=`${e.usedCorruptions[r+2]}`,a.appendChild(l),s=document.createTextNode(u.t("corruptions.next")),a.appendChild(s),l=document.createElement("span"),l.id=`corrNext${r+2}`,l.textContent=`${e.prototypeCorruptions[r+2]}`,a.appendChild(l),n.appendChild(a);let c;c=document.createElement("button"),c.className="corrBtn corruptionMax",c.textContent=`+${u.t("corruptions.max")}`,c.addEventListener("click",()=>hn(r+2,99)),n.appendChild(c),c=document.createElement("button"),c.className="corrBtn corruptionUp",c.textContent="+1",c.addEventListener("click",()=>hn(r+2,1)),n.appendChild(c),c=document.createElement("button"),c.className="corrBtn corruptionDown",c.textContent="-1",c.addEventListener("click",()=>hn(r+2,-1)),n.appendChild(c),c=document.createElement("button"),c.className="corrBtn corruptionReset",c.textContent=`-${u.t("corruptions.max")}`,c.addEventListener("click",()=>hn(r+2,-99)),n.appendChild(c),n.addEventListener("click",()=>Fa(r+2))}},ql=()=>{let r=an("corruptionLoadoutTable");for(let a=r.rows.length-1;a>=1;a--)r.deleteRow(a);let n=8+xe.CORRUPTION_LOADOUT_SLOT_QOL;for(let a=0;avoid _C()),c.classList.add("corrLoadoutName"),c.title=u.t("corruptions.loadoutTable.firstRowTitle")):c.title=u.t("corruptions.loadoutTable.otherRowTitle",{value:a}):l<=8&&(a===0?c.textContent=e.prototypeCorruptions[l+1].toString():c.textContent=e.corruptionLoadouts[a][l+1].toString())}if(a===0){let l=s.insertCell(),c=document.createElement("button");c.className="corrImport",c.textContent=u.t("corruptions.loadoutTable.import"),c.addEventListener("click",()=>void NC()),l.appendChild(c),l.title=u.t("corruptions.importLoadoutInTextFormat"),l=s.insertCell(),c=document.createElement("button"),c.className="corrLoad",c.textContent=u.t("corruptions.loadoutTable.zero"),c.addEventListener("click",()=>Gs(!1,a)),l.appendChild(c),l.title=u.t("corruptions.loadoutTable.zeroTitle")}else{let l=s.insertCell(),c=document.createElement("button");c.className="corrSave",c.textContent=u.t("corruptions.loadoutTable.save"),c.addEventListener("click",()=>Gs(!0,a)),l.appendChild(c),l.title=u.t("corruptions.loadoutTable.saveTitle"),l=s.insertCell(),c=document.createElement("button"),c.className="corrLoad",c.textContent=u.t("corruptions.loadoutTable.load"),c.addEventListener("click",()=>Gs(!1,a)),l.appendChild(c)}}Ds(),Va()},qa=(t=0)=>{let r=an("corruptionLoadoutTable").rows[t+1].cells;for(let n=1;n8);n++)r[n].textContent=(t===0?e.prototypeCorruptions[n+1]:e.corruptionLoadouts[t][n+1]).toString()},Gs=(t=!0,r=1)=>{t?(e.corruptionLoadouts[r]=Array.from(e.prototypeCorruptions),qa(r)):(r===0?e.prototypeCorruptions=[0,0,0,0,0,0,0,0,0,0,0,0,0]:e.prototypeCorruptions=Array.from(e.corruptionLoadouts[r]),qa(),Va())},gd=t=>{if(t.includes("/")&&t.split("/").length===13){let r=t.split("/").map(n=>Number(n));for(let n of r)if(!Number.isInteger(n)||Number.isNaN(n)||n<0||n>Qa())return!1;return e.prototypeCorruptions=r,qa(),Va(),!0}return!1};async function NC(){let t=await Ee(u.t("corruptions.importCorruptionsPrompt.import"));gd(`0/0/${t}/0/0/0`)||P(u.t("corruptions.importCorruptionsPrompt.importError"))}async function $C(t=0){let n=/^[\x00-\xFF]*$/,a=await Ee(u.t("corruptions.corruptionLoadoutName.loadoutPrompt",{loadNum:t+1,maxChars:9}));if(a){if(a.length>9)return P(u.t("corruptions.corruptionLoadoutName.errors.exceedsCharacterLimit"));if(n.test(a)){if(e.corruptionLoadoutNames[t]=a,Ds(),a==="crazy")return P(u.t("corruptions.corruptionLoadoutName.errors.crazyJoke"))}else return P(u.t("corruptions.corruptionLoadoutName.errors.regexError"))}else return P(u.t("corruptions.corruptionLoadoutName.errors.noName"))}var Ds=()=>{let t=an("corruptionLoadoutTable").rows,r=8+xe.CORRUPTION_LOADOUT_SLOT_QOL;for(let n=0;nvoid $C(n)),a[0].classList.add("corrLoadoutName")),a[0].textContent=`${e.corruptionLoadoutNames[n]}:`}},_C=async()=>{let t=e.prototypeCorruptions.slice(2,10).join("/");"clipboard"in navigator?await navigator.clipboard.writeText(t).catch(r=>P(u.t("corruptions.loadoutExport.saveErrorNavigator",{message:r.message}))):P(u.t("corruptions.loadoutExport.saveErrorNavigator",{message:t}))},O0=()=>{let r=Object.keys(e.corruptionLoadouts).length;if(r<16)for(let n=r+1;n<=16;n++)e.corruptionLoadouts[n]=Array(13).fill(0),e.corruptionLoadoutNames.push(`Loadout ${n}`)},U0=()=>{let t=i("corruptionCleanseConfirm");t.style.visibility="visible",setTimeout(()=>t.style.visibility="hidden",1e4)},B0=()=>{let t=document.getElementsByClassName("corruptionStatRow");for(let l=0;l0||e.singularityUpgrades.platonicTau.getEffect().bonus)for(let l=0;l0||e.singularityUpgrades.platonicTau.getEffect().bonus)for(let l=0;l0||e.singularityUpgrades.platonicTau.getEffect().bonus)for(let l=0;l0||e.singularityUpgrades.platonicTau.getEffect().bonus)for(let l=0;l{let t=document.getElementsByClassName("coinunlock1");for(let A=0;A0?L[A].style.display="block":L[A].style.display="none";let E=document.getElementsByClassName("chal10");for(let A=0;A0?"flex":"none":T[A].style.display=e.ascensionCount>0?"block":"none";let S=document.getElementsByClassName("chal11");for(let A=0;A0?S[A].style.display="block":S[A].style.display="none";let I=document.getElementsByClassName("chal12");for(let A=0;A0?I[A].style.display="block":I[A].style.display="none";let N=document.getElementsByClassName("chal13");for(let A=0;A0?N[A].style.display="block":N[A].style.display="none";let X=document.getElementsByClassName("chal14");for(let A=0;A0?X[A].style.display="block":X[A].style.display="none";let re=document.getElementsByClassName("ascendunlockib");for(let A=0;A0?"inline-block":"none";let w=document.getElementsByClassName("prestigeunlockib");for(let A=0;A0?"block":"none";let J=document.getElementsByClassName("cubeUpgrade10");for(let A=0;A0?"flex":"none";let Te=document.getElementsByClassName("cubeUpgrade19");for(let A=0;A0?"block":"none";let ut=document.getElementsByClassName("sacrificeAnts");for(let A of Array.from(ut))A.style.display=e.achievements[173]===1?"block":"none";let ft=document.getElementsByClassName("hepteracts");for(let A of Array.from(ft))A.style.display=e.challenge15Exponent>=1e15?"block":"none";let xt=document.getElementsByClassName("singularity");for(let A of Array.from(xt)){let Ot=Number(A.getAttribute("count"))||1;A.style.display=e.highestSingularityCount>=Ot?"block":"none"}let Gt=document.getElementsByClassName("isEvent");for(let A of Array.from(Gt))A.style.display=o.isEvent?"block":"none";Lu();let er=i("corruptionHepteracts");er.style.display=e.achievements[255]>0?"block":"none";let Ht=document.getElementsByClassName("assortedCookies1"),ce=document.getElementsByClassName("assortedCookies2"),z=document.getElementsByClassName("assortedCookies3"),Z=document.getElementsByClassName("assortedCookies4"),se=document.getElementsByClassName("assortedCookies5");for(let A of Array.from(Ht))A.style.display=e.singularityUpgrades.cookies.getEffect().bonus?"block":"none";for(let A of Array.from(ce))A.style.display=e.singularityUpgrades.cookies2.getEffect().bonus?"block":"none";for(let A of Array.from(z))A.style.display=e.singularityUpgrades.cookies3.getEffect().bonus?"block":"none";for(let A of Array.from(Z))A.style.display=e.singularityUpgrades.cookies4.getEffect().bonus?"block":"none";for(let A of Array.from(se))A.style.display=e.singularityUpgrades.cookies5.getEffect().bonus?"block":"none";let ne=document.getElementsByClassName("goldenQuark3Upg");for(let A of Array.from(ne))A.style.display=e.singularityUpgrades.goldenQuarks3.getEffect().bonus>0?"block":"none";e.upgrades[89]===1?(i("transcendautotoggle").style.display="block",i("transcendamount").style.display="block",i("autotranscend").style.display="block"):(i("transcendautotoggle").style.display="none",i("transcendamount").style.display="none",i("autotranscend").style.display="none"),e.achievements[38]===1?(i("rune2area").style.display="flex",i("runeshowpower2").style.display="block"):(i("rune2area").style.display="none",i("runeshowpower2").style.display="none"),e.achievements[43]===1?(i("prestigeautotoggle").style.display="block",i("prestigeamount").style.display="block",i("autoprestige").style.display="block"):(i("prestigeautotoggle").style.display="none",i("prestigeamount").style.display="none",i("autoprestige").style.display="none"),e.achievements[44]===1?(i("rune3area").style.display="flex",i("runeshowpower3").style.display="block"):(i("rune3area").style.display="none",i("runeshowpower3").style.display="none"),e.achievements[102]===1?(i("rune4area").style.display="flex",i("runeshowpower4").style.display="block"):(i("rune4area").style.display="none",i("runeshowpower4").style.display="none"),e.achievements[119]===1?i("talisman1area").style.display="flex":i("talisman1area").style.display="none",e.achievements[126]===1?i("talisman2area").style.display="flex":i("talisman2area").style.display="none",e.achievements[133]===1?i("talisman3area").style.display="flex":i("talisman3area").style.display="none",e.achievements[134]===1?(i("toggleRuneSubTab2").style.display="block",i("toggleRuneSubTab3").style.display="block"):(i("toggleRuneSubTab2").style.display="none",i("toggleRuneSubTab3").style.display="none"),e.achievements[140]===1?i("talisman4area").style.display="flex":i("talisman4area").style.display="none",e.achievements[147]===1?i("talisman5area").style.display="flex":i("talisman5area").style.display="none",e.achievements[173]===1?i("sacrificeAnts").style.display="block":i("sacrificeAnts").style.display="none",e.researches[39]>0?i("reincarnationCrystalInfo").style.display="block":i("reincarnationCrystalInfo").style.display="none",e.researches[40]>0?i("reincarnationMythosInfo").style.display="block":i("reincarnationMythosInfo").style.display="none",e.researches[46]>0?i("reincarnateautomation").style.display="block":i("reincarnateautomation").style.display="none",e.researches[82]>0?(i("rune5area").style.display="flex",i("runeshowpower5").style.display="block"):(i("rune5area").style.display="none",i("runeshowpower5").style.display="none"),e.researches[124]>0?(i("antSacrificeButtons").style.display="flex",i("autoAntSacrifice").style.display="block"):(i("antSacrificeButtons").style.display="none",i("autoAntSacrifice").style.display="none"),e.researches[124]>0||e.highestSingularityCount>0?i("toggleAutoSacrificeAnt").style.display="block":i("toggleAutoSacrificeAnt").style.display="none",e.researches[130]>0?i("toggleautofortify").style.display="block":i("toggleautofortify").style.display="none",e.researches[135]>0?i("toggleautoenhance").style.display="block":i("toggleautoenhance").style.display="none";for(let A=1;A<=5;A++)e.researches[190]>0?i(`tesseractAutoToggle${A}`).style.display="block":i(`tesseractAutoToggle${A}`).style.display="none";e.researches[190]>0?i("tesseractautobuytoggle").style.display="block":i("tesseractautobuytoggle").style.display="none",e.researches[190]>0?i("tesseractautobuymode").style.display="block":i("tesseractautobuymode").style.display="none",e.researches[190]>0?i("tesseractAmount").style.display="block":i("tesseractAmount").style.display="none",e.researches[190]>0?i("autotessbuyeramount").style.display="block":i("autotessbuyeramount").style.display="none",e.antUpgrades[11]>0||e.ascensionCount>0?i("talisman6area").style.display="flex":i("talisman6area").style.display="none",e.shopUpgrades.offeringAuto>0?i("toggleautosacrifice").style.display="block":i("toggleautosacrifice").style.display="none",e.cubeUpgrades[51]>0&&e.highestSingularityCount>=40?i("toggleautoBuyFragments").style.display="block":i("toggleautoBuyFragments").style.display="none",e.shopUpgrades.obtainiumAuto>0?i("toggleautoresearch").style.display="block":i("toggleautoresearch").style.display="none",i("toggleautoresearchmode").style.display=e.shopUpgrades.obtainiumAuto>0&&qt()?"block":"none",jl()?i("talisman7area").style.display="flex":i("talisman7area").style.display="none",e.cubeUpgrades[8]>0?i("reincarnateAutoUpgrade").style.display="block":i("reincarnateAutoUpgrade").style.display="none",wa()?(i("rune6area").style.display="flex",i("runeshowpower6").style.display="block"):(i("rune6area").style.display="none",i("runeshowpower6").style.display="none"),e.platonicUpgrades[20]>0?(i("rune7area").style.display="flex",i("runeshowpower7").style.display="block"):(i("rune7area").style.display="none",i("runeshowpower7").style.display="none"),e.highestSingularityCount>0?i("saveOffToggle").style.display="block":i("saveOffToggle").style.display="none",e.highestSingularityCount>=35?(i("openCubes").style.display="block",i("cubeOpensInput").style.display="block",i("openTesseracts").style.display="block",i("tesseractsOpensInput").style.display="block",i("openHypercubes").style.display="block",i("hypercubesOpensInput").style.display="block",i("openPlatonicCube").style.display="block",i("platonicCubeOpensInput").style.display="block"):(i("openCubes").style.display="none",i("cubeOpensInput").style.display="none",i("openTesseracts").style.display="none",i("tesseractsOpensInput").style.display="none",i("openHypercubes").style.display="none",i("hypercubesOpensInput").style.display="none",i("openPlatonicCube").style.display="none",i("platonicCubeOpensInput").style.display="none"),e.highestSingularityCount>=50&&e.singularityCount=150?i("toggleAutoCubeUpgrades").style.display="block":i("toggleAutoCubeUpgrades").style.display="none",e.highestSingularityCount>=100&&e.singularityCount=200?i("toggleAutoPlatonicUpgrades").style.display="block":i("toggleAutoPlatonicUpgrades").style.display="none",e.highestSingularityCount>0&&e.ascensionCount>0?i("settingpic6").style.display="block":i("settingpic6").style.display="none",e.highestSingularityCount>0&&e.challenge15Exponent>=1e15?i("heptnotificationpic").style.display="block":i("heptnotificationpic").style.display="none",i("warpAuto").style.display=e.shopUpgrades.autoWarp>0?"":"none";let he=document.getElementsByClassName("octeracts");for(let A of Array.from(he))A.style.display=e.singularityUpgrades.octeractUnlock.getEffect().bonus?"block":"none";let Fe=document.getElementsByClassName("singChallenges");for(let A of Array.from(Fe))A.style.display=e.highestSingularityCount>=25?"block":"none";i("toggleSingularitySubTab4").style.display=e.singularityChallenges.noSingularityUpgrades.completions>=1?"block":"none",i("challengesTabsToggle").style.display=e.highestSingularityCount>=25?"flex":"none",e.runelevels[6]>0||e.highestSingularityCount>0?i("singularitybtn").style.display="block":i("singularitybtn").style.display="none",e.highestSingularityCount>0&&e.ascensionCount>=1?i("totalQuarkCountStatisticSing").style.display="block":i("totalQuarkCountStatisticSing").style.display="none",i("ascensionStats").style.visibility=e.achievements[197]>0||e.highestSingularityCount>0?"visible":"hidden",i("ascHyperStats").style.display=e.challengecompletions[13]>0?"":"none",i("ascPlatonicStats").style.display=e.challengecompletions[14]>0?"":"none",i("ascHepteractStats").style.display=e.achievements[255]>0?"":"none";let Mt={toggle1:e.upgrades[81]===1,toggle2:e.upgrades[82]===1,toggle3:e.upgrades[83]===1,toggle4:e.upgrades[84]===1,toggle5:e.upgrades[85]===1,toggle6:e.upgrades[86]===1,toggle7:e.upgrades[87]===1,toggle8:e.upgrades[88]===1,toggle10:e.achievements[78]===1,toggle11:e.achievements[85]===1,toggle12:e.achievements[92]===1,toggle13:e.achievements[99]===1,toggle14:e.achievements[106]===1,toggle15:e.achievements[43]===1,toggle16:e.upgrades[94]===1,toggle17:e.upgrades[95]===1,toggle18:e.upgrades[96]===1,toggle19:e.upgrades[97]===1,toggle20:e.upgrades[98]===1,toggle21:e.upgrades[89]===1,toggle22:e.cubeUpgrades[7]===1,toggle23:e.cubeUpgrades[7]===1,toggle24:e.cubeUpgrades[7]===1,toggle25:e.cubeUpgrades[7]===1,toggle26:e.cubeUpgrades[7]===1,toggle27:e.researches[46]===1,coinAutoUpgrade:e.upgrades[91]===1,prestigeAutoUpgrade:e.upgrades[92]===1,transcendAutoUpgrade:e.upgrades[99]===1,generatorsAutoUpgrade:e.upgrades[90]===1,toggle9:e.unlocks.prestige,toggle28:e.prestigeCount>.5||e.reincarnationCount>.5,toggle29:e.transcendCount>.5||e.reincarnationCount>.5,toggle30:e.reincarnationCount>.5,toggle31:e.ascensionCount>0,toggle32:e.achievements[173]>0,toggle33:e.highestSingularityCount>0&&e.ascensionCount>0,toggle34:e.unlocks.coinfour,toggle35:e.challenge15Exponent>=1e15&&e.highestSingularityCount>0,toggle36:e.highestSingularityCount>=15,toggle37:e.highestSingularityCount>=15,toggle38:e.highestSingularityCount>0,toggle39:e.unlocks.prestige,toggle40:e.unlocks.prestige,toggle41:e.challengecompletions[11]>0,toggle42:e.highestSingularityCount>=6,toggle43:e.highestSingularityCount>=6};Object.keys(Mt).forEach(A=>{let Ot=i(A);if(Ot===null){console.error(`Automation unlock failed to find element with ID '${A}'.`);return}Ot.style.display=Mt[A]?"block":"none"}),B0()},i0=()=>{var r,n;i("buildings").style.display="none",i("buildingstab").style.backgroundColor="",i("upgrades").style.display="none",i("upgradestab").style.backgroundColor="",i("settings").style.display="none",i("statistics").style.display="none",i("achievementstab").style.backgroundColor="",i("achievementstab").style.color="white",i("runes").style.display="none",i("runestab").style.backgroundColor="",i("challenges").style.display="none",i("challengetab").style.backgroundColor="",i("research").style.display="none",i("researchtab").style.backgroundColor="",i("shop").style.display="none",i("shoptab").style.backgroundColor="",i("ants").style.display="none",i("anttab").style.backgroundColor="",i("cubetab").style.backgroundColor="",i("traitstab").style.backgroundColor="",i("cubes").style.display="none",i("traits").style.display="none",i("singularity").style.display="none",i("singularitytab").style.backgroundColor="",i("event").style.display="none",i("eventtab").style.backgroundColor="",(r=document.getElementById("pseudoCoins"))==null||r.style.setProperty("display","none"),i("pseudoCoinstab").style.backgroundColor="";let t=i("settingstab");if(t.style.backgroundColor="",t.style.borderColor="white",o.currentTab===0&&(i("buildingstab").style.backgroundColor="orange",i("buildings").style.display="block"),o.currentTab===1&&(i("upgrades").style.display="block",i("upgradestab").style.backgroundColor="orange",i("upgradedescription").textContent=u.t("upgrades.hoverOverUpgrade")),o.currentTab===10){i("settings").style.display="block";let a=i("settingstab");a.style.backgroundColor="orange",a.style.borderColor="gold"}o.currentTab===2?(i("statistics").style.display="block",i("achievementstab").style.backgroundColor="white",i("achievementstab").style.color="black",i("achievementprogress").textContent=u.t("achievements.totalPoints",{x:d(e.achievementPoints),y:d(aa),z:(100*e.achievementPoints/aa).toPrecision(4)})):o.currentTab===3&&(i("runes").style.display="block",i("runestab").style.backgroundColor="blue",i("runeshowlevelup").textContent=u.t("runes.hover"),i("researchrunebonus").textContent=u.t("runes.thanksResearches",{percent:d(100*o.effectiveLevelMult-100,4,!0)}),Nt(1,!1),Nt(2,!1),Nt(3,!1),Nt(4,!1),Nt(5,!1),Nt(6,!1),Nt(7,!1)),o.currentTab===4&&(i("challenges").style.display="block",i("challengetab").style.backgroundColor="purple"),o.currentTab===5&&(i("research").style.display="block",i("researchtab").style.backgroundColor="green"),o.currentTab===11&&(i("shop").style.display="block",i("shoptab").style.backgroundColor="limegreen"),o.currentTab===6&&(i("ants").style.display="block",i("anttab").style.backgroundColor="brown"),o.currentTab===7&&(i("cubes").style.display="flex",i("cubetab").style.backgroundColor="white"),o.currentTab===8&&(i("traits").style.display="flex",i("traitstab").style.backgroundColor="white"),o.currentTab===9&&(i("singularity").style.display="block",i("singularitytab").style.backgroundColor="lightgoldenrodyellow",Nc(),_c()),o.currentTab===12&&(i("event").style.display="block",i("eventtab").style.backgroundColor="gold"),o.currentTab===13&&(Nl(),(n=document.getElementById("pseudoCoins"))==null||n.style.setProperty("display","unset"),i("pseudoCoinstab").style.backgroundColor="orange")},DC={[0]:$m,[1]:_m,[2]:Dm,[3]:Gm,[4]:Hm,[5]:fl,[10]:qm,[11]:Lu,[6]:Fm,[7]:hl,[8]:Qm,[9]:jm,[12]:Vm,[13]:Wm},bd=()=>{let t=["coins","runeshards","prestigePoints","transcendPoints","transcendShards","reincarnationPoints","worlds","researchPoints"],r=["coinDisplay","offeringDisplay","diamondDisplay","mythosDisplay","mythosshardDisplay","particlesDisplay","quarkDisplay","obtainiumDisplay"];for(let n=0;n{if(i("prestigebtn").style.backgroundColor=e.toggles[15]&&e.achievements[43]===1?"green":"",i("transcendbtn").style.backgroundColor=e.toggles[21]&&e.upgrades[89]>.5&&e.currentChallenge.transcension===0?"green":"",i("reincarnatebtn").style.backgroundColor=e.toggles[27]&&e.researches[46]>.5&&e.currentChallenge.transcension===0&&e.currentChallenge.reincarnation===0?"green":"",i("acceleratorboostbtn").style.backgroundColor=e.toggles[8]&&e.upgrades[88]>.5?"green":"",i("challengebtn").style.backgroundColor=e.currentChallenge.transcension===0?"":"purple",i("reincarnatechallengebtn").style.backgroundColor=e.currentChallenge.reincarnation===0?"":"purple",i("ascendChallengeBtn").style.backgroundColor=e.currentChallenge.ascension===0?"":"purple",i("ascendbtn").style.backgroundColor=e.autoAscend&&e.challengecompletions[11]>0&&e.cubeUpgrades[10]>0?"green":"",i("singularitybtn").style.filter=e.runelevels[6]>0?"":"contrast(1.25) sepia(1) grayscale(0.25)",e.toggles[33]&&e.highestSingularityCount===0&&(e.toggles[28]&&!e.unlocks.prestige&&(i("prestigebtn").style.boxShadow=e.coinsThisPrestige.gte(1e16)?"cyan 0px 0px 10px 2px":""),e.toggles[29]&&!e.unlocks.transcend&&(i("transcendbtn").style.boxShadow=e.coinsThisTranscension.gte(1e100)?"plum 0px 0px 10px 2px":""),e.toggles[30]&&!e.unlocks.reincarnate&&(i("reincarnatebtn").style.boxShadow=e.transcendShards.gte(1e300)?"greenyellow 0px 0px 10px 2px":""),e.toggles[31]&&e.ascensionCount===0&&(i("ascendbtn").style.boxShadow=e.challengecompletions[10]>0?"orange 0px 0px 10px 2px":"")),o.currentTab===0&&o.buildingSubTab==="coin"){let t=i("buycoin1"),r=i("buycoin2"),n=i("buycoin3"),a=i("buycoin4"),s=i("buycoin5"),l=i("buyaccelerator"),c=i("buymultiplier"),p=i("buyacceleratorboost");(!e.toggles[1]||e.upgrades[81]===0)&&e.coins.gte(e.firstCostCoin)?t.classList.add("buildingPurchaseBtnAvailable"):t.classList.remove("buildingPurchaseBtnAvailable"),(!e.toggles[2]||e.upgrades[82]===0)&&e.coins.gte(e.secondCostCoin)?r.classList.add("buildingPurchaseBtnAvailable"):r.classList.remove("buildingPurchaseBtnAvailable"),(!e.toggles[3]||e.upgrades[83]===0)&&e.coins.gte(e.thirdCostCoin)?n.classList.add("buildingPurchaseBtnAvailable"):n.classList.remove("buildingPurchaseBtnAvailable"),(!e.toggles[4]||e.upgrades[84]===0)&&e.coins.gte(e.fourthCostCoin)?a.classList.add("buildingPurchaseBtnAvailable"):a.classList.remove("buildingPurchaseBtnAvailable"),(!e.toggles[5]||e.upgrades[85]===0)&&e.coins.gte(e.fifthCostCoin)?s.classList.add("buildingPurchaseBtnAvailable"):s.classList.remove("buildingPurchaseBtnAvailable"),(!e.toggles[6]||e.upgrades[86]===0)&&e.coins.gte(e.acceleratorCost)?l.classList.add("buildingPurchaseBtnAvailable"):l.classList.remove("buildingPurchaseBtnAvailable"),(!e.toggles[7]||e.upgrades[87]===0)&&e.coins.gte(e.multiplierCost)?c.classList.add("buildingPurchaseBtnAvailable"):c.classList.remove("buildingPurchaseBtnAvailable"),(!e.toggles[8]||e.upgrades[88]===0)&&e.prestigePoints.gte(e.acceleratorBoostCost)?p.classList.add("buildingPurchaseBtnAvailable"):p.classList.remove("buildingPurchaseBtnAvailable")}if(o.currentTab===0&&o.buildingSubTab==="diamond"){let t=i("buydiamond1"),r=i("buydiamond2"),n=i("buydiamond3"),a=i("buydiamond4"),s=i("buydiamond5"),l=i("buycrystalupgrade1"),c=i("buycrystalupgrade2"),p=i("buycrystalupgrade3"),g=i("buycrystalupgrade4"),m=i("buycrystalupgrade5");(!e.toggles[10]||e.achievements[78]===0)&&e.prestigePoints.gte(e.firstCostDiamonds)?t.classList.add("buildingPurchaseBtnAvailable"):t.classList.remove("buildingPurchaseBtnAvailable"),(!e.toggles[11]||e.achievements[85]===0)&&e.prestigePoints.gte(e.secondCostDiamonds)?r.classList.add("buildingPurchaseBtnAvailable"):r.classList.remove("buildingPurchaseBtnAvailable"),(!e.toggles[12]||e.achievements[92]===0)&&e.prestigePoints.gte(e.thirdCostDiamonds)?n.classList.add("buildingPurchaseBtnAvailable"):n.classList.remove("buildingPurchaseBtnAvailable"),(!e.toggles[13]||e.achievements[99]===0)&&e.prestigePoints.gte(e.fourthCostDiamonds)?a.classList.add("buildingPurchaseBtnAvailable"):a.classList.remove("buildingPurchaseBtnAvailable"),(!e.toggles[14]||e.achievements[106]===0)&&e.prestigePoints.gte(e.fifthCostDiamonds)?s.classList.add("buildingPurchaseBtnAvailable"):s.classList.remove("buildingPurchaseBtnAvailable");let h=0;h+=Math.floor(o.rune3level/16*o.effectiveLevelMult)*100/100,e.upgrades[73]===1&&e.currentChallenge.reincarnation!==0&&(h+=10),e.achievements[79]<1?e.prestigeShards.gte(f.pow(10,o.crystalUpgradesCost[0]+o.crystalUpgradeCostIncrement[0]*Math.floor(Math.pow(e.crystalUpgrades[0]+.5-h,2)/2)))?l.style.backgroundColor="purple":l.style.backgroundColor="":l.style.backgroundColor="green",e.achievements[86]<1?e.prestigeShards.gte(f.pow(10,o.crystalUpgradesCost[1]+o.crystalUpgradeCostIncrement[1]*Math.floor(Math.pow(e.crystalUpgrades[1]+.5-h,2)/2)))?c.style.backgroundColor="purple":c.style.backgroundColor="":c.style.backgroundColor="green",e.achievements[93]<1?e.prestigeShards.gte(f.pow(10,o.crystalUpgradesCost[2]+o.crystalUpgradeCostIncrement[2]*Math.floor(Math.pow(e.crystalUpgrades[2]+.5-h,2)/2)))?p.style.backgroundColor="purple":p.style.backgroundColor="":p.style.backgroundColor="green",e.achievements[100]<1?e.prestigeShards.gte(f.pow(10,o.crystalUpgradesCost[3]+o.crystalUpgradeCostIncrement[3]*Math.floor(Math.pow(e.crystalUpgrades[3]+.5-h,2)/2)))?g.style.backgroundColor="purple":g.style.backgroundColor="":g.style.backgroundColor="green",e.achievements[107]<1?e.prestigeShards.gte(f.pow(10,o.crystalUpgradesCost[4]+o.crystalUpgradeCostIncrement[4]*Math.floor(Math.pow(e.crystalUpgrades[4]+.5-h,2)/2)))?m.style.backgroundColor="purple":m.style.backgroundColor="":m.style.backgroundColor="green"}if(o.currentTab===3){if(o.runescreen==="runes")for(let t=1;t<=7;t++)e.runeshards>.5?i(`activaterune${t}`).classList.add("runeButtonAvailable"):i(`activaterune${t}`).classList.remove("runeButtonAvailable");if(o.runescreen==="talismans"){let t=i("buyTalismanItem1"),r=i("buyTalismanItem2"),n=i("buyTalismanItem3"),a=i("buyTalismanItem4"),s=i("buyTalismanItem5"),l=i("buyTalismanItem6"),c=i("buyTalismanItem7"),p=[t,r,n,a,s,l,c];for(let g=0;go.talismanResourceObtainiumCosts[g]&&e.runeshards>o.talismanResourceOfferingCosts[g]?p[g].classList.add("talisminBtnAvailable"):p[g].classList.remove("talisminBtnAvailable")}}if(o.currentTab===0&&o.buildingSubTab==="mythos")for(let t=1;t<=5;t++){let r=e.toggles[t+15],n=e[`${o.ordinals[t-1]}CostMythos`];(!r||!e.upgrades[93+t])&&e.transcendPoints.gte(n)?i(`buymythos${t}`).classList.add("buildingPurchaseBtnAvailable"):i(`buymythos${t}`).classList.remove("buildingPurchaseBtnAvailable")}if(o.currentTab===0&&o.buildingSubTab==="particle")for(let t=1;t<=5;t++){let r=e[`${o.ordinals[t-1]}CostParticles`];e.reincarnationPoints.gte(r)?i(`buyparticles${t}`).classList.add("buildingPurchaseBtnAvailable"):i(`buyparticles${t}`).classList.remove("buildingPurchaseBtnAvailable")}if(o.currentTab===0&&o.buildingSubTab==="tesseract"){for(let t=1;t<=5;t++){let r=e[`ascendBuilding${t}`].cost;Number(e.wowTesseracts)>=r?i(`buyTesseracts${t}`).classList.add("buildingPurchaseBtnAvailable"):i(`buyTesseracts${t}`).classList.remove("buildingPurchaseBtnAvailable")}for(let t=1;t<=8;t++)e.researches[175]>=1?(i(`buyConstantUpgrade${t}`).classList.remove("constUpgradeAvailable"),i(`buyConstantUpgrade${t}`).classList.add("constUpgradeAuto")):(i(`buyConstantUpgrade${t}`).classList.remove("constUpgradeAuto"),e.ascendShards.gte(f.pow(10,e.constantUpgrades[t]).times(o.constUpgradeCosts[t]))?i(`buyConstantUpgrade${t}`).classList.add("constUpgradeAvailable"):i(`buyConstantUpgrade${t}`).classList.remove("constUpgradeAvailable"));for(let t=9;t<=10;t++)e.researches[175]>=1||e.constantUpgrades[t]>=1?(i(`buyConstantUpgrade${t}`).classList.remove("constUpgradeAvailable"),i(`buyConstantUpgrade${t}`).classList.add("constUpgradeAuto")):(i(`buyConstantUpgrade${t}`).classList.remove("constUpgradeAuto"),e.ascendShards.gte(f.pow(10,e.constantUpgrades[t]).times(o.constUpgradeCosts[t]))?i(`buyConstantUpgrade${t}`).classList.add("constUpgradeAvailable"):i(`buyConstantUpgrade${t}`).classList.remove("constUpgradeAvailable"))}if(o.currentTab===6){e.reincarnationPoints.gte(e.firstCostAnts)?i("anttier1").classList.add("antTierBtnAvailable"):i("anttier1").classList.remove("antTierBtnAvailable");for(let t=2;t<=8;t++){let r=e[`${o.ordinals[t-1]}CostAnts`];e.antPoints.gte(r)?i(`anttier${t}`).classList.add("antTierBtnAvailable"):i(`anttier${t}`).classList.remove("antTierBtnAvailable")}for(let t=1;t<=12;t++)e.antPoints.gte(f.pow(o.antUpgradeCostIncreases[t-1],e.antUpgrades[t-1]*o.extinctionMultiplier[e.usedCorruptions[10]]).times(o.antUpgradeBaseCost[t-1]))?i(`antUpgrade${t}`).classList.add("antUpgradeBtnAvailable"):i(`antUpgrade${t}`).classList.remove("antUpgradeBtnAvailable")}},Lr=()=>{for(let t=1;t<=15;t++){let r=i(`challenge${t}`);r.classList.remove("challengeActive"),e.currentChallenge.transcension===t&&r.classList.add("challengeActive"),e.currentChallenge.reincarnation===t&&r.classList.add("challengeActive"),e.currentChallenge.ascension===t&&r.classList.add("challengeActive")}e.retrychallenges?i("retryChallenge").textContent=u.t("challenges.retryChallengesOn"):i("retryChallenge").textContent=u.t("challenges.retryChallengesOff");for(let t=1;t<=15;t++)Ir(t)},Ir=t=>{let r=i(`challenge${t}level`),n=je(t);t===15?r.textContent=d(e.challenge15Exponent,0,!0):r.textContent=`${e.challengecompletions[t]}/${n}`},I0=()=>{for(let n=1;n<=280;n++)i(`ach${n}`).style.backgroundColor="";let t=document.getElementsByClassName("purpleach"),r=document.getElementsByClassName("redach");for(let n=0;n.5&&R(n)},xl=()=>{let t=i("corrStatsBtn"),r=i("corrLoadoutsBtn");e.corruptionShowStats?(i("corruptionStats").style.display="flex",i("corruptionLoadouts").style.display="none",t.classList.add("subtab-active"),r.classList.remove("subtab-active")):(i("corruptionStats").style.display="none",i("corruptionLoadouts").style.display="flex",t.classList.remove("subtab-active"),r.classList.add("subtab-active"))},GC=()=>{let t=e.ascensionCounter;t===0&&(t=1);let[r,n,a,s,l]=Xr().slice(4),c=e.singularityUpgrades.oneMind.getEffect().bonus,p={ascLen:zt(e.ascStatToggles[6]?e.ascensionCounter:e.ascensionCounterReal,0),ascCubes:d(r*(e.ascStatToggles[1]?1:1/t),2),ascTess:d(n*(e.ascStatToggles[2]?1:1/t),3),ascHyper:d(a*(e.ascStatToggles[3]?1:1/t),4),ascPlatonic:d(s*(e.ascStatToggles[4]?1:1/t),5),ascHepteract:d(l*(e.ascStatToggles[5]?1:1/t),3),ascC10:`${d(e.challengecompletions[10])}`,ascTimeAccel:`${d(qe().mult,3)}x`,ascAscensionTimeAccel:`${d(Rr(),3)}x${c?"*":""}`,ascSingularityCount:d(e.singularityCount),ascSingLen:zt(e.singularityCounter),ascSingChallengeLen:zt(e.singChallengeTimer)};for(let g in p){let m=i(g);m.textContent!==p[g]&&(m.textContent=p[g]),g==="ascSingChallengeLen"&&(e.singularityChallenges.limitedTime.enabled&&e.singChallengeTimer>600-20*e.singularityChallenges.limitedTime.completions?m.style.color="red":m.style.color="white")}},HC={[0]:"yellow",[1]:"yellow",[2]:"white",[3]:"cyan",[4]:"plum",[5]:"green",[6]:"brown",[7]:"purple",[8]:"orange",[10]:"white",[11]:"limegreen"},Dl=()=>{var n;let t=i("tabBorder"),r=(n=HC[o.currentTab])!=null?n:"yellow";t.style.backgroundColor=r},Yo,Hs,hd=class{constructor(){Tt(this,Yo,[]);Tt(this,Hs,!1)}enqueue(r){return new Promise((n,a)=>{ee(this,Yo).push({action:r,resolve:n,reject:a}),this.dequeue()})}async dequeue(){if(ee(this,Hs))return!1;let r=ee(this,Yo).shift();if(!r)return!1;try{St(this,Hs,!0);let n=await r.action();r.resolve(n)}catch(n){r.reject(n)}finally{St(this,Hs,!1),this.dequeue()}return!0}};Yo=new WeakMap,Hs=new WeakMap;var yd=new hd,ye=async t=>yd.enqueue(()=>{let r=i("confirmationBox"),n=i("confirmWrapper"),a=i("confirm"),s=i("transparentBG"),l=i("ok_confirm"),c=i("cancel_confirm");i("alertWrapper").style.display="none",i("promptWrapper").style.display="none",r.style.display="block",n.style.display="block",s.style.display="block",a.querySelector("p").textContent=t,a.focus();let p=Fn(),g=({target:h})=>{let b=h;l.removeEventListener("click",g),c.removeEventListener("click",g),a.removeEventListener("keyup",m),r.style.display="none",n.style.display="none",s.style.display="none",p.resolve(b===l)},m=h=>h.key==="Enter"||h.key===" "?g({target:l}):h.key==="Escape"?g({target:c}):h.preventDefault();return l.addEventListener("click",g,{once:!0}),c.addEventListener("click",g,{once:!0}),a.addEventListener("keyup",m),p.promise}),P=t=>yd.enqueue(()=>{let r=i("confirmationBox"),n=i("alertWrapper"),a=i("transparentBG"),s=i("alert"),l=i("ok_alert");i("confirmWrapper").style.display="none",i("promptWrapper").style.display="none",r.style.display="block",n.style.display="block",a.style.display="block",s.querySelector("p").textContent=t,s.focus();let c=Fn(),p=()=>{l.removeEventListener("click",p),s.removeEventListener("keyup",g),r.style.display="none",n.style.display="none",a.style.display="none",c.resolve()},g=m=>(m.key==="Enter"||m.key===" ")&&p();return l.addEventListener("click",p,{once:!0}),s.addEventListener("keyup",g),c.promise}),Ee=(t,r)=>yd.enqueue(()=>{let n=i("confirmationBox"),a=i("promptWrapper"),s=i("transparentBG"),l=i("prompt"),c=i("ok_prompt"),p=i("cancel_prompt");i("alertWrapper").style.display="none",i("confirmWrapper").style.display="none",n.style.display="block",a.style.display="block",s.style.display="block",l.querySelector("label").textContent=t,r&&(l.querySelector("input").placeholder=r),l.querySelector("input").focus();let g=Fn(),m=({target:b})=>{let C=b,v=C.parentNode.querySelector("input");c.removeEventListener("click",m),p.removeEventListener("click",m),l.querySelector("input").removeEventListener("keyup",h),n.style.display="none",a.style.display="none",s.style.display="none",g.resolve(C.id===c.id?v.value||v.placeholder:null),v.value=v.textContent=v.placeholder="",l.querySelector("input").blur()},h=b=>b.key==="Enter"?m({target:c}):b.key==="Escape"?m({target:p}):b.preventDefault();return c.addEventListener("click",m,{once:!0}),p.addEventListener("click",m,{once:!0}),l.querySelector("input").addEventListener("keyup",h),g.promise}),md,fd,Dt=(t,r=3e4)=>{let n=i("notification"),a=document.querySelector("#notification > p"),s=i("notifx");a.textContent=t,n.style.display="block",n.classList.remove("slide-out"),n.classList.add("slide-in");let l=Fn(),c=()=>{n.style.display="none",a.textContent="",fd=0},p=()=>{n.classList.add("slide-out"),n.classList.remove("slide-in"),md=0,s.removeEventListener("click",p),fd=setTimeout(c,1e3),l.resolve()};return s.addEventListener("click",p),clearTimeout(md),clearTimeout(fd),md=setTimeout(p,r),l.promise};var Fs=[0,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,2,8,10,2,8,10,10,2,8,10,10,10,10,10,2,4,6,8,10,10,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,1,2,4,6,8,9,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,20,20,20,40,60,60,100,20,20,40,40,60,60,100,20,20,40,40,60,60,100,20,40,40,40,60,60,100,40,40,40,60,60,100,100,40,40,60,60,100,100,100,20,40,40,60,60,100,100,40,60,100,60,100,100,40,40,40,40,40,40,40,40,40,40,40,40,100,100,0,50,75,75,75,100,100,150,50,75,75,75,100,100,150,50,75,75,75,100,100,150,10,10,20,20,30,40,50],aa=Fs.reduce((t,r)=>t+r,0),FC=t=>{let r=Xr(),n={118:d(Math.pow(.9925,e.challengecompletions[6]+e.challengecompletions[7]+e.challengecompletions[8]+e.challengecompletions[9]+e.challengecompletions[10]),4),169:d(f.log(e.antPoints.add(10),10),2),174:d(.4*f.log(e.antPoints.add(1),10),2),187:{x:d(Math.max(1,Math.log10(r[3]+1)-7),2),y:d(Math.min(100,e.ascensionCount/1e4),2)},188:d(Math.min(100,e.ascensionCount/5e4),2),189:d(Math.min(200,e.ascensionCount/25e5),2),193:d(f.log(e.ascendShards.add(1),10)/4,2),195:d(Math.min(25e3,f.log(e.ascendShards.add(1),10)/4),2),196:d(Math.min(2e3,f.log(e.ascendShards.add(1),10)/50),2),202:d(Math.min(200,e.ascensionCount/5e6),2),216:d(Math.min(200,e.ascensionCount/1e7),2),223:d(Math.min(200,e.ascensionCount/1337e4),2),240:d(Math.min(1.5,1+Math.max(2,Math.log10(qe().mult))/20),2),254:d(Math.min(15,Math.log10(r[3]+1)*.6),2,!0),255:d(Math.min(15,Math.log10(r[3]+1)*.6),2,!0),256:d(Math.min(15,Math.log10(r[3]+1)*.6),2,!0),257:d(Math.min(15,Math.log10(r[3]+1)*.6),2,!0),258:d(Math.min(15,Math.log10(r[3]+1)*.6),2,!0),262:d(Math.min(10,Math.log10(e.ascensionCount+1)),2),263:d(Math.min(10,Math.log10(e.ascensionCount+1)),2),264:d(Math.min(40,e.ascensionCount/2e11),2),265:d(Math.min(20,e.ascensionCount/8e12),2),266:d(Math.min(10,e.ascensionCount/1e14),2),267:d(Math.min(100,f.log(e.ascendShards.add(1),10)/1e3),2),270:d(Math.min(100,f.log(e.ascendShards.add(1),10)/1e4),2),271:d(Math.max(0,Math.min(1,(f.log(e.ascendShards.add(1),10)-1e5)/9e5)),2,!0)};if([3,4,5,6,7,10,11,12,13,14,17,18,19,20,21,24,25,26,27,28,31,32,33,34,35,36,37,38,43,44,45,46,47,50,51,52,53,57,58,59,60,61,62,71,72,73,74,75,76,77,78,79,80,82,84,85,86,87,89,91,92,93,94,96,98,99,100,101,102,103,105,106,107,108,110,112,115,117,119,122,124,126,127,128,129,131,132,133,134,135,136,137,140,141,147,171,172,173,176,177,178,179,180,181,182,197,198,199,200,201,204,205,206,207,208,209,211,212,213,214,215,218,219,220,221,222,250,251,253,259,260,261].includes(t)||t in n){let s=n[t],l=typeof s=="object"?s:{x:s};return u.t(`achievements.rewards.${t}`,l)}return""},QC=async t=>{if(e.highestSingularityCount===0&&(t===36||t===38||t===255))return P(u.t(`achievements.alerts.${t}`))},wt=t=>{t===1&&(e.prestigenoaccelerator&&R(60),e.prestigenomultiplier&&R(57),e.prestigenocoinupgrades&&R(64),o.prestigePointGain.gte(1)&&R(36),o.prestigePointGain.gte(1e6)&&R(37),o.prestigePointGain.gte(1e100)&&R(38),o.prestigePointGain.gte("1e1000")&&R(39),o.prestigePointGain.gte("1e10000")&&R(40),o.prestigePointGain.gte("1e77777")&&R(41),o.prestigePointGain.gte("1e250000")&&R(42)),t===2&&(e.transcendnoaccelerator&&R(61),e.transcendnomultiplier&&R(58),e.transcendnocoinupgrades&&R(65),e.transcendnocoinorprestigeupgrades&&R(66),o.transcendPointGain.gte(1)&&R(43),o.transcendPointGain.gte(1e6)&&R(44),o.transcendPointGain.gte(1e50)&&R(45),o.transcendPointGain.gte(1e308)&&R(46),o.transcendPointGain.gte("1e1500")&&R(47),o.transcendPointGain.gte("1e25000")&&R(48),o.transcendPointGain.gte("1e100000")&&R(49)),t===3&&(e.reincarnatenoaccelerator&&R(62),e.reincarnatenomultiplier&&R(59),e.reincarnatenocoinupgrades&&R(67),e.reincarnatenocoinorprestigeupgrades&&R(68),e.reincarnatenocoinprestigeortranscendupgrades&&R(69),e.reincarnatenocoinprestigetranscendorgeneratorupgrades&&R(70),o.reincarnationPointGain.gte(1)&&R(50),o.reincarnationPointGain.gte(1e5)&&R(51),o.reincarnationPointGain.gte(1e30)&&R(52),o.reincarnationPointGain.gte(1e200)&&R(53),o.reincarnationPointGain.gte("1e1500")&&R(54),o.reincarnationPointGain.gte("1e5000")&&R(55),o.reincarnationPointGain.gte("1e7777")&&R(56))},qC=[[1,.5,78],[1,2.5,79],[1,4.5,80],[1,9.5,81],[1,19.5,82],[1,49.5,83],[1,74.5,84],[2,.5,85],[2,2.5,86],[2,4.5,87],[2,9.5,88],[2,19.5,89],[2,49.5,90],[2,74.5,91],[3,.5,92],[3,2.5,93],[3,4.5,94],[3,9.5,95],[3,19.5,96],[3,49.5,97],[3,74.5,98],[4,.5,99],[4,2.5,100],[4,4.5,101],[4,9.5,102],[4,19.5,103],[4,49.5,104],[4,74.5,105],[5,.5,106],[5,2.5,107],[5,4.5,108],[5,9.5,109],[5,19.5,110],[5,49.5,111],[5,74.5,112],[6,.5,113],[6,1.5,114],[6,2.5,115],[6,4.5,116],[6,9.5,117],[6,14.5,118],[6,24.5,119],[7,.5,120],[7,1.5,121],[7,2.5,122],[7,4.5,123],[7,9.5,124],[7,14.5,125],[7,24.5,126],[8,.5,127],[8,1.5,128],[8,2.5,129],[8,4.5,130],[8,9.5,131],[8,19.5,132],[8,24.5,133],[9,.5,134],[9,1.5,135],[9,2.5,136],[9,4.5,137],[9,9.5,138],[9,19.5,139],[9,24.5,140],[10,.5,141],[10,1.5,142],[10,2.5,143],[10,4.5,144],[10,9.5,145],[10,19.5,146],[10,24.5,147],[15,.5,252]],jC={1:["1e1000",75],2:["1e1000",76],3:["1e99999",77],5:["1e120000",63]},yr=(t,r)=>{let n=ae(e.upgrades.slice(101,106));for(let[,a,s]of qC.filter(([l])=>l===t))e.challengecompletions[t]>a&&e.achievements[s]<1&&R(s);if([1,2,3,5].includes(t)&&!r){let[a,s]=jC[t];t===5?e.coinsThisTranscension.gte(a)&&e.acceleratorBought===0&&e.acceleratorBoostBought===0&&R(s):e.coinsThisTranscension.gte(a)&&n===0&&R(s)}if(t>=11&&t<=14){let a=[0,1,2,3,5,10,20,30];for(let s=1;s<=7;s++)e.challengecompletions[t]>=a[s]&&e.achievements[119+7*t+s]<1&&R(119+7*t+s)}e.challengecompletions[10]>=50&&t===11&&e.usedCorruptions[7]>=5&&e.achievements[247]<1&&R(247)},N0=[()=>e.firstOwnedCoin>=1&&e.achievements[1]<.5,()=>e.firstOwnedCoin>=10&&e.achievements[2]<.5,()=>e.firstOwnedCoin>=100&&e.achievements[3]<.5,()=>e.firstOwnedCoin>=1e3&&e.achievements[4]<.5,()=>e.firstOwnedCoin>=5e3&&e.achievements[5]<.5,()=>e.firstOwnedCoin>=1e4&&e.achievements[6]<.5,()=>e.firstOwnedCoin>=2e4&&e.achievements[7]<.5,()=>e.secondOwnedCoin>=1&&e.achievements[8]<.5,()=>e.secondOwnedCoin>=10&&e.achievements[9]<.5,()=>e.secondOwnedCoin>=100&&e.achievements[10]<.5,()=>e.secondOwnedCoin>=1e3&&e.achievements[11]<.5,()=>e.secondOwnedCoin>=5e3&&e.achievements[12]<.5,()=>e.secondOwnedCoin>=1e4&&e.achievements[13]<.5,()=>e.secondOwnedCoin>=2e4&&e.achievements[14]<.5,()=>e.thirdOwnedCoin>=1&&e.achievements[15]<.5,()=>e.thirdOwnedCoin>=10&&e.achievements[16]<.5,()=>e.thirdOwnedCoin>=100&&e.achievements[17]<.5,()=>e.thirdOwnedCoin>=1e3&&e.achievements[18]<.5,()=>e.thirdOwnedCoin>=5e3&&e.achievements[19]<.5,()=>e.thirdOwnedCoin>=1e4&&e.achievements[20]<.5,()=>e.thirdOwnedCoin>=2e4&&e.achievements[21]<.5,()=>e.fourthOwnedCoin>=1&&e.achievements[22]<.5,()=>e.fourthOwnedCoin>=10&&e.achievements[23]<.5,()=>e.fourthOwnedCoin>=100&&e.achievements[24]<.5,()=>e.fourthOwnedCoin>=1e3&&e.achievements[25]<.5,()=>e.fourthOwnedCoin>=5e3&&e.achievements[26]<.5,()=>e.fourthOwnedCoin>=1e4&&e.achievements[27]<.5,()=>e.fourthOwnedCoin>=2e4&&e.achievements[28]<.5,()=>e.fifthOwnedCoin>=1&&e.achievements[29]<.5,()=>e.fifthOwnedCoin>=10&&e.achievements[30]<.5,()=>e.fifthOwnedCoin>=66&&e.achievements[31]<.5,()=>e.fifthOwnedCoin>=666&&e.achievements[32]<.5,()=>e.fifthOwnedCoin>=6666&&e.achievements[33]<.5,()=>e.fifthOwnedCoin>=17777&&e.achievements[34]<.5,()=>e.fifthOwnedCoin>=42777&&e.achievements[35]<.5],$0=()=>{for(let t of N0)if(t()){let r=N0.indexOf(t)+1;R(r)}},As=(t,r=0)=>{if(t===1){let n=[0,1,2,10,100,1e3,14142,141421,1414213,1e7,1e8,2e9,4e10,8e11,16e12,1e14];for(let a=1;a<=7;a++)e.ascensionCount>=n[a]&&e.achievements[182+a]<1&&R(182+a),e.ascensionCount>=n[a+8]&&e.achievements[259+a]<1&&R(259+a);e.ascensionCount>=n[8]&&e.achievements[240]<1&&R(240)}if(t===2){let n=[0,3.14,1e6,432e8,69e20,1509e30,1e66,"1.8e308","1e1000","1e5000","1e15000","1e50000","1e100000","1e300000","1e1000000"];for(let a=1;a<=7;a++)e.ascendShards.gte(n[a])&&e.achievements[189+a]<1&&R(189+a),e.ascendShards.gte(n[a+7])&&e.achievements[266+a]<1&&R(266+a)}if(t===3){let n=[0,1e5,1e6,1e7,1e8,1e9,5e9,25e9,1e12,1e14,1e17,2e18,4e19,1e21,1e23];for(let a=1;a<=7;a++)r>=n[a]&&e.achievements[224+a]<1&&R(224+a),r>=n[7+a]&&e.achievements[252+a]<1&&R(252+a)}},_0=t=>{let r=1;t>=183&&(r=5),t>=253&&(r=40);let n=e.worlds.applyBonus(1),a=r*n;return a>100&&(a=Math.pow(100,.6)*Math.pow(a,.4)),Math.floor(Fs[t]*a)},D0=t=>{let r=u.t(`achievements.descriptions.${t}`,{number:`${t}`}),n=e.achievements[t]>.5?u.t("achievements.completed"):"",a=FC(t);i("achievementdescription").textContent=r+n,i("achievementreward").textContent=u.t("achievements.rewardGainMessage",{x:Fs[t],y:d(_0(t),0,!0),z:a}),e.achievements[t]>.5?i("achievementdescription").style.color="gold":i("achievementdescription").style.color="white"},R=t=>{if(e.achievements[t]<1){if(e.toggles[34]){let r=u.t(`achievements.descriptions.${t}`,{number:`${t}`});Dt(u.t("achievements.notification",{m:r}))}QC(t),e.achievementPoints+=Fs[t],e.worlds.add(_0(t),!1),i("achievementprogress").textContent=u.t("achievements.totalPoints",{x:d(e.achievementPoints),y:d(aa),z:(100*e.achievementPoints/aa).toPrecision(4)}),e.achievements[t]=1,Oe()}i(`ach${t}`).style.backgroundColor="Green",Ct.emit("achievement",t)};var Jo=class{constructor(){this.totalVal=0}initialize(){this.totalVal=0;for(let r of Object.keys(this.vals))this.updateVal(r,!0)}updateTotal(r,n,a=!1){a?this.totalVal+=n:this.totalVal+=n-r}flatten(){let r=Object.values(this.vals);return r.push(this.totalVal),r}},vd=class{constructor(){this.totalVal=1}initialize(){this.totalVal=1;for(let r of Object.keys(this.vals))this.updateVal(r,!0)}updateTotal(r,n,a=!1){if(a)this.totalVal*=n;else if(this.totalVal!==0&&n!==0)this.totalVal*=n/r;else if(n===0)this.totalVal=0;else{let s=this.flatten();s.pop(),this.totalVal=be(s)}}flatten(){let r=Object.values(this.vals);return r.push(this.totalVal),r}},Vl=class extends Jo{constructor(){super();this.reset()}reset(){this.vals={Base:1,Exalt1:0,SingularityPerk:0,ShopUpgrades:0,Exalt5:0,Event:0},this.totalVal=1}updateVal(n,a=!1){let s=this.vals[n];switch(n){case"Base":{this.vals[n]=1;break}case"Exalt1":{this.vals[n]=+e.singularityChallenges.noSingularityUpgrades.rewards.luckBonus;break}case"SingularityPerk":{this.vals[n]=Pd();break}case"ShopUpgrades":{this.vals[n]=e.shopUpgrades.shopAmbrosiaLuckMultiplier4/100;break}case"Exalt5":{this.vals[n]=+e.singularityChallenges.noAmbrosiaUpgrades.rewards.luckBonus;break}case"Event":{this.vals[n]=o.isEvent?Ye(12):0;break}}let l=this.vals[n];this.updateTotal(s,l,a),e.caches.ambrosiaLuck.updateVal("Base")}},Wl=class extends Jo{constructor(){super();this.reset()}reset(){this.vals={Base:100,SingPerks:0,ShopUpgrades:0,SingularityBerries:0,OcteractBerries:0,BlueberryUpgrade1:0,BlueberryUpgrade2:0,BlueberryCubeLuck1:0,BlueberryQuarkLuck1:0,OneHundredThirtyOne:0,TwoHundredSixtyNine:0,ShopOcteractAmbrosiaLuck:0,Exalt5:0},this.totalVal=0,this.usedTotal=0}updateVal(n,a=!1){let s=this.vals[n];switch(n){case"Base":{this.vals[n]=100;break}case"SingPerks":{this.vals[n]=Cd();break}case"ShopUpgrades":{this.vals[n]=xd();break}case"SingularityBerries":{this.vals[n]=Td();break}case"OcteractBerries":{this.vals[n]=kd();break}case"BlueberryUpgrade1":{this.vals[n]=+e.blueberryUpgrades.ambrosiaLuck1.bonus.ambrosiaLuck;break}case"BlueberryUpgrade2":{this.vals[n]=+e.blueberryUpgrades.ambrosiaLuck2.bonus.ambrosiaLuck;break}case"BlueberryCubeLuck1":{this.vals[n]=+e.blueberryUpgrades.ambrosiaCubeLuck1.bonus.ambrosiaLuck;break}case"BlueberryQuarkLuck1":{this.vals[n]=+e.blueberryUpgrades.ambrosiaQuarkLuck1.bonus.ambrosiaLuck;break}case"OneHundredThirtyOne":{this.vals[n]=e.highestSingularityCount>=131?131:0;break}case"TwoHundredSixtyNine":{this.vals[n]=e.highestSingularityCount>=269?269:0;break}case"ShopOcteractAmbrosiaLuck":{this.vals[n]=e.shopUpgrades.shopOcteractAmbrosiaLuck*(1+Math.floor(Math.log10(e.totalWowOcteracts+1)));break}case"Exalt5":{this.vals[n]=+e.singularityChallenges.noAmbrosiaUpgrades.rewards.additiveLuck;break}}let l=this.vals[n];this.updateTotal(s,l,a),this.usedTotal=Math.floor(this.totalVal*e.caches.ambrosiaLuckAdditiveMult.totalVal)}},Kl=class extends vd{constructor(){super();this.reset()}reset(){this.vals={DefaultVal:1,Blueberries:1,ShopUpgrades:1,SingularityBerries:1,OcteractBerries:1,BlueberryPatreon:1,Exalt2:1,Exalt5:1,CashGrabUltra:1,Event:1},this.totalVal=0}updateVal(n,a=!1){let s=this.vals[n];switch(n){case"DefaultVal":{this.vals[n]=1*+e.visitedAmbrosiaSubtab;break}case"Blueberries":{this.vals[n]=e.caches.blueberryInventory.totalVal;break}case"ShopUpgrades":{this.vals[n]=wd();break}case"SingularityBerries":{this.vals[n]=Md();break}case"OcteractBerries":{this.vals[n]=Sd();break}case"BlueberryPatreon":{this.vals[n]=+e.blueberryUpgrades.ambrosiaPatreon.bonus.blueberryGeneration;break}case"Exalt2":{this.vals[n]=+e.singularityChallenges.oneChallengeCap.rewards.blueberrySpeedMult;break}case"Exalt5":{this.vals[n]=+e.singularityChallenges.noAmbrosiaUpgrades.rewards.blueberrySpeedMult;break}case"Event":{this.vals[n]=o.isEvent?1+Ye(11):1;break}case"CashGrabUltra":{this.vals[n]=ho();break}}let l=this.vals[n];this.updateTotal(s,l,a)}},zl=class extends Jo{constructor(){super();this.reset()}reset(){this.vals={Exalt1:0,SingularityUpgrade:0,SingularityPerk:0,Exalt5:0},this.totalVal=0}updateVal(n,a=!1){let s=this.vals[n];switch(n){case"Exalt1":{this.vals[n]=+(e.singularityChallenges.noSingularityUpgrades.completions>0);break}case"SingularityUpgrade":{this.vals[n]=+e.singularityUpgrades.blueberries.getEffect().bonus;break}case"SingularityPerk":{this.vals[n]=Ld();break}case"Exalt5":this.vals[n]=+e.singularityChallenges.noAmbrosiaUpgrades.rewards.blueberries}let l=this.vals[n];this.updateTotal(s,l,a),e.caches.ambrosiaGeneration.updateVal("Blueberries")}},Xl=()=>{o.ambrosiaCurrStats={ambrosiaAdditiveLuckMult:zr().value,ambrosiaLuck:Ge().value,ambrosiaBlueberries:ha().value,ambrosiaGenerationSpeed:De().value}};var VC=.08,WC=1.2,KC=.15,zC=.125,XC=.125,ZC=.125,H0=()=>{o.totalCoinOwned=e.firstOwnedCoin+e.secondOwnedCoin+e.thirdOwnedCoin+e.fourthOwnedCoin+e.fifthOwnedCoin},F0=()=>{let t=0;e.upgrades[26]>.5&&(t+=1),e.upgrades[31]>.5&&(t+=Math.floor(o.totalCoinOwned/2e3)*100/100),e.achievements[7]>.5&&(t+=Math.floor(e.firstOwnedCoin/2e3)),e.achievements[14]>.5&&(t+=Math.floor(e.secondOwnedCoin/2e3)),e.achievements[21]>.5&&(t+=Math.floor(e.thirdOwnedCoin/2e3)),e.achievements[28]>.5&&(t+=Math.floor(e.fourthOwnedCoin/2e3)),e.achievements[35]>.5&&(t+=Math.floor(e.fifthOwnedCoin/2e3)),t+=e.researches[93]*Math.floor(1/20*(o.rune1level+o.rune2level+o.rune3level+o.rune4level+o.rune5level)),t+=Math.floor((.01+o.rune1level)*o.effectiveLevelMult/20),t*=1+1/5*e.researches[3]*(1+1/2*_("ascension",e.challengecompletions[14])),t*=1+1/20*e.researches[16]+1/20*e.researches[17],t*=1+1/20*e.researches[88],t*=_t(20,(e.antUpgrades[4-1]+o.bonusant4)/1e3*20/19),t*=1+1/100*e.researches[127],t*=1+.8/100*e.researches[142],t*=1+.6/100*e.researches[157],t*=1+.4/100*e.researches[172],t*=1+.2/100*e.researches[187],t*=1+.01/100*e.researches[200],t*=1+.01/100*e.cubeUpgrades[50],t*=1+1/1e3*Ve("acceleratorBoost"),e.upgrades[73]>.5&&e.currentChallenge.reincarnation!==0&&(t*=2),t=Math.min(1e100,Math.floor(t)),o.freeAcceleratorBoost=t,o.totalAcceleratorBoost=Math.floor(e.acceleratorBoostBought+o.freeAcceleratorBoost)*100/100},Q0=()=>{o.acceleratorMultiplier=1,o.acceleratorMultiplier*=1+e.achievements[60]/100,o.acceleratorMultiplier*=1+e.achievements[61]/100,o.acceleratorMultiplier*=1+e.achievements[62]/100,o.acceleratorMultiplier*=1+1/5*e.researches[1]*(1+1/2*_("ascension",e.challengecompletions[14])),o.acceleratorMultiplier*=1+1/20*e.researches[6]+1/25*e.researches[7]+1/40*e.researches[8]+3/200*e.researches[9]+1/200*e.researches[10],o.acceleratorMultiplier*=1+1/20*e.researches[86],o.acceleratorMultiplier*=1+1/100*e.researches[126],o.acceleratorMultiplier*=1+.8/100*e.researches[141],o.acceleratorMultiplier*=1+.6/100*e.researches[156],o.acceleratorMultiplier*=1+.4/100*e.researches[171],o.acceleratorMultiplier*=1+.2/100*e.researches[186],o.acceleratorMultiplier*=1+.01/100*e.researches[200],o.acceleratorMultiplier*=1+.01/100*e.cubeUpgrades[50],o.acceleratorMultiplier*=Math.pow(1.01,e.upgrades[21]+e.upgrades[22]+e.upgrades[23]+e.upgrades[24]+e.upgrades[25]),(e.currentChallenge.transcension!==0||e.currentChallenge.reincarnation!==0)&&e.upgrades[50]>.5&&(o.acceleratorMultiplier*=1.25)},Pu=()=>1/(1-ae([.05*e.achievements[80],.05*e.achievements[87],.05*e.achievements[94],.05*e.achievements[101],.05*e.achievements[108],.05*e.achievements[115],.075*e.achievements[122],.075*e.achievements[129],.05*e.upgrades[61],.25*Math.min(1,o.rune4level/400),.005*e.cubeUpgrades[2]]));function co(t,r=!1,n=e.runelevels[t],a=!1){let s=Pu(),l=null;r?l=ae([1/100*e.highestchallengecompletions[3],1*e.upgrades[66]]):l=ae([1,Math.min(1,e.highestchallengecompletions[1]),.4/10*e.highestchallengecompletions[1],.6*e.researches[22],.3*e.researches[23],2*e.upgrades[61],e.upgrades[71]*n/25]);let c=be([1+e.researches[91]/20,1+e.researches[92]/20,_t(999,1/1e4*Math.pow(e.antUpgrades[8-1]+o.bonusant8,1.1)),o.cubeBonusMultiplier[4],1+e.ascensionCounter/1e3*e.cubeUpgrades[32],1+1/10*e.constantUpgrades[8],o.challenge15Rewards.runeExp]),p=1/Math.pow(o.droughtMultiplier[e.usedCorruptions[8]],1-1/2*e.platonicUpgrades[13]),g=[be([1+e.researches[78]/50,1+e.researches[111]/100,1+_("reincarnation",e.challengecompletions[7])/10,p]),be([1+e.researches[80]/50,1+e.researches[112]/100,1+_("reincarnation",e.challengecompletions[7])/10,p]),be([1+e.researches[79]/50,1+e.researches[113]/100,1+_("reincarnation",e.challengecompletions[8])/5,p]),be([1+e.researches[77]/50,1+e.researches[114]/100,1+_("reincarnation",e.challengecompletions[6])/10,p]),be([1+e.researches[83]/20,1+e.researches[115]/100,1+_("reincarnation",e.challengecompletions[9])/5,p]),be([1]),be([1])],m=[l,c,s,g[t]];return a?m:Math.min(1e200,be(m))}var YC=t=>be([Math.pow((t+1)/2,3),(3.5*t+100)/500,Math.max(1,(t-200)/9),Math.max(1,(t-400)/12),Math.max(1,(t-600)/15),Math.max(1,Math.pow(1.03,(t-800)/4))]),Zl=null,on=(t,r=e.runelevels[t])=>{Zl!=null||(Zl=Array.from({length:4e4+1},(a,s)=>YC(s)));let n=Zl[r];return t===5&&(n=Math.pow(100,r)),t===6&&(n=Math.pow(1e25,r)*(e.highestSingularityCount+1)),n*o.runeexpbase[t]},rt=t=>{let r=1e3,n=20*(e.cubeUpgrades[16]+e.cubeUpgrades[37])+3*e.constantUpgrades[7]+80*_("ascension",e.challengecompletions[11])+200*_("ascension",e.challengecompletions[14])+Math.floor(.04*e.researches[200]+.04*e.cubeUpgrades[50]),a=[null,10*(e.researches[78]+e.researches[111])+n,10*(e.researches[80]+e.researches[112])+n,10*(e.researches[79]+e.researches[113])+n,10*(e.researches[77]+e.researches[114])+n,10*e.researches[115]+n,-901,-999];return r=a[t]>o.runeMaxLvl?o.runeMaxLvl:r+a[t],r},Qn=()=>{let t=xe.INSTANT_UNLOCK_2?6:0;t+=e.cubeUpgrades[73];let r=e.runelevels[5]+t;return r+Math.max(0,r-74)+Math.max(0,r-98)};function Qr(t,r=!0,n=!1){if(t==="acceleratorBoost"||t==="ascension"||t==="ascensionChallenge")return 0;let a=0,s=0,l=0,c=0;(t==="reincarnation"||t==="reincarnationChallenge")&&(s+=3,e.achievements[52]>.5&&(s+=25*Math.min(e.reincarnationcounter/1800,1)),e.upgrades[62]>.5&&(s+=1/50*ae(e.challengecompletions)),s+=.6*e.researches[25],e.researches[95]===1&&(s+=4),s+=1/200*o.rune5level*o.effectiveLevelMult*(1+e.researches[85]/200),s*=1+Math.pow(f.log(e.reincarnationShards.add(1),10),2/3)/4,s*=Math.min(Math.pow(e.reincarnationcounter/10+1,2),1),e.reincarnationcounter>=5&&(s*=Math.max(1,e.reincarnationcounter/10))),(t==="transcension"||t==="transcensionChallenge"||t==="reincarnation"||t==="reincarnationChallenge")&&(l+=2,e.reincarnationCount>0&&(l+=2),e.achievements[44]>.5&&(l+=15*Math.min(e.transcendcounter/1800,1)),e.challengecompletions[2]>0&&(l+=1),l+=.2*e.researches[24],l+=1/200*o.rune5level*o.effectiveLevelMult*(1+e.researches[85]/200),l*=1+Math.pow(f.log(e.transcendShards.add(1),10),1/2)/5,l*=1+_("reincarnation",e.challengecompletions[8])/25,l*=Math.min(Math.pow(e.transcendcounter/10,2),1),e.transcendCount>=5&&(l*=Math.max(1,e.transcendcounter/10))),c+=1,(e.transcendCount>0||e.reincarnationCount>0)&&(c+=1),e.reincarnationCount>0&&(c+=2),e.achievements[37]>.5&&(c+=15*Math.min(e.prestigecounter/1800,1)),e.challengecompletions[2]>0&&(c+=1),c+=.2*e.researches[24],c+=1/200*o.rune5level*o.effectiveLevelMult*(1+e.researches[85]/200),c*=1+Math.pow(f.log(e.prestigeShards.add(1),10),1/2)/5,c*=1+_("reincarnation",e.challengecompletions[6])/50,c*=Math.min(Math.pow(e.prestigecounter/10,2),1),e.prestigeCount>=5&&(c*=Math.max(1,e.prestigecounter/10)),a=s+l+c;let p=[1+10*e.achievements[33]/100,1+15*e.achievements[34]/100,1+25*e.achievements[35]/100,1+20*e.upgrades[38]/100,1+e.upgrades[75]*2*Math.min(1,Math.pow(e.maxobtainium/3e7,.5)),1+1/50*e.shopUpgrades.offeringAuto,1+1/25*e.shopUpgrades.offeringEX,1+1/100*e.shopUpgrades.cashGrab,1+1/1e4*ae(e.challengecompletions)*e.researches[85],1+Math.pow(e.antUpgrades[6-1]+o.bonusant6,.66),o.cubeBonusMultiplier[3],1+.02*e.constantUpgrades[3],1+3e-4*e.talismanLevels[3-1]*e.researches[149]+4e-4*e.talismanLevels[3-1]*e.researches[179],1+.12*_("ascension",e.challengecompletions[12]),1+.01/100*e.researches[200],1+Math.min(1,e.ascensionCount/1e6)*e.achievements[187],1+.6*e.achievements[250]+1*e.achievements[251],1+.05*e.cubeUpgrades[46],1+.02/100*e.cubeUpgrades[50],1+e.platonicUpgrades[5],1+2.5*e.platonicUpgrades[10],1+5*e.platonicUpgrades[15],o.challenge15Rewards.offering,1+5*(e.singularityUpgrades.starterPack.getEffect().bonus?1:0),+e.singularityUpgrades.singOfferings1.getEffect().bonus,+e.singularityUpgrades.singOfferings2.getEffect().bonus,+e.singularityUpgrades.singOfferings3.getEffect().bonus,+e.singularityUpgrades.singCitadel.getEffect().bonus,+e.singularityUpgrades.singCitadel2.getEffect().bonus,1+e.cubeUpgrades[54]/100,+e.octeractUpgrades.octeractOfferings1.getEffect().bonus,1+.001*+e.blueberryUpgrades.ambrosiaOffering1.bonus.offeringMult,Math.pow(1.04,e.cubeUpgrades[72]*ae(e.talismanRarity)),So(),n2(),1+Ye(8)];if(r)a*=be(p);else return p;if(n)return be(p);if(o.eventClicked&&o.isEvent&&(a*=1.05),a/=Le("Offering"),e.currentChallenge.ascension===15&&(a*=1+7*e.cubeUpgrades[62]),a*=1+1/200*e.shopUpgrades.cashGrab2,a*=1+1/100*e.shopUpgrades.offeringEX2*e.singularityCount,a*=Math.pow(1.02,e.shopUpgrades.offeringEX3),a*=Au(),e.singularityChallenges.limitedTime.enabled){let m=e.singularityChallenges.limitedTime.completions,h=e.singChallengeTimer;a*=Ud(m,h)}a=Math.min(1e300,a);let g=0;return t==="prestige"&&(g=a/(1+e.prestigecounter)),(t==="transcension"||t==="transcensionChallenge")&&(g=a/(1+e.transcendcounter)),(t==="reincarnation"||t==="reincarnationChallenge")&&(g=a/(1+e.reincarnationcounter)),g>e.offeringpersecond&&(e.offeringpersecond=g),a}var Or=()=>{if(o.obtainiumGain=1,e.upgrades[69]>0&&(o.obtainiumGain*=Math.min(10,new f(f.pow(f.log(o.reincarnationPointGain.add(10),10),.5)).toNumber())),e.upgrades[72]>0&&(o.obtainiumGain*=Math.min(50,1+2*e.challengecompletions[6]+2*e.challengecompletions[7]+2*e.challengecompletions[8]+2*e.challengecompletions[9]+2*e.challengecompletions[10])),e.upgrades[74]>0&&(o.obtainiumGain*=1+4*Math.min(1,Math.pow(e.maxofferings/1e5,.5))),o.obtainiumGain*=1+e.researches[65]/5,o.obtainiumGain*=1+e.researches[76]/10,o.obtainiumGain*=1+e.researches[81]/10,o.obtainiumGain*=1+e.shopUpgrades.obtainiumAuto/50,o.obtainiumGain*=1+e.shopUpgrades.cashGrab/100,o.obtainiumGain*=1+1/25*e.shopUpgrades.obtainiumEX,o.obtainiumGain*=1+o.rune5level/200*o.effectiveLevelMult*(1+e.researches[84]/200*(1+1*o.effectiveRuneSpiritPower[5]*Xe()/400)),o.obtainiumGain*=1+.01*e.achievements[84]+.03*e.achievements[91]+.05*e.achievements[98]+.07*e.achievements[105]+.09*e.achievements[112]+.11*e.achievements[119]+.13*e.achievements[126]+.15*e.achievements[133]+.17*e.achievements[140]+.19*e.achievements[147],o.obtainiumGain*=1+2*Math.pow((e.antUpgrades[10-1]+o.bonusant10)/50,2/3),o.obtainiumGain*=1+e.achievements[188]*Math.min(2,e.ascensionCount/5e6),o.obtainiumGain*=1+.6*e.achievements[250]+1*e.achievements[251],o.obtainiumGain*=o.cubeBonusMultiplier[5],o.obtainiumGain*=1+.04*e.constantUpgrades[4],o.obtainiumGain*=1+.1*e.cubeUpgrades[47],o.obtainiumGain*=1+.1*e.cubeUpgrades[3],o.obtainiumGain*=1+.5*_("ascension",e.challengecompletions[12]),o.obtainiumGain*=1+Xe()/400*o.effectiveRuneSpiritPower[4],o.obtainiumGain*=1+.03*Math.log(e.uncommonFragments+1)/Math.log(4)*e.researches[144],o.obtainiumGain*=1+.02/100*e.cubeUpgrades[50],e.achievements[53]>0&&(o.obtainiumGain*=1+1/800*o.runeSum),e.achievements[128]&&(o.obtainiumGain*=1.5),e.achievements[129]&&(o.obtainiumGain*=1.25),e.achievements[51]>0&&(o.obtainiumGain+=4),e.reincarnationcounter>=2&&(o.obtainiumGain+=1*e.researches[63]),e.reincarnationcounter>=5&&(o.obtainiumGain+=2*e.researches[64]),o.obtainiumGain*=Math.min(1,Math.pow(e.reincarnationcounter/10,2)),e.reincarnationCount>=5&&(o.obtainiumGain*=Math.max(1,e.reincarnationcounter/10)),o.obtainiumGain*=Math.pow(f.log(e.transcendShards.add(1),10)/300,2),o.obtainiumGain=Math.pow(o.obtainiumGain,Math.min(1,o.illiteracyPower[e.usedCorruptions[5]]*(1+9/100*e.platonicUpgrades[9]*Math.min(100,Math.log10(e.researchPoints+10))))),o.obtainiumGain*=1+4/100*e.cubeUpgrades[42],o.obtainiumGain*=1+3/100*e.cubeUpgrades[43],o.obtainiumGain*=1+e.platonicUpgrades[5],o.obtainiumGain*=1+1.5*e.platonicUpgrades[9],o.obtainiumGain*=1+2.5*e.platonicUpgrades[10],o.obtainiumGain*=1+5*e.platonicUpgrades[15],o.obtainiumGain*=o.challenge15Rewards.obtainium,o.obtainiumGain*=1+5*(e.singularityUpgrades.starterPack.getEffect().bonus?1:0),o.obtainiumGain*=+e.singularityUpgrades.singObtainium1.getEffect().bonus,o.obtainiumGain*=+e.singularityUpgrades.singObtainium2.getEffect().bonus,o.obtainiumGain*=+e.singularityUpgrades.singObtainium3.getEffect().bonus,o.obtainiumGain*=1+e.cubeUpgrades[55]/100,o.obtainiumGain*=1+1/200*e.shopUpgrades.cashGrab2,o.obtainiumGain*=1+1/100*e.shopUpgrades.obtainiumEX2*e.singularityCount,o.obtainiumGain*=1+Ye(9),o.obtainiumGain*=+e.singularityUpgrades.singCitadel.getEffect().bonus,o.obtainiumGain*=+e.singularityUpgrades.singCitadel2.getEffect().bonus,o.obtainiumGain*=+e.octeractUpgrades.octeractObtainium1.getEffect().bonus,o.obtainiumGain*=Math.pow(1.02,e.shopUpgrades.obtainiumEX3),o.obtainiumGain*=Mo(),o.eventClicked&&o.isEvent&&(o.obtainiumGain*=1.05),e.currentChallenge.ascension===15&&(o.obtainiumGain+=1,o.obtainiumGain*=1+7*e.cubeUpgrades[62]),o.obtainiumGain*=1+.001*+e.blueberryUpgrades.ambrosiaObtainium1.bonus.obtainiumMult,o.obtainiumGain*=ku(),o.obtainiumGain*=So(),e.singularityChallenges.limitedTime.enabled){let t=e.singularityChallenges.limitedTime.completions,r=e.singChallengeTimer;o.obtainiumGain*=Ud(t,r)}o.obtainiumGain*=Math.pow(1.04,e.cubeUpgrades[71]*ae(e.talismanRarity)),isFinite(o.obtainiumGain)||(o.obtainiumGain=1e300),o.obtainiumGain=Math.min(1e300,o.obtainiumGain),o.obtainiumGain/=Le("Obtainium"),e.usedCorruptions[5]>=15&&(o.obtainiumGain=Math.pow(o.obtainiumGain,1/4)),e.usedCorruptions[5]>=16&&(o.obtainiumGain=Math.pow(o.obtainiumGain,1/3)),o.obtainiumGain=Math.max(1+e.singularityCount,o.obtainiumGain),e.currentChallenge.ascension===14&&(o.obtainiumGain=0),e.obtainiumpersecond=Math.min(1e300,o.obtainiumGain)/(.1+e.reincarnationcounter),e.maxobtainiumpersecond=Math.max(e.maxobtainiumpersecond,e.obtainiumpersecond)},Eo=()=>.05*(10*e.researches[61]+2*e.researches[62])*e.maxobtainiumpersecond*(1+4*e.cubeUpgrades[3]/5),Iu=()=>{let t=0,r=0;if(e.achievements[135]===1&&(t+=.02),e.achievements[136]===1&&(t+=.02),t+=.02*(e.talismanRarity[4-1]-1),t+=3*e.researches[106]/100,t+=3*e.researches[107]/100,t+=3*e.researches[116]/200,t+=3*e.researches[117]/200,t+=o.cubeBonusMultiplier[9]-1,t+=4e-4*e.cubeUpgrades[50],r+=.06*e.researches[118],r+=4e-4*e.cubeUpgrades[50],e.highestSingularityCount>=7&&(t+=r,r=t),e.highestSingularityCount<7)for(let s=1;s<=5;s++)e.talismanOne[s]===1?o.talisman1Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[1-1]]+t)*e.talismanLevels[1-1]*o.challenge15Rewards.talismanBonus:o.talisman1Effect[s]=(o.talismanNegativeModifier[e.talismanRarity[1-1]]-r)*e.talismanLevels[1-1]*-1*o.challenge15Rewards.talismanBonus,e.talismanTwo[s]===1?o.talisman2Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[2-1]]+t)*e.talismanLevels[2-1]*o.challenge15Rewards.talismanBonus:o.talisman2Effect[s]=(o.talismanNegativeModifier[e.talismanRarity[2-1]]-r)*e.talismanLevels[2-1]*-1*o.challenge15Rewards.talismanBonus,e.talismanThree[s]===1?o.talisman3Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[3-1]]+t)*e.talismanLevels[3-1]*o.challenge15Rewards.talismanBonus:o.talisman3Effect[s]=(o.talismanNegativeModifier[e.talismanRarity[3-1]]-r)*e.talismanLevels[3-1]*-1*o.challenge15Rewards.talismanBonus,e.talismanFour[s]===1?o.talisman4Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[4-1]]+t)*e.talismanLevels[4-1]*o.challenge15Rewards.talismanBonus:o.talisman4Effect[s]=(o.talismanNegativeModifier[e.talismanRarity[4-1]]-r)*e.talismanLevels[4-1]*-1*o.challenge15Rewards.talismanBonus,e.talismanFive[s]===1?o.talisman5Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[5-1]]+t)*e.talismanLevels[5-1]*o.challenge15Rewards.talismanBonus:o.talisman5Effect[s]=(o.talismanNegativeModifier[e.talismanRarity[5-1]]-r)*e.talismanLevels[5-1]*-1*o.challenge15Rewards.talismanBonus,e.talismanSix[s]===1?o.talisman6Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[6-1]]+t)*e.talismanLevels[6-1]*o.challenge15Rewards.talismanBonus:o.talisman6Effect[s]=(o.talismanNegativeModifier[e.talismanRarity[6-1]]-r)*e.talismanLevels[6-1]*-1*o.challenge15Rewards.talismanBonus,e.talismanSeven[s]===1?o.talisman7Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[7-1]]+t)*e.talismanLevels[7-1]*o.challenge15Rewards.talismanBonus:o.talisman7Effect[s]=(o.talismanNegativeModifier[e.talismanRarity[7-1]]-r)*e.talismanLevels[7-1]*-1*o.challenge15Rewards.talismanBonus;else for(let s=1;s<=5;s++)o.talisman1Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[1-1]]+t)*e.talismanLevels[1-1]*o.challenge15Rewards.talismanBonus,o.talisman2Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[2-1]]+t)*e.talismanLevels[2-1]*o.challenge15Rewards.talismanBonus,o.talisman3Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[3-1]]+t)*e.talismanLevels[3-1]*o.challenge15Rewards.talismanBonus,o.talisman4Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[4-1]]+t)*e.talismanLevels[4-1]*o.challenge15Rewards.talismanBonus,o.talisman5Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[5-1]]+t)*e.talismanLevels[5-1]*o.challenge15Rewards.talismanBonus,o.talisman6Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[6-1]]+t)*e.talismanLevels[6-1]*o.challenge15Rewards.talismanBonus,o.talisman7Effect[s]=(o.talismanPositiveModifier[e.talismanRarity[7-1]]+t)*e.talismanLevels[7-1]*o.challenge15Rewards.talismanBonus;let n=[o.talisman1Effect,o.talisman2Effect,o.talisman3Effect,o.talisman4Effect,o.talisman5Effect,o.talisman6Effect,o.talisman7Effect],a=[0,0,0,0,0,0];n.forEach(s=>{s.forEach((l,c)=>{a[c]+=l})}),[,o.rune1Talisman,o.rune2Talisman,o.rune3Talisman,o.rune4Talisman,o.rune5Talisman]=a,o.talisman6Power=0,o.talisman7Quarks=0,e.talismanRarity[1-1]===6&&(o.rune2Talisman+=400),e.talismanRarity[2-1]===6&&(o.rune1Talisman+=400),e.talismanRarity[3-1]===6&&(o.rune4Talisman+=400),e.talismanRarity[4-1]===6&&(o.rune3Talisman+=400),e.talismanRarity[5-1]===6&&(o.rune5Talisman+=400),e.talismanRarity[6-1]===6&&(o.talisman6Power=2.5),e.talismanRarity[7-1]===6&&(o.talisman7Quarks=2)},He=()=>{var t;if(Iu(),e.currentChallenge.reincarnation!==9){let r=(t=e.antUpgrades[8])!=null?t:0;o.rune1level=Math.max(1,e.runelevels[0]+Math.min(1e7,r+o.bonusant9)*1+o.rune1Talisman+7*e.constantUpgrades[7]),o.rune2level=Math.max(1,e.runelevels[1]+Math.min(1e7,r+o.bonusant9)*1+o.rune2Talisman+7*e.constantUpgrades[7]),o.rune3level=Math.max(1,e.runelevels[2]+Math.min(1e7,r+o.bonusant9)*1+o.rune3Talisman+7*e.constantUpgrades[7]),o.rune4level=Math.max(1,e.runelevels[3]+Math.min(1e7,r+o.bonusant9)*1+o.rune4Talisman+7*e.constantUpgrades[7]),o.rune5level=Math.max(1,e.runelevels[4]+Math.min(1e7,r+o.bonusant9)*1+o.rune5Talisman+7*e.constantUpgrades[7])}o.runeSum=ae([o.rune1level,o.rune2level,o.rune3level,o.rune4level,o.rune5level]),_u()},_u=()=>{o.blessingMultiplier=1,o.spiritMultiplier=1,o.blessingMultiplier*=1+6.9*e.researches[134]/100,o.blessingMultiplier*=1+(e.talismanRarity[3-1]-1)/10,o.blessingMultiplier*=1+.1*Math.log10(e.epicFragments+1)*e.researches[174],o.blessingMultiplier*=1+2*e.researches[194]/100,e.researches[160]>0&&(o.blessingMultiplier*=Math.pow(1.25,8)),o.spiritMultiplier*=1+8*e.researches[164]/100,e.researches[165]>0&&e.currentChallenge.ascension!==0&&(o.spiritMultiplier*=Math.pow(2,8)),o.spiritMultiplier*=1+.15*Math.log10(e.legendaryFragments+1)*e.researches[189],o.spiritMultiplier*=1+2*e.researches[194]/100,o.spiritMultiplier*=1+(e.talismanRarity[5-1]-1)/100;for(let t=1;t<=5;t++)o.runeBlessings[t]=o.blessingMultiplier*e.runelevels[t-1]*e.runeBlessingLevels[t],o.runeSpirits[t]=o.spiritMultiplier*e.runelevels[t-1]*e.runeSpiritLevels[t];for(let t=1;t<=5;t++)o.runeBlessings[t]<=1e30?o.effectiveRuneBlessingPower[t]=Math.pow(o.runeBlessings[t],1/8)/75*o.challenge15Rewards.blessingBonus:o.runeBlessings[t]>1e30&&(o.effectiveRuneBlessingPower[t]=Math.pow(10,5/2)*Math.pow(o.runeBlessings[t],1/24)/75*o.challenge15Rewards.blessingBonus),o.runeSpirits[t]<=1e25?o.effectiveRuneSpiritPower[t]=Math.pow(o.runeSpirits[t],1/8)/75*o.challenge15Rewards.spiritBonus:o.runeSpirits[t]>1e25&&(o.effectiveRuneSpiritPower[t]=Math.pow(10,25/12)*Math.pow(o.runeSpirits[t],1/24)/75*o.challenge15Rewards.spiritBonus)},It=()=>{let t=0;t+=2*(e.talismanRarity[6-1]-1),t+=_("reincarnation",e.challengecompletions[9]),t+=2*e.constantUpgrades[6],t+=12*_("ascension",e.challengecompletions[11]),t+=Math.floor(1/200*e.researches[200]),t*=o.challenge15Rewards.bonusAntLevel;let r=0,n=0;e.currentChallenge.ascension===11&&(r=999),e.currentChallenge.ascension===11&&(n=Math.floor((4*e.challengecompletions[8]+23*e.challengecompletions[9])*Math.max(0,1-e.challengecompletions[11]/10))),o.bonusant1=Math.min(e.antUpgrades[1-1]+r,4*e.researches[97]+t+e.researches[102]+2*e.researches[132]+n),o.bonusant2=Math.min(e.antUpgrades[2-1]+r,4*e.researches[97]+t+e.researches[102]+2*e.researches[132]+n),o.bonusant3=Math.min(e.antUpgrades[3-1]+r,4*e.researches[97]+t+e.researches[102]+2*e.researches[132]+n),o.bonusant4=Math.min(e.antUpgrades[4-1]+r,4*e.researches[97]+t+e.researches[102]+2*e.researches[132]+n),o.bonusant5=Math.min(e.antUpgrades[5-1]+r,4*e.researches[97]+t+e.researches[102]+2*e.researches[132]+n),o.bonusant6=Math.min(e.antUpgrades[6-1]+r,4*e.researches[97]+t+e.researches[102]+2*e.researches[132]+n),o.bonusant7=Math.min(e.antUpgrades[7-1]+r,4*e.researches[98]+t+e.researches[102]+2*e.researches[132]+n),o.bonusant8=Math.min(e.antUpgrades[8-1]+r,4*e.researches[98]+t+e.researches[102]+2*e.researches[132]+n),o.bonusant9=Math.min(e.antUpgrades[9-1]+r,4*e.researches[98]+t+e.researches[102]+2*e.researches[132]+n),o.bonusant10=Math.min(e.antUpgrades[10-1]+r,4*e.researches[98]+t+e.researches[102]+2*e.researches[132]+n),o.bonusant11=Math.min(e.antUpgrades[11-1]+r,4*e.researches[98]+t+e.researches[102]+2*e.researches[132]+n),o.bonusant12=Math.min(e.antUpgrades[12-1]+r,4*e.researches[98]+t+e.researches[102]+2*e.researches[132]+n)},ea=()=>{o.antELO=0,o.effectiveELO=0;let t=ae(e.antUpgrades);e.antPoints.gte("1e40")&&(o.antELO+=f.log(e.antPoints,10),o.antELO+=1/2*t,o.antELO+=1/10*e.firstOwnedAnts,o.antELO+=1/5*e.secondOwnedAnts,o.antELO+=1/3*e.thirdOwnedAnts,o.antELO+=1/2*e.fourthOwnedAnts,o.antELO+=e.fifthOwnedAnts,o.antELO+=2*e.sixthOwnedAnts,o.antELO+=4*e.seventhOwnedAnts,o.antELO+=8*e.eighthOwnedAnts,o.antELO+=666*e.researches[178],o.antELO*=1+.01*e.achievements[180]+.02*e.achievements[181]+.03*e.achievements[182],o.antELO*=1+e.researches[110]/100,o.antELO*=1+2.5*e.researches[148]/100,e.achievements[176]===1&&(o.antELO+=25),e.achievements[177]===1&&(o.antELO+=50),e.achievements[178]===1&&(o.antELO+=75),e.achievements[179]===1&&(o.antELO+=100),o.antELO+=25*e.researches[108],o.antELO+=25*e.researches[109],o.antELO+=40*e.researches[123],o.antELO+=100*_("reincarnation",e.challengecompletions[10]),o.antELO+=75*e.upgrades[80],o.antELO=1/10*Math.floor(10*o.antELO),o.effectiveELO+=.5*Math.min(3500,o.antELO),o.effectiveELO+=.1*Math.min(4e3,o.antELO),o.effectiveELO+=.1*Math.min(6e3,o.antELO),o.effectiveELO+=.1*Math.min(1e4,o.antELO),o.effectiveELO+=.2*o.antELO,o.effectiveELO+=o.cubeBonusMultiplier[8]-1,o.effectiveELO+=1*e.cubeUpgrades[50],o.effectiveELO*=1+.03*e.upgrades[124])},JC=()=>{o.timeMultiplier=Math.min(1,Math.pow(e.antSacrificeTimer/10,2)),e.achievements[177]===0&&(o.timeMultiplier*=Math.min(1e3,Math.max(1,e.antSacrificeTimer/10))),e.achievements[177]>0&&(o.timeMultiplier*=Math.max(1,e.antSacrificeTimer/10)),o.upgradeMultiplier=1,o.upgradeMultiplier*=1+2*(1-Math.pow(2,-(e.antUpgrades[11-1]+o.bonusant11)/125)),o.upgradeMultiplier*=1+e.researches[103]/20,o.upgradeMultiplier*=1+e.researches[104]/20,e.achievements[132]===1&&(o.upgradeMultiplier*=1.25),e.achievements[137]===1&&(o.upgradeMultiplier*=1.25),o.upgradeMultiplier*=1+20/3*o.effectiveRuneBlessingPower[3],o.upgradeMultiplier*=1+1/50*_("reincarnation",e.challengecompletions[10]),o.upgradeMultiplier*=1+1/50*e.researches[122],o.upgradeMultiplier*=1+3/100*e.researches[133],o.upgradeMultiplier*=1+2/100*e.researches[163],o.upgradeMultiplier*=1+1/100*e.researches[193],o.upgradeMultiplier*=1+1/10*e.upgrades[79],o.upgradeMultiplier*=1+1/4*e.upgrades[40],o.upgradeMultiplier*=o.cubeBonusMultiplier[7],o.upgradeMultiplier*=1+Ye(7),o.upgradeMultiplier=Math.min(1e300,o.upgradeMultiplier)},ad=()=>{ea(),JC();let t=1e300,r=Math.min(t,o.timeMultiplier*o.upgradeMultiplier);return{antSacrificePoints:o.effectiveELO*r/85,offerings:Math.min(t,e.offeringpersecond*.15*o.effectiveELO*r/180),obtainium:Math.min(t,e.maxobtainiumpersecond*.24*o.effectiveELO*r/180),talismanShards:o.antELO>500?Math.min(t,Math.max(1,Math.floor(r/210*Math.pow(1/4*Math.max(0,o.effectiveELO-500),2)))):0,commonFragments:o.antELO>750?Math.min(t,Math.max(1,Math.floor(r/110*Math.pow(1/9*Math.max(0,o.effectiveELO-750),1.83)))):0,uncommonFragments:o.antELO>1e3?Math.min(t,Math.max(1,Math.floor(r/170*Math.pow(1/16*Math.max(0,o.effectiveELO-1e3),1.66)))):0,rareFragments:o.antELO>1500?Math.min(t,Math.max(1,Math.floor(r/200*Math.pow(1/25*Math.max(0,o.effectiveELO-1500),1.5)))):0,epicFragments:o.antELO>2e3?Math.min(t,Math.max(1,Math.floor(r/200*Math.pow(1/36*Math.max(0,o.effectiveELO-2e3),1.33)))):0,legendaryFragments:o.antELO>3e3?Math.min(t,Math.max(1,Math.floor(r/230*Math.pow(1/49*Math.max(0,o.effectiveELO-3e3),1.16)))):0,mythicalFragments:o.antELO>5e3?Math.min(t,Math.max(1,Math.floor(r/220*Math.pow(1/64*Math.max(0,o.effectiveELO-4150),1)))):0}},q0=async()=>{let t=await Ee(u.t("calculate.timePrompt")),r=Number(t);if(Number.isNaN(r)||r<=0)return P(u.t("calculate.timePromptError"));i("offlineContainer").style.display="flex",i("offlineBlur").style.display="",Ad(r)},Ad=async(t=0)=>{El(),o.timeWarp=!0;let r=(86400*3+7200*2*e.researches[31]+7200*2*e.researches[32])*xe.OFFLINE_TIMER_CAP_BUFF,n=Date.now(),a=Math.min(r,Math.max(t,(n-e.offlinetick)/1e3)),s=a/200,l=200;i("offlineTimer").textContent=u.t("calculate.offlineTimer",{value:d(a,0)}),Ms(e.buyTalismanShardPercent),Zt();let c=e.offlinetick>0;e.offlinetick=e.offlinetick<15e11?Date.now():e.offlinetick,o.timeMultiplier=qe().mult,Or();let p=Eo(),g={prestige:a/Math.max(.01,e.fastestprestige),offering:Math.floor(a),transcension:a/Math.max(.01,e.fastesttranscend),reincarnation:a/Math.max(.01,e.fastestreincarnate),obtainium:a*p*o.timeMultiplier},m={prestige:a*o.timeMultiplier,transcension:a*o.timeMultiplier,reincarnation:a*o.timeMultiplier,ants:a*o.timeMultiplier,antsReal:a,ascension:e.ascensionCounter,quarks:Rt().gain};Xl(),Ie("ascension",a),Ie("quarks",a),Ie("goldenQuarks",a),Ie("singularity",a),Ie("octeracts",s),Ie("ambrosia",a),e.prestigeCount+=g.prestige,e.transcendCount+=g.transcension,e.reincarnationCount+=g.reincarnation,m.ascension=e.ascensionCounter-m.ascension,m.quarks=Rt().gain-m.quarks;let h=$t(()=>{o.timeMultiplier=qe().mult,Or(),Ie("prestige",s),Ie("transcension",s),Ie("reincarnation",s),Ie("octeracts",s),Rd(s*o.timeMultiplier),e.researches[61]>0&&e.currentChallenge.ascension!==14&&Br("addObtainium",s),e.achievements[173]>0&&Br("antSacrifice",s),Br("addOfferings",s),e.shopUpgrades.offeringAuto>0&&e.autoSacrificeToggle&&Br("runeSacrifice",s),l%5===1&&Io(),l-=1,l<1&&(_a(h),o.timeWarp=!1)},0);if(i("offlinePrestigeCountNumber").textContent=d(g.prestige,0,!0),i("offlinePrestigeTimer").innerHTML=u.t("offlineProgress.currentPrestigeTimer",{value:d(m.prestige,2,!1)}),i("offlineOfferingCount").innerHTML=u.t("offlineProgress.offeringsGenerated",{value:d(g.offering,0,!0)}),i("offlineTranscensionCount").innerHTML=u.t("offlineProgress.transcensionCount",{value:d(g.transcension,0,!0)}),i("offlineTranscensionTimer").innerHTML=u.t("offlineProgress.currentTranscensionCounter",{value:d(m.transcension,2,!1)}),i("offlineReincarnationCount").innerHTML=u.t("offlineProgress.reincarnationCount",{value:d(g.reincarnation,0,!0)}),i("offlineReincarnationTimer").innerHTML=u.t("offlineProgress.currentReincarnationTimer",{value:d(m.reincarnation,2,!1)}),i("offlineObtainiumCount").innerHTML=u.t("offlineProgress.obtainiumGenerated",{value:d(g.obtainium,0,!0)}),i("offlineAntTimer").innerHTML=u.t("offlineProgress.ingameAntSacTimer",{value:d(m.ants,2,!1)}),i("offlineRealAntTimer").innerHTML=u.t("offlineProgress.realAntSacTimer",{value:d(m.antsReal,2,!0)}),i("offlineAscensionTimer").innerHTML=u.t("offlineProgress.currentAscensionTimer",{value:d(m.ascension,2,!0)}),i("offlineQuarkCount").innerHTML=u.t("offlineProgress.exportQuarks",{value:d(m.quarks,0,!0)}),i("progressbardescription").textContent=u.t("calculate.offlineEarnings"),e.offlinetick=n,!e.loadedNov13Vers){if(e.challengecompletions[14]>0||e.highestchallengecompletions[14]>0){let b=e.ascensionCount;Pe("ascensionChallenge"),e.ascensionCount=b+1}e.loadedNov13Vers=!0}if(vr(),Zt(),Or(),It(),He(),c){let b=i("notification");b.classList.add("slide-out"),b.classList.remove("slide-in"),document.body.classList.remove("scrollbar"),document.body.classList.add("loading"),i("exitOffline").style.visibility="hidden",i("offlineContainer").style.display="flex",i("transparentBG").style.display="block"}else Qs()},Qs=()=>{document.body.classList.remove("loading"),document.body.classList.add("scrollbar"),i("transparentBG").style.display="none",i("offlineContainer").style.display="none",i("offlineBlur").style.display="none",Do()},pt=(t,r,n)=>1+(t-1)*(1-Math.pow(2,-r/n)),_t=(t,r)=>1+(t-1)*(1-Math.exp(-r)),Qt=()=>{let t=[e.cubeBlessings.accelerator,e.cubeBlessings.multiplier,e.cubeBlessings.offering,e.cubeBlessings.runeExp,e.cubeBlessings.obtainium,e.cubeBlessings.antSpeed,e.cubeBlessings.antSacrifice,e.cubeBlessings.antELO,e.cubeBlessings.talismanBonus,e.cubeBlessings.globalSpeed],r=[e.cubeUpgrades[45]/100,e.cubeUpgrades[35]/100,e.cubeUpgrades[24]/100,e.cubeUpgrades[14]/100,e.cubeUpgrades[40]/100,e.cubeUpgrades[22]/40,e.cubeUpgrades[15]/100,e.cubeUpgrades[25]/100,e.cubeUpgrades[44]/100,e.cubeUpgrades[34]/100];for(let n=1;n<=10;n++){let a=1,s=1;t[n-1]>=1e3&&(a=o.blessingDRPower[n],s*=Math.pow(1e3,(1-o.blessingDRPower[n])*(1+r[n-1]))),n===6&&(a=2.25,s=1),o.cubeBonusMultiplier[n]=Math.min(1e300,1+s*o.blessingbase[n]*Math.pow(t[n-1],a*(1+r[n-1]))*o.tesseractBonusMultiplier[n])}He(),ea(),Or()},Oo=()=>{if(e.singularityChallenges.noOcteracts.enabled)return 1;if(e.totalWowOcteracts<1e3){let t=1+.002*e.totalWowOcteracts;return t>1.00001?t:1}else{let t=2+ +e.singularityChallenges.noOcteracts.rewards.octeractPow;return 3*Math.pow(Math.log10(e.totalWowOcteracts)-2,t)}},fn=()=>{if(e.singularityChallenges.noOcteracts.enabled)return 1;if(e.totalWowOcteracts<1e3){let t=1+2e-4*e.totalWowOcteracts;return t>1.00001?t:1}else return 1.1+.1*(Math.log10(e.totalWowOcteracts)-2)},Au=()=>e.singularityChallenges.noOcteracts.rewards.offeringBonus?Math.pow(fn(),1.5):1,Mo=()=>e.singularityChallenges.noOcteracts.rewards.obtainiumBonus?Math.pow(fn(),1.4):1,zn=()=>{let t=1;if(e.singularityChallenges.limitedTime.enabled){let a=e.singularityChallenges.limitedTime.completions,s=e.singChallengeTimer;t=Ud(a,s)}let r=[xe.CUBE_BUFF,Math.pow(Math.min(1,e.ascensionCounter/10),2)*(1+(1/4*e.achievements[204]+1/4*e.achievements[211]+1/2*e.achievements[218])*Math.max(0,e.ascensionCounter/10-1)),1+6/100*e.achievements[250]+10/100*e.achievements[251],1+e.achievements[240]*Math.min(.5,Math.max(.1,1/20*Math.log10(qe().mult+.01))),o.challenge15Rewards.cube1*o.challenge15Rewards.cube2*o.challenge15Rewards.cube3*o.challenge15Rewards.cube4*o.challenge15Rewards.cube5,1+1/100*Qn(),1+e.platonicUpgrades[10],Math.pow(1.01,e.platonicUpgrades[15]*e.challengecompletions[9]),Di(),1+Ye(2),1/Le("Cubes"),1+.75*e.shopUpgrades.seasonPassY/100,1+4*(e.singularityUpgrades.starterPack.getEffect().bonus?1:0),+e.singularityUpgrades.singCubes1.getEffect().bonus,+e.singularityUpgrades.singCubes2.getEffect().bonus,+e.singularityUpgrades.singCubes3.getEffect().bonus,1+e.shopUpgrades.seasonPassZ*e.singularityCount/100,1+1*e.cubeUpgrades[66]*(1-e.platonicUpgrades[15]),1+.25*+o.isEvent*e.cubeUpgrades[58],Oo(),+e.singularityChallenges.noSingularityUpgrades.rewards.cubes,+e.singularityUpgrades.singCitadel.getEffect().bonus,+e.singularityUpgrades.singCitadel2.getEffect().bonus,1+ +e.singularityUpgrades.platonicDelta.getEffect().bonus*Math.min(9,e.shopUpgrades.shopSingularitySpeedup>0?e.singularityCounter*50/(3600*24):e.singularityCounter/(3600*24)),Math.pow(1.02,e.shopUpgrades.seasonPassInfinity),yl(),+e.blueberryUpgrades.ambrosiaTutorial.bonus.cubes,+e.blueberryUpgrades.ambrosiaCubes1.bonus.cubes,+e.blueberryUpgrades.ambrosiaLuckCube1.bonus.cubes,+e.blueberryUpgrades.ambrosiaQuarkCube1.bonus.cubes,+e.blueberryUpgrades.ambrosiaCubes2.bonus.cubes,+e.blueberryUpgrades.ambrosiaHyperflux.bonus.hyperFlux,+So(),+Ki(),+V0(),t],n=o.isEvent&&o.eventClicked?1.05:1;return{mult:be(r)*n,list:r}},ll=(t=-1)=>{t<0&&(t=An().effectiveScore);let r=[Math.pow(t/3e3,1/4.1),zn().mult,1+2.25*e.shopUpgrades.seasonPass/100,(1+e.researches[119]/400)*(1+e.researches[120]/400)*(1+e.researches[137]/100)*(1+.9*e.researches[152]/100)*(1+.8*e.researches[167]/100)*(1+.7*e.researches[182]/100)*(1+.03/100*e.researches[192]*e.antUpgrades[12-1])*(1+.6*e.researches[197]/100),1+.004/100*e.researches[200],(1+e.cubeUpgrades[1]/6)*(1+e.cubeUpgrades[11]/11)*(1+.4*e.cubeUpgrades[30]),1+.01*f.log(e.ascendShards.add(1),4)*Math.min(1,e.constantUpgrades[10]),1+e.achievements[189]*Math.min(2,e.ascensionCount/25e7),1+e.achievements[193]*f.log(e.ascendShards.add(1),10)/400,1+Math.min(250,e.achievements[195]*f.log(e.ascendShards.add(1),10)/400),1+4/100*(e.achievements[198]+e.achievements[199]+e.achievements[200])+3/100*e.achievements[201],1+Math.min(.15,.6/100*Math.log10(t+1))*e.achievements[254],1+Xe()/400*o.effectiveRuneSpiritPower[2],o.platonicBonusMultiplier[0],1+9e-5*ae(e.usedCorruptions)*e.platonicUpgrades[1],1+Math.pow(1.03,Math.log10(Math.max(1,e.wowAbyssals)))*e.cubeUpgrades[63]-e.cubeUpgrades[63]];return{list:r,mult:be(r)}},cl=(t=-1)=>{t<0&&(t=An().effectiveScore);let r=ae(e.usedCorruptions.slice(2,10)),n=[Math.pow(1+Math.max(0,t-1e5)/1e4,.35),zn().mult,1+2.25*e.shopUpgrades.seasonPass/100,1+.01*f.log(e.ascendShards.add(1),4)*Math.min(1,e.constantUpgrades[10]),1+.4*e.cubeUpgrades[30],1+1/200*e.cubeUpgrades[38]*r,1+Math.min(250,e.achievements[195]*f.log(e.ascendShards.add(1),10)/400),1+e.achievements[202]*Math.min(2,e.ascensionCount/5e8),1+4/100*(e.achievements[205]+e.achievements[206]+e.achievements[207])+3/100*e.achievements[208],1+Math.min(.15,.6/100*Math.log10(t+1))*e.achievements[255],o.platonicBonusMultiplier[1],1+18e-5*r*e.platonicUpgrades[2]];return{list:n,mult:be(n)}},ul=(t=-1)=>{t<0&&(t=An().effectiveScore);let r=[Math.pow(1+Math.max(0,t-1e9)/1e8,.5),zn().mult,1+1.5*e.shopUpgrades.seasonPass2/100,1+4/100*(e.achievements[212]+e.achievements[213]+e.achievements[214])+3/100*e.achievements[215],1+e.achievements[216]*Math.min(2,e.ascensionCount/1e9),1+1/10*e.achievements[253],1+Math.min(.15,.6/100*Math.log10(t+1))*e.achievements[256],1+Math.min(2,e.ascensionCount/25e9)*e.achievements[265],o.platonicBonusMultiplier[2],1+54e-5*ae(e.usedCorruptions)*e.platonicUpgrades[3],1+.6/1e3*Ve("hyperrealism")];return{list:r,mult:be(r)}},dl=(t=-1)=>{t<0&&(t=An().effectiveScore);let r=[Math.pow(1+Math.max(0,t-2666e9)/2666e8,.75),zn().mult,1+1.5*e.shopUpgrades.seasonPass2/100,1+Math.min(20,e.achievements[196]*1/5e3*f.log(e.ascendShards.add(1),10)),1+4/100*(e.achievements[219]+e.achievements[220]+e.achievements[221])+3/100*e.achievements[222],1+e.achievements[223]*Math.min(2,e.ascensionCount/1337e6),1+Math.min(.15,.6/100*Math.log10(t+1))*e.achievements[257],o.platonicBonusMultiplier[3],1+1.2*e.platonicUpgrades[4]/50];return{list:r,mult:be(r)}},pl=(t=-1)=>{t<0&&(t=An().effectiveScore);let r=[Math.pow(1+Math.max(0,t-1666e13)/333e14,.85),zn().mult,1+1.5*e.shopUpgrades.seasonPass3/100,1+Math.min(.15,.6/100*Math.log10(t+1))*e.achievements[258],1+Math.min(.4,e.ascensionCount/2e13)*e.achievements[264],1+Math.min(.2,e.ascensionCount/8e14)*e.achievements[265],Math.min(2,1+1/1e6*f.log(e.ascendShards.add(1),10)*e.achievements[270])];return{list:r,mult:be(r)}},j0=()=>{let t=ae(e.usedCorruptions.slice(2,10));return[xe.CUBE_BUFF,1+1.5*e.shopUpgrades.seasonPass3/100,1+.75*e.shopUpgrades.seasonPassY/100,1+e.shopUpgrades.seasonPassZ*e.singularityCount/100,1+e.shopUpgrades.seasonPassLost/1e3,1+ +(t>=14*8)*e.cubeUpgrades[70]/1e4,1+ +(t>=14*8)*+e.singularityUpgrades.divinePack.getEffect().bonus,+e.singularityUpgrades.singCubes1.getEffect().bonus,+e.singularityUpgrades.singCubes2.getEffect().bonus,+e.singularityUpgrades.singCubes3.getEffect().bonus,+e.singularityUpgrades.singOcteractGain.getEffect().bonus,+e.singularityUpgrades.singOcteractGain2.getEffect().bonus,+e.singularityUpgrades.singOcteractGain3.getEffect().bonus,+e.singularityUpgrades.singOcteractGain4.getEffect().bonus,+e.singularityUpgrades.singOcteractGain5.getEffect().bonus,1+rr()/100*+e.singularityUpgrades.singOcteractPatreonBonus.getEffect().bonus,1+.2*+e.octeractUpgrades.octeractStarter.getEffect().bonus,+e.octeractUpgrades.octeractGain.getEffect().bonus,+e.octeractUpgrades.octeractGain2.getEffect().bonus,a2(),Math.pow(1+ +e.octeractUpgrades.octeractAscensionsOcteractGain.getEffect().bonus,1+Math.floor(Math.log10(1+e.ascensionCount))),1+Ye(10),1+ +e.singularityUpgrades.platonicDelta.getEffect().bonus*Math.min(9,e.shopUpgrades.shopSingularitySpeedup>0?e.singularityCounter*50/(3600*24):e.singularityCounter/(3600*24)),+e.singularityChallenges.noSingularityUpgrades.rewards.cubes,Math.pow(1.02,e.shopUpgrades.seasonPassInfinity),yl(),+e.blueberryUpgrades.ambrosiaTutorial.bonus.cubes,+e.blueberryUpgrades.ambrosiaCubes1.bonus.cubes,+e.blueberryUpgrades.ambrosiaLuckCube1.bonus.cubes,+e.blueberryUpgrades.ambrosiaQuarkCube1.bonus.cubes,+e.blueberryUpgrades.ambrosiaCubes2.bonus.cubes,+Ki(),+V0()]},Kr=()=>{let r=An().effectiveScore,n=r>=1e23?r/1e23:0,a=j0(),s=e.singularityUpgrades.oneMind.getEffect().bonus?Math.pow(10,1/2):Math.pow(Rr(),1/2),l=e.singularityUpgrades.oneMind.getEffect().bonus?Math.pow(Rr()/10,+e.octeractUpgrades.octeractOneMindImprover.getEffect().bonus):1,c=o.isEvent&&o.eventClicked?1.05:1;return 1/(24*3600*365*1e15)*n*be(a)*s*l*c},Im=(t=-1)=>{t<0&&(t=An().effectiveScore);let n=j0();n.unshift(t>=1e23?t/1e23:0);let a=Rr(),s=e.singularityUpgrades.oneMind.getEffect().bonus?Math.pow(10,1/2)*Math.pow(a/10,+e.octeractUpgrades.octeractOneMindImprover.getEffect().bonus):Math.pow(a,1/2);return n.push(s),{list:n,mult:be(n)}},qe=()=>{let t=[1+.0033333333333333335*Math.log10(e.maxobtainium+1)*e.upgrades[70],1+e.researches[121]/50,1+.015*e.researches[136],1+.012*e.researches[151],1+.009*e.researches[166],1+.006*e.researches[181],1+.003*e.researches[196],1+8*o.effectiveRuneBlessingPower[1],1+Xe()/400*o.effectiveRuneSpiritPower[1],o.cubeBonusMultiplier[10],1+e.cubeUpgrades[18]/5,pt(2,e.antUpgrades[11]+o.bonusant12,69),1+.1*(e.talismanRarity[1]-1),o.challenge15Rewards.globalSpeed,1+.01*e.cubeUpgrades[52]],r=[o.lazinessMultiplier[e.usedCorruptions[3]]],n=be(t)*r[0];if(n>100){let c=10*Math.sqrt(n)/n;r.push(c)}else r.push(1);if(n<1){let c=Math.pow(n,1-e.platonicUpgrades[7]/30)/n;r.push(c)}else r.push(1);r.push(1/Le("Global Speed"));let a=[o.platonicBonusMultiplier[7],1+(e.singularityUpgrades.intermediatePack.getEffect().bonus?1:0),1+ +e.octeractUpgrades.octeractImprovedGlobalSpeed.getEffect().bonus*e.singularityCount,1+ +e.singularityChallenges.limitedTime.rewards.globalSpeed,Math.max(Math.pow(1.01,(e.singularityCount-200)*e.shopUpgrades.shopChronometerS),1)],s=be(t)*be(r)*be(a);return e.usedCorruptions[3]>=6&&e.achievements[241]<1&&R(241),s>3600&&e.achievements[242]<1&&R(242),{preList:t,drList:r,postList:a,mult:s}},e2=()=>{if(e.singularityChallenges.limitedAscensions.enabled){let t=e.ascensionCount-Math.max(0,20-e.singularityChallenges.limitedAscensions.completions);return t=Math.max(0,t),Math.pow(2,t)}else return 1},Mu=()=>{let t=[1+.012*e.shopUpgrades.chronometer,1+.006*e.shopUpgrades.chronometer2,1+.015*e.shopUpgrades.chronometer3,1+6e-4*Ve("chronos"),1+Math.min(.1,.01*Math.log10(e.ascensionCount+1))*e.achievements[262],1+Math.min(.1,.01*Math.log10(e.ascensionCount+1))*e.achievements[263],1+.002*ae(e.usedCorruptions)*e.platonicUpgrades[15],o.challenge15Rewards.ascensionSpeed,1+.0025*e.cubeUpgrades[59],1+.5*(e.singularityUpgrades.intermediatePack.getEffect().bonus?1:0),1+.001*e.singularityCount*e.shopUpgrades.chronometerZ,1+ +e.octeractUpgrades.octeractImprovedAscensionSpeed.getEffect().bonus*e.singularityCount,1+ +e.octeractUpgrades.octeractImprovedAscensionSpeed2.getEffect().bonus*e.singularityCount,1+Ye(4),e.singularityUpgrades.singAscensionSpeed2.level>0&&e.runelevels[6]<1?6:1,Math.pow(1.01,e.shopUpgrades.chronometerInfinity),1/e2(),Math.pow(1+ +e.singularityChallenges.limitedAscensions.rewards.ascensionSpeedMult,1+Math.max(0,Math.floor(Math.log10(e.ascensionCount)))),1+ +e.singularityChallenges.limitedTime.rewards.ascensionSpeed,Math.max(Math.pow(1.01,(e.singularityCount-200)*e.shopUpgrades.shopChronometerS),1)],r=be(t),n=e.singularityUpgrades.singAscensionSpeed.level>0?r>=1?1.03:.97:1;t.push(Math.pow(r,n)/r),t.push(1/Le("Ascension Speed"));let a=be(t);return isFinite(a)||(a=0),{list:t,mult:a}},Rr=()=>Mu().mult,Tu=()=>{let t=1,r=[5,7,10,20,35,50,65,80,90,100,121,144,150,160,166,169,170,175,180,190,196,200,201,202,203,204,205,210,212,214,216,218,220,225,250,255,260,261,262];for(let n of r)e.highestSingularityCount>=n&&(t*=1.05);return e.highestSingularityCount>=200&&(t*=Math.pow((e.highestSingularityCount-179)/20,2)),t},Ti=()=>{let t=1;return e.achievementPoints>0&&(t+=e.achievementPoints/25e3),e.achievements[250]>0&&(t+=.1),e.achievements[251]>0&&(t+=.1),e.platonicUpgrades[5]>0&&(t+=.2),e.platonicUpgrades[10]>0&&(t+=.25),e.platonicUpgrades[15]>0&&(t+=.3),e.challenge15Exponent>=1e11&&(t+=o.challenge15Rewards.quarks-1),wa()&&(t*=1.1+.15/75*Qn()),e.challenge15Exponent>=1e15&&(t*=1+5/1e4*Ve("quark")),e.overfluxPowder>0&&(t*=ds()),e.achievements[266]>0&&(t*=1+Math.min(.1,e.ascensionCount/1e16)),e.singularityCount>0&&(t*=1+e.singularityCount/10),o.isEvent&&(t*=1+Ye(0)+Ye(13)),e.cubeUpgrades[53]>0&&(t*=1+.1*e.cubeUpgrades[53]/100),e.cubeUpgrades[68]>0&&(t*=1+1/1e4*e.cubeUpgrades[68]+.05*Math.floor(e.cubeUpgrades[68]/1e3)),t*=Tu(),t*=+e.octeractUpgrades.octeractQuarkGain.getEffect().bonus,t*=1+.4*+e.octeractUpgrades.octeractStarter.getEffect().bonus,t*=1+1/1e4*Math.floor(e.octeractUpgrades.octeractQuarkGain.level/111)*e.octeractUpgrades.octeractQuarkGain2.level*Math.floor(1+Math.log10(Math.max(1,e.hepteractCrafts.quark.BAL))),t*=1+.02*e.singularityUpgrades.intermediatePack.level+.04*e.singularityUpgrades.advancedPack.level+.06*e.singularityUpgrades.expertPack.level+.08*e.singularityUpgrades.masterPack.level+.1*e.singularityUpgrades.divinePack.level,t*=1+ +e.singularityUpgrades.singQuarkImprover1.getEffect().bonus,t*=fn(),t*=To(),t*=+e.blueberryUpgrades.ambrosiaTutorial.bonus.quarks,t*=+e.blueberryUpgrades.ambrosiaQuarks1.bonus.quarks,t*=+e.blueberryUpgrades.ambrosiaCubeQuark1.bonus.quarks,t*=+e.blueberryUpgrades.ambrosiaLuckQuark1.bonus.quarks,t*=+e.blueberryUpgrades.ambrosiaQuarks2.bonus.quarks,t*=bo(),t*=1+ +e.singularityChallenges.limitedTime.rewards.quarkMult,t*=1+ +e.singularityChallenges.sadisticPrequel.rewards.quarkMult,e.highestSingularityCount===0&&(t*=1.25),t},Su=(t=!1)=>{let r=2*e.singularityCount+10,n=e.singularityCount<10?200-10*e.singularityCount:0;e.singularityCount===0&&(n+=200);let a=1;e.highestSingularityCount>=200&&(a=3),e.highestSingularityCount>=208&&(a=5),e.highestSingularityCount>=221&&(a=8);let s=[xe.GOLDEN_QUARK_BUFF,1+Math.max(0,Math.log10(e.challenge15Exponent+1)-20)/2,1+rr()/100,+e.singularityUpgrades.goldenQuarks1.getEffect().bonus,1+.12*e.cubeUpgrades[69],+e.singularityChallenges.noSingularityUpgrades.rewards.goldenQuarks,1+Ye(1),1+fa(),e.highestSingularityCount>=100?1+Math.min(1,e.highestSingularityCount/250):1,a];return s.push(t?1/1e5:((r+e.quarksThisSingularity/1e5)*be(s)+n)/be(s)),{list:s,mult:be(s)}},Xt=(t=!1)=>Su(t).mult,Xe=()=>{let t=400,r=e.singularityUpgrades.corruptionFifteen.getEffect().bonus?1:0;for(let n=1;n<=9;n++)t+=16*Math.pow(e.usedCorruptions[n]+r,2);return t},Zn=(t,r,n,a=1e9)=>{let s=r*t*(1+t)/2,l=Math.min(t+a,Math.floor(-1/2+Math.sqrt(1/4+2*(n+s)/r))),c=r*l*(1+l)/2-s;return[l,c]},sr=(t,r,n,a,s)=>{let l=a/2;n=n||0;let c=r*(l*Math.pow(t,2)+t*(1-l));n+=c;let p=n/r,g=l>0?Math.max(0,Math.floor((l-1)/(2*l)+Math.pow(Math.pow(1-l,2)+4*l*p,1/2)/(2*l))):Math.floor(p);g=Math.min(g,s+t),g=Math.max(g,t);let m=r*(l*Math.pow(g,2)+g*(1-l))-c;return g===t&&(m=r*(1+2*l*t)),{levelCanBuy:g,cost:m}},G0=t=>t<0||!Number.isInteger(t)?-1:Math.pow(t*(t+1)/2,2),t2=(t,r,n,a)=>{if(t<0)throw new Error(String(u.t("calculate.quadraticImproperError")));let s=Math.pow(r,2)-4*t*n;if(s<0)throw new Error(String(u.t("calculate.quadraticDeterminantError")));if(s===0)return-r/(2*t);let l=-r+Math.sqrt(Math.pow(r,2)-4*t*n),c=-r-Math.sqrt(Math.pow(r,2)-4*t*n);return a?l/(2*t):c/(2*t)},Bg=(t,r,n,a)=>{if(t>=a)return{levelCanBuy:a,cost:0};let s=r*G0(t),l=s+n;if(l<0)throw new Error(String(u.t("calculate.cubicSumNegativeError")));let c=Math.pow(l/r,.5),p=t2(1,1,-2*c,!0),g=Math.max(Math.min(a,Math.floor(p)),t),m=g===t?r*Math.pow(t+1,3):r*G0(g)-s;return{levelCanBuy:g,cost:m}},r2=()=>{let t=1;return t*=o.challenge15Rewards.score,t*=o.platonicBonusMultiplier[6],e.cubeUpgrades[21]>0&&(t*=1+.05*e.cubeUpgrades[21]),e.cubeUpgrades[31]>0&&(t*=1+.05*e.cubeUpgrades[31]),e.cubeUpgrades[41]>0&&(t*=1+.05*e.cubeUpgrades[41]),e.achievements[267]>0&&(t*=1+Math.min(1,1/1e5*f.log(e.ascendShards.add(1),10))),e.achievements[259]>0&&(t*=Math.max(1,Math.pow(1.01,Math.log2(e.hepteractCrafts.abyss.CAP)))),o.isEvent&&(t*=1+Ye(6)),t},An=()=>{let t=0,r=1,n=0,a=e.singularityUpgrades.corruptionFifteen.getEffect().bonus?1:0;a+=+e.singularityChallenges.oneChallengeCap.rewards.freeCorruptionLevel;let s=[0,8,10,12,15,20,60,80,120,180,300],l=[0,10,12,15,20,30,80,120,180,300,450],c=[0,20,30,50,100,200,250,300,400,500,750],p=[0,1e4,1e4,1e4,1e4,1e4,2e3,3e3,4e3,5e3,7500];s[1]+=e.cubeUpgrades[56],s[2]+=e.cubeUpgrades[56],s[3]+=e.cubeUpgrades[56];for(let h=1;h<=10;h++)t+=s[h]*e.highestchallengecompletions[h],h<=5&&e.highestchallengecompletions[h]>=75&&(t+=l[h]*(e.highestchallengecompletions[h]-75),e.highestchallengecompletions[h]>=750&&(t+=c[h]*(e.highestchallengecompletions[h]-750)),e.highestchallengecompletions[h]>=9e3&&(t+=p[h]*(e.highestchallengecompletions[h]-9e3))),h<=10&&h>5&&e.highestchallengecompletions[h]>=25&&(t+=l[h]*(e.highestchallengecompletions[h]-25),e.highestchallengecompletions[h]>=60&&(t+=c[h]*(e.highestchallengecompletions[h]-60)));t*=Math.pow(1.03+.005*e.cubeUpgrades[39]+.0025*(e.platonicUpgrades[5]+e.platonicUpgrades[10]),e.highestchallengecompletions[10]);let g=e.singularityUpgrades.advancedPack.getEffect().bonus?.33:0;g+=+e.singularityChallenges.oneChallengeCap.rewards.corrScoreIncrease,g+=.3*e.cubeUpgrades[74];for(let h=2;h<10;h++){let b=h===2&&e.usedCorruptions[h]>=10?1+2*Math.min(1,e.platonicUpgrades[17])+.04*e.platonicUpgrades[17]:1;r*=Math.pow(o.corruptionPointMultipliers[e.usedCorruptions[h]+a],b)+g,e.usedCorruptions[h]>=14&&e.singularityUpgrades.masterPack.getEffect().bonus&&(r*=1.1)}let m=r2();return n=t*r*m,n>1e23&&(n=Math.pow(n,.5)*Math.pow(1e23,.5)),e.singularityUpgrades.expertPack.getEffect().bonus?n*=1.5:n*=1,{baseScore:t,corruptionMultiplier:r,bonusMultiplier:m,effectiveScore:n}},Xr=()=>{let t=0,r=1,n=An(),a=n.baseScore,s=n.corruptionMultiplier,l=n.bonusMultiplier,c=n.effectiveScore;for(let x=1;x<=10;x++)r=x>=6?2:1,t+=r*e.highestchallengecompletions[x];let p=e.singularityUpgrades.oneMind.getEffect().bonus?Rr()/10:1,g=t;g*=ll(c).mult,g*=p;let m=e.singularityUpgrades.platonicTau.getEffect().bonus?1.01:1;g=Math.pow(g,m);let h=1;c>=1e5&&(h+=.5),h*=cl(c).mult,h*=p;let b=c>=1e9?1:0;b*=ul(c).mult,b*=p;let C=c>=2666e9?1:0;C*=dl(c).mult,C*=p;let v=o.challenge15Rewards.hepteractUnlocked&&c>=1666e14&&e.achievements[255]>0?1:0;return v*=pl(c).mult,v*=p,[t,Math.floor(a),s,Math.floor(c),Math.min(1e300,Math.floor(g)),Math.min(1e300,Math.max(e.singularityCount,Math.floor(h))),Math.min(1e300,Math.floor(b)),Math.min(1e300,Math.floor(C)),Math.min(1e300,Math.floor(v)),l]},Lo=()=>{let t=1;if(e.singularityChallenges.limitedAscensions.enabled)return t;if(e.challengecompletions[10]>0&&e.achievements[197]===1){let{effectiveScore:r}=An();e.ascensionCounter>=10&&(e.achievements[188]>0&&(t+=99),t*=1+(e.ascensionCounter/10-1)*.2*(e.achievements[189]+e.achievements[202]+e.achievements[209]+e.achievements[216]+e.achievements[223])),t*=e.achievements[187]&&Math.floor(r)>1e8?Math.log10(Math.floor(r)+1)-1:1,t*=o.challenge15Rewards.ascensions,t*=e.achievements[260]>0?1.1:1,t*=e.achievements[261]>0?1.1:1,t*=e.platonicUpgrades[15]>0?2:1,t*=1+.02*e.platonicUpgrades[16],t*=1+.02*e.platonicUpgrades[16]*Math.min(1,e.overfluxPowder/1e5),t*=1+e.singularityCount/10,t*=+e.singularityUpgrades.ascensions.getEffect().bonus,t*=+e.octeractUpgrades.octeractAscensions.getEffect().bonus,t*=+e.octeractUpgrades.octeractAscensions2.getEffect().bonus,t*=e.singularityUpgrades.oneMind.getEffect().bonus?Rr()/10:1}return Math.floor(t)},Ar=()=>{let t=[.01,o.challenge15Rewards.powder,1+e.shopUpgrades.powderEX/50,1+e.achievements[256]/20,1+e.achievements[257]/20,1+.01*e.platonicUpgrades[16],1+Ye(3)];return{list:t,mult:be(t)}},_n=()=>(pt(2,Math.pow(e.overfluxOrbs,.5),40)+pt(1.5,Math.pow(e.overfluxOrbs,.5),160)+pt(1.5,Math.pow(e.overfluxOrbs,.5),640)+pt(1.15,+(e.highestSingularityCount>=1)*Math.pow(e.overfluxOrbs,.45),2560)+pt(1.15,+(e.highestSingularityCount>=2)*Math.pow(e.overfluxOrbs,.4),1e4)+pt(1.25,+(e.highestSingularityCount>=5)*Math.pow(e.overfluxOrbs,.35),4e4)+pt(1.25,+(e.highestSingularityCount>=10)*Math.pow(e.overfluxOrbs,.32),16e4)+pt(1.35,+(e.highestSingularityCount>=15)*Math.pow(e.overfluxOrbs,.27),64e4)+pt(1.45,+(e.highestSingularityCount>=20)*Math.pow(e.overfluxOrbs,.24),2e6)+pt(1.55,+(e.highestSingularityCount>=25)*Math.pow(e.overfluxOrbs,.21),1e7)+pt(1.85,+(e.highestSingularityCount>=30)*Math.pow(e.overfluxOrbs,.18),4e7)+pt(3,+(e.highestSingularityCount>=35)*Math.pow(e.overfluxOrbs,.15),1e8)-11)*(1+1/500*e.shopUpgrades.cubeToQuarkAll)*(e.autoWarpCheck?1+e.dailyPowderResetUses:1),Di=()=>e.overfluxPowder>1e4?1+1/16*Math.pow(Math.log10(e.overfluxPowder),2):1+1/1e4*e.overfluxPowder,ds=()=>e.overfluxPowder>1e4?1+1/40*Math.log10(e.overfluxPowder):1+1/1e5*e.overfluxPowder,Cd=()=>{let t=0,r=[35,42,49,56,63,70,77],n=[135,142,149,156,163,170,177];for(let a of r)e.highestSingularityCount>=a&&(t+=5);for(let a of n)e.highestSingularityCount>=a&&(t+=6);return t},wd=()=>{let t=[1+e.shopUpgrades.shopAmbrosiaGeneration1/100,1+e.shopUpgrades.shopAmbrosiaGeneration2/100,1+e.shopUpgrades.shopAmbrosiaGeneration3/100,1+e.shopUpgrades.shopAmbrosiaGeneration4/1e3];return be(t)},xd=()=>{let t=[2*e.shopUpgrades.shopAmbrosiaLuck1,2*e.shopUpgrades.shopAmbrosiaLuck2,2*e.shopUpgrades.shopAmbrosiaLuck3,.6*e.shopUpgrades.shopAmbrosiaLuck4];return ae(t)},Md=()=>{let t=[+e.singularityUpgrades.singAmbrosiaGeneration.getEffect().bonus,+e.singularityUpgrades.singAmbrosiaGeneration2.getEffect().bonus,+e.singularityUpgrades.singAmbrosiaGeneration3.getEffect().bonus,+e.singularityUpgrades.singAmbrosiaGeneration4.getEffect().bonus];return be(t)},Td=()=>{let t=[+e.singularityUpgrades.singAmbrosiaLuck.getEffect().bonus,+e.singularityUpgrades.singAmbrosiaLuck2.getEffect().bonus,+e.singularityUpgrades.singAmbrosiaLuck3.getEffect().bonus,+e.singularityUpgrades.singAmbrosiaLuck4.getEffect().bonus];return ae(t)},Sd=()=>{let t=[+e.octeractUpgrades.octeractAmbrosiaGeneration.getEffect().bonus,+e.octeractUpgrades.octeractAmbrosiaGeneration2.getEffect().bonus,+e.octeractUpgrades.octeractAmbrosiaGeneration3.getEffect().bonus,+e.octeractUpgrades.octeractAmbrosiaGeneration4.getEffect().bonus];return be(t)},kd=()=>{let t=[+e.octeractUpgrades.octeractAmbrosiaLuck.getEffect().bonus,+e.octeractUpgrades.octeractAmbrosiaLuck2.getEffect().bonus,+e.octeractUpgrades.octeractAmbrosiaLuck3.getEffect().bonus,+e.octeractUpgrades.octeractAmbrosiaLuck4.getEffect().bonus];return ae(t)},Po=()=>{let t=[5e3,25e3,75e3,25e4,5e5,1e6,2e6,4e6,1e7,2e7,4e7,1e8,2e8,4e8,1e9],r=o.TIME_PER_AMBROSIA+Math.floor(e.lifetimeAmbrosia/30),n=0;for(let a of t)r>=a&&n++;return n},Ss=()=>{let t=o.TIME_PER_AMBROSIA;t+=Math.floor(e.lifetimeAmbrosia/30);let r=Po();return Math.pow(2,r)*t},Ld=()=>{let t=0;return e.highestSingularityCount>=270?t=5:e.highestSingularityCount>=256?t=4:e.highestSingularityCount>=192?t=3:e.highestSingularityCount>=128?t=2:e.highestSingularityCount>=64&&(t=1),t},yl=()=>{let t=e.singularityChallenges.noAmbrosiaUpgrades.enabled?0:e.lifetimeAmbrosia,r=1;return r+=Math.min(1.5,Math.floor(t/66)/100),t>=1e4&&(r+=Math.min(1.5,Math.floor(t/666)/100)),t>=1e5&&(r+=Math.floor(t/6666)/100),r},To=()=>{let t=e.singularityChallenges.noAmbrosiaUpgrades.enabled?0:e.lifetimeAmbrosia,r=1;return r+=Math.min(.3,Math.floor(t/1666)/100),t>=5e4&&(r+=Math.min(.3,Math.floor(t/16666)/100)),t>=5e5&&(r+=Math.floor(t/166666)/100),r},Ed=t=>1+e.shopUpgrades.shopCashGrabUltra*t*Math.min(1,Math.pow(e.lifetimeAmbrosia/1e7,1/3)),ho=()=>Ed(KC),Ki=()=>Ed(WC),bo=()=>Ed(VC),Od=t=>1+t*Math.min(e.shopUpgrades.shopEXUltra,Math.floor(e.lifetimeAmbrosia/1e3)/125),n2=()=>Od(zC),ku=()=>Od(XC),V0=()=>Od(ZC),So=()=>e.singularityChallenges.limitedAscensions.rewards.exaltBonus&&o.currentSingChallenge!==void 0?Math.pow(1.04,e.singularityChallenges[o.currentSingChallenge].completions):1,Ud=(t,r)=>{let n=Math.max(0,r-600+20*t);return n===0?1:Math.pow(10+t,-n/60)},Pd=()=>{let t=[100,150,200,225,250,255,260,265,269,272];for(let r=0;r{let t=[1,+e.singularityChallenges.noSingularityUpgrades.rewards.luckBonus,Pd(),e.shopUpgrades.shopAmbrosiaLuckMultiplier4/100,+e.singularityChallenges.noAmbrosiaUpgrades.rewards.luckBonus,.001*e.cubeUpgrades[77],o.isEvent?Ye(12):0];return{value:ae(t),array:t}},Ge=()=>{let t=[100,xe.AMBROSIA_LUCK_BUFF,Cd(),xd(),Td(),kd(),+e.blueberryUpgrades.ambrosiaLuck1.bonus.ambrosiaLuck,+e.blueberryUpgrades.ambrosiaLuck2.bonus.ambrosiaLuck,+e.blueberryUpgrades.ambrosiaCubeLuck1.bonus.ambrosiaLuck,+e.blueberryUpgrades.ambrosiaQuarkLuck1.bonus.ambrosiaLuck,e.highestSingularityCount>=131?131:0,e.highestSingularityCount>=269?269:0,e.shopUpgrades.shopOcteractAmbrosiaLuck*(1+Math.floor(Math.log10(e.totalWowOcteracts+1))),+e.singularityChallenges.noAmbrosiaUpgrades.rewards.additiveLuck,2*e.cubeUpgrades[77],Math.min(100,e.cubeUpgradeRedBarFilled/50),e.shopUpgrades.shopAmbrosiaUltra*du()],r=zr().value;return{value:ae(t)*r,array:t.concat(r)}},ha=()=>{let t=[+(e.singularityChallenges.noSingularityUpgrades.completions>0),+e.singularityUpgrades.blueberries.getEffect().bonus,Ld(),+e.singularityChallenges.noAmbrosiaUpgrades.rewards.blueberries];return{value:ae(t),array:t}},De=()=>{let t=[+e.visitedAmbrosiaSubtab,xe.AMBROSIA_GENERATION_BUFF,ha().value,wd(),Md(),Sd(),+e.blueberryUpgrades.ambrosiaPatreon.bonus.blueberryGeneration,+e.singularityChallenges.oneChallengeCap.rewards.blueberrySpeedMult,+e.singularityChallenges.noAmbrosiaUpgrades.rewards.blueberrySpeedMult,1+.01*e.cubeUpgrades[76]*Po(),o.isEvent?1+Ye(11):1,ho()];return{value:be(t),array:t}},Bd=()=>{if(!e.dayCheck)return;let t=new Date(il()),r=new Date(t.getFullYear(),t.getMonth(),t.getDate()),n=t.getHours(),a=t.getMinutes(),s=t.getSeconds();e.dayTimer=60*60*24-60*60*n-60*a-s,r.getTime()-36e5>e.dayCheck.getTime()&&(e.dayCheck=r,oo(!0),e.dailyPowderResetUses=1+e.shopUpgrades.extraWarp,e.dailyCodeUsed=!1,i("cubeQuarksOpenRequirement").style.display="block",e.challengecompletions[11]>0&&(i("tesseractQuarksOpenRequirement").style.display="block"),e.challengecompletions[13]>0&&(i("hypercubeQuarksOpenRequirement").style.display="block"),e.challengecompletions[14]>0&&(i("platonicCubeQuarksOpenRequirement").style.display="block"))},oo=(t=!1)=>{e.cubeQuarkDaily=0,e.tesseractQuarkDaily=0,e.hypercubeQuarkDaily=0,e.platonicCubeQuarkDaily=0,e.cubeOpenedDaily=0,e.tesseractOpenedDaily=0,e.hypercubeOpenedDaily=0,e.platonicCubeOpenedDaily=0,t&&(e.overfluxPowder+=e.overfluxOrbs*Ar().mult,e.overfluxOrbs=o.challenge15Rewards.freeOrbs)},Ye=t=>o.isEvent?Cu(t):0,a2=()=>{let t=0,r=[18,38,58,78,88,98,118,148,178,188,198,208,218,228,238,248];for(let n of r)e.highestSingularityCount>=n&&(t+=1);return 1+t*e.highestSingularityCount/100},wa=()=>e.shopUpgrades.infiniteAscent>0||xe.INSTANT_UNLOCK_2,jl=()=>e.shopUpgrades.shopTalisman>0||xe.INSTANT_UNLOCK_1;var du=()=>{let t=0;for(let r of Object.values(e.singularityChallenges))t+=r.completions;return t};var je=t=>{let r=0;return t<=5?e.singularityChallenges.oneChallengeCap.enabled?1:(r=25,e.researches[105]>0?9001:(r+=5*e.researches[65+t],r)):t<=10&&t>5?e.singularityChallenges.oneChallengeCap.enabled?1:(r=40,r+=4*e.cubeUpgrades[29],r+=2*e.shopUpgrades.challengeExtension,e.platonicUpgrades[5]>0&&(r+=10),e.platonicUpgrades[10]>0&&(r+=10),e.platonicUpgrades[15]>0&&(r+=30),r+=2*+e.singularityUpgrades.singChallengeExtension.getEffect().bonus,r+=2*+e.singularityUpgrades.singChallengeExtension2.getEffect().bonus,r+=2*+e.singularityUpgrades.singChallengeExtension3.getEffect().bonus,r+=+e.singularityChallenges.oneChallengeCap.rewards.capIncrease,r+=+e.singularityChallenges.oneChallengeCap.rewards.reinCapIncrease2,r):t<=15&&t>10?t===15?0:e.singularityChallenges.oneChallengeCap.enabled?1:(r=30,e.platonicUpgrades[5]>0&&(r+=5),e.platonicUpgrades[10]>0&&(r+=5),e.platonicUpgrades[15]>0&&(r+=20),r+=+e.singularityUpgrades.singChallengeExtension.getEffect().bonus,r+=+e.singularityUpgrades.singChallengeExtension2.getEffect().bonus,r+=+e.singularityUpgrades.singChallengeExtension3.getEffect().bonus,r+=+e.singularityChallenges.oneChallengeCap.rewards.ascCapIncrease2,r):r},lt=(t,r=!0)=>{let n=1;r&&(o.challengefocus=t,i("oneChallengeDetails").style.display="flex",i("startChallenge").style.display="block",i("retryChallenge").style.display="block",o.triggerChallenge=t);let a=je(t);t<=5&&r&&(e.challengecompletions[t]>=100?i("completionSoftcap").innerHTML=u.t("challenges.perCompletionBonus",{x:100,y:d(_("transcend",e.challengecompletions[t]),2,!0)}):i("completionSoftcap").textContent=u.t("challenges.perCompletionBonusEmpty")),t>5&&t<=10&&(n=10,e.challengecompletions[t]>=25&&r?i("completionSoftcap").innerHTML=u.t("challenges.perCompletionBonus",{x:25,y:d(_("reincarnation",e.challengecompletions[t]),2,!0)}):i("completionSoftcap").textContent=u.t("challenges.perCompletionBonusEmpty")),t>10&&(e.challengecompletions[t]>=10?i("completionSoftcap").innerHTML=u.t("challenges.perCompletionBonus",{x:10,y:d(_("ascension",e.challengecompletions[t]),2,!0)}):i("completionSoftcap").textContent=u.t("challenges.perCompletionBonusEmpty"));let s="",l=i("challengeName"),c=i("challengeFlavor"),p=i("challengeRestrictions"),g=i("challengeGoal"),m=i("challengePer1").childNodes[0],h=i("challengePer2").childNodes[0],b=i("challengePer3").childNodes[0],C=i("challengeFirst1"),v=i("challengeQuarkBonus"),x=i("startChallenge"),B=i("challengeCurrent1"),U=i("challengeCurrent2"),k=i("challengeCurrent3");if(t===o.challengefocus){let X=`${e.challengecompletions[t]}/${d(a)}`,re=t>=6&&t<=10||t===15,w=d(Et(t,e.challengecompletions[t],re?t:0)),H="",J="",Te="";switch(t){case 1:{H=J=d(10*_("transcend",e.challengecompletions[1])),Te=d(.04*_("transcend",e.challengecompletions[1]),2,!0);break}case 2:{H=J=d(5*_("transcend",e.challengecompletions[2]));break}case 3:{H=d(.04*e.challengecompletions[3],2,!0),J=d(.5*_("transcend",e.challengecompletions[3]),2,!0),Te=d(.01*_("transcend",e.challengecompletions[3]),2,!0);break}case 4:{H=d(5*_("transcend",e.challengecompletions[4])),J=d(2*_("transcend",e.challengecompletions[4])),Te=d(.5*_("transcend",e.challengecompletions[4]),2,!0);break}case 5:{H=d(.5+_("transcend",e.challengecompletions[5])/100,2,!0),J=d(Math.pow(10,_("transcend",e.challengecompletions[5])));break}case 6:{H=d(Math.pow(.965,_("reincarnation",e.challengecompletions[6])),3,!0),J=d(10*_("reincarnation",e.challengecompletions[6])),Te=d(2*_("reincarnation",e.challengecompletions[6]));break}case 7:{H=d(1+.04*_("reincarnation",e.challengecompletions[7]),2,!0),J=Te=d(10*_("reincarnation",e.challengecompletions[7]));break}case 8:{H=d(.25*_("reincarnation",e.challengecompletions[8]),2,!0),J=d(20*_("reincarnation",e.challengecompletions[8]),2,!0),Te=d(4*_("reincarnation",e.challengecompletions[8]),2,!0);break}case 9:{H=d(_("reincarnation",e.challengecompletions[9])),J=d(Math.pow(1.1,_("reincarnation",e.challengecompletions[9])),2,!0),Te=d(20*_("reincarnation",e.challengecompletions[9]),2,!0);break}case 10:{H=d(100*_("reincarnation",e.challengecompletions[10])),J=d(2*_("reincarnation",e.challengecompletions[10])),Te=d(10*_("reincarnation",e.challengecompletions[10]),2,!0);break}case 11:{H=d(12*_("ascension",e.challengecompletions[11])),J=d(f.pow(1e5,_("ascension",e.challengecompletions[11]))),Te=d(80*_("ascension",e.challengecompletions[11]));break}case 12:{H=d(50*_("ascension",e.challengecompletions[12])),J=d(12*_("ascension",e.challengecompletions[12])),Te=d(_("ascension",e.challengecompletions[12]));break}case 13:{H=d(100-100*Math.pow(.966,_("ascension",e.challengecompletions[13])),3,!0),J=d(6*_("ascension",e.challengecompletions[13])),Te=d(3*_("ascension",e.challengecompletions[13]));break}case 14:{H=d(50*_("ascension",e.challengecompletions[14])),J=d(1*e.challengecompletions[14]),Te=d(200*_("ascension",e.challengecompletions[14]));break}}l.textContent=u.t(`challenges.${t}.name`,{value:X,completions:e.challengecompletions[t],max:a}),c.textContent=u.t(`challenges.${t}.flavor`),p.textContent=u.t(`challenges.${t}.restrictions`),g.textContent=u.t(`challenges.${t}.goal`,{value:w}),m.textContent=u.t(`challenges.${t}.per.1`),h.textContent=u.t(`challenges.${t}.per.2`),b.textContent=u.t(`challenges.${t}.per.3`),C.textContent=u.t(`challenges.${t}.first`),x.textContent=u.t(`challenges.${t}.start`),B.textContent=u.t(`challenges.${t}.current.1`,{value:H}),U.textContent=u.t(`challenges.${t}.current.2`,{value:J}),k.textContent=u.t(`challenges.${t}.current.3`,{value:Te})}t===15&&o.challengefocus===15&&a===0&&(g.textContent=u.t("challenges.15.noGoal"));let L=[0,8,10,12,15,20,60,80,120,180,300],E=[0,10,12,15,20,30,80,120,180,300,450],T=[0,20,30,50,100,200,250,300,400,500,750],S=[0,1e4,1e4,1e4,1e4,1e4,2e3,3e3,4e3,5e3,7500],I=0;if(t<=5&&(e.highestchallengecompletions[t]>=9e3?I=S[t]:e.highestchallengecompletions[t]>=750?I=T[t]:e.highestchallengecompletions[t]>=75?I=E[t]:I=L[t]),t>5&&t<=10&&(e.highestchallengecompletions[t]>=60?I=T[t]:e.highestchallengecompletions[t]>=25?I=E[t]:I=L[t]),r&&(v.textContent=""),e.ascensionCount===0&&(s="Quarks",v.style.color="cyan"),e.challengecompletions[t]>=e.highestchallengecompletions[t]&&e.highestchallengecompletions[t]=e.highestchallengecompletions[t]&&e.highestchallengecompletions[t]=1&&(v.textContent=u.t("challenges.ascensionBankAdd",{x:t>5?2:1,y:I})),e.challengecompletions[t]>=e.highestchallengecompletions[t]&&e.highestchallengecompletions[t]<10&&t>10&&(v.textContent=u.t("challenges.hypercubeOneTimeBonus")),r){let X=i("toggleAutoChallengeIgnore");X.style.display=t<=(ti()?15:10)&&e.researches[150]>0?"block":"none",X.style.border=e.autoChallengeToggles[t]?"2px solid green":"2px solid red",t>=11&&t<=15?e.autoChallengeToggles[t]?X.textContent=u.t("challenges.autoAscRunChalOn",{x:t}):X.textContent=u.t("challenges.autoAscRunChalOff",{x:t}):e.autoChallengeToggles[t]?X.textContent=u.t("challenges.autoRunChalOn",{x:t}):X.textContent=u.t("challenges.autoRunChalOff",{x:t})}let N=i("toggleAutoChallengeStart");e.autoChallengeRunning?(N.textContent=u.t("challenges.autoChallengeSweepOn"),N.style.border="2px solid gold"):(N.textContent=u.t("challenges.autoChallengeSweepOff"),N.style.border="2px solid red")},Ml=t=>{e.currentChallenge.reincarnation===9&&(o.rune1level=1,o.rune2level=1,o.rune3level=1,o.rune4level=1,o.rune5level=1,e.crystalUpgrades=[0,0,0,0,0,0,0,0]),o.prestigePointGain=new f("0"),typeof t=="number"&&(t>=6&&(o.transcendPointGain=new f("0")),t>=11&&(o.reincarnationPointGain=new f("0"))),He()},W0=()=>{i("retryChallenge").textContent=e.retrychallenges?u.t("challenges.retryChallengesOff"):u.t("challenges.retryChallengesOn"),e.retrychallenges=!e.retrychallenges},Id=(t,r)=>{let n=.1;t>=6&&(n=1),e.ascensionCount===0&&e.worlds.add(1+Math.floor(r*n)*100/100),qt()&&e.ascensionCount===0&&t>=6&&t<=10&&(e.roombaResearchIndex=0,e.autoResearch=o.researchOrderByCost[e.roombaResearchIndex])},Yl=(t,r,n=0)=>{let a=Math.max(1,o.hyperchallengedMultiplier[e.usedCorruptions[4]]/(1+e.platonicUpgrades[8]/2.5));switch(t==="ascension"&&(a=1),t){case"transcend":return a*=o.challenge15Rewards.transcendChallengeReduction,r>=75?a*=Math.pow(1+r,12)/Math.pow(75,8):a*=Math.pow(1+r,2),r>=1e3&&(a*=10*Math.pow(r/1e3,3)),r>=9e3&&(a*=1337),r>=9001&&(a*=r-8999),a;case"reincarnation":return r>=100&&(n===9||n===10)&&(a*=Math.pow(1.05,(r-100)*(1+(r-100)/20))),r>=90&&(n===6?a*=100:n===7?a*=50:n===8?a*=10:a*=4),r>=80&&(n===6?a*=50:n===7?a*=20:n===8?a*=4:a*=2),r>=70&&(n===6?a*=20:n===7?a*=10:n===8?a*=2:a*=1),r>=60&&(n===9||n===10)&&(a*=Math.pow(1e3,(r-60)*(1-.01*e.shopUpgrades.challengeTome-.01*e.shopUpgrades.challengeTome2)/10)),r>=25&&(a*=Math.pow(1+r,5)/625),r<25&&(a*=Math.min(Math.pow(1+r,2),Math.pow(1.3797,r))),a*=o.challenge15Rewards.reincarnationChallengeReduction,a;case"ascension":return n!==15?r>=10?a*=2*(1+r)-10:a*=1+r:a*=Math.pow(1e3,r),a}},_=(t,r)=>{let n=0;switch(t){case"transcend":return n+=Math.min(100,r),n+=1/20*(Math.min(1e3,Math.max(100,r))-100),n+=1/100*(Math.max(1e3,r)-1e3),n;case"reincarnation":return n+=Math.min(25,r),n+=1/2*(Math.min(75,Math.max(25,r))-25),n+=1/10*(Math.max(75,r)-75),n;case"ascension":return n+=Math.min(10,r),n+=1/2*(Math.max(10,r)-10),n}},Et=(t,r,n=0)=>{let a=o.challengeBaseRequirements[t-1];if(t<=5)return f.pow(10,a*Yl("transcend",r,n));if(t<=10){let s=0;return t===10&&(s=1e8*(e.researches[140]+e.researches[155]+e.researches[170]+e.researches[185])+2e7*(e.shopUpgrades.challengeTome+e.shopUpgrades.challengeTome2)),f.pow(10,(a-s)*Yl("reincarnation",r,n))}else return t<=14?Yl("ascension",r,n):t===15?f.pow(10,1*Math.pow(10,30)*Yl("ascension",r,n)):0},K0=t=>{if(e.researches[150]===0||!e.autoChallengeRunning)return;o.autoChallengeTimerIncrement+=t;let r="none";if(e.currentChallenge.reincarnation!==0||e.currentChallenge.transcension!==0?r="exit":e.autoChallengeIndex===1?r="start":r="enter",ti()&&e.currentChallenge.ascension===15&&e.shopUpgrades.challenge15Auto===0&&(r==="start"||r==="enter")&&e.autoAscend&&e.challengecompletions[11]>0&&e.cubeUpgrades[10]>0&&e.autoAscendMode==="realAscensionTime"&&e.ascensionCounterRealReal>=Math.max(.1,e.autoAscendThreshold-5)){r="wait",fr("WAIT");return}if(o.autoChallengeTimerIncrement>=e.autoChallengeTimer.exit&&r==="exit"){let n=e.currentChallenge.reincarnation!==0?"reincarnation":"transcension";o.autoChallengeTimerIncrement=0;let a=e.autoChallengeIndex,s=ei(a+1);n==="transcension"&&Ae("transcensionChallenge",void 0,!0),n==="reincarnation"&&Ae("reincarnationChallenge",void 0,!0),s<=10&&(s=e.autoChallengeTimer.start&&r==="start"||o.autoChallengeTimerIncrement>=e.autoChallengeTimer.enter&&r==="enter"){o.autoChallengeTimerIncrement=0;let n=e.autoChallengeIndex,a=ei(n);if(a===11)return;e.autoChallengeIndex=a,hr(e.autoChallengeIndex,!0),fr("EXIT");return}},ei=(t,r=!1,n=1,a=10)=>{let s=t;for(let l=s;l<=a&&(!e.autoChallengeToggles[l]||!r&&l!==15&&e.highestchallengecompletions[l]>=je(l));l++)s+=1;if(s>a){s=n;for(let l=s;l<=a&&(!e.autoChallengeToggles[l]||!r&&l!==15&&e.highestchallengecompletions[l]>=je(l));l++)s+=1}return s},ti=()=>e.highestSingularityCount>=101&&e.shopUpgrades.instantChallenge2>0,ko=()=>{let t=[1+5e-4*Ve("challenge"),1+.25*e.platonicUpgrades[15]];return be(t)};var ct=t=>d(typeof t=="string"?new f(t):t),ri=(t,r)=>typeof t=="string"?ct(t):typeof t=="number"&&e.historyShowPerSecond&&r.seconds!==0?t===0?"0.000/s":`${d(t/r.seconds,3,t<1e3)}/s`:d(t),s2={offerings:{img:"Offering.png",formatter:ct,imgTitle:"Offerings"},obtainium:{img:"Obtainium.png",formatter:ct,imgTitle:"Obtainium"},particles:{img:"Particle.png",formatter:ct,imgTitle:"Particles"},diamonds:{img:"Diamond.png",formatter:ct,imgTitle:"Diamonds"},mythos:{img:"Mythos.png",formatter:ct,imgTitle:"Mythos"},wowTesseracts:{img:"TinyWow4.png",formatter:ri,imgTitle:"Wow! Tesseracts"},wowHypercubes:{img:"TinyWow5.png",formatter:ri,imgTitle:"Wow! Hypercubes",onlyif:()=>e.challengecompletions[13]>0},wowCubes:{img:"TinyWow3.png",formatter:ri,imgTitle:"Wow! Cubes"},wowPlatonicCubes:{img:"TinyWow6.png",formatter:ri,imgTitle:"Platonic Cubes",onlyif:()=>e.challengecompletions[14]>0},wowHepteracts:{img:"TinyWow7.png",formatter:ri,imgTitle:"Hepteracts",onlyif:()=>e.achievements[255]>0},singularityCount:{img:"TinyS.png",formatter:ct,imgTitle:"Singularity Count",onlyif:()=>e.highestSingularityCount>0},quarks:{img:"Quark.png",formatter:ct,imgTitle:"Quarks",onlyif:()=>e.highestSingularityCount>0},goldenQuarks:{img:"GoldenQuark.png",formatter:ct,imgTitle:"Golden Quarks",onlyif:()=>e.highestSingularityCount>0},wowTribs:{img:"TinyWow3.png",formatter:ct,imgTitle:"Cube Tributes",onlyif:()=>e.highestSingularityCount>0},tessTribs:{img:"TinyWow4.png",formatter:ct,imgTitle:"Tesseract Gifts",onlyif:()=>e.highestSingularityCount>0},hyperTribs:{img:"TinyWow5.png",formatter:ct,imgTitle:"Hypercube Bendictions",onlyif:()=>e.highestSingularityCount>0},platTribs:{img:"TinyWow6.png",formatter:ct,imgTitle:"Platonics Opened",onlyif:()=>e.highestSingularityCount>0},octeracts:{img:"TinyWow8.png",formatter:ct,imgTitle:"Octeracts",onlyif:()=>e.singularityUpgrades.octeractUnlock.getEffect().bonus>0},c15Score:{img:"TinyChallenge15.png",formatter:ct,imgTitle:"C15 score",onlyif:()=>e.singularityCount>0},quarkHept:{img:"TinyQuarkHept.png",formatter:ct,imgTitle:"Quark Hept",onlyif:()=>e.singularityCount>0}},o2=["offerings","obtainium","particles","diamonds","mythos","wowCubes","wowTesseracts","wowHypercubes","wowPlatonicCubes","wowHepteracts","singularityCount","quarks","goldenQuarks","wowTribs","tessTribs","hyperTribs","platTribs","octeracts","c15Score","quarkHept"],i2={antsacrifice:{img:"SacrificeNoBorder.png"},prestige:{img:"TinyP.png"},transcend:{img:"TinyT.png"},reincarnate:{img:"TinyR.png"},ascend:{img:"TinyA.png"},singularity:{img:"TinyS.png"}},Nd={ants:"historyAntsTable",reset:"historyResetTable",ascend:"historyAscendTable",singularity:"historySingularityTable"},z0=["CorruptViscocity.png","CorruptSpatialDilation.png","CorruptHyperchallenged.png","CorruptScientificIlliteracy.png","CorruptDeflation.png","CorruptExtinction.png","CorruptDrought.png","CorruptFinancialCollapse.png"],l2=["Viscosity [Accelerators and Multipliers]","Spacial Dilation [Time]","Hyperchallenged [Challenge Requirements]","Scientific Illiteracy [Obtainium]","Market Deflation [Diamonds]","Extinction [Ants]","Drought [Offering EXP]","Financial Recession [Coins]"],c2=t=>{let r;return(r=/e\+?(.+)/.exec(t))!==null?`e${r[1]}`:t},u2=(t,r)=>{for(;e.history[t].length>o.historyCountMax-1;)e.history[t].shift();e.history[t].push(r),d2(t,r)};Ct.on("historyAdd",u2);var d2=(t,r)=>{let n=X0(t,r),s=i(Nd[t]).querySelector("tbody");for(s.insertBefore(n,s.childNodes[0]);s.childNodes.length>o.historyCountMax;)s.removeChild(s.lastChild);if(t==="ascend"){let l=Array.from(n.getElementsByClassName("ascendHistoryLoadCorruptions"));for(let c of l)c.addEventListener("click",p=>Z0(p.target))}},X0=(t,r)=>{let n=1,a=document.createElement("tr"),s="",l=i2[r.kind],c=new Date(r.date).toLocaleString();s+=`${r.kind}${zt(r.seconds,60)}`;let p=[],g=r;o2.forEach(h=>{var b;if(Object.prototype.hasOwnProperty.call(r,h)){let C=s2[h];if(C.onlyif&&!C.onlyif(r))return;let v=(b=C.formatter)!=null?b:()=>{},x=`${C.imgTitle}${v(g[h],r)}`;p.push(x)}});let m=[];if(r.kind==="antsacrifice"){let h=ra(r.antSacrificePointsBefore),b=ra(r.antSacrificePointsAfter),C=b-h;m.push(`Ant Multiplier+${d(C,3,!1)}`,`Crumbs${c2(ct(r.crumbs))}`,`ELO${d(r.effectiveELO)}`)}else if(r.kind==="ascend"){m.push(`C10${r.c10Completions}`);let h=g2(r);m.push(h[0]),m.push(h[1]),m.push(h[2])}return n+=p.length,s+=p.reduce((h,b)=>`${h}${b}`,""),s+=``,s+=m.reduce((h,b)=>`${h}${b}`,""),s+=``,a.innerHTML=s,a},p2=(t,r)=>{let n=r.querySelector("tbody");if(n.innerHTML="",e.history[t].length>0)for(let a=e.history[t].length-1;a>=0;--a){let s=X0(t,e.history[t][a]);n.appendChild(s)}if(t==="ascend"){let a=Array.from(document.getElementsByClassName("ascendHistoryLoadCorruptions"));for(let s of a)s.addEventListener("click",l=>Z0(l.target))}};function Z0(t){let r=t.getAttribute("data-corr");r&&(gd(r),Dt(u.t("corruptions.loadoutApplied"),5e3))}var $d=()=>{Object.keys(Nd).forEach(t=>p2(t,i(Nd[t])))},Y0=()=>{e.historyShowPerSecond=!e.historyShowPerSecond,$d();let t=i("historyTogglePerSecondButton");e.historyShowPerSecond?t.textContent=u.t("history.perSecondOn"):t.textContent=u.t("history.perSecondOff"),t.style.borderColor=e.historyShowPerSecond?"green":"red"},g2=t=>{let r=`Score: ${d(t.corruptionScore,0,!1)}`,n="",a="",s=0;for(let l=0;l${t.usedCorruptions[c]}`:n+=`${s>0?"/0":"0"}`,s++}return n&&(a+=``),t.currentChallenge!==void 0&&(r+=` / C${t.currentChallenge}`),[r,n,a]};var J0=Un(vc());var eh=async()=>{let t="===== SUMMARY STATS =====",r=`Time Generated: ${new Date().toString()}`,n=`Version: ${tr}`,a=`-----+----- `,s=`First Played: ${e.firstPlayed} `,l=`===== RESOURCES ===== `;if(l=l+(e.reincarnationCount>0||e.highestSingularityCount>0?`Quarks: ${d(Number(e.worlds),0,!0)} @@ -165,22 +212,22 @@ ${d(s.goldenQuarks,0,!0)} Golden Quarks`),await P(a),e.highestSingularityCount>0 `,c=`${c}Current Octeracts: ${d(e.wowOcteracts,2,!0)} `,c=`${c}Current Per Second: ${d(Kr(),2,!0)} `,c=`${c}Total Generated Octeracts: ${d(e.totalWowOcteracts,2,!0)} -`,c=`${c}Octeract Cube Bonus: ${d(100*(Lo()-1),2,!0)}% +`,c=`${c}Octeract Cube Bonus: ${d(100*(Oo()-1),2,!0)}% `,c=`${c}Octeract Quark Bonus: ${d(100*(fn()-1),2,!0)}% `);let p="";e.highestSingularityCount>0&&(p=`===== SINGULARITY ===== `,p=`${p}Current Singularity: ${e.singularityCount} `,p=`${p}Highest Singularity Reached: ${e.highestSingularityCount} `,p=`${p}Golden Quarks: ${d(e.goldenQuarks,2,!0)} -`,p=`${p}+Golden Quarks on Singularity: ${d(Wt(),2,!0)} -`,p=`${p}Time in Singularity: ${Tr(e.singularityCounter)} -`,p=`${p}Effective Singularity [for penalties]: ${d(Ys(),2,!0)} +`,p=`${p}+Golden Quarks on Singularity: ${d(Xt(),2,!0)} +`,p=`${p}Time in Singularity: ${kr(e.singularityCounter)} +`,p=`${p}Effective Singularity [for penalties]: ${d(ro(),2,!0)} `,p=`${p}Antiquity of Ant God Upgraded: ${e.runelevels[6]>0?"\u2714":"\u2716"} `);let g="";(e.ascensionCount>0||e.highestSingularityCount>0)&&(g=`===== ASCENSION ===== `,g=`${g}Ascension Count: ${d(e.ascensionCount,0,!0)} -`,g=`${g}Ascension Timer: ${Tr(e.ascensionCounter)} -`,g=`${g}Real Life Ascension Timer: ${Tr(e.ascensionCounterReal)} -`,g=`${g}Truly Real Life Ascension Timer: ${Tr(e.ascensionCounterRealReal)} -`,g=`${g}Ascension Speed Multiplier: ${d(Ur(),2,!0)} +`,g=`${g}Ascension Timer: ${kr(e.ascensionCounter)} +`,g=`${g}Real Life Ascension Timer: ${kr(e.ascensionCounterReal)} +`,g=`${g}Truly Real Life Ascension Timer: ${kr(e.ascensionCounterRealReal)} +`,g=`${g}Ascension Speed Multiplier: ${d(Rr(),2,!0)} `,g=`${g}Challenge 11 Completions: ${e.challengecompletions[11]}/${je(11)} `,g=`${g}Challenge 12 Completions: ${e.challengecompletions[12]}/${je(12)} `,g=`${g}Challenge 13 Completions: ${e.challengecompletions[13]}/${je(13)} @@ -205,8 +252,8 @@ ${d(s.goldenQuarks,0,!0)} Golden Quarks`),await P(a),e.highestSingularityCount>0 `,g=`${g}Powder: ${d(e.overfluxPowder,2,!0)} `));let m="";(e.reincarnationCount>0||e.highestSingularityCount>0)&&(m=`===== REINCARNATION ===== `,m=`${m}Reincarnation Count: ${d(e.reincarnationCount,0,!0)} -`,m=`${m}Reincarnation Timer: ${Tr(e.reincarnationcounter)} -`,m=`${m}Fastest Reincarnation: ${Tr(e.fastestreincarnate)} +`,m=`${m}Reincarnation Timer: ${kr(e.reincarnationcounter)} +`,m=`${m}Fastest Reincarnation: ${kr(e.fastestreincarnate)} `,m=`${m}Global Speed Multiplier: ${d(qe().mult,2,!0)} `,m=`${m}Challenge 6 Completions: ${e.highestchallengecompletions[6]}/${je(6)} `,m=`${m}Challenge 7 Completions: ${e.highestchallengecompletions[7]}/${je(7)} @@ -215,8 +262,8 @@ ${d(s.goldenQuarks,0,!0)} Golden Quarks`),await P(a),e.highestSingularityCount>0 `,m=`${m}Challenge 10 Completions: ${e.highestchallengecompletions[10]}/${je(10)} `);let h="";(e.transcendCount>0||e.highestSingularityCount>0)&&(h=`===== TRANSCENSION ===== `,h=`${h}Transcension Count: ${d(e.transcendCount,0,!0)} -`,h=`${h}Transcension Timer: ${Tr(e.transcendcounter)} -`,h=`${h}Fastest Transcension: ${Tr(e.fastesttranscend)} +`,h=`${h}Transcension Timer: ${kr(e.transcendcounter)} +`,h=`${h}Fastest Transcension: ${kr(e.fastesttranscend)} `,h=`${h}Challenge 1 Completions: ${e.highestchallengecompletions[1]}/${je(1)} `,h=`${h}Challenge 2 Completions: ${e.highestchallengecompletions[2]}/${je(2)} `,h=`${h}Challenge 3 Completions: ${e.highestchallengecompletions[3]}/${je(3)} @@ -224,22 +271,22 @@ ${d(s.goldenQuarks,0,!0)} Golden Quarks`),await P(a),e.highestSingularityCount>0 `,h=`${h}Challenge 5 Completions: ${e.highestchallengecompletions[5]}/${je(5)} `);let b="";(e.prestigeCount>0||e.highestSingularityCount>0)&&(b=`===== PRESTIGE & RUNES ===== `,b=`${b}Prestige Count: ${d(e.prestigeCount,0,!0)} -`,b=`${b}Prestige Timer: ${Tr(e.prestigecounter)} -`,b=`${b}Fastest Prestige: ${Tr(e.fastestprestige)} -`,b=`${b+u.t("achievements.totalPoints",{x:d(e.achievementPoints),y:d(Yn),z:(100*e.achievementPoints/Yn).toPrecision(4)})} +`,b=`${b}Prestige Timer: ${kr(e.prestigecounter)} +`,b=`${b}Fastest Prestige: ${kr(e.fastestprestige)} +`,b=`${b+u.t("achievements.totalPoints",{x:d(e.achievementPoints),y:d(aa),z:(100*e.achievementPoints/aa).toPrecision(4)})} `,b=`${b}Speed Rune: Level ${d(e.runelevels[0],0,!0)}/${d(rt(1))} [Bonus: ${d(o.rune1level-e.runelevels[0],0,!0)}] `,(e.achievements[38]>0||e.highestSingularityCount>0)&&(b=`${b}Duplication Rune: Level ${d(e.runelevels[1],0,!0)}/${d(rt(2))} [Bonus: ${d(o.rune2level-e.runelevels[1],0,!0)}] `),(e.achievements[44]>0||e.highestSingularityCount>0)&&(b=`${b}Prism Rune: Level ${d(e.runelevels[2],0,!0)}/${d(rt(3))} [Bonus: ${d(o.rune3level-e.runelevels[2],0,!0)}] `),(e.achievements[102]>0||e.highestSingularityCount>0)&&(b=`${b}Thrift Rune: Level ${d(e.runelevels[3],0,!0)}/${d(rt(4))} [Bonus: ${d(o.rune4level-e.runelevels[3],0,!0)}] `),(e.researches[82]>0||e.highestSingularityCount>0)&&(b=`${b}Superior Intellect: Level ${d(e.runelevels[4],0,!0)}/${d(rt(5))} [Bonus: ${d(o.rune5level-e.runelevels[4],0,!0)}] -`),(ha()||e.highestSingularityCount>0)&&(b=`${b}Infinite Ascent: Level ${d(e.runelevels[5],0,!0)}/${d(rt(6))} +`),(wa()||e.highestSingularityCount>0)&&(b=`${b}Infinite Ascent: Level ${d(e.runelevels[5],0,!0)}/${d(rt(6))} `),(e.platonicUpgrades[20]>0||e.highestSingularityCount>0)&&(b=`${b}Antiquities: Level ${d(e.runelevels[6],0,!0)}/${d(rt(7))} `));let C=` `;if(e.reincarnationCount>0||e.highestSingularityCount>0){C=`===== SHOP UPGRADES ===== - [\u2605]: Upgrade is MAXED - - [\u2714]: Upgrade is unlocked - - [\u2716]: Upgrade is locked - -`;let k=Object.keys(e.shopUpgrades),L=0,E=0,T=0,S=0;for(let I of k){let N=e.shopUpgrades[I],X="";pe[I].type!=="consume"&&(L+=1,hs(I)&&(E+=1),N===pe[I].maxLevel&&(T+=1)),S+=pe[I].price*N+pe[I].priceIncrease*N*(N-1)/2,X=X+(hs(I)?N===pe[I].maxLevel?"[\u2605]":"[\u2714]":"[\u2716]"),X=`${X} ${Oa(I)}:`,X=`${X} ${pe[I].type!=="consume"?`Level ${N}/${pe[I].maxLevel}`:`${N}/${pe[I].maxLevel}`}`,X=`${X} +`;let k=Object.keys(e.shopUpgrades),L=0,E=0,T=0,S=0;for(let I of k){let N=e.shopUpgrades[I],X="";pe[I].type!=="consume"&&(L+=1,xs(I)&&(E+=1),N===pe[I].maxLevel&&(T+=1)),S+=pe[I].price*N+pe[I].priceIncrease*N*(N-1)/2,X=X+(xs(I)?N===pe[I].maxLevel?"[\u2605]":"[\u2714]":"[\u2716]"),X=`${X} ${Na(I)}:`,X=`${X} ${pe[I].type!=="consume"?`Level ${N}/${pe[I].maxLevel}`:`${N}/${pe[I].maxLevel}`}`,X=`${X} `,C=C+X}C=C+a,C=`${C}Upgrades Unlocked: ${E}/${L} `,C=`${C}Upgrades MAXED ${T}/${L} `,C=`${C}Quarks Spent in Shop: ${d(S,0,!0)} @@ -264,7 +311,7 @@ ${d(s.goldenQuarks,0,!0)} Golden Quarks`),await P(a),e.highestSingularityCount>0 `,x=x+a}let B=`${t} ${r} ${n} -${s}${l}${c}${p}${g}${m}${h}${b}${C}${v}${x}`;try{await navigator.clipboard.writeText(B)}catch(k){let L=document.createElement("textarea");L.setAttribute("style","top: 0; left: 0; position: fixed;"),L.setAttribute("data-clipboard-text",B),document.body.appendChild(L),L.focus(),L.select();let E=new H0.default(L),T=()=>{E.destroy(),document.body.removeChild(L)};E.on("success",()=>{document.getElementById("exportinfo").textContent="Copied save to clipboard!",T()}),E.on("error",()=>{P("Unable to write the save to clipboard.").finally(T)})}let U=document.createElement("a");return U.setAttribute("href",`data:text/plain;charset=utf-8,${encodeURIComponent(B)}`),U.setAttribute("download",`Statistics-${qo()}`),U.setAttribute("id","downloadSave"),document.body.appendChild(U),U.click(),document.body.removeChild(U),P("Summary Stats saved to clipboard! We also gave you a file, for easy sharing, if that is available on your browser.")};var Q0=()=>{let t=["null","first","second","third","fourth","fifth","sixth","seventh","eighth"];if(!1){let w=document.createElement("button"),H=document.createElement("button");w.textContent="Click here to warp time! [TESTING ONLY]",w.setAttribute("style","width: auto; height: 30px; border: 6px solid gold;"),w.addEventListener("click",()=>U0()),H.textContent="Click to force a new day! [TESTING ONLY]",H.setAttribute("style","width: auto; height: 30px; border: 6px solid orange;"),H.addEventListener("click",()=>ro());let J=i("actualConsumables");J.appendChild(w),J.appendChild(H)}i("exitOffline").addEventListener("click",()=>Ds()),i("offlineContainer").addEventListener("dblclick",()=>Ds()),i("ascCubeStats").addEventListener("click",()=>Zr(1)),i("ascTessStats").addEventListener("click",()=>Zr(2)),i("ascHyperStats").addEventListener("click",()=>Zr(3)),i("ascPlatonicStats").addEventListener("click",()=>Zr(4)),i("ascHepteractStats").addEventListener("click",()=>Zr(5)),i("ascTimeTakenStats").addEventListener("click",()=>Zr(6)),i("prestigebtn").addEventListener("mouseover",()=>at("prestige")),i("transcendbtn").addEventListener("mouseover",()=>at("transcension")),i("reincarnatebtn").addEventListener("mouseover",()=>at("reincarnation")),i("acceleratorboostbtn").addEventListener("mouseover",()=>at("acceleratorBoost")),i("challengebtn").addEventListener("mouseover",()=>at("transcensionChallenge")),i("reincarnatechallengebtn").addEventListener("mouseover",()=>at("reincarnationChallenge")),i("ascendChallengeBtn").addEventListener("mouseover",()=>at("ascensionChallenge")),i("ascendbtn").addEventListener("mouseover",()=>at("ascension")),i("singularitybtn").addEventListener("mouseover",()=>at("singularity"));for(let w of Array.from(document.getElementsByClassName("resetbtn")))w.addEventListener("mouseover",()=>{w.classList.add("hover")}),w.addEventListener("mouseout",()=>{w.classList.remove("hover"),e.currentChallenge.reincarnation?at("reincarnationChallenge"):e.currentChallenge.transcension&&at("transcensionChallenge")});i("prestigebtn").addEventListener("click",()=>Ae("prestige")),i("transcendbtn").addEventListener("click",()=>Ae("transcension")),i("reincarnatebtn").addEventListener("click",()=>Ae("reincarnation")),i("acceleratorboostbtn").addEventListener("click",()=>Fa()),i("challengebtn").addEventListener("click",()=>Ae("transcensionChallenge",void 0,!0)),i("reincarnatechallengebtn").addEventListener("click",()=>Ae("reincarnationChallenge",void 0,!0)),i("ascendChallengeBtn").addEventListener("click",()=>Ae("ascensionChallenge")),i("ascendbtn").addEventListener("click",()=>Ae("ascension")),i("singularitybtn").addEventListener("click",()=>Ae("singularity"));let r=["Coin","Diamond","Mythos","Particle","Tesseract"];for(let w=0;wve(0,{page:w}));let n=["coin","crystal","mythos","particle","tesseract","offering"],a=["one","ten","hundred","thousand","10k","100k"],s=[1,10,100,1e3,1e4,1e5];for(let w=0;wFm(s[w],n[H]));i("buyaccelerator").addEventListener("click",()=>Ss()),i("buymultiplier").addEventListener("click",()=>ks()),i("buyacceleratorboost").addEventListener("click",()=>Fa());let l=["coin","diamond","mythos"],c=["Coin","Diamonds","Mythos"];for(let w=0;w<3;w++)for(let H=1;H<=5;H++)i(`buy${l[w]}${H}`).addEventListener("click",()=>wf(t[H],c[w],w===0?H:H*(H+1)/2));for(let w=1;w<=5;w++)i(`buycrystalupgrade${w}`).addEventListener("mouseover",()=>Ei(w)),i(`buycrystalupgrade${w}`).addEventListener("click",()=>zt(w));for(let w=0;w<5;w++)i(`buyparticles${w+1}`).addEventListener("click",()=>wn(w+1));for(let w=0;w<5;w++)i(`buyTesseracts${w+1}`).addEventListener("click",()=>Da(w+1)),i(`tesseractAutoToggle${w+1}`).addEventListener("click",()=>cf(w+1));for(let w=0;w<10;w++)i(`buyConstantUpgrade${w+1}`).addEventListener("mouseover",()=>Hc(w+1)),i(`buyConstantUpgrade${w+1}`).addEventListener("click",()=>to(w+1));document.querySelectorAll(".auto[toggleid]").forEach(w=>w.addEventListener("click",()=>Hm(w))),i("prestigeautotoggle").addEventListener("click",()=>Po(1)),i("transcendautotoggle").addEventListener("click",()=>Po(2)),i("reincarnateautotoggle").addEventListener("click",()=>Po(3)),i("tesseractautobuymode").addEventListener("click",()=>Po(4)),i("prestigeamount").addEventListener("blur",()=>mr(1)),i("transcendamount").addEventListener("blur",()=>mr(2)),i("reincarnationamount").addEventListener("blur",()=>mr(3)),i("ascensionAmount").addEventListener("blur",()=>mr(4)),i("autoAntSacrificeAmount").addEventListener("blur",()=>mr(5)),i("tesseractautobuytoggle").addEventListener("click",()=>Qm()),i("tesseractAmount").addEventListener("blur",()=>vl()),i("cubeOpensInput").addEventListener("blur",()=>Yr(1)),i("tesseractsOpensInput").addEventListener("blur",()=>Yr(2)),i("hypercubesOpensInput").addEventListener("blur",()=>Yr(3)),i("platonicCubeOpensInput").addEventListener("blur",()=>Yr(4)),i("openCubes").addEventListener("click",()=>Eo(1)),i("openTesseracts").addEventListener("click",()=>Eo(2)),i("openHypercubes").addEventListener("click",()=>Eo(3)),i("openPlatonicCube").addEventListener("click",()=>Eo(4));for(let w=1;w<=125;w++)i(`upg${w}`).addEventListener("mouseover",()=>Mg(w));for(let w=1;w<=125;w++)i(`upg${w}`).addEventListener("click",()=>pa(w,!1));for(let w=1;w<=6;w++)i(`upgrades${w}`).addEventListener("click",()=>Js(w,!1));i("coinAutoUpgrade").addEventListener("click",()=>Vn("coin")),i("prestigeAutoUpgrade").addEventListener("click",()=>Vn("prestige")),i("transcendAutoUpgrade").addEventListener("click",()=>Vn("transcend")),i("generatorsAutoUpgrade").addEventListener("click",()=>Vn("generators")),i("reincarnateAutoUpgrade").addEventListener("click",()=>Vn("reincarnate"));for(let w=1;w<=_s.length-1;w++)i(`ach${w}`).addEventListener("mouseover",()=>L0(w));i("toggleautosacrifice").addEventListener("click",()=>Tu(0));for(let w=0;w<4;w++)i(`toggleRuneSubTab${w+1}`).addEventListener("click",()=>ve(3,{page:w}));for(let w=0;w<7;w++)i(`rune${w+1}`).addEventListener("mouseover",()=>Rt(w+1)),i(`rune${w+1}`).addEventListener("click",()=>Tu(w+1)),i(`activaterune${w+1}`).addEventListener("mouseover",()=>Rt(w+1)),i(`activaterune${w+1}`).addEventListener("click",()=>fa(w+1));let g=[10,25,50,100],m=["Ten","TwentyFive","Fifty","Hundred"];for(let w=0;wbs(g[w]));i("toggleautoBuyFragments").addEventListener("click",()=>Wm()),i("toggleautoenhance").addEventListener("click",()=>Ym()),i("toggleautofortify").addEventListener("click",()=>Zm());let h=["shard","commonFragment","uncommonFragment","rareFragment","epicFragment","legendaryFragment","mythicalFragment"];for(let w=0;wQi(h[w])),i(`buyTalismanItem${w+1}`).addEventListener("click",()=>ou(h[w]));i("buyTalismanAll").addEventListener("mouseover",()=>Qi(null)),i("buyTalismanAll").addEventListener("click",()=>qi());for(let w=0;w<7;w++)i(`talisman${w+1}`).addEventListener("click",()=>ji(w)),i(`leveluptalisman${w+1}`).addEventListener("mouseover",()=>iu(w)),i(`leveluptalisman${w+1}`).addEventListener("click",()=>Vi(w)),i(`enhancetalisman${w+1}`).addEventListener("mouseover",()=>lu(w)),i(`enhancetalisman${w+1}`).addEventListener("click",()=>Wi(w)),i(`respectalisman${w+1}`).addEventListener("click",()=>cu(w));i("respecAllTalismans").addEventListener("click",()=>cu(7)),i("confirmTalismanRespec").addEventListener("click",()=>am(o.talismanRespec)),i("cancelTalismanRespec").addEventListener("click",()=>sm(o.talismanRespec));for(let w=0;w<5;w++)i(`talismanRespecButton${w+1}`).addEventListener("click",()=>nm(w+1));for(let w=0;w<5;w++)i(`runeBlessingPurchase${w+1}`).addEventListener("click",()=>Ls("Blessings",w+1)),i(`runeSpiritPurchase${w+1}`).addEventListener("click",()=>Ls("Spirits",w+1));i("buyRuneBlessingInput").addEventListener("blur",()=>Ms(1)),i("buyRuneSpiritInput").addEventListener("blur",()=>Ms(2)),i("buyAllBlessings").addEventListener("click",()=>Ps("Blessings")),i("buyAllSpirits").addEventListener("click",()=>Ps("Spirits"));for(let w=0;w<15;w++)i(`challenge${w+1}`).addEventListener("click",()=>ot(w+1)),i(`challenge${w+1}`).addEventListener("dblclick",()=>{ot(w+1),gr(o.triggerChallenge,!1)});i("startChallenge").addEventListener("click",()=>gr(o.triggerChallenge,!1)),i("retryChallenge").addEventListener("click",()=>I0()),i("toggleAutoChallengeIgnore").addEventListener("click",()=>lf(o.triggerChallenge)),i("toggleAutoChallengeStart").addEventListener("click",()=>Ao()),i("startAutoChallengeTimerInput").addEventListener("input",()=>Wn(1)),i("exitAutoChallengeTimerInput").addEventListener("input",()=>Wn(2)),i("enterAutoChallengeTimerInput").addEventListener("input",()=>Wn(3));for(let w=0;w<2;w++)i(`toggleChallengesSubTab${w+1}`).addEventListener("click",()=>ve(4,{page:w}));for(let w=1;w<200;w++)i(`res${w}`).addEventListener("click",()=>Fr(w)),i(`res${w}`).addEventListener("mouseover",()=>Ai(w));i("res200").addEventListener("click",()=>Fr(200,!1,.01)),i("res200").addEventListener("mouseover",()=>Ai(200,!1,.01)),i("toggleresearchbuy").addEventListener("click",()=>qm()),i("toggleautoresearch").addEventListener("click",()=>jm()),i("toggleautoresearchmode").addEventListener("click",()=>Vm());let b=["null","1e700","3","100","10000","1e12","1e36","1e100","1e300"];for(let w=1;w<=8;w++)i(`anttier${w}`).addEventListener("mouseover",()=>Vu(w)),i(`anttier${w}`).addEventListener("mouseover",()=>Yf(w)),i(`anttier${w}`).addEventListener("click",()=>Wu(t[w],b[w],w));let C=["null","100","100","1000","1000","1e5","1e6","1e8","1e11","1e15","1e20","1e40","1e100"];for(let w=1;w<=12;w++)i(`antUpgrade${w}`).addEventListener("mouseover",()=>zu(w)),i(`antUpgrade${w}`).addEventListener("click",()=>Ku(C[w],!1,w));i("antSacrifice").addEventListener("click",()=>As()),i("toggleAntMax").addEventListener("click",()=>gl()),i("toggleAutoSacrificeAnt").addEventListener("click",()=>ws(0)),i("autoSacrificeAntMode").addEventListener("click",()=>ws(1));for(let w=0;w<7;w++)i(`switchCubeSubTab${w+1}`).addEventListener("click",()=>ve(7,{page:w}));for(let w=1;wQc(w)),i(`cubeUpg${w}`).addEventListener("click",()=>jc(w));i("toggleCubeBuy").addEventListener("click",()=>sf()),i("toggleAutoCubeUpgrades").addEventListener("click",()=>ml()),i("open1Cube").addEventListener("click",()=>e.wowCubes.open(1,!1)),i("open20Cube").addEventListener("click",()=>e.wowCubes.open(Math.floor(Number(e.wowCubes)/10),!1)),i("open1000Cube").addEventListener("click",()=>e.wowCubes.open(Math.floor(Number(e.wowCubes)/2),!1)),i("openCustomCube").addEventListener("click",()=>e.wowCubes.openCustom()),i("openMostCube").addEventListener("click",()=>e.wowCubes.open(0,!0)),i("open1Tesseract").addEventListener("click",()=>e.wowTesseracts.open(1,!1)),i("open20Tesseract").addEventListener("click",()=>e.wowTesseracts.open(Math.floor(Number(e.wowTesseracts)/10),!1)),i("open1000Tesseract").addEventListener("click",()=>e.wowTesseracts.open(Math.floor(Number(e.wowTesseracts)/2),!1)),i("openCustomTesseract").addEventListener("click",()=>e.wowTesseracts.openCustom()),i("openMostTesseract").addEventListener("click",()=>e.wowTesseracts.open(1,!0)),i("open1Hypercube").addEventListener("click",()=>e.wowHypercubes.open(1,!1)),i("open20Hypercube").addEventListener("click",()=>e.wowHypercubes.open(Math.floor(Number(e.wowHypercubes)/10),!1)),i("open1000Hypercube").addEventListener("click",()=>e.wowHypercubes.open(Math.floor(Number(e.wowHypercubes)/2),!1)),i("openCustomHypercube").addEventListener("click",()=>e.wowHypercubes.openCustom()),i("openMostHypercube").addEventListener("click",()=>e.wowHypercubes.open(1,!0)),i("open1PlatonicCube").addEventListener("click",()=>e.wowPlatonicCubes.open(1,!1)),i("open40kPlatonicCube").addEventListener("click",()=>e.wowPlatonicCubes.open(Math.floor(Number(e.wowPlatonicCubes)/10),!1)),i("open1mPlatonicCube").addEventListener("click",()=>e.wowPlatonicCubes.open(Math.floor(Number(e.wowPlatonicCubes)/2),!1)),i("openCustomPlatonicCube").addEventListener("click",()=>e.wowPlatonicCubes.openCustom()),i("openMostPlatonicCube").addEventListener("click",()=>e.wowPlatonicCubes.open(1,!0)),i("saveOffToggle").addEventListener("click",()=>Jm());let v=document.getElementsByClassName("platonicUpgradeImage");for(let w=0;wzc(w+1)),v[w].addEventListener("click",()=>Xc(w+1));i("toggleAutoPlatonicUpgrades").addEventListener("click",()=>fl()),i("chronosHepteract").addEventListener("mouseover",()=>sn("chronos")),i("hyperrealismHepteract").addEventListener("mouseover",()=>sn("hyperrealism")),i("quarkHepteract").addEventListener("mouseover",()=>sn("quark")),i("challengeHepteract").addEventListener("mouseover",()=>sn("challenge")),i("abyssHepteract").addEventListener("mouseover",()=>sn("abyss")),i("acceleratorHepteract").addEventListener("mouseover",()=>sn("accelerator")),i("acceleratorBoostHepteract").addEventListener("mouseover",()=>sn("acceleratorBoost")),i("multiplierHepteract").addEventListener("mouseover",()=>sn("multiplier")),i("chronosHepteractCraft").addEventListener("click",()=>e.hepteractCrafts.chronos.craft()),i("hyperrealismHepteractCraft").addEventListener("click",()=>e.hepteractCrafts.hyperrealism.craft()),i("quarkHepteractCraft").addEventListener("click",()=>e.hepteractCrafts.quark.craft()),i("challengeHepteractCraft").addEventListener("click",()=>e.hepteractCrafts.challenge.craft()),i("abyssHepteractCraft").addEventListener("click",()=>e.hepteractCrafts.abyss.craft()),i("acceleratorHepteractCraft").addEventListener("click",()=>e.hepteractCrafts.accelerator.craft()),i("acceleratorBoostHepteractCraft").addEventListener("click",()=>e.hepteractCrafts.acceleratorBoost.craft()),i("multiplierHepteractCraft").addEventListener("click",()=>e.hepteractCrafts.multiplier.craft()),i("chronosHepteractCraftMax").addEventListener("click",()=>e.hepteractCrafts.chronos.craft(!0)),i("hyperrealismHepteractCraftMax").addEventListener("click",()=>e.hepteractCrafts.hyperrealism.craft(!0)),i("quarkHepteractCraftMax").addEventListener("click",()=>e.hepteractCrafts.quark.craft(!0)),i("challengeHepteractCraftMax").addEventListener("click",()=>e.hepteractCrafts.challenge.craft(!0)),i("abyssHepteractCraftMax").addEventListener("click",()=>e.hepteractCrafts.abyss.craft(!0)),i("acceleratorHepteractCraftMax").addEventListener("click",()=>e.hepteractCrafts.accelerator.craft(!0)),i("acceleratorBoostHepteractCraftMax").addEventListener("click",()=>e.hepteractCrafts.acceleratorBoost.craft(!0)),i("multiplierHepteractCraftMax").addEventListener("click",()=>e.hepteractCrafts.multiplier.craft(!0)),i("chronosHepteractCap").addEventListener("click",()=>e.hepteractCrafts.chronos.expand()),i("hyperrealismHepteractCap").addEventListener("click",()=>e.hepteractCrafts.hyperrealism.expand()),i("quarkHepteractCap").addEventListener("click",()=>e.hepteractCrafts.quark.expand()),i("challengeHepteractCap").addEventListener("click",()=>e.hepteractCrafts.challenge.expand()),i("abyssHepteractCap").addEventListener("click",()=>e.hepteractCrafts.abyss.expand()),i("acceleratorHepteractCap").addEventListener("click",()=>e.hepteractCrafts.accelerator.expand()),i("acceleratorBoostHepteractCap").addEventListener("click",()=>e.hepteractCrafts.acceleratorBoost.expand()),i("multiplierHepteractCap").addEventListener("click",()=>e.hepteractCrafts.multiplier.expand()),i("chronosHepteractAuto").addEventListener("click",()=>e.hepteractCrafts.chronos.toggleAutomatic()),i("hyperrealismHepteractAuto").addEventListener("click",()=>e.hepteractCrafts.hyperrealism.toggleAutomatic()),i("quarkHepteractAuto").addEventListener("click",()=>e.hepteractCrafts.quark.toggleAutomatic()),i("challengeHepteractAuto").addEventListener("click",()=>e.hepteractCrafts.challenge.toggleAutomatic()),i("abyssHepteractAuto").addEventListener("click",()=>e.hepteractCrafts.abyss.toggleAutomatic()),i("acceleratorHepteractAuto").addEventListener("click",()=>e.hepteractCrafts.accelerator.toggleAutomatic()),i("acceleratorBoostHepteractAuto").addEventListener("click",()=>e.hepteractCrafts.acceleratorBoost.toggleAutomatic()),i("multiplierHepteractAuto").addEventListener("click",()=>e.hepteractCrafts.multiplier.toggleAutomatic()),i("hepteractToQuark").addEventListener("mouseover",()=>Pg()),i("hepteractToQuarkTrade").addEventListener("click",()=>Vc()),i("hepteractToQuarkTradeMax").addEventListener("click",()=>Vc(!0)),i("hepteractToQuarkTradeAuto").addEventListener("click",()=>Ri()),i("overfluxPowder").addEventListener("mouseover",()=>Ag()),i("powderDayWarp").addEventListener("click",()=>Wc(!1)),i("warpAuto").addEventListener("click",()=>Wc(!0)),i("hepteractAutoPercentageButton").addEventListener("click",()=>df()),i("corrStatsBtn").addEventListener("click",()=>ve(8,{page:0})),i("corrLoadoutsBtn").addEventListener("click",()=>ve(8,{page:1})),i("corruptionDisplays").addEventListener("click",()=>Na(10)),i("corruptionCleanse").addEventListener("click",()=>C0()),i("corruptionCleanseConfirm").addEventListener("click",()=>hn(10,999)),i("ascensionAutoEnable").addEventListener("click",()=>xs(0)),i("ascensionAutoToggle").addEventListener("click",()=>xs(1));let x=Array.from(document.querySelectorAll('[id^="switchSettingSubTab"]'));for(let w of x)w.addEventListener("click",()=>ve(10,{page:x.indexOf(w)}));let B=Array.from(document.querySelectorAll("button.statsNerds"));for(let w of B)w.addEventListener("click",H=>Sm(H.target));i("summaryGeneration").addEventListener("click",()=>F0()),i("exportgame").addEventListener("click",()=>o0()),i("saveStringInput").addEventListener("blur",w=>s0(w.target)),i("savegame").addEventListener("click",()=>hr(!0)),i("deleteGame").addEventListener("click",()=>Ju(!1)),i("preloadDeleteGame").addEventListener("click",()=>i0()),i("promocodes").addEventListener("click",()=>l0()),i("addCodeBox").addEventListener("mouseover",()=>jo("add")),i("addCode").addEventListener("click",()=>xn("add")),i("addCodeAll").addEventListener("click",()=>xn("add",qn())),i("addCodeOne").addEventListener("click",()=>xn("add",1)),i("dailyCode").addEventListener("click",()=>xn("daily")),i("dailyCode").addEventListener("mouseover",()=>jo("daily")),i("timeCode").addEventListener("click",()=>xn("time")),i("timeCode").addEventListener("mouseover",()=>jo("time")),i("historyTogglePerSecondButton").addEventListener("click",()=>G0()),i("resetHotkeys").addEventListener("click",()=>Sf()),i("notation").addEventListener("click",()=>om()),i("iconSet").addEventListener("click",()=>Xi(e.iconSet+1)),i("resetShopUpgrades").addEventListener("click",()=>Hi()),i("toggleConfirmShop").addEventListener("click",()=>rf()),i("toggleBuyMaxShop").addEventListener("click",w=>nf(w)),i("toggleHideShop").addEventListener("click",()=>af()),i("offeringPotions").addEventListener("mouseover",()=>cr("offeringPotion")),i("offeringpotionowned").addEventListener("mouseover",()=>cr("offeringPotion")),i("buyofferingpotion").addEventListener("mouseover",()=>cr("offeringPotion")),i("useofferingpotion").addEventListener("mouseover",()=>cr("offeringPotion")),i("buyofferingpotion").addEventListener("click",()=>Gi("offeringPotion")),i("useofferingpotion").addEventListener("click",()=>gn("offeringPotion")),i("toggle42").addEventListener("click",()=>{e.autoPotionTimer=0}),i("obtainiumPotions").addEventListener("mouseover",()=>cr("obtainiumPotion")),i("obtainiumpotionowned").addEventListener("mouseover",()=>cr("obtainiumPotion")),i("buyobtainiumpotion").addEventListener("mouseover",()=>cr("obtainiumPotion")),i("useobtainiumpotion").addEventListener("mouseover",()=>cr("obtainiumPotion")),i("buyobtainiumpotion").addEventListener("click",()=>Gi("obtainiumPotion")),i("useobtainiumpotion").addEventListener("click",()=>gn("obtainiumPotion")),i("toggle43").addEventListener("click",()=>{e.autoPotionTimerObtainium=0});let U=Object.keys(e.shopUpgrades);for(let w of U)pe[w].type==="upgrade"&&(i(`${w}`).addEventListener("mouseover",()=>cr(w)),i(`${w}Level`).addEventListener("mouseover",()=>cr(w)),i(`${w}Button`).addEventListener("mouseover",()=>cr(w)),i(`${w}Button`).addEventListener("click",()=>Gi(w)));i("buySingularityQuarksButton").addEventListener("click",()=>hg());let k=Object.keys(e.singularityUpgrades);for(let w of k)w!=="offeringAutomatic"&&(i(`${String(w)}`).addEventListener("mouseover",()=>e.singularityUpgrades[`${String(w)}`].updateUpgradeHTML()),i(`${String(w)}`).addEventListener("click",H=>e.singularityUpgrades[`${String(w)}`].buyLevel(H)));i("actualSingularityUpgradeContainer").addEventListener("mouseover",()=>So(!0)),i("actualSingularityUpgradeContainer").addEventListener("mouseout",()=>So(!1));let L=i("singularityPerksIcon"),E=i("singularityPerksText"),T=i("singularityPerksDesc");for(let w of Ec){let H=document.createElement("span");H.innerHTML=`${w.name()}`,H.id=w.ID,H.classList.add("oldPerk"),H.style.display="none",i("singularityPerksGrid").append(H),i(w.ID).addEventListener("mouseover",()=>{let J=Uc(w,e.highestSingularityCount),Te=u.t("singularity.perks.levelInfo",{level:J.level,singularity:J.singularity});L.src=`Pictures/${Be[e.iconSet][0]}/perk${w.ID}.png`,E.innerHTML=Te,T.innerHTML=w.description(e.highestSingularityCount,w.levels)})}let S=Object.keys(e.octeractUpgrades);for(let w of S)i(`${String(w)}`).addEventListener("mouseover",()=>e.octeractUpgrades[`${String(w)}`].updateUpgradeHTML()),i(`${String(w)}`).addEventListener("click",H=>e.octeractUpgrades[`${String(w)}`].buyLevel(H));i("octeractUpgradeContainer").addEventListener("mouseover",()=>So(!0)),i("octeractUpgradeContainer").addEventListener("mouseout",()=>So(!1));let I=Object.keys(e.singularityChallenges);for(let w of I)i(`${String(w)}`).addEventListener("mouseover",()=>e.singularityChallenges[`${String(w)}`].updateChallengeHTML()),i(`${String(w)}`).addEventListener("click",()=>e.singularityChallenges[`${String(w)}`].challengeEntryHandler());let N=Object.keys(e.blueberryUpgrades);for(let w of N)i(`${String(w)}`).addEventListener("mouseover",()=>e.blueberryUpgrades[`${String(w)}`].updateUpgradeHTML()),i(`${String(w)}`).addEventListener("click",H=>e.blueberryUpgrades[`${String(w)}`].buyLevel(H));let X=Array.from(document.querySelectorAll('[id^="blueberryLoadout"]')),re=i("blueberryUpgradeContainer");for(let w=0;w{var Te;Il(H,(Te=e.blueberryLoadouts[H])!=null?Te:{ambrosiaTutorial:0}),re.classList.add(`hoveredBlueberryLoadout${H}`)}),J.addEventListener("mouseout",()=>{re.classList.remove(`hoveredBlueberryLoadout${H}`)}),J.addEventListener("click",()=>{var Te;return f0(H,(Te=e.blueberryLoadouts[H])!=null?Te:{ambrosiaTutorial:0})})}i("blueberryToggleMode").addEventListener("click",()=>pf()),i("getBlueberries").addEventListener("click",()=>p0()),i("refundBlueberries").addEventListener("click",()=>rd()),i("importBlueberries").addEventListener("change",w=>ed(w,m0));for(let w=0;w<4;w++)i(`toggleSingularitySubTab${w+1}`).addEventListener("click",()=>ve(9,{page:w}));i("unsmith").addEventListener("click",()=>Tm()),i("importfile").addEventListener("change",w=>ed(w,Ra));for(let w=1;w<=5;w++)i(`switchTheme${w}`).addEventListener("click",()=>zi(!1,w,!0));i("saveType").addEventListener("click",async w=>{let H=w.target;if(!H.checked){localStorage.removeItem("copyToClipboard"),w.stopPropagation();return}w.preventDefault(),await we(u.t("save.saveToClipboard"))?(H.checked=!H.checked,localStorage.setItem("copyToClipboard","")):localStorage.removeItem("copyToClipboard")}),window.addEventListener("error",lm,{capture:!0})};var q0=()=>{let t=1,r=new f(0),n=new f(0);o.produceFirst=e.firstGeneratedCoin.add(e.firstOwnedCoin).times(o.globalCoinMultiplier).times(o.coinOneMulti).times(e.firstProduceCoin),o.produceSecond=e.secondGeneratedCoin.add(e.secondOwnedCoin).times(o.globalCoinMultiplier).times(o.coinTwoMulti).times(e.secondProduceCoin),o.produceThird=e.thirdGeneratedCoin.add(e.thirdOwnedCoin).times(o.globalCoinMultiplier).times(o.coinThreeMulti).times(e.thirdProduceCoin),o.produceFourth=e.fourthGeneratedCoin.add(e.fourthOwnedCoin).times(o.globalCoinMultiplier).times(o.coinFourMulti).times(e.fourthProduceCoin),o.produceFifth=e.fifthGeneratedCoin.add(e.fifthOwnedCoin).times(o.globalCoinMultiplier).times(o.coinFiveMulti).times(e.fifthProduceCoin),o.produceTotal=o.produceFirst.add(o.produceSecond).add(o.produceThird).add(o.produceFourth).add(o.produceFifth),o.produceFirst.lte(1e-4)&&(o.produceFirst=new f(0)),o.produceSecond.lte(1e-4)&&(o.produceSecond=new f(0)),o.produceThird.lte(1e-4)&&(o.produceThird=new f(0)),o.produceFourth.lte(1e-4)&&(o.produceFourth=new f(0)),o.produceFifth.lte(1e-4)&&(o.produceFifth=new f(0)),o.producePerSecond=o.produceTotal.times(40),e.currentChallenge.reincarnation===6&&(t=3*Math.pow(1+e.challengecompletions[6]/25,2)),e.currentChallenge.reincarnation===9&&(t=.005),e.currentChallenge.ascension===15&&(t=5e-6);let a=Math.max(0,ae(e.challengecompletions)-e.challengecompletions[11]-e.challengecompletions[12]-e.challengecompletions[13]-e.challengecompletions[14]-e.challengecompletions[15]-3*e.cubeUpgrades[49]-(e.singularityCount>=15?4:0)-(e.singularityCount>=20?1:0));e.currentChallenge.ascension===13&&(t*=700*(1+1/6*e.challengecompletions[13]),t*=Math.pow(1.05,a)),e.challengecompletions[6]>0&&(t/=1.075);let s=1;s*=t,s*=1-1/20*e.researches[51]-1/40*e.researches[52]-1/80*e.researches[53]-1/160*e.researches[54]-1/320*e.researches[55],s*=1-.05/1800*(e.achievements[45]+e.achievements[46]+2*e.achievements[47])*Math.min(e.prestigecounter,1800),s*=Math.pow(.965,_("reincarnation",e.challengecompletions[6])),s*=.001+.999*Math.pow(6,-(o.rune2level*o.effectiveLevelMult)/1e3),s*=.01+.99*Math.pow(4,Math.min(0,(400-o.rune4level)/1100)),s*=1-.04*e.achievements[82]-.04*e.achievements[89]-.04*e.achievements[96]-.04*e.achievements[103]-.04*e.achievements[110]-.0566*e.achievements[117]-.0566*e.achievements[124]-.0566*e.achievements[131],s*=Math.pow(.9925,e.achievements[118]*(e.challengecompletions[6]+e.challengecompletions[7]+e.challengecompletions[8]+e.challengecompletions[9]+e.challengecompletions[10])),s*=.005+.995*Math.pow(.99,e.antUpgrades[2]+o.bonusant3),s*=1/Math.pow(1+f.log(e.ascendShards.add(1),10),1+.2/60*e.challengecompletions[10]*e.upgrades[125]+.1*e.platonicUpgrades[5]+.2*e.platonicUpgrades[10]+(o.platonicBonusMultiplier[5]-1)),s*=1-.1*(e.talismanRarity[1-1]-1),s*=Math.pow(.98,3/5*Math.log(1+e.rareFragments)/Math.log(10)*e.researches[159]),s*=Math.pow(.966,_("ascension",e.challengecompletions[13])),s*=1-.666*e.researches[200]/1e5,s*=1-.666*e.cubeUpgrades[50]/1e5,s*=o.challenge15Rewards.taxes,e.upgrades[121]>0&&(s*=.5),s<1e-300&&(s=1e-300),o.maxexponent=Math.floor(275/(f.log(1.01,10)*s))-1;let l=Math.min(o.maxexponent,Math.floor(f.log(o.produceTotal.add(1),10)));e.currentChallenge.ascension===13&&o.maxexponent<=99999&&e.achievements[249]<1&&a>=1&&R(249),l>=1&&(r=f.pow(l,2).div(550)),n=f.pow(o.maxexponent,2).div(550),o.taxdivisor=f.pow(1.01,f.mul(r,s)),o.taxdivisorcheck=f.pow(1.01,f.mul(n,s))};var j0={type:"postProcessor",name:"ColorText",process:t=>t.includes("<<")?t.replace(/<<(.*?)\|(.*?)>>/g,'$2'):t};var Ed={en:{name:"English",flag:"\u{1F1FA}\u{1F1F8}"},zh:{name:"Chinese",flag:"\u{1F1E8}\u{1F1F3}"},fr:{name:"French",flag:"\u{1F3F3}\uFE0F"},de:{name:"German",flag:"\u{1F1E9}\u{1F1EA}"},pl:{name:"Polish",flag:"\u{1F1F5}\u{1F1F1}"},es:{name:"Spanish",flag:"\u{1F1EA}\u{1F1F8}"},ru:{name:"Russian",flag:"\u{1F1F7}\u{1F1FA}"}},Vl=new Map,V0=async()=>{var s;let t={},r=(s=localStorage.getItem("language"))!=null?s:"en",a=await(await fetch(`./translations/${r}.json`)).json();if(Vl.set(r,{translation:a}),t[r]={translation:a},r!=="en"){let c=await(await fetch("./translations/en.json")).json();Vl.set("en",{translation:c}),t.en={translation:c}}await u.use(j0).init({lng:r,fallbackLng:"en",debug:!Dr,resources:t,postProcess:["ColorText"],returnEmptyString:!1,interpolation:{escapeValue:!1}}),e2(),t2()};function JC(t,r,n){let a=document.createElement("button");a.id=`language_${t}`,a.className="language-select",a.addEventListener("click",async()=>{if(!Vl.has(t)){let g=await(await fetch(`./translations/${t}.json`)).json();Vl.set(t,{translation:g}),u.addResourceBundle(t,"translation",g)}await u.changeLanguage(t),localStorage.setItem("language",t),await we(u.t("general.languageChange"))&&location.reload()});let s=document.createElement("span");s.className="lang-flag",s.textContent=n,a.appendChild(s);let l=document.createElement("span");return l.className="lang-name",l.textContent=r,a.appendChild(l),a}function e2(){let t=i("languageOptions");for(let r in Ed){let n=JC(r,Ed[r].name,Ed[r].flag);t.appendChild(n)}}function t2(){let t=document.querySelectorAll("*[i18n]");for(let r of Array.from(t)){let n=r.getAttribute("i18n"),a=u.t(n);a.includes("[r+1,!1])),loaded1009:!0,loaded1009hotfix1:!0,loaded10091:!0,loaded1010:!0,loaded10101:!0,shopUpgrades:{offeringPotion:1,obtainiumPotion:1,offeringEX:0,offeringAuto:0,obtainiumEX:0,obtainiumAuto:0,instantChallenge:0,antSpeed:0,cashGrab:0,shopTalisman:0,seasonPass:0,challengeExtension:0,challengeTome:0,cubeToQuark:0,tesseractToQuark:0,hypercubeToQuark:0,seasonPass2:0,seasonPass3:0,chronometer:0,infiniteAscent:0,calculator:0,calculator2:0,calculator3:0,calculator4:0,calculator5:0,calculator6:0,calculator7:0,constantEX:0,powderEX:0,chronometer2:0,chronometer3:0,seasonPassY:0,seasonPassZ:0,challengeTome2:0,instantChallenge2:0,cashGrab2:0,chronometerZ:0,cubeToQuarkAll:0,offeringEX2:0,obtainiumEX2:0,seasonPassLost:0,powderAuto:0,challenge15Auto:0,extraWarp:0,autoWarp:0,improveQuarkHept:0,improveQuarkHept2:0,improveQuarkHept3:0,improveQuarkHept4:0,shopImprovedDaily:0,shopImprovedDaily2:0,shopImprovedDaily3:0,shopImprovedDaily4:0,offeringEX3:0,obtainiumEX3:0,improveQuarkHept5:0,seasonPassInfinity:0,chronometerInfinity:0,shopSingularityPenaltyDebuff:0,shopAmbrosiaLuckMultiplier4:0,shopOcteractAmbrosiaLuck:0,shopAmbrosiaGeneration1:0,shopAmbrosiaGeneration2:0,shopAmbrosiaGeneration3:0,shopAmbrosiaGeneration4:0,shopAmbrosiaLuck1:0,shopAmbrosiaLuck2:0,shopAmbrosiaLuck3:0,shopAmbrosiaLuck4:0,shopCashGrabUltra:0,shopAmbrosiaAccelerator:0,shopEXUltra:0,shopChronometerS:0,shopAmbrosiaUltra:0,shopSingularitySpeedup:0,shopSingularityPotency:0,shopSadisticRune:0},shopBuyMaxToggle:!1,shopHideToggle:!1,shopConfirmationToggle:!0,autoPotionTimer:0,autoPotionTimerObtainium:0,autoSacrificeToggle:!1,autoBuyFragment:!1,autoFortifyToggle:!1,autoEnhanceToggle:!1,autoResearchToggle:!1,researchBuyMaxToggle:!1,autoResearchMode:"manual",autoResearch:0,autoSacrifice:0,sacrificeTimer:0,quarkstimer:9e4,goldenQuarksTimer:9e4,antPoints:new f("1"),antUpgrades:[0,0,0,0,0,0,0,0,0,0,0,0],antSacrificePoints:0,antSacrificeTimer:900,antSacrificeTimerReal:900,talismanLevels:[0,0,0,0,0,0,0],talismanRarity:[1,1,1,1,1,1,1],talismanOne:[null,-1,1,1,1,-1],talismanTwo:[null,1,1,-1,-1,1],talismanThree:[null,1,-1,1,1,-1],talismanFour:[null,-1,-1,1,1,1],talismanFive:[null,1,1,-1,-1,1],talismanSix:[null,1,1,1,-1,-1],talismanSeven:[null,-1,1,-1,1,1],talismanShards:0,commonFragments:0,uncommonFragments:0,rareFragments:0,epicFragments:0,legendaryFragments:0,mythicalFragments:0,buyTalismanShardPercent:10,autoAntSacrifice:!1,autoAntSacTimer:900,autoAntSacrificeMode:0,antMax:!1,ascensionCount:0,ascensionCounter:0,ascensionCounterReal:0,ascensionCounterRealReal:0,cubeUpgrades:[null,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],cubeUpgradesBuyMaxToggle:!1,autoCubeUpgradesToggle:!1,autoPlatonicUpgradesToggle:!1,platonicUpgrades:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],wowCubes:new tr(0),wowTesseracts:new na(0),wowHypercubes:new aa(0),wowPlatonicCubes:new sa(0),saveOfferingToggle:!1,wowAbyssals:0,wowOcteracts:0,totalWowOcteracts:0,cubeBlessings:{accelerator:0,multiplier:0,offering:0,runeExp:0,obtainium:0,antSpeed:0,antSacrifice:0,antELO:0,talismanBonus:0,globalSpeed:0},tesseractBlessings:{accelerator:0,multiplier:0,offering:0,runeExp:0,obtainium:0,antSpeed:0,antSacrifice:0,antELO:0,talismanBonus:0,globalSpeed:0},hypercubeBlessings:{accelerator:0,multiplier:0,offering:0,runeExp:0,obtainium:0,antSpeed:0,antSacrifice:0,antELO:0,talismanBonus:0,globalSpeed:0},platonicBlessings:{cubes:0,tesseracts:0,hypercubes:0,platonics:0,hypercubeBonus:0,taxes:0,scoreBonus:0,globalSpeed:0},hepteractCrafts:{chronos:Og,hyperrealism:Ug,quark:Bg,challenge:Rg,abyss:Ig,accelerator:Ng,acceleratorBoost:$g,multiplier:_g},ascendShards:new f("0"),autoAscend:!1,autoAscendMode:"c10Completions",autoAscendThreshold:1,autoOpenCubes:!1,openCubes:0,autoOpenTesseracts:!1,openTesseracts:0,autoOpenHypercubes:!1,openHypercubes:0,autoOpenPlatonicsCubes:!1,openPlatonicsCubes:0,roombaResearchIndex:0,ascStatToggles:{1:!1,2:!1,3:!1,4:!1,5:!1,6:!1},prototypeCorruptions:[0,0,0,0,0,0,0,0,0,0,0,0,0],usedCorruptions:[0,0,0,0,0,0,0,0,0,0,0,0,0],corruptionLoadouts:{1:[0,0,0,0,0,0,0,0,0,0,0,0,0],2:[0,0,0,0,0,0,0,0,0,0,0,0,0],3:[0,0,0,0,0,0,0,0,0,0,0,0,0],4:[0,0,0,0,0,0,0,0,0,0,0,0,0],5:[0,0,0,0,0,0,0,0,0,0,0,0,0],6:[0,0,0,0,0,0,0,0,0,0,0,0,0],7:[0,0,0,0,0,0,0,0,0,0,0,0,0],8:[0,0,0,0,0,0,0,0,0,0,0,0,0],9:[0,0,0,0,0,0,0,0,0,0,0,0,0],10:[0,0,0,0,0,0,0,0,0,0,0,0,0],11:[0,0,0,0,0,0,0,0,0,0,0,0,0],12:[0,0,0,0,0,0,0,0,0,0,0,0,0],13:[0,0,0,0,0,0,0,0,0,0,0,0,0],14:[0,0,0,0,0,0,0,0,0,0,0,0,0],15:[0,0,0,0,0,0,0,0,0,0,0,0,0],16:[0,0,0,0,0,0,0,0,0,0,0,0,0]},corruptionLoadoutNames:["Loadout 1","Loadout 2","Loadout 3","Loadout 4","Loadout 5","Loadout 6","Loadout 7","Loadout 8","Loadout 9","Loadout 10","Loadout 11","Loadout 12","Loadout 13","Loadout 14","Loadout 15","Loadout 16"],corruptionShowStats:!0,constantUpgrades:[null,0,0,0,0,0,0,0,0,0,0],history:{ants:[],ascend:[],reset:[],singularity:[]},historyShowPerSecond:!1,autoChallengeRunning:!1,autoChallengeIndex:1,autoChallengeToggles:[!1,!0,!0,!0,!0,!0,!0,!0,!0,!0,!0,!1,!1,!1,!1,!1],autoChallengeStartExponent:10,autoChallengeTimer:{start:10,exit:2,enter:2},runeBlessingLevels:[0,0,0,0,0,0],runeSpiritLevels:[0,0,0,0,0,0],runeBlessingBuyAmount:0,runeSpiritBuyAmount:0,autoTesseracts:[!1,!1,!1,!1,!1,!1],saveString:"Synergism-$VERSION$-$TIME$.txt",exporttest:!!1,dayCheck:null,dayTimer:0,cubeOpenedDaily:0,cubeQuarkDaily:0,tesseractOpenedDaily:0,tesseractQuarkDaily:0,hypercubeOpenedDaily:0,hypercubeQuarkDaily:0,platonicCubeOpenedDaily:0,platonicCubeQuarkDaily:0,overfluxOrbs:0,overfluxOrbsAutoBuy:!1,overfluxPowder:0,dailyPowderResetUses:1,autoWarpCheck:!1,loadedOct4Hotfix:!1,loadedNov13Vers:!0,loadedDec16Vers:!0,loadedV253:!0,loadedV255:!0,loadedV297Hotfix1:!0,loadedV2927Hotfix1:!0,loadedV2930Hotfix1:!0,loadedV2931Hotfix1:!0,loadedV21003Hotfix1:!0,loadedV21007Hotfix1:!0,version:Jt,rngCode:0,promoCodeTiming:{time:0},singularityCount:0,highestSingularityCount:0,singularityCounter:0,goldenQuarks:0,quarksThisSingularity:0,totalQuarksEver:0,hotkeys:{},theme:"Dark Mode",iconSet:0,notation:"Default",singularityUpgrades:{goldenQuarks1:new V(F.goldenQuarks1,"goldenQuarks1"),goldenQuarks2:new V(F.goldenQuarks2,"goldenQuarks2"),goldenQuarks3:new V(F.goldenQuarks3,"goldenQuarks3"),starterPack:new V(F.starterPack,"starterPack"),wowPass:new V(F.wowPass,"wowPass"),cookies:new V(F.cookies,"cookies"),cookies2:new V(F.cookies2,"cookies2"),cookies3:new V(F.cookies3,"cookies3"),cookies4:new V(F.cookies4,"cookies4"),cookies5:new V(F.cookies5,"cookies5"),ascensions:new V(F.ascensions,"ascensions"),corruptionFourteen:new V(F.corruptionFourteen,"corruptionFourteen"),corruptionFifteen:new V(F.corruptionFifteen,"corruptionFifteen"),singOfferings1:new V(F.singOfferings1,"singOfferings1"),singOfferings2:new V(F.singOfferings2,"singOfferings2"),singOfferings3:new V(F.singOfferings3,"singOfferings3"),singObtainium1:new V(F.singObtainium1,"singObtainium1"),singObtainium2:new V(F.singObtainium2,"singObtainium2"),singObtainium3:new V(F.singObtainium3,"singObtainium3"),singCubes1:new V(F.singCubes1,"singCubes1"),singCubes2:new V(F.singCubes2,"singCubes2"),singCubes3:new V(F.singCubes3,"singCubes3"),singCitadel:new V(F.singCitadel,"singCitadel"),singCitadel2:new V(F.singCitadel2,"singCitadel2"),octeractUnlock:new V(F.octeractUnlock,"octeractUnlock"),singOcteractPatreonBonus:new V(F.singOcteractPatreonBonus,"singOcteractPatreonBonus"),intermediatePack:new V(F.intermediatePack,"intermediatePack"),advancedPack:new V(F.advancedPack,"advancedPack"),expertPack:new V(F.expertPack,"expertPack"),masterPack:new V(F.masterPack,"masterPack"),divinePack:new V(F.divinePack,"divinePack"),wowPass2:new V(F.wowPass2,"wowPass2"),potionBuff:new V(F.potionBuff,"potionBuff"),potionBuff2:new V(F.potionBuff2,"potionBuff2"),potionBuff3:new V(F.potionBuff3,"potionBuff3"),singChallengeExtension:new V(F.singChallengeExtension,"singChallengeExtension"),singChallengeExtension2:new V(F.singChallengeExtension2,"singChallengeExtension2"),singChallengeExtension3:new V(F.singChallengeExtension3,"singChallengeExtension3"),singQuarkImprover1:new V(F.singQuarkImprover1,"singQuarkImprover1"),singQuarkHepteract:new V(F.singQuarkHepteract,"singQuarkHepteract"),singQuarkHepteract2:new V(F.singQuarkHepteract2,"singQuarkHepteract2"),singQuarkHepteract3:new V(F.singQuarkHepteract3,"singQuarkHepteract3"),singOcteractGain:new V(F.singOcteractGain,"singOcteractGain"),singOcteractGain2:new V(F.singOcteractGain2,"singOcteractGain2"),singOcteractGain3:new V(F.singOcteractGain3,"singOcteractGain3"),singOcteractGain4:new V(F.singOcteractGain4,"singOcteractGain4"),singOcteractGain5:new V(F.singOcteractGain5,"singOcteractGain5"),wowPass3:new V(F.wowPass3,"wowPass3"),ultimatePen:new V(F.ultimatePen,"ultimatePen"),platonicTau:new V(F.platonicTau,"platonicTau"),platonicAlpha:new V(F.platonicAlpha,"platonicAlpha"),platonicDelta:new V(F.platonicDelta,"platonicDelta"),platonicPhi:new V(F.platonicPhi,"platonicPhi"),singFastForward:new V(F.singFastForward,"singFastForward"),singFastForward2:new V(F.singFastForward2,"singFastForward2"),singAscensionSpeed:new V(F.singAscensionSpeed,"singAscensionSpeed"),singAscensionSpeed2:new V(F.singAscensionSpeed2,"singAscensionSpeed2"),oneMind:new V(F.oneMind,"oneMind"),wowPass4:new V(F.wowPass4,"wowPass4"),offeringAutomatic:new V(F.offeringAutomatic,"offeringAutomatic"),blueberries:new V(F.blueberries,"blueberries"),singAmbrosiaLuck:new V(F.singAmbrosiaLuck,"singAmbrosiaLuck"),singAmbrosiaLuck2:new V(F.singAmbrosiaLuck2,"singAmbrosiaLuck2"),singAmbrosiaLuck3:new V(F.singAmbrosiaLuck3,"singAmbrosiaLuck3"),singAmbrosiaLuck4:new V(F.singAmbrosiaLuck4,"singAmbrosiaLuck4"),singAmbrosiaGeneration:new V(F.singAmbrosiaGeneration,"singAmbrosiaGeneration"),singAmbrosiaGeneration2:new V(F.singAmbrosiaGeneration2,"singAmbrosiaGeneration2"),singAmbrosiaGeneration3:new V(F.singAmbrosiaGeneration3,"singAmbrosiaGeneration3"),singAmbrosiaGeneration4:new V(F.singAmbrosiaGeneration4,"singAmbrosiaGeneration4")},octeractUpgrades:{octeractStarter:new fe(le.octeractStarter,"octeractStarter"),octeractGain:new fe(le.octeractGain,"octeractGain"),octeractGain2:new fe(le.octeractGain2,"octeractGain2"),octeractQuarkGain:new fe(le.octeractQuarkGain,"octeractQuarkGain"),octeractQuarkGain2:new fe(le.octeractQuarkGain2,"octeractQuarkGain2"),octeractCorruption:new fe(le.octeractCorruption,"octeractCorruption"),octeractGQCostReduce:new fe(le.octeractGQCostReduce,"octeractGQCostReduce"),octeractExportQuarks:new fe(le.octeractExportQuarks,"octeractExportQuarks"),octeractImprovedDaily:new fe(le.octeractImprovedDaily,"octeractImprovedDaily"),octeractImprovedDaily2:new fe(le.octeractImprovedDaily2,"octeractImprovedDaily2"),octeractImprovedDaily3:new fe(le.octeractImprovedDaily3,"octeractImprovedDaily3"),octeractImprovedQuarkHept:new fe(le.octeractImprovedQuarkHept,"octeractImprovedQuarkHept"),octeractImprovedGlobalSpeed:new fe(le.octeractImprovedGlobalSpeed,"octeractImprovedGlobalSpeed"),octeractImprovedAscensionSpeed:new fe(le.octeractImprovedAscensionSpeed,"octeractImprovedAscensionSpeed"),octeractImprovedAscensionSpeed2:new fe(le.octeractImprovedAscensionSpeed2,"octeractImprovedAscensionSpeed2"),octeractImprovedFree:new fe(le.octeractImprovedFree,"octeractImprovedFree"),octeractImprovedFree2:new fe(le.octeractImprovedFree2,"octeractImprovedFree2"),octeractImprovedFree3:new fe(le.octeractImprovedFree3,"octeractImprovedFree3"),octeractImprovedFree4:new fe(le.octeractImprovedFree4,"octeractImprovedFree4"),octeractSingUpgradeCap:new fe(le.octeractSingUpgradeCap,"octeractSingUpgradeCap"),octeractOfferings1:new fe(le.octeractOfferings1,"octeractOfferings1"),octeractObtainium1:new fe(le.octeractObtainium1,"octeractObtainium1"),octeractAscensions:new fe(le.octeractAscensions,"octeractAscensions"),octeractAscensions2:new fe(le.octeractAscensions2,"octeractAscensions2"),octeractAscensionsOcteractGain:new fe(le.octeractAscensionsOcteractGain,"octeractAscensionsOcteractGain"),octeractFastForward:new fe(le.octeractFastForward,"octeractFastForward"),octeractAutoPotionSpeed:new fe(le.octeractAutoPotionSpeed,"octeractAutoPotionSpeed"),octeractAutoPotionEfficiency:new fe(le.octeractAutoPotionEfficiency,"octeractAutoPotionEfficiency"),octeractOneMindImprover:new fe(le.octeractOneMindImprover,"octeractOneMindImprover"),octeractAmbrosiaLuck:new fe(le.octeractAmbrosiaLuck,"octeractAmbrosiaLuck"),octeractAmbrosiaLuck2:new fe(le.octeractAmbrosiaLuck2,"octeractAmbrosiaLuck2"),octeractAmbrosiaLuck3:new fe(le.octeractAmbrosiaLuck3,"octeractAmbrosiaLuck3"),octeractAmbrosiaLuck4:new fe(le.octeractAmbrosiaLuck4,"octeractAmbrosiaLuck4"),octeractAmbrosiaGeneration:new fe(le.octeractAmbrosiaGeneration,"octeractAmbrosiaGeneration"),octeractAmbrosiaGeneration2:new fe(le.octeractAmbrosiaGeneration2,"octeractAmbrosiaGeneration2"),octeractAmbrosiaGeneration3:new fe(le.octeractAmbrosiaGeneration3,"octeractAmbrosiaGeneration3"),octeractAmbrosiaGeneration4:new fe(le.octeractAmbrosiaGeneration4,"octeractAmbrosiaGeneration4")},dailyCodeUsed:!1,hepteractAutoCraftPercentage:50,octeractTimer:0,insideSingularityChallenge:!1,singularityChallenges:{noSingularityUpgrades:new ir(Ze.noSingularityUpgrades,"noSingularityUpgrades"),oneChallengeCap:new ir(Ze.oneChallengeCap,"oneChallengeCap"),noOcteracts:new ir(Ze.noOcteracts,"noOcteracts"),limitedAscensions:new ir(Ze.limitedAscensions,"limitedAscensions"),noAmbrosiaUpgrades:new ir(Ze.noAmbrosiaUpgrades,"noAmbrosiaUpgrades"),limitedTime:new ir(Ze.limitedTime,"limitedTime"),sadisticPrequel:new ir(Ze.sadisticPrequel,"sadisticPrequel")},ambrosia:0,lifetimeAmbrosia:0,ambrosiaRNG:0,blueberryTime:0,visitedAmbrosiaSubtab:!1,spentBlueberries:0,blueberryUpgrades:{ambrosiaTutorial:new Ke($e.ambrosiaTutorial,"ambrosiaTutorial"),ambrosiaQuarks1:new Ke($e.ambrosiaQuarks1,"ambrosiaQuarks1"),ambrosiaCubes1:new Ke($e.ambrosiaCubes1,"ambrosiaQuarks1"),ambrosiaLuck1:new Ke($e.ambrosiaLuck1,"ambrosiaLuck1"),ambrosiaCubeQuark1:new Ke($e.ambrosiaCubeQuark1,"ambrosiaCubeQuark1"),ambrosiaLuckQuark1:new Ke($e.ambrosiaLuckQuark1,"ambrosiaLuckQuark1"),ambrosiaLuckCube1:new Ke($e.ambrosiaLuckCube1,"ambrosiaLuckCube1"),ambrosiaQuarkCube1:new Ke($e.ambrosiaQuarkCube1,"ambrosiaQuarkCube1"),ambrosiaCubeLuck1:new Ke($e.ambrosiaCubeLuck1,"ambrosiaCubeLuck1"),ambrosiaQuarkLuck1:new Ke($e.ambrosiaQuarkLuck1,"ambrosiaQuarkLuck1"),ambrosiaQuarks2:new Ke($e.ambrosiaQuarks2,"ambrosiaQuarks2"),ambrosiaCubes2:new Ke($e.ambrosiaCubes2,"ambrosiaQuarks2"),ambrosiaLuck2:new Ke($e.ambrosiaLuck2,"ambrosiaLuck2"),ambrosiaPatreon:new Ke($e.ambrosiaPatreon,"ambrosiaPatreon"),ambrosiaObtainium1:new Ke($e.ambrosiaObtainium1,"ambrosiaObtainium1"),ambrosiaOffering1:new Ke($e.ambrosiaOffering1,"ambrosiaOffering1"),ambrosiaHyperflux:new Ke($e.ambrosiaHyperflux,"ambrosiaHyperflux")},blueberryLoadouts:{1:{},2:{},3:{},4:{},5:{},6:{},7:{},8:{},9:{},10:{},11:{},12:{},13:{},14:{},15:{},16:{}},blueberryLoadoutMode:"saveTree",ultimateProgress:0,ultimatePixels:0,cubeUpgradeRedBarFilled:0,singChallengeTimer:0,caches:{ambrosiaLuckAdditiveMult:new Dl,ambrosiaLuck:new Gl,ambrosiaGeneration:new Hl,blueberryInventory:new Fl},lastExportedSave:0,seed:Array.from({length:2},()=>Date.now())},M=Object.assign({},e,{codes:new Map(Array.from({length:48},(t,r)=>[r+1,!1]))}),hr=t=>{e.offlinetick=Date.now(),e.loaded1009=!0,e.loaded1009hotfix1=!0;let r=fs.parse(e),n=rs(JSON.stringify(r));if(n!==null)localStorage.setItem("Synergysave2",n);else return P(u.t("testing.errorSaving")),!1;if(t){let a=i("saveinfo");a.textContent=u.t("testing.gameSaved"),Ji(()=>a.textContent="",4e3)}return!0},r2=()=>{var c,p,g;let t=localStorage.getItem("Synergysave2"),r=t?JSON.parse(atob(t)):null;if((!1||!Dr)&&(Object.defineProperties(window,{player:{value:e},G:{value:o},Decimal:{value:f},i18n:{value:u}}),r&&!1&&(r.exporttest=!1)),Object.assign(o,O({},Xf)),r){if((r.exporttest===!1||r.exporttest==="NO!")&&!!1)return P(u.t("testing.saveInLive2"));let m=e.codes.size,h=Object.keys(r).filter(S=>S.includes("offerpromo"));h.length>0&&h.forEach(S=>{let I=r[S],N=+S.replace(/[^\d]/g,"");e.codes.set(N,!!I)});let b=Di.safeParse(r);if(b.success)Object.assign(e,b.data);else{console.log(b.error),console.log(r),du();return}if(nd(),e.lastExportedSave=(c=r.lastExportedSave)!=null?c:0,r.offerpromo24used!==void 0&&e.codes.set(25,!1),e.codes.size"u"&&(e.codes.set(13,!1),e.researches.push(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0),e.achievements.push(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0),e.maxofferings=e.runeshards,e.maxobtainium=e.researchPoints,e.researchPoints+=51200*e.researches[50],e.researches[50]=0),e.maxofferings=e.maxofferings||0,e.maxobtainium=e.maxobtainium||0,e.runeshards=e.runeshards||0,e.researchPoints=e.researchPoints||0,(!r.loaded1009||r.loaded1009hotfix1===null||((p=r.shopUpgrades)==null?void 0:p.offeringPotion)===void 0)&&(e.firstOwnedParticles=0,e.secondOwnedParticles=0,e.thirdOwnedParticles=0,e.fourthOwnedParticles=0,e.fifthOwnedParticles=0,e.firstCostParticles=new f("1"),e.secondCostParticles=new f("1e2"),e.thirdCostParticles=new f("1e4"),e.fourthCostParticles=new f("1e8"),e.fifthCostParticles=new f("1e16"),e.autoSacrificeToggle=!1,e.autoResearchToggle=!1,e.autoResearchMode="manual",e.autoResearch=0,e.autoSacrifice=0,e.sacrificeTimer=0,e.loaded1009=!0,e.codes.set(18,!1)),r.loaded1009hotfix1||(e.loaded1009hotfix1=!0,e.codes.set(19,!0),e.firstOwnedParticles=0,e.secondOwnedParticles=0,e.thirdOwnedParticles=0,e.fourthOwnedParticles=0,e.fifthOwnedParticles=0,e.firstCostParticles=new f("1"),e.secondCostParticles=new f("1e2"),e.thirdCostParticles=new f("1e4"),e.fourthCostParticles=new f("1e8"),e.fifthCostParticles=new f("1e16")),(r.loaded10091===void 0||!r.loaded10091||e.researches[86]>100||e.researches[87]>100||e.researches[88]>100||e.researches[89]>100||e.researches[90]>10)&&(e.loaded10091=!0,e.researchPoints+=75e7*e.researches[82],e.researchPoints+=2e8*e.researches[83],e.researchPoints+=45e8*e.researches[84],e.researchPoints+=25e6*e.researches[86],e.researchPoints+=75e6*e.researches[87],e.researchPoints+=3e8*e.researches[88],e.researchPoints+=1e9*e.researches[89],e.researchPoints+=25e6*e.researches[90],e.researchPoints+=1e8*e.researches[91],e.researchPoints+=2e9*e.researches[92],e.researchPoints+=9e9*e.researches[93],e.researchPoints+=725e8*e.researches[94],e.researches[86]=0,e.researches[87]=0,e.researches[88]=0,e.researches[89]=0,e.researches[90]=0,e.researches[91]=0,e.researches[92]=0),(((g=r.achievements)==null?void 0:g[169])===void 0||typeof e.achievements[169]>"u"||r.loaded1010===void 0||r.loaded1010===!1)&&(e.loaded1010=!0,e.codes.set(21,!1),e.firstOwnedAnts=0,e.firstGeneratedAnts=new f("0"),e.firstCostAnts=new f("1e700"),e.firstProduceAnts=1e-4,e.secondOwnedAnts=0,e.secondGeneratedAnts=new f("0"),e.secondCostAnts=new f("3"),e.secondProduceAnts=5e-5,e.thirdOwnedAnts=0,e.thirdGeneratedAnts=new f("0"),e.thirdCostAnts=new f("100"),e.thirdProduceAnts=2e-5,e.fourthOwnedAnts=0,e.fourthGeneratedAnts=new f("0"),e.fourthCostAnts=new f("1e4"),e.fourthProduceAnts=1e-5,e.fifthOwnedAnts=0,e.fifthGeneratedAnts=new f("0"),e.fifthCostAnts=new f("1e12"),e.fifthProduceAnts=5e-6,e.sixthOwnedAnts=0,e.sixthGeneratedAnts=new f("0"),e.sixthCostAnts=new f("1e36"),e.sixthProduceAnts=2e-6,e.seventhOwnedAnts=0,e.seventhGeneratedAnts=new f("0"),e.seventhCostAnts=new f("1e100"),e.seventhProduceAnts=1e-6,e.eighthOwnedAnts=0,e.eighthGeneratedAnts=new f("0"),e.eighthCostAnts=new f("1e300"),e.eighthProduceAnts=1e-8,e.achievements.push(0,0,0,0,0,0,0,0,0,0,0,0,0,0),e.antPoints=new f("1"),e.upgrades[38]=0,e.upgrades[39]=0,e.upgrades[40]=0,e.upgrades[76]=0,e.upgrades[77]=0,e.upgrades[78]=0,e.upgrades[79]=0,e.upgrades[80]=0,e.antUpgrades=[0,0,0,0,0,0,0,0,0,0,0,0],e.unlocks.rrow4=!1,e.researchPoints+=3e7*e.researches[50],e.researchPoints+=2e9*e.researches[96],e.researchPoints+=5e9*e.researches[97],e.researchPoints+=3e10*e.researches[98],e.researches[50]=0,e.researches[96]=0,e.researches[97]=0,e.researches[98]=0,e.researches.push(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0),e.talismanLevels=[0,0,0,0,0,0,0],e.talismanRarity=[1,1,1,1,1,1,1],e.talismanShards=0,e.commonFragments=0,e.uncommonFragments=0,e.rareFragments=0,e.epicFragments=0,e.legendaryFragments=0,e.mythicalFragments=0,e.buyTalismanShardPercent=10,e.talismanOne=[null,-1,1,1,1,-1],e.talismanTwo=[null,1,1,-1,-1,1],e.talismanThree=[null,1,-1,1,1,-1],e.talismanFour=[null,-1,-1,1,1,1],e.talismanFive=[null,1,1,-1,-1,1],e.talismanSix=[null,1,1,1,-1,-1],e.talismanSeven=[null,-1,1,-1,1,1],e.antSacrificePoints=0,e.antSacrificeTimer=0,e.obtainiumpersecond=0,e.maxobtainiumpersecond=0),r.loaded10101===void 0||r.loaded10101===!1){e.loaded10101=!0;let S=[0,31,32,61,62,63,64,76,77,78,79,80,81,98,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,125],I=[0,2,20,5,10,80,5e3,1e7,1e7,2e7,3e7,4e7,2e8,3e10,1e11,1e12,2e11,1e12,2e10,2e11,1e12,2e13,5e13,1e14,2e14,5e14,1e15,2e15,1e16,1e15,1e16,1e14,1e15,1e15,1e20];for(let N=1;N0&&(e.ascensionCounter=86400*90),e.singularityCount===0&&(e.cubeUpgrades=[...M.cubeUpgrades]),e.wowCubes=new tr(0),e.wowTesseracts=new na(0),e.wowHypercubes=new aa(0),e.wowPlatonicCubes=new sa(0),e.cubeBlessings={accelerator:0,multiplier:0,offering:0,runeExp:0,obtainium:0,antSpeed:0,antSacrifice:0,antELO:0,talismanBonus:0,globalSpeed:0}),e.transcendCount<0&&(e.transcendCount=0),e.reincarnationCount<0&&(e.reincarnationCount=0),e.runeshards<0&&(e.runeshards=0),e.researchPoints<0&&(e.researchPoints=0),e.resettoggle1===0&&(e.resettoggle1=1,e.resettoggle2=1,e.resettoggle3=1,e.resettoggle4=1),e.tesseractAutoBuyerToggle===0&&(e.tesseractAutoBuyerToggle=1),e.reincarnationCount<.5&&e.unlocks.rrow4&&(e.unlocks={coinone:!1,cointwo:!1,cointhree:!1,coinfour:!1,prestige:!1,generation:!1,transcend:!1,reincarnate:!1,rrow1:!1,rrow2:!1,rrow3:!1,rrow4:!1}),Number.isInteger(e.ascendBuilding1.cost)||(e.ascendBuilding1.cost=1,e.ascendBuilding1.owned=0,e.ascendBuilding2.cost=10,e.ascendBuilding2.owned=0,e.ascendBuilding3.cost=100,e.ascendBuilding3.owned=0,e.ascendBuilding4.cost=1e3,e.ascendBuilding4.owned=0,e.ascendBuilding5.cost=1e4,e.ascendBuilding5.owned=0),e.dayCheck||(e.dayCheck=new Date),typeof e.dayCheck=="string"&&(e.dayCheck=new Date(e.dayCheck),isNaN(e.dayCheck.getTime())&&(e.dayCheck=new Date));let C=On;isNaN(C.getTime())?e.dayCheck.getTime()<16540092e5&&(e.dayCheck=new Date("06/01/2022 00:00:00")):(C=new Date(C.getFullYear(),C.getMonth(),C.getDate()-1),e.dayCheck.getTime()I>=2&&I<=9?Math.min(v*(e.challengecompletions[wl(I)]>0?1:0),S):S);for(let S=1;S<=5;S++){let I=`ascendBuilding${S}`;e[I].generated=new f(e[I].generated)}for(;typeof e.achievements[252]>"u";)e.achievements.push(0);for(;typeof e.researches[200]>"u";)e.researches.push(0);for(;typeof e.upgrades[140]>"u";)e.upgrades.push(0);(e.saveString===""||e.saveString==="Synergism-v1011Test.txt")&&(e.saveString=e.singularityCount===0?"Synergism-$VERSION$-$TIME$.txt":"Synergism-$VERSION$-$TIME$-$SING$.txt"),i("saveStringInput").value=Zs(e.saveString);for(let S=1;S<126;S++)Ft(S,!0);for(let S=1;S<=200;S++)ns(S);for(let S=1;S0?ot(e.currentChallenge.transcension):e.currentChallenge.reincarnation>0?ot(e.currentChallenge.reincarnation):e.currentChallenge.ascension>0?ot(e.currentChallenge.ascension):ot(1),Ga(),v0(),h0();let k=1+8+xe.CORRUPTION_LOADOUT_SLOT_QOL;for(let S=0;S.5&&(i(`rune${e.autoSacrifice}`).style.backgroundColor="orange"),e.autoWarpCheck?(i("warpAuto").textContent=u.t("general.autoOnColon"),i("warpAuto").style.border="2px solid green"):(i("warpAuto").textContent=u.t("general.autoOffColon"),i("warpAuto").style.border="2px solid red"),i("autoHepteractPercentage").textContent=u.t("wowCubes.hepteractForge.autoSetting",{x:`${e.hepteractAutoCraftPercentage}`}),i("hepteractToQuarkTradeAuto").textContent=e.overfluxOrbsAutoBuy?u.t("general.autoOnColon"):u.t("general.autoOffColon"),i("hepteractToQuarkTradeAuto").style.border=`2px solid ${e.overfluxOrbsAutoBuy?"green":"red"}`,Ri(!0,!0),i("blueberryToggleMode").innerHTML=e.blueberryLoadoutMode==="saveTree"?u.t("ambrosia.loadouts.save"):u.t("ambrosia.loadouts.load"),bs(e.buyTalismanShardPercent),Kt(),Ar(),Bt(),He(),Ad(),ff(),ku(),o.currentSingChallenge!==void 0){let S=e.singularityChallenges[o.currentSingChallenge].computeSingularityRquirement();e.singularityCount=S}}M0(),e.currentChallenge.reincarnation?at("reincarnationChallenge"):e.currentChallenge.transcension&&at("transcensionChallenge");let n=new Date,a=n.getHours(),s=n.getMinutes(),l=n.getSeconds();e.dayTimer=60*60*24-(l+60*s+60*60*a)},W0=["","K","M","B","T","Qa","Qt","Sx","Sp","Oc","No","Dc","UDc","DDc","TDc","QaDc","QtDc","SxDc","SpDc","OcDc","NoDc","Vg","UVg","DVg","TVg","QaVg","QtVg","SxVg","SpVg","OcVg","NoVg","Tg","UTg","DTg","TTg","QaTg","QtTg","SxTg","SpTg","OTg","NTg","Qd","UQd","DQd","TQd","QaQd","QtQd","SxQd","SpQd","OcQd","NoQd","Qi","UQi","DQi","TQi","QaQi","QtQi","SxQi","SpQi","OQi","NQi","Se","USe","DSe","TSe","QaSe","QtSe","SxSe","SpSe","OcSe","NoSe","St","USt","DSt","TSt","QaSt","QtSt","SxSt","SpSt","OcSt","NoSt","Ocg","UOcg","DOcg","TOcg","QaOcg","QtOcg","SxOcg","SpOcg","OcOcg","NoOcg","Nono","UNono","DNono","TNono","QaNono","QtNono","SxNono","SpNono","OcNono","NoNono","Ce"],n2=typeof Intl.NumberFormat.prototype.formatToParts=="function",Wl=n2?Intl.NumberFormat().formatToParts(1000.1).filter(t=>t.type==="decimal"||t.type==="group"):null,[{value:a2},{value:s2}]=(Wl==null?void 0:Wl.length)!==2?[{value:","},{value:"."}]:Wl,Od={minimumFractionDigits:2,maximumFractionDigits:2},Ud=(t,r=3)=>{let n=1,a="",s=t.split(".");for(let l=s[0].length-1;l>=0;l--)n++===r&&l!==0?(n=1,a=a2+t[l]+a):a=t[l]+a;return typeof s[1]<"u"&&(a+=s2+s[1]),a|0,a},d=(t,r=0,n=!1,a=!0,s=!1)=>{if(t==null)return"0 [null]";if(typeof t=="object"&&Symbol.toPrimitive in t&&(t=Number(t)),!(t instanceof f)&&typeof t!="number"||isNaN(t))return isNaN(t)?"0 [NaN]":"0 [und.]";if(typeof t=="number"&&e.notation==="Default"&&t<(s?1e-15:.001)&&t>0)return t.toExponential(r);let l,c;if(Li(t))l=t.e,c=t.mantissa;else if(typeof t=="number"){if(t===0)return"0";l=Math.floor(Math.log10(Math.abs(t))),c=t/Math.pow(10,l)}if(c>9.9999999&&(c=1,++l),c<1&&c>.9999999&&(c=1),l<-15)return"0";if(e.notation==="Pure Engineering"){let p=l%3<0?3+l%3:l%3;l=l-p,c=c*Math.pow(10,p)}if(e.notation==="Pure Scientific"||e.notation==="Pure Engineering"){if(l>=1e6)return Number.isFinite(l)?`E${d(l,3)}`:"Infinity";if(r=l===2&&r>2?2:r,l>=6||l<0){r=r<2?2:r;let g=(Math.floor(c*Math.pow(10,r))/Math.pow(10,r)).toLocaleString(void 0,Od),m=Ud(l.toString());return`${g}e${m}`}return c=c*Math.pow(10,l),c-Math.floor(c)>.9999999&&(c=Math.ceil(c)),`${(Math.floor(c*Math.pow(10,r))/Math.pow(10,r)).toLocaleString(void 0,{minimumFractionDigits:r,maximumFractionDigits:r})}`}if(l<0&&!Li(t)&&s)return l<=-15?`${d(c,r,n)} / ${Math.pow(10,-l-15)}Qa`:l<=-12?`${d(c,r,n)} / ${Math.pow(10,-l-12)}T`:l<=-9?`${d(c,r,n)} / ${Math.pow(10,-l-9)}B`:l<=-6?`${d(c,r,n)} / ${Math.pow(10,-l-6)}M`:l<=-3?`${d(c,r,n)} / ${Math.pow(10,-l-3)}K`:`${d(c,r,n)} / ${Math.pow(10,-l)}`;if(l<6||n&&l<7){let p=c*Math.pow(10,l),g;return p-Math.floor(p)>.9999999&&(p=Math.ceil(p)),(l<2||n&&l<3)&&r>0?g=p.toFixed(l===2&&r>2?2:r):(p=Math.floor(p),g=p.toString()),Ud(g)}else if(l<1e6){let p=(Math.floor(c*100)/100).toLocaleString(void 0,Od),g=Ud(l.toString());return`${p}e${g}`}else if(l>=1e6){if(!Number.isFinite(l))return"Infinity";let p=!1&&a?"":(Math.floor(c*100)/100).toLocaleString(void 0,Od),g=Math.ceil(Math.log10(l)),m=(g-1)%3+1,h=l/Math.pow(10,g-m);h===1e3&&(h=1,m=1);let b=h.toLocaleString(void 0,{minimumFractionDigits:4-m,maximumFractionDigits:4-m}),C=Math.floor(Math.log10(l)/3);return typeof W0[C]=="string"?`${p}e${b}${W0[C]}`:`e${l.toExponential(2)}`}else return"0 [und.]"},Vt=(t,r)=>(t>=86400?`${d(Math.floor(t/86400))}d`:"")+(t>=3600?`${d(Math.floor(t/3600)%24)}h`:"")+(t>=60?`${d(Math.floor(t/60)%60)}m`:"")+(t>=864e4?"":`${d(Math.floor(t)%60)+(r&&t{let t=0;o.totalAccelerator=e.acceleratorBought,o.costDivisor=1,e.upgrades[8]!==0&&(t+=Math.floor(e.multiplierBought/7)),e.upgrades[21]!==0&&(t+=5),e.upgrades[22]!==0&&(t+=4),e.upgrades[23]!==0&&(t+=3),e.upgrades[24]!==0&&(t+=2),e.upgrades[25]!==0&&(t+=1),e.upgrades[27]!==0&&(t+=Math.min(250,Math.floor(f.log(e.coins.add(1),1e3)))+Math.min(1750,Math.max(0,Math.floor(f.log(e.coins.add(1),1e15))-50))),e.upgrades[29]!==0&&(t+=Math.floor(Math.min(2e3,(e.firstOwnedCoin+e.secondOwnedCoin+e.thirdOwnedCoin+e.fourthOwnedCoin+e.fifthOwnedCoin)/80))),e.upgrades[32]!==0&&(t+=Math.min(500,Math.floor(f.log(e.prestigePoints.add(1),1e25)))),e.upgrades[45]!==0&&(t+=Math.min(2500,Math.floor(f.log(e.transcendShards.add(1),10)))),e.achievements[5]!==0&&(t+=Math.floor(e.firstOwnedCoin/500)),e.achievements[12]!==0&&(t+=Math.floor(e.secondOwnedCoin/500)),e.achievements[19]!==0&&(t+=Math.floor(e.thirdOwnedCoin/500)),e.achievements[26]!==0&&(t+=Math.floor(e.fourthOwnedCoin/500)),e.achievements[33]!==0&&(t+=Math.floor(e.fifthOwnedCoin/500)),e.achievements[60]!==0&&(t+=2),e.achievements[61]!==0&&(t+=2),e.achievements[62]!==0&&(t+=2),t+=5*_("transcend",e.challengecompletions[2]),o.freeUpgradeAccelerator=t,t+=o.totalAcceleratorBoost*(4+2*e.researches[18]+2*e.researches[19]+3*e.researches[20]+o.cubeBonusMultiplier[1]),e.unlocks.prestige&&(t+=Math.floor(Math.pow(o.rune1level*o.effectiveLevelMult/4,1.25)),t*=1+o.rune1level*1/400*o.effectiveLevelMult),O0(),t*=o.acceleratorMultiplier,t=Math.pow(t,Math.min(1,(1+e.platonicUpgrades[6]/30)*o.viscosityPower[e.usedCorruptions[2]])),t+=2e3*Ve("accelerator"),t*=o.challenge15Rewards.accelerator,t*=1+3/1e4*Ve("accelerator"),t=Math.floor(Math.min(1e100,t)),e.usedCorruptions[2]>=15&&(t=Math.pow(t,.2)),e.usedCorruptions[2]>=16&&(t=1),o.freeAccelerator=t,o.totalAccelerator+=o.freeAccelerator,o.tuSevenMulti=1,e.upgrades[46]>.5&&(o.tuSevenMulti=1.05),o.acceleratorPower=Math.pow(1.1+o.tuSevenMulti*(o.totalAcceleratorBoost/100)*(1+_("transcend",e.challengecompletions[2])/20),1+.04*_("reincarnation",e.challengecompletions[7])),o.acceleratorPower+=1/200*Math.floor(_("transcend",e.challengecompletions[2])/2)*100/100;for(let r=1;r<=5;r++)e.achievements[7*r-4]>0&&(o.acceleratorPower+=5e-4*r);e.currentChallenge.reincarnation!==7&&e.currentChallenge.reincarnation!==10&&(e.currentChallenge.transcension===1&&(o.acceleratorPower*=25/(50+e.challengecompletions[1]),o.acceleratorPower+=.55,o.acceleratorPower=Math.max(1,o.acceleratorPower)),e.currentChallenge.transcension===2&&(o.acceleratorPower=1),e.currentChallenge.transcension===3&&(o.acceleratorPower=1.05+2*o.tuSevenMulti*(o.totalAcceleratorBoost/300)*(1+_("transcend",e.challengecompletions[2])/20))),o.acceleratorPower=Math.min(1e300,o.acceleratorPower),e.currentChallenge.reincarnation===7&&(o.acceleratorPower=1),e.currentChallenge.reincarnation===10&&(o.acceleratorPower=1),e.currentChallenge.transcension!==1&&(o.acceleratorEffect=f.pow(o.acceleratorPower,o.totalAccelerator)),e.currentChallenge.transcension===1&&(o.acceleratorEffect=f.pow(o.acceleratorPower,o.totalAccelerator+o.totalMultiplier)),o.acceleratorEffectDisplay=new f(o.acceleratorPower*100-100),e.currentChallenge.reincarnation===10&&(o.acceleratorEffect=new f(1)),o.generatorPower=new f(1),e.upgrades[11]>.5&&e.currentChallenge.reincarnation!==7&&(o.generatorPower=f.pow(1.02,o.totalAccelerator))},Bu=()=>{let t=0;e.upgrades[7]>0&&(t+=Math.min(4,1+Math.floor(f.log(e.fifthOwnedCoin+1,10)))),e.upgrades[9]>0&&(t+=Math.floor(e.acceleratorBought/10)),e.upgrades[21]>0&&(t+=1),e.upgrades[22]>0&&(t+=1),e.upgrades[23]>0&&(t+=1),e.upgrades[24]>0&&(t+=1),e.upgrades[25]>0&&(t+=1),e.upgrades[28]>0&&(t+=Math.min(1e3,Math.floor((e.firstOwnedCoin+e.secondOwnedCoin+e.thirdOwnedCoin+e.fourthOwnedCoin+e.fifthOwnedCoin)/160))),e.upgrades[30]>0&&(t+=Math.min(75,Math.floor(f.log(e.coins.add(1),1e10)))+Math.min(925,Math.floor(f.log(e.coins.add(1),1e30)))),e.upgrades[33]>0&&(t+=o.totalAcceleratorBoost),e.upgrades[49]>0&&(t+=Math.min(50,Math.floor(f.log(e.transcendPoints.add(1),1e10)))),e.upgrades[68]>0&&(t+=Math.min(2500,Math.floor(f.log(o.taxdivisor,10)*1/1e3))),e.challengecompletions[1]>0&&(t+=1),e.achievements[6]>.5&&(t+=Math.floor(e.firstOwnedCoin/1e3)),e.achievements[13]>.5&&(t+=Math.floor(e.secondOwnedCoin/1e3)),e.achievements[20]>.5&&(t+=Math.floor(e.thirdOwnedCoin/1e3)),e.achievements[27]>.5&&(t+=Math.floor(e.fourthOwnedCoin/1e3)),e.achievements[34]>.5&&(t+=Math.floor(e.fifthOwnedCoin/1e3)),e.achievements[57]>.5&&(t+=1),e.achievements[58]>.5&&(t+=1),e.achievements[59]>.5&&(t+=1),t+=20*e.researches[94]*Math.floor((o.rune1level+o.rune2level+o.rune3level+o.rune4level+o.rune5level)/8),o.freeUpgradeMultiplier=Math.min(1e100,t),e.achievements[38]>.5&&(t+=Math.floor(Math.floor(o.rune2level/10*o.effectiveLevelMult)*Math.floor(1+o.rune2level/10*o.effectiveLevelMult)/2)*100/100),t*=1+e.achievements[57]/100,t*=1+e.achievements[58]/100,t*=1+e.achievements[59]/100,t*=Math.pow(1.01,e.upgrades[21]+e.upgrades[22]+e.upgrades[23]+e.upgrades[24]+e.upgrades[25]),t*=1+.03*e.upgrades[34]+.02*e.upgrades[35],t*=1+1/5*e.researches[2]*(1+1/2*_("ascension",e.challengecompletions[14])),t*=1+1/20*e.researches[11]+1/25*e.researches[12]+1/40*e.researches[13]+3/200*e.researches[14]+1/200*e.researches[15],t*=1+o.rune2level/400*o.effectiveLevelMult,t*=1+1/20*e.researches[87],t*=1+1/100*e.researches[128],t*=1+.8/100*e.researches[143],t*=1+.6/100*e.researches[158],t*=1+.4/100*e.researches[173],t*=1+.2/100*e.researches[188],t*=1+.01/100*e.researches[200],t*=1+.01/100*e.cubeUpgrades[50],t*=Nt(40,(e.antUpgrades[4]+o.bonusant5)/1e3*40/39),t*=o.cubeBonusMultiplier[2],(e.currentChallenge.transcension!==0||e.currentChallenge.reincarnation!==0)&&e.upgrades[50]>.5&&(t*=1.25),t=Math.pow(t,Math.min(1,(1+e.platonicUpgrades[6]/30)*o.viscosityPower[e.usedCorruptions[2]])),t+=1e3*Ve("multiplier"),t*=o.challenge15Rewards.multiplier,t*=1+3/1e4*Ve("multiplier"),t=Math.floor(Math.min(1e100,t)),e.usedCorruptions[2]>=15&&(t=Math.pow(t,.2)),e.usedCorruptions[2]>=16&&(t=1),o.freeMultiplier=t,o.totalMultiplier=o.freeMultiplier+e.multiplierBought,o.challengeOneLog=3;let r=0,n=0;r+=f.log(e.transcendShards.add(1),3),r*=1+11*e.researches[33]/100,r*=1+11*e.researches[34]/100,r*=1+11*e.researches[35]/100,r*=1+e.researches[89]/5,r*=1+10*o.effectiveRuneBlessingPower[2],n+=Math.floor(.1*r*_("transcend",e.challengecompletions[1])),n+=_("transcend",e.challengecompletions[1])*10,o.freeMultiplierBoost=n,o.totalMultiplierBoost=Math.pow(Math.floor(r)+n,1+_("reincarnation",e.challengecompletions[7])*.04);let a=1;e.challengecompletions[7]>.5&&(a=1.25),o.multiplierPower=2+.005*o.totalMultiplierBoost*a,e.currentChallenge.reincarnation!==7&&e.currentChallenge.reincarnation!==10&&(e.currentChallenge.transcension===1&&(o.multiplierPower=1),e.currentChallenge.transcension===2&&(o.multiplierPower=1.25+.0012*(r+n)*a)),o.multiplierPower=Math.min(1e300,o.multiplierPower),e.currentChallenge.reincarnation===7&&(o.multiplierPower=1),e.currentChallenge.reincarnation===10&&(o.multiplierPower=1),o.multiplierEffect=f.pow(o.multiplierPower,o.totalMultiplier)},o2=()=>{let t=new f(1),r=new f(1),n=1/3;n+=Math.min(10+.05*e.researches[129]*Math.log(e.commonFragments+1)/Math.log(4)+20*Xe()/400*o.effectiveRuneSpiritPower[3],.05*e.crystalUpgrades[3]),n+=.04*_("transcend",e.challengecompletions[3]),n+=.08*e.researches[28],n+=.08*e.researches[29],n+=.04*e.researches[30],n+=8*e.cubeUpgrades[17],o.prestigeMultiplier=f.pow(e.prestigeShards,n).add(1);let a=1;e.currentChallenge.reincarnation===7&&(a=.05),e.currentChallenge.reincarnation===8&&(a=0),o.buildingPower=1+(1-Math.pow(2,-1/160))*a*f.log(e.reincarnationShards.add(1),10)*(1+1/20*e.researches[36]+1/40*e.researches[37]+1/40*e.researches[38])+(a+.2)*.25/1.2*_("reincarnation",e.challengecompletions[8]),o.buildingPower=Math.pow(o.buildingPower,1+e.cubeUpgrades[12]*.09),o.buildingPower=Math.pow(o.buildingPower,1+e.cubeUpgrades[36]*.05),o.reincarnationMultiplier=f.pow(o.buildingPower,o.totalCoinOwned),o.antMultiplier=f.pow(f.max(1,e.antPoints),ju()),t=t.times(o.multiplierEffect),t=t.times(o.acceleratorEffect),t=t.times(o.prestigeMultiplier),t=t.times(o.reincarnationMultiplier),t=t.times(o.antMultiplier);let s=new f(o.totalCoinOwned+1).times(f.min(1e30,f.pow(1.008,o.totalCoinOwned)));e.highestSingularityCount>0&&(t=t.times(Math.pow(e.goldenQuarks+1,1.5)*Math.pow(e.highestSingularityCount+1,2))),e.upgrades[6]>.5&&(t=t.times(s)),e.upgrades[12]>.5&&(t=t.times(f.min(1e4,f.pow(1.01,e.prestigeCount)))),e.upgrades[20]>.5&&(t=t.times(f.pow(o.totalCoinOwned/4+1,10))),e.upgrades[41]>.5&&(t=t.times(f.min(1e30,f.pow(e.transcendPoints.add(1),1/2)))),e.upgrades[43]>.5&&(t=t.times(f.min(1e30,f.pow(1.01,e.transcendCount)))),e.upgrades[48]>.5&&(t=t.times(f.pow(o.totalMultiplier*o.totalAccelerator/1e3+1,8))),e.currentChallenge.reincarnation===6&&(t=t.dividedBy(1e250)),e.currentChallenge.reincarnation===7&&(t=t.dividedBy("1e1250")),e.currentChallenge.reincarnation===9&&(t=t.dividedBy("1e2000000")),e.currentChallenge.reincarnation===10&&(t=t.dividedBy("1e12500000")),r=f.pow(t,1+.001*e.researches[17]);let l=f.pow(r,1+.025*e.upgrades[123]);e.currentChallenge.ascension===15&&e.platonicUpgrades[5]>0&&(l=f.pow(l,1.1)),e.currentChallenge.ascension===15&&e.platonicUpgrades[14]>0&&(l=f.pow(l,1+1/20*e.usedCorruptions[9]*f.log(e.coins.add(1),10)/(1e7+f.log(e.coins.add(1),10)))),e.currentChallenge.ascension===15&&e.platonicUpgrades[15]>0&&(l=f.pow(l,1.1)),l=f.pow(l,o.challenge15Rewards.coinExponent),o.globalCoinMultiplier=l,o.globalCoinMultiplier=f.pow(o.globalCoinMultiplier,o.financialcollapsePower[e.usedCorruptions[9]]),o.coinOneMulti=new f(1),e.upgrades[1]>.5&&(o.coinOneMulti=o.coinOneMulti.times(s)),e.upgrades[10]>.5&&(o.coinOneMulti=o.coinOneMulti.times(f.pow(2,Math.min(50,e.secondOwnedCoin/15)))),e.upgrades[56]>.5&&(o.coinOneMulti=o.coinOneMulti.times("1e5000")),o.coinTwoMulti=new f(1),e.upgrades[2]>.5&&(o.coinTwoMulti=o.coinTwoMulti.times(s)),e.upgrades[13]>.5&&(o.coinTwoMulti=o.coinTwoMulti.times(f.min(1e50,f.pow(e.firstGeneratedMythos.add(e.firstOwnedMythos).add(1),4/3).times(1e10)))),e.upgrades[19]>.5&&(o.coinTwoMulti=o.coinTwoMulti.times(f.min(1e200,e.transcendPoints.times(1e30).add(1)))),e.upgrades[57]>.5&&(o.coinTwoMulti=o.coinTwoMulti.times("1e7500")),o.coinThreeMulti=new f(1),e.upgrades[3]>.5&&(o.coinThreeMulti=o.coinThreeMulti.times(s)),e.upgrades[18]>.5&&(o.coinThreeMulti=o.coinThreeMulti.times(f.min(1e125,e.transcendShards.add(1)))),e.upgrades[58]>.5&&(o.coinThreeMulti=o.coinThreeMulti.times("1e15000")),o.coinFourMulti=new f(1),e.upgrades[4]>.5&&(o.coinFourMulti=o.coinFourMulti.times(s)),e.upgrades[17]>.5&&(o.coinFourMulti=o.coinFourMulti.times(1e100)),e.upgrades[59]>.5&&(o.coinFourMulti=o.coinFourMulti.times("1e25000")),o.coinFiveMulti=new f(1),e.upgrades[5]>.5&&(o.coinFiveMulti=o.coinFiveMulti.times(s)),e.upgrades[60]>.5&&(o.coinFiveMulti=o.coinFiveMulti.times("1e35000")),o.globalCrystalMultiplier=new f(1),e.achievements[36]>.5&&(o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(2)),e.achievements[37]>.5&&e.prestigePoints.gte(10)&&(o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.log(e.prestigePoints.add(1),10))),e.achievements[44]>.5&&(o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.pow(o.rune3level/2*o.effectiveLevelMult,2).times(f.pow(2,o.rune3level*o.effectiveLevelMult/2-8)).add(1))),e.upgrades[36]>.5&&(o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.min("1e5000",f.pow(e.prestigePoints,1/500)))),e.upgrades[63]>.5&&(o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.min("1e6000",f.pow(e.reincarnationPoints.add(1),6)))),e.researches[39]>.5&&(o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.pow(o.reincarnationMultiplier,1/50))),o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.min(f.pow(10,50+2*e.crystalUpgrades[0]),f.pow(1.05,e.achievementPoints*e.crystalUpgrades[0]))),o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.min(f.pow(10,100+5*e.crystalUpgrades[1]),f.pow(f.log(e.coins.add(1),10),e.crystalUpgrades[1]/3))),o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.pow(1+Math.min(.12+.88*e.upgrades[122]+.001*e.researches[129]*Math.log(e.commonFragments+1)/Math.log(4),.001*e.crystalUpgrades[2]),e.firstOwnedDiamonds+e.secondOwnedDiamonds+e.thirdOwnedDiamonds+e.fourthOwnedDiamonds+e.fifthOwnedDiamonds)),o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.pow(1.01,(e.challengecompletions[1]+e.challengecompletions[2]+e.challengecompletions[3]+e.challengecompletions[4]+e.challengecompletions[5])*e.crystalUpgrades[4])),o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.pow(10,_("transcend",e.challengecompletions[5]))),o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.pow(1e4,e.researches[5]*(1+1/2*_("ascension",e.challengecompletions[14])))),o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.pow(2.5,e.researches[26])),o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.pow(2.5,e.researches[27])),o.globalMythosMultiplier=new f(1),e.upgrades[37]>.5&&(o.globalMythosMultiplier=o.globalMythosMultiplier.times(f.pow(f.log(e.prestigePoints.add(10),10),2))),e.upgrades[42]>.5&&(o.globalMythosMultiplier=o.globalMythosMultiplier.times(f.min(1e50,f.pow(e.prestigePoints.add(1),1/50).dividedBy(2.5).add(1)))),e.upgrades[47]>.5&&(o.globalMythosMultiplier=o.globalMythosMultiplier.times(f.pow(1.05,e.achievementPoints)).times(e.achievementPoints+1)),e.upgrades[51]>.5&&(o.globalMythosMultiplier=o.globalMythosMultiplier.times(f.pow(o.totalAcceleratorBoost,2))),e.upgrades[52]>.5&&(o.globalMythosMultiplier=o.globalMythosMultiplier.times(f.pow(o.globalMythosMultiplier,.025))),e.upgrades[64]>.5&&(o.globalMythosMultiplier=o.globalMythosMultiplier.times(f.pow(e.reincarnationPoints.add(1),2))),e.researches[40]>.5&&(o.globalMythosMultiplier=o.globalMythosMultiplier.times(f.pow(o.reincarnationMultiplier,1/250))),o.grandmasterMultiplier=new f(1),o.totalMythosOwned=e.firstOwnedMythos+e.secondOwnedMythos+e.thirdOwnedMythos+e.fourthOwnedMythos+e.fifthOwnedMythos,o.mythosBuildingPower=1+_("transcend",e.challengecompletions[3])/200,o.challengeThreeMultiplier=f.pow(o.mythosBuildingPower,o.totalMythosOwned),o.grandmasterMultiplier=o.grandmasterMultiplier.times(o.challengeThreeMultiplier),o.mythosupgrade13=new f(1),o.mythosupgrade14=new f(1),o.mythosupgrade15=new f(1),e.upgrades[53]===1&&(o.mythosupgrade13=o.mythosupgrade13.times(f.min("1e1250",f.pow(o.acceleratorEffect,1/125)))),e.upgrades[54]===1&&(o.mythosupgrade14=o.mythosupgrade14.times(f.min("1e2000",f.pow(o.multiplierEffect,1/180)))),e.upgrades[55]===1&&(o.mythosupgrade15=o.mythosupgrade15.times(f.pow("1e1000",Math.min(1e3,o.buildingPower-1)))),o.globalConstantMult=new f("1"),o.globalConstantMult=o.globalConstantMult.times(f.pow(1.05+.01*e.achievements[270]+.001*e.platonicUpgrades[18],e.constantUpgrades[1])),o.globalConstantMult=o.globalConstantMult.times(f.pow(1+.001*Math.min(100+10*e.achievements[270]+10*e.shopUpgrades.constantEX+1e3*(o.challenge15Rewards.exponent-1)+3*e.platonicUpgrades[18],e.constantUpgrades[2]),Gc())),o.globalConstantMult=o.globalConstantMult.times(1+2/100*e.researches[139]),o.globalConstantMult=o.globalConstantMult.times(1+3/100*e.researches[154]),o.globalConstantMult=o.globalConstantMult.times(1+4/100*e.researches[169]),o.globalConstantMult=o.globalConstantMult.times(1+5/100*e.researches[184]),o.globalConstantMult=o.globalConstantMult.times(1+10/100*e.researches[199]),o.globalConstantMult=o.globalConstantMult.times(o.challenge15Rewards.constantBonus),e.platonicUpgrades[5]>0&&(o.globalConstantMult=o.globalConstantMult.times(2)),e.platonicUpgrades[10]>0&&(o.globalConstantMult=o.globalConstantMult.times(10)),e.platonicUpgrades[15]>0&&(o.globalConstantMult=o.globalConstantMult.times(1e250)),o.globalConstantMult=o.globalConstantMult.times(f.pow(e.overfluxPowder+1,10*e.platonicUpgrades[16]))},kd=t=>{if(A0(),E0(),Uu(),Bu(),o2(),q0(),o.produceTotal.gte(.001)){let l=f.min(o.produceTotal.dividedBy(o.taxdivisor),f.pow(10,o.maxexponent-f.log(o.taxdivisorcheck,10))).times(t/.025);e.coins=e.coins.add(l),e.coinsThisPrestige=e.coinsThisPrestige.add(l),e.coinsThisTranscension=e.coinsThisTranscension.add(l),e.coinsThisReincarnation=e.coinsThisReincarnation.add(l),e.coinsTotal=e.coinsTotal.add(l)}c2(),e.upgrades[93]===1&&e.coinsThisPrestige.gte(1e16)&&(e.prestigePoints=e.prestigePoints.add(f.floor(o.prestigePointGain.dividedBy(4e3).times(t/.025)))),e.upgrades[100]===1&&e.coinsThisTranscension.gte(1e100)&&(e.transcendPoints=e.transcendPoints.add(f.floor(o.transcendPointGain.dividedBy(4e3).times(t/.025)))),e.cubeUpgrades[28]>0&&e.transcendShards.gte(1e300)&&(e.reincarnationPoints=e.reincarnationPoints.add(f.floor(o.reincarnationPointGain.dividedBy(4e3).times(t/.025)))),o.produceFirstDiamonds=e.firstGeneratedDiamonds.add(e.firstOwnedDiamonds).times(e.firstProduceDiamonds).times(o.globalCrystalMultiplier),o.produceSecondDiamonds=e.secondGeneratedDiamonds.add(e.secondOwnedDiamonds).times(e.secondProduceDiamonds).times(o.globalCrystalMultiplier),o.produceThirdDiamonds=e.thirdGeneratedDiamonds.add(e.thirdOwnedDiamonds).times(e.thirdProduceDiamonds).times(o.globalCrystalMultiplier),o.produceFourthDiamonds=e.fourthGeneratedDiamonds.add(e.fourthOwnedDiamonds).times(e.fourthProduceDiamonds).times(o.globalCrystalMultiplier),o.produceFifthDiamonds=e.fifthGeneratedDiamonds.add(e.fifthOwnedDiamonds).times(e.fifthProduceDiamonds).times(o.globalCrystalMultiplier),e.fourthGeneratedDiamonds=e.fourthGeneratedDiamonds.add(o.produceFifthDiamonds.times(t/.025)),e.thirdGeneratedDiamonds=e.thirdGeneratedDiamonds.add(o.produceFourthDiamonds.times(t/.025)),e.secondGeneratedDiamonds=e.secondGeneratedDiamonds.add(o.produceThirdDiamonds.times(t/.025)),e.firstGeneratedDiamonds=e.firstGeneratedDiamonds.add(o.produceSecondDiamonds.times(t/.025)),o.produceDiamonds=o.produceFirstDiamonds,e.currentChallenge.transcension!==3&&e.currentChallenge.reincarnation!==10&&(e.prestigeShards=e.prestigeShards.add(o.produceDiamonds.times(t/.025))),o.produceFifthMythos=e.fifthGeneratedMythos.add(e.fifthOwnedMythos).times(e.fifthProduceMythos).times(o.globalMythosMultiplier).times(o.grandmasterMultiplier).times(o.mythosupgrade15),o.produceFourthMythos=e.fourthGeneratedMythos.add(e.fourthOwnedMythos).times(e.fourthProduceMythos).times(o.globalMythosMultiplier),o.produceThirdMythos=e.thirdGeneratedMythos.add(e.thirdOwnedMythos).times(e.thirdProduceMythos).times(o.globalMythosMultiplier).times(o.mythosupgrade14),o.produceSecondMythos=e.secondGeneratedMythos.add(e.secondOwnedMythos).times(e.secondProduceMythos).times(o.globalMythosMultiplier),o.produceFirstMythos=e.firstGeneratedMythos.add(e.firstOwnedMythos).times(e.firstProduceMythos).times(o.globalMythosMultiplier).times(o.mythosupgrade13),e.fourthGeneratedMythos=e.fourthGeneratedMythos.add(o.produceFifthMythos.times(t/.025)),e.thirdGeneratedMythos=e.thirdGeneratedMythos.add(o.produceFourthMythos.times(t/.025)),e.secondGeneratedMythos=e.secondGeneratedMythos.add(o.produceThirdMythos.times(t/.025)),e.firstGeneratedMythos=e.firstGeneratedMythos.add(o.produceSecondMythos.times(t/.025)),o.produceMythos=new f("0"),o.produceMythos=e.firstGeneratedMythos.add(e.firstOwnedMythos).times(e.firstProduceMythos).times(o.globalMythosMultiplier).times(o.mythosupgrade13),o.producePerSecondMythos=o.produceMythos.times(40);let r=new f("1");e.upgrades[67]>.5&&(r=r.times(f.pow(1.03,e.firstOwnedParticles+e.secondOwnedParticles+e.thirdOwnedParticles+e.fourthOwnedParticles+e.fifthOwnedParticles))),o.produceFifthParticles=e.fifthGeneratedParticles.add(e.fifthOwnedParticles).times(e.fifthProduceParticles),o.produceFourthParticles=e.fourthGeneratedParticles.add(e.fourthOwnedParticles).times(e.fourthProduceParticles),o.produceThirdParticles=e.thirdGeneratedParticles.add(e.thirdOwnedParticles).times(e.thirdProduceParticles),o.produceSecondParticles=e.secondGeneratedParticles.add(e.secondOwnedParticles).times(e.secondProduceParticles),o.produceFirstParticles=e.firstGeneratedParticles.add(e.firstOwnedParticles).times(e.firstProduceParticles).times(r),e.fourthGeneratedParticles=e.fourthGeneratedParticles.add(o.produceFifthParticles.times(t/.025)),e.thirdGeneratedParticles=e.thirdGeneratedParticles.add(o.produceFourthParticles.times(t/.025)),e.secondGeneratedParticles=e.secondGeneratedParticles.add(o.produceThirdParticles.times(t/.025)),e.firstGeneratedParticles=e.firstGeneratedParticles.add(o.produceSecondParticles.times(t/.025)),o.produceParticles=new f("0"),o.produceParticles=e.firstGeneratedParticles.add(e.firstOwnedParticles).times(e.firstProduceParticles).times(r),o.producePerSecondParticles=o.produceParticles.times(40),e.currentChallenge.transcension!==3&&e.currentChallenge.reincarnation!==10&&(e.transcendShards=e.transcendShards.add(o.produceMythos.times(t/.025))),e.currentChallenge.reincarnation!==10&&(e.reincarnationShards=e.reincarnationShards.add(o.produceParticles.times(t/.025))),l2(t);for(let l=1;l<=5;l++)if(o.ascendBuildingProduction[o.ordinals[5-l]]=e[`ascendBuilding${6-l}`].generated.add(e[`ascendBuilding${6-l}`].owned).times(e[`ascendBuilding${l}`].multiplier).times(o.globalConstantMult),l!==5){let c=5-l;e[`ascendBuilding${c}`].generated=e[`ascendBuilding${c}`].generated.add(o.ascendBuildingProduction[o.ordinals[c]].times(t))}e.ascendShards=e.ascendShards.add(o.ascendBuildingProduction.first.times(t)),e.ascensionCount>0&&Ts(2),e.researches[71]>.5&&e.challengecompletions[1].5&&e.challengecompletions[2].5&&e.challengecompletions[3].5&&e.challengecompletions[4].5&&e.challengecompletions[5]=9&&e.coins.gte(Lt(a,e.challengecompletions[a],a))&&(Ae("reincarnationChallenge",!1),o.autoChallengeTimerIncrement=0),s!==0&&s<15&&e.challengecompletions[10]>=Lt(s,e.challengecompletions[s],s)&&(Ae("ascensionChallenge",!1),fr(s,!0)),s===15&&e.coins.gte(Lt(s,e.challengecompletions[s],s))&&Ae("ascensionChallenge",!1)},i2=()=>{o.globalAntMult=new f(10),o.globalAntMult=o.globalAntMult.times(5),o.globalAntMult=o.globalAntMult.times(1+1/2500*Math.pow(o.rune5level*o.effectiveLevelMult*(1+e.researches[84]/200*(1+1*o.effectiveRuneSpiritPower[5]*Xe()/400)),2)),e.upgrades[76]===1&&(o.globalAntMult=o.globalAntMult.times(5)),o.globalAntMult=o.globalAntMult.times(f.pow(1+e.upgrades[77]/250+e.researches[96]/5e3+e.cubeUpgrades[65]/250,e.firstOwnedAnts+e.secondOwnedAnts+e.thirdOwnedAnts+e.fourthOwnedAnts+e.fifthOwnedAnts+e.sixthOwnedAnts+e.seventhOwnedAnts+e.eighthOwnedAnts)),o.globalAntMult=o.globalAntMult.times(1+e.upgrades[78]*.005*Math.pow(Math.log10(e.maxofferings+1),2)),o.globalAntMult=o.globalAntMult.times(f.pow(1.11+e.researches[101]/1e3+e.researches[162]/1e4,e.antUpgrades[0]+o.bonusant1)),o.globalAntMult=o.globalAntMult.times(Xn(e.antSacrificePoints)),o.globalAntMult=o.globalAntMult.times(f.pow(Math.max(1,e.researchPoints),o.effectiveRuneBlessingPower[5])),o.globalAntMult=o.globalAntMult.times(f.pow(1+o.runeSum/100,o.talisman6Power)),o.globalAntMult=o.globalAntMult.times(f.pow(1.1,_("reincarnation",e.challengecompletions[9]))),o.globalAntMult=o.globalAntMult.times(o.cubeBonusMultiplier[6]),e.achievements[169]===1&&(o.globalAntMult=o.globalAntMult.times(f.log(e.antPoints.add(10),10))),e.achievements[171]===1&&(o.globalAntMult=o.globalAntMult.times(1.16666)),e.achievements[172]===1&&(o.globalAntMult=o.globalAntMult.times(1+2*(1-Math.pow(2,-Math.min(1,e.reincarnationcounter/7200))))),e.upgrades[39]===1&&(o.globalAntMult=o.globalAntMult.times(1.6)),o.globalAntMult=o.globalAntMult.times(f.pow(1+.1*f.log(e.ascendShards.add(1),10),e.constantUpgrades[5])),o.globalAntMult=o.globalAntMult.times(f.pow(1e5,_("ascension",e.challengecompletions[11]))),e.researches[147]>0&&(o.globalAntMult=o.globalAntMult.times(f.log(e.antPoints.add(10),10))),e.researches[177]>0&&(o.globalAntMult=o.globalAntMult.times(f.pow(f.log(e.antPoints.add(10),10),e.researches[177]))),e.currentChallenge.ascension===12&&(o.globalAntMult=f.pow(o.globalAntMult,.5)),e.currentChallenge.ascension===13&&(o.globalAntMult=f.pow(o.globalAntMult,.23)),e.currentChallenge.ascension===14&&(o.globalAntMult=f.pow(o.globalAntMult,.2)),e.currentChallenge.ascension!==15?o.globalAntMult=f.pow(o.globalAntMult,1-.9/90*Math.min(99,ae(e.usedCorruptions))):o.globalAntMult=f.pow(o.globalAntMult,.01),o.globalAntMult=f.pow(o.globalAntMult,o.extinctionMultiplier[e.usedCorruptions[7]]),o.globalAntMult=o.globalAntMult.times(o.challenge15Rewards.antSpeed),o.globalAntMult=o.globalAntMult.times(f.pow(1.2,e.shopUpgrades.antSpeed)),e.platonicUpgrades[12]>0&&(o.globalAntMult=o.globalAntMult.times(f.pow(1+1/100*e.platonicUpgrades[12],ae(e.highestchallengecompletions)))),e.currentChallenge.ascension===15&&e.platonicUpgrades[10]>0&&(o.globalAntMult=f.pow(o.globalAntMult,1.25)),e.achievements[274]>0&&(o.globalAntMult=o.globalAntMult.times(4.44)),e.usedCorruptions[7]>=14&&(o.globalAntMult=f.pow(o.globalAntMult,.02)),e.usedCorruptions[7]>=15&&(o.globalAntMult=f.pow(o.globalAntMult,.02)),e.usedCorruptions[7]>=16&&(o.globalAntMult=f.pow(o.globalAntMult,.02)),e.octeractUpgrades.octeractStarter.getEffect().bonus&&(o.globalAntMult=o.globalAntMult.times(1e5)),e.highestSingularityCount>=30&&(o.globalAntMult=o.globalAntMult.times(1e3)),e.highestSingularityCount>=70&&(o.globalAntMult=o.globalAntMult.times(1e3)),e.highestSingularityCount>=100&&(o.globalAntMult=o.globalAntMult.times(1e6))},l2=t=>{i2(),o.antEightProduce=e.eighthGeneratedAnts.add(e.eighthOwnedAnts).times(e.eighthProduceAnts).times(o.globalAntMult),o.antSevenProduce=e.seventhGeneratedAnts.add(e.seventhOwnedAnts).times(e.seventhProduceAnts).times(o.globalAntMult),o.antSixProduce=e.sixthGeneratedAnts.add(e.sixthOwnedAnts).times(e.sixthProduceAnts).times(o.globalAntMult),o.antFiveProduce=e.fifthGeneratedAnts.add(e.fifthOwnedAnts).times(e.fifthProduceAnts).times(o.globalAntMult),o.antFourProduce=e.fourthGeneratedAnts.add(e.fourthOwnedAnts).times(e.fourthProduceAnts).times(o.globalAntMult),o.antThreeProduce=e.thirdGeneratedAnts.add(e.thirdOwnedAnts).times(e.thirdProduceAnts).times(o.globalAntMult),o.antTwoProduce=e.secondGeneratedAnts.add(e.secondOwnedAnts).times(e.secondProduceAnts).times(o.globalAntMult),o.antOneProduce=e.firstGeneratedAnts.add(e.firstOwnedAnts).times(e.firstProduceAnts).times(o.globalAntMult),e.seventhGeneratedAnts=e.seventhGeneratedAnts.add(o.antEightProduce.times(t/1)),e.sixthGeneratedAnts=e.sixthGeneratedAnts.add(o.antSevenProduce.times(t/1)),e.fifthGeneratedAnts=e.fifthGeneratedAnts.add(o.antSixProduce.times(t/1)),e.fourthGeneratedAnts=e.fourthGeneratedAnts.add(o.antFiveProduce.times(t/1)),e.thirdGeneratedAnts=e.thirdGeneratedAnts.add(o.antFourProduce.times(t/1)),e.secondGeneratedAnts=e.secondGeneratedAnts.add(o.antThreeProduce.times(t/1)),e.firstGeneratedAnts=e.firstGeneratedAnts.add(o.antTwoProduce.times(t/1)),e.antPoints=e.antPoints.add(o.antOneProduce.times(t/1))},c2=()=>{let t=.5+_("transcend",e.challengecompletions[5])/100,r=.03;e.currentChallenge.transcension===5&&(t=.01/(1+e.challengecompletions[5]),r=.001),e.currentChallenge.reincarnation===10&&(t=1e-4/(1+e.challengecompletions[10]),r=.001),t*=o.deflationMultiplier[e.usedCorruptions[6]],o.prestigePointGain=f.floor(f.pow(e.coinsThisPrestige.dividedBy(1e12),t)),e.upgrades[16]>.5&&e.currentChallenge.transcension!==5&&e.currentChallenge.reincarnation!==10&&(o.prestigePointGain=o.prestigePointGain.times(f.min(f.pow(10,1e33),f.pow(o.acceleratorEffect,1/3*o.deflationMultiplier[e.usedCorruptions[6]])))),o.transcendPointGain=f.floor(f.pow(e.coinsThisTranscension.dividedBy(1e100),r)),e.upgrades[44]>.5&&e.currentChallenge.transcension!==5&&e.currentChallenge.reincarnation!==10&&(o.transcendPointGain=o.transcendPointGain.times(f.min(1e6,f.pow(1.01,e.transcendCount)))),o.reincarnationPointGain=f.floor(f.pow(e.transcendShards.dividedBy(1e300),.01)),e.currentChallenge.reincarnation!==0&&(o.reincarnationPointGain=f.pow(o.reincarnationPointGain,.01)),e.achievements[50]===1&&(o.reincarnationPointGain=o.reincarnationPointGain.times(2)),e.upgrades[65]>.5&&(o.reincarnationPointGain=o.reincarnationPointGain.times(5)),e.currentChallenge.ascension===12&&(o.reincarnationPointGain=new f("0"))},Ae=async(t,r=!0,n=!1)=>{if(t==="prestige"&&(e.coinsThisPrestige.gte(1e16)||o.prestigePointGain.gte(100))&&(r?Kl("prestige"):(vt(1),Pe("prestige"))),t==="transcension"&&(e.coinsThisTranscension.gte(1e100)||o.transcendPointGain.gte(.5))&&e.currentChallenge.transcension===0&&(r&&Kl("transcend"),r||(vt(2),Pe("transcension"))),t==="transcensionChallenge"&&e.currentChallenge.transcension!==0){let a=e.currentChallenge.transcension,s=je(a),l=c=>e.coinsThisTranscension.gte(Lt(a,c,a));if(l(e.challengecompletions[a])&&e.challengecompletions[a]0&&(c=10),e.shopUpgrades.instantChallenge2>0&&(c+=e.highestSingularityCount),e.currentChallenge.ascension===13&&(c=1);let p=0,g=e.challengecompletions[a];for(;pe.highestchallengecompletions[a]){for(;e.challengecompletions[a]>e.highestchallengecompletions[a];)e.highestchallengecompletions[a]+=1,Ld(a,e.highestchallengecompletions[a]);Gt()}fr(a),(!e.retrychallenges||r||e.autoChallengeRunning&&e.challengecompletions[a]>=s)&&(pr("ENTER"),e.currentChallenge.transcension=0,Sr()),(e.shopUpgrades.instantChallenge===0||n)&&(Pe("transcensionChallenge",!1,"leaveChallenge"),e.transcendCount-=1)}if(t==="reincarnation"&&o.reincarnationPointGain.gt(.5)&&e.currentChallenge.transcension===0&&e.currentChallenge.reincarnation===0&&(r&&Kl("reincarnate"),r||(vt(3),Pe("reincarnation"))),t==="reincarnationChallenge"&&e.currentChallenge.reincarnation!==0){let a=e.currentChallenge.reincarnation,s=je(a),l=c=>a<=8?e.transcendShards.gte(Lt(a,c,a)):e.coins.gte(Lt(a,c,a));if(l(e.challengecompletions[a])&&e.challengecompletions[a]0&&(c=10),e.shopUpgrades.instantChallenge2>0&&(c+=e.highestSingularityCount),e.currentChallenge.ascension===13&&(c=1);let p=0,g=e.challengecompletions[a];for(;pe.highestchallengecompletions[a]){for(;e.challengecompletions[a]>e.highestchallengecompletions[a];)e.highestchallengecompletions[a]+=1,Ld(a,e.highestchallengecompletions[a]);ta(),ra(),Gt()}if(fr(a),!e.retrychallenges||r||e.autoChallengeRunning&&e.challengecompletions[a]>=s){if(pr("ENTER"),e.currentChallenge.reincarnation=0,e.shopUpgrades.instantChallenge>0)for(let c=1;c<=5;c++)e.challengecompletions[c]=e.highestchallengecompletions[c];Sr(),He(),Bt()}(e.shopUpgrades.instantChallenge===0||n)&&(Pe("reincarnationChallenge",!1,"leaveChallenge"),e.reincarnationCount-=1)}if(t==="ascension"&&e.achievements[141]>0&&(!e.toggles[31]||e.challengecompletions[10]>0)&&r&&Kl("ascend"),t==="ascensionChallenge"&&e.currentChallenge.ascension!==0){let a=!0;if(r&&(e.challengecompletions[11]===0||e.toggles[31])&&(a=await we(u.t("main.exitAscensionChallenge"))),!a)return;let s=e.currentChallenge.ascension,l=je(s);if(s!==0&&s<15&&(e.challengecompletions[10]>=Lt(s,e.challengecompletions[s],s)&&e.challengecompletions[s]0)&&e.usedCorruptions.slice(2,10).every(p=>p===11)&&e.coins.gte(f.pow(10,e.challenge15Exponent/c))&&(e.challenge15Exponent=f.log(e.coins.add(1),10)*c,il())}e.challengecompletions[s]>e.highestchallengecompletions[s]&&(e.highestchallengecompletions[s]+=1,e.wowHypercubes.add(1),e.highestchallengecompletions[s]>=l&&(n=!0)),(!e.retrychallenges||r||n)&&(!r&&(zo()||!e.autoChallengeRunning)&&e.autoAscend&&e.challengecompletions[11]>0&&e.cubeUpgrades[10]>0||(e.currentChallenge.ascension=0,Sr())),(e.shopUpgrades.instantChallenge2===0&&s!==15||r)&&Pe("ascensionChallenge",!1)}if(t==="singularity"){if(e.runelevels[6]===0)return P(u.t("main.noAntiquity"));let a=300;if(e.insideSingularityChallenge)return P(u.t("main.insideSingularityChallenge"));if(e.singularityCount>=a)return P(u.t("main.gameBeat"));let s=!1,l=e.singularityCount+1+ua();return!e.toggles[33]&&e.singularityCount>0?s=await we(u.t("main.singularityConfirm0",{x:d(l),y:d(Wt(),2,!0)})):(await P(u.t("main.singularityMessage1",{x:d(e.singularityCount)})),await P(u.t("main.singularityMessage2")),await P(u.t("main.singularityMessage3")),await P(u.t("main.singularityMessage4",{x:d(l),y:d(Wt(),2,!0),z:d(er())})),await P(u.t("main.singularityMessage5")),s=await we(u.t("main.singularityConfirm1")),s&&(s=await we(u.t("main.singularityConfirm2"))),s&&(s=await we(u.t("main.singularityConfirm3")))),s?(await ms(),hr(),P(u.t("main.welcomeToSingularity",{x:d(e.singularityCount)}))):P(u.t("main.singularityCancelled"))}},Kl=async t=>{t==="prestige"&&(e.toggles[28]?await we(u.t("main.prestigePrompt"))&&(vt(1),Pe("prestige")):(vt(1),Pe("prestige"))),t==="transcend"&&(e.toggles[29]?await we(u.t("main.transcendPrompt"))&&(vt(2),Pe("transcension")):(vt(2),Pe("transcension"))),t==="reincarnate"&&e.currentChallenge.ascension!==12&&(e.toggles[30]?await we(u.t("main.reincarnatePrompt"))&&(vt(3),Pe("reincarnation")):(vt(3),Pe("reincarnation"))),t==="ascend"&&(!e.toggles[31]||await we(u.t("main.ascendPrompt")))&&Pe("ascension")},Au=()=>{o.effectiveLevelMult=1,o.effectiveLevelMult*=1+e.researches[4]/10*(1+1/2*_("ascension",e.challengecompletions[14])),o.effectiveLevelMult*=1+e.researches[21]/100,o.effectiveLevelMult*=1+e.researches[90]/100,o.effectiveLevelMult*=1+e.researches[131]/200,o.effectiveLevelMult*=1+e.researches[161]/200*3/5,o.effectiveLevelMult*=1+e.researches[176]/200*2/5,o.effectiveLevelMult*=1+e.researches[191]/200*1/5,o.effectiveLevelMult*=1+e.researches[146]/200*4/5,o.effectiveLevelMult*=1+.01*Math.log(e.talismanShards+1)/Math.log(4)*Math.min(1,e.constantUpgrades[9]),o.effectiveLevelMult*=o.challenge15Rewards.runeBonus},Oo=()=>{o.uFourteenMulti=new f(1),o.uFifteenMulti=new f(1),e.upgrades[14]>.5&&(o.uFourteenMulti=f.pow(1.15,o.freeAccelerator)),e.upgrades[15]>.5&&(o.uFifteenMulti=f.pow(1.15,o.freeAccelerator)),!e.unlocks.coinone&&e.coins.gte(500)&&(e.unlocks.coinone=!0,Oe()),!e.unlocks.cointwo&&e.coins.gte(1e4)&&(e.unlocks.cointwo=!0,Oe()),!e.unlocks.cointhree&&e.coins.gte(1e5)&&(e.unlocks.cointhree=!0,Oe()),!e.unlocks.coinfour&&e.coins.gte(4e6)&&(e.unlocks.coinfour=!0,Oe()),e.achievements[169]===0&&e.antPoints.gte(3)&&R(169),e.achievements[170]===0&&e.antPoints.gte(1e5)&&R(170),e.achievements[171]===0&&e.antPoints.gte(666666666)&&R(171),e.achievements[172]===0&&e.antPoints.gte(1e20)&&R(172),e.achievements[173]===0&&e.antPoints.gte(1e40)&&R(173),e.achievements[174]===0&&e.antPoints.gte("1e500")&&R(174),e.achievements[175]===0&&e.antPoints.gte("1e2500")&&R(175),e.researches[200]>=1e5&&e.achievements[250]<1&&R(250),e.cubeUpgrades[50]>=1e5&&e.achievements[251]<1&&R(251),Cg(),e.toggles[1]&&e.upgrades[81]===1&&e.coins.gte(e.firstCostCoin)&&dt(1,"Coin"),e.toggles[2]&&e.upgrades[82]===1&&e.coins.gte(e.secondCostCoin)&&dt(2,"Coin"),e.toggles[3]&&e.upgrades[83]===1&&e.coins.gte(e.thirdCostCoin)&&dt(3,"Coin"),e.toggles[4]&&e.upgrades[84]===1&&e.coins.gte(e.fourthCostCoin)&&dt(4,"Coin"),e.toggles[5]&&e.upgrades[85]===1&&e.coins.gte(e.fifthCostCoin)&&dt(5,"Coin"),e.toggles[6]&&e.upgrades[86]===1&&e.coins.gte(e.acceleratorCost)&&Ss(!0),e.toggles[7]&&e.upgrades[87]===1&&e.coins.gte(e.multiplierCost)&&ks(!0),e.toggles[8]&&e.upgrades[88]===1&&e.prestigePoints.gte(e.acceleratorBoostCost)&&Fa(!0),e.toggles[10]&&e.achievements[78]===1&&e.prestigePoints.gte(e.firstCostDiamonds)&&dt(1,"Diamonds"),e.toggles[11]&&e.achievements[85]===1&&e.prestigePoints.gte(e.secondCostDiamonds)&&dt(2,"Diamonds"),e.toggles[12]&&e.achievements[92]===1&&e.prestigePoints.gte(e.thirdCostDiamonds)&&dt(3,"Diamonds"),e.toggles[13]&&e.achievements[99]===1&&e.prestigePoints.gte(e.fourthCostDiamonds)&&dt(4,"Diamonds"),e.toggles[14]&&e.achievements[106]===1&&e.prestigePoints.gte(e.fifthCostDiamonds)&&dt(5,"Diamonds"),Au();let t=0;if(t+=Math.floor(o.rune3level/16*o.effectiveLevelMult)*100/100,e.upgrades[73]>.5&&e.currentChallenge.reincarnation!==0&&(t+=10),e.achievements[79]>.5&&e.prestigeShards.gte(f.pow(10,o.crystalUpgradesCost[0]+o.crystalUpgradeCostIncrement[0]*Math.floor(Math.pow(e.crystalUpgrades[0]-.5-t,2)/2)))&&zt(1,!0),e.achievements[86]>.5&&e.prestigeShards.gte(f.pow(10,o.crystalUpgradesCost[1]+o.crystalUpgradeCostIncrement[1]*Math.floor(Math.pow(e.crystalUpgrades[1]-.5-t,2)/2)))&&zt(2,!0),e.achievements[93]>.5&&e.prestigeShards.gte(f.pow(10,o.crystalUpgradesCost[2]+o.crystalUpgradeCostIncrement[2]*Math.floor(Math.pow(e.crystalUpgrades[2]-.5-t,2)/2)))&&zt(3,!0),e.achievements[100]>.5&&e.prestigeShards.gte(f.pow(10,o.crystalUpgradesCost[3]+o.crystalUpgradeCostIncrement[3]*Math.floor(Math.pow(e.crystalUpgrades[3]-.5-t,2)/2)))&&zt(4,!0),e.achievements[107]>.5&&e.prestigeShards.gte(f.pow(10,o.crystalUpgradesCost[4]+o.crystalUpgradeCostIncrement[4]*Math.floor(Math.pow(e.crystalUpgrades[4]-.5-t,2)/2)))&&zt(5,!0),e.toggles[16]&&e.upgrades[94]===1&&e.transcendPoints.gte(e.firstCostMythos)&&dt(1,"Mythos"),e.toggles[17]&&e.upgrades[95]===1&&e.transcendPoints.gte(e.secondCostMythos)&&dt(2,"Mythos"),e.toggles[18]&&e.upgrades[96]===1&&e.transcendPoints.gte(e.thirdCostMythos)&&dt(3,"Mythos"),e.toggles[19]&&e.upgrades[97]===1&&e.transcendPoints.gte(e.fourthCostMythos)&&dt(4,"Mythos"),e.toggles[20]&&e.upgrades[98]===1&&e.transcendPoints.gte(e.fifthCostMythos)&&dt(5,"Mythos"),e.toggles[22]&&e.cubeUpgrades[7]===1&&e.reincarnationPoints.gte(e.firstCostParticles)&&wn(1,!0),e.toggles[23]&&e.cubeUpgrades[7]===1&&e.reincarnationPoints.gte(e.secondCostParticles)&&wn(2,!0),e.toggles[24]&&e.cubeUpgrades[7]===1&&e.reincarnationPoints.gte(e.thirdCostParticles)&&wn(3,!0),e.toggles[25]&&e.cubeUpgrades[7]===1&&e.reincarnationPoints.gte(e.fourthCostParticles)&&wn(4,!0),e.toggles[26]&&e.cubeUpgrades[7]===1&&e.reincarnationPoints.gte(e.fifthCostParticles)&&wn(5,!0),e.researches[175]>0)for(let c=1;c<=10;c++)e.ascendShards.gte(eo(c).pop())&&to(c,!0);if(e.researches[190]>0&&e.tesseractAutoBuyerToggle===1&&e.resettoggle4<2){let c=[null,null,null,null,null];for(let m=1;m<=5;m++)e.autoTesseracts[m]&&(c[m-1]=e[`ascendBuilding${m}`].owned);let p=Number(e.wowTesseracts)-e.tesseractAutoBuyerAmount,g=Cl(c,p);for(let m=5;m>=1;m--){let h=c[m-1],b=g[m-1];h!==null&&b!==null&&b!==h&&Da(m,b-h)}}if(e.researches[130]>0||e.researches[135]>0){let c=[e.achievements[119]>0,e.achievements[126]>0,e.achievements[133]>0,e.achievements[140]>0,e.achievements[147]>0,e.antUpgrades[11]>0||e.ascensionCount>0,_l()],p=!1;if(e.autoEnhanceToggle&&e.researches[135]>0)for(let g=0;g0)for(let g=0;g.5&&(e.fourthGeneratedCoin=e.fourthGeneratedCoin.add(e.fifthGeneratedCoin.add(e.fifthOwnedCoin).times(o.uFifteenMulti).times(o.generatorPower))),e.upgrades[102]>.5&&(e.thirdGeneratedCoin=e.thirdGeneratedCoin.add(e.fourthGeneratedCoin.add(e.fourthOwnedCoin).times(o.uFourteenMulti).times(o.generatorPower))),e.upgrades[103]>.5&&(e.secondGeneratedCoin=e.secondGeneratedCoin.add(e.thirdGeneratedCoin.add(e.thirdOwnedCoin).times(o.generatorPower))),e.upgrades[104]>.5&&(e.firstGeneratedCoin=e.firstGeneratedCoin.add(e.secondGeneratedCoin.add(e.secondOwnedCoin).times(o.generatorPower))),e.upgrades[105]>.5&&(e.fifthGeneratedCoin=e.fifthGeneratedCoin.add(e.firstOwnedCoin));let r=1;r+=1/100*(e.achievements[71]+e.achievements[72]+e.achievements[73]+e.achievements[74]+e.achievements[75]+e.achievements[76]+e.achievements[77]);let n=0;e.upgrades[106]>.5&&(n+=.1),e.upgrades[107]>.5&&(n+=.15),e.upgrades[108]>.5&&(n+=.25),e.upgrades[109]>.5&&(n+=.25),e.upgrades[110]>.5&&(n+=.25),n*=r;let a=0;if(e.upgrades[111]>.5&&(a+=.08),e.upgrades[112]>.5&&(a+=.08),e.upgrades[113]>.5&&(a+=.08),e.upgrades[114]>.5&&(a+=.08),e.upgrades[115]>.5&&(a+=.08),a*=r,t=0,e.upgrades[116]>.5&&(t+=.05),e.upgrades[117]>.5&&(t+=.05),e.upgrades[118]>.5&&(t+=.05),e.upgrades[119]>.5&&(t+=.05),e.upgrades[120]>.5&&(t+=.05),t*=r,n!==0&&(e.fifthGeneratedCoin=e.fifthGeneratedCoin.add(f.pow(e.firstGeneratedDiamonds.add(e.firstOwnedDiamonds).add(1),n))),a!==0&&(e.fifthGeneratedDiamonds=e.fifthGeneratedDiamonds.add(f.pow(e.firstGeneratedMythos.add(e.firstOwnedMythos).add(1),a))),t!==0&&(e.fifthGeneratedMythos=e.fifthGeneratedMythos.add(f.pow(e.firstGeneratedParticles.add(e.firstOwnedParticles).add(1),t))),e.runeshards>e.maxofferings&&(e.maxofferings=e.runeshards),e.researchPoints>e.maxobtainium&&(e.maxobtainium=e.researchPoints),isNaN(e.runeshards)&&(e.runeshards=0),e.runeshards>1e300&&(e.runeshards=1e300),isNaN(e.researchPoints)&&(e.researchPoints=0),e.researchPoints>1e300&&(e.researchPoints=1e300),o.optimalOfferingTimer=600+30*e.researches[85]+.4*o.rune5level+120*e.shopUpgrades.offeringEX,o.optimalObtainiumTimer=3600+120*e.shopUpgrades.obtainiumEX,Jf(),e.autoAscend&&e.challengecompletions[11]>0&&e.cubeUpgrades[10]>0&&e.currentChallenge.reincarnation!==10){let c=!1;if(e.autoAscendMode==="c10Completions"&&e.challengecompletions[10]>=Math.max(1,e.autoAscendThreshold)&&(c=!0),e.autoAscendMode==="realAscensionTime"&&e.ascensionCounterRealReal>=Math.max(.1,e.autoAscendThreshold)&&(c=!0),c&&e.challengecompletions[10]>0)if(zo()&&e.currentChallenge.ascension!==0&&e.retrychallenges&&e.researches[150]===1&&e.autoChallengeRunning){let p=Ko(e.currentChallenge.ascension+1,!1,11,15);p<=15&&e.currentChallenge.ascension!==p?(Ae("ascensionChallenge",!1,!0),e.currentChallenge.ascension=p,Pe("ascensionChallenge",!1)):(p=Ko(e.currentChallenge.ascension+1,!0,11,15),Ae("ascensionChallenge",!1,!0),e.currentChallenge.ascension=p<=15?p:0,Pe("ascensionChallenge",!1))}else e.currentChallenge.ascension!==0?(Ae("ascensionChallenge",!1,!0),Pe("ascensionChallenge",!1)):Pe("ascension",!1)}let s=null;if(e.researches[175]>0)for(let c=1;c<=10;c++)s=eo(c),e.ascendShards.gte(s[1])&&to(c,!0);let l=xl();if(l!==o.prevReductionValue){o.prevReductionValue=l;let c=["Coin","Diamonds","Mythos"];for(let p=0;p0&&e.currentChallenge.ascension===15&&e.usedCorruptions.slice(2,10).every(c=>c===11)){let c=xo();e.coins.gte(f.pow(10,e.challenge15Exponent/c))&&(e.challenge15Exponent=f.log(e.coins.add(1),10)*c,il())}},u2=()=>{Oo(),cd()},d2=()=>{x0(),S0()},p2=()=>{It(hr,5e3),It(d2,200),It(u2,50),o.timeWarp||Ds()},Bd=0,g2=()=>{Bd=performance.now(),It(b2,5)},K0=5,m2=20,zl=0,f2=new Date,h2=performance.now(),tl=()=>f2.getTime()+(performance.now()-h2),b2=()=>{let r=performance.now()-Bd;zl+=(r-zl)/m2;let n;for(;r>5;)n=K0,n+=zl>16?Math.min(3600*1e3,zl-K0):0,n=Math.min(r,n),y2(n/1e3),Bd+=n,r-=n},y2=t=>{if(!o.timeWarp){let r=qe().mult;if(kd(t*r),Ie("prestige",t),Ie("transcension",t),Ie("reincarnation",t),Ie("ascension",t),Ie("quarks",t),Ie("goldenQuarks",t),Ie("octeracts",t),Ie("singularity",t),Ie("autoPotion",t),Ie("ambrosia",t),e.shopUpgrades.offeringAuto>0&&e.autoSacrificeToggle&&Or("runeSacrifice",t),e.achievements[173]===1&&Or("antSacrifice",t),e.researches[61]===1?Or("addObtainium",t):Ar(),e.autoResearchToggle&&e.autoResearch>0&&e.autoResearch<=yg(e)&&(Ht()||e.autoResearchMode==="manual")){let n=0,a=1+e.challengecompletions[14];for(;n0;){{let s=e.autoResearch===200?.01:0;if(!Fr(e.autoResearch,!0,s))break}n++}}}if(e.highestchallengecompletions[3]>0&&Or("addOfferings",t/2),e.cubeUpgrades[2]>0&&Or("addOfferings",t*e.cubeUpgrades[2]),N0(t),(e.resettoggle1===1||e.resettoggle1===0)&&e.toggles[15]&&e.achievements[43]===1&&o.prestigePointGain.gte(e.prestigePoints.times(f.pow(10,e.prestigeamount)))&&e.coinsThisPrestige.gte(1e16)&&(vt(1),Pe("prestige",!0)),e.resettoggle1===2){o.autoResetTimers.prestige+=t;let r=Math.max(.01,e.prestigeamount);e.toggles[15]&&e.achievements[43]===1&&o.autoResetTimers.prestige>=r&&e.coinsThisPrestige.gte(1e16)&&(vt(1),Pe("prestige",!0))}if((e.resettoggle2===1||e.resettoggle2===0)&&e.toggles[21]&&e.upgrades[89]===1&&o.transcendPointGain.gte(e.transcendPoints.times(f.pow(10,e.transcendamount)))&&e.coinsThisTranscension.gte(1e100)&&e.currentChallenge.transcension===0&&(vt(2),Pe("transcension",!0)),e.resettoggle2===2){o.autoResetTimers.transcension+=t;let r=Math.max(.01,e.transcendamount);e.toggles[21]&&e.upgrades[89]===1&&o.autoResetTimers.transcension>=r&&e.coinsThisTranscension.gte(1e100)&&e.currentChallenge.transcension===0&&(vt(2),Pe("transcension",!0))}if(e.currentChallenge.ascension!==12){if(o.autoResetTimers.reincarnation+=t,e.resettoggle3===2){let r=Math.max(.01,e.reincarnationamount);e.toggles[27]&&e.researches[46]>.5&&e.transcendShards.gte("1e300")&&o.autoResetTimers.reincarnation>=r&&e.currentChallenge.transcension===0&&e.currentChallenge.reincarnation===0&&(vt(3),Pe("reincarnation",!0))}(e.resettoggle3===1||e.resettoggle3===0)&&e.toggles[27]&&e.researches[46]>.5&&o.reincarnationPointGain.gte(e.reincarnationPoints.add(1).times(f.pow(10,e.reincarnationamount)))&&e.transcendShards.gte(1e300)&&e.currentChallenge.transcension===0&&e.currentChallenge.reincarnation===0&&(vt(3),Pe("reincarnation",!0))}Qr("reincarnation")},kf=(t,r)=>{if(!e.toggles[40])return;let a={coin:"Coin",diamond:"Diamonds",mythos:"Mythos",particle:"Particles",tesseract:"Tesseracts"}[o.buildingSubTab];if(t.shiftKey){let s=Number(r)-1;r==="BACKQUOTE"&&(s=-1),e.challengecompletions[11]>0&&!isNaN(s)&&(s>=0&&s0&&(gr(6),ot(6));break;case"7":o.currentTab===0&&o.buildingSubTab==="diamond"&&zt(2),o.currentTab===4&&e.achievements[113]===1&&(gr(7),ot(7));break;case"8":o.currentTab===0&&o.buildingSubTab==="diamond"&&zt(3),o.currentTab===4&&e.achievements[120]===1&&(gr(8),ot(8));break;case"9":o.currentTab===0&&o.buildingSubTab==="diamond"&&zt(4),o.currentTab===4&&e.achievements[127]===1&&(gr(9),ot(9));break;case"0":o.currentTab===0&&o.buildingSubTab==="diamond"&&zt(5),o.currentTab===4&&e.achievements[134]===1&&(gr(10),ot(10));break}},v2=()=>{let t=i("exitOffline");t.style.visibility="visible",Ji(()=>t.focus(),100)},td=(t=!1)=>{var s,l;du();let r=Ji(()=>i("preloadDeleteGame").style.display="block",1e4);Tl();let n=localStorage.getItem("Synergysave2");if(n){let c=z0.default.decompressFromBase64(n);if(c!==""){if(!c)return P(u.t("save.loadFailed"));let g=rs(c);if(g===null)return P(u.t("save.loadFailed"));localStorage.clear(),localStorage.setItem("Synergysave2",g),P(u.t("main.transferredFromLZ"))}r2()}if(!t)wd();else if(e.singularityChallenges.limitedTime.rewards.preserveQuarks||e.worlds.reset(),!hr())return;zi(!0),im(),Xi(),Mu(),cd(),g2(),bn(0),ve(0,{page:0}),ve(3,{page:0}),ve(4,{page:0}),ve(7,{page:0}),ve(8,{page:0}),ve(9,{page:0}),ve(10,{page:0}),Sd(),It(Sd,3e4),p2(),Ul(),pu().catch(()=>{}).finally(()=>{It(()=>pu().catch(c=>{console.error(c)}),1e3*60*5)}),v2(),uu(r),It(Ql,15e3),localStorage.getItem("pleaseStar")===null&&(P(u.t("main.starRepo")),localStorage.setItem("pleaseStar","")),typeof((s=navigator.storage)==null?void 0:s.persist)=="function"&&typeof((l=navigator.storage)==null?void 0:l.persisted)=="function"&&navigator.storage.persisted().then(c=>c?Promise.resolve(!1):navigator.storage.persist()).then(c=>{c&&P(u.t("main.dataPersistent"))});let a=i("saveType");a.checked=localStorage.getItem("copyToClipboard")!==null};window.addEventListener("load",async()=>{await V0(),xm().catch(console.error);try{await b0()}catch(n){if(console.error(n),!await we("PseudoCoin bonuses weren't fetched, if you have purchased upgrades they will not take effect. Press OK to continue to the game without upgrades."))return}let t=i("versionnumber"),r=n=>`${n}`.padStart(2,"0");if(t instanceof HTMLElement){let n=isNaN(On.getTime())?"":` [Last Update: ${r(On.getHours())}:${r(On.getMinutes())} UTC ${r(On.getDate())}-${On.toLocaleString("en-us",{month:"short"})}-${On.getFullYear()}].`;t.textContent=`You're ${!1?"testing":"playing"} v${Jt} - The Alternate Reality${n} ${!1?u.t("testing.saveInLive"):""}`}document.title=`Synergism v${Jt}`,Q0(),td(),y0(),$l()},{once:!0});window.addEventListener("unload",()=>{window.scrollTo(0,0)});})(); +${s}${l}${c}${p}${g}${m}${h}${b}${C}${v}${x}`;try{await navigator.clipboard.writeText(B)}catch(k){let L=document.createElement("textarea");L.setAttribute("style","top: 0; left: 0; position: fixed;"),L.setAttribute("data-clipboard-text",B),document.body.appendChild(L),L.focus(),L.select();let E=new J0.default(L),T=()=>{E.destroy(),document.body.removeChild(L)};E.on("success",()=>{document.getElementById("exportinfo").textContent="Copied save to clipboard!",T()}),E.on("error",()=>{P("Unable to write the save to clipboard.").finally(T)})}let U=document.createElement("a");return U.setAttribute("href",`data:text/plain;charset=utf-8,${encodeURIComponent(B)}`),U.setAttribute("download",`Statistics-${Xo()}`),U.setAttribute("id","downloadSave"),document.body.appendChild(U),U.click(),document.body.removeChild(U),P("Summary Stats saved to clipboard! We also gave you a file, for easy sharing, if that is available on your browser.")};var th=()=>{let t=["null","first","second","third","fourth","fifth","sixth","seventh","eighth"];if(!1){let w=document.createElement("button"),H=document.createElement("button");w.textContent="Click here to warp time! [TESTING ONLY]",w.setAttribute("style","width: auto; height: 30px; border: 6px solid gold;"),w.addEventListener("click",()=>q0()),H.textContent="Click to force a new day! [TESTING ONLY]",H.setAttribute("style","width: auto; height: 30px; border: 6px solid orange;"),H.addEventListener("click",()=>oo());let J=i("actualConsumables");J.appendChild(w),J.appendChild(H)}i("exitOffline").addEventListener("click",()=>Qs()),i("offlineContainer").addEventListener("dblclick",()=>Qs()),i("ascCubeStats").addEventListener("click",()=>Zr(1)),i("ascTessStats").addEventListener("click",()=>Zr(2)),i("ascHyperStats").addEventListener("click",()=>Zr(3)),i("ascPlatonicStats").addEventListener("click",()=>Zr(4)),i("ascHepteractStats").addEventListener("click",()=>Zr(5)),i("ascTimeTakenStats").addEventListener("click",()=>Zr(6)),i("prestigebtn").addEventListener("mouseover",()=>st("prestige")),i("transcendbtn").addEventListener("mouseover",()=>st("transcension")),i("reincarnatebtn").addEventListener("mouseover",()=>st("reincarnation")),i("acceleratorboostbtn").addEventListener("mouseover",()=>st("acceleratorBoost")),i("challengebtn").addEventListener("mouseover",()=>st("transcensionChallenge")),i("reincarnatechallengebtn").addEventListener("mouseover",()=>st("reincarnationChallenge")),i("ascendChallengeBtn").addEventListener("mouseover",()=>st("ascensionChallenge")),i("ascendbtn").addEventListener("mouseover",()=>st("ascension")),i("singularitybtn").addEventListener("mouseover",()=>st("singularity"));for(let w of Array.from(document.getElementsByClassName("resetbtn")))w.addEventListener("mouseover",()=>{w.classList.add("hover")}),w.addEventListener("mouseout",()=>{w.classList.remove("hover"),e.currentChallenge.reincarnation?st("reincarnationChallenge"):e.currentChallenge.transcension&&st("transcensionChallenge")});i("prestigebtn").addEventListener("click",()=>Ae("prestige")),i("transcendbtn").addEventListener("click",()=>Ae("transcension")),i("reincarnatebtn").addEventListener("click",()=>Ae("reincarnation")),i("acceleratorboostbtn").addEventListener("click",()=>Ka()),i("challengebtn").addEventListener("click",()=>Ae("transcensionChallenge",void 0,!0)),i("reincarnatechallengebtn").addEventListener("click",()=>Ae("reincarnationChallenge",void 0,!0)),i("ascendChallengeBtn").addEventListener("click",()=>Ae("ascensionChallenge")),i("ascendbtn").addEventListener("click",()=>Ae("ascension")),i("singularitybtn").addEventListener("click",()=>Ae("singularity"));let r=["Coin","Diamond","Mythos","Particle","Tesseract"];for(let w=0;wCe(0,{page:w}));let n=["coin","crystal","mythos","particle","tesseract","offering"],a=["one","ten","hundred","thousand","10k","100k"],s=[1,10,100,1e3,1e4,1e5];for(let w=0;wXm(s[w],n[H]));i("buyaccelerator").addEventListener("click",()=>Es()),i("buymultiplier").addEventListener("click",()=>Os()),i("buyacceleratorboost").addEventListener("click",()=>Ka());let l=["coin","diamond","mythos"],c=["Coin","Diamonds","Mythos"];for(let w=0;w<3;w++)for(let H=1;H<=5;H++)i(`buy${l[w]}${H}`).addEventListener("click",()=>Af(t[H],c[w],w===0?H:H*(H+1)/2));for(let w=1;w<=5;w++)i(`buycrystalupgrade${w}`).addEventListener("mouseover",()=>Ni(w)),i(`buycrystalupgrade${w}`).addEventListener("click",()=>Yt(w));for(let w=0;w<5;w++)i(`buyparticles${w+1}`).addEventListener("click",()=>wn(w+1));for(let w=0;w<5;w++)i(`buyTesseracts${w+1}`).addEventListener("click",()=>ja(w+1)),i(`tesseractAutoToggle${w+1}`).addEventListener("click",()=>bf(w+1));for(let w=0;w<10;w++)i(`buyConstantUpgrade${w+1}`).addEventListener("mouseover",()=>Kc(w+1)),i(`buyConstantUpgrade${w+1}`).addEventListener("click",()=>so(w+1));document.querySelectorAll(".auto[toggleid]").forEach(w=>w.addEventListener("click",()=>zm(w))),i("prestigeautotoggle").addEventListener("click",()=>Uo(1)),i("transcendautotoggle").addEventListener("click",()=>Uo(2)),i("reincarnateautotoggle").addEventListener("click",()=>Uo(3)),i("tesseractautobuymode").addEventListener("click",()=>Uo(4)),i("prestigeamount").addEventListener("blur",()=>br(1)),i("transcendamount").addEventListener("blur",()=>br(2)),i("reincarnationamount").addEventListener("blur",()=>br(3)),i("ascensionAmount").addEventListener("blur",()=>br(4)),i("autoAntSacrificeAmount").addEventListener("blur",()=>br(5)),i("tesseractautobuytoggle").addEventListener("click",()=>Zm()),i("tesseractAmount").addEventListener("blur",()=>Sl()),i("cubeOpensInput").addEventListener("blur",()=>Yr(1)),i("tesseractsOpensInput").addEventListener("blur",()=>Yr(2)),i("hypercubesOpensInput").addEventListener("blur",()=>Yr(3)),i("platonicCubeOpensInput").addEventListener("blur",()=>Yr(4)),i("openCubes").addEventListener("click",()=>Ro(1)),i("openTesseracts").addEventListener("click",()=>Ro(2)),i("openHypercubes").addEventListener("click",()=>Ro(3)),i("openPlatonicCube").addEventListener("click",()=>Ro(4));for(let w=1;w<=125;w++)i(`upg${w}`).addEventListener("mouseover",()=>Og(w));for(let w=1;w<=125;w++)i(`upg${w}`).addEventListener("click",()=>ba(w,!1));for(let w=1;w<=6;w++)i(`upgrades${w}`).addEventListener("click",()=>no(w,!1));i("coinAutoUpgrade").addEventListener("click",()=>Yn("coin")),i("prestigeAutoUpgrade").addEventListener("click",()=>Yn("prestige")),i("transcendAutoUpgrade").addEventListener("click",()=>Yn("transcend")),i("generatorsAutoUpgrade").addEventListener("click",()=>Yn("generators")),i("reincarnateAutoUpgrade").addEventListener("click",()=>Yn("reincarnate"));for(let w=1;w<=Fs.length-1;w++)i(`ach${w}`).addEventListener("mouseover",()=>D0(w));i("toggleautosacrifice").addEventListener("click",()=>Ou(0));for(let w=0;w<4;w++)i(`toggleRuneSubTab${w+1}`).addEventListener("click",()=>Ce(3,{page:w}));for(let w=0;w<7;w++)i(`rune${w+1}`).addEventListener("mouseover",()=>Nt(w+1)),i(`rune${w+1}`).addEventListener("click",()=>Ou(w+1)),i(`activaterune${w+1}`).addEventListener("mouseover",()=>Nt(w+1)),i(`activaterune${w+1}`).addEventListener("click",()=>Ca(w+1));let g=[10,25,50,100],m=["Ten","TwentyFive","Fifty","Hundred"];for(let w=0;wMs(g[w]));i("toggleautoBuyFragments").addEventListener("click",()=>tf()),i("toggleautoenhance").addEventListener("click",()=>of()),i("toggleautofortify").addEventListener("click",()=>sf());let h=["shard","commonFragment","uncommonFragment","rareFragment","epicFragment","legendaryFragment","mythicalFragment"];for(let w=0;wzi(h[w])),i(`buyTalismanItem${w+1}`).addEventListener("click",()=>gu(h[w]));i("buyTalismanAll").addEventListener("mouseover",()=>zi(null)),i("buyTalismanAll").addEventListener("click",()=>Xi());for(let w=0;w<7;w++)i(`talisman${w+1}`).addEventListener("click",()=>Zi(w)),i(`leveluptalisman${w+1}`).addEventListener("mouseover",()=>mu(w)),i(`leveluptalisman${w+1}`).addEventListener("click",()=>Yi(w)),i(`enhancetalisman${w+1}`).addEventListener("mouseover",()=>fu(w)),i(`enhancetalisman${w+1}`).addEventListener("click",()=>Ji(w)),i(`respectalisman${w+1}`).addEventListener("click",()=>hu(w));i("respecAllTalismans").addEventListener("click",()=>hu(7)),i("confirmTalismanRespec").addEventListener("click",()=>pm(o.talismanRespec)),i("cancelTalismanRespec").addEventListener("click",()=>gm(o.talismanRespec));for(let w=0;w<5;w++)i(`talismanRespecButton${w+1}`).addEventListener("click",()=>dm(w+1));for(let w=0;w<5;w++)i(`runeBlessingPurchase${w+1}`).addEventListener("click",()=>Us("Blessings",w+1)),i(`runeSpiritPurchase${w+1}`).addEventListener("click",()=>Us("Spirits",w+1));i("buyRuneBlessingInput").addEventListener("blur",()=>Ps(1)),i("buyRuneSpiritInput").addEventListener("blur",()=>Ps(2)),i("buyAllBlessings").addEventListener("click",()=>Bs("Blessings")),i("buyAllSpirits").addEventListener("click",()=>Bs("Spirits"));for(let w=0;w<15;w++)i(`challenge${w+1}`).addEventListener("click",()=>lt(w+1)),i(`challenge${w+1}`).addEventListener("dblclick",()=>{lt(w+1),hr(o.triggerChallenge,!1)});i("startChallenge").addEventListener("click",()=>hr(o.triggerChallenge,!1)),i("retryChallenge").addEventListener("click",()=>W0()),i("toggleAutoChallengeIgnore").addEventListener("click",()=>hf(o.triggerChallenge)),i("toggleAutoChallengeStart").addEventListener("click",()=>Bo()),i("startAutoChallengeTimerInput").addEventListener("input",()=>Jn(1)),i("exitAutoChallengeTimerInput").addEventListener("input",()=>Jn(2)),i("enterAutoChallengeTimerInput").addEventListener("input",()=>Jn(3));for(let w=0;w<2;w++)i(`toggleChallengesSubTab${w+1}`).addEventListener("click",()=>Ce(4,{page:w}));for(let w=1;w<200;w++)i(`res${w}`).addEventListener("click",()=>Fr(w)),i(`res${w}`).addEventListener("mouseover",()=>Ii(w));i("res200").addEventListener("click",()=>Fr(200,!1,.01)),i("res200").addEventListener("mouseover",()=>Ii(200,!1,.01)),i("toggleresearchbuy").addEventListener("click",()=>Ym()),i("toggleautoresearch").addEventListener("click",()=>Jm()),i("toggleautoresearchmode").addEventListener("click",()=>ef());let b=["null","1e700","3","100","10000","1e12","1e36","1e100","1e300"];for(let w=1;w<=8;w++)i(`anttier${w}`).addEventListener("mouseover",()=>ed(w)),i(`anttier${w}`).addEventListener("mouseover",()=>u0(w)),i(`anttier${w}`).addEventListener("click",()=>td(t[w],b[w],w));let C=["null","100","100","1000","1000","1e5","1e6","1e8","1e11","1e15","1e20","1e40","1e100"];for(let w=1;w<=12;w++)i(`antUpgrade${w}`).addEventListener("mouseover",()=>nd(w)),i(`antUpgrade${w}`).addEventListener("click",()=>rd(C[w],!1,w));i("antSacrifice").addEventListener("click",()=>Rs()),i("toggleAntMax").addEventListener("click",()=>vl()),i("toggleAutoSacrificeAnt").addEventListener("click",()=>ks(0)),i("autoSacrificeAntMode").addEventListener("click",()=>ks(1));for(let w=0;w<7;w++)i(`switchCubeSubTab${w+1}`).addEventListener("click",()=>Ce(7,{page:w}));for(let w=1;wXc(w)),i(`cubeUpg${w}`).addEventListener("click",()=>Yc(w));i("toggleCubeBuy").addEventListener("click",()=>mf()),i("toggleAutoCubeUpgrades").addEventListener("click",()=>Cl()),i("open1Cube").addEventListener("click",()=>e.wowCubes.open(1,!1)),i("open20Cube").addEventListener("click",()=>e.wowCubes.open(Math.floor(Number(e.wowCubes)/10),!1)),i("open1000Cube").addEventListener("click",()=>e.wowCubes.open(Math.floor(Number(e.wowCubes)/2),!1)),i("openCustomCube").addEventListener("click",()=>e.wowCubes.openCustom()),i("openMostCube").addEventListener("click",()=>e.wowCubes.open(0,!0)),i("open1Tesseract").addEventListener("click",()=>e.wowTesseracts.open(1,!1)),i("open20Tesseract").addEventListener("click",()=>e.wowTesseracts.open(Math.floor(Number(e.wowTesseracts)/10),!1)),i("open1000Tesseract").addEventListener("click",()=>e.wowTesseracts.open(Math.floor(Number(e.wowTesseracts)/2),!1)),i("openCustomTesseract").addEventListener("click",()=>e.wowTesseracts.openCustom()),i("openMostTesseract").addEventListener("click",()=>e.wowTesseracts.open(1,!0)),i("open1Hypercube").addEventListener("click",()=>e.wowHypercubes.open(1,!1)),i("open20Hypercube").addEventListener("click",()=>e.wowHypercubes.open(Math.floor(Number(e.wowHypercubes)/10),!1)),i("open1000Hypercube").addEventListener("click",()=>e.wowHypercubes.open(Math.floor(Number(e.wowHypercubes)/2),!1)),i("openCustomHypercube").addEventListener("click",()=>e.wowHypercubes.openCustom()),i("openMostHypercube").addEventListener("click",()=>e.wowHypercubes.open(1,!0)),i("open1PlatonicCube").addEventListener("click",()=>e.wowPlatonicCubes.open(1,!1)),i("open40kPlatonicCube").addEventListener("click",()=>e.wowPlatonicCubes.open(Math.floor(Number(e.wowPlatonicCubes)/10),!1)),i("open1mPlatonicCube").addEventListener("click",()=>e.wowPlatonicCubes.open(Math.floor(Number(e.wowPlatonicCubes)/2),!1)),i("openCustomPlatonicCube").addEventListener("click",()=>e.wowPlatonicCubes.openCustom()),i("openMostPlatonicCube").addEventListener("click",()=>e.wowPlatonicCubes.open(1,!0)),i("saveOffToggle").addEventListener("click",()=>lf());let v=document.getElementsByClassName("platonicUpgradeImage");for(let w=0;wru(w+1)),v[w].addEventListener("click",()=>nu(w+1));i("toggleAutoPlatonicUpgrades").addEventListener("click",()=>wl()),i("chronosHepteract").addEventListener("mouseover",()=>sn("chronos")),i("hyperrealismHepteract").addEventListener("mouseover",()=>sn("hyperrealism")),i("quarkHepteract").addEventListener("mouseover",()=>sn("quark")),i("challengeHepteract").addEventListener("mouseover",()=>sn("challenge")),i("abyssHepteract").addEventListener("mouseover",()=>sn("abyss")),i("acceleratorHepteract").addEventListener("mouseover",()=>sn("accelerator")),i("acceleratorBoostHepteract").addEventListener("mouseover",()=>sn("acceleratorBoost")),i("multiplierHepteract").addEventListener("mouseover",()=>sn("multiplier")),i("chronosHepteractCraft").addEventListener("click",()=>e.hepteractCrafts.chronos.craft()),i("hyperrealismHepteractCraft").addEventListener("click",()=>e.hepteractCrafts.hyperrealism.craft()),i("quarkHepteractCraft").addEventListener("click",()=>e.hepteractCrafts.quark.craft()),i("challengeHepteractCraft").addEventListener("click",()=>e.hepteractCrafts.challenge.craft()),i("abyssHepteractCraft").addEventListener("click",()=>e.hepteractCrafts.abyss.craft()),i("acceleratorHepteractCraft").addEventListener("click",()=>e.hepteractCrafts.accelerator.craft()),i("acceleratorBoostHepteractCraft").addEventListener("click",()=>e.hepteractCrafts.acceleratorBoost.craft()),i("multiplierHepteractCraft").addEventListener("click",()=>e.hepteractCrafts.multiplier.craft()),i("chronosHepteractCraftMax").addEventListener("click",()=>e.hepteractCrafts.chronos.craft(!0)),i("hyperrealismHepteractCraftMax").addEventListener("click",()=>e.hepteractCrafts.hyperrealism.craft(!0)),i("quarkHepteractCraftMax").addEventListener("click",()=>e.hepteractCrafts.quark.craft(!0)),i("challengeHepteractCraftMax").addEventListener("click",()=>e.hepteractCrafts.challenge.craft(!0)),i("abyssHepteractCraftMax").addEventListener("click",()=>e.hepteractCrafts.abyss.craft(!0)),i("acceleratorHepteractCraftMax").addEventListener("click",()=>e.hepteractCrafts.accelerator.craft(!0)),i("acceleratorBoostHepteractCraftMax").addEventListener("click",()=>e.hepteractCrafts.acceleratorBoost.craft(!0)),i("multiplierHepteractCraftMax").addEventListener("click",()=>e.hepteractCrafts.multiplier.craft(!0)),i("chronosHepteractCap").addEventListener("click",()=>e.hepteractCrafts.chronos.expand()),i("hyperrealismHepteractCap").addEventListener("click",()=>e.hepteractCrafts.hyperrealism.expand()),i("quarkHepteractCap").addEventListener("click",()=>e.hepteractCrafts.quark.expand()),i("challengeHepteractCap").addEventListener("click",()=>e.hepteractCrafts.challenge.expand()),i("abyssHepteractCap").addEventListener("click",()=>e.hepteractCrafts.abyss.expand()),i("acceleratorHepteractCap").addEventListener("click",()=>e.hepteractCrafts.accelerator.expand()),i("acceleratorBoostHepteractCap").addEventListener("click",()=>e.hepteractCrafts.acceleratorBoost.expand()),i("multiplierHepteractCap").addEventListener("click",()=>e.hepteractCrafts.multiplier.expand()),i("chronosHepteractAuto").addEventListener("click",()=>e.hepteractCrafts.chronos.toggleAutomatic()),i("hyperrealismHepteractAuto").addEventListener("click",()=>e.hepteractCrafts.hyperrealism.toggleAutomatic()),i("quarkHepteractAuto").addEventListener("click",()=>e.hepteractCrafts.quark.toggleAutomatic()),i("challengeHepteractAuto").addEventListener("click",()=>e.hepteractCrafts.challenge.toggleAutomatic()),i("abyssHepteractAuto").addEventListener("click",()=>e.hepteractCrafts.abyss.toggleAutomatic()),i("acceleratorHepteractAuto").addEventListener("click",()=>e.hepteractCrafts.accelerator.toggleAutomatic()),i("acceleratorBoostHepteractAuto").addEventListener("click",()=>e.hepteractCrafts.acceleratorBoost.toggleAutomatic()),i("multiplierHepteractAuto").addEventListener("click",()=>e.hepteractCrafts.multiplier.toggleAutomatic()),i("hepteractToQuark").addEventListener("mouseover",()=>Ng()),i("hepteractToQuarkTrade").addEventListener("click",()=>Jc()),i("hepteractToQuarkTradeMax").addEventListener("click",()=>Jc(!0)),i("hepteractToQuarkTradeAuto").addEventListener("click",()=>Gi()),i("overfluxPowder").addEventListener("mouseover",()=>$g()),i("powderDayWarp").addEventListener("click",()=>eu(!1)),i("warpAuto").addEventListener("click",()=>eu(!0)),i("hepteractAutoPercentageButton").addEventListener("click",()=>vf()),i("corrStatsBtn").addEventListener("click",()=>Ce(8,{page:0})),i("corrLoadoutsBtn").addEventListener("click",()=>Ce(8,{page:1})),i("corruptionDisplays").addEventListener("click",()=>Fa(10)),i("corruptionCleanse").addEventListener("click",()=>U0()),i("corruptionCleanseConfirm").addEventListener("click",()=>hn(10,999)),i("ascensionAutoEnable").addEventListener("click",()=>Ls(0)),i("ascensionAutoToggle").addEventListener("click",()=>Ls(1));let x=Array.from(document.querySelectorAll('[id^="switchSettingSubTab"]'));for(let w of x)w.addEventListener("click",()=>Ce(10,{page:x.indexOf(w)}));let B=Array.from(document.querySelectorAll("button.statsNerds"));for(let w of B)w.addEventListener("click",H=>Bm(H.target));i("summaryGeneration").addEventListener("click",()=>eh()),i("exportgame").addEventListener("click",()=>y0()),i("saveStringInput").addEventListener("blur",w=>b0(w.target)),i("savegame").addEventListener("click",()=>vr(!0)),i("deleteGame").addEventListener("click",()=>id(!1)),i("preloadDeleteGame").addEventListener("click",()=>v0()),i("promocodes").addEventListener("click",()=>C0()),i("addCodeBox").addEventListener("mouseover",()=>Zo("add")),i("addCode").addEventListener("click",()=>xn("add")),i("addCodeAll").addEventListener("click",()=>xn("add",Xn())),i("addCodeOne").addEventListener("click",()=>xn("add",1)),i("dailyCode").addEventListener("click",()=>xn("daily")),i("dailyCode").addEventListener("mouseover",()=>Zo("daily")),i("timeCode").addEventListener("click",()=>xn("time")),i("timeCode").addEventListener("mouseover",()=>Zo("time")),i("historyTogglePerSecondButton").addEventListener("click",()=>Y0()),i("resetHotkeys").addEventListener("click",()=>Bf()),i("notation").addEventListener("click",()=>mm()),i("iconSet").addEventListener("click",()=>rl(e.iconSet+1)),i("resetShopUpgrades").addEventListener("click",()=>Wi()),i("toggleConfirmShop").addEventListener("click",()=>df()),i("toggleBuyMaxShop").addEventListener("click",w=>pf(w)),i("toggleHideShop").addEventListener("click",()=>gf()),i("offeringPotions").addEventListener("mouseover",()=>pr("offeringPotion")),i("offeringpotionowned").addEventListener("mouseover",()=>pr("offeringPotion")),i("buyofferingpotion").addEventListener("mouseover",()=>pr("offeringPotion")),i("useofferingpotion").addEventListener("mouseover",()=>pr("offeringPotion")),i("buyofferingpotion").addEventListener("click",()=>Vi("offeringPotion")),i("useofferingpotion").addEventListener("click",()=>gn("offeringPotion")),i("toggle42").addEventListener("click",()=>{e.autoPotionTimer=0}),i("obtainiumPotions").addEventListener("mouseover",()=>pr("obtainiumPotion")),i("obtainiumpotionowned").addEventListener("mouseover",()=>pr("obtainiumPotion")),i("buyobtainiumpotion").addEventListener("mouseover",()=>pr("obtainiumPotion")),i("useobtainiumpotion").addEventListener("mouseover",()=>pr("obtainiumPotion")),i("buyobtainiumpotion").addEventListener("click",()=>Vi("obtainiumPotion")),i("useobtainiumpotion").addEventListener("click",()=>gn("obtainiumPotion")),i("toggle43").addEventListener("click",()=>{e.autoPotionTimerObtainium=0});let U=Object.keys(e.shopUpgrades);for(let w of U)pe[w].type==="upgrade"&&(i(`${w}`).addEventListener("mouseover",()=>pr(w)),i(`${w}Level`).addEventListener("mouseover",()=>pr(w)),i(`${w}Button`).addEventListener("mouseover",()=>pr(w)),i(`${w}Button`).addEventListener("click",()=>Vi(w)));i("buySingularityQuarksButton").addEventListener("click",()=>Tg());let k=Object.keys(e.singularityUpgrades);for(let w of k)w!=="offeringAutomatic"&&(i(`${String(w)}`).addEventListener("mouseover",()=>e.singularityUpgrades[`${String(w)}`].updateUpgradeHTML()),i(`${String(w)}`).addEventListener("click",H=>e.singularityUpgrades[`${String(w)}`].buyLevel(H)));i("actualSingularityUpgradeContainer").addEventListener("mouseover",()=>Ao(!0)),i("actualSingularityUpgradeContainer").addEventListener("mouseout",()=>Ao(!1));let L=i("singularityPerksIcon"),E=i("singularityPerksText"),T=i("singularityPerksDesc");for(let w of $c){let H=document.createElement("span");H.innerHTML=`${w.name()}`,H.id=w.ID,H.classList.add("oldPerk"),H.style.display="none",i("singularityPerksGrid").append(H),i(w.ID).addEventListener("mouseover",()=>{let J=Dc(w,e.highestSingularityCount),Te=u.t("singularity.perks.levelInfo",{level:J.level,singularity:J.singularity});L.src=`Pictures/${Be[e.iconSet][0]}/perk${w.ID}.png`,E.innerHTML=Te,T.innerHTML=w.description(e.highestSingularityCount,w.levels)})}let S=Object.keys(e.octeractUpgrades);for(let w of S)i(`${String(w)}`).addEventListener("mouseover",()=>e.octeractUpgrades[`${String(w)}`].updateUpgradeHTML()),i(`${String(w)}`).addEventListener("click",H=>e.octeractUpgrades[`${String(w)}`].buyLevel(H));i("octeractUpgradeContainer").addEventListener("mouseover",()=>Ao(!0)),i("octeractUpgradeContainer").addEventListener("mouseout",()=>Ao(!1));let I=Object.keys(e.singularityChallenges);for(let w of I)i(`${String(w)}`).addEventListener("mouseover",()=>e.singularityChallenges[`${String(w)}`].updateChallengeHTML()),i(`${String(w)}`).addEventListener("click",()=>e.singularityChallenges[`${String(w)}`].challengeEntryHandler());let N=Object.keys(e.blueberryUpgrades);for(let w of N)i(`${String(w)}`).addEventListener("mouseover",()=>e.blueberryUpgrades[`${String(w)}`].updateUpgradeHTML()),i(`${String(w)}`).addEventListener("click",H=>e.blueberryUpgrades[`${String(w)}`].buyLevel(H));let X=Array.from(document.querySelectorAll('[id^="blueberryLoadout"]')),re=i("blueberryUpgradeContainer");for(let w=0;w{var Te;Fl(H,(Te=e.blueberryLoadouts[H])!=null?Te:{ambrosiaTutorial:0}),re.classList.add(`hoveredBlueberryLoadout${H}`)}),J.addEventListener("mouseout",()=>{re.classList.remove(`hoveredBlueberryLoadout${H}`)}),J.addEventListener("click",()=>{var Te;return L0(H,(Te=e.blueberryLoadouts[H])!=null?Te:{ambrosiaTutorial:0})})}i("blueberryToggleMode").addEventListener("click",()=>Cf()),i("getBlueberries").addEventListener("click",()=>T0()),i("refundBlueberries").addEventListener("click",()=>ud()),i("importBlueberries").addEventListener("change",w=>ld(w,k0));for(let w=0;w<4;w++)i(`toggleSingularitySubTab${w+1}`).addEventListener("click",()=>Ce(9,{page:w}));i("unsmith").addEventListener("click",()=>Um()),i("importfile").addEventListener("change",w=>ld(w,Ga));for(let w=1;w<=5;w++)i(`switchTheme${w}`).addEventListener("click",()=>tl(!1,w,!0));i("saveType").addEventListener("click",async w=>{let H=w.target;if(!H.checked){localStorage.removeItem("copyToClipboard"),w.stopPropagation();return}w.preventDefault(),await ye(u.t("save.saveToClipboard"))?(H.checked=!H.checked,localStorage.setItem("copyToClipboard","")):localStorage.removeItem("copyToClipboard")}),window.addEventListener("error",hm,{capture:!0})};var rh=()=>{let t=1,r=new f(0),n=new f(0);o.produceFirst=e.firstGeneratedCoin.add(e.firstOwnedCoin).times(o.globalCoinMultiplier).times(o.coinOneMulti).times(e.firstProduceCoin),o.produceSecond=e.secondGeneratedCoin.add(e.secondOwnedCoin).times(o.globalCoinMultiplier).times(o.coinTwoMulti).times(e.secondProduceCoin),o.produceThird=e.thirdGeneratedCoin.add(e.thirdOwnedCoin).times(o.globalCoinMultiplier).times(o.coinThreeMulti).times(e.thirdProduceCoin),o.produceFourth=e.fourthGeneratedCoin.add(e.fourthOwnedCoin).times(o.globalCoinMultiplier).times(o.coinFourMulti).times(e.fourthProduceCoin),o.produceFifth=e.fifthGeneratedCoin.add(e.fifthOwnedCoin).times(o.globalCoinMultiplier).times(o.coinFiveMulti).times(e.fifthProduceCoin),o.produceTotal=o.produceFirst.add(o.produceSecond).add(o.produceThird).add(o.produceFourth).add(o.produceFifth),o.produceFirst.lte(1e-4)&&(o.produceFirst=new f(0)),o.produceSecond.lte(1e-4)&&(o.produceSecond=new f(0)),o.produceThird.lte(1e-4)&&(o.produceThird=new f(0)),o.produceFourth.lte(1e-4)&&(o.produceFourth=new f(0)),o.produceFifth.lte(1e-4)&&(o.produceFifth=new f(0)),o.producePerSecond=o.produceTotal.times(40),e.currentChallenge.reincarnation===6&&(t=3*Math.pow(1+e.challengecompletions[6]/25,2)),e.currentChallenge.reincarnation===9&&(t=.005),e.currentChallenge.ascension===15&&(t=5e-6);let a=Math.max(0,ae(e.challengecompletions)-e.challengecompletions[11]-e.challengecompletions[12]-e.challengecompletions[13]-e.challengecompletions[14]-e.challengecompletions[15]-3*e.cubeUpgrades[49]-(e.singularityCount>=15?4:0)-(e.singularityCount>=20?1:0));e.currentChallenge.ascension===13&&(t*=700*(1+1/6*e.challengecompletions[13]),t*=Math.pow(1.05,a)),e.challengecompletions[6]>0&&(t/=1.075);let s=1;s*=t,s*=1-1/20*e.researches[51]-1/40*e.researches[52]-1/80*e.researches[53]-1/160*e.researches[54]-1/320*e.researches[55],s*=1-.05/1800*(e.achievements[45]+e.achievements[46]+2*e.achievements[47])*Math.min(e.prestigecounter,1800),s*=Math.pow(.965,_("reincarnation",e.challengecompletions[6])),s*=.001+.999*Math.pow(6,-(o.rune2level*o.effectiveLevelMult)/1e3),s*=.01+.99*Math.pow(4,Math.min(0,(400-o.rune4level)/1100)),s*=1-.04*e.achievements[82]-.04*e.achievements[89]-.04*e.achievements[96]-.04*e.achievements[103]-.04*e.achievements[110]-.0566*e.achievements[117]-.0566*e.achievements[124]-.0566*e.achievements[131],s*=Math.pow(.9925,e.achievements[118]*(e.challengecompletions[6]+e.challengecompletions[7]+e.challengecompletions[8]+e.challengecompletions[9]+e.challengecompletions[10])),s*=.005+.995*Math.pow(.99,e.antUpgrades[2]+o.bonusant3),s*=1/Math.pow(1+f.log(e.ascendShards.add(1),10),1+.2/60*e.challengecompletions[10]*e.upgrades[125]+.1*e.platonicUpgrades[5]+.2*e.platonicUpgrades[10]+(o.platonicBonusMultiplier[5]-1)),s*=1-.1*(e.talismanRarity[1-1]-1),s*=Math.pow(.98,3/5*Math.log(1+e.rareFragments)/Math.log(10)*e.researches[159]),s*=Math.pow(.966,_("ascension",e.challengecompletions[13])),s*=1-.666*e.researches[200]/1e5,s*=1-.666*e.cubeUpgrades[50]/1e5,s*=o.challenge15Rewards.taxes,e.upgrades[121]>0&&(s*=.5),s<1e-300&&(s=1e-300),o.maxexponent=Math.floor(275/(f.log(1.01,10)*s))-1;let l=Math.min(o.maxexponent,Math.floor(f.log(o.produceTotal.add(1),10)));e.currentChallenge.ascension===13&&o.maxexponent<=99999&&e.achievements[249]<1&&a>=1&&R(249),l>=1&&(r=f.pow(l,2).div(550)),n=f.pow(o.maxexponent,2).div(550),o.taxdivisor=f.pow(1.01,f.mul(r,s)),o.taxdivisorcheck=f.pow(1.01,f.mul(n,s))};var nh={type:"postProcessor",name:"ColorText",process:t=>t.includes("<<")?t.replace(/<<(.*?)\|(.*?)>>/g,'$2'):t};var _d={en:{name:"English",flag:"\u{1F1FA}\u{1F1F8}"},zh:{name:"Chinese",flag:"\u{1F1E8}\u{1F1F3}"},fr:{name:"French",flag:"\u{1F3F3}\uFE0F"},de:{name:"German",flag:"\u{1F1E9}\u{1F1EA}"},pl:{name:"Polish",flag:"\u{1F1F5}\u{1F1F1}"},es:{name:"Spanish",flag:"\u{1F1EA}\u{1F1F8}"},ru:{name:"Russian",flag:"\u{1F1F7}\u{1F1FA}"}},Jl=new Map,ah=async()=>{var s;let t={},r=(s=localStorage.getItem("language"))!=null?s:"en",a=await(await fetch(`./translations/${r}.json`)).json();if(Jl.set(r,{translation:a}),t[r]={translation:a},r!=="en"){let c=await(await fetch("./translations/en.json")).json();Jl.set("en",{translation:c}),t.en={translation:c}}await u.use(nh).init({lng:r,fallbackLng:"en",debug:!nt,resources:t,postProcess:["ColorText"],returnEmptyString:!1,interpolation:{escapeValue:!1}}),f2(),h2()};function m2(t,r,n){let a=document.createElement("button");a.id=`language_${t}`,a.className="language-select",a.addEventListener("click",async()=>{if(!Jl.has(t)){let g=await(await fetch(`./translations/${t}.json`)).json();Jl.set(t,{translation:g}),u.addResourceBundle(t,"translation",g)}await u.changeLanguage(t),localStorage.setItem("language",t),await ye(u.t("general.languageChange"))&&location.reload()});let s=document.createElement("span");s.className="lang-flag",s.textContent=n,a.appendChild(s);let l=document.createElement("span");return l.className="lang-name",l.textContent=r,a.appendChild(l),a}function f2(){let t=i("languageOptions");for(let r in _d){let n=m2(r,_d[r].name,_d[r].flag);t.appendChild(n)}}function h2(){let t=document.querySelectorAll("*[i18n]");for(let r of Array.from(t)){let n=r.getAttribute("i18n"),a=u.t(n);a.includes("[r+1,!1])),loaded1009:!0,loaded1009hotfix1:!0,loaded10091:!0,loaded1010:!0,loaded10101:!0,shopUpgrades:{offeringPotion:1,obtainiumPotion:1,offeringEX:0,offeringAuto:0,obtainiumEX:0,obtainiumAuto:0,instantChallenge:0,antSpeed:0,cashGrab:0,shopTalisman:0,seasonPass:0,challengeExtension:0,challengeTome:0,cubeToQuark:0,tesseractToQuark:0,hypercubeToQuark:0,seasonPass2:0,seasonPass3:0,chronometer:0,infiniteAscent:0,calculator:0,calculator2:0,calculator3:0,calculator4:0,calculator5:0,calculator6:0,calculator7:0,constantEX:0,powderEX:0,chronometer2:0,chronometer3:0,seasonPassY:0,seasonPassZ:0,challengeTome2:0,instantChallenge2:0,cashGrab2:0,chronometerZ:0,cubeToQuarkAll:0,offeringEX2:0,obtainiumEX2:0,seasonPassLost:0,powderAuto:0,challenge15Auto:0,extraWarp:0,autoWarp:0,improveQuarkHept:0,improveQuarkHept2:0,improveQuarkHept3:0,improveQuarkHept4:0,shopImprovedDaily:0,shopImprovedDaily2:0,shopImprovedDaily3:0,shopImprovedDaily4:0,offeringEX3:0,obtainiumEX3:0,improveQuarkHept5:0,seasonPassInfinity:0,chronometerInfinity:0,shopSingularityPenaltyDebuff:0,shopAmbrosiaLuckMultiplier4:0,shopOcteractAmbrosiaLuck:0,shopAmbrosiaGeneration1:0,shopAmbrosiaGeneration2:0,shopAmbrosiaGeneration3:0,shopAmbrosiaGeneration4:0,shopAmbrosiaLuck1:0,shopAmbrosiaLuck2:0,shopAmbrosiaLuck3:0,shopAmbrosiaLuck4:0,shopCashGrabUltra:0,shopAmbrosiaAccelerator:0,shopEXUltra:0,shopChronometerS:0,shopAmbrosiaUltra:0,shopSingularitySpeedup:0,shopSingularityPotency:0,shopSadisticRune:0},shopBuyMaxToggle:!1,shopHideToggle:!1,shopConfirmationToggle:!0,autoPotionTimer:0,autoPotionTimerObtainium:0,autoSacrificeToggle:!1,autoBuyFragment:!1,autoFortifyToggle:!1,autoEnhanceToggle:!1,autoResearchToggle:!1,researchBuyMaxToggle:!1,autoResearchMode:"manual",autoResearch:0,autoSacrifice:0,sacrificeTimer:0,quarkstimer:9e4,goldenQuarksTimer:9e4,antPoints:new f("1"),antUpgrades:[0,0,0,0,0,0,0,0,0,0,0,0],antSacrificePoints:0,antSacrificeTimer:900,antSacrificeTimerReal:900,talismanLevels:[0,0,0,0,0,0,0],talismanRarity:[1,1,1,1,1,1,1],talismanOne:[null,-1,1,1,1,-1],talismanTwo:[null,1,1,-1,-1,1],talismanThree:[null,1,-1,1,1,-1],talismanFour:[null,-1,-1,1,1,1],talismanFive:[null,1,1,-1,-1,1],talismanSix:[null,1,1,1,-1,-1],talismanSeven:[null,-1,1,-1,1,1],talismanShards:0,commonFragments:0,uncommonFragments:0,rareFragments:0,epicFragments:0,legendaryFragments:0,mythicalFragments:0,buyTalismanShardPercent:10,autoAntSacrifice:!1,autoAntSacTimer:900,autoAntSacrificeMode:0,antMax:!1,ascensionCount:0,ascensionCounter:0,ascensionCounterReal:0,ascensionCounterRealReal:0,cubeUpgrades:[null,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],cubeUpgradesBuyMaxToggle:!1,autoCubeUpgradesToggle:!1,autoPlatonicUpgradesToggle:!1,platonicUpgrades:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],wowCubes:new nr(0),wowTesseracts:new ca(0),wowHypercubes:new ua(0),wowPlatonicCubes:new da(0),saveOfferingToggle:!1,wowAbyssals:0,wowOcteracts:0,totalWowOcteracts:0,cubeBlessings:{accelerator:0,multiplier:0,offering:0,runeExp:0,obtainium:0,antSpeed:0,antSacrifice:0,antELO:0,talismanBonus:0,globalSpeed:0},tesseractBlessings:{accelerator:0,multiplier:0,offering:0,runeExp:0,obtainium:0,antSpeed:0,antSacrifice:0,antELO:0,talismanBonus:0,globalSpeed:0},hypercubeBlessings:{accelerator:0,multiplier:0,offering:0,runeExp:0,obtainium:0,antSpeed:0,antSacrifice:0,antELO:0,talismanBonus:0,globalSpeed:0},platonicBlessings:{cubes:0,tesseracts:0,hypercubes:0,platonics:0,hypercubeBonus:0,taxes:0,scoreBonus:0,globalSpeed:0},hepteractCrafts:{chronos:Dg,hyperrealism:Gg,quark:Hg,challenge:Fg,abyss:Qg,accelerator:qg,acceleratorBoost:jg,multiplier:Vg},ascendShards:new f("0"),autoAscend:!1,autoAscendMode:"c10Completions",autoAscendThreshold:1,autoOpenCubes:!1,openCubes:0,autoOpenTesseracts:!1,openTesseracts:0,autoOpenHypercubes:!1,openHypercubes:0,autoOpenPlatonicsCubes:!1,openPlatonicsCubes:0,roombaResearchIndex:0,ascStatToggles:{1:!1,2:!1,3:!1,4:!1,5:!1,6:!1},prototypeCorruptions:[0,0,0,0,0,0,0,0,0,0,0,0,0],usedCorruptions:[0,0,0,0,0,0,0,0,0,0,0,0,0],corruptionLoadouts:{1:[0,0,0,0,0,0,0,0,0,0,0,0,0],2:[0,0,0,0,0,0,0,0,0,0,0,0,0],3:[0,0,0,0,0,0,0,0,0,0,0,0,0],4:[0,0,0,0,0,0,0,0,0,0,0,0,0],5:[0,0,0,0,0,0,0,0,0,0,0,0,0],6:[0,0,0,0,0,0,0,0,0,0,0,0,0],7:[0,0,0,0,0,0,0,0,0,0,0,0,0],8:[0,0,0,0,0,0,0,0,0,0,0,0,0],9:[0,0,0,0,0,0,0,0,0,0,0,0,0],10:[0,0,0,0,0,0,0,0,0,0,0,0,0],11:[0,0,0,0,0,0,0,0,0,0,0,0,0],12:[0,0,0,0,0,0,0,0,0,0,0,0,0],13:[0,0,0,0,0,0,0,0,0,0,0,0,0],14:[0,0,0,0,0,0,0,0,0,0,0,0,0],15:[0,0,0,0,0,0,0,0,0,0,0,0,0],16:[0,0,0,0,0,0,0,0,0,0,0,0,0]},corruptionLoadoutNames:["Loadout 1","Loadout 2","Loadout 3","Loadout 4","Loadout 5","Loadout 6","Loadout 7","Loadout 8","Loadout 9","Loadout 10","Loadout 11","Loadout 12","Loadout 13","Loadout 14","Loadout 15","Loadout 16"],corruptionShowStats:!0,constantUpgrades:[null,0,0,0,0,0,0,0,0,0,0],history:{ants:[],ascend:[],reset:[],singularity:[]},historyShowPerSecond:!1,autoChallengeRunning:!1,autoChallengeIndex:1,autoChallengeToggles:[!1,!0,!0,!0,!0,!0,!0,!0,!0,!0,!0,!1,!1,!1,!1,!1],autoChallengeStartExponent:10,autoChallengeTimer:{start:10,exit:2,enter:2},runeBlessingLevels:[0,0,0,0,0,0],runeSpiritLevels:[0,0,0,0,0,0],runeBlessingBuyAmount:0,runeSpiritBuyAmount:0,autoTesseracts:[!1,!1,!1,!1,!1,!1],saveString:"Synergism-$VERSION$-$TIME$.txt",exporttest:!!1,dayCheck:null,dayTimer:0,cubeOpenedDaily:0,cubeQuarkDaily:0,tesseractOpenedDaily:0,tesseractQuarkDaily:0,hypercubeOpenedDaily:0,hypercubeQuarkDaily:0,platonicCubeOpenedDaily:0,platonicCubeQuarkDaily:0,overfluxOrbs:0,overfluxOrbsAutoBuy:!1,overfluxPowder:0,dailyPowderResetUses:1,autoWarpCheck:!1,loadedOct4Hotfix:!1,loadedNov13Vers:!0,loadedDec16Vers:!0,loadedV253:!0,loadedV255:!0,loadedV297Hotfix1:!0,loadedV2927Hotfix1:!0,loadedV2930Hotfix1:!0,loadedV2931Hotfix1:!0,loadedV21003Hotfix1:!0,loadedV21007Hotfix1:!0,version:tr,rngCode:0,promoCodeTiming:{time:0},singularityCount:0,highestSingularityCount:0,singularityCounter:0,goldenQuarks:0,quarksThisSingularity:0,totalQuarksEver:0,hotkeys:{},theme:"Dark Mode",iconSet:0,notation:"Default",singularityUpgrades:{goldenQuarks1:new V(F.goldenQuarks1,"goldenQuarks1"),goldenQuarks2:new V(F.goldenQuarks2,"goldenQuarks2"),goldenQuarks3:new V(F.goldenQuarks3,"goldenQuarks3"),starterPack:new V(F.starterPack,"starterPack"),wowPass:new V(F.wowPass,"wowPass"),cookies:new V(F.cookies,"cookies"),cookies2:new V(F.cookies2,"cookies2"),cookies3:new V(F.cookies3,"cookies3"),cookies4:new V(F.cookies4,"cookies4"),cookies5:new V(F.cookies5,"cookies5"),ascensions:new V(F.ascensions,"ascensions"),corruptionFourteen:new V(F.corruptionFourteen,"corruptionFourteen"),corruptionFifteen:new V(F.corruptionFifteen,"corruptionFifteen"),singOfferings1:new V(F.singOfferings1,"singOfferings1"),singOfferings2:new V(F.singOfferings2,"singOfferings2"),singOfferings3:new V(F.singOfferings3,"singOfferings3"),singObtainium1:new V(F.singObtainium1,"singObtainium1"),singObtainium2:new V(F.singObtainium2,"singObtainium2"),singObtainium3:new V(F.singObtainium3,"singObtainium3"),singCubes1:new V(F.singCubes1,"singCubes1"),singCubes2:new V(F.singCubes2,"singCubes2"),singCubes3:new V(F.singCubes3,"singCubes3"),singCitadel:new V(F.singCitadel,"singCitadel"),singCitadel2:new V(F.singCitadel2,"singCitadel2"),octeractUnlock:new V(F.octeractUnlock,"octeractUnlock"),singOcteractPatreonBonus:new V(F.singOcteractPatreonBonus,"singOcteractPatreonBonus"),intermediatePack:new V(F.intermediatePack,"intermediatePack"),advancedPack:new V(F.advancedPack,"advancedPack"),expertPack:new V(F.expertPack,"expertPack"),masterPack:new V(F.masterPack,"masterPack"),divinePack:new V(F.divinePack,"divinePack"),wowPass2:new V(F.wowPass2,"wowPass2"),potionBuff:new V(F.potionBuff,"potionBuff"),potionBuff2:new V(F.potionBuff2,"potionBuff2"),potionBuff3:new V(F.potionBuff3,"potionBuff3"),singChallengeExtension:new V(F.singChallengeExtension,"singChallengeExtension"),singChallengeExtension2:new V(F.singChallengeExtension2,"singChallengeExtension2"),singChallengeExtension3:new V(F.singChallengeExtension3,"singChallengeExtension3"),singQuarkImprover1:new V(F.singQuarkImprover1,"singQuarkImprover1"),singQuarkHepteract:new V(F.singQuarkHepteract,"singQuarkHepteract"),singQuarkHepteract2:new V(F.singQuarkHepteract2,"singQuarkHepteract2"),singQuarkHepteract3:new V(F.singQuarkHepteract3,"singQuarkHepteract3"),singOcteractGain:new V(F.singOcteractGain,"singOcteractGain"),singOcteractGain2:new V(F.singOcteractGain2,"singOcteractGain2"),singOcteractGain3:new V(F.singOcteractGain3,"singOcteractGain3"),singOcteractGain4:new V(F.singOcteractGain4,"singOcteractGain4"),singOcteractGain5:new V(F.singOcteractGain5,"singOcteractGain5"),wowPass3:new V(F.wowPass3,"wowPass3"),ultimatePen:new V(F.ultimatePen,"ultimatePen"),platonicTau:new V(F.platonicTau,"platonicTau"),platonicAlpha:new V(F.platonicAlpha,"platonicAlpha"),platonicDelta:new V(F.platonicDelta,"platonicDelta"),platonicPhi:new V(F.platonicPhi,"platonicPhi"),singFastForward:new V(F.singFastForward,"singFastForward"),singFastForward2:new V(F.singFastForward2,"singFastForward2"),singAscensionSpeed:new V(F.singAscensionSpeed,"singAscensionSpeed"),singAscensionSpeed2:new V(F.singAscensionSpeed2,"singAscensionSpeed2"),oneMind:new V(F.oneMind,"oneMind"),wowPass4:new V(F.wowPass4,"wowPass4"),offeringAutomatic:new V(F.offeringAutomatic,"offeringAutomatic"),blueberries:new V(F.blueberries,"blueberries"),singAmbrosiaLuck:new V(F.singAmbrosiaLuck,"singAmbrosiaLuck"),singAmbrosiaLuck2:new V(F.singAmbrosiaLuck2,"singAmbrosiaLuck2"),singAmbrosiaLuck3:new V(F.singAmbrosiaLuck3,"singAmbrosiaLuck3"),singAmbrosiaLuck4:new V(F.singAmbrosiaLuck4,"singAmbrosiaLuck4"),singAmbrosiaGeneration:new V(F.singAmbrosiaGeneration,"singAmbrosiaGeneration"),singAmbrosiaGeneration2:new V(F.singAmbrosiaGeneration2,"singAmbrosiaGeneration2"),singAmbrosiaGeneration3:new V(F.singAmbrosiaGeneration3,"singAmbrosiaGeneration3"),singAmbrosiaGeneration4:new V(F.singAmbrosiaGeneration4,"singAmbrosiaGeneration4")},octeractUpgrades:{octeractStarter:new fe(le.octeractStarter,"octeractStarter"),octeractGain:new fe(le.octeractGain,"octeractGain"),octeractGain2:new fe(le.octeractGain2,"octeractGain2"),octeractQuarkGain:new fe(le.octeractQuarkGain,"octeractQuarkGain"),octeractQuarkGain2:new fe(le.octeractQuarkGain2,"octeractQuarkGain2"),octeractCorruption:new fe(le.octeractCorruption,"octeractCorruption"),octeractGQCostReduce:new fe(le.octeractGQCostReduce,"octeractGQCostReduce"),octeractExportQuarks:new fe(le.octeractExportQuarks,"octeractExportQuarks"),octeractImprovedDaily:new fe(le.octeractImprovedDaily,"octeractImprovedDaily"),octeractImprovedDaily2:new fe(le.octeractImprovedDaily2,"octeractImprovedDaily2"),octeractImprovedDaily3:new fe(le.octeractImprovedDaily3,"octeractImprovedDaily3"),octeractImprovedQuarkHept:new fe(le.octeractImprovedQuarkHept,"octeractImprovedQuarkHept"),octeractImprovedGlobalSpeed:new fe(le.octeractImprovedGlobalSpeed,"octeractImprovedGlobalSpeed"),octeractImprovedAscensionSpeed:new fe(le.octeractImprovedAscensionSpeed,"octeractImprovedAscensionSpeed"),octeractImprovedAscensionSpeed2:new fe(le.octeractImprovedAscensionSpeed2,"octeractImprovedAscensionSpeed2"),octeractImprovedFree:new fe(le.octeractImprovedFree,"octeractImprovedFree"),octeractImprovedFree2:new fe(le.octeractImprovedFree2,"octeractImprovedFree2"),octeractImprovedFree3:new fe(le.octeractImprovedFree3,"octeractImprovedFree3"),octeractImprovedFree4:new fe(le.octeractImprovedFree4,"octeractImprovedFree4"),octeractSingUpgradeCap:new fe(le.octeractSingUpgradeCap,"octeractSingUpgradeCap"),octeractOfferings1:new fe(le.octeractOfferings1,"octeractOfferings1"),octeractObtainium1:new fe(le.octeractObtainium1,"octeractObtainium1"),octeractAscensions:new fe(le.octeractAscensions,"octeractAscensions"),octeractAscensions2:new fe(le.octeractAscensions2,"octeractAscensions2"),octeractAscensionsOcteractGain:new fe(le.octeractAscensionsOcteractGain,"octeractAscensionsOcteractGain"),octeractFastForward:new fe(le.octeractFastForward,"octeractFastForward"),octeractAutoPotionSpeed:new fe(le.octeractAutoPotionSpeed,"octeractAutoPotionSpeed"),octeractAutoPotionEfficiency:new fe(le.octeractAutoPotionEfficiency,"octeractAutoPotionEfficiency"),octeractOneMindImprover:new fe(le.octeractOneMindImprover,"octeractOneMindImprover"),octeractAmbrosiaLuck:new fe(le.octeractAmbrosiaLuck,"octeractAmbrosiaLuck"),octeractAmbrosiaLuck2:new fe(le.octeractAmbrosiaLuck2,"octeractAmbrosiaLuck2"),octeractAmbrosiaLuck3:new fe(le.octeractAmbrosiaLuck3,"octeractAmbrosiaLuck3"),octeractAmbrosiaLuck4:new fe(le.octeractAmbrosiaLuck4,"octeractAmbrosiaLuck4"),octeractAmbrosiaGeneration:new fe(le.octeractAmbrosiaGeneration,"octeractAmbrosiaGeneration"),octeractAmbrosiaGeneration2:new fe(le.octeractAmbrosiaGeneration2,"octeractAmbrosiaGeneration2"),octeractAmbrosiaGeneration3:new fe(le.octeractAmbrosiaGeneration3,"octeractAmbrosiaGeneration3"),octeractAmbrosiaGeneration4:new fe(le.octeractAmbrosiaGeneration4,"octeractAmbrosiaGeneration4")},dailyCodeUsed:!1,hepteractAutoCraftPercentage:50,octeractTimer:0,insideSingularityChallenge:!1,singularityChallenges:{noSingularityUpgrades:new ur(Ze.noSingularityUpgrades,"noSingularityUpgrades"),oneChallengeCap:new ur(Ze.oneChallengeCap,"oneChallengeCap"),noOcteracts:new ur(Ze.noOcteracts,"noOcteracts"),limitedAscensions:new ur(Ze.limitedAscensions,"limitedAscensions"),noAmbrosiaUpgrades:new ur(Ze.noAmbrosiaUpgrades,"noAmbrosiaUpgrades"),limitedTime:new ur(Ze.limitedTime,"limitedTime"),sadisticPrequel:new ur(Ze.sadisticPrequel,"sadisticPrequel")},ambrosia:0,lifetimeAmbrosia:0,ambrosiaRNG:0,blueberryTime:0,visitedAmbrosiaSubtab:!1,spentBlueberries:0,blueberryUpgrades:{ambrosiaTutorial:new Ke($e.ambrosiaTutorial,"ambrosiaTutorial"),ambrosiaQuarks1:new Ke($e.ambrosiaQuarks1,"ambrosiaQuarks1"),ambrosiaCubes1:new Ke($e.ambrosiaCubes1,"ambrosiaQuarks1"),ambrosiaLuck1:new Ke($e.ambrosiaLuck1,"ambrosiaLuck1"),ambrosiaCubeQuark1:new Ke($e.ambrosiaCubeQuark1,"ambrosiaCubeQuark1"),ambrosiaLuckQuark1:new Ke($e.ambrosiaLuckQuark1,"ambrosiaLuckQuark1"),ambrosiaLuckCube1:new Ke($e.ambrosiaLuckCube1,"ambrosiaLuckCube1"),ambrosiaQuarkCube1:new Ke($e.ambrosiaQuarkCube1,"ambrosiaQuarkCube1"),ambrosiaCubeLuck1:new Ke($e.ambrosiaCubeLuck1,"ambrosiaCubeLuck1"),ambrosiaQuarkLuck1:new Ke($e.ambrosiaQuarkLuck1,"ambrosiaQuarkLuck1"),ambrosiaQuarks2:new Ke($e.ambrosiaQuarks2,"ambrosiaQuarks2"),ambrosiaCubes2:new Ke($e.ambrosiaCubes2,"ambrosiaQuarks2"),ambrosiaLuck2:new Ke($e.ambrosiaLuck2,"ambrosiaLuck2"),ambrosiaPatreon:new Ke($e.ambrosiaPatreon,"ambrosiaPatreon"),ambrosiaObtainium1:new Ke($e.ambrosiaObtainium1,"ambrosiaObtainium1"),ambrosiaOffering1:new Ke($e.ambrosiaOffering1,"ambrosiaOffering1"),ambrosiaHyperflux:new Ke($e.ambrosiaHyperflux,"ambrosiaHyperflux")},blueberryLoadouts:{1:{},2:{},3:{},4:{},5:{},6:{},7:{},8:{},9:{},10:{},11:{},12:{},13:{},14:{},15:{},16:{}},blueberryLoadoutMode:"saveTree",ultimateProgress:0,ultimatePixels:0,cubeUpgradeRedBarFilled:0,singChallengeTimer:0,caches:{ambrosiaLuckAdditiveMult:new Vl,ambrosiaLuck:new Wl,ambrosiaGeneration:new Kl,blueberryInventory:new zl},lastExportedSave:0,seed:Array.from({length:2},()=>Date.now())},M=Object.assign({},e,{codes:new Map(Array.from({length:48},(t,r)=>[r+1,!1]))}),vr=t=>{e.offlinetick=Date.now(),e.loaded1009=!0,e.loaded1009hotfix1=!0;let r=ws.parse(e),n=ls(JSON.stringify(r));if(n!==null)localStorage.setItem("Synergysave2",n);else return P(u.t("testing.errorSaving")),!1;if(t){let a=i("saveinfo");a.textContent=u.t("testing.gameSaved"),sl(()=>a.textContent="",4e3)}return!0},b2=()=>{var c,p,g;let t=localStorage.getItem("Synergysave2"),r=t?JSON.parse(atob(t)):null;if((!1||!nt)&&(Object.defineProperties(window,{player:{value:e},G:{value:o},Decimal:{value:f},i18n:{value:u}}),r&&!1&&(r.exporttest=!1)),Object.assign(o,O({},l0)),r){if((r.exporttest===!1||r.exporttest==="NO!")&&!!1)return P(u.t("testing.saveInLive2"));let m=e.codes.size,h=Object.keys(r).filter(S=>S.includes("offerpromo"));h.length>0&&h.forEach(S=>{let I=r[S],N=+S.replace(/[^\d]/g,"");e.codes.set(N,!!I)});let b=ji.safeParse(r);if(b.success)Object.assign(e,b.data);else{console.log(b.error),console.log(r),yu();return}if(dd(),e.lastExportedSave=(c=r.lastExportedSave)!=null?c:0,r.offerpromo24used!==void 0&&e.codes.set(25,!1),e.codes.size"u"&&(e.codes.set(13,!1),e.researches.push(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0),e.achievements.push(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0),e.maxofferings=e.runeshards,e.maxobtainium=e.researchPoints,e.researchPoints+=51200*e.researches[50],e.researches[50]=0),e.maxofferings=e.maxofferings||0,e.maxobtainium=e.maxobtainium||0,e.runeshards=e.runeshards||0,e.researchPoints=e.researchPoints||0,(!r.loaded1009||r.loaded1009hotfix1===null||((p=r.shopUpgrades)==null?void 0:p.offeringPotion)===void 0)&&(e.firstOwnedParticles=0,e.secondOwnedParticles=0,e.thirdOwnedParticles=0,e.fourthOwnedParticles=0,e.fifthOwnedParticles=0,e.firstCostParticles=new f("1"),e.secondCostParticles=new f("1e2"),e.thirdCostParticles=new f("1e4"),e.fourthCostParticles=new f("1e8"),e.fifthCostParticles=new f("1e16"),e.autoSacrificeToggle=!1,e.autoResearchToggle=!1,e.autoResearchMode="manual",e.autoResearch=0,e.autoSacrifice=0,e.sacrificeTimer=0,e.loaded1009=!0,e.codes.set(18,!1)),r.loaded1009hotfix1||(e.loaded1009hotfix1=!0,e.codes.set(19,!0),e.firstOwnedParticles=0,e.secondOwnedParticles=0,e.thirdOwnedParticles=0,e.fourthOwnedParticles=0,e.fifthOwnedParticles=0,e.firstCostParticles=new f("1"),e.secondCostParticles=new f("1e2"),e.thirdCostParticles=new f("1e4"),e.fourthCostParticles=new f("1e8"),e.fifthCostParticles=new f("1e16")),(r.loaded10091===void 0||!r.loaded10091||e.researches[86]>100||e.researches[87]>100||e.researches[88]>100||e.researches[89]>100||e.researches[90]>10)&&(e.loaded10091=!0,e.researchPoints+=75e7*e.researches[82],e.researchPoints+=2e8*e.researches[83],e.researchPoints+=45e8*e.researches[84],e.researchPoints+=25e6*e.researches[86],e.researchPoints+=75e6*e.researches[87],e.researchPoints+=3e8*e.researches[88],e.researchPoints+=1e9*e.researches[89],e.researchPoints+=25e6*e.researches[90],e.researchPoints+=1e8*e.researches[91],e.researchPoints+=2e9*e.researches[92],e.researchPoints+=9e9*e.researches[93],e.researchPoints+=725e8*e.researches[94],e.researches[86]=0,e.researches[87]=0,e.researches[88]=0,e.researches[89]=0,e.researches[90]=0,e.researches[91]=0,e.researches[92]=0),(((g=r.achievements)==null?void 0:g[169])===void 0||typeof e.achievements[169]>"u"||r.loaded1010===void 0||r.loaded1010===!1)&&(e.loaded1010=!0,e.codes.set(21,!1),e.firstOwnedAnts=0,e.firstGeneratedAnts=new f("0"),e.firstCostAnts=new f("1e700"),e.firstProduceAnts=1e-4,e.secondOwnedAnts=0,e.secondGeneratedAnts=new f("0"),e.secondCostAnts=new f("3"),e.secondProduceAnts=5e-5,e.thirdOwnedAnts=0,e.thirdGeneratedAnts=new f("0"),e.thirdCostAnts=new f("100"),e.thirdProduceAnts=2e-5,e.fourthOwnedAnts=0,e.fourthGeneratedAnts=new f("0"),e.fourthCostAnts=new f("1e4"),e.fourthProduceAnts=1e-5,e.fifthOwnedAnts=0,e.fifthGeneratedAnts=new f("0"),e.fifthCostAnts=new f("1e12"),e.fifthProduceAnts=5e-6,e.sixthOwnedAnts=0,e.sixthGeneratedAnts=new f("0"),e.sixthCostAnts=new f("1e36"),e.sixthProduceAnts=2e-6,e.seventhOwnedAnts=0,e.seventhGeneratedAnts=new f("0"),e.seventhCostAnts=new f("1e100"),e.seventhProduceAnts=1e-6,e.eighthOwnedAnts=0,e.eighthGeneratedAnts=new f("0"),e.eighthCostAnts=new f("1e300"),e.eighthProduceAnts=1e-8,e.achievements.push(0,0,0,0,0,0,0,0,0,0,0,0,0,0),e.antPoints=new f("1"),e.upgrades[38]=0,e.upgrades[39]=0,e.upgrades[40]=0,e.upgrades[76]=0,e.upgrades[77]=0,e.upgrades[78]=0,e.upgrades[79]=0,e.upgrades[80]=0,e.antUpgrades=[0,0,0,0,0,0,0,0,0,0,0,0],e.unlocks.rrow4=!1,e.researchPoints+=3e7*e.researches[50],e.researchPoints+=2e9*e.researches[96],e.researchPoints+=5e9*e.researches[97],e.researchPoints+=3e10*e.researches[98],e.researches[50]=0,e.researches[96]=0,e.researches[97]=0,e.researches[98]=0,e.researches.push(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0),e.talismanLevels=[0,0,0,0,0,0,0],e.talismanRarity=[1,1,1,1,1,1,1],e.talismanShards=0,e.commonFragments=0,e.uncommonFragments=0,e.rareFragments=0,e.epicFragments=0,e.legendaryFragments=0,e.mythicalFragments=0,e.buyTalismanShardPercent=10,e.talismanOne=[null,-1,1,1,1,-1],e.talismanTwo=[null,1,1,-1,-1,1],e.talismanThree=[null,1,-1,1,1,-1],e.talismanFour=[null,-1,-1,1,1,1],e.talismanFive=[null,1,1,-1,-1,1],e.talismanSix=[null,1,1,1,-1,-1],e.talismanSeven=[null,-1,1,-1,1,1],e.antSacrificePoints=0,e.antSacrificeTimer=0,e.obtainiumpersecond=0,e.maxobtainiumpersecond=0),r.loaded10101===void 0||r.loaded10101===!1){e.loaded10101=!0;let S=[0,31,32,61,62,63,64,76,77,78,79,80,81,98,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,125],I=[0,2,20,5,10,80,5e3,1e7,1e7,2e7,3e7,4e7,2e8,3e10,1e11,1e12,2e11,1e12,2e10,2e11,1e12,2e13,5e13,1e14,2e14,5e14,1e15,2e15,1e16,1e15,1e16,1e14,1e15,1e15,1e20];for(let N=1;N0&&(e.ascensionCounter=86400*90),e.singularityCount===0&&(e.cubeUpgrades=[...M.cubeUpgrades]),e.wowCubes=new nr(0),e.wowTesseracts=new ca(0),e.wowHypercubes=new ua(0),e.wowPlatonicCubes=new da(0),e.cubeBlessings={accelerator:0,multiplier:0,offering:0,runeExp:0,obtainium:0,antSpeed:0,antSacrifice:0,antELO:0,talismanBonus:0,globalSpeed:0}),e.transcendCount<0&&(e.transcendCount=0),e.reincarnationCount<0&&(e.reincarnationCount=0),e.runeshards<0&&(e.runeshards=0),e.researchPoints<0&&(e.researchPoints=0),e.resettoggle1===0&&(e.resettoggle1=1,e.resettoggle2=1,e.resettoggle3=1,e.resettoggle4=1),e.tesseractAutoBuyerToggle===0&&(e.tesseractAutoBuyerToggle=1),e.reincarnationCount<.5&&e.unlocks.rrow4&&(e.unlocks={coinone:!1,cointwo:!1,cointhree:!1,coinfour:!1,prestige:!1,generation:!1,transcend:!1,reincarnate:!1,rrow1:!1,rrow2:!1,rrow3:!1,rrow4:!1}),Number.isInteger(e.ascendBuilding1.cost)||(e.ascendBuilding1.cost=1,e.ascendBuilding1.owned=0,e.ascendBuilding2.cost=10,e.ascendBuilding2.owned=0,e.ascendBuilding3.cost=100,e.ascendBuilding3.owned=0,e.ascendBuilding4.cost=1e3,e.ascendBuilding4.owned=0,e.ascendBuilding5.cost=1e4,e.ascendBuilding5.owned=0),e.dayCheck||(e.dayCheck=new Date),typeof e.dayCheck=="string"&&(e.dayCheck=new Date(e.dayCheck),isNaN(e.dayCheck.getTime())&&(e.dayCheck=new Date));let C=Nn;isNaN(C.getTime())?e.dayCheck.getTime()<16540092e5&&(e.dayCheck=new Date("06/01/2022 00:00:00")):(C=new Date(C.getFullYear(),C.getMonth(),C.getDate()-1),e.dayCheck.getTime()I>=2&&I<=9?Math.min(v*(e.challengecompletions[Ll(I)]>0?1:0),S):S);for(let S=1;S<=5;S++){let I=`ascendBuilding${S}`;e[I].generated=new f(e[I].generated)}for(;typeof e.achievements[252]>"u";)e.achievements.push(0);for(;typeof e.researches[200]>"u";)e.researches.push(0);for(;typeof e.upgrades[140]>"u";)e.upgrades.push(0);(e.saveString===""||e.saveString==="Synergism-v1011Test.txt")&&(e.saveString=e.singularityCount===0?"Synergism-$VERSION$-$TIME$.txt":"Synergism-$VERSION$-$TIME$-$SING$.txt"),i("saveStringInput").value=to(e.saveString);for(let S=1;S<126;S++)jt(S,!0);for(let S=1;S<=200;S++)cs(S);for(let S=1;S0?lt(e.currentChallenge.transcension):e.currentChallenge.reincarnation>0?lt(e.currentChallenge.reincarnation):e.currentChallenge.ascension>0?lt(e.currentChallenge.ascension):lt(1),Va(),O0(),P0();let k=1+8+xe.CORRUPTION_LOADOUT_SLOT_QOL;for(let S=0;S.5&&(i(`rune${e.autoSacrifice}`).style.backgroundColor="orange"),e.autoWarpCheck?(i("warpAuto").textContent=u.t("general.autoOnColon"),i("warpAuto").style.border="2px solid green"):(i("warpAuto").textContent=u.t("general.autoOffColon"),i("warpAuto").style.border="2px solid red"),i("autoHepteractPercentage").textContent=u.t("wowCubes.hepteractForge.autoSetting",{x:`${e.hepteractAutoCraftPercentage}`}),i("hepteractToQuarkTradeAuto").textContent=e.overfluxOrbsAutoBuy?u.t("general.autoOnColon"):u.t("general.autoOffColon"),i("hepteractToQuarkTradeAuto").style.border=`2px solid ${e.overfluxOrbsAutoBuy?"green":"red"}`,Gi(!0,!0),i("blueberryToggleMode").innerHTML=e.blueberryLoadoutMode==="saveTree"?u.t("ambrosia.loadouts.save"):u.t("ambrosia.loadouts.load"),Ms(e.buyTalismanShardPercent),Zt(),Or(),It(),He(),$d(),Mf(),Bu(),o.currentSingChallenge!==void 0){let S=e.singularityChallenges[o.currentSingChallenge].computeSingularityRquirement();e.singularityCount=S}}I0(),e.currentChallenge.reincarnation?st("reincarnationChallenge"):e.currentChallenge.transcension&&st("transcensionChallenge");let n=new Date,a=n.getHours(),s=n.getMinutes(),l=n.getSeconds();e.dayTimer=60*60*24-(l+60*s+60*60*a)},sh=["","K","M","B","T","Qa","Qt","Sx","Sp","Oc","No","Dc","UDc","DDc","TDc","QaDc","QtDc","SxDc","SpDc","OcDc","NoDc","Vg","UVg","DVg","TVg","QaVg","QtVg","SxVg","SpVg","OcVg","NoVg","Tg","UTg","DTg","TTg","QaTg","QtTg","SxTg","SpTg","OTg","NTg","Qd","UQd","DQd","TQd","QaQd","QtQd","SxQd","SpQd","OcQd","NoQd","Qi","UQi","DQi","TQi","QaQi","QtQi","SxQi","SpQi","OQi","NQi","Se","USe","DSe","TSe","QaSe","QtSe","SxSe","SpSe","OcSe","NoSe","St","USt","DSt","TSt","QaSt","QtSt","SxSt","SpSt","OcSt","NoSt","Ocg","UOcg","DOcg","TOcg","QaOcg","QtOcg","SxOcg","SpOcg","OcOcg","NoOcg","Nono","UNono","DNono","TNono","QaNono","QtNono","SxNono","SpNono","OcNono","NoNono","Ce"],y2=typeof Intl.NumberFormat.prototype.formatToParts=="function",ec=y2?Intl.NumberFormat().formatToParts(1000.1).filter(t=>t.type==="decimal"||t.type==="group"):null,[{value:v2},{value:C2}]=(ec==null?void 0:ec.length)!==2?[{value:","},{value:"."}]:ec,Dd={minimumFractionDigits:2,maximumFractionDigits:2},Gd=(t,r=3)=>{let n=1,a="",s=t.split(".");for(let l=s[0].length-1;l>=0;l--)n++===r&&l!==0?(n=1,a=v2+t[l]+a):a=t[l]+a;return typeof s[1]<"u"&&(a+=C2+s[1]),a|0,a},d=(t,r=0,n=!1,a=!0,s=!1)=>{if(t==null)return"0 [null]";if(typeof t=="object"&&Symbol.toPrimitive in t&&(t=Number(t)),!(t instanceof f)&&typeof t!="number"||isNaN(t))return isNaN(t)?"0 [NaN]":"0 [und.]";if(typeof t=="number"&&e.notation==="Default"&&t<(s?1e-15:.001)&&t>0)return t.toExponential(r);let l,c;if(Bi(t))l=t.e,c=t.mantissa;else if(typeof t=="number"){if(t===0)return"0";l=Math.floor(Math.log10(Math.abs(t))),c=t/Math.pow(10,l)}if(c>9.9999999&&(c=1,++l),c<1&&c>.9999999&&(c=1),l<-15)return"0";if(e.notation==="Pure Engineering"){let p=l%3<0?3+l%3:l%3;l=l-p,c=c*Math.pow(10,p)}if(e.notation==="Pure Scientific"||e.notation==="Pure Engineering"){if(l>=1e6)return Number.isFinite(l)?`E${d(l,3)}`:"Infinity";if(r=l===2&&r>2?2:r,l>=6||l<0){r=r<2?2:r;let g=(Math.floor(c*Math.pow(10,r))/Math.pow(10,r)).toLocaleString(void 0,Dd),m=Gd(l.toString());return`${g}e${m}`}return c=c*Math.pow(10,l),c-Math.floor(c)>.9999999&&(c=Math.ceil(c)),`${(Math.floor(c*Math.pow(10,r))/Math.pow(10,r)).toLocaleString(void 0,{minimumFractionDigits:r,maximumFractionDigits:r})}`}if(l<0&&!Bi(t)&&s)return l<=-15?`${d(c,r,n)} / ${Math.pow(10,-l-15)}Qa`:l<=-12?`${d(c,r,n)} / ${Math.pow(10,-l-12)}T`:l<=-9?`${d(c,r,n)} / ${Math.pow(10,-l-9)}B`:l<=-6?`${d(c,r,n)} / ${Math.pow(10,-l-6)}M`:l<=-3?`${d(c,r,n)} / ${Math.pow(10,-l-3)}K`:`${d(c,r,n)} / ${Math.pow(10,-l)}`;if(l<6||n&&l<7){let p=c*Math.pow(10,l),g;return p-Math.floor(p)>.9999999&&(p=Math.ceil(p)),(l<2||n&&l<3)&&r>0?g=p.toFixed(l===2&&r>2?2:r):(p=Math.floor(p),g=p.toString()),Gd(g)}else if(l<1e6){let p=(Math.floor(c*100)/100).toLocaleString(void 0,Dd),g=Gd(l.toString());return`${p}e${g}`}else if(l>=1e6){if(!Number.isFinite(l))return"Infinity";let p=!1&&a?"":(Math.floor(c*100)/100).toLocaleString(void 0,Dd),g=Math.ceil(Math.log10(l)),m=(g-1)%3+1,h=l/Math.pow(10,g-m);h===1e3&&(h=1,m=1);let b=h.toLocaleString(void 0,{minimumFractionDigits:4-m,maximumFractionDigits:4-m}),C=Math.floor(Math.log10(l)/3);return typeof sh[C]=="string"?`${p}e${b}${sh[C]}`:`e${l.toExponential(2)}`}else return"0 [und.]"},zt=(t,r)=>(t>=86400?`${d(Math.floor(t/86400))}d`:"")+(t>=3600?`${d(Math.floor(t/3600)%24)}h`:"")+(t>=60?`${d(Math.floor(t/60)%60)}m`:"")+(t>=864e4?"":`${d(Math.floor(t)%60)+(r&&t{let t=0;o.totalAccelerator=e.acceleratorBought,o.costDivisor=1,e.upgrades[8]!==0&&(t+=Math.floor(e.multiplierBought/7)),e.upgrades[21]!==0&&(t+=5),e.upgrades[22]!==0&&(t+=4),e.upgrades[23]!==0&&(t+=3),e.upgrades[24]!==0&&(t+=2),e.upgrades[25]!==0&&(t+=1),e.upgrades[27]!==0&&(t+=Math.min(250,Math.floor(f.log(e.coins.add(1),1e3)))+Math.min(1750,Math.max(0,Math.floor(f.log(e.coins.add(1),1e15))-50))),e.upgrades[29]!==0&&(t+=Math.floor(Math.min(2e3,(e.firstOwnedCoin+e.secondOwnedCoin+e.thirdOwnedCoin+e.fourthOwnedCoin+e.fifthOwnedCoin)/80))),e.upgrades[32]!==0&&(t+=Math.min(500,Math.floor(f.log(e.prestigePoints.add(1),1e25)))),e.upgrades[45]!==0&&(t+=Math.min(2500,Math.floor(f.log(e.transcendShards.add(1),10)))),e.achievements[5]!==0&&(t+=Math.floor(e.firstOwnedCoin/500)),e.achievements[12]!==0&&(t+=Math.floor(e.secondOwnedCoin/500)),e.achievements[19]!==0&&(t+=Math.floor(e.thirdOwnedCoin/500)),e.achievements[26]!==0&&(t+=Math.floor(e.fourthOwnedCoin/500)),e.achievements[33]!==0&&(t+=Math.floor(e.fifthOwnedCoin/500)),e.achievements[60]!==0&&(t+=2),e.achievements[61]!==0&&(t+=2),e.achievements[62]!==0&&(t+=2),t+=5*_("transcend",e.challengecompletions[2]),o.freeUpgradeAccelerator=t,t+=o.totalAcceleratorBoost*(4+2*e.researches[18]+2*e.researches[19]+3*e.researches[20]+o.cubeBonusMultiplier[1]),e.unlocks.prestige&&(t+=Math.floor(Math.pow(o.rune1level*o.effectiveLevelMult/4,1.25)),t*=1+o.rune1level*1/400*o.effectiveLevelMult),Q0(),t*=o.acceleratorMultiplier,t=Math.pow(t,Math.min(1,(1+e.platonicUpgrades[6]/30)*o.viscosityPower[e.usedCorruptions[2]])),t+=2e3*Ve("accelerator"),t*=o.challenge15Rewards.accelerator,t*=1+3/1e4*Ve("accelerator"),t=Math.floor(Math.min(1e100,t)),e.usedCorruptions[2]>=15&&(t=Math.pow(t,.2)),e.usedCorruptions[2]>=16&&(t=1),o.freeAccelerator=t,o.totalAccelerator+=o.freeAccelerator,o.tuSevenMulti=1,e.upgrades[46]>.5&&(o.tuSevenMulti=1.05),o.acceleratorPower=Math.pow(1.1+o.tuSevenMulti*(o.totalAcceleratorBoost/100)*(1+_("transcend",e.challengecompletions[2])/20),1+.04*_("reincarnation",e.challengecompletions[7])),o.acceleratorPower+=1/200*Math.floor(_("transcend",e.challengecompletions[2])/2)*100/100;for(let r=1;r<=5;r++)e.achievements[7*r-4]>0&&(o.acceleratorPower+=5e-4*r);e.currentChallenge.reincarnation!==7&&e.currentChallenge.reincarnation!==10&&(e.currentChallenge.transcension===1&&(o.acceleratorPower*=25/(50+e.challengecompletions[1]),o.acceleratorPower+=.55,o.acceleratorPower=Math.max(1,o.acceleratorPower)),e.currentChallenge.transcension===2&&(o.acceleratorPower=1),e.currentChallenge.transcension===3&&(o.acceleratorPower=1.05+2*o.tuSevenMulti*(o.totalAcceleratorBoost/300)*(1+_("transcend",e.challengecompletions[2])/20))),o.acceleratorPower=Math.min(1e300,o.acceleratorPower),e.currentChallenge.reincarnation===7&&(o.acceleratorPower=1),e.currentChallenge.reincarnation===10&&(o.acceleratorPower=1),e.currentChallenge.transcension!==1&&(o.acceleratorEffect=f.pow(o.acceleratorPower,o.totalAccelerator)),e.currentChallenge.transcension===1&&(o.acceleratorEffect=f.pow(o.acceleratorPower,o.totalAccelerator+o.totalMultiplier)),o.acceleratorEffectDisplay=new f(o.acceleratorPower*100-100),e.currentChallenge.reincarnation===10&&(o.acceleratorEffect=new f(1)),o.generatorPower=new f(1),e.upgrades[11]>.5&&e.currentChallenge.reincarnation!==7&&(o.generatorPower=f.pow(1.02,o.totalAccelerator))},Gu=()=>{let t=0;e.upgrades[7]>0&&(t+=Math.min(4,1+Math.floor(f.log(e.fifthOwnedCoin+1,10)))),e.upgrades[9]>0&&(t+=Math.floor(e.acceleratorBought/10)),e.upgrades[21]>0&&(t+=1),e.upgrades[22]>0&&(t+=1),e.upgrades[23]>0&&(t+=1),e.upgrades[24]>0&&(t+=1),e.upgrades[25]>0&&(t+=1),e.upgrades[28]>0&&(t+=Math.min(1e3,Math.floor((e.firstOwnedCoin+e.secondOwnedCoin+e.thirdOwnedCoin+e.fourthOwnedCoin+e.fifthOwnedCoin)/160))),e.upgrades[30]>0&&(t+=Math.min(75,Math.floor(f.log(e.coins.add(1),1e10)))+Math.min(925,Math.floor(f.log(e.coins.add(1),1e30)))),e.upgrades[33]>0&&(t+=o.totalAcceleratorBoost),e.upgrades[49]>0&&(t+=Math.min(50,Math.floor(f.log(e.transcendPoints.add(1),1e10)))),e.upgrades[68]>0&&(t+=Math.min(2500,Math.floor(f.log(o.taxdivisor,10)*1/1e3))),e.challengecompletions[1]>0&&(t+=1),e.achievements[6]>.5&&(t+=Math.floor(e.firstOwnedCoin/1e3)),e.achievements[13]>.5&&(t+=Math.floor(e.secondOwnedCoin/1e3)),e.achievements[20]>.5&&(t+=Math.floor(e.thirdOwnedCoin/1e3)),e.achievements[27]>.5&&(t+=Math.floor(e.fourthOwnedCoin/1e3)),e.achievements[34]>.5&&(t+=Math.floor(e.fifthOwnedCoin/1e3)),e.achievements[57]>.5&&(t+=1),e.achievements[58]>.5&&(t+=1),e.achievements[59]>.5&&(t+=1),t+=20*e.researches[94]*Math.floor((o.rune1level+o.rune2level+o.rune3level+o.rune4level+o.rune5level)/8),o.freeUpgradeMultiplier=Math.min(1e100,t),e.achievements[38]>.5&&(t+=Math.floor(Math.floor(o.rune2level/10*o.effectiveLevelMult)*Math.floor(1+o.rune2level/10*o.effectiveLevelMult)/2)*100/100),t*=1+e.achievements[57]/100,t*=1+e.achievements[58]/100,t*=1+e.achievements[59]/100,t*=Math.pow(1.01,e.upgrades[21]+e.upgrades[22]+e.upgrades[23]+e.upgrades[24]+e.upgrades[25]),t*=1+.03*e.upgrades[34]+.02*e.upgrades[35],t*=1+1/5*e.researches[2]*(1+1/2*_("ascension",e.challengecompletions[14])),t*=1+1/20*e.researches[11]+1/25*e.researches[12]+1/40*e.researches[13]+3/200*e.researches[14]+1/200*e.researches[15],t*=1+o.rune2level/400*o.effectiveLevelMult,t*=1+1/20*e.researches[87],t*=1+1/100*e.researches[128],t*=1+.8/100*e.researches[143],t*=1+.6/100*e.researches[158],t*=1+.4/100*e.researches[173],t*=1+.2/100*e.researches[188],t*=1+.01/100*e.researches[200],t*=1+.01/100*e.cubeUpgrades[50],t*=_t(40,(e.antUpgrades[4]+o.bonusant5)/1e3*40/39),t*=o.cubeBonusMultiplier[2],(e.currentChallenge.transcension!==0||e.currentChallenge.reincarnation!==0)&&e.upgrades[50]>.5&&(t*=1.25),t=Math.pow(t,Math.min(1,(1+e.platonicUpgrades[6]/30)*o.viscosityPower[e.usedCorruptions[2]])),t+=1e3*Ve("multiplier"),t*=o.challenge15Rewards.multiplier,t*=1+3/1e4*Ve("multiplier"),t=Math.floor(Math.min(1e100,t)),e.usedCorruptions[2]>=15&&(t=Math.pow(t,.2)),e.usedCorruptions[2]>=16&&(t=1),o.freeMultiplier=t,o.totalMultiplier=o.freeMultiplier+e.multiplierBought,o.challengeOneLog=3;let r=0,n=0;r+=f.log(e.transcendShards.add(1),3),r*=1+11*e.researches[33]/100,r*=1+11*e.researches[34]/100,r*=1+11*e.researches[35]/100,r*=1+e.researches[89]/5,r*=1+10*o.effectiveRuneBlessingPower[2],n+=Math.floor(.1*r*_("transcend",e.challengecompletions[1])),n+=_("transcend",e.challengecompletions[1])*10,o.freeMultiplierBoost=n,o.totalMultiplierBoost=Math.pow(Math.floor(r)+n,1+_("reincarnation",e.challengecompletions[7])*.04);let a=1;e.challengecompletions[7]>.5&&(a=1.25),o.multiplierPower=2+.005*o.totalMultiplierBoost*a,e.currentChallenge.reincarnation!==7&&e.currentChallenge.reincarnation!==10&&(e.currentChallenge.transcension===1&&(o.multiplierPower=1),e.currentChallenge.transcension===2&&(o.multiplierPower=1.25+.0012*(r+n)*a)),o.multiplierPower=Math.min(1e300,o.multiplierPower),e.currentChallenge.reincarnation===7&&(o.multiplierPower=1),e.currentChallenge.reincarnation===10&&(o.multiplierPower=1),o.multiplierEffect=f.pow(o.multiplierPower,o.totalMultiplier)},w2=()=>{let t=new f(1),r=new f(1),n=1/3;n+=Math.min(10+.05*e.researches[129]*Math.log(e.commonFragments+1)/Math.log(4)+20*Xe()/400*o.effectiveRuneSpiritPower[3],.05*e.crystalUpgrades[3]),n+=.04*_("transcend",e.challengecompletions[3]),n+=.08*e.researches[28],n+=.08*e.researches[29],n+=.04*e.researches[30],n+=8*e.cubeUpgrades[17],o.prestigeMultiplier=f.pow(e.prestigeShards,n).add(1);let a=1;e.currentChallenge.reincarnation===7&&(a=.05),e.currentChallenge.reincarnation===8&&(a=0),o.buildingPower=1+(1-Math.pow(2,-1/160))*a*f.log(e.reincarnationShards.add(1),10)*(1+1/20*e.researches[36]+1/40*e.researches[37]+1/40*e.researches[38])+(a+.2)*.25/1.2*_("reincarnation",e.challengecompletions[8]),o.buildingPower=Math.pow(o.buildingPower,1+e.cubeUpgrades[12]*.09),o.buildingPower=Math.pow(o.buildingPower,1+e.cubeUpgrades[36]*.05),o.reincarnationMultiplier=f.pow(o.buildingPower,o.totalCoinOwned),o.antMultiplier=f.pow(f.max(1,e.antPoints),Ju()),t=t.times(o.multiplierEffect),t=t.times(o.acceleratorEffect),t=t.times(o.prestigeMultiplier),t=t.times(o.reincarnationMultiplier),t=t.times(o.antMultiplier);let s=new f(o.totalCoinOwned+1).times(f.min(1e30,f.pow(1.008,o.totalCoinOwned)));e.highestSingularityCount>0&&(t=t.times(Math.pow(e.goldenQuarks+1,1.5)*Math.pow(e.highestSingularityCount+1,2))),e.upgrades[6]>.5&&(t=t.times(s)),e.upgrades[12]>.5&&(t=t.times(f.min(1e4,f.pow(1.01,e.prestigeCount)))),e.upgrades[20]>.5&&(t=t.times(f.pow(o.totalCoinOwned/4+1,10))),e.upgrades[41]>.5&&(t=t.times(f.min(1e30,f.pow(e.transcendPoints.add(1),1/2)))),e.upgrades[43]>.5&&(t=t.times(f.min(1e30,f.pow(1.01,e.transcendCount)))),e.upgrades[48]>.5&&(t=t.times(f.pow(o.totalMultiplier*o.totalAccelerator/1e3+1,8))),e.currentChallenge.reincarnation===6&&(t=t.dividedBy(1e250)),e.currentChallenge.reincarnation===7&&(t=t.dividedBy("1e1250")),e.currentChallenge.reincarnation===9&&(t=t.dividedBy("1e2000000")),e.currentChallenge.reincarnation===10&&(t=t.dividedBy("1e12500000")),r=f.pow(t,1+.001*e.researches[17]);let l=f.pow(r,1+.025*e.upgrades[123]);e.currentChallenge.ascension===15&&e.platonicUpgrades[5]>0&&(l=f.pow(l,1.1)),e.currentChallenge.ascension===15&&e.platonicUpgrades[14]>0&&(l=f.pow(l,1+1/20*e.usedCorruptions[9]*f.log(e.coins.add(1),10)/(1e7+f.log(e.coins.add(1),10)))),e.currentChallenge.ascension===15&&e.platonicUpgrades[15]>0&&(l=f.pow(l,1.1)),l=f.pow(l,o.challenge15Rewards.coinExponent),o.globalCoinMultiplier=l,o.globalCoinMultiplier=f.pow(o.globalCoinMultiplier,o.financialcollapsePower[e.usedCorruptions[9]]),o.coinOneMulti=new f(1),e.upgrades[1]>.5&&(o.coinOneMulti=o.coinOneMulti.times(s)),e.upgrades[10]>.5&&(o.coinOneMulti=o.coinOneMulti.times(f.pow(2,Math.min(50,e.secondOwnedCoin/15)))),e.upgrades[56]>.5&&(o.coinOneMulti=o.coinOneMulti.times("1e5000")),o.coinTwoMulti=new f(1),e.upgrades[2]>.5&&(o.coinTwoMulti=o.coinTwoMulti.times(s)),e.upgrades[13]>.5&&(o.coinTwoMulti=o.coinTwoMulti.times(f.min(1e50,f.pow(e.firstGeneratedMythos.add(e.firstOwnedMythos).add(1),4/3).times(1e10)))),e.upgrades[19]>.5&&(o.coinTwoMulti=o.coinTwoMulti.times(f.min(1e200,e.transcendPoints.times(1e30).add(1)))),e.upgrades[57]>.5&&(o.coinTwoMulti=o.coinTwoMulti.times("1e7500")),o.coinThreeMulti=new f(1),e.upgrades[3]>.5&&(o.coinThreeMulti=o.coinThreeMulti.times(s)),e.upgrades[18]>.5&&(o.coinThreeMulti=o.coinThreeMulti.times(f.min(1e125,e.transcendShards.add(1)))),e.upgrades[58]>.5&&(o.coinThreeMulti=o.coinThreeMulti.times("1e15000")),o.coinFourMulti=new f(1),e.upgrades[4]>.5&&(o.coinFourMulti=o.coinFourMulti.times(s)),e.upgrades[17]>.5&&(o.coinFourMulti=o.coinFourMulti.times(1e100)),e.upgrades[59]>.5&&(o.coinFourMulti=o.coinFourMulti.times("1e25000")),o.coinFiveMulti=new f(1),e.upgrades[5]>.5&&(o.coinFiveMulti=o.coinFiveMulti.times(s)),e.upgrades[60]>.5&&(o.coinFiveMulti=o.coinFiveMulti.times("1e35000")),o.globalCrystalMultiplier=new f(1),e.achievements[36]>.5&&(o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(2)),e.achievements[37]>.5&&e.prestigePoints.gte(10)&&(o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.log(e.prestigePoints.add(1),10))),e.achievements[44]>.5&&(o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.pow(o.rune3level/2*o.effectiveLevelMult,2).times(f.pow(2,o.rune3level*o.effectiveLevelMult/2-8)).add(1))),e.upgrades[36]>.5&&(o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.min("1e5000",f.pow(e.prestigePoints,1/500)))),e.upgrades[63]>.5&&(o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.min("1e6000",f.pow(e.reincarnationPoints.add(1),6)))),e.researches[39]>.5&&(o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.pow(o.reincarnationMultiplier,1/50))),o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.min(f.pow(10,50+2*e.crystalUpgrades[0]),f.pow(1.05,e.achievementPoints*e.crystalUpgrades[0]))),o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.min(f.pow(10,100+5*e.crystalUpgrades[1]),f.pow(f.log(e.coins.add(1),10),e.crystalUpgrades[1]/3))),o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.pow(1+Math.min(.12+.88*e.upgrades[122]+.001*e.researches[129]*Math.log(e.commonFragments+1)/Math.log(4),.001*e.crystalUpgrades[2]),e.firstOwnedDiamonds+e.secondOwnedDiamonds+e.thirdOwnedDiamonds+e.fourthOwnedDiamonds+e.fifthOwnedDiamonds)),o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.pow(1.01,(e.challengecompletions[1]+e.challengecompletions[2]+e.challengecompletions[3]+e.challengecompletions[4]+e.challengecompletions[5])*e.crystalUpgrades[4])),o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.pow(10,_("transcend",e.challengecompletions[5]))),o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.pow(1e4,e.researches[5]*(1+1/2*_("ascension",e.challengecompletions[14])))),o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.pow(2.5,e.researches[26])),o.globalCrystalMultiplier=o.globalCrystalMultiplier.times(f.pow(2.5,e.researches[27])),o.globalMythosMultiplier=new f(1),e.upgrades[37]>.5&&(o.globalMythosMultiplier=o.globalMythosMultiplier.times(f.pow(f.log(e.prestigePoints.add(10),10),2))),e.upgrades[42]>.5&&(o.globalMythosMultiplier=o.globalMythosMultiplier.times(f.min(1e50,f.pow(e.prestigePoints.add(1),1/50).dividedBy(2.5).add(1)))),e.upgrades[47]>.5&&(o.globalMythosMultiplier=o.globalMythosMultiplier.times(f.pow(1.05,e.achievementPoints)).times(e.achievementPoints+1)),e.upgrades[51]>.5&&(o.globalMythosMultiplier=o.globalMythosMultiplier.times(f.pow(o.totalAcceleratorBoost,2))),e.upgrades[52]>.5&&(o.globalMythosMultiplier=o.globalMythosMultiplier.times(f.pow(o.globalMythosMultiplier,.025))),e.upgrades[64]>.5&&(o.globalMythosMultiplier=o.globalMythosMultiplier.times(f.pow(e.reincarnationPoints.add(1),2))),e.researches[40]>.5&&(o.globalMythosMultiplier=o.globalMythosMultiplier.times(f.pow(o.reincarnationMultiplier,1/250))),o.grandmasterMultiplier=new f(1),o.totalMythosOwned=e.firstOwnedMythos+e.secondOwnedMythos+e.thirdOwnedMythos+e.fourthOwnedMythos+e.fifthOwnedMythos,o.mythosBuildingPower=1+_("transcend",e.challengecompletions[3])/200,o.challengeThreeMultiplier=f.pow(o.mythosBuildingPower,o.totalMythosOwned),o.grandmasterMultiplier=o.grandmasterMultiplier.times(o.challengeThreeMultiplier),o.mythosupgrade13=new f(1),o.mythosupgrade14=new f(1),o.mythosupgrade15=new f(1),e.upgrades[53]===1&&(o.mythosupgrade13=o.mythosupgrade13.times(f.min("1e1250",f.pow(o.acceleratorEffect,1/125)))),e.upgrades[54]===1&&(o.mythosupgrade14=o.mythosupgrade14.times(f.min("1e2000",f.pow(o.multiplierEffect,1/180)))),e.upgrades[55]===1&&(o.mythosupgrade15=o.mythosupgrade15.times(f.pow("1e1000",Math.min(1e3,o.buildingPower-1)))),o.globalConstantMult=new f("1"),o.globalConstantMult=o.globalConstantMult.times(f.pow(1.05+.01*e.achievements[270]+.001*e.platonicUpgrades[18],e.constantUpgrades[1])),o.globalConstantMult=o.globalConstantMult.times(f.pow(1+.001*Math.min(100+10*e.achievements[270]+10*e.shopUpgrades.constantEX+1e3*(o.challenge15Rewards.exponent-1)+3*e.platonicUpgrades[18],e.constantUpgrades[2]),Wc())),o.globalConstantMult=o.globalConstantMult.times(1+2/100*e.researches[139]),o.globalConstantMult=o.globalConstantMult.times(1+3/100*e.researches[154]),o.globalConstantMult=o.globalConstantMult.times(1+4/100*e.researches[169]),o.globalConstantMult=o.globalConstantMult.times(1+5/100*e.researches[184]),o.globalConstantMult=o.globalConstantMult.times(1+10/100*e.researches[199]),o.globalConstantMult=o.globalConstantMult.times(o.challenge15Rewards.constantBonus),e.platonicUpgrades[5]>0&&(o.globalConstantMult=o.globalConstantMult.times(2)),e.platonicUpgrades[10]>0&&(o.globalConstantMult=o.globalConstantMult.times(10)),e.platonicUpgrades[15]>0&&(o.globalConstantMult=o.globalConstantMult.times(1e250)),o.globalConstantMult=o.globalConstantMult.times(f.pow(e.overfluxPowder+1,10*e.platonicUpgrades[16]))},Rd=t=>{if(H0(),F0(),Du(),Gu(),w2(),rh(),o.produceTotal.gte(.001)){let l=f.min(o.produceTotal.dividedBy(o.taxdivisor),f.pow(10,o.maxexponent-f.log(o.taxdivisorcheck,10))).times(t/.025);e.coins=e.coins.add(l),e.coinsThisPrestige=e.coinsThisPrestige.add(l),e.coinsThisTranscension=e.coinsThisTranscension.add(l),e.coinsThisReincarnation=e.coinsThisReincarnation.add(l),e.coinsTotal=e.coinsTotal.add(l)}T2(),e.upgrades[93]===1&&e.coinsThisPrestige.gte(1e16)&&(e.prestigePoints=e.prestigePoints.add(f.floor(o.prestigePointGain.dividedBy(4e3).times(t/.025)))),e.upgrades[100]===1&&e.coinsThisTranscension.gte(1e100)&&(e.transcendPoints=e.transcendPoints.add(f.floor(o.transcendPointGain.dividedBy(4e3).times(t/.025)))),e.cubeUpgrades[28]>0&&e.transcendShards.gte(1e300)&&(e.reincarnationPoints=e.reincarnationPoints.add(f.floor(o.reincarnationPointGain.dividedBy(4e3).times(t/.025)))),o.produceFirstDiamonds=e.firstGeneratedDiamonds.add(e.firstOwnedDiamonds).times(e.firstProduceDiamonds).times(o.globalCrystalMultiplier),o.produceSecondDiamonds=e.secondGeneratedDiamonds.add(e.secondOwnedDiamonds).times(e.secondProduceDiamonds).times(o.globalCrystalMultiplier),o.produceThirdDiamonds=e.thirdGeneratedDiamonds.add(e.thirdOwnedDiamonds).times(e.thirdProduceDiamonds).times(o.globalCrystalMultiplier),o.produceFourthDiamonds=e.fourthGeneratedDiamonds.add(e.fourthOwnedDiamonds).times(e.fourthProduceDiamonds).times(o.globalCrystalMultiplier),o.produceFifthDiamonds=e.fifthGeneratedDiamonds.add(e.fifthOwnedDiamonds).times(e.fifthProduceDiamonds).times(o.globalCrystalMultiplier),e.fourthGeneratedDiamonds=e.fourthGeneratedDiamonds.add(o.produceFifthDiamonds.times(t/.025)),e.thirdGeneratedDiamonds=e.thirdGeneratedDiamonds.add(o.produceFourthDiamonds.times(t/.025)),e.secondGeneratedDiamonds=e.secondGeneratedDiamonds.add(o.produceThirdDiamonds.times(t/.025)),e.firstGeneratedDiamonds=e.firstGeneratedDiamonds.add(o.produceSecondDiamonds.times(t/.025)),o.produceDiamonds=o.produceFirstDiamonds,e.currentChallenge.transcension!==3&&e.currentChallenge.reincarnation!==10&&(e.prestigeShards=e.prestigeShards.add(o.produceDiamonds.times(t/.025))),o.produceFifthMythos=e.fifthGeneratedMythos.add(e.fifthOwnedMythos).times(e.fifthProduceMythos).times(o.globalMythosMultiplier).times(o.grandmasterMultiplier).times(o.mythosupgrade15),o.produceFourthMythos=e.fourthGeneratedMythos.add(e.fourthOwnedMythos).times(e.fourthProduceMythos).times(o.globalMythosMultiplier),o.produceThirdMythos=e.thirdGeneratedMythos.add(e.thirdOwnedMythos).times(e.thirdProduceMythos).times(o.globalMythosMultiplier).times(o.mythosupgrade14),o.produceSecondMythos=e.secondGeneratedMythos.add(e.secondOwnedMythos).times(e.secondProduceMythos).times(o.globalMythosMultiplier),o.produceFirstMythos=e.firstGeneratedMythos.add(e.firstOwnedMythos).times(e.firstProduceMythos).times(o.globalMythosMultiplier).times(o.mythosupgrade13),e.fourthGeneratedMythos=e.fourthGeneratedMythos.add(o.produceFifthMythos.times(t/.025)),e.thirdGeneratedMythos=e.thirdGeneratedMythos.add(o.produceFourthMythos.times(t/.025)),e.secondGeneratedMythos=e.secondGeneratedMythos.add(o.produceThirdMythos.times(t/.025)),e.firstGeneratedMythos=e.firstGeneratedMythos.add(o.produceSecondMythos.times(t/.025)),o.produceMythos=new f("0"),o.produceMythos=e.firstGeneratedMythos.add(e.firstOwnedMythos).times(e.firstProduceMythos).times(o.globalMythosMultiplier).times(o.mythosupgrade13),o.producePerSecondMythos=o.produceMythos.times(40);let r=new f("1");e.upgrades[67]>.5&&(r=r.times(f.pow(1.03,e.firstOwnedParticles+e.secondOwnedParticles+e.thirdOwnedParticles+e.fourthOwnedParticles+e.fifthOwnedParticles))),o.produceFifthParticles=e.fifthGeneratedParticles.add(e.fifthOwnedParticles).times(e.fifthProduceParticles),o.produceFourthParticles=e.fourthGeneratedParticles.add(e.fourthOwnedParticles).times(e.fourthProduceParticles),o.produceThirdParticles=e.thirdGeneratedParticles.add(e.thirdOwnedParticles).times(e.thirdProduceParticles),o.produceSecondParticles=e.secondGeneratedParticles.add(e.secondOwnedParticles).times(e.secondProduceParticles),o.produceFirstParticles=e.firstGeneratedParticles.add(e.firstOwnedParticles).times(e.firstProduceParticles).times(r),e.fourthGeneratedParticles=e.fourthGeneratedParticles.add(o.produceFifthParticles.times(t/.025)),e.thirdGeneratedParticles=e.thirdGeneratedParticles.add(o.produceFourthParticles.times(t/.025)),e.secondGeneratedParticles=e.secondGeneratedParticles.add(o.produceThirdParticles.times(t/.025)),e.firstGeneratedParticles=e.firstGeneratedParticles.add(o.produceSecondParticles.times(t/.025)),o.produceParticles=new f("0"),o.produceParticles=e.firstGeneratedParticles.add(e.firstOwnedParticles).times(e.firstProduceParticles).times(r),o.producePerSecondParticles=o.produceParticles.times(40),e.currentChallenge.transcension!==3&&e.currentChallenge.reincarnation!==10&&(e.transcendShards=e.transcendShards.add(o.produceMythos.times(t/.025))),e.currentChallenge.reincarnation!==10&&(e.reincarnationShards=e.reincarnationShards.add(o.produceParticles.times(t/.025))),M2(t);for(let l=1;l<=5;l++)if(o.ascendBuildingProduction[o.ordinals[5-l]]=e[`ascendBuilding${6-l}`].generated.add(e[`ascendBuilding${6-l}`].owned).times(e[`ascendBuilding${l}`].multiplier).times(o.globalConstantMult),l!==5){let c=5-l;e[`ascendBuilding${c}`].generated=e[`ascendBuilding${c}`].generated.add(o.ascendBuildingProduction[o.ordinals[c]].times(t))}e.ascendShards=e.ascendShards.add(o.ascendBuildingProduction.first.times(t)),e.ascensionCount>0&&As(2),e.researches[71]>.5&&e.challengecompletions[1].5&&e.challengecompletions[2].5&&e.challengecompletions[3].5&&e.challengecompletions[4].5&&e.challengecompletions[5]=9&&e.coins.gte(Et(a,e.challengecompletions[a],a))&&(Ae("reincarnationChallenge",!1),o.autoChallengeTimerIncrement=0),s!==0&&s<15&&e.challengecompletions[10]>=Et(s,e.challengecompletions[s],s)&&(Ae("ascensionChallenge",!1),yr(s,!0)),s===15&&e.coins.gte(Et(s,e.challengecompletions[s],s))&&Ae("ascensionChallenge",!1)},x2=()=>{o.globalAntMult=new f(10),o.globalAntMult=o.globalAntMult.times(5),o.globalAntMult=o.globalAntMult.times(1+1/2500*Math.pow(o.rune5level*o.effectiveLevelMult*(1+e.researches[84]/200*(1+1*o.effectiveRuneSpiritPower[5]*Xe()/400)),2)),e.upgrades[76]===1&&(o.globalAntMult=o.globalAntMult.times(5)),o.globalAntMult=o.globalAntMult.times(f.pow(1+e.upgrades[77]/250+e.researches[96]/5e3+e.cubeUpgrades[65]/250,e.firstOwnedAnts+e.secondOwnedAnts+e.thirdOwnedAnts+e.fourthOwnedAnts+e.fifthOwnedAnts+e.sixthOwnedAnts+e.seventhOwnedAnts+e.eighthOwnedAnts)),o.globalAntMult=o.globalAntMult.times(1+e.upgrades[78]*.005*Math.pow(Math.log10(e.maxofferings+1),2)),o.globalAntMult=o.globalAntMult.times(f.pow(1.11+e.researches[101]/1e3+e.researches[162]/1e4,e.antUpgrades[0]+o.bonusant1)),o.globalAntMult=o.globalAntMult.times(ra(e.antSacrificePoints)),o.globalAntMult=o.globalAntMult.times(f.pow(Math.max(1,e.researchPoints),o.effectiveRuneBlessingPower[5])),o.globalAntMult=o.globalAntMult.times(f.pow(1+o.runeSum/100,o.talisman6Power)),o.globalAntMult=o.globalAntMult.times(f.pow(1.1,_("reincarnation",e.challengecompletions[9]))),o.globalAntMult=o.globalAntMult.times(o.cubeBonusMultiplier[6]),e.achievements[169]===1&&(o.globalAntMult=o.globalAntMult.times(f.log(e.antPoints.add(10),10))),e.achievements[171]===1&&(o.globalAntMult=o.globalAntMult.times(1.16666)),e.achievements[172]===1&&(o.globalAntMult=o.globalAntMult.times(1+2*(1-Math.pow(2,-Math.min(1,e.reincarnationcounter/7200))))),e.upgrades[39]===1&&(o.globalAntMult=o.globalAntMult.times(1.6)),o.globalAntMult=o.globalAntMult.times(f.pow(1+.1*f.log(e.ascendShards.add(1),10),e.constantUpgrades[5])),o.globalAntMult=o.globalAntMult.times(f.pow(1e5,_("ascension",e.challengecompletions[11]))),e.researches[147]>0&&(o.globalAntMult=o.globalAntMult.times(f.log(e.antPoints.add(10),10))),e.researches[177]>0&&(o.globalAntMult=o.globalAntMult.times(f.pow(f.log(e.antPoints.add(10),10),e.researches[177]))),e.currentChallenge.ascension===12&&(o.globalAntMult=f.pow(o.globalAntMult,.5)),e.currentChallenge.ascension===13&&(o.globalAntMult=f.pow(o.globalAntMult,.23)),e.currentChallenge.ascension===14&&(o.globalAntMult=f.pow(o.globalAntMult,.2)),e.currentChallenge.ascension!==15?o.globalAntMult=f.pow(o.globalAntMult,1-.9/90*Math.min(99,ae(e.usedCorruptions))):o.globalAntMult=f.pow(o.globalAntMult,.01),o.globalAntMult=f.pow(o.globalAntMult,o.extinctionMultiplier[e.usedCorruptions[7]]),o.globalAntMult=o.globalAntMult.times(o.challenge15Rewards.antSpeed),o.globalAntMult=o.globalAntMult.times(f.pow(1.2,e.shopUpgrades.antSpeed)),e.platonicUpgrades[12]>0&&(o.globalAntMult=o.globalAntMult.times(f.pow(1+1/100*e.platonicUpgrades[12],ae(e.highestchallengecompletions)))),e.currentChallenge.ascension===15&&e.platonicUpgrades[10]>0&&(o.globalAntMult=f.pow(o.globalAntMult,1.25)),e.achievements[274]>0&&(o.globalAntMult=o.globalAntMult.times(4.44)),e.usedCorruptions[7]>=14&&(o.globalAntMult=f.pow(o.globalAntMult,.02)),e.usedCorruptions[7]>=15&&(o.globalAntMult=f.pow(o.globalAntMult,.02)),e.usedCorruptions[7]>=16&&(o.globalAntMult=f.pow(o.globalAntMult,.02)),e.octeractUpgrades.octeractStarter.getEffect().bonus&&(o.globalAntMult=o.globalAntMult.times(1e5)),e.highestSingularityCount>=30&&(o.globalAntMult=o.globalAntMult.times(1e3)),e.highestSingularityCount>=70&&(o.globalAntMult=o.globalAntMult.times(1e3)),e.highestSingularityCount>=100&&(o.globalAntMult=o.globalAntMult.times(1e6))},M2=t=>{x2(),o.antEightProduce=e.eighthGeneratedAnts.add(e.eighthOwnedAnts).times(e.eighthProduceAnts).times(o.globalAntMult),o.antSevenProduce=e.seventhGeneratedAnts.add(e.seventhOwnedAnts).times(e.seventhProduceAnts).times(o.globalAntMult),o.antSixProduce=e.sixthGeneratedAnts.add(e.sixthOwnedAnts).times(e.sixthProduceAnts).times(o.globalAntMult),o.antFiveProduce=e.fifthGeneratedAnts.add(e.fifthOwnedAnts).times(e.fifthProduceAnts).times(o.globalAntMult),o.antFourProduce=e.fourthGeneratedAnts.add(e.fourthOwnedAnts).times(e.fourthProduceAnts).times(o.globalAntMult),o.antThreeProduce=e.thirdGeneratedAnts.add(e.thirdOwnedAnts).times(e.thirdProduceAnts).times(o.globalAntMult),o.antTwoProduce=e.secondGeneratedAnts.add(e.secondOwnedAnts).times(e.secondProduceAnts).times(o.globalAntMult),o.antOneProduce=e.firstGeneratedAnts.add(e.firstOwnedAnts).times(e.firstProduceAnts).times(o.globalAntMult),e.seventhGeneratedAnts=e.seventhGeneratedAnts.add(o.antEightProduce.times(t/1)),e.sixthGeneratedAnts=e.sixthGeneratedAnts.add(o.antSevenProduce.times(t/1)),e.fifthGeneratedAnts=e.fifthGeneratedAnts.add(o.antSixProduce.times(t/1)),e.fourthGeneratedAnts=e.fourthGeneratedAnts.add(o.antFiveProduce.times(t/1)),e.thirdGeneratedAnts=e.thirdGeneratedAnts.add(o.antFourProduce.times(t/1)),e.secondGeneratedAnts=e.secondGeneratedAnts.add(o.antThreeProduce.times(t/1)),e.firstGeneratedAnts=e.firstGeneratedAnts.add(o.antTwoProduce.times(t/1)),e.antPoints=e.antPoints.add(o.antOneProduce.times(t/1))},T2=()=>{let t=.5+_("transcend",e.challengecompletions[5])/100,r=.03;e.currentChallenge.transcension===5&&(t=.01/(1+e.challengecompletions[5]),r=.001),e.currentChallenge.reincarnation===10&&(t=1e-4/(1+e.challengecompletions[10]),r=.001),t*=o.deflationMultiplier[e.usedCorruptions[6]],o.prestigePointGain=f.floor(f.pow(e.coinsThisPrestige.dividedBy(1e12),t)),e.upgrades[16]>.5&&e.currentChallenge.transcension!==5&&e.currentChallenge.reincarnation!==10&&(o.prestigePointGain=o.prestigePointGain.times(f.min(f.pow(10,1e33),f.pow(o.acceleratorEffect,1/3*o.deflationMultiplier[e.usedCorruptions[6]])))),o.transcendPointGain=f.floor(f.pow(e.coinsThisTranscension.dividedBy(1e100),r)),e.upgrades[44]>.5&&e.currentChallenge.transcension!==5&&e.currentChallenge.reincarnation!==10&&(o.transcendPointGain=o.transcendPointGain.times(f.min(1e6,f.pow(1.01,e.transcendCount)))),o.reincarnationPointGain=f.floor(f.pow(e.transcendShards.dividedBy(1e300),.01)),e.currentChallenge.reincarnation!==0&&(o.reincarnationPointGain=f.pow(o.reincarnationPointGain,.01)),e.achievements[50]===1&&(o.reincarnationPointGain=o.reincarnationPointGain.times(2)),e.upgrades[65]>.5&&(o.reincarnationPointGain=o.reincarnationPointGain.times(5)),e.currentChallenge.ascension===12&&(o.reincarnationPointGain=new f("0"))},Ae=async(t,r=!0,n=!1)=>{if(t==="prestige"&&(e.coinsThisPrestige.gte(1e16)||o.prestigePointGain.gte(100))&&(r?tc("prestige"):(wt(1),Pe("prestige"))),t==="transcension"&&(e.coinsThisTranscension.gte(1e100)||o.transcendPointGain.gte(.5))&&e.currentChallenge.transcension===0&&(r&&tc("transcend"),r||(wt(2),Pe("transcension"))),t==="transcensionChallenge"&&e.currentChallenge.transcension!==0){let a=e.currentChallenge.transcension,s=je(a),l=c=>e.coinsThisTranscension.gte(Et(a,c,a));if(l(e.challengecompletions[a])&&e.challengecompletions[a]0&&(c=10),e.shopUpgrades.instantChallenge2>0&&(c+=e.highestSingularityCount),e.currentChallenge.ascension===13&&(c=1);let p=0,g=e.challengecompletions[a];for(;pe.highestchallengecompletions[a]){for(;e.challengecompletions[a]>e.highestchallengecompletions[a];)e.highestchallengecompletions[a]+=1,Id(a,e.highestchallengecompletions[a]);Qt()}yr(a),(!e.retrychallenges||r||e.autoChallengeRunning&&e.challengecompletions[a]>=s)&&(fr("ENTER"),e.currentChallenge.transcension=0,Lr()),(e.shopUpgrades.instantChallenge===0||n)&&(Pe("transcensionChallenge",!1,"leaveChallenge"),e.transcendCount-=1)}if(t==="reincarnation"&&o.reincarnationPointGain.gt(.5)&&e.currentChallenge.transcension===0&&e.currentChallenge.reincarnation===0&&(r&&tc("reincarnate"),r||(wt(3),Pe("reincarnation"))),t==="reincarnationChallenge"&&e.currentChallenge.reincarnation!==0){let a=e.currentChallenge.reincarnation,s=je(a),l=c=>a<=8?e.transcendShards.gte(Et(a,c,a)):e.coins.gte(Et(a,c,a));if(l(e.challengecompletions[a])&&e.challengecompletions[a]0&&(c=10),e.shopUpgrades.instantChallenge2>0&&(c+=e.highestSingularityCount),e.currentChallenge.ascension===13&&(c=1);let p=0,g=e.challengecompletions[a];for(;pe.highestchallengecompletions[a]){for(;e.challengecompletions[a]>e.highestchallengecompletions[a];)e.highestchallengecompletions[a]+=1,Id(a,e.highestchallengecompletions[a]);ia(),la(),Qt()}if(yr(a),!e.retrychallenges||r||e.autoChallengeRunning&&e.challengecompletions[a]>=s){if(fr("ENTER"),e.currentChallenge.reincarnation=0,e.shopUpgrades.instantChallenge>0)for(let c=1;c<=5;c++)e.challengecompletions[c]=e.highestchallengecompletions[c];Lr(),He(),It()}(e.shopUpgrades.instantChallenge===0||n)&&(Pe("reincarnationChallenge",!1,"leaveChallenge"),e.reincarnationCount-=1)}if(t==="ascension"&&e.achievements[141]>0&&(!e.toggles[31]||e.challengecompletions[10]>0)&&r&&tc("ascend"),t==="ascensionChallenge"&&e.currentChallenge.ascension!==0){let a=!0;if(r&&(e.challengecompletions[11]===0||e.toggles[31])&&(a=await ye(u.t("main.exitAscensionChallenge"))),!a)return;let s=e.currentChallenge.ascension,l=je(s);if(s!==0&&s<15&&(e.challengecompletions[10]>=Et(s,e.challengecompletions[s],s)&&e.challengecompletions[s]0)&&e.usedCorruptions.slice(2,10).every(p=>p===11)&&e.coins.gte(f.pow(10,e.challenge15Exponent/c))&&(e.challenge15Exponent=f.log(e.coins.add(1),10)*c,gl())}e.challengecompletions[s]>e.highestchallengecompletions[s]&&(e.highestchallengecompletions[s]+=1,e.wowHypercubes.add(1),e.highestchallengecompletions[s]>=l&&(n=!0)),(!e.retrychallenges||r||n)&&(!r&&(ti()||!e.autoChallengeRunning)&&e.autoAscend&&e.challengecompletions[11]>0&&e.cubeUpgrades[10]>0||(e.currentChallenge.ascension=0,Lr())),(e.shopUpgrades.instantChallenge2===0&&s!==15||r)&&Pe("ascensionChallenge",!1)}if(t==="singularity"){if(e.runelevels[6]===0)return P(u.t("main.noAntiquity"));let a=300;if(e.insideSingularityChallenge)return P(u.t("main.insideSingularityChallenge"));if(e.singularityCount>=a)return P(u.t("main.gameBeat"));let s=!1,l=e.singularityCount+1+fa();return!e.toggles[33]&&e.singularityCount>0?s=await ye(u.t("main.singularityConfirm0",{x:d(l),y:d(Xt(),2,!0)})):(await P(u.t("main.singularityMessage1",{x:d(e.singularityCount)})),await P(u.t("main.singularityMessage2")),await P(u.t("main.singularityMessage3")),await P(u.t("main.singularityMessage4",{x:d(l),y:d(Xt(),2,!0),z:d(rr())})),await P(u.t("main.singularityMessage5")),s=await ye(u.t("main.singularityConfirm1")),s&&(s=await ye(u.t("main.singularityConfirm2"))),s&&(s=await ye(u.t("main.singularityConfirm3")))),s?(await Cs(),vr(),P(u.t("main.welcomeToSingularity",{x:d(e.singularityCount)}))):P(u.t("main.singularityCancelled"))}},tc=async t=>{t==="prestige"&&(e.toggles[28]?await ye(u.t("main.prestigePrompt"))&&(wt(1),Pe("prestige")):(wt(1),Pe("prestige"))),t==="transcend"&&(e.toggles[29]?await ye(u.t("main.transcendPrompt"))&&(wt(2),Pe("transcension")):(wt(2),Pe("transcension"))),t==="reincarnate"&&e.currentChallenge.ascension!==12&&(e.toggles[30]?await ye(u.t("main.reincarnatePrompt"))&&(wt(3),Pe("reincarnation")):(wt(3),Pe("reincarnation"))),t==="ascend"&&(!e.toggles[31]||await ye(u.t("main.ascendPrompt")))&&Pe("ascension")},Nu=()=>{o.effectiveLevelMult=1,o.effectiveLevelMult*=1+e.researches[4]/10*(1+1/2*_("ascension",e.challengecompletions[14])),o.effectiveLevelMult*=1+e.researches[21]/100,o.effectiveLevelMult*=1+e.researches[90]/100,o.effectiveLevelMult*=1+e.researches[131]/200,o.effectiveLevelMult*=1+e.researches[161]/200*3/5,o.effectiveLevelMult*=1+e.researches[176]/200*2/5,o.effectiveLevelMult*=1+e.researches[191]/200*1/5,o.effectiveLevelMult*=1+e.researches[146]/200*4/5,o.effectiveLevelMult*=1+.01*Math.log(e.talismanShards+1)/Math.log(4)*Math.min(1,e.constantUpgrades[9]),o.effectiveLevelMult*=o.challenge15Rewards.runeBonus},Io=()=>{o.uFourteenMulti=new f(1),o.uFifteenMulti=new f(1),e.upgrades[14]>.5&&(o.uFourteenMulti=f.pow(1.15,o.freeAccelerator)),e.upgrades[15]>.5&&(o.uFifteenMulti=f.pow(1.15,o.freeAccelerator)),!e.unlocks.coinone&&e.coins.gte(500)&&(e.unlocks.coinone=!0,Oe()),!e.unlocks.cointwo&&e.coins.gte(1e4)&&(e.unlocks.cointwo=!0,Oe()),!e.unlocks.cointhree&&e.coins.gte(1e5)&&(e.unlocks.cointhree=!0,Oe()),!e.unlocks.coinfour&&e.coins.gte(4e6)&&(e.unlocks.coinfour=!0,Oe()),e.achievements[169]===0&&e.antPoints.gte(3)&&R(169),e.achievements[170]===0&&e.antPoints.gte(1e5)&&R(170),e.achievements[171]===0&&e.antPoints.gte(666666666)&&R(171),e.achievements[172]===0&&e.antPoints.gte(1e20)&&R(172),e.achievements[173]===0&&e.antPoints.gte(1e40)&&R(173),e.achievements[174]===0&&e.antPoints.gte("1e500")&&R(174),e.achievements[175]===0&&e.antPoints.gte("1e2500")&&R(175),e.researches[200]>=1e5&&e.achievements[250]<1&&R(250),e.cubeUpgrades[50]>=1e5&&e.achievements[251]<1&&R(251),Pg(),e.toggles[1]&&e.upgrades[81]===1&&e.coins.gte(e.firstCostCoin)&>(1,"Coin"),e.toggles[2]&&e.upgrades[82]===1&&e.coins.gte(e.secondCostCoin)&>(2,"Coin"),e.toggles[3]&&e.upgrades[83]===1&&e.coins.gte(e.thirdCostCoin)&>(3,"Coin"),e.toggles[4]&&e.upgrades[84]===1&&e.coins.gte(e.fourthCostCoin)&>(4,"Coin"),e.toggles[5]&&e.upgrades[85]===1&&e.coins.gte(e.fifthCostCoin)&>(5,"Coin"),e.toggles[6]&&e.upgrades[86]===1&&e.coins.gte(e.acceleratorCost)&&Es(!0),e.toggles[7]&&e.upgrades[87]===1&&e.coins.gte(e.multiplierCost)&&Os(!0),e.toggles[8]&&e.upgrades[88]===1&&e.prestigePoints.gte(e.acceleratorBoostCost)&&Ka(!0),e.toggles[10]&&e.achievements[78]===1&&e.prestigePoints.gte(e.firstCostDiamonds)&>(1,"Diamonds"),e.toggles[11]&&e.achievements[85]===1&&e.prestigePoints.gte(e.secondCostDiamonds)&>(2,"Diamonds"),e.toggles[12]&&e.achievements[92]===1&&e.prestigePoints.gte(e.thirdCostDiamonds)&>(3,"Diamonds"),e.toggles[13]&&e.achievements[99]===1&&e.prestigePoints.gte(e.fourthCostDiamonds)&>(4,"Diamonds"),e.toggles[14]&&e.achievements[106]===1&&e.prestigePoints.gte(e.fifthCostDiamonds)&>(5,"Diamonds"),Nu();let t=0;if(t+=Math.floor(o.rune3level/16*o.effectiveLevelMult)*100/100,e.upgrades[73]>.5&&e.currentChallenge.reincarnation!==0&&(t+=10),e.achievements[79]>.5&&e.prestigeShards.gte(f.pow(10,o.crystalUpgradesCost[0]+o.crystalUpgradeCostIncrement[0]*Math.floor(Math.pow(e.crystalUpgrades[0]-.5-t,2)/2)))&&Yt(1,!0),e.achievements[86]>.5&&e.prestigeShards.gte(f.pow(10,o.crystalUpgradesCost[1]+o.crystalUpgradeCostIncrement[1]*Math.floor(Math.pow(e.crystalUpgrades[1]-.5-t,2)/2)))&&Yt(2,!0),e.achievements[93]>.5&&e.prestigeShards.gte(f.pow(10,o.crystalUpgradesCost[2]+o.crystalUpgradeCostIncrement[2]*Math.floor(Math.pow(e.crystalUpgrades[2]-.5-t,2)/2)))&&Yt(3,!0),e.achievements[100]>.5&&e.prestigeShards.gte(f.pow(10,o.crystalUpgradesCost[3]+o.crystalUpgradeCostIncrement[3]*Math.floor(Math.pow(e.crystalUpgrades[3]-.5-t,2)/2)))&&Yt(4,!0),e.achievements[107]>.5&&e.prestigeShards.gte(f.pow(10,o.crystalUpgradesCost[4]+o.crystalUpgradeCostIncrement[4]*Math.floor(Math.pow(e.crystalUpgrades[4]-.5-t,2)/2)))&&Yt(5,!0),e.toggles[16]&&e.upgrades[94]===1&&e.transcendPoints.gte(e.firstCostMythos)&>(1,"Mythos"),e.toggles[17]&&e.upgrades[95]===1&&e.transcendPoints.gte(e.secondCostMythos)&>(2,"Mythos"),e.toggles[18]&&e.upgrades[96]===1&&e.transcendPoints.gte(e.thirdCostMythos)&>(3,"Mythos"),e.toggles[19]&&e.upgrades[97]===1&&e.transcendPoints.gte(e.fourthCostMythos)&>(4,"Mythos"),e.toggles[20]&&e.upgrades[98]===1&&e.transcendPoints.gte(e.fifthCostMythos)&>(5,"Mythos"),e.toggles[22]&&e.cubeUpgrades[7]===1&&e.reincarnationPoints.gte(e.firstCostParticles)&&wn(1,!0),e.toggles[23]&&e.cubeUpgrades[7]===1&&e.reincarnationPoints.gte(e.secondCostParticles)&&wn(2,!0),e.toggles[24]&&e.cubeUpgrades[7]===1&&e.reincarnationPoints.gte(e.thirdCostParticles)&&wn(3,!0),e.toggles[25]&&e.cubeUpgrades[7]===1&&e.reincarnationPoints.gte(e.fourthCostParticles)&&wn(4,!0),e.toggles[26]&&e.cubeUpgrades[7]===1&&e.reincarnationPoints.gte(e.fifthCostParticles)&&wn(5,!0),e.researches[175]>0)for(let c=1;c<=10;c++)e.ascendShards.gte(ao(c).pop())&&so(c,!0);if(e.researches[190]>0&&e.tesseractAutoBuyerToggle===1&&e.resettoggle4<2){let c=[null,null,null,null,null];for(let m=1;m<=5;m++)e.autoTesseracts[m]&&(c[m-1]=e[`ascendBuilding${m}`].owned);let p=Number(e.wowTesseracts)-e.tesseractAutoBuyerAmount,g=kl(c,p);for(let m=5;m>=1;m--){let h=c[m-1],b=g[m-1];h!==null&&b!==null&&b!==h&&ja(m,b-h)}}if(e.researches[130]>0||e.researches[135]>0){let c=[e.achievements[119]>0,e.achievements[126]>0,e.achievements[133]>0,e.achievements[140]>0,e.achievements[147]>0,e.antUpgrades[11]>0||e.ascensionCount>0,jl()],p=!1;if(e.autoEnhanceToggle&&e.researches[135]>0)for(let g=0;g0)for(let g=0;g.5&&(e.fourthGeneratedCoin=e.fourthGeneratedCoin.add(e.fifthGeneratedCoin.add(e.fifthOwnedCoin).times(o.uFifteenMulti).times(o.generatorPower))),e.upgrades[102]>.5&&(e.thirdGeneratedCoin=e.thirdGeneratedCoin.add(e.fourthGeneratedCoin.add(e.fourthOwnedCoin).times(o.uFourteenMulti).times(o.generatorPower))),e.upgrades[103]>.5&&(e.secondGeneratedCoin=e.secondGeneratedCoin.add(e.thirdGeneratedCoin.add(e.thirdOwnedCoin).times(o.generatorPower))),e.upgrades[104]>.5&&(e.firstGeneratedCoin=e.firstGeneratedCoin.add(e.secondGeneratedCoin.add(e.secondOwnedCoin).times(o.generatorPower))),e.upgrades[105]>.5&&(e.fifthGeneratedCoin=e.fifthGeneratedCoin.add(e.firstOwnedCoin));let r=1;r+=1/100*(e.achievements[71]+e.achievements[72]+e.achievements[73]+e.achievements[74]+e.achievements[75]+e.achievements[76]+e.achievements[77]);let n=0;e.upgrades[106]>.5&&(n+=.1),e.upgrades[107]>.5&&(n+=.15),e.upgrades[108]>.5&&(n+=.25),e.upgrades[109]>.5&&(n+=.25),e.upgrades[110]>.5&&(n+=.25),n*=r;let a=0;if(e.upgrades[111]>.5&&(a+=.08),e.upgrades[112]>.5&&(a+=.08),e.upgrades[113]>.5&&(a+=.08),e.upgrades[114]>.5&&(a+=.08),e.upgrades[115]>.5&&(a+=.08),a*=r,t=0,e.upgrades[116]>.5&&(t+=.05),e.upgrades[117]>.5&&(t+=.05),e.upgrades[118]>.5&&(t+=.05),e.upgrades[119]>.5&&(t+=.05),e.upgrades[120]>.5&&(t+=.05),t*=r,n!==0&&(e.fifthGeneratedCoin=e.fifthGeneratedCoin.add(f.pow(e.firstGeneratedDiamonds.add(e.firstOwnedDiamonds).add(1),n))),a!==0&&(e.fifthGeneratedDiamonds=e.fifthGeneratedDiamonds.add(f.pow(e.firstGeneratedMythos.add(e.firstOwnedMythos).add(1),a))),t!==0&&(e.fifthGeneratedMythos=e.fifthGeneratedMythos.add(f.pow(e.firstGeneratedParticles.add(e.firstOwnedParticles).add(1),t))),e.runeshards>e.maxofferings&&(e.maxofferings=e.runeshards),e.researchPoints>e.maxobtainium&&(e.maxobtainium=e.researchPoints),isNaN(e.runeshards)&&(e.runeshards=0),e.runeshards>1e300&&(e.runeshards=1e300),isNaN(e.researchPoints)&&(e.researchPoints=0),e.researchPoints>1e300&&(e.researchPoints=1e300),o.optimalOfferingTimer=600+30*e.researches[85]+.4*o.rune5level+120*e.shopUpgrades.offeringEX,o.optimalObtainiumTimer=3600+120*e.shopUpgrades.obtainiumEX,d0(),e.autoAscend&&e.challengecompletions[11]>0&&e.cubeUpgrades[10]>0&&e.currentChallenge.reincarnation!==10){let c=!1;if(e.autoAscendMode==="c10Completions"&&e.challengecompletions[10]>=Math.max(1,e.autoAscendThreshold)&&(c=!0),e.autoAscendMode==="realAscensionTime"&&e.ascensionCounterRealReal>=Math.max(.1,e.autoAscendThreshold)&&(c=!0),c&&e.challengecompletions[10]>0)if(ti()&&e.currentChallenge.ascension!==0&&e.retrychallenges&&e.researches[150]===1&&e.autoChallengeRunning){let p=ei(e.currentChallenge.ascension+1,!1,11,15);p<=15&&e.currentChallenge.ascension!==p?(Ae("ascensionChallenge",!1,!0),e.currentChallenge.ascension=p,Pe("ascensionChallenge",!1)):(p=ei(e.currentChallenge.ascension+1,!0,11,15),Ae("ascensionChallenge",!1,!0),e.currentChallenge.ascension=p<=15?p:0,Pe("ascensionChallenge",!1))}else e.currentChallenge.ascension!==0?(Ae("ascensionChallenge",!1,!0),Pe("ascensionChallenge",!1)):Pe("ascension",!1)}let s=null;if(e.researches[175]>0)for(let c=1;c<=10;c++)s=ao(c),e.ascendShards.gte(s[1])&&so(c,!0);let l=Pl();if(l!==o.prevReductionValue){o.prevReductionValue=l;let c=["Coin","Diamonds","Mythos"];for(let p=0;p0&&e.currentChallenge.ascension===15&&e.usedCorruptions.slice(2,10).every(c=>c===11)){let c=ko();e.coins.gte(f.pow(10,e.challenge15Exponent/c))&&(e.challenge15Exponent=f.log(e.coins.add(1),10)*c,gl())}},S2=()=>{Io(),bd()},k2=()=>{R0(),$0()},L2=()=>{$t(vr,5e3),$t(k2,200),$t(S2,50),o.timeWarp||Qs()},Hd=0,P2=()=>{Hd=performance.now(),$t(U2,5)},oh=5,A2=20,rc=0,E2=new Date,O2=performance.now(),il=()=>E2.getTime()+(performance.now()-O2),U2=()=>{let r=performance.now()-Hd;rc+=(r-rc)/A2;let n;for(;r>5;)n=oh,n+=rc>16?Math.min(3600*1e3,rc-oh):0,n=Math.min(r,n),B2(n/1e3),Hd+=n,r-=n},B2=t=>{if(!o.timeWarp){let r=qe().mult;if(Rd(t*r),Ie("prestige",t),Ie("transcension",t),Ie("reincarnation",t),Ie("ascension",t),Ie("quarks",t),Ie("goldenQuarks",t),Ie("octeracts",t),Ie("singularity",t),Ie("autoPotion",t),Ie("ambrosia",t),e.shopUpgrades.offeringAuto>0&&e.autoSacrificeToggle&&Br("runeSacrifice",t),e.achievements[173]===1&&Br("antSacrifice",t),e.researches[61]===1?Br("addObtainium",t):Or(),e.autoResearchToggle&&e.autoResearch>0&&e.autoResearch<=kg(e)&&(qt()||e.autoResearchMode==="manual")){let n=0,a=1+e.challengecompletions[14];for(;n0;){{let s=e.autoResearch===200?.01:0;if(!Fr(e.autoResearch,!0,s))break}n++}}}if(e.highestchallengecompletions[3]>0&&Br("addOfferings",t/2),e.cubeUpgrades[2]>0&&Br("addOfferings",t*e.cubeUpgrades[2]),K0(t),(e.resettoggle1===1||e.resettoggle1===0)&&e.toggles[15]&&e.achievements[43]===1&&o.prestigePointGain.gte(e.prestigePoints.times(f.pow(10,e.prestigeamount)))&&e.coinsThisPrestige.gte(1e16)&&(wt(1),Pe("prestige",!0)),e.resettoggle1===2){o.autoResetTimers.prestige+=t;let r=Math.max(.01,e.prestigeamount);e.toggles[15]&&e.achievements[43]===1&&o.autoResetTimers.prestige>=r&&e.coinsThisPrestige.gte(1e16)&&(wt(1),Pe("prestige",!0))}if((e.resettoggle2===1||e.resettoggle2===0)&&e.toggles[21]&&e.upgrades[89]===1&&o.transcendPointGain.gte(e.transcendPoints.times(f.pow(10,e.transcendamount)))&&e.coinsThisTranscension.gte(1e100)&&e.currentChallenge.transcension===0&&(wt(2),Pe("transcension",!0)),e.resettoggle2===2){o.autoResetTimers.transcension+=t;let r=Math.max(.01,e.transcendamount);e.toggles[21]&&e.upgrades[89]===1&&o.autoResetTimers.transcension>=r&&e.coinsThisTranscension.gte(1e100)&&e.currentChallenge.transcension===0&&(wt(2),Pe("transcension",!0))}if(e.currentChallenge.ascension!==12){if(o.autoResetTimers.reincarnation+=t,e.resettoggle3===2){let r=Math.max(.01,e.reincarnationamount);e.toggles[27]&&e.researches[46]>.5&&e.transcendShards.gte("1e300")&&o.autoResetTimers.reincarnation>=r&&e.currentChallenge.transcension===0&&e.currentChallenge.reincarnation===0&&(wt(3),Pe("reincarnation",!0))}(e.resettoggle3===1||e.resettoggle3===0)&&e.toggles[27]&&e.researches[46]>.5&&o.reincarnationPointGain.gte(e.reincarnationPoints.add(1).times(f.pow(10,e.reincarnationamount)))&&e.transcendShards.gte(1e300)&&e.currentChallenge.transcension===0&&e.currentChallenge.reincarnation===0&&(wt(3),Pe("reincarnation",!0))}Qr("reincarnation")},Rf=(t,r)=>{if(!e.toggles[40])return;let a={coin:"Coin",diamond:"Diamonds",mythos:"Mythos",particle:"Particles",tesseract:"Tesseracts"}[o.buildingSubTab];if(t.shiftKey){let s=Number(r)-1;r==="BACKQUOTE"&&(s=-1),e.challengecompletions[11]>0&&!isNaN(s)&&(s>=0&&s0&&(hr(6),lt(6));break;case"7":o.currentTab===0&&o.buildingSubTab==="diamond"&&Yt(2),o.currentTab===4&&e.achievements[113]===1&&(hr(7),lt(7));break;case"8":o.currentTab===0&&o.buildingSubTab==="diamond"&&Yt(3),o.currentTab===4&&e.achievements[120]===1&&(hr(8),lt(8));break;case"9":o.currentTab===0&&o.buildingSubTab==="diamond"&&Yt(4),o.currentTab===4&&e.achievements[127]===1&&(hr(9),lt(9));break;case"0":o.currentTab===0&&o.buildingSubTab==="diamond"&&Yt(5),o.currentTab===4&&e.achievements[134]===1&&(hr(10),lt(10));break}},R2=()=>{let t=i("exitOffline");t.style.visibility="visible",sl(()=>t.focus(),100)},cd=(t=!1)=>{var s,l;yu();let r=sl(()=>i("preloadDeleteGame").style.display="block",1e4);El();let n=localStorage.getItem("Synergysave2");if(n){let c=ih.default.decompressFromBase64(n);if(c!==""){if(!c)return P(u.t("save.loadFailed"));let g=ls(c);if(g===null)return P(u.t("save.loadFailed"));localStorage.clear(),localStorage.setItem("Synergysave2",g),P(u.t("main.transferredFromLZ"))}b2()}if(!t)Ad();else if(e.singularityChallenges.limitedTime.rewards.preserveQuarks||e.worlds.reset(),!vr())return;tl(!0),fm(),rl(),Eu(),bd(),P2(),bn(0),Ce(0,{page:0}),Ce(3,{page:0}),Ce(4,{page:0}),Ce(7,{page:0}),Ce(8,{page:0}),Ce(9,{page:0}),Ce(10,{page:0}),Bd(),$t(Bd,3e4),L2(),Dl(),vu().catch(()=>{}).finally(()=>{$t(()=>vu().catch(c=>{console.error(c)}),1e3*60*5)}),R2(),bu(r),$t(Xl,15e3),localStorage.getItem("pleaseStar")===null&&(P(u.t("main.starRepo")),localStorage.setItem("pleaseStar","")),typeof((s=navigator.storage)==null?void 0:s.persist)=="function"&&typeof((l=navigator.storage)==null?void 0:l.persisted)=="function"&&navigator.storage.persisted().then(c=>c?Promise.resolve(!1):navigator.storage.persist()).then(c=>{c&&P(u.t("main.dataPersistent"))});let a=i("saveType");a.checked=localStorage.getItem("copyToClipboard")!==null};window.addEventListener("load",async()=>{await ah(),Em().catch(console.error);try{await A0()}catch(n){if(console.error(n),!await ye("PseudoCoin bonuses weren't fetched, if you have purchased upgrades they will not take effect. Press OK to continue to the game without upgrades."))return}let t=i("versionnumber"),r=n=>`${n}`.padStart(2,"0");if(t instanceof HTMLElement){let n=isNaN(Nn.getTime())?"":` [Last Update: ${r(Nn.getHours())}:${r(Nn.getMinutes())} UTC ${r(Nn.getDate())}-${Nn.toLocaleString("en-us",{month:"short"})}-${Nn.getFullYear()}].`;t.textContent=`You're ${!1?"testing":"playing"} v${tr} - The Alternate Reality${n} ${!1?u.t("testing.saveInLive"):""}`}document.title=`Synergism v${tr}`,th(),cd(),E0(),ql()},{once:!0});window.addEventListener("unload",()=>{window.scrollTo(0,0)});})(); /*! Bundled license information: clipboard/dist/clipboard.js: diff --git a/index.html b/index.html index d8cc14cf7..0b18b22cd 100644 --- a/index.html +++ b/index.html @@ -4696,12 +4696,17 @@

Artists

> +
+
+
+
PseudoCoins diff --git a/package.json b/package.json index 6d2daf917..38dcc1d08 100644 --- a/package.json +++ b/package.json @@ -38,8 +38,8 @@ "csslint": "npx stylelint Synergism.css", "csslint:fix": "npx stylelint Synergism.css --fix", "htmllint": "npx htmlhint index.html", - "build:esbuild": "npx esbuild src/Synergism.ts --bundle --minify --target=\"chrome58,firefox57,safari11,edge29\" --outfile=\"./dist/out.js\"", - "watch:esbuild": "npx esbuild src/Synergism.ts --bundle --minify --target=\"chrome58,firefox57,safari11,edge29\" --outfile=\"./dist/out.js\" --watch --sourcemap", + "build:esbuild": "npx esbuild src/Synergism.ts --bundle --minify --target=\"chrome58,firefox57,safari11,edge29\" --outfile=\"./dist/out.js\" --define:PROD=true", + "watch:esbuild": "npx esbuild src/Synergism.ts --bundle --minify --target=\"chrome58,firefox57,safari11,edge29\" --outfile=\"./dist/out.js\" --watch --sourcemap --define:PROD=false", "check:tsc": "npx -p typescript tsc", "watch:tsc": "npx -p typescript tsc --watch", "prepare": "husky install", diff --git a/translations/en.json b/translations/en.json index 8aa2c5176..f42405c7f 100644 --- a/translations/en.json +++ b/translations/en.json @@ -2537,6 +2537,7 @@ }, "pseudocoins": { "buy": "Purchase Coins", + "subscriptions": "Subscriptions", "upgrades": "Buy Upgrades", "merch": "Purchase Merch" }