Merge pull request #71 from danielyxie/dev

Dev v0.22.0
This commit is contained in:
danielyxie
2017-06-21 14:55:42 -05:00
committed by GitHub
24 changed files with 1007 additions and 537 deletions

View File

@ -239,6 +239,7 @@ background-color: #555;
background-color: #555;
width: auto;
display: none;
margin-bottom: 6px;
}
.active-scripts-script-panel p,
@ -251,6 +252,26 @@ background-color: #555;
margin-left: 5%;
}
.active-scripts-button {
color: #aaa;
font-size: 16px;
font-weight: bold;
-webkit-border-radius: 12px;
-moz-border-radius: 12px;
border-radius: 12px;
-moz-box-shadow: 1px 1px 3px #000;
-webkit-box-shadow: 1px 1px 3px #000;
box-shadow: 1px 1px 3px #000;
margin: 4px;
padding: 4px;
}
.active-scripts-button:hover,
.active-scripts-button:focus {
color: white;
text-decoration: none;
cursor: pointer;
}
/* Hacknet Nodes */
#hacknet-nodes-container {
@ -396,6 +417,10 @@ background-color: #555;
margin: 6px;
}
#faction-favor, #faction-reputation {
display: inline;
}
#faction-hack-div,
#faction-fieldwork-div,
#faction-securitywork-div,
@ -452,6 +477,7 @@ div.faction-clear {
margin-left: 10%;
width: 99%;
color: var(--my-font-color);
overflow-y: auto;
}
#faction-augmentations-container p,
@ -545,3 +571,7 @@ div.faction-clear {
margin: 10px 5px 10px 5px;
}
#location-job-reputation, #location-company-favor {
display: inline;
}

View File

@ -52,7 +52,7 @@
#log-box-close {
position: fixed;
right: 27%;
right: 26%;
}
.dialog-box-close-button:hover,

View File

@ -457,9 +457,11 @@
<div id="faction-container">
<h1 id="faction-name"></h1>
<p id="faction-info"></p>
<p id="faction-reputation"></p>
<p> --------------- </p>
<p id="faction-reputation" class="tooltip"></p>
<p> --------------- </p>
<p id="faction-favor" class="tooltip"></p>
<p> --------------- </p>
<p id="faction-work-description-text">
Perform work/carry out assignments for your faction to help further its cause! By doing so
you will gain reputation for your faction. You will also gain reputation passively over time,
@ -569,7 +571,11 @@
<p id="location-info"> </p>
<p id="location-job-title"> </p>
<p id="location-job-reputation"> </p>
<p id="location-text-divider-1"> --------------- </p>
<p id="location-job-reputation" class="tooltip"> </p>
<p id="location-text-divider-2"> --------------- </p>
<p id="location-company-favor" class="tooltip"> </p>
<p id="location-text-divider-3"> --------------- </p>
<!-- Jobs/Work at a company -->
<a id="location-software-job" class="a-link-button"> Apply for Software Job</a>

View File

@ -232,6 +232,24 @@ function createActiveScriptsText(workerscript, item) {
item.appendChild(itemText);
var logButton = document.createElement("span");
logButton.innerHTML = "Log";
var killButton = document.createElement("span");
killButton.innerHTML = "Kill script";
logButton.setAttribute("class", "active-scripts-button");
killButton.setAttribute("class", "active-scripts-button");
logButton.addEventListener("click", function() {
logBoxCreate(workerscript.scriptRef);
return false;
});
killButton.addEventListener("click", function() {
killWorkerScript(workerscript.scriptRef, workerscript.scriptRef.scriptRef.server);
dialogBoxCreate("Killing script, may take a few minutes to complete...");
return false;
});
item.appendChild(logButton);
item.appendChild(killButton);
//Return total online production rate
return onlineMps;
}

View File

@ -30,6 +30,14 @@ function getAlias(name) {
return null;
}
function removeAlias(name) {
if (Aliases.hasOwnProperty(name)) {
delete Aliases[name];
return true;
}
return false;
}
//Returns the original string with any aliases substituted in
//Aliases only applied to "whole words", one level deep
function substituteAliases(origCommand) {

View File

@ -156,7 +156,7 @@ initAugmentations = function() {
//Combat stat augmentations
var HemoRecirculator = new Augmentation(AugmentationNames.HemoRecirculator);
HemoRecirculator.setInfo("A heart implant that greatly increases the body's ability to effectively use and pump " +
"blood. <br><br> This augmentation increases all of the player's combat stats by 15%.")
"blood. <br><br> This augmentation increases all of the player's combat stats by 10%.")
HemoRecirculator.setRequirements(4000, 9000000);
HemoRecirculator.addToFactions(["Tetrads", "The Dark Army", "The Syndicate"]);
if (augmentationExists(AugmentationNames.HemoRecirculator)) {
@ -170,7 +170,7 @@ initAugmentations = function() {
Targeting1.setInfo("This cranial implant is embedded within the player's inner ear structure and optic nerves. It regulates and enhances the user's " +
"balance and hand-eye coordination. It is also capable of augmenting reality by projecting digital information " +
"directly onto the retina. These enhancements allow the player to better lock-on and keep track of enemies. <br><br>" +
"This augmentation increases the player's dexterity by 20%.");
"This augmentation increases the player's dexterity by 15%.");
Targeting1.addToFactions(["Slum Snakes", "The Dark Army", "The Syndicate", "Sector-12", "Volhaven", "Ishima",
"OmniTek Incorporated", "KuaiGong International", "Blade Industries"]);
if (augmentationExists(AugmentationNames.Targeting1)) {
@ -183,7 +183,7 @@ initAugmentations = function() {
Targeting2.setRequirements(3500, 8500000);
Targeting2.setInfo("This is an upgrade of the Augmented Targeting I cranial implant, which is capable of augmenting reality " +
"and enhances the user's balance and hand-eye coordination. <br><br>This upgrade increases the player's dexterity " +
"by an additional 40%.");
"by an additional 25%.");
Targeting2.addToFactions(["The Dark Army", "The Syndicate", "Sector-12", "Volhaven", "Ishima",
"OmniTek Incorporated", "KuaiGong International", "Blade Industries"]);
if (augmentationExists(AugmentationNames.Targeting2)) {
@ -196,7 +196,7 @@ initAugmentations = function() {
Targeting3.setRequirements(11000, 23000000);
Targeting3.setInfo("This is an upgrade of the Augmented Targeting II cranial implant, which is capable of augmenting reality " +
"and enhances the user's balance and hand-eye coordination. <br><br>This upgrade increases the player's dexterity " +
"by an additional 60%.");
"by an additional 40%.");
Targeting3.addToFactions(["The Dark Army", "The Syndicate", "OmniTek Incorporated",
"KuaiGong International", "Blade Industries", "The Covenant"]);
if (augmentationExists(AugmentationNames.Targeting3)) {
@ -209,7 +209,7 @@ initAugmentations = function() {
SyntheticHeart.setRequirements(300000, 575000000);
SyntheticHeart.setInfo("This advanced artificial heart, created from plasteel and graphene, is capable of pumping more blood " +
"at much higher efficiencies than a normal human heart.<br><br> This augmentation increases the player's agility " +
"and strength by 100%");
"and strength by 50%");
SyntheticHeart.addToFactions(["KuaiGong International", "Fulcrum Secret Technologies", "Speakers for the Dead",
"NWO", "The Covenant", "Daedalus", "Illuminati"]);
if (augmentationExists(AugmentationNames.SyntheticHeart)) {
@ -223,7 +223,7 @@ initAugmentations = function() {
SynfibrilMuscle.setInfo("The myofibrils in human muscles are injected with special chemicals that react with the proteins inside " +
"the myofibrils, altering their underlying structure. The end result is muscles that are stronger and more elastic. " +
"Scientists have named these artificially enhanced units 'synfibrils'.<br><br> This augmentation increases the player's " +
"strength and defense by 80%.");
"strength and defense by 35%.");
SynfibrilMuscle.addToFactions(["KuaiGong International", "Fulcrum Secret Technologies", "Speakers for the Dead",
"NWO", "The Covenant", "Daedalus", "Illuminati", "Blade Industries"]);
if (augmentationExists(AugmentationNames.SynfibrilMuscle)) {
@ -236,7 +236,7 @@ initAugmentations = function() {
CombatRib1.setRequirements(2500, 4500000);
CombatRib1.setInfo("The human body's ribs are replaced with artificial ribs that automatically and continuously release cognitive " +
"and performance-enhancing drugs into the bloodstream, improving the user's abilities in combat.<br><br>" +
"This augmentation increases the player's strength and defense by 15%.");
"This augmentation increases the player's strength and defense by 10%.");
CombatRib1.addToFactions(["Slum Snakes", "The Dark Army", "The Syndicate", "Sector-12", "Volhaven", "Ishima",
"OmniTek Incorporated", "KuaiGong International", "Blade Industries"]);
if (augmentationExists(AugmentationNames.CombatRib1)) {
@ -248,7 +248,7 @@ initAugmentations = function() {
var CombatRib2 = new Augmentation(AugmentationNames.CombatRib2);
CombatRib2.setRequirements(7000, 12000000);
CombatRib2.setInfo("This is an upgrade to the Combat Rib I augmentation, and is capable of releasing even more potent combat-enhancing " +
"drugs into the bloodstream<br><br>. This upgrade increases the player's strength and defense by an additional 25%.")
"drugs into the bloodstream<br><br>. This upgrade increases the player's strength and defense by an additional 15%.")
CombatRib2.addToFactions(["The Dark Army", "The Syndicate", "Sector-12", "Volhaven", "Ishima",
"OmniTek Incorporated", "KuaiGong International", "Blade Industries"]);
if (augmentationExists(AugmentationNames.CombatRib2)) {
@ -260,7 +260,7 @@ initAugmentations = function() {
var CombatRib3 = new Augmentation(AugmentationNames.CombatRib3);
CombatRib3.setRequirements(12000, 22000000);
CombatRib3.setInfo("This is an upgrade to the Combat Rib II augmentation, and is capable of releasing even more potent combat-enhancing " +
"drugs into the bloodstream<br><br>. This upgrade increases the player's strength and defense by an additional 40%.");
"drugs into the bloodstream<br><br>. This upgrade increases the player's strength and defense by an additional 20%.");
CombatRib3.addToFactions(["The Dark Army", "The Syndicate", "OmniTek Incorporated",
"KuaiGong International", "Blade Industries", "The Covenant"]);
if (augmentationExists(AugmentationNames.CombatRib3)) {
@ -273,7 +273,7 @@ initAugmentations = function() {
NanofiberWeave.setRequirements(14000, 20000000);
NanofiberWeave.setInfo("Synthetic nanofibers are woven into the skin's extracellular matrix using electrospinning. " +
"This improves the skin's ability to regenerate itself and protect the body from external stresses and forces.<br><br>" +
"This augmentation increases the player's strength and defense by 40%.");
"This augmentation increases the player's strength and defense by 25%.");
NanofiberWeave.addToFactions(["Tian Di Hui", "The Syndicate", "The Dark Army", "Speakers for the Dead",
"Blade Industries", "Fulcrum Secret Technologies", "OmniTek Incorporated"]);
if (augmentationExists(AugmentationNames.NanofiberWeave)) {
@ -289,7 +289,7 @@ initAugmentations = function() {
"that has ever been created. The dilatant fluid, despite being thin and light, is extremely effective " +
"at stopping piercing blows and reducing blunt trauma. The properties of graphene allow the plating to " +
"mitigate damage from any fire-related or electrical traumas.<br><br>" +
"This augmentation increases the player's defense by 150%.");
"This augmentation increases the player's defense by 125%.");
SubdermalArmor.addToFactions(["The Syndicate", "Fulcrum Secret Technologies", "Illuminati", "Daedalus",
"The Covenant"]);
if (augmentationExists(AugmentationNames.SubdermalArmor)) {
@ -302,7 +302,7 @@ initAugmentations = function() {
WiredReflexes.setRequirements(500, 500000);
WiredReflexes.setInfo("Synthetic nerve-enhancements are injected into all major parts of the somatic nervous system, " +
"supercharging the body's ability to send signals through neurons. This results in increased reflex speed.<br><br>" +
"This augmentation increases the player's agility and dexterity by 10%.");
"This augmentation increases the player's agility and dexterity by 5%.");
WiredReflexes.addToFactions(["Tian Di Hui", "Slum Snakes", "Sector-12", "Volhaven", "Aevum", "Ishima",
"The Syndicate", "The Dark Army", "Speakers for the Dead"]);
if (augmentationExists(AugmentationNames.WiredReflexes)) {
@ -315,7 +315,7 @@ initAugmentations = function() {
GrapheneBoneLacings.setRequirements(450000, 850000000);
GrapheneBoneLacings.setInfo("A graphene-based material is grafted and fused into the user's bones, significantly increasing " +
"their density and tensile strength.<br><br>" +
"This augmentation increases the player's strength and defense by 125%.");
"This augmentation increases the player's strength and defense by 75%.");
GrapheneBoneLacings.addToFactions(["Fulcrum Secret Technologies", "The Covenant"]);
if (augmentationExists(AugmentationNames.GrapheneBoneLacings)) {
GrapheneBoneLacings.owned = Augmentations[AugmentationNames.GrapheneBoneLacings].owned;
@ -329,7 +329,7 @@ initAugmentations = function() {
"Not only is the Bionic Spine physically stronger than a human spine, but it is also capable of digitally " +
"stimulating and regulating the neural signals that are sent and received by the spinal cord. This results in " +
"greatly improved senses and reaction speeds.<br><br>" +
"This augmentation increases all of the player's combat stats by 25%.");
"This augmentation increases all of the player's combat stats by 18%.");
BionicSpine.addToFactions(["Speakers for the Dead", "The Syndicate", "KuaiGong International",
"OmniTek Incorporated", "Blade Industries"]);
if (augmentationExists(AugmentationNames.BionicSpine)) {
@ -342,7 +342,7 @@ initAugmentations = function() {
GrapheneBionicSpine.setRequirements(650000, 1200000000);
GrapheneBionicSpine.setInfo("An upgrade to the Bionic Spine augmentation. It fuses the implant with an advanced graphene " +
"material to make it much stronger and lighter.<br><br>" +
"This augmentation increases all of the player's combat stats by 100%.");
"This augmentation increases all of the player's combat stats by 65%.");
GrapheneBionicSpine.addToFactions(["Fulcrum Secret Technologies", "ECorp"]);
if (augmentationExists(AugmentationNames.GrapheneBionicSpine)) {
GrapheneBionicSpine.owned = Augmentations[AugmentationNames.GrapheneBionicSpine].owned;
@ -353,7 +353,7 @@ initAugmentations = function() {
var BionicLegs = new Augmentation(AugmentationNames.BionicLegs);
BionicLegs.setRequirements(60000, 75000000);
BionicLegs.setInfo("Cybernetic legs created from plasteel and carbon fibers that completely replace the user's organic legs. <br><br>" +
"This augmentation increases the player's agility by 75%.");
"This augmentation increases the player's agility by 60%.");
BionicLegs.addToFactions(["Speakers for the Dead", "The Syndicate", "KuaiGong International",
"OmniTek Incorporated", "Blade Industries"]);
if (augmentationExists(AugmentationNames.BionicLegs)) {
@ -366,7 +366,7 @@ initAugmentations = function() {
GrapheneBionicLegs.setRequirements(300000, 900000000);
GrapheneBionicLegs.setInfo("An upgrade to the Bionic Legs augmentation. It fuses the implant with an advanced graphene " +
"material to make it much stronger and lighter.<br><br>" +
"This augmentation increases the player's agility by an additional 200%.");
"This augmentation increases the player's agility by an additional 175%.");
GrapheneBionicLegs.addToFactions(["MegaCorp", "ECorp", "Fulcrum Secret Technologies"]);
if (augmentationExists(AugmentationNames.GrapheneBionicLegs)) {
GrapheneBionicLegs.owned = Augmentations[AugmentationNames.GrapheneBionicLegs].owned;
@ -422,7 +422,7 @@ initAugmentations = function() {
var BitWire = new Augmentation(AugmentationNames.BitWire);
BitWire.setRequirements(1500, 2000000);
BitWire.setInfo("A small brain implant embedded in the cerebrum. This regulates and improves the brain's computing " +
"capabilities. <br><br> This augmentation increases the player's hacking skill by 10%");
"capabilities. <br><br> This augmentation increases the player's hacking skill by 5%");
BitWire.addToFactions(["CyberSec", "NiteSec"]);
if (augmentationExists(AugmentationNames.BitWire)) {
BitWire.owned = Augmentations[AugmentationNames.BitWire].owned;
@ -440,7 +440,7 @@ initAugmentations = function() {
"This augmentation:<br>" +
"Increases the player's hacking speed by 3%<br>" +
"Increases the amount of money the player's gains from hacking by 15%<br>" +
"Inreases the player's hacking skill by 15%");
"Inreases the player's hacking skill by 12%");
ArtificialBioNeuralNetwork.addToFactions(["BitRunners", "Fulcrum Secret Technologies"]);
if (augmentationExists(AugmentationNames.ArtificialBioNeuralNetwork)) {
ArtificialBioNeuralNetwork.owned = Augmentations[AugmentationNames.ArtificialBioNeuralNetwork].owned;
@ -453,7 +453,7 @@ initAugmentations = function() {
ArtificialSynapticPotentiation.setInfo("The body is injected with a chemical that artificially induces synaptic potentiation, " +
"otherwise known as the strengthening of synapses. This results in a enhanced cognitive abilities.<br><br>" +
"This augmentation: <br>" +
"Increases the player's hacking speed by 3% <br> " +
"Increases the player's hacking speed by 2% <br> " +
"Increases the player's hacking chance by 5%<br>" +
"Increases the player's hacking experience gain rate by 5%");
ArtificialSynapticPotentiation.addToFactions(["The Black Hand", "NiteSec"]);
@ -471,8 +471,8 @@ initAugmentations = function() {
"counterparts, leading to greater processing speeds and better brain function.<br><br>" +
"This augmentation:<br>" +
"Increases the player's hacking speed by 3%<br>" +
"Increases the player's hacking skill by 10%<br>" +
"Increases the player's hacking experience gain rate by 20%");
"Increases the player's hacking skill by 8%<br>" +
"Increases the player's hacking experience gain rate by 10%");
EnhancedMyelinSheathing.addToFactions(["Fulcrum Secret Technologies", "BitRunners", "The Black Hand"]);
if (augmentationExists(AugmentationNames.EnhancedMyelinSheathing)) {
EnhancedMyelinSheathing.owned = Augmentations[AugmentationNames.EnhancedMyelinSheathing].owned;
@ -496,7 +496,7 @@ initAugmentations = function() {
NeuralRetentionEnhancement.setRequirements(8000, 50000000);
NeuralRetentionEnhancement.setInfo("Chemical injections are used to permanently alter and strengthen the brain's neuronal " +
"circuits, strengthening its ability to retain information.<br><br>" +
"This augmentation increases the player's hacking experience gain rate by 40%.");
"This augmentation increases the player's hacking experience gain rate by 25%.");
NeuralRetentionEnhancement.addToFactions(["NiteSec"]);
if (augmentationExists(AugmentationNames.NeuralRetentionEnhancement)) {
NeuralRetentionEnhancement.owned = Augmentations[AugmentationNames.NeuralRetentionEnhancement].owned;
@ -509,7 +509,7 @@ initAugmentations = function() {
DataJack.setInfo("A brain implant that provides an interface for direct, wireless communication between a computer's main " +
"memory and the mind. This implant allows the user to not only access a computer's memory, but also alter " +
"and delete it.<br><br>" +
"This augmentation increases the amount of money the player gains from hacking by 30%");
"This augmentation increases the amount of money the player gains from hacking by 25%");
DataJack.addToFactions(["BitRunners", "The Black Hand", "NiteSec", "Chongqing", "New Tokyo"]);
if (augmentationExists(AugmentationNames.DataJack)) {
DataJack.owned = Augmentations[AugmentationNames.DataJack].owned;
@ -524,7 +524,7 @@ initAugmentations = function() {
"processing all of the traffic on that network. By itself, the Embedded Netburner Module does " +
"not do much, but a variety of very powerful upgrades can be installed that allow you to fully " +
"control the traffic on a network.<br><br>" +
"This augmentation increases the player's hacking skill by 10%");
"This augmentation increases the player's hacking skill by 8%");
ENM.addToFactions(["BitRunners", "The Black Hand", "NiteSec", "ECorp", "MegaCorp",
"Fulcrum Secret Technologies", "NWO", "Blade Industries"]);
if (augmentationExists(AugmentationNames.ENM)) {
@ -541,8 +541,8 @@ initAugmentations = function() {
"Increases the player's hacking speed by 3%<br>" +
"Increases the amount of money the player gains from hacking by 10%<br>" +
"Increases the player's chance of successfully performing a hack by 3%<br>" +
"Increases the player's hacking experience gain rate by 10%<br>" +
"Increases the player's hacking skill by 10%");
"Increases the player's hacking experience gain rate by 7%<br>" +
"Increases the player's hacking skill by 7%");
ENMCore.addToFactions(["BitRunners", "The Black Hand", "ECorp", "MegaCorp",
"Fulcrum Secret Technologies", "NWO", "Blade Industries"]);
if (augmentationExists(AugmentationNames.ENMCore)) {
@ -559,10 +559,10 @@ initAugmentations = function() {
"packets.<br><br>" +
"This augmentation: <br>" +
"Increases the player's hacking speed by 5%<br>" +
"Increases the amount of money the player gains from hacking by 50%<br>" +
"Increases the amount of money the player gains from hacking by 30%<br>" +
"Increases the player's chance of successfully performing a hack by 5%<br>" +
"Increases the player's hacking experience gain rate by 50%<br>" +
"Increases the player's hacking skill by 15%");
"Increases the player's hacking experience gain rate by 15%<br>" +
"Increases the player's hacking skill by 8%");
ENMCoreV2.addToFactions(["BitRunners", "ECorp", "MegaCorp", "Fulcrum Secret Technologies", "NWO",
"Blade Industries", "OmniTek Incorporated", "KuaiGong International"]);
if (augmentationExists(AugmentationNames.ENMCoreV2)) {
@ -578,10 +578,10 @@ initAugmentations = function() {
"any device on a network.<br><br>" +
"This augmentation:<br>" +
"Increases the player's hacking speed by 5%<br>" +
"Increases the amount of money the player gains from hacking by 50%<br>" +
"Increases the amount of money the player gains from hacking by 40%<br>" +
"Increases the player's chance of successfully performing a hack by 10%<br>" +
"Increases the player's hacking experience gain rate by 100%<br>" +
"Increases the player's hacking skill by 20%");
"Increases the player's hacking experience gain rate by 25%<br>" +
"Increases the player's hacking skill by 10%");
ENMCoreV3.addToFactions(["ECorp", "MegaCorp", "Fulcrum Secret Technologies", "NWO",
"Daedalus", "The Covenant", "Illuminati"]);
if (augmentationExists(AugmentationNames.ENMCoreV3)) {
@ -594,7 +594,7 @@ initAugmentations = function() {
ENMAnalyzeEngine.setRequirements(250000, 1200000000);
ENMAnalyzeEngine.setInfo("Installs the Analyze Engine for the Embedded Netburner Module, which is a CPU cluster " +
"that vastly outperforms the Netburner Module's native single-core processor.<br><br>" +
"This augmentation increases the player's hacking speed by 12%.");
"This augmentation increases the player's hacking speed by 10%.");
ENMAnalyzeEngine.addToFactions(["ECorp", "MegaCorp", "Fulcrum Secret Technologies", "NWO",
"Daedalus", "The Covenant", "Illuminati"]);
if (augmentationExists(AugmentationNames.ENMAnalyzeEngine)) {
@ -609,7 +609,7 @@ initAugmentations = function() {
"Embedded Netburner Module. This allows the Module to send and receive data " +
"directly to and from the main memory of devices on a network.<br><br>" +
"This augmentation: <br>" +
"Increases the amount of money the player gains from hacking by 50%<br>" +
"Increases the amount of money the player gains from hacking by 40%<br>" +
"Increases the player's chance of successfully performing a hack by 20%");
ENMDMA.addToFactions(["ECorp", "MegaCorp", "Fulcrum Secret Technologies", "NWO",
"Daedalus", "The Covenant", "Illuminati"]);
@ -625,8 +625,8 @@ initAugmentations = function() {
"in order to improve cognitive functions<br><br>" +
"This augmentation:<br>" +
"Increases the player's hacking speed by 2%<br>" +
"Increases the player's chance of successfully performing a hack by 15%<br>" +
"Increases the player's hacking experience gain rate by 30%");
"Increases the player's chance of successfully performing a hack by 10%<br>" +
"Increases the player's hacking experience gain rate by 12%");
Neuralstimulator.addToFactions(["The Black Hand", "Chongqing", "Sector-12", "New Tokyo", "Aevum",
"Ishima", "Volhaven", "Bachman & Associates", "Clarke Incorporated",
"Four Sigma"]);
@ -641,8 +641,8 @@ initAugmentations = function() {
NeuralAccelerator.setInfo("A microprocessor that accelerates the processing " +
"speed of biological neural networks. This is a cranial implant that is embedded inside the brain. <br><br>" +
"This augmentation: <br>" +
"Increases the player's hacking skill by 20%<br>" +
"Increases the player's hacking experience gain rate by 20%<br>" +
"Increases the player's hacking skill by 10%<br>" +
"Increases the player's hacking experience gain rate by 15%<br>" +
"Increases the amount of money the player gains from hacking by 20%");
NeuralAccelerator.addToFactions(["BitRunners"]);
if (augmentationExists(AugmentationNames.NeuralAccelerator)) {
@ -659,7 +659,7 @@ initAugmentations = function() {
"so that the brain doesn't have to. <br><br>" +
"This augmentation: <br>" +
"Increases the player's hacking speed by 1%<br>" +
"Increases the player's hacking skill by 15%");
"Increases the player's hacking skill by 5%");
CranialSignalProcessorsG1.addToFactions(["CyberSec"]);
if (augmentationExists(AugmentationNames.CranialSignalProcessorsG1)) {
CranialSignalProcessorsG1.owned = Augmentations[AugmentationNames.CranialSignalProcessorsG1].owned;
@ -676,7 +676,7 @@ initAugmentations = function() {
"This augmentation: <br>" +
"Increases the player's hacking speed by 2%<br>" +
"Increases the player's chance of successfully performing a hack by 5%<br>" +
"Increases the player's hacking skill by 15%");
"Increases the player's hacking skill by 7%");
CranialSignalProcessorsG2.addToFactions(["NiteSec"]);
if (augmentationExists(AugmentationNames.CranialSignalProcessorsG2)) {
CranialSignalProcessorsG2.owned = Augmentations[AugmentationNames.CranialSignalProcessorsG2].owned;
@ -692,8 +692,8 @@ initAugmentations = function() {
"so that the brain doesn't have to. <br><br>" +
"This augmentation:<br>" +
"Increases the player's hacking speed by 2%<br>" +
"Increases the amount of money the player gains from hacking by 20%<br>" +
"Increases the player's hacking skill by 15%");
"Increases the amount of money the player gains from hacking by 15%<br>" +
"Increases the player's hacking skill by 9%");
CranialSignalProcessorsG3.addToFactions(["NiteSec", "The Black Hand"]);
if (augmentationExists(AugmentationNames.CranialSignalProcessorsG3)) {
CranialSignalProcessorsG3.owned = Augmentations[AugmentationNames.CranialSignalProcessorsG3].owned;
@ -709,7 +709,7 @@ initAugmentations = function() {
"so that the brain doesn't have to. <br><br>" +
"This augmentation: <br>" +
"Increases the player's hacking speed by 2%<br>" +
"Increases the amount of money the player gains from hacking by 25%<br>" +
"Increases the amount of money the player gains from hacking by 20%<br>" +
"Increases the amount of money the player can inject into servers using grow() by 25%");
CranialSignalProcessorsG4.addToFactions(["The Black Hand"]);
if (augmentationExists(AugmentationNames.CranialSignalProcessorsG4)) {
@ -741,8 +741,8 @@ initAugmentations = function() {
"by decreasing the neuron gap junction. Then, the body is genetically modified " +
"to enhance the production and capabilities of its neural stem cells. <br><br>" +
"This augmentation: <br>" +
"Increases the player's hacking skill by 25%<br>" +
"Increases the player's hacking experience gain rate by 40%<br>"+
"Increases the player's hacking skill by 15%<br>" +
"Increases the player's hacking experience gain rate by 10%<br>"+
"Increases the player's hacking speed by 3%");
NeuronalDensification.addToFactions(["Clarke Incorporated"]);
if (augmentationExists(AugmentationNames.NeuronalDensification)) {
@ -805,7 +805,7 @@ initAugmentations = function() {
"it using the brain's electrochemical signals.<br><br>" +
"This augmentation:<br>" +
"Increases the amount of reputation the player gains when working for a company by 30%<br>" +
"Increases the player's hacking skill by 10%");
"Increases the player's hacking skill by 8%");
PCDNI.addToFactions(["Four Sigma", "OmniTek Incorporated", "ECorp", "Blade Industries"]);
if (augmentationExists(AugmentationNames.PCDNI)) {
PCDNI.owned = Augmentations[AugmentationNames.PCDNI].owned;
@ -820,7 +820,7 @@ initAugmentations = function() {
"to the connected computer.<br><br>" +
"This augmentation:<br>" +
"Increases the amount of reputation the player gains when working for a company by 75%<br>" +
"Increases the player's hacking skill by 20%");
"Increases the player's hacking skill by 10%");
PCDNIOptimizer.addToFactions(["Fulcrum Secret Technologies", "ECorp", "Blade Industries"]);
if (augmentationExists(AugmentationNames.PCDNIOptimizer)) {
PCDNIOptimizer.owned = Augmentations[AugmentationNames.PCDNIOptimizer].owned;
@ -972,7 +972,7 @@ initAugmentations = function() {
Neurotrainer2.setInfo("A decentralized cranial implant that improves the brain's ability to learn. This " +
"is a more powerful version of the Neurotrainer I augmentation, but it does not " +
"require Neurotrainer I to be installed as a prerequisite.<br><br>" +
"This augmentation increases the player's experience gain rate for all stats by 20%");
"This augmentation increases the player's experience gain rate for all stats by 15%");
Neurotrainer2.addToFactions(["BitRunners", "NiteSec"]);
if (augmentationExists(AugmentationNames.Neurotrainer2)) {
Neurotrainer2.owned = Augmentations[AugmentationNames.Neurotrainer2].owned;
@ -985,7 +985,7 @@ initAugmentations = function() {
Neurotrainer3.setInfo("A decentralized cranial implant that improves the brain's ability to learn. This " +
"is a more powerful version of the Neurotrainer I and Neurotrainer II augmentation, " +
"but it does not require either of them to be installed as a prerequisite.<br><br>" +
"This augmentation increases the player's experience gain rate for all stats by 30%");
"This augmentation increases the player's experience gain rate for all stats by 20%");
Neurotrainer3.addToFactions(["NWO", "Four Sigma"]);
if (augmentationExists(AugmentationNames.Neurotrainer3)) {
Neurotrainer3.owned = Augmentations[AugmentationNames.Neurotrainer3].owned;
@ -998,7 +998,7 @@ initAugmentations = function() {
"Embedded circuitry within the implant provides the ability to detect heat and movement " +
"through solid objects such as wells, thus providing 'x-ray vision'-like capabilities.<br><br>" +
"This augmentation: <br>" +
"Increases the player's dexterity by 50%<br>" +
"Increases the player's dexterity by 40%<br>" +
"Increases the player's hacking speed by 3%<br>" +
"Increases the amount of money the player gains from hacking by 10%");
Hypersight.setRequirements(60000, 550000000);
@ -1061,7 +1061,7 @@ initAugmentations = function() {
"are capable of capturing wasted energy (in the form of heat) " +
"and converting it back into usable power. <br><br>" +
"This augmentation: <br>" +
"Increases all of the player's stats by 10%<br>" +
"Increases all of the player's stats by 5%<br>" +
"Increases the player's experience gain rate for all stats by 10%");
PowerRecirculator.setRequirements(10000, 33000000);
PowerRecirculator.addToFactions(["Tetrads", "The Dark Army", "The Syndicate", "NWO"]);
@ -1104,7 +1104,7 @@ initAugmentations = function() {
"2056.<br><br>" +
"This augmentation: <br>" +
"Increases all of the player's combat stats by 75%<br>" +
"Increases the player's hacking skill by 25%");
"Increases the player's hacking skill by 15%");
SPTN97.setRequirements(500000, 950000000);
SPTN97.addToFactions(["The Covenant"]);
if (augmentationExists(AugmentationNames.SPTN97)) {
@ -1133,8 +1133,8 @@ initAugmentations = function() {
"fusion power through nuclear fusion, providing limitless amount of clean " +
"energy for the body. <br><br>" +
"This augmentation:<br>" +
"Increases all of the player's combat stats by 40%<br>" +
"Increases all of the player's combat stat experience gain rate by 40%");
"Increases all of the player's combat stats by 35%<br>" +
"Increases all of the player's combat stat experience gain rate by 35%");
CordiARCReactor.setRequirements(450000, 975000000);
CordiARCReactor.addToFactions(["MegaCorp"]);
if (augmentationExists(AugmentationNames.CordiARCReactor)) {
@ -1167,7 +1167,7 @@ initAugmentations = function() {
"and integumentary system. The drug permanently modifies the DNA of the " +
"body's skin and bone cells, granting them the ability to repair " +
"and restructure themselves. <br><br>" +
"This augmentation increases the player's strength and defense by 75%");
"This augmentation increases the player's strength and defense by 55%");
Neotra.setRequirements(225000, 550000000);
Neotra.addToFactions(["Blade Industries"]);
if (augmentationExists(AugmentationNames.Neotra)) {
@ -1182,8 +1182,8 @@ initAugmentations = function() {
"body. These nanobots induce physiological change and significantly " +
"improve the body's functionining in all aspects. <br><br>" +
"This augmentation: <br>" +
"Increases all of the player's stats by 25%<br>" +
"Increases the player's experience gain rate for all stats by 20%");
"Increases all of the player's stats by 20%<br>" +
"Increases the player's experience gain rate for all stats by 15%");
Xanipher.setRequirements(350000, 800000000);
Xanipher.addToFactions(["NWO"]);
if (augmentationExists(AugmentationNames.Xanipher)) {
@ -1212,8 +1212,8 @@ initAugmentations = function() {
"into your brain, enhancing your programming and " +
"hacking abilities. <br><br>" +
"This augmentation:<br>" +
"Increases the player's hacking skill by 30%<br>" +
"Increases the player's hacking experience gain rate by 30%");
"Increases the player's hacking skill by 20%<br>" +
"Increases the player's hacking experience gain rate by 25%");
OmniTekInfoLoad.setRequirements(250000, 550000000)
OmniTekInfoLoad.addToFactions(["OmniTek Incorporated"]);
if (augmentationExists(AugmentationNames.OmniTekInfoLoad)) {
@ -1231,7 +1231,7 @@ initAugmentations = function() {
"to the body using a skin graft. The result is photosynthetic " +
"skin cells, allowing users to generate their own energy " +
"and nutrition using solar power. <br><br>" +
"This augmentation increases the player's strength, defense, and agility by 50%");
"This augmentation increases the player's strength, defense, and agility by 40%");
PhotosyntheticCells.setRequirements(225000, 525000000);
PhotosyntheticCells.addToFactions(["KuaiGong International"]);
if (augmentationExists(AugmentationNames.PhotosyntheticCells)) {
@ -1246,8 +1246,8 @@ initAugmentations = function() {
"mind and BitRunners' data servers, which reportedly contain " +
"the largest database of hacking tools and information in the world. <br><br>" +
"This augmentation: <br>" +
"Increases the player's hacking skill by 20%<br>" +
"Increases the player's hacking experience gain rate by 25%<br>" +
"Increases the player's hacking skill by 15%<br>" +
"Increases the player's hacking experience gain rate by 20%<br>" +
"Increases the player's chance of successfully performing a hack by 10%<br>" +
"Increases the player's hacking speed by 5%<br>" +
"Lets the player start with the FTPCrack.exe and relaySMTP.exe programs after a reset");
@ -1266,7 +1266,7 @@ initAugmentations = function() {
"with hardware and firmware that lets the user connect to, access and hack " +
"devices and machines just by touching them. <br><br>" +
"This augmentation: <br>" +
"Increases the player's strength and dexterity by 20%<br>" +
"Increases the player's strength and dexterity by 15%<br>" +
"Increases the player's hacking skill by 10%<br>" +
"Increases the player's hacking speed by 2%<br>" +
"Increases the amount of money the player gains from hacking by 10%");
@ -1284,8 +1284,8 @@ initAugmentations = function() {
"The CRTX42-AA is an artificially-synthesized gene that targets the visual and prefrontal " +
"cortex and improves cognitive abilities. <br><br>" +
"This augmentation: <br>" +
"Improves the player's hacking skill by 10%<br>" +
"Improves the player's hacking experience gain rate by 20%");
"Improves the player's hacking skill by 8%<br>" +
"Improves the player's hacking experience gain rate by 15%");
CRTX42AA.setRequirements(18000, 45000000);
CRTX42AA.addToFactions(["NiteSec"]);
if (augmentationExists(AugmentationNames.CRTX42AA)) {
@ -1299,7 +1299,7 @@ initAugmentations = function() {
Neuregen.setInfo("A drug that genetically modifies the neurons in the brain. " +
"The result is that these neurons never die and continuously " +
"regenerate and strengthen themselves. <br><br>" +
"This augmentation increases the player's hacking experience gain rate by 75%");
"This augmentation increases the player's hacking experience gain rate by 40%");
Neuregen.setRequirements(15000, 75000000);
Neuregen.addToFactions(["Chongqing"]);
if (augmentationExists(AugmentationNames.Neuregen)) {
@ -1380,9 +1380,9 @@ initAugmentations = function() {
"the retractable blades with an advanced graphene material " +
"to make them much stronger and lighter. <br><br>" +
"This augmentation:<br>" +
"Increases the player's strength and defense by 50%<br>" +
"Increases the player's strength and defense by 40%<br>" +
"Increases the player's crime success rate by 10%<br>" +
"Increases the amount of money the player gains from crimes by 25%");
"Increases the amount of money the player gains from crimes by 30%");
GrapheneBrachiBlades.setRequirements(90000, 500000000);
GrapheneBrachiBlades.addToFactions(["Speakers for the Dead"]);
if (augmentationExists(AugmentationNames.GrapheneBrachiBlades)) {
@ -1396,7 +1396,7 @@ initAugmentations = function() {
GrapheneBionicArms.setInfo("An upgrade to the Bionic Arms augmentation. It infuses the " +
"prosthetic arms with an advanced graphene material " +
"to make them much stronger and lighter. <br><br>" +
"This augmentation increases the player's strength and dexterity by 125%");
"This augmentation increases the player's strength and dexterity by 85%");
GrapheneBionicArms.setRequirements(200000, 750000000);
GrapheneBionicArms.addToFactions(["The Dark Army"]);
if (augmentationExists(AugmentationNames.GrapheneBionicArms)) {
@ -1409,9 +1409,9 @@ initAugmentations = function() {
var BrachiBlades = new Augmentation(AugmentationNames.BrachiBlades);
BrachiBlades.setInfo("A set of retractable plasteel blades are implanted in the arm, underneath the skin. " +
"<br><br>This augmentation: <br>" +
"Increases the player's strength and defense by 20%<br>" +
"Increases the player's strength and defense by 15%<br>" +
"Increases the player's crime success rate by 10%<br>" +
"Increases the amount of money the player gains from crimes by 10%");
"Increases the amount of money the player gains from crimes by 15%");
BrachiBlades.setRequirements(5000, 18000000);
BrachiBlades.addToFactions(["The Syndicate"]);
if (augmentationExists(AugmentationNames.BrachiBlades)) {
@ -1424,7 +1424,7 @@ initAugmentations = function() {
var BionicArms = new Augmentation(AugmentationNames.BionicArms);
BionicArms.setInfo("Cybernetic arms created from plasteel and carbon fibers that completely replace " +
"the user's organic arms. <br><br>" +
"This augmentation increases the user's strength and dexterity by 50%");
"This augmentation increases the user's strength and dexterity by 30%");
BionicArms.setRequirements(25000, 55000000);
BionicArms.addToFactions(["Tetrads"]);
if (augmentationExists(AugmentationNames.BionicArms)) {
@ -1459,66 +1459,66 @@ applyAugmentation = function(aug, reapply=false) {
switch(aug.name) {
//Combat stat augmentations
case AugmentationNames.Targeting1:
Player.dexterity_mult *= 1.2;
Player.dexterity_mult *= 1.15;
break;
case AugmentationNames.Targeting2:
Player.dexterity_mult *= 1.4;
Player.dexterity_mult *= 1.25;
break;
case AugmentationNames.Targeting3:
Player.dexterity_mult *= 1.6;
Player.dexterity_mult *= 1.40;
break;
case AugmentationNames.SyntheticHeart: //High level
Player.agility_mult *= 2.0;
Player.strength_mult *= 2.0;
Player.agility_mult *= 1.5;
Player.strength_mult *= 1.5;
break;
case AugmentationNames.SynfibrilMuscle: //Medium-high level
Player.strength_mult *= 1.8;
Player.defense_mult *= 1.8;
Player.strength_mult *= 1.35;
Player.defense_mult *= 1.35;
break;
case AugmentationNames.CombatRib1:
Player.strength_mult *= 1.1;
Player.defense_mult *= 1.1;
break;
case AugmentationNames.CombatRib2:
Player.strength_mult *= 1.15;
Player.defense_mult *= 1.15;
break;
case AugmentationNames.CombatRib2:
Player.strength_mult *= 1.25;
Player.defense_mult *= 1.25;
break;
case AugmentationNames.CombatRib3:
Player.strength_mult *= 1.40;
Player.defense_mult *= 1.40;
Player.strength_mult *= 1.20;
Player.defense_mult *= 1.20;
break;
case AugmentationNames.NanofiberWeave: //Med level
Player.strength_mult *= 1.4;
Player.defense_mult *= 1.4;
break;
case AugmentationNames.SubdermalArmor: //High level
Player.defense_mult *= 2.5;
break;
case AugmentationNames.WiredReflexes: //Low level
Player.agility_mult *= 1.1;
Player.dexterity_mult *= 1.1;
break;
case AugmentationNames.GrapheneBoneLacings: //High level
Player.strength_mult *= 2.25;
Player.defense_mult *= 2.25;
break;
case AugmentationNames.BionicSpine: //Med level
Player.strength_mult *= 1.25;
Player.defense_mult *= 1.25;
Player.agility_mult *= 1.25;
Player.dexterity_mult *= 1.25;
break;
case AugmentationNames.SubdermalArmor: //High level
Player.defense_mult *= 2.25;
break;
case AugmentationNames.WiredReflexes: //Low level
Player.agility_mult *= 1.05;
Player.dexterity_mult *= 1.05;
break;
case AugmentationNames.GrapheneBoneLacings: //High level
Player.strength_mult *= 1.75;
Player.defense_mult *= 1.75;
break;
case AugmentationNames.BionicSpine: //Med level
Player.strength_mult *= 1.18;
Player.defense_mult *= 1.18;
Player.agility_mult *= 1.18;
Player.dexterity_mult *= 1.18;
break;
case AugmentationNames.GrapheneBionicSpine: //High level
Player.strength_mult *= 2;
Player.defense_mult *= 2;
Player.agility_mult *= 2;
Player.dexterity_mult *= 2;
Player.strength_mult *= 1.65;
Player.defense_mult *= 1.65;
Player.agility_mult *= 1.65;
Player.dexterity_mult *= 1.65;
break;
case AugmentationNames.BionicLegs: //Med level
Player.agility_mult *= 1.75;
Player.agility_mult *= 1.6;
break;
case AugmentationNames.GrapheneBionicLegs: //High level
Player.agility_mult *= 3.0;
Player.agility_mult *= 2.75;
break;
//Labor stats augmentations
@ -1536,90 +1536,90 @@ applyAugmentation = function(aug, reapply=false) {
//Hacking augmentations
case AugmentationNames.BitWire:
Player.hacking_mult *= 1.1;
Player.hacking_mult *= 1.05;
break;
case AugmentationNames.ArtificialBioNeuralNetwork: //Med level
Player.hacking_speed_mult *= .97;
Player.hacking_speed_mult *= 1.03;
Player.hacking_money_mult *= 1.15;
Player.hacking_mult *= 1.15;
Player.hacking_mult *= 1.12;
break;
case AugmentationNames.ArtificialSynapticPotentiation: //Med level
Player.hacking_speed_mult *= .97;
Player.hacking_speed_mult *= 1.02;
Player.hacking_chance_mult *= 1.05;
Player.hacking_exp_mult *= 1.05;
break;
case AugmentationNames.EnhancedMyelinSheathing: //Med level
Player.hacking_speed_mult *= .97;
Player.hacking_exp_mult *= 1.2;
Player.hacking_mult *= 1.1;
Player.hacking_speed_mult *= 1.03;
Player.hacking_exp_mult *= 1.1;
Player.hacking_mult *= 1.08;
break;
case AugmentationNames.SynapticEnhancement: //Low Level
Player.hacking_speed_mult *= .97;
Player.hacking_speed_mult *= 1.03;
break;
case AugmentationNames.NeuralRetentionEnhancement: //Med level
Player.hacking_exp_mult *= 1.4;
Player.hacking_exp_mult *= 1.25;
break;
case AugmentationNames.DataJack: //Med low level
Player.hacking_money_mult *= 1.3;
Player.hacking_money_mult *= 1.25;
break;
case AugmentationNames.ENM: //Medium level
Player.hacking_mult *= 1.1;
Player.hacking_mult *= 1.08;
break;
case AugmentationNames.ENMCore: //Medium level
Player.hacking_speed_mult *= .97;
Player.hacking_speed_mult *= 1.03;
Player.hacking_money_mult *= 1.1;
Player.hacking_chance_mult *= 1.03;
Player.hacking_exp_mult *= 1.1;
Player.hacking_mult *= 1.1;
Player.hacking_exp_mult *= 1.07;
Player.hacking_mult *= 1.07;
break;
case AugmentationNames.ENMCoreV2: //Medium high level
Player.hacking_speed_mult *= .95;
Player.hacking_money_mult *= 1.5;
Player.hacking_speed_mult *= 1.05;
Player.hacking_money_mult *= 1.3;
Player.hacking_chance_mult *= 1.05;
Player.hacking_exp_mult *= 1.5;
Player.hacking_mult *= 1.15;
Player.hacking_exp_mult *= 1.15;
Player.hacking_mult *= 1.08;
break;
case AugmentationNames.ENMCoreV3: //High level
Player.hacking_speed_mult *= .95;
Player.hacking_money_mult *= 1.5;
Player.hacking_speed_mult *= 1.05;
Player.hacking_money_mult *= 1.4;
Player.hacking_chance_mult *= 1.1;
Player.hacking_exp_mult *= 2.0;
Player.hacking_mult *= 1.2;
Player.hacking_exp_mult *= 1.25;
Player.hacking_mult *= 1.1;
break;
case AugmentationNames.ENMAnalyzeEngine: //High level
Player.hacking_speed_mult *= 0.88;
Player.hacking_speed_mult *= 1.1;
break;
case AugmentationNames.ENMDMA: //High level
Player.hacking_money_mult *= 1.5;
Player.hacking_money_mult *= 1.4;
Player.hacking_chance_mult *= 1.2;
break;
case AugmentationNames.Neuralstimulator: //Medium Level
Player.hacking_speed_mult *= .98;
Player.hacking_chance_mult *= 1.15;
Player.hacking_exp_mult *= 1.3;
Player.hacking_speed_mult *= 1.02;
Player.hacking_chance_mult *= 1.1;
Player.hacking_exp_mult *= 1.12;
break;
case AugmentationNames.NeuralAccelerator:
Player.hacking_mult *= 1.2;
Player.hacking_exp_mult *= 1.2;
Player.hacking_mult *= 1.1;
Player.hacking_exp_mult *= 1.15;
Player.hacking_money_mult *= 1.2;
break;
case AugmentationNames.CranialSignalProcessorsG1:
Player.hacking_speed_mult *= 0.99;
Player.hacking_mult *= 1.15;
Player.hacking_speed_mult *= 1.01;
Player.hacking_mult *= 1.05;
break;
case AugmentationNames.CranialSignalProcessorsG2:
Player.hacking_speed_mult *= 0.98;
Player.hacking_speed_mult *= 1.02;
Player.hacking_chance_mult *= 1.05;
Player.hacking_mult *= 1.15;
Player.hacking_mult *= 1.07;
break;
case AugmentationNames.CranialSignalProcessorsG3:
Player.hacking_speed_mult *= 0.98;
Player.hacking_money_mult *= 1.2;
Player.hacking_mult *= 1.15;
Player.hacking_speed_mult *= 1.02;
Player.hacking_money_mult *= 1.15;
Player.hacking_mult *= 1.09;
break;
case AugmentationNames.CranialSignalProcessorsG4:
Player.hacking_speed_mult *= 0.98;
Player.hacking_money_mult *= 1.25;
Player.hacking_speed_mult *= 1.02;
Player.hacking_money_mult *= 1.2;
Player.hacking_grow_mult *= 1.25;
break;
case AugmentationNames.CranialSignalProcessorsG5:
@ -1628,9 +1628,9 @@ applyAugmentation = function(aug, reapply=false) {
Player.hacking_grow_mult *= 1.75;
break;
case AugmentationNames.NeuronalDensification:
Player.hacking_mult *= 1.25;
Player.hacking_exp_mult *= 1.40;
Player.hacking_speed_mult *= 0.97;
Player.hacking_mult *= 1.15;
Player.hacking_exp_mult *= 1.1;
Player.hacking_speed_mult *= 1.03;
break;
//Work augmentations
@ -1653,16 +1653,16 @@ applyAugmentation = function(aug, reapply=false) {
break;
case AugmentationNames.PCDNI: //Med level
Player.company_rep_mult *= 1.3;
Player.hacking_mult *= 1.1;
Player.hacking_mult *= 1.08;
break;
case AugmentationNames.PCDNIOptimizer: //High level
Player.company_rep_mult *= 1.75;
Player.hacking_mult *= 1.20;
Player.hacking_mult *= 1.1;
break;
case AugmentationNames.PCDNINeuralNetwork: //High level
Player.company_rep_mult *= 2;
Player.hacking_mult *= 1.1;
Player.hacking_speed_mult *= .95;
Player.hacking_speed_mult *= 1.05;
break;
case AugmentationNames.ADRPheromone1:
Player.company_rep_mult *= 1.1;
@ -1692,7 +1692,7 @@ applyAugmentation = function(aug, reapply=false) {
//Misc augmentations
case AugmentationNames.NeuroFluxGovernor:
Player.hacking_chance_mult *= 1.01;
Player.hacking_speed_mult *= 0.99;
Player.hacking_speed_mult *= 1.01;
Player.hacking_money_mult *= 1.01;
Player.hacking_grow_mult *= 1.01;
Player.hacking_mult *= 1.01;
@ -1737,6 +1737,14 @@ applyAugmentation = function(aug, reapply=false) {
Player.charisma_exp_mult *= 1.1;
break;
case AugmentationNames.Neurotrainer2: //Medium level
Player.hacking_exp_mult *= 1.15;
Player.strength_exp_mult *= 1.15;
Player.defense_exp_mult *= 1.15;
Player.dexterity_exp_mult *= 1.15;
Player.agility_exp_mult *= 1.15;
Player.charisma_exp_mult *= 1.15;
break;
case AugmentationNames.Neurotrainer3: //High Level
Player.hacking_exp_mult *= 1.2;
Player.strength_exp_mult *= 1.2;
Player.defense_exp_mult *= 1.2;
@ -1744,17 +1752,9 @@ applyAugmentation = function(aug, reapply=false) {
Player.agility_exp_mult *= 1.2;
Player.charisma_exp_mult *= 1.2;
break;
case AugmentationNames.Neurotrainer3: //High Level
Player.hacking_exp_mult *= 1.3;
Player.strength_exp_mult *= 1.3;
Player.defense_exp_mult *= 1.3;
Player.dexterity_exp_mult *= 1.3;
Player.agility_exp_mult *= 1.3;
Player.charisma_exp_mult *= 1.3;
break;
case AugmentationNames.Hypersight: //Medium high level
Player.dexterity_mult *= 1.5;
Player.hacking_speed_mult *= .97;
Player.dexterity_mult *= 1.4;
Player.hacking_speed_mult *= 1.03;
Player.hacking_money_mult *= 1.1;
break;
case AugmentationNames.LuminCloaking1:
@ -1767,10 +1767,10 @@ applyAugmentation = function(aug, reapply=false) {
Player.crime_money_mult *= 1.25;
break;
case AugmentationNames.HemoRecirculator:
Player.strength_mult *= 1.15;
Player.defense_mult *= 1.15;
Player.agility_mult *= 1.15;
Player.dexterity_mult *= 1.15;
Player.strength_mult *= 1.1;
Player.defense_mult *= 1.1;
Player.agility_mult *= 1.1;
Player.dexterity_mult *= 1.1;
break;
case AugmentationNames.SmartSonar:
Player.dexterity_mult *= 1.1;
@ -1778,12 +1778,12 @@ applyAugmentation = function(aug, reapply=false) {
Player.crime_money_mult *= 1.25;
break;
case AugmentationNames.PowerRecirculator:
Player.hacking_mult *= 1.1;
Player.strength_mult *= 1.1;
Player.defense_mult *= 1.1;
Player.dexterity_mult *= 1.1;
Player.agility_mult *= 1.1;
Player.charisma_mult *= 1.1;
Player.hacking_mult *= 1.05;
Player.strength_mult *= 1.05;
Player.defense_mult *= 1.05;
Player.dexterity_mult *= 1.05;
Player.agility_mult *= 1.05;
Player.charisma_mult *= 1.05;
Player.hacking_exp_mult *= 1.1;
Player.strength_exp_mult *= 1.1;
Player.defense_exp_mult *= 1.1;
@ -1793,7 +1793,7 @@ applyAugmentation = function(aug, reapply=false) {
break;
//Unique augmentations (for factions)
case AugmentationNames.QLink:
Player.hacking_speed_mult *= 0.9;
Player.hacking_speed_mult *= 1.1;
Player.hacking_chance_mult *= 1.3;
Player.hacking_money_mult *= 2;
break;
@ -1802,20 +1802,20 @@ applyAugmentation = function(aug, reapply=false) {
Player.defense_mult *= 1.75;
Player.dexterity_mult *= 1.75;
Player.agility_mult *= 1.75;
Player.hacking_mult *= 1.25;
Player.hacking_mult *= 1.15;
break;
case AugmentationNames.HiveMind:
Player.hacking_grow_mult *= 3;
break;
case AugmentationNames.CordiARCReactor:
Player.strength_mult *= 1.4;
Player.defense_mult *= 1.4;
Player.dexterity_mult *= 1.4;
Player.agility_mult *= 1.4;
Player.strength_exp_mult *= 1.4;
Player.defense_exp_mult *= 1.4;
Player.dexterity_exp_mult *= 1.4;
Player.agility_exp_mult *= 1.4;
Player.strength_mult *= 1.35;
Player.defense_mult *= 1.35;
Player.dexterity_mult *= 1.35;
Player.agility_mult *= 1.35;
Player.strength_exp_mult *= 1.35;
Player.defense_exp_mult *= 1.35;
Player.dexterity_exp_mult *= 1.35;
Player.agility_exp_mult *= 1.35;
break;
case AugmentationNames.SmartJaw:
Player.charisma_mult *= 1.5;
@ -1824,22 +1824,22 @@ applyAugmentation = function(aug, reapply=false) {
Player.faction_rep_mult *= 1.25;
break;
case AugmentationNames.Neotra:
Player.strength_mult *= 1.75;
Player.defense_mult *= 1.75;
Player.strength_mult *= 1.55;
Player.defense_mult *= 1.55;
break;
case AugmentationNames.Xanipher:
Player.hacking_mult *= 1.25;
Player.strength_mult *= 1.25;
Player.defense_mult *= 1.25;
Player.dexterity_mult *= 1.25;
Player.agility_mult *= 1.25;
Player.charisma_mult *= 1.25;
Player.hacking_exp_mult *= 1.2;
Player.strength_exp_mult *= 1.2;
Player.defense_exp_mult *= 1.2;
Player.dexterity_exp_mult *= 1.2;
Player.agility_exp_mult *= 1.2;
Player.charisma_exp_mult *= 1.2;
Player.hacking_mult *= 1.2;
Player.strength_mult *= 1.2;
Player.defense_mult *= 1.2;
Player.dexterity_mult *= 1.2;
Player.agility_mult *= 1.2;
Player.charisma_mult *= 1.2;
Player.hacking_exp_mult *= 1.15;
Player.strength_exp_mult *= 1.15;
Player.defense_exp_mult *= 1.15;
Player.dexterity_exp_mult *= 1.15;
Player.agility_exp_mult *= 1.15;
Player.charisma_exp_mult *= 1.15;
break;
case AugmentationNames.nextSENS:
Player.hacking_mult *= 1.2;
@ -1850,33 +1850,33 @@ applyAugmentation = function(aug, reapply=false) {
Player.charisma_mult *= 1.2;
break;
case AugmentationNames.OmniTekInfoLoad:
Player.hacking_mult *= 1.3;
Player.hacking_exp_mult *= 1.3;
break;
case AugmentationNames.PhotosyntheticCells:
Player.strength_mult *= 1.5;
Player.defense_mult *= 1.5;
Player.agility_mult *= 1.5;
break;
case AugmentationNames.Neurolink:
Player.hacking_mult *= 1.2;
Player.hacking_exp_mult *= 1.25;
break;
case AugmentationNames.PhotosyntheticCells:
Player.strength_mult *= 1.4;
Player.defense_mult *= 1.4;
Player.agility_mult *= 1.4;
break;
case AugmentationNames.Neurolink:
Player.hacking_mult *= 1.15;
Player.hacking_exp_mult *= 1.2;
Player.hacking_chance_mult *= 1.1;
Player.hacking_speed_mult *= 0.95;
Player.hacking_speed_mult *= 1.05;
break;
case AugmentationNames.TheBlackHand:
Player.strength_mult *= 1.2;
Player.dexterity_mult *= 1.2;
Player.strength_mult *= 1.15;
Player.dexterity_mult *= 1.15;
Player.hacking_mult *= 1.1;
Player.hacking_speed_mult *= 0.98;
Player.hacking_speed_mult *= 1.02;
Player.hacking_money_mult *= 1.1;
break;
case AugmentationNames.CRTX42AA:
Player.hacking_mult *= 1.1;
Player.hacking_exp_mult *= 1.2;
Player.hacking_mult *= 1.08;
Player.hacking_exp_mult *= 1.15;
break;
case AugmentationNames.Neuregen:
Player.hacking_exp_mult *= 1.75;
Player.hacking_exp_mult *= 1.4;
break;
case AugmentationNames.CashRoot:
break;
@ -1895,24 +1895,24 @@ applyAugmentation = function(aug, reapply=false) {
Player.defense_mult *= 1.5;
break;
case AugmentationNames.GrapheneBrachiBlades:
Player.strength_mult *= 1.5;
Player.defense_mult *= 1.5;
Player.strength_mult *= 1.4;
Player.defense_mult *= 1.4;
Player.crime_success_mult *= 1.1;
Player.crime_money_mult *= 1.25;
Player.crime_money_mult *= 1.3;
break;
case AugmentationNames.GrapheneBionicArms:
Player.strength_mult *= 2.25;
Player.dexterity_mult *= 2.25;
Player.strength_mult *= 1.85;
Player.dexterity_mult *= 1.85;
break;
case AugmentationNames.BrachiBlades:
Player.strength_mult *= 1.2;
Player.defense_mult *= 1.2;
Player.strength_mult *= 1.15;
Player.defense_mult *= 1.15;
Player.crime_success_mult *= 1.1;
Player.crime_money_mult *= 1.1;
Player.crime_money_mult *= 1.15;
break;
case AugmentationNames.BionicArms:
Player.strength_mult *= 1.5;
Player.dexterity_mult *= 1.5;
Player.strength_mult *= 1.3;
Player.dexterity_mult *= 1.3;
break;
case AugmentationNames.SNA:
Player.work_money_mult *= 1.1;
@ -1991,4 +1991,14 @@ PlayerObject.prototype.reapplyAllAugmentations = function() {
function augmentationExists(name) {
return Augmentations.hasOwnProperty(name);
}
//Used for testing balance
function giveAllAugmentations() {
for (var name in Augmentations) {
var aug = Augmentations[name];
if (aug == null) {continue;}
Player.augmentations.push(name);
}
Player.reapplyAllAugmentations();
}

View File

@ -1,32 +1,26 @@
//Netburner Company class
// Note: Company Positions can be loaded every time with init() but Company class needs
// to be saved/loaded from localStorage
function Company() {
this.companyName = "";
function Company(name, salaryMult, expMult, jobStatReqOffset) {
this.companyName = name;
this.info = "";
this.companyPositions = []; //Names (only name, not object) of all company positions
this.perks = []; //Available Perks
this.salaryMultiplier = 1; //Multiplier for base salary
this.expMultiplier = 1; //Multiplier for base exp gain
this.salaryMultiplier = salaryMult; //Multiplier for base salary
this.expMultiplier = expMult; //Multiplier for base exp gain
//The additional levels you need in the relevant stat to qualify for a job.
//E.g the offset for a megacorporation will be high, let's say 200, so the
//stat level you'd need to get an intern job would be 200 instead of 1.
this.jobStatReqOffset = 1;
this.jobStatReqOffset = jobStatReqOffset;
//Player-related properties for company
this.isPlayerEmployed = false;
this.playerPosition = ""; //Name (only name, not object) of the current position player holds
this.playerReputation = 1; //"Reputation" within company, gain reputation by working for company
this.playerPosition = ""; //Name (only name, not object) of the current position player holds
this.playerReputation = 1; //"Reputation" within company, gain reputation by working for company
this.favor = 0;
};
Company.prototype.init = function(name, salaryMult, expMult, jobStatReqOffset) {
this.companyName = name;
this.salaryMultiplier = salaryMult;
this.expMultiplier = expMult;
this.jobStatReqOffset = jobStatReqOffset;
}
Company.prototype.setInfo = function(inf) {
this.info = inf;
}
@ -50,6 +44,11 @@ Company.prototype.hasPosition = function(pos) {
return false;
}
Company.prototype.gainFavor = function() {
if (this.favor == null || this.favor == undefined) {this.favor = 0;}
this.favor += Math.max(0, (this.playerReputation-1) / CONSTANTS.CompanyReputationToFavor);
}
Company.prototype.toJSON = function() {
return Generic_toJSON("Company", this);
}
@ -271,10 +270,10 @@ CompanyPositions = {
SecurityGuard: new CompanyPosition("Security Guard", 0, 51, 51, 51, 51, 1, 0, 20),
SecurityOfficer: new CompanyPosition("Security Officer", 26, 151, 151, 151, 151, 51, 8000, 75),
SecuritySupervisor: new CompanyPosition("Security Supervisor", 26, 251, 251, 251, 251, 101, 32000, 275),
HeadOfSecurity: new CompanyPosition("Head of Security", 51, 501, 501, 501, 501, 151, 144000, 550),
FieldAgent: new CompanyPosition("Field Agent", 101, 101, 101, 101, 101, 101, 8000, 55),
SecretAgent: new CompanyPosition("Secret Agent", 201, 251, 251, 251, 251, 32000, 190),
SpecialOperative: new CompanyPosition("Special Operative", 251, 501, 501, 501, 501, 144000, 425),
HeadOfSecurity: new CompanyPosition("Head of Security", 51, 501, 501, 501, 501, 151, 144000, 550),
FieldAgent: new CompanyPosition("Field Agent", 101, 101, 101, 101, 101, 101, 8000, 55),
SecretAgent: new CompanyPosition("Secret Agent", 201, 251, 251, 251, 251, 201, 32000, 190),
SpecialOperative: new CompanyPosition("Special Operative", 251, 501, 501, 501, 501, 251, 144000, 425),
init: function() {
//Argument order: hack, str, def, dex, agi, cha
@ -481,8 +480,7 @@ getNextCompanyPosition = function(currPos) {
initCompanies = function() {
/* Companies that also have servers */
//Megacorporations
var ECorp = new Company();
ECorp.init(Locations.AevumECorp, 3.0, 3.0, 249);
var ECorp = new Company(Locations.AevumECorp, 3.0, 3.0, 249);
ECorp.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.ITIntern, CompanyPositions.BusinessIntern,
CompanyPositions.JuniorDev, CompanyPositions.SeniorDev, CompanyPositions.LeadDev,
@ -493,10 +491,13 @@ initCompanies = function() {
CompanyPositions.BusinessManager, CompanyPositions.OperationsManager, CompanyPositions.CFO,
CompanyPositions.CEO, CompanyPositions.SecurityGuard, CompanyPositions.SecurityOfficer,
CompanyPositions.SecuritySupervisor, CompanyPositions.HeadOfSecurity]);
if (companyExists(Locations.AevumECorp)) {
ECorp.favor = Companies[Locations.AevumECorp].favor;
delete Companies[Locations.AevumECorp];
}
AddToCompanies(ECorp);
var MegaCorp = new Company();
MegaCorp.init(Locations.Sector12MegaCorp, 3.0, 3.0, 249);
var MegaCorp = new Company(Locations.Sector12MegaCorp, 3.0, 3.0, 249);
MegaCorp.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.ITIntern, CompanyPositions.BusinessIntern,
CompanyPositions.JuniorDev, CompanyPositions.SeniorDev, CompanyPositions.LeadDev,
@ -507,10 +508,13 @@ initCompanies = function() {
CompanyPositions.BusinessManager, CompanyPositions.OperationsManager, CompanyPositions.CFO,
CompanyPositions.CEO, CompanyPositions.SecurityGuard, CompanyPositions.SecurityOfficer,
CompanyPositions.SecuritySupervisor, CompanyPositions.HeadOfSecurity]);
if (companyExists(Locations.Sector12MegaCorp)) {
MegaCorp.favor = Companies[Locations.Sector12MegaCorp].favor;
delete Companies[Locations.Sector12MegaCorp];
}
AddToCompanies(MegaCorp);
var BachmanAndAssociates = new Company();
BachmanAndAssociates.init(Locations.AevumBachmanAndAssociates, 2.6, 2.6, 224);
var BachmanAndAssociates = new Company(Locations.AevumBachmanAndAssociates, 2.6, 2.6, 224);
BachmanAndAssociates.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.ITIntern, CompanyPositions.BusinessIntern,
CompanyPositions.JuniorDev, CompanyPositions.SeniorDev, CompanyPositions.LeadDev,
@ -521,10 +525,13 @@ initCompanies = function() {
CompanyPositions.BusinessManager, CompanyPositions.OperationsManager, CompanyPositions.CFO,
CompanyPositions.CEO, CompanyPositions.SecurityGuard, CompanyPositions.SecurityOfficer,
CompanyPositions.SecuritySupervisor, CompanyPositions.HeadOfSecurity]);
if (companyExists(Locations.AevumBachmanAndAssociates)) {
BachmanAndAssociates.favor = Companies[Locations.AevumBachmanAndAssociates].favor;
delete Companies[Locations.AevumBachmanAndAssociates];
}
AddToCompanies(BachmanAndAssociates);
var BladeIndustries = new Company();
BladeIndustries.init(Locations.Sector12BladeIndustries, 2.75, 2.75, 224);
var BladeIndustries = new Company(Locations.Sector12BladeIndustries, 2.75, 2.75, 224);
BladeIndustries.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.ITIntern, CompanyPositions.BusinessIntern,
CompanyPositions.JuniorDev, CompanyPositions.SeniorDev, CompanyPositions.LeadDev,
@ -535,10 +542,13 @@ initCompanies = function() {
CompanyPositions.BusinessManager, CompanyPositions.OperationsManager, CompanyPositions.CFO,
CompanyPositions.CEO, CompanyPositions.SecurityGuard, CompanyPositions.SecurityOfficer,
CompanyPositions.SecuritySupervisor, CompanyPositions.HeadOfSecurity]);
if (companyExists(Locations.Sector12BladeIndustries)) {
BladeIndustries.favor = Companies[Locations.Sector12BladeIndustries].favor;
delete Companies[Locations.Sector12BladeIndustries];
}
AddToCompanies(BladeIndustries);
var NWO = new Company();
NWO.init(Locations.VolhavenNWO, 2.75, 2.75, 249);
var NWO = new Company(Locations.VolhavenNWO, 2.75, 2.75, 249);
NWO.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.ITIntern, CompanyPositions.BusinessIntern,
CompanyPositions.JuniorDev, CompanyPositions.SeniorDev, CompanyPositions.LeadDev,
@ -549,10 +559,13 @@ initCompanies = function() {
CompanyPositions.BusinessManager, CompanyPositions.OperationsManager, CompanyPositions.CFO,
CompanyPositions.CEO, CompanyPositions.SecurityGuard, CompanyPositions.SecurityOfficer,
CompanyPositions.SecuritySupervisor, CompanyPositions.HeadOfSecurity]);
if (companyExists(Locations.VolhavenNWO)) {
NWO.favor = Companies[Locations.VolhavenNWO].favor;
delete Companies[Locations.VolhavenNWO];
}
AddToCompanies(NWO);
var ClarkeIncorporated = new Company();
ClarkeIncorporated.init(Locations.AevumClarkeIncorporated, 2.25, 2.25, 224);
var ClarkeIncorporated = new Company(Locations.AevumClarkeIncorporated, 2.25, 2.25, 224);
ClarkeIncorporated.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.ITIntern, CompanyPositions.BusinessIntern,
CompanyPositions.JuniorDev, CompanyPositions.SeniorDev, CompanyPositions.LeadDev,
@ -563,10 +576,13 @@ initCompanies = function() {
CompanyPositions.BusinessManager, CompanyPositions.OperationsManager, CompanyPositions.CFO,
CompanyPositions.CEO, CompanyPositions.SecurityGuard, CompanyPositions.SecurityOfficer,
CompanyPositions.SecuritySupervisor, CompanyPositions.HeadOfSecurity]);
if (companyExists(Locations.AevumClarkeIncorporated)) {
ClarkeIncorporated.favor = Companies[Locations.AevumClarkeIncorporated].favor;
delete Companies[Locations.AevumClarkeIncorporated];
}
AddToCompanies(ClarkeIncorporated);
var OmniTekIncorporated = new Company();
OmniTekIncorporated.init(Locations.VolhavenOmniTekIncorporated, 2.25, 2.25, 224);
var OmniTekIncorporated = new Company(Locations.VolhavenOmniTekIncorporated, 2.25, 2.25, 224);
OmniTekIncorporated.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.ITIntern, CompanyPositions.BusinessIntern,
CompanyPositions.JuniorDev, CompanyPositions.SeniorDev, CompanyPositions.LeadDev,
@ -577,10 +593,13 @@ initCompanies = function() {
CompanyPositions.BusinessManager, CompanyPositions.OperationsManager, CompanyPositions.CFO,
CompanyPositions.CEO, CompanyPositions.SecurityGuard, CompanyPositions.SecurityOfficer,
CompanyPositions.SecuritySupervisor, CompanyPositions.HeadOfSecurity]);
if (companyExists(Locations.VolhavenOmniTekIncorporated)) {
OmniTekIncorporated.favor = Companies[Locations.VolhavenOmniTekIncorporated].favor;
delete Companies[Locations.VolhavenOmniTekIncorporated];
}
AddToCompanies(OmniTekIncorporated);
var FourSigma = new Company();
FourSigma.init(Locations.Sector12FourSigma, 2.5, 2.5, 224);
var FourSigma = new Company(Locations.Sector12FourSigma, 2.5, 2.5, 224);
FourSigma.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.ITIntern, CompanyPositions.BusinessIntern,
CompanyPositions.JuniorDev, CompanyPositions.SeniorDev, CompanyPositions.LeadDev,
@ -591,10 +610,13 @@ initCompanies = function() {
CompanyPositions.BusinessManager, CompanyPositions.OperationsManager, CompanyPositions.CFO,
CompanyPositions.CEO, CompanyPositions.SecurityGuard, CompanyPositions.SecurityOfficer,
CompanyPositions.SecuritySupervisor, CompanyPositions.HeadOfSecurity]);
if (companyExists(Locations.Sector12FourSigma)) {
FourSigma.favor = Companies[Locations.Sector12FourSigma].favor;
delete Companies[Locations.Sector12FourSigma];
}
AddToCompanies(FourSigma);
var KuaiGongInternational = new Company();
KuaiGongInternational.init(Locations.ChongqingKuaiGongInternational, 2.2, 2.2, 224);
var KuaiGongInternational = new Company(Locations.ChongqingKuaiGongInternational, 2.2, 2.2, 224);
KuaiGongInternational.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.ITIntern, CompanyPositions.BusinessIntern,
CompanyPositions.JuniorDev, CompanyPositions.SeniorDev, CompanyPositions.LeadDev,
@ -605,11 +627,14 @@ initCompanies = function() {
CompanyPositions.BusinessManager, CompanyPositions.OperationsManager, CompanyPositions.CFO,
CompanyPositions.CEO, CompanyPositions.SecurityGuard, CompanyPositions.SecurityOfficer,
CompanyPositions.SecuritySupervisor, CompanyPositions.HeadOfSecurity]);
if (companyExists(Locations.ChongqingKuaiGongInternational)) {
KuaiGongInternational.favor = Companies[Locations.ChongqingKuaiGongInternational].favor;
delete Companies[Locations.ChongqingKuaiGongInternational];
}
AddToCompanies(KuaiGongInternational);
//Technology and communication companies ("Large" servers)
var FulcrumTechnologies = new Company();
FulcrumTechnologies.init(Locations.AevumFulcrumTechnologies, 2.0, 2.0, 224);
var FulcrumTechnologies = new Company(Locations.AevumFulcrumTechnologies, 2.0, 2.0, 224);
FulcrumTechnologies.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.ITIntern, CompanyPositions.BusinessIntern,
CompanyPositions.JuniorDev, CompanyPositions.SeniorDev, CompanyPositions.LeadDev,
@ -619,10 +644,13 @@ initCompanies = function() {
CompanyPositions.VicePresident, CompanyPositions.CTO, CompanyPositions.BusinessAnalyst,
CompanyPositions.BusinessManager, CompanyPositions.OperationsManager, CompanyPositions.CFO,
CompanyPositions.CEO]);
if (companyExists(Locations.AevumFulcrumTechnologies)) {
FulcrumTechnologies.favor = Companies[Locations.AevumFulcrumTechnologies].favor;
delete Companies[Locations.AevumFulcrumTechnologies];
}
AddToCompanies(FulcrumTechnologies);
var StormTechnologies = new Company();
StormTechnologies.init(Locations.IshimaStormTechnologies, 1.8, 1.8, 199);
var StormTechnologies = new Company(Locations.IshimaStormTechnologies, 1.8, 1.8, 199);
StormTechnologies.addPositions([
CompanyPositions.SoftwareIntern,
CompanyPositions.JuniorDev, CompanyPositions.SeniorDev, CompanyPositions.LeadDev,
@ -633,10 +661,13 @@ initCompanies = function() {
CompanyPositions.VicePresident, CompanyPositions.CTO, CompanyPositions.BusinessAnalyst,
CompanyPositions.BusinessManager, CompanyPositions.OperationsManager, CompanyPositions.CFO,
CompanyPositions.CEO]);
if (companyExists(Locations.IshimaStormTechnologies)) {
StormTechnologies.favor = Companies[Locations.IshimaStormTechnologies].favor;
delete Companies[Locations.IshimaStormTechnologies];
}
AddToCompanies(StormTechnologies);
var DefComm = new Company();
DefComm.init(Locations.NewTokyoDefComm, 1.75, 1.75, 199);
var DefComm = new Company(Locations.NewTokyoDefComm, 1.75, 1.75, 199);
DefComm.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.JuniorDev, CompanyPositions.SeniorDev,
CompanyPositions.LeadDev, CompanyPositions.SoftwareConsultant, CompanyPositions.SeniorSoftwareConsultant,
@ -644,10 +675,13 @@ initCompanies = function() {
CompanyPositions.ITManager, CompanyPositions.SysAdmin, CompanyPositions.SecurityEngineer,
CompanyPositions.NetworkEngineer, CompanyPositions.NetworkAdministrator, CompanyPositions.HeadOfSoftware,
CompanyPositions.HeadOfEngineering, CompanyPositions.CTO, CompanyPositions.CFO, CompanyPositions.CEO]);
if (companyExists(Locations.NewTokyoDefComm)) {
DefComm.favor = Companies[Locations.NewTokyoDefComm].favor;
delete Companies[Locations.NewTokyoDefComm];
}
AddToCompanies(DefComm);
var HeliosLabs = new Company();
HeliosLabs.init(Locations.VolhavenHeliosLabs, 1.8, 1.8, 199);
var HeliosLabs = new Company(Locations.VolhavenHeliosLabs, 1.8, 1.8, 199);
HeliosLabs.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.JuniorDev, CompanyPositions.SeniorDev,
CompanyPositions.LeadDev, CompanyPositions.SoftwareConsultant, CompanyPositions.SeniorSoftwareConsultant,
@ -655,10 +689,13 @@ initCompanies = function() {
CompanyPositions.ITManager, CompanyPositions.SysAdmin, CompanyPositions.SecurityEngineer,
CompanyPositions.NetworkEngineer, CompanyPositions.NetworkAdministrator, CompanyPositions.HeadOfSoftware,
CompanyPositions.HeadOfEngineering, CompanyPositions.CTO, CompanyPositions.CFO, CompanyPositions.CEO]);
if (companyExists(Locations.VolhavenHeliosLabs)) {
HeliosLabs.favor = Companies[Locations.VolhavenHeliosLabs].favor;
delete Companies[Locations.VolhavenHeliosLabs];
}
AddToCompanies(HeliosLabs);
var VitaLife = new Company();
VitaLife.init(Locations.NewTokyoVitaLife, 1.8, 1.8, 199);
var VitaLife = new Company(Locations.NewTokyoVitaLife, 1.8, 1.8, 199);
VitaLife.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.JuniorDev, CompanyPositions.SeniorDev,
CompanyPositions.LeadDev, CompanyPositions.SoftwareConsultant, CompanyPositions.SeniorSoftwareConsultant,
@ -667,10 +704,13 @@ initCompanies = function() {
CompanyPositions.NetworkEngineer, CompanyPositions.NetworkAdministrator, CompanyPositions.HeadOfSoftware,
CompanyPositions.HeadOfEngineering, CompanyPositions.CTO, CompanyPositions.BusinessManager,
CompanyPositions.OperationsManager, CompanyPositions.CFO, CompanyPositions.CEO]);
if (companyExists(Locations.NewTokyoVitaLife)) {
VitaLife.favor = Companies[Locations.NewTokyoVitaLife].favor;
delete Companies[Locations.NewTokyoVitaLife];
}
AddToCompanies(VitaLife);
var IcarusMicrosystems = new Company();
IcarusMicrosystems.init(Locations.Sector12IcarusMicrosystems, 1.9, 1.9, 199);
var IcarusMicrosystems = new Company(Locations.Sector12IcarusMicrosystems, 1.9, 1.9, 199);
IcarusMicrosystems.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.JuniorDev, CompanyPositions.SeniorDev,
CompanyPositions.LeadDev, CompanyPositions.SoftwareConsultant, CompanyPositions.SeniorSoftwareConsultant,
@ -679,10 +719,13 @@ initCompanies = function() {
CompanyPositions.NetworkEngineer, CompanyPositions.NetworkAdministrator, CompanyPositions.HeadOfSoftware,
CompanyPositions.HeadOfEngineering, CompanyPositions.CTO, CompanyPositions.BusinessManager,
CompanyPositions.OperationsManager, CompanyPositions.CFO, CompanyPositions.CEO]);
if (companyExists(Locations.Sector12IcarusMicrosystems)) {
IcarusMicrosystems.favor = Companies[Locations.Sector12IcarusMicrosystems].favor;
delete Companies[Locations.Sector12IcarusMicrosystems];
}
AddToCompanies(IcarusMicrosystems);
var UniversalEnergy = new Company();
UniversalEnergy.init(Locations.Sector12UniversalEnergy, 2.0, 2.0, 199);
var UniversalEnergy = new Company(Locations.Sector12UniversalEnergy, 2.0, 2.0, 199);
UniversalEnergy.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.JuniorDev, CompanyPositions.SeniorDev,
CompanyPositions.LeadDev, CompanyPositions.SoftwareConsultant, CompanyPositions.SeniorSoftwareConsultant,
@ -691,10 +734,13 @@ initCompanies = function() {
CompanyPositions.NetworkEngineer, CompanyPositions.NetworkAdministrator, CompanyPositions.HeadOfSoftware,
CompanyPositions.HeadOfEngineering, CompanyPositions.CTO, CompanyPositions.BusinessManager,
CompanyPositions.OperationsManager, CompanyPositions.CFO, CompanyPositions.CEO]);
if (companyExists(Locations.Sector12UniversalEnergy)) {
UniversalEnergy.favor = Companies[Locations.Sector12UniversalEnergy].favor;
delete Companies[Locations.Sector12UniversalEnergy];
}
AddToCompanies(UniversalEnergy);
var GalacticCybersystems = new Company();
GalacticCybersystems.init(Locations.AevumGalacticCybersystems, 1.9, 1.9, 199);
var GalacticCybersystems = new Company(Locations.AevumGalacticCybersystems, 1.9, 1.9, 199);
GalacticCybersystems.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.JuniorDev, CompanyPositions.SeniorDev,
CompanyPositions.LeadDev, CompanyPositions.SoftwareConsultant, CompanyPositions.SeniorSoftwareConsultant,
@ -703,11 +749,14 @@ initCompanies = function() {
CompanyPositions.NetworkEngineer, CompanyPositions.NetworkAdministrator, CompanyPositions.HeadOfSoftware,
CompanyPositions.HeadOfEngineering, CompanyPositions.CTO, CompanyPositions.BusinessManager,
CompanyPositions.OperationsManager, CompanyPositions.CFO, CompanyPositions.CEO]);
if (companyExists(Locations.AevumGalacticCybersystems)) {
GalacticCybersystems.favor = Companies[Locations.AevumGalacticCybersystems].favor;
delete Companies[Locations.AevumGalacticCybersystems];
}
AddToCompanies(GalacticCybersystems);
//Defense Companies ("Large" Companies)
var AeroCorp = new Company();
AeroCorp.init(Locations.AevumAeroCorp, 1.7, 1.7, 199);
var AeroCorp = new Company(Locations.AevumAeroCorp, 1.7, 1.7, 199);
AeroCorp.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.JuniorDev, CompanyPositions.SeniorDev,
CompanyPositions.LeadDev, CompanyPositions.ITIntern, CompanyPositions.ITAnalyst,
@ -717,10 +766,13 @@ initCompanies = function() {
CompanyPositions.OperationsManager, CompanyPositions.CFO, CompanyPositions.CEO,
CompanyPositions.SecurityGuard, CompanyPositions.SecurityOfficer, CompanyPositions.SecuritySupervisor,
CompanyPositions.HeadOfSecurity]);
if (companyExists(Locations.AevumAeroCorp)) {
AeroCorp.favor = Companies[Locations.AevumAeroCorp].favor;
delete Companies[Locations.AevumAeroCorp];
}
AddToCompanies(AeroCorp);
var OmniaCybersystems = new Company();
OmniaCybersystems.init(Locations.VolhavenOmniaCybersystems, 1.7, 1.7, 199);
var OmniaCybersystems = new Company(Locations.VolhavenOmniaCybersystems, 1.7, 1.7, 199);
OmniaCybersystems.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.JuniorDev, CompanyPositions.SeniorDev,
CompanyPositions.LeadDev, CompanyPositions.ITIntern, CompanyPositions.ITAnalyst,
@ -730,10 +782,13 @@ initCompanies = function() {
CompanyPositions.OperationsManager, CompanyPositions.CFO, CompanyPositions.CEO,
CompanyPositions.SecurityGuard, CompanyPositions.SecurityOfficer, CompanyPositions.SecuritySupervisor,
CompanyPositions.HeadOfSecurity]);
if (companyExists(Locations.VolhavenOmniaCybersystems)) {
OmniaCybersystems.favor = Companies[Locations.VolhavenOmniaCybersystems].favor;
delete Companies[Locations.VolhavenOmniaCybersystems];
}
AddToCompanies(OmniaCybersystems);
var SolarisSpaceSystems = new Company();
SolarisSpaceSystems.init(Locations.ChongqingSolarisSpaceSystems, 1.7, 1.7, 199);
var SolarisSpaceSystems = new Company(Locations.ChongqingSolarisSpaceSystems, 1.7, 1.7, 199);
SolarisSpaceSystems.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.JuniorDev, CompanyPositions.SeniorDev,
CompanyPositions.LeadDev, CompanyPositions.ITIntern, CompanyPositions.ITAnalyst,
@ -743,10 +798,13 @@ initCompanies = function() {
CompanyPositions.OperationsManager, CompanyPositions.CFO, CompanyPositions.CEO,
CompanyPositions.SecurityGuard, CompanyPositions.SecurityOfficer, CompanyPositions.SecuritySupervisor,
CompanyPositions.HeadOfSecurity]);
if (companyExists(Locations.ChongqingSolarisSpaceSystems)) {
SolarisSpaceSystems.favor = Companies[Locations.ChongqingSolarisSpaceSystems].favor;
delete Companies[Locations.ChongqingSolarisSpaceSystems];
}
AddToCompanies(SolarisSpaceSystems);
var DeltaOne = new Company();
DeltaOne.init(Locations.Sector12DeltaOne, 1.6, 1.6, 199);
var DeltaOne = new Company(Locations.Sector12DeltaOne, 1.6, 1.6, 199);
DeltaOne.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.JuniorDev, CompanyPositions.SeniorDev,
CompanyPositions.LeadDev, CompanyPositions.ITIntern, CompanyPositions.ITAnalyst,
@ -756,11 +814,14 @@ initCompanies = function() {
CompanyPositions.OperationsManager, CompanyPositions.CFO, CompanyPositions.CEO,
CompanyPositions.SecurityGuard, CompanyPositions.SecurityOfficer, CompanyPositions.SecuritySupervisor,
CompanyPositions.HeadOfSecurity]);
if (companyExists(Locations.Sector12DeltaOne)) {
DeltaOne.favor = Companies[Locations.Sector12DeltaOne].favor;
delete Companies[Locations.Sector12DeltaOne];
}
AddToCompanies(DeltaOne);
//Health, medicine, pharmaceutical companies ("Large" servers)
var GlobalPharmaceuticals = new Company();
GlobalPharmaceuticals.init(Locations.NewTokyoGlobalPharmaceuticals, 1.8, 1.8, 224);
var GlobalPharmaceuticals = new Company(Locations.NewTokyoGlobalPharmaceuticals, 1.8, 1.8, 224);
GlobalPharmaceuticals.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.ITIntern, CompanyPositions.BusinessIntern,
CompanyPositions.JuniorDev, CompanyPositions.SeniorDev, CompanyPositions.LeadDev,
@ -771,10 +832,13 @@ initCompanies = function() {
CompanyPositions.BusinessManager, CompanyPositions.OperationsManager,
CompanyPositions.CFO, CompanyPositions.CEO, CompanyPositions.SecurityGuard,
CompanyPositions.SecuritySupervisor, CompanyPositions.HeadOfSecurity]);
if (companyExists(Locations.NewTokyoGlobalPharmaceuticals)) {
GlobalPharmaceuticals.favor = Companies[Locations.NewTokyoGlobalPharmaceuticals].favor;
delete Companies[Locations.NewTokyoGlobalPharmaceuticals];
}
AddToCompanies(GlobalPharmaceuticals);
var NovaMedical = new Company();
NovaMedical.init(Locations.IshimaNovaMedical, 1.75, 1.75, 199);
var NovaMedical = new Company(Locations.IshimaNovaMedical, 1.75, 1.75, 199);
NovaMedical.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.ITIntern, CompanyPositions.BusinessIntern,
CompanyPositions.JuniorDev, CompanyPositions.SeniorDev, CompanyPositions.LeadDev,
@ -785,11 +849,14 @@ initCompanies = function() {
CompanyPositions.BusinessManager, CompanyPositions.OperationsManager,
CompanyPositions.CFO, CompanyPositions.CEO, CompanyPositions.SecurityGuard,
CompanyPositions.SecuritySupervisor, CompanyPositions.HeadOfSecurity]);
if (companyExists(Locations.IshimaNovaMedical)) {
NovaMedical.favor = Companies[Locations.IshimaNovaMedical].favor;
delete Companies[Locations.IshimaNovaMedical];
}
AddToCompanies(NovaMedical);
//Other large companies
var CIA = new Company();
CIA.init(Locations.Sector12CIA, 2.0, 2.0, 149);
var CIA = new Company(Locations.Sector12CIA, 2.0, 2.0, 149);
CIA.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.JuniorDev, CompanyPositions.SeniorDev,
CompanyPositions.LeadDev, CompanyPositions.ITIntern, CompanyPositions.ITAnalyst,
@ -798,10 +865,13 @@ initCompanies = function() {
CompanyPositions.HeadOfEngineering, CompanyPositions.SecurityGuard, CompanyPositions.SecurityOfficer,
CompanyPositions.SecuritySupervisor, CompanyPositions.HeadOfSecurity, CompanyPositions.FieldAgent,
CompanyPositions.SecretAgent, CompanyPositions.SpecialOperative]);
if (companyExists(Locations.Sector12CIA)) {
CIA.favor = Companies[Locations.Sector12CIA].favor;
delete Companies[Locations.Sector12CIA];
}
AddToCompanies(CIA);
var NSA = new Company();
NSA.init(Locations.Sector12NSA, 2.0, 2.0, 149);
var NSA = new Company(Locations.Sector12NSA, 2.0, 2.0, 149);
NSA.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.JuniorDev, CompanyPositions.SeniorDev,
CompanyPositions.LeadDev, CompanyPositions.ITIntern, CompanyPositions.ITAnalyst,
@ -810,10 +880,13 @@ initCompanies = function() {
CompanyPositions.HeadOfEngineering, CompanyPositions.SecurityGuard, CompanyPositions.SecurityOfficer,
CompanyPositions.SecuritySupervisor, CompanyPositions.HeadOfSecurity, CompanyPositions.FieldAgent,
CompanyPositions.SecretAgent, CompanyPositions.SpecialOperative]);
if (companyExists(Locations.Sector12NSA)) {
NSA.favor = Companies[Locations.Sector12NSA].favor;
delete Companies[Locations.Sector12NSA];
}
AddToCompanies(NSA);
var WatchdogSecurity = new Company();
WatchdogSecurity.init(Locations.AevumWatchdogSecurity, 1.5, 1.5, 124);
var WatchdogSecurity = new Company(Locations.AevumWatchdogSecurity, 1.5, 1.5, 124);
WatchdogSecurity.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.JuniorDev, CompanyPositions.SeniorDev,
CompanyPositions.LeadDev, CompanyPositions.SoftwareConsultant, CompanyPositions.SeniorSoftwareConsultant,
@ -823,11 +896,14 @@ initCompanies = function() {
CompanyPositions.HeadOfEngineering, CompanyPositions.SecurityGuard, CompanyPositions.SecurityOfficer,
CompanyPositions.SecuritySupervisor, CompanyPositions.HeadOfSecurity, CompanyPositions.FieldAgent,
CompanyPositions.SecretAgent, CompanyPositions.SpecialOperative]);
if (companyExists(Locations.AevumWatchdogSecurity)) {
WatchdogSecurity.favor = Companies[Locations.AevumWatchdogSecurity].favor;
delete Companies[Locations.AevumWatchdogSecurity];
}
AddToCompanies(WatchdogSecurity);
//"Medium level" companies
var LexoCorp = new Company();
LexoCorp.init(Locations.VolhavenLexoCorp, 1.4, 1.4, 99);
var LexoCorp = new Company(Locations.VolhavenLexoCorp, 1.4, 1.4, 99);
LexoCorp.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.JuniorDev, CompanyPositions.SeniorDev,
CompanyPositions.LeadDev, CompanyPositions.SoftwareConsultant, CompanyPositions.SeniorSoftwareConsultant,
@ -837,44 +913,59 @@ initCompanies = function() {
CompanyPositions.BusinessIntern, CompanyPositions.BusinessAnalyst,
CompanyPositions.OperationsManager, CompanyPositions.CFO, CompanyPositions.CEO,
CompanyPositions.SecurityGuard, CompanyPositions.SecurityOfficer, CompanyPositions.HeadOfSecurity]);
if (companyExists(Locations.VolhavenLexoCorp)) {
LexoCorp.favor = Companies[Locations.VolhavenLexoCorp].favor;
delete Companies[Locations.VolhavenLexoCorp];
}
AddToCompanies(LexoCorp);
var RhoConstruction = new Company();
RhoConstruction.init(Locations.AevumRhoConstruction, 1.3, 1.3, 49);
var RhoConstruction = new Company(Locations.AevumRhoConstruction, 1.3, 1.3, 49);
RhoConstruction.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.JuniorDev, CompanyPositions.SeniorDev,
CompanyPositions.LeadDev, CompanyPositions.BusinessIntern, CompanyPositions.BusinessAnalyst,
CompanyPositions.BusinessManager, CompanyPositions.OperationsManager]);
if (companyExists(Locations.AevumRhoConstruction)) {
RhoConstruction.favor = Companies[Locations.AevumRhoConstruction].favor;
delete Companies[Locations.AevumRhoConstruction];
}
AddToCompanies(RhoConstruction);
var AlphaEnterprises = new Company();
AlphaEnterprises.init(Locations.Sector12AlphaEnterprises, 1.5, 1.5, 99);
var AlphaEnterprises = new Company(Locations.Sector12AlphaEnterprises, 1.5, 1.5, 99);
AlphaEnterprises.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.JuniorDev, CompanyPositions.SeniorDev,
CompanyPositions.LeadDev, CompanyPositions.SoftwareConsultant, CompanyPositions.SeniorSoftwareConsultant,
CompanyPositions.BusinessIntern, CompanyPositions.BusinessAnalyst,
CompanyPositions.BusinessManager, CompanyPositions.OperationsManager]);
if (companyExists(Locations.Sector12AlphaEnterprises)) {
AlphaEnterprises.favor = Companies[Locations.Sector12AlphaEnterprises].favor;
delete Companies[Locations.Sector12AlphaEnterprises];
}
AddToCompanies(AlphaEnterprises);
var AevumPolice = new Company();
AevumPolice.init(Locations.AevumPolice, 1.3, 1.3, 99);
var AevumPolice = new Company(Locations.AevumPolice, 1.3, 1.3, 99);
AevumPolice.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.JuniorDev, CompanyPositions.SeniorDev,
CompanyPositions.LeadDev, CompanyPositions.SecurityGuard, CompanyPositions.PoliceOfficer]);
if (companyExists(Locations.AevumPolice)) {
AevumPolice.favor = Companies[Locations.AevumPolice].favor;
delete Companies[Locations.AevumPolice];
}
AddToCompanies(AevumPolice);
var SysCoreSecurities = new Company();
SysCoreSecurities.init(Locations.VolhavenSysCoreSecurities, 1.3, 1.3, 124);
var SysCoreSecurities = new Company(Locations.VolhavenSysCoreSecurities, 1.3, 1.3, 124);
SysCoreSecurities.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.JuniorDev, CompanyPositions.SeniorDev,
CompanyPositions.LeadDev, CompanyPositions.ITIntern, CompanyPositions.ITAnalyst,
CompanyPositions.ITManager, CompanyPositions.SysAdmin, CompanyPositions.SecurityEngineer,
CompanyPositions.NetworkEngineer, CompanyPositions.NetworkAdministrator, CompanyPositions.HeadOfSoftware,
CompanyPositions.CTO]);
if (companyExists(Locations.VolhavenSysCoreSecurities)) {
SysCoreSecurities.favor = Companies[Locations.VolhavenSysCoreSecurities].favor;
delete Companies[Locations.VolhavenSysCoreSecurities];
}
AddToCompanies(SysCoreSecurities);
var CompuTek = new Company();
CompuTek.init(Locations.VolhavenCompuTek, 1.2, 1.2, 74);
var CompuTek = new Company(Locations.VolhavenCompuTek, 1.2, 1.2, 74);
CompuTek.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.JuniorDev, CompanyPositions.SeniorDev,
CompanyPositions.LeadDev, CompanyPositions.SoftwareConsultant, CompanyPositions.SeniorSoftwareConsultant,
@ -882,10 +973,13 @@ initCompanies = function() {
CompanyPositions.ITManager, CompanyPositions.SysAdmin, CompanyPositions.SecurityEngineer,
CompanyPositions.NetworkEngineer, CompanyPositions.NetworkAdministrator, CompanyPositions.HeadOfSoftware,
CompanyPositions.CTO]);
if (companyExists(Locations.VolhavenCompuTek)) {
CompuTek.favor = Companies[Locations.VolhavenCompuTek].favor;
delete Companies[Locations.VolhavenCompuTek];
}
AddToCompanies(CompuTek);
var NetLinkTechnologies = new Company();
NetLinkTechnologies.init(Locations.AevumNetLinkTechnologies, 1.2, 1.2, 99);
var NetLinkTechnologies = new Company(Locations.AevumNetLinkTechnologies, 1.2, 1.2, 99);
NetLinkTechnologies.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.JuniorDev, CompanyPositions.SeniorDev,
CompanyPositions.LeadDev, CompanyPositions.SoftwareConsultant, CompanyPositions.SeniorSoftwareConsultant,
@ -893,10 +987,13 @@ initCompanies = function() {
CompanyPositions.ITManager, CompanyPositions.SysAdmin, CompanyPositions.SecurityEngineer,
CompanyPositions.NetworkEngineer, CompanyPositions.NetworkAdministrator, CompanyPositions.HeadOfSoftware,
CompanyPositions.CTO]);
if (companyExists(Locations.AevumNetLinkTechnologies)) {
NetLinkTechnologies.favor = Companies[Locations.AevumNetLinkTechnologies].favor;
delete Companies[Locations.AevumNetLinkTechnologies];
}
AddToCompanies(NetLinkTechnologies);
var CarmichaelSecurity = new Company();
CarmichaelSecurity.init(Locations.Sector12CarmichaelSecurity, 1.2, 1.2, 74);
var CarmichaelSecurity = new Company(Locations.Sector12CarmichaelSecurity, 1.2, 1.2, 74);
CarmichaelSecurity.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.JuniorDev, CompanyPositions.SeniorDev,
CompanyPositions.LeadDev, CompanyPositions.SoftwareConsultant, CompanyPositions.SeniorSoftwareConsultant,
@ -906,32 +1003,48 @@ initCompanies = function() {
CompanyPositions.HeadOfEngineering, CompanyPositions.SecurityGuard, CompanyPositions.SecurityOfficer,
CompanyPositions.SecuritySupervisor, CompanyPositions.HeadOfSecurity, CompanyPositions.FieldAgent,
CompanyPositions.SecretAgent, CompanyPositions.SpecialOperative]);
if (companyExists(Locations.Sector12CarmichaelSecurity)) {
CarmichaelSecurity.favor = Companies[Locations.Sector12CarmichaelSecurity].favor;
delete Companies[Locations.Sector12CarmichaelSecurity];
}
AddToCompanies(CarmichaelSecurity);
//"Low level" companies
var FoodNStuff = new Company();
FoodNStuff.init(Locations.Sector12FoodNStuff, 1, 1, 0);
var FoodNStuff = new Company(Locations.Sector12FoodNStuff, 1, 1, 0);
FoodNStuff.addPositions([CompanyPositions.Employee, CompanyPositions.PartTimeEmployee]);
if (companyExists(Locations.Sector12FoodNStuff)) {
FoodNStuff.favor = Companies[Locations.Sector12FoodNStuff].favor;
delete Companies[Locations.Sector12FoodNStuff];
}
AddToCompanies(FoodNStuff);
var JoesGuns = new Company();
JoesGuns.init(Locations.Sector12JoesGuns, 1, 1, 0);
var JoesGuns = new Company(Locations.Sector12JoesGuns, 1, 1, 0);
JoesGuns.addPositions([CompanyPositions.Employee, CompanyPositions.PartTimeEmployee]);
if (companyExists(Locations.Sector12JoesGuns)) {
JoesGuns.favor = Companies[Locations.Sector12JoesGuns].favor;
delete Companies[Locations.Sector12JoesGuns];
}
AddToCompanies(JoesGuns);
var OmegaSoftware = new Company();
OmegaSoftware.init(Locations.IshimaOmegaSoftware, 1.1, 1.1, 49);
var OmegaSoftware = new Company(Locations.IshimaOmegaSoftware, 1.1, 1.1, 49);
OmegaSoftware.addPositions([
CompanyPositions.SoftwareIntern, CompanyPositions.JuniorDev, CompanyPositions.SeniorDev,
CompanyPositions.LeadDev, CompanyPositions.SoftwareConsultant, CompanyPositions.SeniorSoftwareConsultant,
CompanyPositions.ITIntern, CompanyPositions.ITAnalyst,
CompanyPositions.ITManager, CompanyPositions.CTO, CompanyPositions.CEO]);
if (companyExists(Locations.IshimaOmegaSoftware)) {
OmegaSoftware.favor = Companies[Locations.IshimaOmegaSoftware].favor;
delete Companies[Locations.IshimaOmegaSoftware];
}
AddToCompanies(OmegaSoftware);
/* Companies that do not have servers */
var NoodleBar = new Company();
NoodleBar.init(Locations.NewTokyoNoodleBar, 1, 1, 0);
var NoodleBar = new Company(Locations.NewTokyoNoodleBar, 1, 1, 0);
NoodleBar.addPositions([CompanyPositions.Waiter, CompanyPositions.PartTimeWaiter]);
if (companyExists(Locations.NewTokyoNoodleBar)) {
NoodleBar.favor = Companies[Locations.NewTokyoNoodleBar].favor;
delete Companies[Locations.NewTokyoNoodleBar];
}
AddToCompanies(NoodleBar);
}
@ -942,4 +1055,8 @@ Companies = {}
AddToCompanies = function (company) {
var name = company.companyName;
Companies[name] = company;
}
function companyExists(name) {
return Companies.hasOwnProperty(name);
}

View File

@ -1,5 +1,5 @@
CONSTANTS = {
Version: "0.21.0",
Version: "0.22.0",
//Max level for any skill, assuming no multipliers. Determined by max numerical value in javascript for experience
//and the skill level formula in Player.js. Note that all this means it that when experience hits MAX_INT, then
@ -28,6 +28,10 @@ CONSTANTS = {
HacknetNodeMaxRam: 64,
HacknetNodeMaxCores: 16,
/* Faction and Company favor */
FactionReputationToFavor: 7500,
CompanyReputationToFavor: 5000,
/* Augmentation */
//NeuroFlux Governor cost multiplier as you level up
NeuroFluxGovernorLevelMult: 1.13,
@ -67,9 +71,11 @@ CONSTANTS = {
ScriptHNUpgRamRamCost: 0.6,
ScriptHNUpgCoreRamCost: 0.8,
MultithreadingRAMCost: 1.002,
//Server constants
ServerBaseGrowthRate: 1.02, //Unadjusted Growth rate
ServerMaxGrowthRate: 1.003, //Maximum possible growth rate (max rate accounting for server security)
ServerBaseGrowthRate: 1.03, //Unadjusted Growth rate
ServerMaxGrowthRate: 1.0045, //Maximum possible growth rate (max rate accounting for server security)
ServerFortifyAmount: 0.002, //Amount by which server's security increases when its hacked/grown
ServerWeakenAmount: 0.1, //Amount by which server's security decreases when weakened
@ -177,7 +183,8 @@ CONSTANTS = {
"sudov Shows whether or not you have root access on this computer<br>" +
"tail [script] [args...] Display dynamic logs for the script with the specified name and arguments<br>" +
"theme [preset] | bg txt hlgt Change the color scheme of the UI<br>" +
"top Display all running scripts and their RAM usage<br>",
"top Display all running scripts and their RAM usage<br>" +
'unalias "[alias name]" Deletes the specified alias. Double quotation marks are required<br>',
/* Tutorial related things */
TutorialGettingStartedText: "Todo...",
@ -281,7 +288,7 @@ CONSTANTS = {
"yield $50,000. <br><br> " +
"Each additional thread to a script will slightly increase the RAM usage for that thread. The total cost of running a script with " +
"n threads can be calculated with: <br>" +
"base cost * n * (1.02 ^ n) <br>" +
"base cost * n * (1.005 ^ n) <br>" +
"where the base cost is the amount of RAM required to run the script with a single thread. In the terminal, you can run the " +
"'mem [scriptname] -t n' command to see how much RAM a script requires with n threads. <br><br>" +
"Every method for running a script has an option for making it multihreaded. To run a script with " +
@ -471,6 +478,11 @@ CONSTANTS = {
"hostname or IP of the target server. Does NOT work while offline <br> Example: getServerMoneyAvailable('foodnstuff');<br><br>" +
"<i>getServerSecurityLevel(hostname/ip)</i><br>Returns the security level of a server. The argument passed in must be a string with either the " +
"hostname or IP of the target server. A server's security is denoted by a number between 1 and 100. Does NOT work while offline.<br><br>" +
"<i>getServerBaseSecurityLevel(hostname/ip)</i><br> Returns the base security level of a server. This is the security level that the server starts out with. " +
"This is different than getServerSecurityLevel() because getServerSecurityLevel() returns the current security level of a server, which can constantly change " +
"due to hack(), grow(), and weaken() calls on that server. The base security level will stay the same until you reset by installing an Augmentation. <br><br>" +
"The argument passed in must be a string with either the hostname or IP of the target server. A server's base security is denoted by a number between 1 and 100. " +
"Does NOT work while offline.<br><br>" +
"<i>getServerRequiredHackingLevel(hostname/ip)</i><br> Returns the required hacking level of a server. The argument passed in must be a string with either the " +
"hostname or IP or the target server. Does NOT work while offline <br><br>" +
"<i>fileExists(filename, [hostname/ip])</i><br> Returns a boolean (true or false) indicating whether the specified file exists on a server. " +
@ -643,9 +655,31 @@ CONSTANTS = {
"RAM Upgrades on your home computer",
Changelog:
"v0.22.0 - Major rebalancing, optimization, and favor system<br>" +
"-Significantly nerfed most augmentations<br>" +
"-Almost every server with a required hacking level of 200 or more now has slightly randomized server parameters. This means that after every Augmentation " +
"purchase, the required hacking level, base security level, and growth factor of these servers will all be slightly different<br>" +
"-The hacking speed multiplier now increases rather than decreases. The hacking time is now divided by your hacking speed " +
"multiplier rather than multiplied. In other words, a higher hacking speed multiplier is better<br>" +
"-Servers now have a minimum server security, which is approximately one third of their starting ('base') server security<br>" +
"-If you do not steal any money from a server, then you gain hacking experience equal to the amount you would have gained " +
"had you failed the hack<br>" +
"-The effects of grow() were increased by 50%<br>" +
"-grow() and weaken() now give hacking experience based on the server's base security level, rather than a flat exp amount<br>" +
"-Slightly reduced amount of exp gained from hack(), weaken(), and grow()<br>" +
"-Rebalanced formulas that determine crime success<br>" +
"-Reduced RAM cost for multithreading a script. The RAM multiplier for each thread was reduced from 1.02 to 1.005<br>" +
"-Optimized Script objects so they take less space in the save file<br>" +
"-Added getServerBaseSecurityLevel() Netscript function<br>" +
"-New favor system for companies and factions. Earning reputation at a company/faction will give you favor for that entity when you " +
"reset after installing an Augmentation. This favor persists through the rest of the game. The more favor you have, the faster you will earn " +
"reputation with that faction<br>" +
"-You can no longer donate to a faction for reputation until you have 150 favor with that faction<br>" +
"-Added unalias Terminal command<br>" +
"-Changed requirements for endgame Factions<br><br>" +
"v0.21.1<br>" +
"-IF YOUR GAME BREAKS, DO THE FOLLOWING: Options -> Soft Reset -> Save Game -> Reload Page. Sorry about that! <br>" +
"-Autocompletion for aliases - courtesy of Github user LTCNugget" +
"-Autocompletion for aliases - courtesy of Github user LTCNugget<br><br>" +
"v0.21.0<br>" +
"-Added dynamic arrays. See Netscript documentation<br>" +
"-Added ability to pass arguments into scripts. See documentation<br>" +
@ -795,28 +829,26 @@ CONSTANTS = {
"-You can now see what an Augmentation does and its price even while its locked<br><br>",
LatestUpdate:
"v0.21.0<br>" +
"-All scripts automatically killed for the sake of update compatibility<br>" +
"-IF YOUR GAME BREAKS, DO THE FOLLOWING: Options -> Soft Reset -> Save Game -> Reload Page. Sorry about that! <br>" +
"-Autocompletion for aliases - courtesy of Github user LTCNugget<br><br>" +
"-Added dynamic arrays. See Netscript documentation<br>" +
"-Added ability to pass arguments into scripts. See documentation<br>" +
"-The implementation/function signature of functions that deal with scripts have changed. Therefore, some old scripts might not " +
"work anymore. Some of these functions include run(), exec(), isRunning(), kill(), and some others I may have forgot about. " +
"Please check the updated Netscript documentation if you run into issues." +
"-Note that scripts are now uniquely identified by the script name and their arguments. For example, you can run " +
"a script using <br>run foodnstuff.script 1<br> and you can also run the same script with a different argument " +
"<br>run foodnstuff.script 2<br>These will be considered two different scripts. To kill the first script you must " +
"run <br>kill foodnstuff.script 1<br> and to kill the second you must run <br>kill foodnstuff.script 2<br> Similar concepts " +
"apply for Terminal Commands such as tail, and Netscript commands such as run(), exec(), kill(), isRunning(), etc.<br>" +
"-Added basic theme functionality using the 'theme' Terminal command - All credit goes to /u/0x726564646974 who implemented the awesome feature<br>" +
"-Optimized Script objects, which were causing save errors when the player had too many scripts<br>" +
"-Formula for determining exp gained from hacking was changed<br>" +
"-Fixed bug where you could purchase Darkweb items without TOR router<br>" +
"-Slightly increased cost multiplier for Home Computer RAM<br>" +
"-Fixed bug where you could hack too much money from a server (and bring its money available below zero)<br>" +
"-Changed tail command so that it brings up a display box with dynamic log contents. To get " +
"old functionality where the logs are printed to the Terminal, use the new 'check' command<br>" +
"-As a result of the change above, you can no longer call tail/check on scripts that are not running<br>" +
"-Added autocompletion for buying Programs in Darkweb<br>",
"v0.22.0 - Major rebalancing, optimization, and favor system<br>" +
"-Significantly nerfed most augmentations<br>" +
"-Almost every server with a required hacking level of 200 or more now has slightly randomized server parameters. This means that after every Augmentation " +
"purchase, the required hacking level, base security level, and growth factor of these servers will all be slightly different<br>" +
"-The hacking speed multiplier now increases rather than decreases. The hacking time is now divided by your hacking speed " +
"multiplier rather than multiplied. In other words, a higher hacking speed multiplier is better<br>" +
"-Servers now have a minimum server security, which is approximately one third of their starting ('base') server security<br>" +
"-If you do not steal any money from a server, then you gain hacking experience equal to the amount you would have gained " +
"had you failed the hack<br>" +
"-The effects of grow() were increased by 50%<br>" +
"-grow() and weaken() now give hacking experience based on the server's base security level, rather than a flat exp amount<br>" +
"-Slightly reduced amount of exp gained from hack(), weaken(), and grow()<br>" +
"-Rebalanced formulas that determine crime success<br>" +
"-Reduced RAM cost for multithreading a script. The RAM multiplier for each thread was reduced from 1.02 to 1.005<br>" +
"-Optimized Script objects so they take less space in the save file<br>" +
"-Added getServerBaseSecurityLevel() Netscript function<br>" +
"-New favor system for companies and factions. Earning reputation at a company/faction will give you favor for that entity when you " +
"reset after installing an Augmentation. This favor persists through the rest of the game. The more favor you have, the faster you will earn " +
"reputation with that faction<br>" +
"-You can no longer donate to a faction for reputation until you have 150 favor with that faction<br>" +
"-Added unalias Terminal command<br>" +
"-Changed requirements for endgame Factions<br>",
}

View File

@ -90,28 +90,24 @@ function determineCrimeSuccess(crime, moneyGained) {
}
function determineCrimeChanceShoplift() {
var chance = ((Player.strength / CONSTANTS.MaxSkillLevel +
Player.defense / CONSTANTS.MaxSkillLevel +
Player.dexterity / CONSTANTS.MaxSkillLevel +
Player.agility / CONSTANTS.MaxSkillLevel)) * 10;
var chance = ((Player.dexterity / CONSTANTS.MaxSkillLevel +
Player.agility / CONSTANTS.MaxSkillLevel)) * 20;
chance *= Player.crime_success_mult;
return Math.min(chance, 1);
}
function determineCrimeChanceMug() {
var chance = ((Player.strength / CONSTANTS.MaxSkillLevel +
Player.defense / CONSTANTS.MaxSkillLevel +
Player.dexterity / CONSTANTS.MaxSkillLevel +
Player.agility / CONSTANTS.MaxSkillLevel)) * 5;
var chance = ((2 *Player.strength / CONSTANTS.MaxSkillLevel +
0.5 * Player.defense / CONSTANTS.MaxSkillLevel +
2 * Player.dexterity / CONSTANTS.MaxSkillLevel +
0.5 * Player.agility / CONSTANTS.MaxSkillLevel)) * 5;
chance *= Player.crime_success_mult;
return Math.min(chance, 1);
}
function determineCrimeChanceDealDrugs() {
var chance = ((2*Player.charisma / CONSTANTS.MaxSkillLevel +
Player.strength / CONSTANTS.MaxSkillLevel +
Player.defense / CONSTANTS.MaxSkillLevel +
Player.dexterity / CONSTANTS.MaxSkillLevel +
var chance = ((3*Player.charisma / CONSTANTS.MaxSkillLevel +
2*Player.dexterity / CONSTANTS.MaxSkillLevel +
Player.agility / CONSTANTS.MaxSkillLevel));
chance *= Player.crime_success_mult;
return Math.min(chance, 1);
@ -128,10 +124,10 @@ function determineCrimeChanceTraffickArms() {
}
function determineCrimeChanceHomicide() {
var chance = ((Player.strength / CONSTANTS.MaxSkillLevel +
Player.defense / CONSTANTS.MaxSkillLevel +
Player.dexterity / CONSTANTS.MaxSkillLevel +
Player.agility / CONSTANTS.MaxSkillLevel));
var chance = ((2 * Player.strength / CONSTANTS.MaxSkillLevel +
2 * Player.defense / CONSTANTS.MaxSkillLevel +
0.5 * Player.dexterity / CONSTANTS.MaxSkillLevel +
0.5 * Player.agility / CONSTANTS.MaxSkillLevel));
chance *= Player.crime_success_mult;
return Math.min(chance, 1);
}
@ -139,9 +135,8 @@ function determineCrimeChanceHomicide() {
function determineCrimeChanceGrandTheftAuto() {
var chance = ((Player.hacking_skill / CONSTANTS.MaxSkillLevel +
Player.strength / CONSTANTS.MaxSkillLevel +
Player.defense / CONSTANTS.MaxSkillLevel +
4 * Player.dexterity / CONSTANTS.MaxSkillLevel +
Player.agility / CONSTANTS.MaxSkillLevel +
2 * Player.agility / CONSTANTS.MaxSkillLevel +
2 * Player.charisma / CONSTANTS.MaxSkillLevel)) / 8;
chance *= Player.crime_success_mult;
return Math.min(chance, 1);
@ -150,17 +145,15 @@ function determineCrimeChanceGrandTheftAuto() {
function determineCrimeChanceKidnap() {
var chance = ((Player.charisma / CONSTANTS.MaxSkillLevel +
Player.strength / CONSTANTS.MaxSkillLevel +
Player.defense / CONSTANTS.MaxSkillLevel +
Player.dexterity / CONSTANTS.MaxSkillLevel +
Player.agility / CONSTANTS.MaxSkillLevel)) / 6;
Player.agility / CONSTANTS.MaxSkillLevel)) / 5;
chance *= Player.crime_success_mult;
return Math.min(chance, 1);
}
function determineCrimeChanceAssassination() {
var chance = ((Player.strength / CONSTANTS.MaxSkillLevel +
Player.defense / CONSTANTS.MaxSkillLevel +
Player.dexterity / CONSTANTS.MaxSkillLevel +
2 * Player.dexterity / CONSTANTS.MaxSkillLevel +
Player.agility / CONSTANTS.MaxSkillLevel)) / 8;
chance *= Player.crime_success_mult;
return Math.min(chance, 1);

View File

@ -30,6 +30,9 @@ function Faction(name) {
//Multipliers for unlocking and purchasing augmentations
this.augmentationPriceMult = 1;
this.augmentationRepRequirementMult = 1;
//Faction favor
this.favor = 0;
};
Faction.prototype.setAugmentationMultipliers = function(price, rep) {
@ -41,6 +44,12 @@ Faction.prototype.setInfo = function(inf) {
this.info = inf;
}
Faction.prototype.gainFavor = function() {
if (this.favor == null || this.favor == undefined) {this.favor = 0;}
var gain = (this.playerReputation / CONSTANTS.FactionReputationToFavor);
this.favor += gain;
}
Faction.prototype.toJSON = function() {
return Generic_toJSON("Faction", this);
}
@ -59,115 +68,267 @@ AddToFactions = function(faction) {
Factions[name] = faction;
}
function factionExists(name) {
return Factions.hasOwnProperty(name);
}
//TODO Augmentation price and rep requirement mult are 1 for everything right now,
// This might change in the future for balance
initFactions = function() {
//Endgame
var Illuminati = new Faction("Illuminati");
Illuminati.setInfo(FactionInfo.IlluminatiInfo);
if (factionExists("Illuminati")) {
Illuminati.favor = Factions["Illuminati"].favor;
delete Factions["Illuminati"];
}
AddToFactions(Illuminati);
var Daedalus = new Faction("Daedalus");
Daedalus.setInfo(FactionInfo.DaedalusInfo);
if (factionExists("Daedalus")) {
Daedalus.favor = Factions["Daedalus"].favor;
delete Factions["Daedalus"];
}
AddToFactions(Daedalus);
var Covenant = new Faction("The Covenant");
Covenant.setInfo(FactionInfo.CovenantInfo);
if (factionExists("The Covenant")) {
Covenant.favor = Factions["The Covenant"].favor;
delete Factions["The Covenant"];
}
AddToFactions(Covenant);
//Megacorporations, each forms its own faction
var ECorp = new Faction("ECorp");
ECorp.setInfo(FactionInfo.ECorpInfo);
if (factionExists("ECorp")) {
ECorp.favor = Factions["ECorp"].favor;
delete Factions["ECorp"];
}
AddToFactions(ECorp);
var MegaCorp = new Faction("MegaCorp");
MegaCorp.setInfo(FactionInfo.MegaCorpInfo);
if (factionExists("MegaCorp")) {
MegaCorp.favor = Factions["MegaCorp"].favor;
delete Factions["MegaCorp"];
}
AddToFactions(MegaCorp);
var BachmanAndAssociates = new Faction("Bachman & Associates");
BachmanAndAssociates.setInfo(FactionInfo.BachmanAndAssociatesInfo);
if (factionExists("Bachman & Associates")) {
BachmanAndAssociates.favor = Factions["Bachman & Associates"].favor;
delete Factions["Bachman & Associates"];
}
AddToFactions(BachmanAndAssociates);
var BladeIndustries = new Faction("Blade Industries");
BladeIndustries.setInfo(FactionInfo.BladeIndustriesInfo);
if (factionExists("Blade Industries")) {
BladeIndustries.favor = Factions["Blade Industries"].favor;
delete Factions["Blade Industries"];
}
AddToFactions(BladeIndustries);
var NWO = new Faction("NWO");
NWO.setInfo(FactionInfo.NWOInfo);
if (factionExists("NWO")) {
NWO.favor = Factions["NWO"].favor;
delete Factions["NWO"];
}
AddToFactions(NWO);
var ClarkeIncorporated = new Faction("Clarke Incorporated");
ClarkeIncorporated.setInfo(FactionInfo.ClarkeIncorporatedInfo);
if (factionExists("Clarke Incorporated")) {
ClarkeIncorporated.favor = Factions["Clarke Incorporated"].favor;
delete Factions["Clarke Incorporated"];
}
AddToFactions(ClarkeIncorporated);
var OmniTekIncorporated = new Faction("OmniTek Incorporated");
OmniTekIncorporated.setInfo(FactionInfo.OmniTekIncorporatedInfo);
if (factionExists("OmniTek Incorporated")) {
OmniTekIncorporated.favor = Factions["OmniTek Incorporated"].favor;
delete Factions["OmniTek Incorporated"];
}
AddToFactions(OmniTekIncorporated);
var FourSigma = new Faction("Four Sigma");
FourSigma.setInfo(FactionInfo.FourSigmaInfo);
if (factionExists("Four Sigma")) {
FourSigma.favor = Factions["Four Sigma"].favor;
delete Factions["Four Sigma"];
}
AddToFactions(FourSigma);
var KuaiGongInternational = new Faction("KuaiGong International");
KuaiGongInternational.setInfo(FactionInfo.KuaiGongInternationalInfo);
if (factionExists("KuaiGong International")) {
KuaiGongInternational.favor = Factions["KuaiGong International"].favor;
delete Factions["KuaiGong International"];
}
AddToFactions(KuaiGongInternational);
//Other corporations
var FulcrumTechnologies = new Faction("Fulcrum Secret Technologies");
FulcrumTechnologies.setInfo(FactionInfo.FulcrumSecretTechnologiesInfo);
if (factionExists("Fulcrum Secret Technologies")) {
FulcrumTechnologies.favor = Factions["Fulcrum Secret Technologies"].favor;
delete Factions["Fulcrum Secret Technologies"];
}
AddToFactions(FulcrumTechnologies);
//Hacker groups
var BitRunners = new Faction("BitRunners");
BitRunners.setInfo(FactionInfo.BitRunnersInfo);
if (factionExists("BitRunners")) {
BitRunners.favor = Factions["BitRunners"].favor;
delete Factions["BitRunners"];
}
AddToFactions(BitRunners);
var BlackHand = new Faction("The Black Hand");
BlackHand.setInfo(FactionInfo.BlackHandInfo);
if (factionExists("The Black Hand")) {
BlackHand.favor = Factions["The Black Hand"].favor;
delete Factions["The Black Hand"];
}
AddToFactions(BlackHand);
var NiteSec = new Faction("NiteSec");
NiteSec.setInfo(FactionInfo.NiteSecInfo);
if (factionExists("NiteSec")) {
NiteSec.favor = Factions["NiteSec"].favor;
delete Factions["NiteSec"];
}
AddToFactions(NiteSec);
//City factions, essentially governments
var Chongqing = new Faction("Chongqing");
Chongqing.setInfo(FactionInfo.ChongqingInfo);
if (factionExists("Chongqing")) {
Chongqing.favor = Factions["Chongqing"].favor;
delete Factions["Chongqing"];
}
AddToFactions(Chongqing);
var Sector12 = new Faction("Sector-12");
Sector12.setInfo(FactionInfo.Sector12Info);
if (factionExists("Sector-12")) {
Sector12.favor = Factions["Sector-12"].favor;
delete Factions["Sector-12"];
}
AddToFactions(Sector12);
var NewTokyo = new Faction("New Tokyo");
NewTokyo.setInfo(FactionInfo.NewTokyoInfo);
if (factionExists("New Tokyo")) {
NewTokyo.favor = Factions["New Tokyo"].favor;
delete Factions["New Tokyo"];
}
AddToFactions(NewTokyo);
var Aevum = new Faction("Aevum");
Aevum.setInfo(FactionInfo.AevumInfo);
if (factionExists("Aevum")) {
Aevum.favor = Factions["Aevum"].favor;
delete Factions["Aevum"];
}
AddToFactions(Aevum);
var Ishima = new Faction("Ishima");
Ishima.setInfo(FactionInfo.IshimaInfo);
AddToFactions(Ishima);
Ishima.setInfo
var Volhaven = new Faction("Volhaven");
Volhaven.setInfo(FactionInfo.VolhavenInfo);
AddToFactions(Volhaven);
if (factionExists("Volhaven")) {
Volhaven.favor = Factions["Volhaven"].favor;
delete Factions["Volhaven"];
}
AddToFactions(Volhaven);(FactionInfo.IshimaInfo);
if (factionExists("Ishima")) {
Ishima.favor = Factions["Ishima"].favor;
delete Factions["Ishima"];
}
AddToFactions(Ishima);
//Criminal Organizations/Gangs
var SpeakersForTheDead = new Faction("Speakers for the Dead");
SpeakersForTheDead.setInfo(FactionInfo.SpeakersForTheDeadInfo);
if (factionExists("Speakers for the Dead")) {
SpeakersForTheDead.favor = Factions["Speakers for the Dead"].favor;
delete Factions["Speakers for the Dead"];
}
AddToFactions(SpeakersForTheDead);
var DarkArmy = new Faction("The Dark Army");
DarkArmy.setInfo(FactionInfo.DarkArmyInfo);
if (factionExists("The Dark Army")) {
DarkArmy.favor = Factions["The Dark Army"].favor;
delete Factions["The Dark Army"];
}
AddToFactions(DarkArmy);
var TheSyndicate = new Faction("The Syndicate");
TheSyndicate.setInfo(FactionInfo.TheSyndicateInfo);
if (factionExists("The Syndicate")) {
TheSyndicate.favor = Factions["The Syndicate"].favor;
delete Factions["The Syndicate"];
}
AddToFactions(TheSyndicate);
var Silhouette = new Faction("Silhouette");
Silhouette.setInfo(FactionInfo.SilhouetteInfo);
if (factionExists("Silhouette")) {
Silhouette.favor = Factions["Silhouette"].favor;
delete Factions["Silhouette"];
}
AddToFactions(Silhouette);
var Tetrads = new Faction("Tetrads"); //Low-medium level asian crime gang
Tetrads.setInfo(FactionInfo.TetradsInfo);
if (factionExists("Tetrads")) {
Tetrads.favor = Factions["Tetrads"].favor;
delete Factions["Tetrads"];
}
AddToFactions(Tetrads);
var SlumSnakes = new Faction("Slum Snakes"); //Low level crime gang
SlumSnakes.setInfo(FactionInfo.SlumSnakesInfo);
if (factionExists("Slum Snakes")) {
SlumSnakes.favor = Factions["Slum Snakes"].favor;
delete Factions["Slum Snakes"];
}
AddToFactions(SlumSnakes);
//Earlygame factions - factions the player will prestige with early on that don't
//belong in other categories
var Netburners = new Faction("Netburners");
Netburners.setInfo(FactionInfo.NetburnersInfo);
if (factionExists("Netburners")) {
Netburners.favor = Factions["Netburners"].favor;
delete Factions["Netburners"];
}
AddToFactions(Netburners);
var TianDiHui = new Faction("Tian Di Hui"); //Society of the Heaven and Earth
TianDiHui.setInfo(FactionInfo.TianDiHuiInfo);
if (factionExists("Tian Di Hui")) {
TianDiHui.favor = Factions["Tian Di Hui"].favor;
delete Factions["Tian Di Hui"];
}
AddToFactions(TianDiHui);
var CyberSec = new Faction("CyberSec");
CyberSec.setInfo(FactionInfo.CyberSecInfo);
if (factionExists("CyberSec")) {
CyberSec.favor = Factions["CyberSec"].favor;
delete Factions["CyberSec"];
}
AddToFactions(CyberSec);
}
@ -175,10 +336,6 @@ initFactions = function() {
//those requirements and will return an array of all factions that the Player should
//receive an invitation to
PlayerObject.prototype.checkForFactionInvitations = function() {
if (Engine.Debug) {
console.log("checkForFactionInvitations() called");
console.log("karma: " + this.karma);
}
invitedFactions = []; //Array which will hold all Factions th eplayer should be invited to
var company = Companies[this.companyName];
@ -190,39 +347,35 @@ PlayerObject.prototype.checkForFactionInvitations = function() {
//Illuminati
var illuminatiFac = Factions["Illuminati"];
if (!illuminatiFac.isBanned && !illuminatiFac.isMember && !illuminatiFac.alreadyInvited &&
this.numAugmentations >= 10 &&
this.money >= 10000000000 && this.total_money >= 20000000000 &&
this.hacking_skill >= 800 && this.total_hacking >= 7000 &&
this.strength >= 900 && this.total_strength >= 10000 &&
this.defense >= 900 && this.total_defense >= 10000 &&
this.dexterity >= 900 && this.total_dexterity >= 10000 &&
this.agility >= 900 && this.total_agility >= 10000) {
this.numAugmentations >= 30 &&
this.money >= 150000000000 &&
this.hacking_skill >= 1200 &&
this.strength >= 1000 && this.defense >= 1000 &&
this.dexterity >= 1000 && this.agility >= 1000) {
invitedFactions.push(illuminatiFac);
}
//Daedalus
var daedalusFac = Factions["Daedalus"];
if (!daedalusFac.isBanned && !daedalusFac.isMember && !daedalusFac.alreadyInvited &&
this.numAugmentations >= 15 &&
this.money >= 1000000000 && this.total_money >= 10000000000 &&
this.hacking_skill >= 1000 && this.total_hacking >= 10000 &&
this.strength >= 500 && this.total_strength >= 8000 &&
this.defense >= 500 && this.total_defense >= 8000 &&
this.dexterity >= 500 && this.total_dexterity >= 8000 &&
this.agility >= 500 && this.total_agility >= 8000) {
this.numAugmentations >= 30 &&
this.money >= 100000000000 &&
(this.hacking_skill >= 2500 ||
(this.strength >= 1500 && this.defense >= 1500 &&
this.dexterity >= 1500 && this.agility >= 1500))) {
invitedFactions.push(daedalusFac);
}
//The Covenant
var covenantFac = Factions["The Covenant"];
if (!covenantFac.isBanned && !covenantFac.isMember && !covenantFac.alreadyInvited &&
this.numAugmentations >= 12 &&
this.money >= 5000000000 && this.total_money >= 10000000000 &&
this.hacking_skill >= 850 && this.total_hacking >= 5000 &&
this.strength >= 850 && this.total_strength >= 5000 &&
this.defense >= 850 && this.total_defense >= 5000 &&
this.dexterity >= 850 && this.total_dexterity >= 5000 &&
this.agility >= 850 && this.total_agility >= 5000) {
this.numAugmentations >= 30 &&
this.money >= 75000000000 &&
this.hacking_skill >= 850 &&
this.strength >= 850 &&
this.defense >= 850 &&
this.dexterity >= 850 &&
this.agility >= 850) {
invitedFactions.push(covenantFac);
}
@ -558,7 +711,15 @@ displayFactionContent = function(factionName) {
var faction = Factions[factionName];
document.getElementById("faction-name").innerHTML = factionName;
document.getElementById("faction-info").innerHTML = "<i>" + faction.info + "</i>";
document.getElementById("faction-reputation").innerHTML = "Reputation: " + formatNumber(faction.playerReputation, 4);
document.getElementById("faction-reputation").innerHTML = "Reputation: " + formatNumber(faction.playerReputation, 4) +
"<span class='tooltiptext'>You will earn " +
formatNumber(faction.playerReputation / CONSTANTS.FactionReputationToFavor, 4) +
" faction favor upon resetting after installing an Augmentation</span>";
document.getElementById("faction-favor").innerHTML = "Faction Favor: " + formatNumber(faction.favor, 4) +
"<span class='tooltiptext'>Faction favor increases the rate at which " +
"you earn reputation for this faction by 1% per favor. Faction favor " +
"is gained whenever you reset after installing an Augmentation. The amount of " +
"favor you gain depends on how much reputation you have with the faction</span>";
var hackDiv = document.getElementById("faction-hack-div");
var fieldWorkDiv = document.getElementById("faction-fieldwork-div");
@ -626,7 +787,12 @@ displayFactionContent = function(factionName) {
});
if (faction.isMember) {
donateDiv.style.display = "inline";
if (faction.favor >= 150) {
donateDiv.style.display = "inline";
} else {
donateDiv.style.display = "none";
}
switch(faction.name) {
case "Illuminati":
hackDiv.style.display = "inline";

View File

@ -111,6 +111,10 @@ displayLocationContent = function() {
var jobTitle = document.getElementById("location-job-title");
var jobReputation = document.getElementById("location-job-reputation");
var companyFavor = document.getElementById("location-company-favor");
var locationTxtDiv1 = document.getElementById("location-text-divider-1");
var locationTxtDiv2 = document.getElementById("location-text-divider-2");
var locationTxtDiv3 = document.getElementById("location-text-divider-3");
var gymTrainStr = document.getElementById("location-gym-train-str");
var gymTrainDef = document.getElementById("location-gym-train-def");
@ -259,9 +263,21 @@ displayLocationContent = function() {
var company = Companies[loc];
jobTitle.style.display = "block";
jobReputation.style.display = "block";
jobReputation.style.display = "inline";
companyFavor.style.display = "inline";
locationTxtDiv1.style.display = "block";
locationTxtDiv2.style.display = "block";
locationTxtDiv3.style.display = "block";
jobTitle.innerHTML = "Job Title: " + Player.companyPosition.positionName;
jobReputation.innerHTML = "Company reputation: " + (company.playerReputation.toFixed(4)).toLocaleString();
jobReputation.innerHTML = "Company reputation: " + formatNumber(company.playerReputation, 4) +
"<span class='tooltiptext'>You will earn " +
formatNumber(company.playerReputation / CONSTANTS.CompanyReputationToFavor, 4) +
" faction favor upon resetting after installing an Augmentation</span>";
companyFavor.innerHTML = "Company Favor: " + formatNumber(company.favor, 4) +
"<span class='tooltiptext'>Company favor increases the rate at which " +
"you earn reputation for this company by 1% per favor. Company favor " +
"is gained whenever you reset after installing an Augmentation. The amount of " +
"favor you gain depends on how much reputation you have with the company</span>";
work.style.display = "block";
var currPos = Player.companyPosition;
@ -298,6 +314,10 @@ displayLocationContent = function() {
} else {
jobTitle.style.display = "none";
jobReputation.style.display = "none";
companyFavor.style.display = "none";
locationTxtDiv1.style.display = "none";
locationTxtDiv2.style.display = "none";
locationTxtDiv3.style.display = "none";
}
switch (loc) {

View File

@ -498,6 +498,22 @@ function evaluate(exp, workerScript) {
}, function(e) {
reject(e);
});
} else if (exp.func.value == "getServerBaseSecurityLevel") {
if (exp.args.length != 1) {
return reject(makeRuntimeRejectMsg(workerScript, "getServerBaseSecurityLevel() call has incorrect number of arguments. Takes 1 arguments"));
}
var ipPromise = evaluate(exp.args[0], workerScript);
ipPromise.then(function(ip) {
var server = getServer(ip);
if (server == null) {
workerScript.scriptRef.log("getServerBaseSecurityLevel() failed. Invalid IP or hostname passed in: " + ip);
return reject(makeRuntimeRejectMsg(workerScript, "Invalid IP or hostname passed into getServerBaseSecurityLevel() command"));;
}
workerScript.scriptRef.log("getServerBaseSecurityLevel() returned " + formatNumber(server.baseDifficulty, 3) + " for " + server.hostname);
resolve(server.baseDifficulty);
}, function(e) {
reject(e);
});
} else if (exp.func.value == "getServerRequiredHackingLevel") {
if (exp.args.length != 1) {
return reject(makeRuntimeRejectMsg(workerScript, "getServerRequiredHackingLevel() call has incorrect number of arguments. Takes 1 argument"));
@ -971,7 +987,7 @@ function runScriptFromScript(server, scriptname, args, workerScript, threads=1)
//Check for admin rights and that there is enough RAM availble to run
var script = server.scripts[i];
var ramUsage = script.ramUsage;
ramUsage = ramUsage * threads * Math.pow(1.02, threads-1);
ramUsage = ramUsage * threads * Math.pow(CONSTANTS.MultithreadingRAMCost, threads-1);
var ramAvailable = server.maxRam - server.ramUsed;
if (server.hasAdminRights == false) {
@ -1023,7 +1039,7 @@ function scriptCalculateHackingChance(server) {
function scriptCalculateHackingTime(server) {
var difficultyMult = server.requiredHackingSkill * server.hackDifficulty;
var skillFactor = (2.5 * difficultyMult + 500) / (Player.hacking_skill + 50);
var hackingTime = skillFactor * Player.hacking_speed_mult * 5; //This is in seconds
var hackingTime = 5 * skillFactor / Player.hacking_speed_mult; //This is in seconds
return hackingTime;
}
@ -1032,7 +1048,7 @@ function scriptCalculateExpGain(server) {
if (server.baseDifficulty == null) {
server.baseDifficulty = server.hackDifficulty;
}
return (server.baseDifficulty * Player.hacking_exp_mult * 0.5 + 4);
return (server.baseDifficulty * Player.hacking_exp_mult * 0.5 + 2);
}
//The same as Player's calculatePercentMoneyHacked() function but takes in the server as an argument
@ -1049,7 +1065,7 @@ function scriptCalculatePercentMoneyHacked(server) {
function scriptCalculateGrowTime(server) {
var difficultyMult = server.requiredHackingSkill * server.hackDifficulty;
var skillFactor = (2.5 * difficultyMult + 500) / (Player.hacking_skill + 50);
var growTime = skillFactor * Player.hacking_speed_mult * 16; //This is in seconds
var growTime = 16 * skillFactor / Player.hacking_speed_mult; //This is in seconds
return growTime * 1000;
}
@ -1057,6 +1073,6 @@ function scriptCalculateGrowTime(server) {
function scriptCalculateWeakenTime(server) {
var difficultyMult = server.requiredHackingSkill * server.hackDifficulty;
var skillFactor = (2.5 * difficultyMult + 500) / (Player.hacking_skill + 50);
var weakenTime = skillFactor * Player.hacking_speed_mult * 40; //This is in seconds
var weakenTime = 40 * skillFactor / Player.hacking_speed_mult; //This is in seconds
return weakenTime * 1000;
}

View File

@ -188,7 +188,10 @@ function netscriptHack(exp, workerScript) {
moneyGained = Math.floor(server.moneyAvailable * moneyGained) * threads;
//Over-the-top safety checks
if (moneyGained <= 0) {moneyGained = 0;}
if (moneyGained <= 0) {
moneyGained = 0;
expGainedOnSuccess = expGainedOnFailure;
}
if (moneyGained > server.moneyAvailable) {moneyGained = server.moneyAvailable;}
server.moneyAvailable -= moneyGained;
if (server.moneyAvailable < 0) {server.moneyAvailable = 0;}
@ -253,7 +256,10 @@ function netscriptGrow(exp, workerScript) {
server.moneyAvailable += (1 * threads); //It can be grown even if it has no money
var growthPercentage = processSingleServerGrowth(server, 450 * threads);
workerScript.scriptRef.recordGrow(server.ip, threads);
var expGain = 0.5 * Player.hacking_exp_mult * threads;
var expGain = scriptCalculateExpGain(server) * threads;
if (growthPercentage == 1) {
expGain = 0;
}
workerScript.scriptRef.log("Available money on " + server.hostname + " grown by "
+ formatNumber(growthPercentage*100 - 100, 6) + "%. Gained " +
formatNumber(expGain, 4) + " hacking exp (t=" + threads +")");
@ -303,7 +309,7 @@ function netscriptWeaken(exp, workerScript) {
if (env.stopFlag) {return Promise.reject(workerScript);}
server.weaken(CONSTANTS.ServerWeakenAmount * threads);
workerScript.scriptRef.recordWeaken(server.ip, threads);
var expGain = 3 * Player.hacking_exp_mult * threads;
var expGain = scriptCalculateExpGain(server) * threads;
workerScript.scriptRef.log("Server security level on " + server.hostname + " weakened to " + server.hackDifficulty +
". Gained " + formatNumber(expGain, 4) + " hacking exp (t=" + threads + ")");
workerScript.scriptRef.onlineExpGained += expGain;

View File

@ -142,7 +142,8 @@ function addWorkerScript(runningScriptObj, server) {
} else {
runningScriptObj.threads = 1;
}
var ramUsage = runningScriptObj.scriptRef.ramUsage * threads * Math.pow(1.02, threads-1);
var ramUsage = runningScriptObj.scriptRef.ramUsage * threads
* Math.pow(CONSTANTS.MultithreadingRAMCost, threads-1);
server.ramUsed += ramUsage;
//Create the WorkerScript

View File

@ -233,7 +233,7 @@ PlayerObject.prototype.calculateHackingChance = function() {
PlayerObject.prototype.calculateHackingTime = function() {
var difficultyMult = this.getCurrentServer().requiredHackingSkill * this.getCurrentServer().hackDifficulty;
var skillFactor = (2.5 * difficultyMult + 200) / (this.hacking_skill + 100);
return skillFactor * this.hacking_speed_mult * 5;
return 5 * skillFactor / this.hacking_speed_mult;
}
//Calculates the PERCENTAGE of a server's money that the player will hack from the server if successful
@ -259,7 +259,7 @@ PlayerObject.prototype.calculateExpGain = function() {
if (s.baseDifficulty == null) {
s.baseDifficulty = s.hackDifficulty;
}
return (s.baseDifficulty * this.hacking_exp_mult * 0.5 + 4);
return (s.baseDifficulty * this.hacking_exp_mult * 0.5 + 2);
}
//Hack/Analyze a server. Return the amount of time the hack will take. This lets the Terminal object know how long to disable itself for
@ -635,6 +635,11 @@ PlayerObject.prototype.finishFactionWork = function(cancelled, faction) {
}
PlayerObject.prototype.startFactionWork = function(faction) {
//Update reputation gain rate to account for faction favor
var favorMult = 1 + (faction.favor / 100);
if (isNaN(favorMult)) {favorMult = 1;}
this.workRepGainRate *= favorMult;
this.isWorking = true;
this.workType = CONSTANTS.WorkTypeFaction;
this.currentWorkFactionName = faction.name;
@ -655,8 +660,8 @@ PlayerObject.prototype.startFactionWork = function(faction) {
PlayerObject.prototype.startFactionHackWork = function(faction) {
this.resetWorkStatus();
this.workHackExpGainRate = .175 * this.hacking_exp_mult;
this.workRepGainRate = this.hacking_skill / CONSTANTS.MaxSkillLevel * this.faction_rep_mult;
this.workHackExpGainRate = .15 * this.hacking_exp_mult;
this.workRepGainRate = 0.9 * this.hacking_skill / CONSTANTS.MaxSkillLevel * this.faction_rep_mult;
this.factionWorkType = CONSTANTS.FactionWorkHacking;
this.currentWorkFactionDescription = "carrying out hacking contracts";
@ -716,6 +721,11 @@ PlayerObject.prototype.workForFaction = function(numCycles) {
break;
}
//Update reputation gain rate to account for faction favor
var favorMult = 1 + (faction.favor / 100);
if (isNaN(favorMult)) {favorMult = 1;}
this.workRepGainRate *= favorMult;
this.workHackExpGained += this.workHackExpGainRate * numCycles;
this.workStrExpGained += this.workStrExpGainRate * numCycles;
this.workDefExpGained += this.workDefExpGainRate * numCycles;
@ -805,29 +815,32 @@ PlayerObject.prototype.getWorkChaExpGain = function() {
//Reputation gained per game cycle
PlayerObject.prototype.getWorkRepGain = function() {
var company = Companies[this.companyName];
var jobPerformance = this.companyPosition.calculateJobPerformance(this.hacking_skill, this.strength,
this.defense, this.dexterity,
this.agility, this.charisma);
return jobPerformance * this.company_rep_mult;
this.agility, this.charisma);
//Update reputation gain rate to account for company favor
var favorMult = 1 + (company.favor / 100);
if (isNaN(favorMult)) {favorMult = 1;}
return jobPerformance * this.company_rep_mult * favorMult;
}
PlayerObject.prototype.getFactionSecurityWorkRepGain = function() {
var t = (this.hacking_skill / CONSTANTS.MaxSkillLevel +
this.strength / CONSTANTS.MaxSkillLevel +
this.defense / CONSTANTS.MaxSkillLevel +
this.dexterity / CONSTANTS.MaxSkillLevel +
this.agility / CONSTANTS.MaxSkillLevel) / 5;
var t = 0.9 * (this.hacking_skill / CONSTANTS.MaxSkillLevel +
this.strength / CONSTANTS.MaxSkillLevel +
this.defense / CONSTANTS.MaxSkillLevel +
this.dexterity / CONSTANTS.MaxSkillLevel +
this.agility / CONSTANTS.MaxSkillLevel) / 5;
return t * this.faction_rep_mult;
}
PlayerObject.prototype.getFactionFieldWorkRepGain = function() {
var t = (this.hacking_skill / CONSTANTS.MaxSkillLevel +
this.strength / CONSTANTS.MaxSkillLevel +
this.defense / CONSTANTS.MaxSkillLevel +
this.dexterity / CONSTANTS.MaxSkillLevel +
this.agility / CONSTANTS.MaxSkillLevel +
this.charisma / CONSTANTS.MaxSkillLevel) / 6;
var t = 0.9 * (this.hacking_skill / CONSTANTS.MaxSkillLevel +
this.strength / CONSTANTS.MaxSkillLevel +
this.defense / CONSTANTS.MaxSkillLevel +
this.dexterity / CONSTANTS.MaxSkillLevel +
this.agility / CONSTANTS.MaxSkillLevel +
this.charisma / CONSTANTS.MaxSkillLevel) / 6;
return t * this.faction_rep_mult;
}

View File

@ -166,21 +166,19 @@ function prestigeAugmentation() {
Player.hacknetNodes.length = 0;
Player.totalHacknetNodeProduction = 0;
//Delete Companies
//Gain favor for Companies
for (var member in Companies) {
if (Companies.hasOwnProperty(member)) {
delete Companies[member];
Companies[member].gainFavor();
}
}
Companies = {};
//Reset Factions
//Gain favor for factions
for (var member in Factions) {
if (Factions.hasOwnProperty(member)) {
delete Factions[member];
Factions[member].gainFavor();
}
}
Factions = {};
//Stop a Terminal action if there is onerror
if (Engine._actionInProgress) {
@ -200,5 +198,7 @@ function prestigeAugmentation() {
//Messages
initMessages();
Player.playtimeSinceLastAug = 0;
Engine.loadTerminalContent();
}

View File

@ -17,7 +17,21 @@ function BitburnerSaveObject() {
BitburnerSaveObject.prototype.saveGame = function() {
this.PlayerSave = JSON.stringify(Player);
this.AllServersSave = JSON.stringify(AllServers);
//Delete all logs from all running scripts
var TempAllServers = JSON.parse(JSON.stringify(AllServers), Reviver);
//var TempAllServers = jQuery.extend(true, {}, AllServers); //Deep copy
for (var ip in TempAllServers) {
var server = TempAllServers[ip];
if (server == null) {continue;}
for (var i = 0; i < server.runningScripts.length; ++i) {
var runningScriptObj = server.runningScripts[i];
runningScriptObj.logs.length = 0;
runningScriptObj.logs = [];
}
}
this.AllServersSave = JSON.stringify(TempAllServers);
this.CompaniesSave = JSON.stringify(Companies);
this.FactionsSave = JSON.stringify(Factions);
this.SpecialServerIpsSave = JSON.stringify(SpecialServerIps);
@ -69,7 +83,7 @@ loadGame = function(saveObj) {
try {
var ver = JSON.parse(saveObj.VersionSave, Reviver);
if (ver != CONSTANTS.Version) {
if (CONSTANTS.Version == "0.21.0") {
if (CONSTANTS.Version == "0.21.0" || CONSTANTS.Version == "0.22.0") {
dialogBoxCreate("All scripts automatically killed for the sake of compatibility " +
"with new version. If the game is still broken, try the following: " +
"Options -> Soft Reset -> Save Game -> Reload page. If that STILL " +

View File

@ -245,13 +245,15 @@ scriptCalculateOfflineProduction = function(runningScriptObj) {
var confidence = (runningScriptObj.onlineRunningTime) / 14400;
if (confidence >= 1) {confidence = 1;}
//Data map: [MoneyStolen, NumTimesHacked, NumTimesGrown, NumTimesWeaken]
//Grow
for (var ip in runningScriptObj.numTimesGrowMap) {
if (runningScriptObj.numTimesGrowMap.hasOwnProperty(ip)) {
if (runningScriptObj.numTimesGrowMap[ip] == 0 || runningScriptObj.numTimesGrowMap[ip] == null) {continue;}
for (var ip in runningScriptObj.dataMap) {
if (runningScriptObj.dataMap.hasOwnProperty(ip)) {
if (runningScriptObj.dataMap[ip][2] == 0 || runningScriptObj.dataMap[ip][2] == null) {continue;}
var serv = AllServers[ip];
if (serv == null) {continue;}
var timesGrown = Math.round(0.5 * runningScriptObj.numTimesGrowMap[ip] / runningScriptObj.onlineRunningTime * timePassed);
var timesGrown = Math.round(0.5 * runningScriptObj.dataMap[ip][2] / runningScriptObj.onlineRunningTime * timePassed);
console.log(runningScriptObj.filename + " called grow() on " + serv.hostname + " " + timesGrown + " times while offline");
runningScriptObj.log("Called grow() on " + serv.hostname + " " + timesGrown + " times while offline");
var growth = processSingleServerGrowth(serv, timesGrown * 450);
@ -260,12 +262,12 @@ scriptCalculateOfflineProduction = function(runningScriptObj) {
}
var totalOfflineProduction = 0;
for (var ip in runningScriptObj.moneyStolenMap) {
if (runningScriptObj.moneyStolenMap.hasOwnProperty(ip)) {
if (runningScriptObj.moneyStolenMap[ip] == 0 || runningScriptObj.moneyStolenMap[ip] == null) {continue;}
for (var ip in runningScriptObj.dataMap) {
if (runningScriptObj.dataMap.hasOwnProperty(ip)) {
if (runningScriptObj.dataMap[ip][0] == 0 || runningScriptObj.dataMap[ip][0] == null) {continue;}
var serv = AllServers[ip];
if (serv == null) {continue;}
var production = 0.5 * runningScriptObj.moneyStolenMap[ip] / runningScriptObj.onlineRunningTime * timePassed;
var production = 0.5 * runningScriptObj.dataMap[ip][0] / runningScriptObj.onlineRunningTime * timePassed;
production *= confidence;
if (production > serv.moneyAvailable) {
production = serv.moneyAvailable;
@ -276,6 +278,7 @@ scriptCalculateOfflineProduction = function(runningScriptObj) {
runningScriptObj.log(runningScriptObj.filename + " generated $" + production + " while offline by hacking " + serv.hostname);
serv.moneyAvailable -= production;
if (serv.moneyAvailable < 0) {serv.moneyAvailable = 0;}
if (isNaN(serv.moneyAvailable)) {serv.moneyAvailable = 0;}
}
}
@ -292,12 +295,12 @@ scriptCalculateOfflineProduction = function(runningScriptObj) {
runningScriptObj.offlineExpGained += expGain;
//Fortify a server's security based on how many times it was hacked
for (var ip in runningScriptObj.numTimesHackMap) {
if (runningScriptObj.numTimesHackMap.hasOwnProperty(ip)) {
if (runningScriptObj.numTimesHackMap[ip] == 0 || runningScriptObj.numTimesHackMap[ip] == null) {continue;}
for (var ip in runningScriptObj.dataMap) {
if (runningScriptObj.dataMap.hasOwnProperty(ip)) {
if (runningScriptObj.dataMap[ip][1] == 0 || runningScriptObj.dataMap[ip][1] == null) {continue;}
var serv = AllServers[ip];
if (serv == null) {continue;}
var timesHacked = Math.round(0.5 * runningScriptObj.numTimesHackMap[ip] / runningScriptObj.onlineRunningTime * timePassed);
var timesHacked = Math.round(0.5 * runningScriptObj.dataMap[ip][1] / runningScriptObj.onlineRunningTime * timePassed);
console.log(runningScriptObj.filename + " hacked " + serv.hostname + " " + timesHacked + " times while offline");
runningScriptObj.log("Hacked " + serv.hostname + " " + timesHacked + " times while offline");
serv.fortify(CONSTANTS.ServerFortifyAmount * timesHacked);
@ -305,12 +308,12 @@ scriptCalculateOfflineProduction = function(runningScriptObj) {
}
//Weaken
for (var ip in runningScriptObj.numTimesWeakenMap) {
if (runningScriptObj.numTimesWeakenMap.hasOwnProperty(ip)) {
if (runningScriptObj.numTimesWeakenMap[ip] == 0 || runningScriptObj.numTimesWeakenMap[ip] == null) {continue;}
for (var ip in runningScriptObj.dataMap) {
if (runningScriptObj.dataMap.hasOwnProperty(ip)) {
if (runningScriptObj.dataMap[ip][3] == 0 || runningScriptObj.dataMap[ip][3] == null) {continue;}
var serv = AllServers[ip];
if (serv == null) {continue;}
var timesWeakened = Math.round(0.5 * runningScriptObj.numTimesWeakenMap[ip] / runningScriptObj.onlineRunningTime * timePassed);
var timesWeakened = Math.round(0.5 * runningScriptObj.dataMap[ip][3] / runningScriptObj.onlineRunningTime * timePassed);
console.log(runningScriptObj.filename + " called weaken() on " + serv.hostname + " " + timesWeakened + " times while offline");
runningScriptObj.log("Called weaken() on " + serv.hostname + " " + timesWeakened + " times while offline");
serv.weaken(CONSTANTS.ServerWeakenAmount * timesWeakened);
@ -351,10 +354,8 @@ function RunningScript(script, args) {
this.threads = 1;
this.moneyStolenMap = new AllServersMap();
this.numTimesHackMap = new AllServersMap();
this.numTimesGrowMap = new AllServersMap();
this.numTimesWeakenMap = new AllServersMap();
//[MoneyStolen, NumTimesHacked, NumTimesGrown, NumTimesWeaken]
this.dataMap = new AllServersMap([0, 0, 0, 0]);
}
RunningScript.prototype.reset = function() {
@ -387,30 +388,30 @@ RunningScript.prototype.displayLog = function() {
//Update the moneyStolen and numTimesHack maps when hacking
RunningScript.prototype.recordHack = function(serverIp, moneyGained, n=1) {
if (this.moneyStolenMap == null) {
this.moneyStolenMap = new AllServersMap();
if (this.dataMap == null) {
//[MoneyStolen, NumTimesHacked, NumTimesGrown, NumTimesWeaken]
this.dataMap = new AllServersMap([0, 0, 0, 0]);
}
if (this.numTimesHackMap == null) {
this.numTimesHackMap = new AllServersMap();
}
this.moneyStolenMap[serverIp] += moneyGained;
this.numTimesHackMap[serverIp] += n;
this.dataMap[serverIp][0] += moneyGained;
this.dataMap[serverIp][1] += n;
}
//Update the grow map when calling grow()
RunningScript.prototype.recordGrow = function(serverIp, n=1) {
if (this.numTimesGrowMap == null) {
this.numTimesGrowMap = new AllServersMap();
if (this.dataMap == null) {
//[MoneyStolen, NumTimesHacked, NumTimesGrown, NumTimesWeaken]
this.dataMap = new AllServersMap([0, 0, 0, 0]);
}
this.numTimesGrowMap[serverIp] += n;
this.dataMap[serverIp][2] += n;
}
//Update the weaken map when calling weaken() {
RunningScript.prototype.recordWeaken = function(serverIp, n=1) {
if (this.numTimesWeakenMap == null) {
this.numTimesWeakenMap = new AllServersMap();
if (this.dataMap == null) {
//[MoneyStolen, NumTimesHacked, NumTimesGrown, NumTimesWeaken]
this.dataMap = new AllServersMap([0, 0, 0, 0]);
}
this.numTimesWeakenMap[serverIp] += n;
this.dataMap[serverIp][3] += n;
}
RunningScript.prototype.toJSON = function() {
@ -423,12 +424,15 @@ RunningScript.fromJSON = function(value) {
}
//Creates an object that creates a map/dictionary with the IP of each existing server as
//a key, and 0 as the value. This is used to keep track of how much money a script
//hacks from that server
function AllServersMap() {
//a key. Initializes every key with a specified value that can either by a number or an array
function AllServersMap(arr=false) {
for (var ip in AllServers) {
if (AllServers.hasOwnProperty(ip)) {
this[ip] = 0;
if (arr) {
this[ip] = [0, 0, 0, 0];
} else {
this[ip] = 0;
}
}
}
}

View File

@ -83,7 +83,7 @@ Server.prototype.setHackingParameters = function(requiredHackingSkill, moneyAvai
this.moneyMax = 50 * moneyAvailable;
this.hackDifficulty = hackDifficulty;
this.baseDifficulty = hackDifficulty;
this.minDifficulty = Math.max(1, hackDifficulty - 25);
this.minDifficulty = Math.max(1, Math.round(hackDifficulty / 3));
this.serverGrowth = serverGrowth;
}
@ -122,6 +122,7 @@ Server.prototype.fortify = function(amt) {
Server.prototype.weaken = function(amt) {
this.hackDifficulty -= amt;
if (this.hackDifficulty < this.minDifficulty) {this.hackDifficulty = this.minDifficulty;}
if (this.hackDifficulty < 1) {this.hackDifficulty = 1;}
}
@ -140,277 +141,277 @@ initForeignServers = function() {
//MegaCorporations
var ECorpServer = new Server();
ECorpServer.init(createRandomIp(), "ecorp", "ECorp", true, false, false, false, 0);
ECorpServer.setHackingParameters(900, 100000000000, 99, 99);
ECorpServer.setHackingParameters(getRandomInt(900, 950), 100000000000, 99, 99);
ECorpServer.setPortProperties(5);
AddToAllServers(ECorpServer);
var MegaCorpServer = new Server();
MegaCorpServer.init(createRandomIp(), "megacorp", "MegaCorp", true, false, false, false, 0);
MegaCorpServer.setHackingParameters(900, 80000000000, 99, 99);
MegaCorpServer.setHackingParameters(getRandomInt(900, 950), 80000000000, 99, 99);
MegaCorpServer.setPortProperties(5);
AddToAllServers(MegaCorpServer);
var BachmanAndAssociatesServer = new Server();
BachmanAndAssociatesServer.init(createRandomIp(), "b-and-a", "Bachman & Associates", true, false, false, false, 0);
BachmanAndAssociatesServer.setHackingParameters(900, 32000000000, 80, 70);
BachmanAndAssociatesServer.setHackingParameters(getRandomInt(875, 925), 32000000000, getRandomInt(75, 85), getRandomInt(65, 75));
BachmanAndAssociatesServer.setPortProperties(5);
AddToAllServers(BachmanAndAssociatesServer);
var BladeIndustriesServer = new Server();
BladeIndustriesServer.init(createRandomIp(), "blade", "Blade Industries", true, false, false, false, 0);
BladeIndustriesServer.setHackingParameters(900, 20000000000, 90, 65);
BladeIndustriesServer.setHackingParameters(getRandomInt(875, 925), 20000000000, getRandomInt(90, 95), getRandomInt(60, 75));
BladeIndustriesServer.setPortProperties(5);
AddToAllServers(BladeIndustriesServer);
var NWOServer = new Server();
NWOServer.init(createRandomIp(), "nwo", "New World Order", true, false, false, false, 0);
NWOServer.setHackingParameters(900, 40000000000, 99, 80);
NWOServer.setHackingParameters(getRandomInt(900, 920), 40000000000, 99, getRandomInt(75, 85));
NWOServer.setPortProperties(5);
AddToAllServers(NWOServer);
var ClarkeIncorporatedServer = new Server();
ClarkeIncorporatedServer.init(createRandomIp(), "clarkeinc", "Clarke Incorporated", true, false, false, false, 0);
ClarkeIncorporatedServer.setHackingParameters(900, 15000000000, 50, 60);
ClarkeIncorporatedServer.setHackingParameters(getRandomInt(875, 950), 15000000000, getRandomInt(50, 60), getRandomInt(50, 70));
ClarkeIncorporatedServer.setPortProperties(5);
AddToAllServers(ClarkeIncorporatedServer);
var OmniTekIncorporatedServer = new Server();
OmniTekIncorporatedServer.init(createRandomIp(), "omnitek", "OmniTek Incorporated", true, false, false, false, 0);
OmniTekIncorporatedServer.setHackingParameters(900, 50000000000, 95, 99);
OmniTekIncorporatedServer.setHackingParameters(getRandomInt(870, 930), 50000000000, getRandomInt(90, 99), getRandomInt(95, 99));
OmniTekIncorporatedServer.setPortProperties(5);
AddToAllServers(OmniTekIncorporatedServer);
var FourSigmaServer = new Server();
FourSigmaServer.init(createRandomIp(), "4sigma", "FourSigma", true, false, false, false, 0);
FourSigmaServer.setHackingParameters(900, 25000000000, 60, 80);
FourSigmaServer.setHackingParameters(getRandomInt(875, 925), 25000000000, getRandomInt(60, 70), getRandomInt(75, 85));
FourSigmaServer.setPortProperties(5);
AddToAllServers(FourSigmaServer);
var KuaiGongInternationalServer = new Server();
KuaiGongInternationalServer.init(createRandomIp(), "kuai-gong", "KuaiGong International", true, false, false, false, 0);
KuaiGongInternationalServer.setHackingParameters(925, 75000000000, 99, 99);
KuaiGongInternationalServer.setHackingParameters(getRandomInt(900, 950), 75000000000, getRandomInt(95, 99), getRandomInt(90, 99));
KuaiGongInternationalServer.setPortProperties(5);
AddToAllServers(KuaiGongInternationalServer);
//Technology and communications companies (large targets)
var FulcrumTechnologiesServer = new Server();
FulcrumTechnologiesServer.init(createRandomIp(), "fulcrumtech", "Fulcrum Technologies", true, false, false, false, 64);
FulcrumTechnologiesServer.setHackingParameters(900, 2000000000, 90, 85);
FulcrumTechnologiesServer.setHackingParameters(getRandomInt(900, 1000), 2000000000, getRandomInt(85, 95), getRandomInt(80, 99));
FulcrumTechnologiesServer.setPortProperties(5);
AddToAllServers(FulcrumTechnologiesServer);
var FulcrumSecretTechnologiesServer = new Server();
FulcrumSecretTechnologiesServer.init(createRandomIp(), "fulcrumassets", "Fulcrum Technologies Assets", true, false, false, false, 0);
FulcrumSecretTechnologiesServer.setHackingParameters(999, 1000000, 99, 1);
FulcrumSecretTechnologiesServer.setHackingParameters(getRandomInt(1000, 1250), 1000000, 99, 1);
FulcrumSecretTechnologiesServer.setPortProperties(5);
AddToAllServers(FulcrumSecretTechnologiesServer);
SpecialServerIps.addIp(SpecialServerNames.FulcrumSecretTechnologies, FulcrumSecretTechnologiesServer.ip);
var StormTechnologiesServer = new Server();
StormTechnologiesServer.init(createRandomIp(), "stormtech", "Storm Technologies", true, false, false, false, 0);
StormTechnologiesServer.setHackingParameters(850, 1500000000, 85, 80);
StormTechnologiesServer.setHackingParameters(getRandomInt(825, 875), 1500000000, getRandomInt(80, 90), getRandomInt(70, 90));
StormTechnologiesServer.setPortProperties(5);
AddToAllServers(StormTechnologiesServer);
var DefCommServer = new Server();
DefCommServer.init(createRandomIp(), "defcomm", "DefComm", true, false, false, false, 0);
DefCommServer.setHackingParameters(825, 900000000, 90, 60);
DefCommServer.setHackingParameters(getRandomInt(800, 850), 900000000, getRandomInt(85, 95), getRandomInt(50, 70));
DefCommServer.setPortProperties(5);
AddToAllServers(DefCommServer);
var InfoCommServer = new Server();
InfoCommServer.init(createRandomIp(), "infocomm", "InfoComm", true, false, false, false, 0);
InfoCommServer.setHackingParameters(830, 750000000, 80, 50);
InfoCommServer.setHackingParameters(getRandomInt(800, 850), 750000000, getRandomInt(70, 90), getRandomInt(35, 75));
InfoCommServer.setPortProperties(5);
AddToAllServers(InfoCommServer);
var HeliosLabsServer = new Server();
HeliosLabsServer.init(createRandomIp(), "helios", "Helios Labs", true, false, false, false, 0);
HeliosLabsServer.setHackingParameters(800, 500000000, 90, 75);
HeliosLabsServer.setHackingParameters(getRandomInt(775, 825), 500000000, getRandomInt(85, 95), getRandomInt(70, 80));
HeliosLabsServer.setPortProperties(5);
AddToAllServers(HeliosLabsServer);
var VitaLifeServer = new Server();
VitaLifeServer.init(createRandomIp(), "vitalife", "VitaLife", true, false, false, false, 32);
VitaLifeServer.setHackingParameters(775, 800000000, 85, 70);
VitaLifeServer.setHackingParameters(getRandomInt(750, 800), 800000000, getRandomInt(80, 90), getRandomInt(60, 80));
VitaLifeServer.setPortProperties(5);
AddToAllServers(VitaLifeServer);
var IcarusMicrosystemsServer = new Server();
IcarusMicrosystemsServer.init(createRandomIp(), "icarus", "Icarus Microsystems", true, false, false, false, 0);
IcarusMicrosystemsServer.setHackingParameters(810, 1100000000, 90, 90);
IcarusMicrosystemsServer.setHackingParameters(getRandomInt(800, 820), 1100000000, getRandomInt(85, 95), getRandomInt(85, 95));
IcarusMicrosystemsServer.setPortProperties(5);
AddToAllServers(IcarusMicrosystemsServer);
var UniversalEnergyServer = new Server();
UniversalEnergyServer.init(createRandomIp(), "univ-energy", "Universal Energy", true, false, false, false, 32);
UniversalEnergyServer.setHackingParameters(790, 1500000000, 85, 85);
UniversalEnergyServer.setHackingParameters(getRandomInt(780, 800), 1500000000, getRandomInt(80, 90), getRandomInt(80, 90));
UniversalEnergyServer.setPortProperties(4);
AddToAllServers(UniversalEnergyServer);
var TitanLabsServer = new Server();
TitanLabsServer.init(createRandomIp(), "titan-labs", "Titan Laboratories", true, false, false, false, 32);
TitanLabsServer.setHackingParameters(795, 1000000000, 75, 70);
TitanLabsServer.setHackingParameters(getRandomInt(790, 800), 1000000000, getRandomInt(70, 80), getRandomInt(60, 80));
TitanLabsServer.setPortProperties(5);
AddToAllServers(TitanLabsServer);
var MicrodyneTechnologiesServer = new Server();
MicrodyneTechnologiesServer.init(createRandomIp(), "microdyne", "Microdyne Technologies", true, false, false, false, 16);
MicrodyneTechnologiesServer.setHackingParameters(800, 900000000, 70, 80);
MicrodyneTechnologiesServer.setHackingParameters(getRandomInt(780, 820), 900000000, getRandomInt(65, 75), getRandomInt(70, 90));
MicrodyneTechnologiesServer.setPortProperties(5);
AddToAllServers(MicrodyneTechnologiesServer);
var TaiYangDigitalServer = new Server();
TaiYangDigitalServer.init(createRandomIp(), "taiyang-digital", "Taiyang Digital", true, false, false, false, 0);
TaiYangDigitalServer.setHackingParameters(850, 1100000000, 75, 75);
TaiYangDigitalServer.setHackingParameters(getRandomInt(800, 900), 1100000000, getRandomInt(70, 80), getRandomInt(70, 80));
TaiYangDigitalServer.setPortProperties(5);
AddToAllServers(TaiYangDigitalServer);
var GalacticCyberSystemsServer = new Server();
GalacticCyberSystemsServer.init(createRandomIp(), "galactic-cyber", "Galactic Cybersystems", true, false, false, false, 0);
GalacticCyberSystemsServer.setHackingParameters(825, 500000000, 60, 80);
GalacticCyberSystemsServer.setHackingParameters(getRandomInt(800, 850), 500000000, getRandomInt(55, 65), getRandomInt(70, 90));
GalacticCyberSystemsServer.setPortProperties(5);
AddToAllServers(GalacticCyberSystemsServer);
//Defense Companies ("Large" Companies)
var AeroCorpServer = new Server();
AeroCorpServer.init(createRandomIp(), "aerocorp", "AeroCorp", true, false, false, false, 0);
AeroCorpServer.setHackingParameters(850, 1500000000, 85, 60);
AeroCorpServer.setHackingParameters(getRandomInt(825, 875), 1500000000, getRandomInt(80, 90), getRandomInt(55, 65));
AeroCorpServer.setPortProperties(5);
AddToAllServers(AeroCorpServer);
var OmniaCybersystemsServer = new Server();
OmniaCybersystemsServer.init(createRandomIp(), "omnia", "Omnia Cybersystems", true, false, false, false, 0);
OmniaCybersystemsServer.setHackingParameters(825, 1200000000, 90, 65);
OmniaCybersystemsServer.setHackingParameters(getRandomInt(800, 850), 1200000000, getRandomInt(85, 95), getRandomInt(60, 70));
OmniaCybersystemsServer.setPortProperties(5);
AddToAllServers(OmniaCybersystemsServer);
var ZBDefenseServer = new Server();
ZBDefenseServer.init(createRandomIp(), "zb-def", "ZB Defense Industries", true, false, false, false, 0);
ZBDefenseServer.setHackingParameters(800, 1000000000, 60, 70);
ZBDefenseServer.setHackingParameters(getRandomInt(775, 825), 1000000000, getRandomInt(55, 65), getRandomInt(65, 75));
ZBDefenseServer.setPortProperties(4);
AddToAllServers(ZBDefenseServer);
var AppliedEnergeticsServer = new Server();
AppliedEnergeticsServer.init(createRandomIp(), "applied-energetics", "Applied Energetics", true, false, false, false, 0);
AppliedEnergeticsServer.setHackingParameters(775, 1200000000, 70, 72);
AppliedEnergeticsServer.setHackingParameters(getRandomInt(750, 800), 1200000000, getRandomInt(60, 80), getRandomInt(70, 75));
AppliedEnergeticsServer.setPortProperties(4);
AddToAllServers(AppliedEnergeticsServer);
var SolarisSpaceSystemsServer = new Server();
SolarisSpaceSystemsServer.init(createRandomIp(), "solaris", "Solaris Space Systems", true, false, false, false, 0);
SolarisSpaceSystemsServer.setHackingParameters(800, 900000000, 75, 75);
SolarisSpaceSystemsServer.setHackingParameters(getRandomInt(790, 810), 900000000, getRandomInt(70, 80), getRandomInt(70, 80));
SolarisSpaceSystemsServer.setPortProperties(5);
AddToAllServers(SolarisSpaceSystemsServer);
var DeltaOneServer = new Server();
DeltaOneServer.init(createRandomIp(), "deltaone", "Delta One", true, false, false, false, 0);
DeltaOneServer.setHackingParameters(810, 1500000000, 80, 60);
DeltaOneServer.setHackingParameters(getRandomInt(800, 820), 1500000000, getRandomInt(75, 85), getRandomInt(50, 70));
DeltaOneServer.setPortProperties(5);
AddToAllServers(DeltaOneServer);
//Health, medicine, pharmaceutical companies ("Large" targets)
var GlobalPharmaceuticalsServer = new Server();
GlobalPharmaceuticalsServer.init(createRandomIp(), "global-pharm", "Global Pharmaceuticals", true, false, false, false, 16);
GlobalPharmaceuticalsServer.setHackingParameters(775, 2000000000, 80, 85);
GlobalPharmaceuticalsServer.setHackingParameters(getRandomInt(750, 800), 2000000000, getRandomInt(75, 85), getRandomInt(80, 90));
GlobalPharmaceuticalsServer.setPortProperties(4);
AddToAllServers(GlobalPharmaceuticalsServer);
var NovaMedicalServer = new Server();
NovaMedicalServer.init(createRandomIp(), "nova-med", "Nova Medical", true, false, false, false, 0);
NovaMedicalServer.setHackingParameters(800, 1500000000, 70, 75);
NovaMedicalServer.setHackingParameters(getRandomInt(775, 825), 1500000000, getRandomInt(60, 80), getRandomInt(65, 85));
NovaMedicalServer.setPortProperties(4);
AddToAllServers(NovaMedicalServer);
var ZeusMedicalServer = new Server();
ZeusMedicalServer.init(createRandomIp(), "zeud-med", "Zeus Medical", true, false, false, false, 0);
ZeusMedicalServer.setHackingParameters(810, 1750000000, 80, 75);
ZeusMedicalServer.setHackingParameters(getRandomInt(800, 825), 1750000000, getRandomInt(70, 90), getRandomInt(70, 80));
ZeusMedicalServer.setPortProperties(5);
AddToAllServers(ZeusMedicalServer);
var UnitaLifeGroupServer = new Server();
UnitaLifeGroupServer.init(createRandomIp(), "unitalife", "UnitaLife Group", true, false, false, false, 32);
UnitaLifeGroupServer.setHackingParameters(790, 1400000000, 75, 75);
UnitaLifeGroupServer.setHackingParameters(getRandomInt(780, 800), 1400000000, getRandomInt(70, 80), getRandomInt(70, 80));
UnitaLifeGroupServer.setPortProperties(4);
AddToAllServers(UnitaLifeGroupServer);
//"Medium level" targets
var LexoCorpServer = new Server();
LexoCorpServer.init(createRandomIp(), "lexo-corp", "Lexo Corporation", true, false, false, false, 16);
LexoCorpServer.setHackingParameters(700, 1000000000, 70, 60);
LexoCorpServer.setHackingParameters(getRandomInt(680, 720), 1000000000, getRandomInt(60, 80), getRandomInt(55, 65));
LexoCorpServer.setPortProperties(4);
AddToAllServers(LexoCorpServer);
var RhoConstructionServer = new Server();
RhoConstructionServer.init(createRandomIp(), "rho-construction", "Rho Construction", true, false, false, false, 0);
RhoConstructionServer.setHackingParameters(500, 750000000, 50, 50);
RhoConstructionServer.setHackingParameters(getRandomInt(480, 520), 750000000, getRandomInt(40, 60), getRandomInt(40, 60));
RhoConstructionServer.setPortProperties(3);
AddToAllServers(RhoConstructionServer);
var AlphaEnterprisesServer = new Server();
AlphaEnterprisesServer.init(createRandomIp(), "alpha-ent", "Alpha Enterprises", true, false, false, false, 0);
AlphaEnterprisesServer.setHackingParameters(550, 800000000, 60, 55);
AlphaEnterprisesServer.setHackingParameters(getRandomInt(500, 600), 800000000, getRandomInt(50, 70), getRandomInt(50, 60));
AlphaEnterprisesServer.setPortProperties(4);
AddToAllServers(AlphaEnterprisesServer);
var AevumPoliceServer = new Server();
AevumPoliceServer.init(createRandomIp(), "aevum-police", "Aevum Police Network", true, false, false, false, 0);
AevumPoliceServer.setHackingParameters(425, 100000000, 75, 40);
AevumPoliceServer.setHackingParameters(getRandomInt(400, 450), 100000000, getRandomInt(70, 80), getRandomInt(30, 50));
AevumPoliceServer.setPortProperties(4);
AddToAllServers(AevumPoliceServer);
var RothmanUniversityServer = new Server();
RothmanUniversityServer.init(createRandomIp(), "rothman-uni", "Rothman University Network", true, false, false, false, 4);
RothmanUniversityServer.setHackingParameters(400, 250000000, 50, 40);
RothmanUniversityServer.setHackingParameters(getRandomInt(370, 430), 250000000, getRandomInt(45, 55), getRandomInt(35, 45));
RothmanUniversityServer.setPortProperties(3);
AddToAllServers(RothmanUniversityServer);
var ZBInstituteOfTechnologyServer = new Server();
ZBInstituteOfTechnologyServer.init(createRandomIp(), "zb-institute", "ZB Institute of Technology Network", true, false, false, false, 4);
ZBInstituteOfTechnologyServer.setHackingParameters(750, 1000000000, 75, 80);
ZBInstituteOfTechnologyServer.setHackingParameters(getRandomInt(725, 775), 1000000000, getRandomInt(65, 85), getRandomInt(75, 85));
ZBInstituteOfTechnologyServer.setPortProperties(5);
AddToAllServers(ZBInstituteOfTechnologyServer);
var SummitUniversityServer = new Server();
SummitUniversityServer.init(createRandomIp(), "summit-uni", "Summit University Network", true, false, false, false, 4);
SummitUniversityServer.setHackingParameters(450, 200000000, 55, 50);
SummitUniversityServer.setHackingParameters(getRandomInt(425, 475), 200000000, getRandomInt(45, 65), getRandomInt(40, 60));
SummitUniversityServer.setPortProperties(3);
AddToAllServers(SummitUniversityServer);
var SysCoreSecuritiesServer = new Server();
SysCoreSecuritiesServer.init(createRandomIp(), "syscore", "SysCore Securities", true, false, false, false, 0);
SysCoreSecuritiesServer.setHackingParameters(600, 600000000, 70, 65);
SysCoreSecuritiesServer.setHackingParameters(getRandomInt(550, 650), 600000000, getRandomInt(60, 80), getRandomInt(60, 70));
SysCoreSecuritiesServer.setPortProperties(4);
AddToAllServers(SysCoreSecuritiesServer);
var CatalystVenturesServer = new Server();
CatalystVenturesServer.init(createRandomIp(), "catalyst", "Catalyst Ventures", true, false, false, false, 0);
CatalystVenturesServer.setHackingParameters(425, 900000000, 65, 40);
CatalystVenturesServer.setHackingParameters(getRandomInt(400, 450), 900000000, getRandomInt(60, 70), getRandomInt(25, 55));
CatalystVenturesServer.setPortProperties(3);
AddToAllServers(CatalystVenturesServer);
var TheHubServer = new Server();
TheHubServer.init(createRandomIp(), "the-hub", "The Hub", true, false, false, false, 0);
TheHubServer.setHackingParameters(300, 250000000, 40, 50);
TheHubServer.setHackingParameters(getRandomInt(275, 325), 250000000, getRandomInt(35, 45), getRandomInt(45, 55));
TheHubServer.setPortProperties(2);
AddToAllServers(TheHubServer);
var CompuTekServer = new Server();
CompuTekServer.init(createRandomIp(), "comptek", "CompuTek", true, false, false, false, 8);
CompuTekServer.setHackingParameters(350, 300000000, 60, 55);
CompuTekServer.setHackingParameters(getRandomInt(300, 400), 300000000, getRandomInt(55, 65), getRandomInt(50, 60));
CompuTekServer.setPortProperties(3);
AddToAllServers(CompuTekServer);
var NetLinkTechnologiesServer = new Server();
NetLinkTechnologiesServer.init(createRandomIp(), "netlink", "NetLink Technologies", true, false, false, false, 0);
NetLinkTechnologiesServer.setHackingParameters(400, 350000000, 70, 60);
NetLinkTechnologiesServer.setHackingParameters(getRandomInt(375, 425), 350000000, getRandomInt(60, 80), getRandomInt(50, 70));
NetLinkTechnologiesServer.setPortProperties(3);
AddToAllServers(NetLinkTechnologiesServer);
var JohnsonOrthopedicsServer = new Server();
JohnsonOrthopedicsServer.init(createRandomIp(), "johnson-ortho", "Johnson Orthopedics", true, false, false, false, 4);
JohnsonOrthopedicsServer.setHackingParameters(275, 100000000, 50, 50);
JohnsonOrthopedicsServer.setHackingParameters(getRandomInt(250, 300), 100000000, getRandomInt(40, 60), getRandomInt(40, 60));
JohnsonOrthopedicsServer.setPortProperties(2);
AddToAllServers(JohnsonOrthopedicsServer);
@ -483,14 +484,14 @@ initForeignServers = function() {
var OmegaSoftwareServer = new Server();
OmegaSoftwareServer.init(createRandomIp(), "omega-net", "Omega Software", true, false, false, false, 8);
OmegaSoftwareServer.setHackingParameters(200, 85000000, 30, 35);
OmegaSoftwareServer.setHackingParameters(getRandomInt(180, 220), 85000000, getRandomInt(25, 35), getRandomInt(30, 40));
OmegaSoftwareServer.setPortProperties(2);
AddToAllServers(OmegaSoftwareServer);
//Gyms
var CrushFitnessGymServer = new Server();
CrushFitnessGymServer.init(createRandomIp(), "crush-fitness", "Crush Fitness", true, false, false, false, 0);
CrushFitnessGymServer.setHackingParameters(250, 40000000, 40, 30);
CrushFitnessGymServer.setHackingParameters(getRandomInt(225, 275), 40000000, getRandomInt(35, 45), getRandomInt(27, 33));
CrushFitnessGymServer.setPortProperties(2);
AddToAllServers(CrushFitnessGymServer);
@ -502,19 +503,19 @@ initForeignServers = function() {
var MilleniumFitnessGymServer = new Server();
MilleniumFitnessGymServer.init(createRandomIp(), "millenium-fitness", "Millenium Fitness Network", true, false, false, false, 0);
MilleniumFitnessGymServer.setHackingParameters(500, 100000000, 50, 35);
MilleniumFitnessGymServer.setHackingParameters(getRandomInt(475, 525), 100000000, getRandomInt(45, 55), getRandomInt(25, 45));
MilleniumFitnessGymServer.setPortProperties(3);
AddToAllServers(MilleniumFitnessGymServer);
var PowerhouseGymServer = new Server();
PowerhouseGymServer.init(createRandomIp(), "powerhouse-fitness", "Powerhouse Fitness", true, false, false, false, 0);
PowerhouseGymServer.setHackingParameters(1000, 300000000, 60, 55);
PowerhouseGymServer.setHackingParameters(getRandomInt(950, 1100), 300000000, getRandomInt(55, 65), getRandomInt(50, 60));
PowerhouseGymServer.setPortProperties(5);
AddToAllServers(PowerhouseGymServer);
var SnapFitnessGymServer = new Server();
SnapFitnessGymServer.init(createRandomIp(), "snap-fitness", "Snap Fitness", true, false, false, false, 0);
SnapFitnessGymServer.setHackingParameters(750, 150000000, 50, 50);
SnapFitnessGymServer.setHackingParameters(getRandomInt(675, 800), 150000000, getRandomInt(40, 60), getRandomInt(40, 60));
SnapFitnessGymServer.setPortProperties(4);
AddToAllServers(SnapFitnessGymServer);

View File

@ -585,7 +585,6 @@ var Terminal = {
} else {
post('Incorrect usage of alias command. Usage: alias [aliasname="value"]'); return;
}
break;
case "analyze":
if (commandArray.length != 1) {
@ -648,7 +647,7 @@ var Terminal = {
post("Error: No such script exists");
return;
}
logBoxCreate(runningScript);
runningScript.displayLog();
}
break;
case "clear":
@ -790,7 +789,7 @@ var Terminal = {
for (var i = 0; i < currServ.scripts.length; ++i) {
if (scriptName == currServ.scripts[i].filename) {
var scriptBaseRamUsage = currServ.scripts[i].ramUsage;
var ramUsage = scriptBaseRamUsage * numThreads * Math.pow(1.02, numThreads-1);
var ramUsage = scriptBaseRamUsage * numThreads * Math.pow(CONSTANTS.MultithreadingRAMCost, numThreads-1);
post("This script requires " + formatNumber(ramUsage, 2) + "GB of RAM to run for " + numThreads + " thread(s)");
return;
@ -1041,6 +1040,21 @@ var Terminal = {
//TODO List each's script RAM usage
post("Not yet implemented");
break;
case "unalias":
if (commandArray.length != 2) {
post('Incorrect usage of unalias name. Usage: unalias "[alias]"');
return;
} else if (!(commandArray[1].startsWith('"') && commandArray[1].endsWith('"'))) {
post('Incorrect usage of unalias name. Usage: unalias "[alias]"');
} else {
var alias = commandArray[1].slice(1, -1);
if (removeAlias(alias)) {
post("Removed alias " + alias);
} else {
post("No such alias exists");
}
}
break;
default:
post("Command not found");
}
@ -1304,7 +1318,7 @@ var Terminal = {
if (server.scripts[i].filename == scriptName) {
//Check for admin rights and that there is enough RAM availble to run
var script = server.scripts[i];
var ramUsage = script.ramUsage * numThreads * Math.pow(1.02, numThreads-1);
var ramUsage = script.ramUsage * numThreads * Math.pow(CONSTANTS.MultithreadingRAMCost, numThreads-1);
var ramAvailable = server.maxRam - server.ramUsed;
if (server.hasAdminRights == false) {

View File

@ -357,7 +357,6 @@ var Engine = {
aElem.setAttribute("class", "a-link-button");
aElem.innerHTML = factionName;
aElem.addEventListener("click", function() {
console.log("factionName:" + factionName)
Engine.loadFactionContent();
displayFactionContent(factionName);
return false;
@ -706,6 +705,7 @@ var Engine = {
initFactions();
CompanyPositions.init();
initAugmentations();
initMessages();
//Start interactive tutorial
iTutorialStart();

View File

@ -31,6 +31,7 @@ function clearEventListeners(elemId) {
}
function getRandomInt(min, max) {
if (min > max) {return getRandomInt(max, min);}
return Math.floor(Math.random() * (max - min + 1)) + min;
}

View File

@ -56,7 +56,7 @@ logBoxCreate = function(script) {
logBoxUpdateText = function() {
var txt = document.getElementById("log-box-text");
if (logBoxCurrentScript && logBoxOpened && txt) {
txt.innerHTML = logBoxCurrentScript.filename + ":<br>";
txt.innerHTML = logBoxCurrentScript.filename + printArray(logBoxCurrentScript.args) + ":<br><br>";
for (var i = 0; i < logBoxCurrentScript.logs.length; ++i) {
txt.innerHTML += logBoxCurrentScript.logs[i];
txt.innerHTML += "<br>";

View File

@ -36,7 +36,7 @@ purchaseRamForHomeBoxCreate = function() {
//Calculate cost
//Have cost increase by some percentage each time RAM has been upgraded
var cost = currentRam * CONSTANTS.BaseCostFor1GBOfRamHome;
var mult = Math.pow(1.43, numUpgrades);
var mult = Math.pow(1.45, numUpgrades);
cost = cost * mult;
purchaseRamForHomeBoxSetText("Would you like to purchase additional RAM for your home computer? <br><br>" +