diff --git a/README.md b/README.md index dcc18dfe2..559295e76 100644 --- a/README.md +++ b/README.md @@ -39,4 +39,11 @@ Private beta feedback Also not really a big deal, but I'm at 110% zoom on chrome and the tutorial window covers some of the text - Now, only other suggestion before sleep would be to be able to buy multiple Hacknet upgrades in one click \ No newline at end of file + Now, only other suggestion before sleep would be to be able to buy multiple Hacknet upgrades in one click + +1) - multiple commands to do the same thing? (why?) <--- there are a few of these in the initial help... clear/cls, scan/netstat, connect/telnet... Maybe just pick one to unclutter it? +2) - "Wrong Command! Try Again!" seemed a bit out of place for a terminal. Trying to repro this, it seems you may have already fixed it? +3) - If you can help it, please don't require the code to be exactly pasted from the tutorial to finish the tutorial. I copied the code and then "corrected" the brackets and spacing... and it wouldn't let me continue. :D +5) - As a programmer... you cannot take the TAB key from us in the script editor. :neutral_face: Not sure how the game itself is coded, but if you've got to EAT a ghost-tab just to give me one in-editor... let me tab out my code in-script, or I'll go mad. +6) - Maybe show total $ somewhere onscreen at all (or most) times. $/sec would also be good to know, depending on if you want the player to know that. Bottom of the menu on the left is an empty enough place to keep these. +7) - default the focus to in-editor when you nano up a new script, so you can start typing immediately upon commanding one to be created. \ No newline at end of file diff --git a/src/Constants.js b/src/Constants.js index 188beef91..5e3074d26 100644 --- a/src/Constants.js +++ b/src/Constants.js @@ -18,13 +18,13 @@ CONSTANTS = { BaseCostForHacknetNodeCore: 1000000, /* Hacknet Node constants */ - HacknetNodeMoneyGainPerLevel: 0.75, - HacknetNodePurchaseNextMult: 1.35, //Multiplier when purchasing an additional hacknet node + HacknetNodeMoneyGainPerLevel: 1, + HacknetNodePurchaseNextMult: 1.30, //Multiplier when purchasing an additional hacknet node HacknetNodeUpgradeLevelMult: 1.06, //Multiplier for cost when upgrading level - HacknetNodeUpgradeRamMult: 1.25, //Multiplier for cost when upgrading RAM - HacknetNodeUpgradeCoreMult: 1.45, //Multiplier for cost when buying another core + HacknetNodeUpgradeRamMult: 1.20, //Multiplier for cost when upgrading RAM + HacknetNodeUpgradeCoreMult: 1.40, //Multiplier for cost when buying another core - HacknetNodeMaxLevel: 500, + HacknetNodeMaxLevel: 200, HacknetNodeMaxRam: 64, HacknetNodeMaxCores: 16, @@ -58,7 +58,7 @@ CONSTANTS = { ServerGrowthRate: 1.00075, //Maximum number of log entries for a script - MaxLogCapacity: 20, + MaxLogCapacity: 40, //How much a TOR router costs TorRouterCost: 100000, diff --git a/src/HacknetNode.js b/src/HacknetNode.js index 88c0bba13..01264b705 100644 --- a/src/HacknetNode.js +++ b/src/HacknetNode.js @@ -19,7 +19,7 @@ HacknetNode.prototype.updateMoneyGainRate = function() { //Each CPU core doubles the speed. Every 1GB of ram adds 15% increase this.moneyGainRatePerSecond = (this.level * gainPerLevel) * Math.pow(1.05, this.ram-1) * - this.numCores * Player.hacknet_node_money_mult; + ((this.numCores + 1) / 2) * Player.hacknet_node_money_mult; if (isNaN(this.moneyGainRatePerSecond)) { this.moneyGainRatePerSecond = 0; dialogBoxCreate("Error in calculating Hacknet Node production. Please report to game developer"); diff --git a/src/Player.js b/src/Player.js index 2931adc4b..533ea0e0f 100644 --- a/src/Player.js +++ b/src/Player.js @@ -433,6 +433,7 @@ PlayerObject.prototype.startWork = function() { //Remove all old event listeners from Cancel button var newCancelButton = clearEventListeners("work-in-progress-cancel-button"); + newCancelButton.innerHTML = "Cancel Work"; newCancelButton.addEventListener("click", function() { Player.finishWork(true); return false; @@ -508,6 +509,7 @@ PlayerObject.prototype.startWorkPartTime = function() { this.timeNeededToCompleteWork = CONSTANTS.MillisecondsPer8Hours; var newCancelButton = clearEventListeners("work-in-progress-cancel-button"); + newCancelButton.innerHTML = "Stop Working"; newCancelButton.addEventListener("click", function() { Player.finishWorkPartTime(); return false; @@ -632,13 +634,9 @@ PlayerObject.prototype.startFactionWork = function(faction) { this.timeNeededToCompleteWork = CONSTANTS.MillisecondsPer20Hours; - var cancelButton = document.getElementById("work-in-progress-cancel-button"); - - //Remove all old event listeners from Cancel button - var newCancelButton = cancelButton.cloneNode(true); - cancelButton.parentNode.replaceChild(newCancelButton, cancelButton); - - newCancelButton.addEventListener("click", function() { + var cancelButton = clearEventListeners("work-in-progress-cancel-button"); + cancelButton.innerHTML = "Stop Faction Work"; + cancelButton.addEventListener("click", function() { Player.finishFactionWork(true, faction); return false; }); @@ -836,13 +834,9 @@ PlayerObject.prototype.startCreateProgramWork = function(programName, time) { this.createProgramName = programName; - var cancelButton = document.getElementById("work-in-progress-cancel-button"); - - //Remove all old event listeners from Cancel button - var newCancelButton = cancelButton.cloneNode(true); - cancelButton.parentNode.replaceChild(newCancelButton, cancelButton); - - newCancelButton.addEventListener("click", function() { + var cancelButton = clearEventListeners("work-in-progress-cancel-button"); + cancelButton.innerHTML = "Cancel work on creating program"; + cancelButton.addEventListener("click", function() { Player.finishCreateProgramWork(true, programName); return false; }); @@ -957,13 +951,16 @@ PlayerObject.prototype.startClass = function(costMult, expMult, className) { this.workAgiExpGainRate = agiExp * this.agility_exp_mult; this.workChaExpGainRate = chaExp * this.charisma_exp_mult; - var cancelButton = document.getElementById("work-in-progress-cancel-button"); - - //Remove all old event listeners from Cancel button - var newCancelButton = cancelButton.cloneNode(true); - cancelButton.parentNode.replaceChild(newCancelButton, cancelButton); - - newCancelButton.addEventListener("click", function() { + var cancelButton = clearEventListeners("work-in-progress-cancel-button"); + if (className == CONSTANTS.ClassGymStrength || + className == CONSTANTS.ClassGymDefense || + className == CONSTANTS.ClassGymDexterity || + className == CONSTANTS.ClassGymAgility) { + cancelButton.innerHTML = "Stop training at gym"; + } else { + cancelButton.innerHTML = "Stop taking course"; + } + cancelButton.addEventListener("click", function() { Player.finishClass(); return false; }); @@ -1049,6 +1046,7 @@ PlayerObject.prototype.startCrime = function(hackExp, strExp, defExp, dexExp, ag //Remove all old event listeners from Cancel button var newCancelButton = clearEventListeners("work-in-progress-cancel-button") + newCancelButton.innerHTML = "Cancel crime" newCancelButton.addEventListener("click", function() { Player.finishCrime(true); return false; diff --git a/src/Script.js b/src/Script.js index 1654ec64b..325bc064f 100644 --- a/src/Script.js +++ b/src/Script.js @@ -3,16 +3,29 @@ */ //Initialize the 'save and close' button on script editor page -function scriptEditorSaveCloseInit() { +function scriptEditorInit() { var closeButton = document.getElementById("script-editor-save-and-close-button"); closeButton.addEventListener("click", function() { saveAndCloseScriptEditor(); return false; }); + + var textareas = document.getElementsByTagName('textarea'); + var count = textareas.length; + for(var i=0;i