Buffed crimes and hacking. Increased growth rate of servers. Added getHostanme command. Added preventDefault() for ctrl+b in script editor. Buffed Neuroflux Governor, which adds 1% to all multipliers, and made it more expensive. Nerfed Hacknet Node base production. Fixed nested for loop issue

This commit is contained in:
Daniel Xie
2017-05-29 17:37:38 -05:00
parent a453d96d50
commit af47baf4fa
14 changed files with 180 additions and 85 deletions
+6 -2
View File
@@ -25,8 +25,10 @@ Environment.prototype = {
//Get the current value of a variable
get: function(name) {
if (name in this.vars)
if (name in this.vars) {
return this.vars[name];
}
console.log("here");
throw new Error("Undefined variable " + name);
},
@@ -37,8 +39,10 @@ Environment.prototype = {
//
// If scope is null (aka existing variable with name could not be found)
// and this is NOT the global scope, throw error
if (!scope && this.parent)
if (!scope && this.parent) {
console.log("Here");
throw new Error("Undefined variable " + name);
}
return (scope || this).vars[name] = value;
},