From 542a32c76842ca24f3525d18a9645f1b387bc6a0 Mon Sep 17 00:00:00 2001 From: Daniel Xie Date: Wed, 5 Jul 2017 11:49:01 -0500 Subject: [PATCH] MOre rebalancing with universities and companies --- src/Company.js | 4 ++-- src/Constants.js | 15 ++++++++------- src/HacknetNode.js | 3 +++ src/Player.js | 14 +++++++------- src/StockMarket.js | 13 ++++++++++--- 5 files changed, 30 insertions(+), 19 deletions(-) diff --git a/src/Company.js b/src/Company.js index 799e430ae..e487a5c94 100644 --- a/src/Company.js +++ b/src/Company.js @@ -295,9 +295,9 @@ CompanyPositions = { CompanyPositions.LeadDev.setExperienceGains(.5, 0, 0, 0, 0, .1); CompanyPositions.SoftwareConsultant.setPerformanceParameters(80, 0, 0, 0, 0, 20, 1); - CompanyPositions.SoftwareConsultant.setExperienceGains(.175, 0, 0, 0, 0, .03); + CompanyPositions.SoftwareConsultant.setExperienceGains(.08, 0, 0, 0, 0, .03); CompanyPositions.SeniorSoftwareConsultant.setPerformanceParameters(75, 0, 0, 0, 0, 25, 1.2); - CompanyPositions.SeniorSoftwareConsultant.setExperienceGains(.35, 0, 0, 0, 0, .06); + CompanyPositions.SeniorSoftwareConsultant.setExperienceGains(.25, 0, 0, 0, 0, .06); //Security CompanyPositions.ITIntern.setPerformanceParameters(90, 0, 0, 0, 0, 10, 0.9); diff --git a/src/Constants.js b/src/Constants.js index e63460d6d..c49b30f05 100644 --- a/src/Constants.js +++ b/src/Constants.js @@ -152,12 +152,12 @@ CONSTANTS = { ClassGymDexterity: "training your dexterity at a gym", ClassGymAgility: "training your agility at a gym", - ClassDataStructuresBaseCost: 10, - ClassNetworksBaseCost: 32, - ClassAlgorithmsBaseCost: 120, - ClassManagementBaseCost: 60, - ClassLeadershipBaseCost: 120, - ClassGymBaseCost: 100, + ClassDataStructuresBaseCost: 30, + ClassNetworksBaseCost: 60, + ClassAlgorithmsBaseCost: 240, + ClassManagementBaseCost: 120, + ClassLeadershipBaseCost: 240, + ClassGymBaseCost: 120, CrimeShoplift: "shoplift", CrimeMug: "mug someone", @@ -910,10 +910,11 @@ CONSTANTS = { "v0.24.1
" + "-Adjusted cost of upgrading home computer RAM. Should be a little cheaper for the first few upgrades (up to ~64GB), and " + "then will start being more expensive than before. High RAM upgrades should now be significantly more expensive than before.
" + - "-Very slightly lowered the starting money available on most mid-game and end-game servers (servers with required hacking level " + + "-Slightly lowered the starting money available on most mid-game and end-game servers (servers with required hacking level " + "greater than 200) by about 10-15%
" + "-Rebalanced company/company position reputation gains and requirements
" + "-Studying at a university now gives slightly more EXP and early jobs give slightly less EXP
" + + "-Studying at a university is now considerably more expensive
" + "-Significantly increased cost multiplier for purchasing additional Hacknet Nodes
" + "-Updated Faction descriptions
" + "-'top' Terminal command implemented courtesy of Github user LTCNugget

" + diff --git a/src/HacknetNode.js b/src/HacknetNode.js index e87cf0ae5..e4f97d581 100644 --- a/src/HacknetNode.js +++ b/src/HacknetNode.js @@ -216,6 +216,9 @@ getMaxNumberLevelUpgrades = function(nodeObj) { var min = 1; var max = CONSTANTS.HacknetNodeMaxLevel-1; var levelsToMax = CONSTANTS.HacknetNodeMaxLevel - nodeObj.level; + if (nodeObj.calculateLevelUpgradeCost(levelsToMax) < Player.money) { + return levelsToMax; + } while (min <= max) { var curr = (min + max) / 2 | 0; diff --git a/src/Player.js b/src/Player.js index 04fcc3040..6423d0f3b 100644 --- a/src/Player.js +++ b/src/Player.js @@ -938,13 +938,13 @@ PlayerObject.prototype.startClass = function(costMult, expMult, className) { var gameCPS = 1000 / Engine._idleSpeed; //Base exp gains per second - var baseStudyComputerScienceExp = 0.3; - var baseDataStructuresExp = 0.6; - var baseNetworksExp = 1.2; - var baseAlgorithmsExp = 2.4; - var baseManagementExp = 1.0; - var baseLeadershipExp = 2.0; - var baseGymExp = 1.0; + var baseStudyComputerScienceExp = 0.25; + var baseDataStructuresExp = 0.5; + var baseNetworksExp = 1; + var baseAlgorithmsExp = 2; + var baseManagementExp = 1; + var baseLeadershipExp = 2; + var baseGymExp = 1; //Find cost and exp gain per game cycle var cost = 0; diff --git a/src/StockMarket.js b/src/StockMarket.js index 3deb0ea80..7e138e486 100644 --- a/src/StockMarket.js +++ b/src/StockMarket.js @@ -491,15 +491,22 @@ function displayStockMarketContent() { li.appendChild(sharesTxt); li.appendChild(returnTxt); stockList.appendChild(li); - - updateStockTicker(stock, true); - updateStockPlayerPosition(stock); }()); //Immediate invocation }//End if } stockMarketContentCreated = true; } + + if (Player.hasWseAccount) { + for (var name in StockMarket) { + if (StockMarket.hasOwnProperty(name)) { + var stock = StockMarket[name]; + updateStockTicker(stock, true); + updateStockPlayerPosition(stock); + } + } + } } //'increase' argument is a boolean indicating whether the price increased or decreased