mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2026-04-23 01:32:55 +02:00
Netscript reimplementation
This commit is contained in:
@@ -1,8 +1,12 @@
|
||||
/* Environment
|
||||
* NetScript program environment
|
||||
*/
|
||||
function Environment(parent) {
|
||||
this.vars = Object.create(parent ? parent.vars : null);
|
||||
function Environment(workerScript,parent) {
|
||||
if (parent){
|
||||
this.vars = parent.vars;
|
||||
} else {
|
||||
this.vars = NetscriptFunctions(workerScript);
|
||||
}
|
||||
this.parent = parent;
|
||||
this.stopFlag = false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user