!function(t){functione(e){for(vara,o,s=e[0],l=e[1],c=e[2],u=0,m=[];u<s.length;u++)o=s[u],Object.prototype.hasOwnProperty.call(r,o)&&r[o]&&m.push(r[o][0]),r[o]=0;for(ainl)Object.prototype.hasOwnProperty.call(l,a)&&(t[a]=l[a]);for(f&&f(e);m.length;)m.shift()();returni.push.apply(i,c||[]),n()}functionn(){for(vart,e=0;e<i.length;e++){for(varn=i[e],a=!0,s=1;s<n.length;s++){varl=n[s];0!==r[l]&&(a=!1)}a&&(i.splice(e--,1),t=o(o.s=n[0]))}returnt}vara={},r={0:0},i=[];functiono(e){if(a[e])returna[e].exports;varn=a[e]={i:e,l:!1,exports:{}};returnt[e].call(n.exports,n,n.exports,o),n.l=!0,n.exports}o.m=t,o.c=a,o.d=function(t,e,n){o.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:n})},o.r=function(t){"undefined"!=typeofSymbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},o.t=function(t,e){if(1&e&&(t=o(t)),8&e)returnt;if(4&e&&"object"==typeoft&&t&&t.__esModule)returnt;varn=Object.create(null);if(o.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeoft)for(varaint)o.d(n,a,function(e){returnt[e]}.bind(null,a));returnn},o.n=function(t){vare=t&&t.__esModule?function(){returnt.default}:function(){returnt};returno.d(e,"a",e),e},o.o=function(t,e){returnObject.prototype.hasOwnProperty.call(t,e)},o.p="";vars=window.webpackJsonp=window.webpackJsonp||[],l=s.push.bind(s);s.push=e,s=s.slice();for(varc=0;c<s.length;c++)e(s[c]);varf=l;i.push([1572,1]),n()}([,function(t,e,n){"use strict";n.d(e,"a",(function(){returno})),n.d(e,"b",(function(){returns}));vara=n(589),r=n(111),i=n(16);leto=newa.a;functions(t){o=JSON.parse(t,i.c),o.money=parseFloat(o.money+""),o.exploits=Object(r.c)(o.exploits)}},function(t,e,n){"use strict";n.d(e,"b",(function(){returnC})),n.d(e,"a",(function(){returnI}));vara=n(393),r=n(26),i=n(1),o=n(314),s=n(7),l=n(17),c=n(46),f=n(99),u=n(422),m=n(29),h=n(25),d=n(15),p=n(382),g=n(1087),b=n(191),y=n(599),E=n(468),v=n(629),k=n(265),w=n(292),S=n(93),_=n(19);constC={string:L,number:function(t,e,n){if("string"==typeofn){constt=parseFloat(n);if(!isNaN(t))returnt}elseif("number"==typeofn){if(isNaN(n))throwA(t,`'${e}' is NaN.`);returnn}throwA(t,`'${e}' should be a number. ${x(n)}`,"TYPE")},scriptArgs:O,argsToString:function(t){lete="";for(letnoft)null!==n?void0!==n?(n=Object(v.a)(n),e+="object"==typeofn?JSON.stringify(n):""+n):e+="undefined":e+="null";returne},makeBasicErrorMsg:M,makeRuntimeErrorMsg:A,resolveNetscriptRequestedThreads:function(t,e){constn=t.workerScript.scriptRef.threads;if(!e)returnisNaN(n)||n<1?1:n;consta=0|e;if(isNaN(e)||a<1)throwA(t,`Invalid thread count passed to ${t.function}: ${e}. Threads must be a positive number.`);if(a>n)throwA(t,`Too many threads requested by ${t.function}. Requested: ${e}. Has: ${n}.`);returna},checkEnvFlags:function(t){conste=t.workerScript;if(e.env.stopFlag)throwN(t,()=>"Failed to run due to script being killed."),newo.a(e);if(e.env.runningFn&&"asleep"!==t.function){varn;thrownull===(n=e.delayReject)||void0===n||n.call(e,newo.a(e)),e.env.stopFlag=!0,N(t,()=>"Failed to run due to failed concurrency check."),A(t,`Concurrent calls to Netscript functions are not allowed!\n Did you forget to await hack(), grow(), or some other\n promise-returning function?\n Currently running: ${e.env.runningFn} tried to run: ${t.function}`,"CONCURRENCY")}},checkSingularityAccess:function(t){if(4!==i.a.bitNodeN&&0===i.a.sourceFileLvl(4))throwA(t,"This singularity function requires Source-File 4 to run. A power up you obtain later in the game.\n It will be very obvious when and how you can obtain it.","API ACCESS")},netscriptDelay:function(t,e){constn=t.workerScript;returnnewPromise((function(a,r){n.delay=window.setTimeout(()=>{n.delay=null,n.delayReject=void0,n.env.runningFn="",n.env.stopFlag?r(newo.a(n)):a()},e),n.delayReject=r,n.env.runningFn=t.function}))},updateDynamicRam:function(t,e){constn=t.workerScript,a=t.function;if(n.dynamicLoadedFns[a])return;n.dynamicLoadedFns[a]=!0;letr=n.scriptRef.th
*/r.PARSE_OPTIONS={ecmaVersion:5,locations:!0},r.READONLY_DESCRIPTOR={configurable:!0,enumerable:!0,writable:!1},r.NONENUMERABLE_DESCRIPTOR={configurable:!0,enumerable:!1,writable:!0},r.READONLY_NONENUMERABLE_DESCRIPTOR={configurable:!0,enumerable:!1,writable:!1},r.VARIABLE_DESCRIPTOR={configurable:!1,enumerable:!0,writable:!0},r.STEP_ERROR={},r.SCOPE_REFERENCE={},r.VALUE_IN_DESCRIPTOR={},r.toStringCycles_=[],r.prototype.getErrorLineNumber=function(t){var e=this.sourceCode;if(null==t||null==t.start)return NaN;try{return((e=e.substring(0,t.start)).match(/\n/g)||[]).length+1-this.sourceCodeLineOffset}catch(t){returnNaN}},r.prototype.getErrorLineNumberMessage=function(t){returnisNaN(t)?" (Unknown line number)":t<=0?" (Error occurred in an imported function)":" (Line Number "+t+". This line number is probably incorrect if your script is importing any functions. This is being worked on)"},r.prototype.appendCode=function(t){vare=this.stateStack[0];if(!e||"Program"!==e.node.type)throwError("Expecting original AST to start with a Program node.");if("string"==typeoft&&(t=a.a(t,r.PARSE_OPTIONS)),!t||"Program"!==t.type)throwError("Expecting new AST to start with a Program node.");this.populateScope_(t,e.scope);for(varn,i=0;n=t.body[i];i++)e.node.body.push(n);e.done=!1},r.prototype.step=function(){vart=this.stateStack,e=t[t.length-1];if(!e)return!1;varn=e.node,a=n.type;if("Program"===a&&e.done)return!1;if(this.paused_)return!0;try{vari=this.stepFunctions_[a](t,e,n)}catch(t){if(t!==r.STEP_ERROR)throwt}returni&&t.push(i),!!n.end||this.step()},r.prototype.run=function(){for(;!this.paused_&&this.step(););returnthis.paused_},r.prototype.initGlobalScope=function(t){this.setProperty(t,"NaN",NaN,r.READONLY_DESCRIPTOR),this.setProperty(t,"Infinity",1/0,r.READONLY_DESCRIPTOR),this.setProperty(t,"undefined",void0,r.READONLY_DESCRIPTOR),this.setProperty(t,"window",t,r.READONLY_DESCRIPTOR),this.setProperty(t,"this",t,r.READONLY_DESCRIPTOR),this.setProperty(t,"self",t),this.OBJECT_PROTO=newr.Object(null),this.FUNCTION_PROTO=newr.Object(this.OBJECT_PROTO),this.initFunction(t),this.initObject(t),t.proto=this.OBJECT_PROTO,this.setProperty(t,"constructor",this.OBJECT,r.NONENUMERABLE_DESCRIPTOR),this.initArray(t),this.initString(t),this.initBoolean(t),this.initNumber(t),this.initDate(t),this.initRegExp(t),this.initError(t),this.initMath(t),this.initJSON(t);vare=this,n=this.createNativeFunction((function(t){throwEvalError("Can't happen")}),!1);n.eval=!0,this.setProperty(t,"eval",n),this.setProperty(t,"parseInt",this.createNativeFunction(parseInt,!1)),this.setProperty(t,"parseFloat",this.createNativeFunction(parseFloat,!1)),this.setProperty(t,"isNaN",this.createNativeFunction(isNaN,!1)),this.setProperty(t,"isFinite",this.createNativeFunction(isFinite,!1));for(vara=[[escape,"escape"],[unescape,"unescape"],[decodeURI,"decodeURI"],[decodeURIComponent,"decodeURIComponent"],[encodeURI,"encodeURI"],[encodeURIComponent,"encodeURIComponent"]],i=0;i<a.length;i++){varo=function(t){returnfunction(n){try{returnt(n)}catch(t){e.throwException(e.URI_ERROR,t.message)}}}(a[i][0]);this.setProperty(t,a[i][1],this.createNativeFunction(o,!1),r.NONENUMERABLE_DESCRIPTOR)}this.OBJECT=this.OBJECT,this.OBJECT_PROTO=this.OBJECT_PROTO,this.FUNCTION=this.FUNCTION,this.FUNCTION_PROTO=this.FUNCTION_PROTO,this.ARRAY=this.ARRAY,this.ARRAY_PROTO=this.ARRAY_PROTO,this.REGEXP=this.REGEXP,this.REGEXP_PROTO=this.REGEXP_PROTO,this.DATE=this.DATE,this.DATE_PROTO=this.DATE_PROTO,this.UNDEFINED=void0,this.NULL=null,this.NAN=NaN,this.TRUE=!0,this.FALSE=!1,this.STRING_EMPTY="",this.NUMBER_ZERO=0,this.NUMBER_ONE=1,this.initFunc_&&this.initFunc_(this,t)},r.prototype.initFunction=function(t){vare,n=this,i=/^[A-Za-z_$][\w$]*$/;(e=function(t){if(n.calledWithNew())vare=this;elsee=n.createObjectProto(n.FUNCTION_PROTO);if(arguments.length)varo=String(arguments[arguments.length-1]);elseo="";vars=Array.prototype.slice.call(arguments,0,-1).join(",").trim();if(s){for(varl=s.split(/\s*,\s*/),c=0;c<l.length;c++){varf=l[c];i.test(f)||n.throwException(n.SYNTAX_ERROR,"Invalidfunc
if(!shouldCompile(script,scripts))returnscript.module;if(script.queueCompile=!0,awaitscript.module,!script.queueCompile)returnscript.module;script.queueCompile=!1,script.updateRamUsage(scripts);constuurls=_getScriptUrls(script,scripts,[]),url=uurls[uurls.length-1].url;returnscript.url&&script.url!==url&&URL.revokeObjectURL(script.url),script.dependencies.length>0&&script.dependencies.forEach(t=>URL.revokeObjectURL(t.url)),script.url=uurls[uurls.length-1].url,script.module=newPromise(resolve=>resolve(eval("import(uurls[uurls.length - 1].url)"))),script.dependencies=uurls,script.module}functionisDependencyOutOfDate(t,e,n){consta=e.find(e=>e.filename==t);if(!a)return!0;returna.moduleSequenceNumber>n}functionshouldCompile(t,e){return!t.module||!!t.dependencies.some(n=>isDependencyOutOfDate(n.filename,e,t.moduleSequenceNumber))&&(t.module=null,!0)}function_getScriptUrls(t,e,n){consta=[];for(consteofn)t.dependents.some(t=>t.server===e.server&&t.filename==e.filename)||t.dependents.push({server:e.server,filename:e.filename});n.push(t);try{constr=Object(acorn__WEBPACK_IMPORTED_MODULE_1__.a)(t.code,{sourceType:"module",ecmaVersion:"latest",ranges:!0}),i=[];acorn_walk__WEBPACK_IMPORTED_MODULE_0__.b(r,{ImportDeclaration(t){t.source&&i.push({filename:t.source.value,start:t.source.range[0]+1,end:t.source.range[1]-1})},ExportNamedDeclaration(t){t.source&&i.push({filename:t.source.value,start:t.source.range[0]+1,end:t.source.range[1]-1})},ExportAllDeclaration(t){t.source&&i.push({filename:t.source.value,start:t.source.range[0]+1,end:t.source.range[1]-1})}}),i.sort((t,e)=>e.start-t.start);leto=t.code;for(consttofi){constr=t.filename.startsWith("./")?t.filename.substring(2):t.filename,i=e.filter(t=>Object(_Terminal_DirectoryHelpers__WEBPACK_IMPORTED_MODULE_3__.b)(t.filename,r));if(0===i.length)continue;const[s]=i,l=_getScriptUrls(s,e,n);a.push(...l);constc=l[l.length-1].url;o=o.substring(0,t.start)+c+o.substring(t.end)}o+=`\n//# sourceURL=${t.server}/${t.filename}`;consts=URL.createObjectURL(makeScriptBlob(o));returna.push(new_Script_ScriptUrl__WEBPACK_IMPORTED_MODULE_2__.a(t.filename,s,t.moduleSequenceNumber)),a}catch(t){for(consttofa)URL.revokeObjectURL(t.url);throwt}finally{n.pop()}}},function(t,e,n){"use strict";n.d(e,"a",(function(){returnr}));vara=n(26);functionr(t){if(null!=t.ramUsage&&t.ramUsage>0)returnt.ramUsage;conste=Object(a.d)(t.server);if(null==e)return0;for(letn=0;n<e.scripts.length;++n)if(e.scripts[n].filename===t.filename)returnt.ramUsage=e.scripts[n].ramUsage,t.ramUsage;return0}},function(t,e,n){"use strict";n.d(e,"a",(function(){returnu}));vara=n(9),r=n(77),i=n(22),o=n(95),s=n(1132),l=n(132);constc="/** @param {NS} ns */\nexport async function main(ns) {\n\n}";functionf({args:t,server:e}){if(1==t.length&&(""+t[0]).includes("*")){returnfunction(t,e){constn={glob:t,preGlob:"",postGlob:"",globError:"",globMatches:[],globAgainst:e};if(1!==(t=t.replace("**","*")).split("").filter(t=>"*"==t).length)returnn.globError="Only a single glob is supported per command.\nexample: `nano my-dir/*.js`",n;[n.preGlob,n.postGlob]=t.split("*"),n.preGlob=Object(r.k)(n.preGlob);consti=Object(r.l)(a.a.cwd());returnn.preGlob=`${i}/${n.preGlob}`,e.forEach(t=>{conste=t.filename.startsWith("/")?t.filename:"/"+t.filename;e.startsWith(n.preGlob)&&e.endsWith(n.postGlob)&&n.globMatches.push(e)}),n.glob=`${n.preGlob}*${n.postGlob}`,n}(""+t[0],e.scripts)}returnnull}functionu(t,{args:e,server:n},r){if(e.length<1)returnvoida.a.error(`Incorrect usage of ${t} command. Usage: ${t} [scriptname]`);letu=e;try{constm=f({args:e,server:n});if(m){if(!1===Object(l.isEmpty)(m.globError))thrownewError(m.globError);u=m.globMatches}consth=u.map(e=>{constn=""+e;if(Object(o.a)(n)){constt=a.a.getFilepath(n),e=a.a.getScript(n),r=function(t){returnt.endsWith(".js")}(n),i=null!==e?e.code:r?c:"";returni===c&&s.a.saveCursor(n,{row:3,column:5}),[t,i]}if(n.endsWith(".txt")){constt=a.a.getFilepath(n),e=a.a.getTextFile(n);return[t,null===e?"":e.text]}thrownewError("Invalidfile.Onlyscripts(.scriptor.js),ortext