mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2024-12-20 05:05:47 +01:00
commit
96ef3e0ac7
@ -57,6 +57,7 @@
|
|||||||
<script src="src/DarkWeb.js"></script>
|
<script src="src/DarkWeb.js"></script>
|
||||||
<script src="src/InteractiveTutorial.js"></script>
|
<script src="src/InteractiveTutorial.js"></script>
|
||||||
<script src="src/Alias.js"></script>
|
<script src="src/Alias.js"></script>
|
||||||
|
<script src="src/Message.js"></script>
|
||||||
|
|
||||||
<script src="src/engine.js"></script>
|
<script src="src/engine.js"></script>
|
||||||
|
|
||||||
|
@ -18,7 +18,7 @@ Augmentation.prototype.setInfo = function(inf) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
Augmentation.prototype.setRequirements = function(rep, cost) {
|
Augmentation.prototype.setRequirements = function(rep, cost) {
|
||||||
this.baseRepRequirement = rep;
|
this.baseRepRequirement = rep * CONSTANTS.AugmentationRepMultiplier;
|
||||||
this.baseCost = cost * CONSTANTS.AugmentationCostMultiplier;
|
this.baseCost = cost * CONSTANTS.AugmentationCostMultiplier;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -183,7 +183,7 @@ initAugmentations = function() {
|
|||||||
Targeting2.setRequirements(3500, 8500000);
|
Targeting2.setRequirements(3500, 8500000);
|
||||||
Targeting2.setInfo("This is an upgrade of the Augmented Targeting I cranial implant, which is capable of augmenting reality " +
|
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 " +
|
"and enhances the user's balance and hand-eye coordination. <br><br>This upgrade increases the player's dexterity " +
|
||||||
"by an additional 30%.");
|
"by an additional 40%.");
|
||||||
Targeting2.addToFactions(["The Dark Army", "The Syndicate", "Sector-12", "Volhaven", "Ishima",
|
Targeting2.addToFactions(["The Dark Army", "The Syndicate", "Sector-12", "Volhaven", "Ishima",
|
||||||
"OmniTek Incorporated", "KuaiGong International", "Blade Industries"]);
|
"OmniTek Incorporated", "KuaiGong International", "Blade Industries"]);
|
||||||
if (augmentationExists(AugmentationNames.Targeting2)) {
|
if (augmentationExists(AugmentationNames.Targeting2)) {
|
||||||
@ -196,7 +196,7 @@ initAugmentations = function() {
|
|||||||
Targeting3.setRequirements(11000, 23000000);
|
Targeting3.setRequirements(11000, 23000000);
|
||||||
Targeting3.setInfo("This is an upgrade of the Augmented Targeting II cranial implant, which is capable of augmenting reality " +
|
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 " +
|
"and enhances the user's balance and hand-eye coordination. <br><br>This upgrade increases the player's dexterity " +
|
||||||
"by an additional 50%.");
|
"by an additional 60%.");
|
||||||
Targeting3.addToFactions(["The Dark Army", "The Syndicate", "OmniTek Incorporated",
|
Targeting3.addToFactions(["The Dark Army", "The Syndicate", "OmniTek Incorporated",
|
||||||
"KuaiGong International", "Blade Industries", "The Covenant"]);
|
"KuaiGong International", "Blade Industries", "The Covenant"]);
|
||||||
if (augmentationExists(AugmentationNames.Targeting3)) {
|
if (augmentationExists(AugmentationNames.Targeting3)) {
|
||||||
@ -223,7 +223,7 @@ initAugmentations = function() {
|
|||||||
SynfibrilMuscle.setInfo("The myofibrils in human muscles are injected with special chemicals that react with the proteins inside " +
|
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. " +
|
"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 " +
|
"Scientists have named these artificially enhanced units 'synfibrils'.<br><br> This augmentation increases the player's " +
|
||||||
"strength and defense by 75%.");
|
"strength and defense by 80%.");
|
||||||
SynfibrilMuscle.addToFactions(["KuaiGong International", "Fulcrum Secret Technologies", "Speakers for the Dead",
|
SynfibrilMuscle.addToFactions(["KuaiGong International", "Fulcrum Secret Technologies", "Speakers for the Dead",
|
||||||
"NWO", "The Covenant", "Daedalus", "Illuminati", "Blade Industries"]);
|
"NWO", "The Covenant", "Daedalus", "Illuminati", "Blade Industries"]);
|
||||||
if (augmentationExists(AugmentationNames.SynfibrilMuscle)) {
|
if (augmentationExists(AugmentationNames.SynfibrilMuscle)) {
|
||||||
@ -260,7 +260,7 @@ initAugmentations = function() {
|
|||||||
var CombatRib3 = new Augmentation(AugmentationNames.CombatRib3);
|
var CombatRib3 = new Augmentation(AugmentationNames.CombatRib3);
|
||||||
CombatRib3.setRequirements(12000, 22000000);
|
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 " +
|
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 35%.");
|
"drugs into the bloodstream<br><br>. This upgrade increases the player's strength and defense by an additional 40%.");
|
||||||
CombatRib3.addToFactions(["The Dark Army", "The Syndicate", "OmniTek Incorporated",
|
CombatRib3.addToFactions(["The Dark Army", "The Syndicate", "OmniTek Incorporated",
|
||||||
"KuaiGong International", "Blade Industries", "The Covenant"]);
|
"KuaiGong International", "Blade Industries", "The Covenant"]);
|
||||||
if (augmentationExists(AugmentationNames.CombatRib3)) {
|
if (augmentationExists(AugmentationNames.CombatRib3)) {
|
||||||
@ -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 " +
|
"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 " +
|
"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>" +
|
"greatly improved senses and reaction speeds.<br><br>" +
|
||||||
"This augmentation increases all of the player's combat stats by 20%.");
|
"This augmentation increases all of the player's combat stats by 25%.");
|
||||||
BionicSpine.addToFactions(["Speakers for the Dead", "The Syndicate", "KuaiGong International",
|
BionicSpine.addToFactions(["Speakers for the Dead", "The Syndicate", "KuaiGong International",
|
||||||
"OmniTek Incorporated", "Blade Industries"]);
|
"OmniTek Incorporated", "Blade Industries"]);
|
||||||
if (augmentationExists(AugmentationNames.BionicSpine)) {
|
if (augmentationExists(AugmentationNames.BionicSpine)) {
|
||||||
@ -409,7 +409,7 @@ initAugmentations = function() {
|
|||||||
"language, and the voice's tone/inflection to determine the best course of action during social" +
|
"language, and the voice's tone/inflection to determine the best course of action during social" +
|
||||||
"situations. The implant also uses deep learning software to continuously learn new behavior" +
|
"situations. The implant also uses deep learning software to continuously learn new behavior" +
|
||||||
"patterns and how to best respond.<br><br>" +
|
"patterns and how to best respond.<br><br>" +
|
||||||
"This augmentation increases the player's charisma and charisma experience gain rate by 50%.");
|
"This augmentation increases the player's charisma and charisma experience gain rate by 60%.");
|
||||||
EnhancedSocialInteractionImplant.addToFactions(["Bachman & Associates", "NWO", "Clarke Incorporated",
|
EnhancedSocialInteractionImplant.addToFactions(["Bachman & Associates", "NWO", "Clarke Incorporated",
|
||||||
"OmniTek Incorporated", "Four Sigma"]);
|
"OmniTek Incorporated", "Four Sigma"]);
|
||||||
if (augmentationExists(AugmentationNames.EnhancedSocialInteractionImplant)) {
|
if (augmentationExists(AugmentationNames.EnhancedSocialInteractionImplant)) {
|
||||||
@ -439,7 +439,7 @@ initAugmentations = function() {
|
|||||||
"allowing its user to solve much more complex problems at a much faster rate.<br><br>" +
|
"allowing its user to solve much more complex problems at a much faster rate.<br><br>" +
|
||||||
"This augmentation:<br>" +
|
"This augmentation:<br>" +
|
||||||
"Increases the player's hacking speed by 3%<br>" +
|
"Increases the player's hacking speed by 3%<br>" +
|
||||||
"Increases the amount of money the player's gains from hacking by 10%<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 15%");
|
||||||
ArtificialBioNeuralNetwork.addToFactions(["BitRunners", "Fulcrum Secret Technologies"]);
|
ArtificialBioNeuralNetwork.addToFactions(["BitRunners", "Fulcrum Secret Technologies"]);
|
||||||
if (augmentationExists(AugmentationNames.ArtificialBioNeuralNetwork)) {
|
if (augmentationExists(AugmentationNames.ArtificialBioNeuralNetwork)) {
|
||||||
@ -472,7 +472,7 @@ initAugmentations = function() {
|
|||||||
"This augmentation:<br>" +
|
"This augmentation:<br>" +
|
||||||
"Increases the player's hacking speed by 3%<br>" +
|
"Increases the player's hacking speed by 3%<br>" +
|
||||||
"Increases the player's hacking skill by 10%<br>" +
|
"Increases the player's hacking skill by 10%<br>" +
|
||||||
"Increases the player's hacking experience gain rate by 15%");
|
"Increases the player's hacking experience gain rate by 20%");
|
||||||
EnhancedMyelinSheathing.addToFactions(["Fulcrum Secret Technologies", "BitRunners", "The Black Hand"]);
|
EnhancedMyelinSheathing.addToFactions(["Fulcrum Secret Technologies", "BitRunners", "The Black Hand"]);
|
||||||
if (augmentationExists(AugmentationNames.EnhancedMyelinSheathing)) {
|
if (augmentationExists(AugmentationNames.EnhancedMyelinSheathing)) {
|
||||||
EnhancedMyelinSheathing.owned = Augmentations[AugmentationNames.EnhancedMyelinSheathing].owned;
|
EnhancedMyelinSheathing.owned = Augmentations[AugmentationNames.EnhancedMyelinSheathing].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 " +
|
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 " +
|
"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>" +
|
"and delete it.<br><br>" +
|
||||||
"This augmentation increases the amount of money the player gains from hacking by 25%");
|
"This augmentation increases the amount of money the player gains from hacking by 30%");
|
||||||
DataJack.addToFactions(["BitRunners", "The Black Hand", "NiteSec", "Chongqing", "New Tokyo"]);
|
DataJack.addToFactions(["BitRunners", "The Black Hand", "NiteSec", "Chongqing", "New Tokyo"]);
|
||||||
if (augmentationExists(AugmentationNames.DataJack)) {
|
if (augmentationExists(AugmentationNames.DataJack)) {
|
||||||
DataJack.owned = Augmentations[AugmentationNames.DataJack].owned;
|
DataJack.owned = Augmentations[AugmentationNames.DataJack].owned;
|
||||||
@ -594,7 +594,7 @@ initAugmentations = function() {
|
|||||||
ENMAnalyzeEngine.setRequirements(250000, 1200000000);
|
ENMAnalyzeEngine.setRequirements(250000, 1200000000);
|
||||||
ENMAnalyzeEngine.setInfo("Installs the Analyze Engine for the Embedded Netburner Module, which is a CPU cluster " +
|
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>" +
|
"that vastly outperforms the Netburner Module's native single-core processor.<br><br>" +
|
||||||
"This augmentation increases the player's hacking speed by 10%.");
|
"This augmentation increases the player's hacking speed by 12%.");
|
||||||
ENMAnalyzeEngine.addToFactions(["ECorp", "MegaCorp", "Fulcrum Secret Technologies", "NWO",
|
ENMAnalyzeEngine.addToFactions(["ECorp", "MegaCorp", "Fulcrum Secret Technologies", "NWO",
|
||||||
"Daedalus", "The Covenant", "Illuminati"]);
|
"Daedalus", "The Covenant", "Illuminati"]);
|
||||||
if (augmentationExists(AugmentationNames.ENMAnalyzeEngine)) {
|
if (augmentationExists(AugmentationNames.ENMAnalyzeEngine)) {
|
||||||
@ -625,8 +625,8 @@ initAugmentations = function() {
|
|||||||
"in order to improve cognitive functions<br><br>" +
|
"in order to improve cognitive functions<br><br>" +
|
||||||
"This augmentation:<br>" +
|
"This augmentation:<br>" +
|
||||||
"Increases the player's hacking speed by 2%<br>" +
|
"Increases the player's hacking speed by 2%<br>" +
|
||||||
"Increases the player's chance of successfully performing a hack by 10%<br>" +
|
"Increases the player's chance of successfully performing a hack by 15%<br>" +
|
||||||
"Increases the player's hacking experience gain rate by 25%");
|
"Increases the player's hacking experience gain rate by 30%");
|
||||||
Neuralstimulator.addToFactions(["The Black Hand", "Chongqing", "Sector-12", "New Tokyo", "Aevum",
|
Neuralstimulator.addToFactions(["The Black Hand", "Chongqing", "Sector-12", "New Tokyo", "Aevum",
|
||||||
"Ishima", "Volhaven", "Bachman & Associates", "Clarke Incorporated",
|
"Ishima", "Volhaven", "Bachman & Associates", "Clarke Incorporated",
|
||||||
"Four Sigma"]);
|
"Four Sigma"]);
|
||||||
@ -652,14 +652,14 @@ initAugmentations = function() {
|
|||||||
AddToAugmentations(NeuralAccelerator);
|
AddToAugmentations(NeuralAccelerator);
|
||||||
|
|
||||||
var CranialSignalProcessorsG1 = new Augmentation(AugmentationNames.CranialSignalProcessorsG1);
|
var CranialSignalProcessorsG1 = new Augmentation(AugmentationNames.CranialSignalProcessorsG1);
|
||||||
CranialSignalProcessorsG1.setRequirements(4000, 18000000);
|
CranialSignalProcessorsG1.setRequirements(4000, 16000000);
|
||||||
CranialSignalProcessorsG1.setInfo("The first generation of Cranial Signal Processors. Cranial Signal Processors " +
|
CranialSignalProcessorsG1.setInfo("The first generation of Cranial Signal Processors. Cranial Signal Processors " +
|
||||||
"are a set of specialized microprocessors that are attached to " +
|
"are a set of specialized microprocessors that are attached to " +
|
||||||
"neurons in the brain. These chips process neural signals to quickly and automatically perform specific computations " +
|
"neurons in the brain. These chips process neural signals to quickly and automatically perform specific computations " +
|
||||||
"so that the brain doesn't have to. <br><br>" +
|
"so that the brain doesn't have to. <br><br>" +
|
||||||
"This augmentation: <br>" +
|
"This augmentation: <br>" +
|
||||||
"Increases the player's hacking speed by 1%<br>" +
|
"Increases the player's hacking speed by 1%<br>" +
|
||||||
"Increases the player's hacking skill by 10%");
|
"Increases the player's hacking skill by 15%");
|
||||||
CranialSignalProcessorsG1.addToFactions(["CyberSec"]);
|
CranialSignalProcessorsG1.addToFactions(["CyberSec"]);
|
||||||
if (augmentationExists(AugmentationNames.CranialSignalProcessorsG1)) {
|
if (augmentationExists(AugmentationNames.CranialSignalProcessorsG1)) {
|
||||||
CranialSignalProcessorsG1.owned = Augmentations[AugmentationNames.CranialSignalProcessorsG1].owned;
|
CranialSignalProcessorsG1.owned = Augmentations[AugmentationNames.CranialSignalProcessorsG1].owned;
|
||||||
@ -676,7 +676,7 @@ initAugmentations = function() {
|
|||||||
"This augmentation: <br>" +
|
"This augmentation: <br>" +
|
||||||
"Increases the player's hacking speed by 2%<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 chance of successfully performing a hack by 5%<br>" +
|
||||||
"Increases the player's hacking skill by 10%");
|
"Increases the player's hacking skill by 15%");
|
||||||
CranialSignalProcessorsG2.addToFactions(["NiteSec"]);
|
CranialSignalProcessorsG2.addToFactions(["NiteSec"]);
|
||||||
if (augmentationExists(AugmentationNames.CranialSignalProcessorsG2)) {
|
if (augmentationExists(AugmentationNames.CranialSignalProcessorsG2)) {
|
||||||
CranialSignalProcessorsG2.owned = Augmentations[AugmentationNames.CranialSignalProcessorsG2].owned;
|
CranialSignalProcessorsG2.owned = Augmentations[AugmentationNames.CranialSignalProcessorsG2].owned;
|
||||||
@ -693,7 +693,7 @@ initAugmentations = function() {
|
|||||||
"This augmentation:<br>" +
|
"This augmentation:<br>" +
|
||||||
"Increases the player's hacking speed by 2%<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 amount of money the player gains from hacking by 20%<br>" +
|
||||||
"Increases the player's hacking skill by 10%");
|
"Increases the player's hacking skill by 15%");
|
||||||
CranialSignalProcessorsG3.addToFactions(["NiteSec", "The Black Hand"]);
|
CranialSignalProcessorsG3.addToFactions(["NiteSec", "The Black Hand"]);
|
||||||
if (augmentationExists(AugmentationNames.CranialSignalProcessorsG3)) {
|
if (augmentationExists(AugmentationNames.CranialSignalProcessorsG3)) {
|
||||||
CranialSignalProcessorsG3.owned = Augmentations[AugmentationNames.CranialSignalProcessorsG3].owned;
|
CranialSignalProcessorsG3.owned = Augmentations[AugmentationNames.CranialSignalProcessorsG3].owned;
|
||||||
@ -725,8 +725,9 @@ initAugmentations = function() {
|
|||||||
"neurons in the brain. These chips process neural signals to quickly and automatically perform specific computations " +
|
"neurons in the brain. These chips process neural signals to quickly and automatically perform specific computations " +
|
||||||
"so that the brain doesn't have to. <br><br>" +
|
"so that the brain doesn't have to. <br><br>" +
|
||||||
"This augmentation:<br>" +
|
"This augmentation:<br>" +
|
||||||
"Increases the player's hacking skill by 60%<br>" +
|
"Increases the player's hacking skill by 30%<br>" +
|
||||||
"Increases the amount of money the player can inject into servers using grow() by 50%");
|
"Increases the amount of money the player gains from hacking by 25%<br>" +
|
||||||
|
"Increases the amount of money the player can inject into servers using grow() by 75%");
|
||||||
CranialSignalProcessorsG5.addToFactions(["BitRunners"]);
|
CranialSignalProcessorsG5.addToFactions(["BitRunners"]);
|
||||||
if (augmentationExists(AugmentationNames.CranialSignalProcessorsG5)) {
|
if (augmentationExists(AugmentationNames.CranialSignalProcessorsG5)) {
|
||||||
CranialSignalProcessorsG5.owned = Augmentations[AugmentationNames.CranialSignalProcessorsG5].owned;
|
CranialSignalProcessorsG5.owned = Augmentations[AugmentationNames.CranialSignalProcessorsG5].owned;
|
||||||
@ -740,8 +741,8 @@ initAugmentations = function() {
|
|||||||
"by decreasing the neuron gap junction. Then, the body is genetically modified " +
|
"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>" +
|
"to enhance the production and capabilities of its neural stem cells. <br><br>" +
|
||||||
"This augmentation: <br>" +
|
"This augmentation: <br>" +
|
||||||
"Increases the player's hacking skill by 30%<br>" +
|
"Increases the player's hacking skill by 25%<br>" +
|
||||||
"Increases the player's hacking experience gain rate by 30%<br>"+
|
"Increases the player's hacking experience gain rate by 40%<br>"+
|
||||||
"Increases the player's hacking speed by 3%");
|
"Increases the player's hacking speed by 3%");
|
||||||
NeuronalDensification.addToFactions(["Clarke Incorporated"]);
|
NeuronalDensification.addToFactions(["Clarke Incorporated"]);
|
||||||
if (augmentationExists(AugmentationNames.NeuronalDensification)) {
|
if (augmentationExists(AugmentationNames.NeuronalDensification)) {
|
||||||
@ -788,7 +789,7 @@ initAugmentations = function() {
|
|||||||
"in the brain.<br><br>" +
|
"in the brain.<br><br>" +
|
||||||
"This augmentation: <br>" +
|
"This augmentation: <br>" +
|
||||||
"Increases all experience gains by 10%<br>" +
|
"Increases all experience gains by 10%<br>" +
|
||||||
"Increases the amount of money the player gains from working by 10%<br>" +
|
"Increases the amount of money the player gains from working by 20%<br>" +
|
||||||
"Increases the amount of reputation the player gains when working for a company by 10%");
|
"Increases the amount of reputation the player gains when working for a company by 10%");
|
||||||
FocusWire.addToFactions(["Bachman & Associates", "Clarke Incorporated", "Four Sigma", "KuaiGong International"]);
|
FocusWire.addToFactions(["Bachman & Associates", "Clarke Incorporated", "Four Sigma", "KuaiGong International"]);
|
||||||
if (augmentationExists(AugmentationNames.FocusWire)) {
|
if (augmentationExists(AugmentationNames.FocusWire)) {
|
||||||
@ -803,7 +804,7 @@ initAugmentations = function() {
|
|||||||
"computers. Connecting to a computer through this jack allows you to interface with " +
|
"computers. Connecting to a computer through this jack allows you to interface with " +
|
||||||
"it using the brain's electrochemical signals.<br><br>" +
|
"it using the brain's electrochemical signals.<br><br>" +
|
||||||
"This augmentation:<br>" +
|
"This augmentation:<br>" +
|
||||||
"Increases the amount of reputation the player gains when working for a company by 25%<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 10%");
|
||||||
PCDNI.addToFactions(["Four Sigma", "OmniTek Incorporated", "ECorp", "Blade Industries"]);
|
PCDNI.addToFactions(["Four Sigma", "OmniTek Incorporated", "ECorp", "Blade Industries"]);
|
||||||
if (augmentationExists(AugmentationNames.PCDNI)) {
|
if (augmentationExists(AugmentationNames.PCDNI)) {
|
||||||
@ -818,8 +819,8 @@ initAugmentations = function() {
|
|||||||
"improves the performance of the interface and gives the user more control options " +
|
"improves the performance of the interface and gives the user more control options " +
|
||||||
"to the connected computer.<br><br>" +
|
"to the connected computer.<br><br>" +
|
||||||
"This augmentation:<br>" +
|
"This augmentation:<br>" +
|
||||||
"Increases the amount of reputation the player gains when working for a company by 25%<br>" +
|
"Increases the amount of reputation the player gains when working for a company by 75%<br>" +
|
||||||
"Increases the player's hacking skill by 25%");
|
"Increases the player's hacking skill by 20%");
|
||||||
PCDNIOptimizer.addToFactions(["Fulcrum Secret Technologies", "ECorp", "Blade Industries"]);
|
PCDNIOptimizer.addToFactions(["Fulcrum Secret Technologies", "ECorp", "Blade Industries"]);
|
||||||
if (augmentationExists(AugmentationNames.PCDNIOptimizer)) {
|
if (augmentationExists(AugmentationNames.PCDNIOptimizer)) {
|
||||||
PCDNIOptimizer.owned = Augmentations[AugmentationNames.PCDNIOptimizer].owned;
|
PCDNIOptimizer.owned = Augmentations[AugmentationNames.PCDNIOptimizer].owned;
|
||||||
@ -834,7 +835,7 @@ initAugmentations = function() {
|
|||||||
"The NeuroNet Injector upgrade allows the user to use his/her own brain's " +
|
"The NeuroNet Injector upgrade allows the user to use his/her own brain's " +
|
||||||
"processing power to aid the computer in computational tasks.<br><br>" +
|
"processing power to aid the computer in computational tasks.<br><br>" +
|
||||||
"This augmentation:<br>" +
|
"This augmentation:<br>" +
|
||||||
"Increases the amount of reputation the player gains when working for a company by 50%<br>" +
|
"Increases the amount of reputation the player gains when working for a company by 100%<br>" +
|
||||||
"Increases the player's hacking skill by 10%<br>" +
|
"Increases the player's hacking skill by 10%<br>" +
|
||||||
"Increases the player's hacking speed by 5%");
|
"Increases the player's hacking speed by 5%");
|
||||||
PCDNINeuralNetwork.addToFactions(["Fulcrum Secret Technologies"]);
|
PCDNINeuralNetwork.addToFactions(["Fulcrum Secret Technologies"]);
|
||||||
@ -1315,7 +1316,7 @@ initAugmentations = function() {
|
|||||||
"This augmentation: <br>" +
|
"This augmentation: <br>" +
|
||||||
"Lets the player start with $1,000,000 after a reset<br>" +
|
"Lets the player start with $1,000,000 after a reset<br>" +
|
||||||
"Lets the player start with the BruteSSH.exe program after a reset");
|
"Lets the player start with the BruteSSH.exe program after a reset");
|
||||||
CashRoot.setRequirements(4000, 25000000);
|
CashRoot.setRequirements(5000, 25000000);
|
||||||
CashRoot.addToFactions(["Sector-12"]);
|
CashRoot.addToFactions(["Sector-12"]);
|
||||||
if (augmentationExists(AugmentationNames.CashRoot)) {
|
if (augmentationExists(AugmentationNames.CashRoot)) {
|
||||||
CashRoot.owned = Augmentations[AugmentationNames.CashRoot].owned;
|
CashRoot.owned = Augmentations[AugmentationNames.CashRoot].owned;
|
||||||
@ -1381,7 +1382,7 @@ initAugmentations = function() {
|
|||||||
"This augmentation:<br>" +
|
"This augmentation:<br>" +
|
||||||
"Increases the player's strength and defense by 50%<br>" +
|
"Increases the player's strength and defense by 50%<br>" +
|
||||||
"Increases the player's crime success rate by 10%<br>" +
|
"Increases the player's crime success rate by 10%<br>" +
|
||||||
"Increases the amount of money the player gains from crimes by 20%");
|
"Increases the amount of money the player gains from crimes by 25%");
|
||||||
GrapheneBrachiBlades.setRequirements(90000, 500000000);
|
GrapheneBrachiBlades.setRequirements(90000, 500000000);
|
||||||
GrapheneBrachiBlades.addToFactions(["Speakers for the Dead"]);
|
GrapheneBrachiBlades.addToFactions(["Speakers for the Dead"]);
|
||||||
if (augmentationExists(AugmentationNames.GrapheneBrachiBlades)) {
|
if (augmentationExists(AugmentationNames.GrapheneBrachiBlades)) {
|
||||||
@ -1395,7 +1396,7 @@ initAugmentations = function() {
|
|||||||
GrapheneBionicArms.setInfo("An upgrade to the Bionic Arms augmentation. It infuses the " +
|
GrapheneBionicArms.setInfo("An upgrade to the Bionic Arms augmentation. It infuses the " +
|
||||||
"prosthetic arms with an advanced graphene material " +
|
"prosthetic arms with an advanced graphene material " +
|
||||||
"to make them much stronger and lighter. <br><br>" +
|
"to make them much stronger and lighter. <br><br>" +
|
||||||
"This augmentation increases the player's strength and dexterity by 100%");
|
"This augmentation increases the player's strength and dexterity by 125%");
|
||||||
GrapheneBionicArms.setRequirements(200000, 750000000);
|
GrapheneBionicArms.setRequirements(200000, 750000000);
|
||||||
GrapheneBionicArms.addToFactions(["The Dark Army"]);
|
GrapheneBionicArms.addToFactions(["The Dark Army"]);
|
||||||
if (augmentationExists(AugmentationNames.GrapheneBionicArms)) {
|
if (augmentationExists(AugmentationNames.GrapheneBionicArms)) {
|
||||||
@ -1439,7 +1440,7 @@ initAugmentations = function() {
|
|||||||
"This augmentation: <br>" +
|
"This augmentation: <br>" +
|
||||||
"Increases the amount of money the player earns at a company by 10%<br>" +
|
"Increases the amount of money the player earns at a company by 10%<br>" +
|
||||||
"Increases the amount of reputation the player gains when working for a " +
|
"Increases the amount of reputation the player gains when working for a " +
|
||||||
"company or faction by 20%");
|
"company or faction by 15%");
|
||||||
SNA.setRequirements(2500, 6000000);
|
SNA.setRequirements(2500, 6000000);
|
||||||
SNA.addToFactions(["Tian Di Hui"]);
|
SNA.addToFactions(["Tian Di Hui"]);
|
||||||
if (augmentationExists(AugmentationNames.SNA)) {
|
if (augmentationExists(AugmentationNames.SNA)) {
|
||||||
@ -1461,18 +1462,18 @@ applyAugmentation = function(aug, reapply=false) {
|
|||||||
Player.dexterity_mult *= 1.2;
|
Player.dexterity_mult *= 1.2;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.Targeting2:
|
case AugmentationNames.Targeting2:
|
||||||
Player.dexterity_mult *= 1.3;
|
Player.dexterity_mult *= 1.4;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.Targeting3:
|
case AugmentationNames.Targeting3:
|
||||||
Player.dexterity_mult *= 1.5;
|
Player.dexterity_mult *= 1.6;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.SyntheticHeart: //High level
|
case AugmentationNames.SyntheticHeart: //High level
|
||||||
Player.agility_mult *= 2.0;
|
Player.agility_mult *= 2.0;
|
||||||
Player.strength_mult *= 2.0;
|
Player.strength_mult *= 2.0;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.SynfibrilMuscle: //Medium-high level
|
case AugmentationNames.SynfibrilMuscle: //Medium-high level
|
||||||
Player.strength_mult *= 1.75;
|
Player.strength_mult *= 1.8;
|
||||||
Player.defense_mult *= 1.75;
|
Player.defense_mult *= 1.8;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.CombatRib1:
|
case AugmentationNames.CombatRib1:
|
||||||
//Str and Defense 5%
|
//Str and Defense 5%
|
||||||
@ -1484,8 +1485,8 @@ applyAugmentation = function(aug, reapply=false) {
|
|||||||
Player.defense_mult *= 1.25;
|
Player.defense_mult *= 1.25;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.CombatRib3:
|
case AugmentationNames.CombatRib3:
|
||||||
Player.strength_mult *= 1.35;
|
Player.strength_mult *= 1.40;
|
||||||
Player.defense_mult *= 1.35;
|
Player.defense_mult *= 1.40;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.NanofiberWeave: //Med level
|
case AugmentationNames.NanofiberWeave: //Med level
|
||||||
Player.strength_mult *= 1.4;
|
Player.strength_mult *= 1.4;
|
||||||
@ -1503,10 +1504,10 @@ applyAugmentation = function(aug, reapply=false) {
|
|||||||
Player.defense_mult *= 2.25;
|
Player.defense_mult *= 2.25;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.BionicSpine: //Med level
|
case AugmentationNames.BionicSpine: //Med level
|
||||||
Player.strength_mult *= 1.2;
|
Player.strength_mult *= 1.25;
|
||||||
Player.defense_mult *= 1.2;
|
Player.defense_mult *= 1.25;
|
||||||
Player.agility_mult *= 1.2;
|
Player.agility_mult *= 1.25;
|
||||||
Player.dexterity_mult *= 1.2;
|
Player.dexterity_mult *= 1.25;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.GrapheneBionicSpine: //High level
|
case AugmentationNames.GrapheneBionicSpine: //High level
|
||||||
Player.strength_mult *= 2;
|
Player.strength_mult *= 2;
|
||||||
@ -1523,8 +1524,8 @@ applyAugmentation = function(aug, reapply=false) {
|
|||||||
|
|
||||||
//Labor stats augmentations
|
//Labor stats augmentations
|
||||||
case AugmentationNames.EnhancedSocialInteractionImplant: //Med-high level
|
case AugmentationNames.EnhancedSocialInteractionImplant: //Med-high level
|
||||||
Player.charisma_mult *= 1.5;
|
Player.charisma_mult *= 1.6;
|
||||||
Player.charisma_exp_mult *= 1.5;
|
Player.charisma_exp_mult *= 1.6;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.TITN41Injection:
|
case AugmentationNames.TITN41Injection:
|
||||||
Player.charisma_mult *= 1.15;
|
Player.charisma_mult *= 1.15;
|
||||||
@ -1540,7 +1541,7 @@ applyAugmentation = function(aug, reapply=false) {
|
|||||||
break;
|
break;
|
||||||
case AugmentationNames.ArtificialBioNeuralNetwork: //Med level
|
case AugmentationNames.ArtificialBioNeuralNetwork: //Med level
|
||||||
Player.hacking_speed_mult *= .97;
|
Player.hacking_speed_mult *= .97;
|
||||||
Player.hacking_money_mult *= 1.1;
|
Player.hacking_money_mult *= 1.15;
|
||||||
Player.hacking_mult *= 1.15;
|
Player.hacking_mult *= 1.15;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.ArtificialSynapticPotentiation: //Med level
|
case AugmentationNames.ArtificialSynapticPotentiation: //Med level
|
||||||
@ -1550,7 +1551,7 @@ applyAugmentation = function(aug, reapply=false) {
|
|||||||
break;
|
break;
|
||||||
case AugmentationNames.EnhancedMyelinSheathing: //Med level
|
case AugmentationNames.EnhancedMyelinSheathing: //Med level
|
||||||
Player.hacking_speed_mult *= .97;
|
Player.hacking_speed_mult *= .97;
|
||||||
Player.hacking_exp_mult *= 1.15;
|
Player.hacking_exp_mult *= 1.2;
|
||||||
Player.hacking_mult *= 1.1;
|
Player.hacking_mult *= 1.1;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.SynapticEnhancement: //Low Level
|
case AugmentationNames.SynapticEnhancement: //Low Level
|
||||||
@ -1560,7 +1561,7 @@ applyAugmentation = function(aug, reapply=false) {
|
|||||||
Player.hacking_exp_mult *= 1.4;
|
Player.hacking_exp_mult *= 1.4;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.DataJack: //Med low level
|
case AugmentationNames.DataJack: //Med low level
|
||||||
Player.hacking_money_mult *= 1.25;
|
Player.hacking_money_mult *= 1.3;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.ENM: //Medium level
|
case AugmentationNames.ENM: //Medium level
|
||||||
Player.hacking_mult *= 1.1;
|
Player.hacking_mult *= 1.1;
|
||||||
@ -1587,7 +1588,7 @@ applyAugmentation = function(aug, reapply=false) {
|
|||||||
Player.hacking_mult *= 1.2;
|
Player.hacking_mult *= 1.2;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.ENMAnalyzeEngine: //High level
|
case AugmentationNames.ENMAnalyzeEngine: //High level
|
||||||
Player.hacking_speed_mult *= 0.9;
|
Player.hacking_speed_mult *= 0.88;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.ENMDMA: //High level
|
case AugmentationNames.ENMDMA: //High level
|
||||||
Player.hacking_money_mult *= 1.5;
|
Player.hacking_money_mult *= 1.5;
|
||||||
@ -1595,8 +1596,8 @@ applyAugmentation = function(aug, reapply=false) {
|
|||||||
break;
|
break;
|
||||||
case AugmentationNames.Neuralstimulator: //Medium Level
|
case AugmentationNames.Neuralstimulator: //Medium Level
|
||||||
Player.hacking_speed_mult *= .98;
|
Player.hacking_speed_mult *= .98;
|
||||||
Player.hacking_chance_mult *= 1.1;
|
Player.hacking_chance_mult *= 1.15;
|
||||||
Player.hacking_exp_mult *= 1.25;
|
Player.hacking_exp_mult *= 1.3;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.NeuralAccelerator:
|
case AugmentationNames.NeuralAccelerator:
|
||||||
Player.hacking_mult *= 1.2;
|
Player.hacking_mult *= 1.2;
|
||||||
@ -1605,17 +1606,17 @@ applyAugmentation = function(aug, reapply=false) {
|
|||||||
break;
|
break;
|
||||||
case AugmentationNames.CranialSignalProcessorsG1:
|
case AugmentationNames.CranialSignalProcessorsG1:
|
||||||
Player.hacking_speed_mult *= 0.99;
|
Player.hacking_speed_mult *= 0.99;
|
||||||
Player.hacking_mult *= 1.1;
|
Player.hacking_mult *= 1.15;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.CranialSignalProcessorsG2:
|
case AugmentationNames.CranialSignalProcessorsG2:
|
||||||
Player.hacking_speed_mult *= 0.98;
|
Player.hacking_speed_mult *= 0.98;
|
||||||
Player.hacking_chance_mult *= 1.05;
|
Player.hacking_chance_mult *= 1.05;
|
||||||
Player.hacking_mult *= 1.1;
|
Player.hacking_mult *= 1.15;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.CranialSignalProcessorsG3:
|
case AugmentationNames.CranialSignalProcessorsG3:
|
||||||
Player.hacking_speed_mult *= 0.98;
|
Player.hacking_speed_mult *= 0.98;
|
||||||
Player.hacking_money_mult *= 1.2;
|
Player.hacking_money_mult *= 1.2;
|
||||||
Player.hacking_mult *= 1.1;
|
Player.hacking_mult *= 1.15;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.CranialSignalProcessorsG4:
|
case AugmentationNames.CranialSignalProcessorsG4:
|
||||||
Player.hacking_speed_mult *= 0.98;
|
Player.hacking_speed_mult *= 0.98;
|
||||||
@ -1623,12 +1624,13 @@ applyAugmentation = function(aug, reapply=false) {
|
|||||||
Player.hacking_grow_mult *= 1.25;
|
Player.hacking_grow_mult *= 1.25;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.CranialSignalProcessorsG5:
|
case AugmentationNames.CranialSignalProcessorsG5:
|
||||||
Player.hacking_mult *= 1.6;
|
Player.hacking_mult *= 1.3;
|
||||||
Player.hacking_grow_mult *= 1.5;
|
Player.hacking_money_mult *= 1.25;
|
||||||
|
Player.hacking_grow_mult *= 1.75;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.NeuronalDensification:
|
case AugmentationNames.NeuronalDensification:
|
||||||
Player.hacking_mult *= 1.3;
|
Player.hacking_mult *= 1.25;
|
||||||
Player.hacking_exp_mult *= 1.3;
|
Player.hacking_exp_mult *= 1.40;
|
||||||
Player.hacking_speed_mult *= 0.97;
|
Player.hacking_speed_mult *= 0.97;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
@ -1648,18 +1650,18 @@ applyAugmentation = function(aug, reapply=false) {
|
|||||||
Player.agility_exp_mult *= 1.1;
|
Player.agility_exp_mult *= 1.1;
|
||||||
Player.charisma_exp_mult *= 1.1;
|
Player.charisma_exp_mult *= 1.1;
|
||||||
Player.company_rep_mult *= 1.1;
|
Player.company_rep_mult *= 1.1;
|
||||||
Player.work_money_mult *= 1.1;
|
Player.work_money_mult *= 1.2;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.PCDNI: //Med level
|
case AugmentationNames.PCDNI: //Med level
|
||||||
Player.company_rep_mult *= 1.25;
|
Player.company_rep_mult *= 1.3;
|
||||||
Player.hacking_mult *= 1.1;
|
Player.hacking_mult *= 1.1;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.PCDNIOptimizer: //High level
|
case AugmentationNames.PCDNIOptimizer: //High level
|
||||||
Player.company_rep_mult *= 1.25;
|
Player.company_rep_mult *= 1.75;
|
||||||
Player.hacking_mult *= 1.25;
|
Player.hacking_mult *= 1.20;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.PCDNINeuralNetwork: //High level
|
case AugmentationNames.PCDNINeuralNetwork: //High level
|
||||||
Player.company_rep_mult *= 1.5;
|
Player.company_rep_mult *= 2;
|
||||||
Player.hacking_mult *= 1.1;
|
Player.hacking_mult *= 1.1;
|
||||||
Player.hacking_speed_mult *= .95;
|
Player.hacking_speed_mult *= .95;
|
||||||
break;
|
break;
|
||||||
@ -1897,11 +1899,11 @@ applyAugmentation = function(aug, reapply=false) {
|
|||||||
Player.strength_mult *= 1.5;
|
Player.strength_mult *= 1.5;
|
||||||
Player.defense_mult *= 1.5;
|
Player.defense_mult *= 1.5;
|
||||||
Player.crime_success_mult *= 1.1;
|
Player.crime_success_mult *= 1.1;
|
||||||
Player.crime_money_mult *= 1.2;
|
Player.crime_money_mult *= 1.25;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.GrapheneBionicArms:
|
case AugmentationNames.GrapheneBionicArms:
|
||||||
Player.strength_mult *= 2;
|
Player.strength_mult *= 2.25;
|
||||||
Player.dexterity_mult *= 2;
|
Player.dexterity_mult *= 2.25;
|
||||||
break;
|
break;
|
||||||
case AugmentationNames.BrachiBlades:
|
case AugmentationNames.BrachiBlades:
|
||||||
Player.strength_mult *= 1.2;
|
Player.strength_mult *= 1.2;
|
||||||
@ -1915,8 +1917,8 @@ applyAugmentation = function(aug, reapply=false) {
|
|||||||
break;
|
break;
|
||||||
case AugmentationNames.SNA:
|
case AugmentationNames.SNA:
|
||||||
Player.work_money_mult *= 1.1;
|
Player.work_money_mult *= 1.1;
|
||||||
Player.company_rep_mult *= 1.2;
|
Player.company_rep_mult *= 1.15;
|
||||||
Player.faction_rep_mult *= 1.2;
|
Player.faction_rep_mult *= 1.15;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
throw new Error("ERROR: No such augmentation!");
|
throw new Error("ERROR: No such augmentation!");
|
||||||
|
@ -223,58 +223,58 @@ CompanyPositions = {
|
|||||||
//Constructor: CompanyPosition(name, reqHack, reqStr, reqDef, reqDex, reqAgi, reqCha, reqRep, salary)
|
//Constructor: CompanyPosition(name, reqHack, reqStr, reqDef, reqDex, reqAgi, reqCha, reqRep, salary)
|
||||||
|
|
||||||
//Software
|
//Software
|
||||||
SoftwareIntern: new CompanyPosition("Software Engineering Intern", 1, 0, 0, 0, 0, 0, 0, 12),
|
SoftwareIntern: new CompanyPosition("Software Engineering Intern", 1, 0, 0, 0, 0, 0, 0, 13),
|
||||||
JuniorDev: new CompanyPosition("Junior Software Engineer", 51, 0, 0, 0, 0, 0, 8000, 30),
|
JuniorDev: new CompanyPosition("Junior Software Engineer", 51, 0, 0, 0, 0, 0, 8000, 32),
|
||||||
SeniorDev: new CompanyPosition("Senior Software Engineer", 251, 0, 0, 0, 0, 51, 32000, 60),
|
SeniorDev: new CompanyPosition("Senior Software Engineer", 251, 0, 0, 0, 0, 51, 32000, 63),
|
||||||
LeadDev: new CompanyPosition("Lead Software Developer", 401, 0, 0, 0, 0, 151, 144000, 200),
|
LeadDev: new CompanyPosition("Lead Software Developer", 401, 0, 0, 0, 0, 151, 144000, 210),
|
||||||
|
|
||||||
//TODO Through darkweb, maybe?
|
//TODO Through darkweb, maybe?
|
||||||
FreelanceDeveloper: new CompanyPosition("Freelance Developer", 0, 0, 0, 0, 0, 0, 0, 0),
|
FreelanceDeveloper: new CompanyPosition("Freelance Developer", 0, 0, 0, 0, 0, 0, 0, 0),
|
||||||
|
|
||||||
SoftwareConsultant: new CompanyPosition("Software Consultant", 51, 0, 0, 0, 0, 0, 0, 20),
|
SoftwareConsultant: new CompanyPosition("Software Consultant", 51, 0, 0, 0, 0, 0, 0, 22),
|
||||||
SeniorSoftwareConsultant: new CompanyPosition("Senior Software Consultant", 251, 0, 0, 0, 0, 51, 0, 42),
|
SeniorSoftwareConsultant: new CompanyPosition("Senior Software Consultant", 251, 0, 0, 0, 0, 51, 0, 45),
|
||||||
|
|
||||||
//IT
|
//IT
|
||||||
ITIntern: new CompanyPosition("IT Intern", 1, 0, 0, 0, 0, 0, 0, 10),
|
ITIntern: new CompanyPosition("IT Intern", 1, 0, 0, 0, 0, 0, 0, 11),
|
||||||
ITAnalyst: new CompanyPosition("IT Analyst", 26, 0, 0, 0, 0, 0, 6000, 25),
|
ITAnalyst: new CompanyPosition("IT Analyst", 26, 0, 0, 0, 0, 0, 5000, 25),
|
||||||
ITManager: new CompanyPosition("IT Manager", 151, 0, 0, 0, 0, 51, 24000, 45),
|
ITManager: new CompanyPosition("IT Manager", 151, 0, 0, 0, 0, 51, 22000, 48),
|
||||||
SysAdmin: new CompanyPosition("Systems Administrator", 251, 0, 0, 0, 0, 76, 120000, 150),
|
SysAdmin: new CompanyPosition("Systems Administrator", 251, 0, 0, 0, 0, 76, 120000, 165),
|
||||||
SecurityEngineer: new CompanyPosition("Security Engineer", 151, 0, 0, 0, 0, 26, 28000, 52),
|
SecurityEngineer: new CompanyPosition("Security Engineer", 151, 0, 0, 0, 0, 26, 28000, 55),
|
||||||
NetworkEngineer: new CompanyPosition("Network Engineer", 151, 0, 0, 0, 0, 26, 28000, 52),
|
NetworkEngineer: new CompanyPosition("Network Engineer", 151, 0, 0, 0, 0, 26, 28000, 55),
|
||||||
NetworkAdministrator: new CompanyPosition("Network Administrator", 251, 0, 0, 0, 0, 76, 120000, 150),
|
NetworkAdministrator: new CompanyPosition("Network Administrator", 251, 0, 0, 0, 0, 76, 120000, 165),
|
||||||
|
|
||||||
//Technology management
|
//Technology management
|
||||||
HeadOfSoftware: new CompanyPosition("Head of Software", 501, 0, 0, 0, 0, 251, 288000, 300),
|
HeadOfSoftware: new CompanyPosition("Head of Software", 501, 0, 0, 0, 0, 251, 288000, 330),
|
||||||
HeadOfEngineering: new CompanyPosition("Head of Engineering", 501, 0, 0, 0, 0, 251, 576000, 600),
|
HeadOfEngineering: new CompanyPosition("Head of Engineering", 501, 0, 0, 0, 0, 251, 576000, 660),
|
||||||
VicePresident: new CompanyPosition("Vice President of Technology", 601, 0, 0, 0, 0, 401, 1152000, 900),
|
VicePresident: new CompanyPosition("Vice President of Technology", 601, 0, 0, 0, 0, 401, 1152000, 990),
|
||||||
CTO: new CompanyPosition("Chief Technology Officer", 751, 0, 0, 0, 0, 501, 4608000, 1000),
|
CTO: new CompanyPosition("Chief Technology Officer", 751, 0, 0, 0, 0, 501, 4608000, 1100),
|
||||||
|
|
||||||
//Business
|
//Business
|
||||||
BusinessIntern: new CompanyPosition("Business Intern", 1, 0, 0, 0, 0, 1, 0, 15),
|
BusinessIntern: new CompanyPosition("Business Intern", 1, 0, 0, 0, 0, 1, 0, 18),
|
||||||
BusinessAnalyst: new CompanyPosition("Business Analyst", 6, 0, 0, 0, 0, 51, 8000, 40),
|
BusinessAnalyst: new CompanyPosition("Business Analyst", 6, 0, 0, 0, 0, 51, 8000, 42),
|
||||||
BusinessManager: new CompanyPosition("Business Manager", 51, 0, 0, 0, 0, 101, 32000, 80),
|
BusinessManager: new CompanyPosition("Business Manager", 51, 0, 0, 0, 0, 101, 32000, 84),
|
||||||
OperationsManager: new CompanyPosition("Operations Manager", 51, 0, 0, 0, 0, 226, 144000, 250),
|
OperationsManager: new CompanyPosition("Operations Manager", 51, 0, 0, 0, 0, 226, 144000, 275),
|
||||||
CFO: new CompanyPosition("Chief Financial Officer", 76, 0, 0, 0, 0, 501, 576000, 750),
|
CFO: new CompanyPosition("Chief Financial Officer", 76, 0, 0, 0, 0, 501, 576000, 800),
|
||||||
CEO: new CompanyPosition("Chief Executive Officer", 101, 0, 0, 0, 0, 751, 4608000, 1400),
|
CEO: new CompanyPosition("Chief Executive Officer", 101, 0, 0, 0, 0, 751, 4608000, 1500),
|
||||||
|
|
||||||
BusinessConsultant: new CompanyPosition("Business Consultant", 6, 0, 0, 0, 0, 51, 0, 24),
|
BusinessConsultant: new CompanyPosition("Business Consultant", 6, 0, 0, 0, 0, 51, 0, 28),
|
||||||
SeniorBusinessConsultant: new CompanyPosition("Senior Business Consultant", 51, 0, 0, 0, 0, 226, 0, 160),
|
SeniorBusinessConsultant: new CompanyPosition("Senior Business Consultant", 51, 0, 0, 0, 0, 226, 0, 175),
|
||||||
|
|
||||||
//Non-tech/management jobs
|
//Non-tech/management jobs
|
||||||
PartTimeWaiter: new CompanyPosition("Part-time Waiter", 0, 0, 0, 0, 0, 0, 0, 8),
|
PartTimeWaiter: new CompanyPosition("Part-time Waiter", 0, 0, 0, 0, 0, 0, 0, 9),
|
||||||
PartTimeEmployee: new CompanyPosition("Part-time Employee", 0, 0, 0, 0, 0, 0, 0, 8),
|
PartTimeEmployee: new CompanyPosition("Part-time Employee", 0, 0, 0, 0, 0, 0, 0, 9),
|
||||||
|
|
||||||
Waiter: new CompanyPosition("Waiter", 0, 0, 0, 0, 0, 0, 0, 10),
|
Waiter: new CompanyPosition("Waiter", 0, 0, 0, 0, 0, 0, 0, 11),
|
||||||
Employee: new CompanyPosition("Employee", 0, 0, 0, 0, 0, 0, 0, 10),
|
Employee: new CompanyPosition("Employee", 0, 0, 0, 0, 0, 0, 0, 11),
|
||||||
PoliceOfficer: new CompanyPosition("Police Officer", 11, 101, 101, 101, 101, 51, 8000, 32),
|
PoliceOfficer: new CompanyPosition("Police Officer", 11, 101, 101, 101, 101, 51, 8000, 36),
|
||||||
PoliceChief: new CompanyPosition("Police Chief", 101, 301, 301, 301, 301, 151, 32000, 160),
|
PoliceChief: new CompanyPosition("Police Chief", 101, 301, 301, 301, 301, 151, 32000, 175),
|
||||||
SecurityGuard: new CompanyPosition("Security Guard", 0, 51, 51, 51, 51, 1, 0, 18),
|
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, 70),
|
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, 250),
|
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, 500),
|
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, 50),
|
FieldAgent: new CompanyPosition("Field Agent", 101, 101, 101, 101, 101, 101, 8000, 55),
|
||||||
SecretAgent: new CompanyPosition("Secret Agent", 201, 251, 251, 251, 251, 32000, 180),
|
SecretAgent: new CompanyPosition("Secret Agent", 201, 251, 251, 251, 251, 32000, 190),
|
||||||
SpecialOperative: new CompanyPosition("Special Operative", 251, 501, 501, 501, 501, 144000, 400),
|
SpecialOperative: new CompanyPosition("Special Operative", 251, 501, 501, 501, 501, 144000, 425),
|
||||||
|
|
||||||
init: function() {
|
init: function() {
|
||||||
//Argument order: hack, str, def, dex, agi, cha
|
//Argument order: hack, str, def, dex, agi, cha
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
CONSTANTS = {
|
CONSTANTS = {
|
||||||
Version: "0.18.3",
|
Version: "0.19.0",
|
||||||
|
|
||||||
//Max level for any skill, assuming no multipliers. Determined by max numerical value in javascript for experience
|
//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
|
//and the skill level formula in Player.js. Note that all this means it that when experience hits MAX_INT, then
|
||||||
@ -19,9 +19,9 @@ CONSTANTS = {
|
|||||||
|
|
||||||
/* Hacknet Node constants */
|
/* Hacknet Node constants */
|
||||||
HacknetNodeMoneyGainPerLevel: 1.6,
|
HacknetNodeMoneyGainPerLevel: 1.6,
|
||||||
HacknetNodePurchaseNextMult: 1.39, //Multiplier when purchasing an additional hacknet node
|
HacknetNodePurchaseNextMult: 1.42, //Multiplier when purchasing an additional hacknet node
|
||||||
HacknetNodeUpgradeLevelMult: 1.04, //Multiplier for cost when upgrading level
|
HacknetNodeUpgradeLevelMult: 1.045, //Multiplier for cost when upgrading level
|
||||||
HacknetNodeUpgradeRamMult: 1.26, //Multiplier for cost when upgrading RAM
|
HacknetNodeUpgradeRamMult: 1.28, //Multiplier for cost when upgrading RAM
|
||||||
HacknetNodeUpgradeCoreMult: 1.49, //Multiplier for cost when buying another core
|
HacknetNodeUpgradeCoreMult: 1.49, //Multiplier for cost when buying another core
|
||||||
|
|
||||||
HacknetNodeMaxLevel: 200,
|
HacknetNodeMaxLevel: 200,
|
||||||
@ -66,11 +66,12 @@ CONSTANTS = {
|
|||||||
|
|
||||||
//Server constants
|
//Server constants
|
||||||
ServerGrowthRate: 1.002, //Growth rate
|
ServerGrowthRate: 1.002, //Growth rate
|
||||||
ServerFortifyAmount: 0.001, //Amount by which server's security increases when its hacked
|
ServerFortifyAmount: 0.002, //Amount by which server's security increases when its hacked
|
||||||
ServerWeakenAmount: 0.1, //Amount by which server's security decreases when weakened
|
ServerWeakenAmount: 0.1, //Amount by which server's security decreases when weakened
|
||||||
|
|
||||||
//Augmentation Constants
|
//Augmentation Constants
|
||||||
AugmentationCostMultiplier: 3, //Used for balancing costs without having to readjust every Augmentation cost
|
AugmentationCostMultiplier: 4.5, //Used for balancing costs without having to readjust every Augmentation cost
|
||||||
|
AugmentationRepMultiplier: 1.2, //Used for balancing rep cost without having to readjust every value
|
||||||
|
|
||||||
//Maximum number of log entries for a script
|
//Maximum number of log entries for a script
|
||||||
MaxLogCapacity: 40,
|
MaxLogCapacity: 40,
|
||||||
@ -127,12 +128,12 @@ CONSTANTS = {
|
|||||||
ClassGymDexterity: "training your dexterity at a gym",
|
ClassGymDexterity: "training your dexterity at a gym",
|
||||||
ClassGymAgility: "training your agility at a gym",
|
ClassGymAgility: "training your agility at a gym",
|
||||||
|
|
||||||
ClassDataStructuresBaseCost: 2,
|
ClassDataStructuresBaseCost: 6,
|
||||||
ClassNetworksBaseCost: 10,
|
ClassNetworksBaseCost: 30,
|
||||||
ClassAlgorithmsBaseCost: 40,
|
ClassAlgorithmsBaseCost: 120,
|
||||||
ClassManagementBaseCost: 20,
|
ClassManagementBaseCost: 60,
|
||||||
ClassLeadershipBaseCost: 40,
|
ClassLeadershipBaseCost: 120,
|
||||||
ClassGymBaseCost: 30,
|
ClassGymBaseCost: 100,
|
||||||
|
|
||||||
CrimeShoplift: "shoplift",
|
CrimeShoplift: "shoplift",
|
||||||
CrimeMug: "mug someone",
|
CrimeMug: "mug someone",
|
||||||
@ -147,6 +148,7 @@ CONSTANTS = {
|
|||||||
//Text that is displayed when the 'help' command is ran in Terminal
|
//Text that is displayed when the 'help' command is ran in Terminal
|
||||||
HelpText: 'alias [name="value"] Create aliases for Terminal commands, or list existing aliases<br>' +
|
HelpText: 'alias [name="value"] Create aliases for Terminal commands, or list existing aliases<br>' +
|
||||||
"analyze Get statistics and information about current machine <br>" +
|
"analyze Get statistics and information about current machine <br>" +
|
||||||
|
"cat [message] Display a .msg file<br>" +
|
||||||
"clear Clear all text on the terminal <br>" +
|
"clear Clear all text on the terminal <br>" +
|
||||||
"cls See 'clear' command <br>" +
|
"cls See 'clear' command <br>" +
|
||||||
"connect [ip/hostname] Connects to the machine given by its IP or hostname <br>" +
|
"connect [ip/hostname] Connects to the machine given by its IP or hostname <br>" +
|
||||||
|
@ -8,6 +8,7 @@ Programs = {
|
|||||||
SQLInjectProgram: "SQLInject.exe",
|
SQLInjectProgram: "SQLInject.exe",
|
||||||
DeepscanV1: "DeepscanV1.exe",
|
DeepscanV1: "DeepscanV1.exe",
|
||||||
DeepscanV2: "DeepscanV2.exe",
|
DeepscanV2: "DeepscanV2.exe",
|
||||||
|
Flight: "fl1ght.exe",
|
||||||
}
|
}
|
||||||
|
|
||||||
//TODO Right now the times needed to complete work are hard-coded...
|
//TODO Right now the times needed to complete work are hard-coded...
|
||||||
|
@ -290,12 +290,12 @@ PlayerObject.prototype.checkForFactionInvitations = function() {
|
|||||||
|
|
||||||
//Fulcrum Secret Technologies - If u've unlocked fulcrum secret technolgoies server and have a high rep with the company
|
//Fulcrum Secret Technologies - If u've unlocked fulcrum secret technolgoies server and have a high rep with the company
|
||||||
var fulcrumsecrettechonologiesFac = Factions["Fulcrum Secret Technologies"];
|
var fulcrumsecrettechonologiesFac = Factions["Fulcrum Secret Technologies"];
|
||||||
var fulcrumSecretServer = AllServers[SpecialServerIps["Fulcrum Secret Technologies Server"]];
|
var fulcrumSecretServer = AllServers[SpecialServerIps[SpecialServerNames.FulcrumSecretTechnologies]];
|
||||||
if (fulcrumSecretServer == null) {
|
if (fulcrumSecretServer == null) {
|
||||||
console.log("Error: Could not find Fulcrum Secret Technologies Server");
|
console.log("ERROR: Could not find Fulcrum Secret Technologies Server");
|
||||||
} else {
|
} else {
|
||||||
if (fulcrumsecrettechonologiesFac.isBanned == false && fulcrumsecrettechonologiesFac.isMember == false &&
|
if (fulcrumsecrettechonologiesFac.isBanned == false && fulcrumsecrettechonologiesFac.isMember == false &&
|
||||||
fulcrumSecretServer.hasAdminRights &&
|
fulcrumSecretServer.manuallyHacked &&
|
||||||
this.companyName == Locations.AevumFulcrumTechnologies && companyRep >= 250000) {
|
this.companyName == Locations.AevumFulcrumTechnologies && companyRep >= 250000) {
|
||||||
invitedFactions.push(fulcrumsecrettechonologiesFac);
|
invitedFactions.push(fulcrumsecrettechonologiesFac);
|
||||||
}
|
}
|
||||||
@ -303,23 +303,31 @@ PlayerObject.prototype.checkForFactionInvitations = function() {
|
|||||||
|
|
||||||
//BitRunners
|
//BitRunners
|
||||||
var bitrunnersFac = Factions["BitRunners"];
|
var bitrunnersFac = Factions["BitRunners"];
|
||||||
var homeComp = Player.getHomeComputer();
|
var homeComp = this.getHomeComputer();
|
||||||
if (bitrunnersFac.isBanned == false && bitrunnersFac.isMember == false &&
|
var bitrunnersServer = AllServers[SpecialServerIps[SpecialServerNames.BitRunnersServer]];
|
||||||
|
if (bitrunnersServer == null) {
|
||||||
|
console.log("ERROR: Could not find BitRunners Server");
|
||||||
|
} else if (bitrunnersFac.isBanned == false && bitrunnersFac.isMember == false && bitrunnersServer.manuallyHacked &&
|
||||||
this.hacking_skill >= 500 && homeComp.maxRam >= 128) {
|
this.hacking_skill >= 500 && homeComp.maxRam >= 128) {
|
||||||
invitedFactions.push(bitrunnersFac);
|
invitedFactions.push(bitrunnersFac);
|
||||||
}
|
}
|
||||||
|
|
||||||
//The Black Hand
|
//The Black Hand
|
||||||
var theblackhandFac = Factions["The Black Hand"];
|
var theblackhandFac = Factions["The Black Hand"];
|
||||||
if (theblackhandFac.isBanned == false && theblackhandFac.isMember == false &&
|
var blackhandServer = AllServers[SpecialServerIps[SpecialServerNames.TheBlackHandServer]];
|
||||||
this.hacking_skill >= 300 && this.strength >= 100 && this.defense >= 100 &&
|
if (blackhandServer == null) {
|
||||||
this.agility >= 100 && this.dexterity >= 100 && homeComp.maxRam >= 64) {
|
console.log("ERROR: Could not find The Black Hand Server");
|
||||||
|
} else if (!theblackhandFac.isBanned && !theblackhandFac.isMember && blackhandServer.manuallyHacked &&
|
||||||
|
this.hacking_skill >= 350 && homeComp.maxRam >= 64) {
|
||||||
invitedFactions.push(theblackhandFac);
|
invitedFactions.push(theblackhandFac);
|
||||||
}
|
}
|
||||||
|
|
||||||
//NiteSec
|
//NiteSec
|
||||||
var nitesecFac = Factions["NiteSec"];
|
var nitesecFac = Factions["NiteSec"];
|
||||||
if (nitesecFac.isBanned == false && nitesecFac.isMember == false &&
|
var nitesecServer = AllServers[SpecialServerIps[SpecialServerNames.NiteSecServer]];
|
||||||
|
if (nitesecServer == null) {
|
||||||
|
console.log("ERROR: Could not find NiteSec Server");
|
||||||
|
} else if (!nitesecFac.isBanned && !nitesecFac.isMember && nitesecServer.manuallyHacked &&
|
||||||
this.hacking_skill >= 200 && homeComp.maxRam >= 32) {
|
this.hacking_skill >= 200 && homeComp.maxRam >= 32) {
|
||||||
invitedFactions.push(nitesecFac);
|
invitedFactions.push(nitesecFac);
|
||||||
}
|
}
|
||||||
@ -451,7 +459,10 @@ PlayerObject.prototype.checkForFactionInvitations = function() {
|
|||||||
|
|
||||||
//CyberSec
|
//CyberSec
|
||||||
var cybersecFac = Factions["CyberSec"];
|
var cybersecFac = Factions["CyberSec"];
|
||||||
if (cybersecFac.isBanned == false && cybersecFac.isMember == false &&
|
var cybersecServer = AllServers[SpecialServerIps[SpecialServerNames.CyberSecServer]];
|
||||||
|
if (cybersecServer == null) {
|
||||||
|
console.log("ERROR: Could not find CyberSec Server");
|
||||||
|
} else if (!cybersecFac.isBanned && !cybersecFac.isMember && cybersecServer.manuallyHacked &&
|
||||||
this.hacking_skill >= 50) {
|
this.hacking_skill >= 50) {
|
||||||
invitedFactions.push(cybersecFac);
|
invitedFactions.push(cybersecFac);
|
||||||
}
|
}
|
||||||
|
@ -367,8 +367,8 @@ function iTutorialEvaluateStep() {
|
|||||||
|
|
||||||
case iTutorialSteps.TutorialPageInfo:
|
case iTutorialSteps.TutorialPageInfo:
|
||||||
iTutorialSetText("This page contains a lot of different documentation about the game's " +
|
iTutorialSetText("This page contains a lot of different documentation about the game's " +
|
||||||
"content and mechanics. If you have any questions about how something works " +
|
"content and mechanics. <strong> I know it's a lot, but I highly suggest you read " +
|
||||||
"make sure you check this out first. That's the end of the tutorial. " +
|
"(or at least skim) through this before you start playing </strong>. That's the end of the tutorial. " +
|
||||||
"Hope you enjoy the game!");
|
"Hope you enjoy the game!");
|
||||||
var next = clearEventListeners("interactive-tutorial-next");
|
var next = clearEventListeners("interactive-tutorial-next");
|
||||||
next.style.display = "inline-block";
|
next.style.display = "inline-block";
|
||||||
|
152
src/Message.js
Normal file
152
src/Message.js
Normal file
@ -0,0 +1,152 @@
|
|||||||
|
/* Message.js */
|
||||||
|
function Message(filename, msg) {
|
||||||
|
this.filename = filename;
|
||||||
|
this.msg = msg;
|
||||||
|
this.recvd = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
Message.prototype.toJSON = function() {
|
||||||
|
return Generic_toJSON("Message", this);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Message.fromJSON = function(value) {
|
||||||
|
return Generic_fromJSON(Message, value.data);
|
||||||
|
}
|
||||||
|
|
||||||
|
Reviver.constructors.Message = Message;
|
||||||
|
|
||||||
|
//Sends message to player, including a pop up
|
||||||
|
function sendMessage(msg) {
|
||||||
|
console.log("sending message: " + msg.filename);
|
||||||
|
msg.recvd = true;
|
||||||
|
showMessage(msg);
|
||||||
|
addMessageToServer(msg, "home");
|
||||||
|
}
|
||||||
|
|
||||||
|
function showMessage(msg) {
|
||||||
|
var txt = "Message received from unknown sender: <br><br>" +
|
||||||
|
"<i>" + msg.msg + "</i><br><br>" +
|
||||||
|
"This message was saved as " + msg.filename + " onto your home computer.";
|
||||||
|
dialogBoxCreate(txt);
|
||||||
|
}
|
||||||
|
|
||||||
|
//Adds a message to a server
|
||||||
|
function addMessageToServer(msg, serverHostname) {
|
||||||
|
var server = GetServerByHostname(serverHostname);
|
||||||
|
if (server == null) {
|
||||||
|
console.log("WARNING: Did not locate " + serverHostname);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
server.messages.push(msg);
|
||||||
|
}
|
||||||
|
|
||||||
|
//Checks if any of the 'timed' messages should be sent
|
||||||
|
function checkForMessagesToSend() {
|
||||||
|
console.log("checkForMessagesToSend() called");
|
||||||
|
var jumper0 = Messages[MessageFilenames.Jumper0];
|
||||||
|
var jumper1 = Messages[MessageFilenames.Jumper1];
|
||||||
|
var jumper2 = Messages[MessageFilenames.Jumper2];
|
||||||
|
var jumper3 = Messages[MessageFilenames.Jumper3];
|
||||||
|
var jumper4 = Messages[MessageFilenames.Jumper4];
|
||||||
|
var jumper5 = Messages[MessageFilenames.Jumper5];
|
||||||
|
var cybersecTest = Messages[MessageFilenames.CyberSecTest];
|
||||||
|
var nitesecTest = Messages[MessageFilenames.NiteSecTest];
|
||||||
|
var bitrunnersTest = Messages[MessageFilenames.BitRunnersTest];
|
||||||
|
|
||||||
|
if (jumper0 && !jumper0.recvd && Player.hacking_skill >= 25) {
|
||||||
|
sendMessage(jumper0);
|
||||||
|
} else if (jumper1 && !jumper1.recvd && Player.hacking_skill >= 40) {
|
||||||
|
sendMessage(jumper1);
|
||||||
|
} else if (cybersecTest && !cybersecTest.recvd && Player.hacking_skill >= 50) {
|
||||||
|
sendMessage(cybersecTest);
|
||||||
|
} else if (jumper2 && !jumper2.recvd && Player.hacking_skill >= 175) {
|
||||||
|
sendMessage(jumper2);
|
||||||
|
} else if (nitesecTest && !nitesecTest.recvd && Player.hacking_skill >= 200) {
|
||||||
|
sendMessage(nitesecTest);
|
||||||
|
} else if (jumper3 && !jumper3.recvd && Player.hacking_skill >= 350) {
|
||||||
|
sendMessage(jumper3);
|
||||||
|
} else if (jumper4 && !jumper4.recvd && Player.hacking_skill >= 490) {
|
||||||
|
sendMessage(jumper4);
|
||||||
|
} else if (bitrunnersTest && !bitrunnersTest.recvd && Player.hacking_skill >= 500) {
|
||||||
|
sendMessage(bitrunnersTest);
|
||||||
|
} if (!jumper5 && !jumper5.recvd && Player.hacking_skill >= 900) {
|
||||||
|
sendMessage(jumper5);
|
||||||
|
Player.getHomeComputer.programs.push(Programs.Flight);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function AddToAllMessages(msg) {
|
||||||
|
Messages[msg.filename] = msg;
|
||||||
|
}
|
||||||
|
|
||||||
|
Messages = {}
|
||||||
|
|
||||||
|
MessageFilenames = {
|
||||||
|
Jumper0: "j0.msg",
|
||||||
|
Jumper1: "j1.msg",
|
||||||
|
Jumper2: "j2.msg",
|
||||||
|
Jumper3: "j3.msg",
|
||||||
|
Jumper4: "j4.msg",
|
||||||
|
Jumper5: "j5.msg",
|
||||||
|
CyberSecTest: "csec-test.msg",
|
||||||
|
NiteSecTest: "nitesec-test.msg",
|
||||||
|
BitRunnersTest: "19dfj3l1nd.msg",
|
||||||
|
}
|
||||||
|
|
||||||
|
function initMessages() {
|
||||||
|
//Reset
|
||||||
|
Messages = {};
|
||||||
|
|
||||||
|
//jump3R Messages
|
||||||
|
AddToAllMessages(new Message(MessageFilenames.Jumper0,
|
||||||
|
"I know you can sense it. I know you're searching for it. " +
|
||||||
|
"It's why you spend night after " +
|
||||||
|
"night at your computer. <br><br>It's real, I've seen it. And I can " +
|
||||||
|
"help you find it. But not right now. You're not ready yet.<br><br>-jump3R"));
|
||||||
|
AddToAllMessages(new Message(MessageFilenames.Jumper1,
|
||||||
|
"Soon you will be contacted by a hacking group known as CyberSec. " +
|
||||||
|
"They can help you with your search. <br><br>" +
|
||||||
|
"You should join them, garner their favor, and " +
|
||||||
|
"exploit them for their Augmentations. But do not trust them. " +
|
||||||
|
"They are not what they seem. No one is.<br><br>" +
|
||||||
|
"-jump3R"));
|
||||||
|
AddToAllMessages(new Message(MessageFilenames.Jumper2,
|
||||||
|
"Do not try to save the world. There is no world to save. If " +
|
||||||
|
"you want to find the truth, worry only about yourself. Ethics and " +
|
||||||
|
"morals will get you killed. <br><br>Watch out for a hacking group known as NiteSec." +
|
||||||
|
"<br><br>-jump3R"));
|
||||||
|
AddToAllMessages(new Message(MessageFilenames.Jumper3,
|
||||||
|
"You must learn to walk before you can run. And you must " +
|
||||||
|
"run before you can fly. Look for the black hand. <br><br>" +
|
||||||
|
"I.I.I.I <br><br>-jump3R"));
|
||||||
|
AddToAllMessages(new Message(MessageFilenames.Jumper4,
|
||||||
|
"To find what you are searching for, you must understand the bits. " +
|
||||||
|
"The bits are all around us. The runners will help you.<br><br>" +
|
||||||
|
"-jump3R"));
|
||||||
|
AddToAllMessages(new Message(MessageFilenames.Jumper5,
|
||||||
|
"Build your wings and fly<br><br>-jump3R<br><br> " +
|
||||||
|
"The fl1ght.exe program was added to your home computer"));
|
||||||
|
|
||||||
|
//Messages from hacking factions
|
||||||
|
AddToAllMessages(new Message(MessageFilenames.CyberSecTest,
|
||||||
|
"We've been watching you. Your skills are very impressive. But you're wasting " +
|
||||||
|
"your talents. If you join us, you can put your skills to good use and change " +
|
||||||
|
"the world for the better. If you join us, we can unlock your full potential. <br><br>" +
|
||||||
|
"But first, you must pass our test. Find and hack our server using the Terminal. <br><br>" +
|
||||||
|
"-CyberSec"));
|
||||||
|
AddToAllMessages(new Message(MessageFilenames.NiteSecTest,
|
||||||
|
"People say that the corrupted governments and corporations rule the world. " +
|
||||||
|
"Yes, maybe they do. But do you know who everyone really fears? People " +
|
||||||
|
"like us. Because they can't hide from us. Because they can't fight shadows " +
|
||||||
|
"and ideas with bullets. <br><br>" +
|
||||||
|
"Join us, and people will fear you, too. <br><br>" +
|
||||||
|
"Find and hack our hidden server using the Terminal. Then, we will contact you again." +
|
||||||
|
"<br><br>-NiteSec"));
|
||||||
|
AddToAllMessages(new Message(MessageFilenames.BitRunnersTest,
|
||||||
|
"We know what you are doing. We know what drives you. We know " +
|
||||||
|
"what you are looking for. <br><br> " +
|
||||||
|
"We can help you find the answers.<br><br>" +
|
||||||
|
"run4theh111z"));
|
||||||
|
|
||||||
|
}
|
@ -120,7 +120,6 @@ function evaluate(exp, workerScript) {
|
|||||||
var numConds = exp.cond.length;
|
var numConds = exp.cond.length;
|
||||||
var numThens = exp.then.length;
|
var numThens = exp.then.length;
|
||||||
if (numConds == 0 || numThens == 0 || numConds != numThens) {
|
if (numConds == 0 || numThens == 0 || numConds != numThens) {
|
||||||
console.log("Number of ifs and conds dont match. Rejecting");
|
|
||||||
reject("|" + workerScript.serverIp + "|" + workerScript.name + "|Number of conds and thens in if structure don't match (or there are none)");
|
reject("|" + workerScript.serverIp + "|" + workerScript.name + "|Number of conds and thens in if structure don't match (or there are none)");
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -128,20 +127,17 @@ function evaluate(exp, workerScript) {
|
|||||||
evalIfPromise.then(function(res) {
|
evalIfPromise.then(function(res) {
|
||||||
if (res) {
|
if (res) {
|
||||||
//One of the if/elif statements evaluated to true
|
//One of the if/elif statements evaluated to true
|
||||||
console.log("done with if");
|
|
||||||
resolve("if statement done");
|
resolve("if statement done");
|
||||||
} else {
|
} else {
|
||||||
//None of the if/elif statements were true. Evaluate else if there is one
|
//None of the if/elif statements were true. Evaluate else if there is one
|
||||||
if (exp.else) {
|
if (exp.else) {
|
||||||
var elseEval = evaluate(exp.else, workerScript);
|
var elseEval = evaluate(exp.else, workerScript);
|
||||||
elseEval.then(function(res) {
|
elseEval.then(function(res) {
|
||||||
console.log("if statement done with else");
|
|
||||||
resolve("if statement done with else");
|
resolve("if statement done with else");
|
||||||
}, function(e) {
|
}, function(e) {
|
||||||
reject(e);
|
reject(e);
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
console.log("no else statement, resolving");
|
|
||||||
resolve("if statement done");
|
resolve("if statement done");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -960,12 +956,9 @@ function evaluateIf(exp, workerScript, i) {
|
|||||||
} else {
|
} else {
|
||||||
var cond = evaluate(exp.cond[i], workerScript);
|
var cond = evaluate(exp.cond[i], workerScript);
|
||||||
cond.then(function(condRes) {
|
cond.then(function(condRes) {
|
||||||
console.log("cond evaluated to: " + condRes);
|
|
||||||
if (condRes) {
|
if (condRes) {
|
||||||
console.log("Evaluating then: " + exp.then[i]);
|
|
||||||
var evalThen = evaluate(exp.then[i], workerScript);
|
var evalThen = evaluate(exp.then[i], workerScript);
|
||||||
evalThen.then(function(res) {
|
evalThen.then(function(res) {
|
||||||
console.log("If statement done");
|
|
||||||
resolve(true);
|
resolve(true);
|
||||||
}, function(e) {
|
}, function(e) {
|
||||||
reject(e);
|
reject(e);
|
||||||
|
@ -201,5 +201,8 @@ function prestigeAugmentation() {
|
|||||||
$("#terminal tr:not(:last)").remove();
|
$("#terminal tr:not(:last)").remove();
|
||||||
postNetburnerText();
|
postNetburnerText();
|
||||||
|
|
||||||
|
//Messages
|
||||||
|
initMessages();
|
||||||
|
|
||||||
Engine.loadTerminalContent();
|
Engine.loadTerminalContent();
|
||||||
}
|
}
|
@ -11,6 +11,7 @@ function BitburnerSaveObject() {
|
|||||||
this.SpecialServerIpsSave = "";
|
this.SpecialServerIpsSave = "";
|
||||||
this.AugmentationsSave = "";
|
this.AugmentationsSave = "";
|
||||||
this.AliasesSave = "";
|
this.AliasesSave = "";
|
||||||
|
this.MessagesSave = "";
|
||||||
}
|
}
|
||||||
|
|
||||||
BitburnerSaveObject.prototype.saveGame = function() {
|
BitburnerSaveObject.prototype.saveGame = function() {
|
||||||
@ -21,6 +22,7 @@ BitburnerSaveObject.prototype.saveGame = function() {
|
|||||||
this.SpecialServerIpsSave = JSON.stringify(SpecialServerIps);
|
this.SpecialServerIpsSave = JSON.stringify(SpecialServerIps);
|
||||||
this.AugmentationsSave = JSON.stringify(Augmentations);
|
this.AugmentationsSave = JSON.stringify(Augmentations);
|
||||||
this.AliasesSave = JSON.stringify(Aliases);
|
this.AliasesSave = JSON.stringify(Aliases);
|
||||||
|
this.MessagesSave = JSON.stringify(Messages);
|
||||||
|
|
||||||
var saveString = btoa(unescape(encodeURIComponent(JSON.stringify(this))));
|
var saveString = btoa(unescape(encodeURIComponent(JSON.stringify(this))));
|
||||||
window.localStorage.setItem("bitburnerSave", saveString);
|
window.localStorage.setItem("bitburnerSave", saveString);
|
||||||
@ -52,7 +54,15 @@ loadGame = function(saveObj) {
|
|||||||
} else {
|
} else {
|
||||||
Aliases = {};
|
Aliases = {};
|
||||||
}
|
}
|
||||||
|
if (saveObj.hasOwnProperty("MessagesSave")) {
|
||||||
|
try {
|
||||||
|
Messages = JSON.parse(saveObj.MessagesSave, Reviver);
|
||||||
|
} catch(e) {
|
||||||
|
initMessages();
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
initMessages();
|
||||||
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@ -13,6 +13,7 @@ function Server() {
|
|||||||
//Access information
|
//Access information
|
||||||
this.hasAdminRights = false; //Whether player has admin rights
|
this.hasAdminRights = false; //Whether player has admin rights
|
||||||
this.purchasedByPlayer = false;
|
this.purchasedByPlayer = false;
|
||||||
|
this.manuallyHacked = false; //Flag that tracks whether or not the server has been hacked at least once
|
||||||
|
|
||||||
//RAM, CPU speed and Scripts
|
//RAM, CPU speed and Scripts
|
||||||
this.maxRam = 1; //GB
|
this.maxRam = 1; //GB
|
||||||
@ -131,8 +132,6 @@ Server.fromJSON = function(value) {
|
|||||||
|
|
||||||
Reviver.constructors.Server = Server;
|
Reviver.constructors.Server = Server;
|
||||||
|
|
||||||
//world_daemon: new Server(), //Final server for 2nd tier prestige. Discover that the world is a simulation
|
|
||||||
|
|
||||||
initForeignServers = function() {
|
initForeignServers = function() {
|
||||||
//MegaCorporations
|
//MegaCorporations
|
||||||
var ECorpServer = new Server();
|
var ECorpServer = new Server();
|
||||||
@ -201,8 +200,7 @@ initForeignServers = function() {
|
|||||||
FulcrumSecretTechnologiesServer.setHackingParameters(999, 1000000, 99, 1);
|
FulcrumSecretTechnologiesServer.setHackingParameters(999, 1000000, 99, 1);
|
||||||
FulcrumSecretTechnologiesServer.setPortProperties(5);
|
FulcrumSecretTechnologiesServer.setPortProperties(5);
|
||||||
AddToAllServers(FulcrumSecretTechnologiesServer);
|
AddToAllServers(FulcrumSecretTechnologiesServer);
|
||||||
|
SpecialServerIps.addIp(SpecialServerNames.FulcrumSecretTechnologies, FulcrumSecretTechnologiesServer.ip);
|
||||||
SpecialServerIps.addIp("Fulcrum Secret Technologies Server", FulcrumSecretTechnologiesServer.ip);
|
|
||||||
|
|
||||||
var StormTechnologiesServer = new Server();
|
var StormTechnologiesServer = new Server();
|
||||||
StormTechnologiesServer.init(createRandomIp(), "stormtech", "Storm Technologies", true, false, false, false, 0);
|
StormTechnologiesServer.init(createRandomIp(), "stormtech", "Storm Technologies", true, false, false, false, 0);
|
||||||
@ -519,47 +517,72 @@ initForeignServers = function() {
|
|||||||
//Faction servers, cannot hack money from these
|
//Faction servers, cannot hack money from these
|
||||||
var BitRunnersServer = new Server();
|
var BitRunnersServer = new Server();
|
||||||
BitRunnersServer.init(createRandomIp(), "run4theh111z", "The Runners", true, false, false, false, 0);
|
BitRunnersServer.init(createRandomIp(), "run4theh111z", "The Runners", true, false, false, false, 0);
|
||||||
|
BitRunnersServer.setHackingParameters(getRandomInt(505, 550), 0, 0, 0);
|
||||||
BitRunnersServer.setPortProperties(4);
|
BitRunnersServer.setPortProperties(4);
|
||||||
AddToAllServers(BitRunnersServer);
|
AddToAllServers(BitRunnersServer);
|
||||||
|
SpecialServerIps.addIp(SpecialServerNames.BitRunnersServer, BitRunnersServer.ip);
|
||||||
|
|
||||||
var TheBlackHandServer = new Server();
|
var TheBlackHandServer = new Server();
|
||||||
TheBlackHandServer.init(createRandomIp(), "I.I.I.I", "I.I.I.I", true, false, false, false, false, 0);
|
TheBlackHandServer.init(createRandomIp(), "I.I.I.I", "I.I.I.I", true, false, false, false, false, 0);
|
||||||
|
TheBlackHandServer.setHackingParameters(getRandomInt(303, 325), 0, 0, 0);
|
||||||
TheBlackHandServer.setPortProperties(3);
|
TheBlackHandServer.setPortProperties(3);
|
||||||
AddToAllServers(TheBlackHandServer);
|
AddToAllServers(TheBlackHandServer);
|
||||||
|
SpecialServerIps.addIp(SpecialServerNames.TheBlackHandServer, TheBlackHandServer.ip);
|
||||||
|
|
||||||
var NiteSecServer = new Server();
|
var NiteSecServer = new Server();
|
||||||
NiteSecServer.init(createRandomIp(), "avmnite-02h", "NiteSec", true, false, false, false, 0);
|
NiteSecServer.init(createRandomIp(), "avmnite-02h", "NiteSec", true, false, false, false, 0);
|
||||||
|
NiteSecServer.setHackingParameters(getRandomInt(202, 220), 0, 0, 0);
|
||||||
NiteSecServer.setPortProperties(2);
|
NiteSecServer.setPortProperties(2);
|
||||||
AddToAllServers(NiteSecServer);
|
AddToAllServers(NiteSecServer);
|
||||||
|
SpecialServerIps.addIp(SpecialServerNames.NiteSecServer, NiteSecServer.ip);
|
||||||
|
|
||||||
var DarkArmyServer = new Server();
|
var DarkArmyServer = new Server();
|
||||||
DarkArmyServer.init(createRandomIp(), ".", ".", true, false, false, false, 0);
|
DarkArmyServer.init(createRandomIp(), ".", ".", true, false, false, false, 0);
|
||||||
DarkArmyServer.setPortProperties(5);
|
DarkArmyServer.setHackingParameters(getRandomInt(505, 550), 0, 0, 0);
|
||||||
|
DarkArmyServer.setPortProperties(4);
|
||||||
AddToAllServers(DarkArmyServer);
|
AddToAllServers(DarkArmyServer);
|
||||||
|
SpecialServerIps.addIp(SpecialServerNames.TheDarkArmyServer, DarkArmyServer.ip);
|
||||||
|
|
||||||
var CyberSecServer = new Server();
|
var CyberSecServer = new Server();
|
||||||
CyberSecServer.init(createRandomIp(), "CSEC", "CyberSec", true, false, false, false, 0);
|
CyberSecServer.init(createRandomIp(), "CSEC", "CyberSec", true, false, false, false, 0);
|
||||||
CyberSecServer.setPortProperties(2);
|
CyberSecServer.setHackingParameters(getRandomInt(51, 60), 0, 0, 0);
|
||||||
|
CyberSecServer.setPortProperties(1);
|
||||||
AddToAllServers(CyberSecServer);
|
AddToAllServers(CyberSecServer);
|
||||||
|
SpecialServerIps.addIp(SpecialServerNames.CyberSecServer, CyberSecServer.ip);
|
||||||
|
|
||||||
|
var DaedalusServer = new Server();
|
||||||
|
DaedalusServer.init(createRandomIp(), "Icarus", "Icarus", true, false, false, false, 0);
|
||||||
|
DaedalusServer.setHackingParameters(925, 0, 0, 0);
|
||||||
|
DaedalusServer.setPortProperties(5);
|
||||||
|
AddToAllServers(DaedalusServer);
|
||||||
|
SpecialServerIps.addIp(SpecialServerNames.DaedalusServer, DaedalusServer.ip);
|
||||||
|
|
||||||
|
//Super special Servers
|
||||||
|
var WorldDaemon = new Server();
|
||||||
|
WorldDaemon.init(createRandomIp(), SpecialServerNames.WorldDaemon, SpecialServerNames.WorldDaemon, true, false, false, false, 0);
|
||||||
|
WorldDaemon.setHackingParameters(950, 0, 0, 0);
|
||||||
|
WorldDaemon.setPortProperties(5);
|
||||||
|
AddToAllServers(WorldDaemon);
|
||||||
|
SpecialServerIps.addIp(SpecialServerNames.WorldDaemon, WorldDaemon.ip);
|
||||||
|
|
||||||
|
|
||||||
/* Create a randomized network for all the foreign servers */
|
/* Create a randomized network for all the foreign servers */
|
||||||
//Groupings for creating a randomized network
|
//Groupings for creating a randomized network
|
||||||
var NetworkGroup1 = [IronGymServer, FoodNStuffServer, SigmaCosmeticsServer, JoesGunsServer, HongFangTeaHouseServer, HaraKiriSushiBarServer];
|
var NetworkGroup1 = [IronGymServer, FoodNStuffServer, SigmaCosmeticsServer, JoesGunsServer, HongFangTeaHouseServer, HaraKiriSushiBarServer];
|
||||||
var NetworkGroup2 = [MaxHardwareServer, NectarNightclubServer, Zer0NightclubServer];
|
var NetworkGroup2 = [MaxHardwareServer, NectarNightclubServer, Zer0NightclubServer, CyberSecServer];
|
||||||
var NetworkGroup3 = [OmegaSoftwareServer, PhantasyServer, SilverHelixServer, NeoNightclubServer];
|
var NetworkGroup3 = [OmegaSoftwareServer, PhantasyServer, SilverHelixServer, NeoNightclubServer];
|
||||||
var NetworkGroup4 = [CrushFitnessGymServer, NetLinkTechnologiesServer, CompuTekServer, TheHubServer, JohnsonOrthopedicsServer];
|
var NetworkGroup4 = [CrushFitnessGymServer, NetLinkTechnologiesServer, CompuTekServer, TheHubServer, JohnsonOrthopedicsServer, NiteSecServer];
|
||||||
var NetworkGroup5 = [CatalystVenturesServer, SysCoreSecuritiesServer, SummitUniversityServer, ZBInstituteOfTechnologyServer, RothmanUniversityServer];
|
var NetworkGroup5 = [CatalystVenturesServer, SysCoreSecuritiesServer, SummitUniversityServer, ZBInstituteOfTechnologyServer, RothmanUniversityServer, TheBlackHandServer];
|
||||||
var NetworkGroup6 = [LexoCorpServer, RhoConstructionServer, AlphaEnterprisesServer, AevumPoliceServer, MilleniumFitnessGymServer, CyberSecServer, NiteSecServer];
|
var NetworkGroup6 = [LexoCorpServer, RhoConstructionServer, AlphaEnterprisesServer, AevumPoliceServer, MilleniumFitnessGymServer, CyberSecServer, NiteSecServer];
|
||||||
var NetworkGroup7 = [GlobalPharmaceuticalsServer, AeroCorpServer, GalacticCyberSystemsServer, SnapFitnessGymServer];
|
var NetworkGroup7 = [GlobalPharmaceuticalsServer, AeroCorpServer, GalacticCyberSystemsServer, SnapFitnessGymServer];
|
||||||
var NetworkGroup8 = [DeltaOneServer, UnitaLifeGroupServer, OmniaCybersystemsServer];
|
var NetworkGroup8 = [DeltaOneServer, UnitaLifeGroupServer, OmniaCybersystemsServer, BitRunnersServer];
|
||||||
var NetworkGroup9 = [ZeusMedicalServer, SolarisSpaceSystemsServer, UniversalEnergyServer, IcarusMicrosystemsServer, DefCommServer];
|
var NetworkGroup9 = [ZeusMedicalServer, SolarisSpaceSystemsServer, UniversalEnergyServer, IcarusMicrosystemsServer, DefCommServer];
|
||||||
var NetworkGroup10 = [NovaMedicalServer, ZBDefenseServer, TaiYangDigitalServer, InfoCommServer];
|
var NetworkGroup10 = [NovaMedicalServer, ZBDefenseServer, TaiYangDigitalServer, InfoCommServer];
|
||||||
var NetworkGroup11 = [AppliedEnergeticsServer, MicrodyneTechnologiesServer, TitanLabsServer, BitRunnersServer];
|
var NetworkGroup11 = [AppliedEnergeticsServer, MicrodyneTechnologiesServer, TitanLabsServer, BitRunnersServer];
|
||||||
var NetworkGroup12 = [VitaLifeServer, HeliosLabsServer, StormTechnologiesServer, FulcrumTechnologiesServer];
|
var NetworkGroup12 = [VitaLifeServer, HeliosLabsServer, StormTechnologiesServer, FulcrumTechnologiesServer];
|
||||||
var NetworkGroup13 = [KuaiGongInternationalServer, FourSigmaServer, OmniTekIncorporatedServer, DarkArmyServer];
|
var NetworkGroup13 = [KuaiGongInternationalServer, FourSigmaServer, OmniTekIncorporatedServer, DarkArmyServer];
|
||||||
var NetworkGroup14 = [PowerhouseGymServer, ClarkeIncorporatedServer, NWOServer, BladeIndustriesServer, BachmanAndAssociatesServer];
|
var NetworkGroup14 = [PowerhouseGymServer, ClarkeIncorporatedServer, NWOServer, BladeIndustriesServer, BachmanAndAssociatesServer];
|
||||||
var NetworkGroup15 = [FulcrumSecretTechnologiesServer, MegaCorpServer, ECorpServer];
|
var NetworkGroup15 = [FulcrumSecretTechnologiesServer, MegaCorpServer, ECorpServer, DaedalusServer];
|
||||||
|
|
||||||
for (var i = 0; i < NetworkGroup2.length; i++) {
|
for (var i = 0; i < NetworkGroup2.length; i++) {
|
||||||
var randomServerFromPrevGroup = NetworkGroup1[Math.floor(Math.random() * NetworkGroup1.length)];
|
var randomServerFromPrevGroup = NetworkGroup1[Math.floor(Math.random() * NetworkGroup1.length)];
|
||||||
|
@ -1,6 +1,15 @@
|
|||||||
/* Holds IP of Special Servers */
|
/* Holds IP of Special Servers */
|
||||||
function SpecialServerIpsMap() {
|
SpecialServerNames = {
|
||||||
|
FulcrumSecretTechnologies: "Fulcrum Secret Technologies Server",
|
||||||
|
CyberSecServer: "CyberSec Server",
|
||||||
|
NiteSecServer: "NiteSec Server",
|
||||||
|
TheBlackHandServer: "The Black Hand Server",
|
||||||
|
BitRunnersServer: "BitRunners Server",
|
||||||
|
TheDarkArmyServer: "The Dark Army Server",
|
||||||
|
DaedalusServer: "Daedalus Server",
|
||||||
|
WorldDaemon: "w0r1d_d43m0n",
|
||||||
}
|
}
|
||||||
|
function SpecialServerIpsMap() {}
|
||||||
|
|
||||||
SpecialServerIpsMap.prototype.addIp = function(name, ip) {
|
SpecialServerIpsMap.prototype.addIp = function(name, ip) {
|
||||||
this[name] = ip;
|
this[name] = ip;
|
||||||
|
@ -250,6 +250,13 @@ function determineAllPossibilitiesForTabCompletion(input, index=0) {
|
|||||||
}
|
}
|
||||||
return allPos;
|
return allPos;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (input.startsWith("cat ")) {
|
||||||
|
for (var i = 0; i < currServ.messages.length; ++i) {
|
||||||
|
allPos.push(currServ.messages[i].filename);
|
||||||
|
}
|
||||||
|
return allPos;
|
||||||
|
}
|
||||||
return allPos;
|
return allPos;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -272,7 +279,8 @@ var Terminal = {
|
|||||||
//Complete the hack/analyze command
|
//Complete the hack/analyze command
|
||||||
finishHack: function(cancelled = false) {
|
finishHack: function(cancelled = false) {
|
||||||
if (cancelled == false) {
|
if (cancelled == false) {
|
||||||
console.log("Hack done. Determining success/failure of hack. Re-enabling terminal and changing the id of the hack progress bar");
|
var server = Player.getCurrentServer();
|
||||||
|
server.manuallyHacked = true;
|
||||||
|
|
||||||
//Calculate whether hack was successful
|
//Calculate whether hack was successful
|
||||||
var hackChance = Player.calculateHackingChance();
|
var hackChance = Player.calculateHackingChance();
|
||||||
@ -282,23 +290,23 @@ var Terminal = {
|
|||||||
var expGainedOnFailure = (expGainedOnSuccess / 4);
|
var expGainedOnFailure = (expGainedOnSuccess / 4);
|
||||||
if (rand < hackChance) { //Success!
|
if (rand < hackChance) { //Success!
|
||||||
var moneyGained = Player.calculatePercentMoneyHacked();
|
var moneyGained = Player.calculatePercentMoneyHacked();
|
||||||
moneyGained = Math.floor(Player.getCurrentServer().moneyAvailable * moneyGained);
|
moneyGained = Math.floor(server.moneyAvailable * moneyGained);
|
||||||
|
|
||||||
//Safety check
|
//Safety check
|
||||||
if (moneyGained <= 0) {moneyGained = 0;}
|
if (moneyGained <= 0) {moneyGained = 0;}
|
||||||
|
|
||||||
Player.getCurrentServer().moneyAvailable -= moneyGained;
|
server.moneyAvailable -= moneyGained;
|
||||||
Player.gainMoney(moneyGained);
|
Player.gainMoney(moneyGained);
|
||||||
|
|
||||||
Player.gainHackingExp(expGainedOnSuccess)
|
Player.gainHackingExp(expGainedOnSuccess)
|
||||||
|
|
||||||
Player.getCurrentServer().fortify(CONSTANTS.ServerFortifyAmount);
|
server.fortify(CONSTANTS.ServerFortifyAmount);
|
||||||
|
|
||||||
post("Hack successful! Gained $" + formatNumber(moneyGained, 2) + " and " + formatNumber(expGainedOnSuccess, 4) + " hacking EXP");
|
post("Hack successful! Gained $" + formatNumber(moneyGained, 2) + " and " + formatNumber(expGainedOnSuccess, 4) + " hacking EXP");
|
||||||
} else { //Failure
|
} else { //Failure
|
||||||
//Player only gains 25% exp for failure? TODO Can change this later to balance
|
//Player only gains 25% exp for failure? TODO Can change this later to balance
|
||||||
Player.gainHackingExp(expGainedOnFailure)
|
Player.gainHackingExp(expGainedOnFailure)
|
||||||
post("Failed to hack " + Player.getCurrentServer().hostname + ". Gained " + formatNumber(expGainedOnFailure, 4) + " hacking EXP");
|
post("Failed to hack " + server.hostname + ". Gained " + formatNumber(expGainedOnFailure, 4) + " hacking EXP");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -550,6 +558,24 @@ var Terminal = {
|
|||||||
break;
|
break;
|
||||||
case "buy":
|
case "buy":
|
||||||
executeDarkwebTerminalCommand(commandArray);
|
executeDarkwebTerminalCommand(commandArray);
|
||||||
|
break;
|
||||||
|
case "cat":
|
||||||
|
if (commandArray.length != 2) {
|
||||||
|
post("Incorrect usage of cat command. Usage: cat [message]"); return;
|
||||||
|
}
|
||||||
|
var filename = commandArray[1];
|
||||||
|
//Can only edit script files
|
||||||
|
if (filename.endsWith(".msg") == false) {
|
||||||
|
post("Error: Only .msg files are viewable with cat (filename must end with .msg)"); return;
|
||||||
|
}
|
||||||
|
var s = Player.getCurrentServer();
|
||||||
|
for (var i = 0; i < s.messages.length; ++i) {
|
||||||
|
if (s.messages[i].filename == filename) {
|
||||||
|
showMessage(s.messages[i]);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
post("Error: No such file " + filename);
|
||||||
break;
|
break;
|
||||||
case "clear":
|
case "clear":
|
||||||
case "cls":
|
case "cls":
|
||||||
@ -877,11 +903,15 @@ var Terminal = {
|
|||||||
var allFiles = [];
|
var allFiles = [];
|
||||||
|
|
||||||
//Get all of the programs and scripts on the machine into one temporary array
|
//Get all of the programs and scripts on the machine into one temporary array
|
||||||
for (var i = 0; i < Player.getCurrentServer().programs.length; i++) {
|
var s = Player.getCurrentServer();
|
||||||
allFiles.push(Player.getCurrentServer().programs[i]);
|
for (var i = 0; i < s.programs.length; i++) {
|
||||||
|
allFiles.push(s.programs[i]);
|
||||||
}
|
}
|
||||||
for (var i = 0; i < Player.getCurrentServer().scripts.length; i++) {
|
for (var i = 0; i < s.scripts.length; i++) {
|
||||||
allFiles.push(Player.getCurrentServer().scripts[i].filename);
|
allFiles.push(s.scripts[i].filename);
|
||||||
|
}
|
||||||
|
for (var i = 0; i < s.messages.length; i++) {
|
||||||
|
allFiles.push(s.messages[i].filename);
|
||||||
}
|
}
|
||||||
|
|
||||||
//Sort the files alphabetically then print each
|
//Sort the files alphabetically then print each
|
||||||
|
@ -602,8 +602,9 @@ var Engine = {
|
|||||||
updateDisplays: 3, //Update displays such as Active Scripts display and character display
|
updateDisplays: 3, //Update displays such as Active Scripts display and character display
|
||||||
createProgramNotifications: 10, //Checks whether any programs can be created and notifies
|
createProgramNotifications: 10, //Checks whether any programs can be created and notifies
|
||||||
serverGrowth: 450, //Process server growth every minute and a half
|
serverGrowth: 450, //Process server growth every minute and a half
|
||||||
checkFactionInvitations: 1000, //Check whether you qualify for any faction invitations every 5 minutes
|
checkFactionInvitations: 250, //Check whether you qualify for any faction invitations every 5 minutes
|
||||||
passiveFactionGrowth: 600,
|
passiveFactionGrowth: 600,
|
||||||
|
messages: 300,
|
||||||
},
|
},
|
||||||
|
|
||||||
decrementAllCounters: function(numCycles = 1) {
|
decrementAllCounters: function(numCycles = 1) {
|
||||||
@ -667,7 +668,7 @@ var Engine = {
|
|||||||
var randFaction = invitedFactions[Math.floor(Math.random() * invitedFactions.length)];
|
var randFaction = invitedFactions[Math.floor(Math.random() * invitedFactions.length)];
|
||||||
inviteToFaction(randFaction);
|
inviteToFaction(randFaction);
|
||||||
}
|
}
|
||||||
Engine.Counters.checkFactionInvitations = 1000;
|
Engine.Counters.checkFactionInvitations = 250;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (Engine.Counters.passiveFactionGrowth <= 0) {
|
if (Engine.Counters.passiveFactionGrowth <= 0) {
|
||||||
@ -675,6 +676,11 @@ var Engine = {
|
|||||||
processPassiveFactionRepGain(adjustedCycles);
|
processPassiveFactionRepGain(adjustedCycles);
|
||||||
Engine.Counters.passiveFactionGrowth = 600;
|
Engine.Counters.passiveFactionGrowth = 600;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (Engine.Counters.messages <= 0) {
|
||||||
|
checkForMessagesToSend();
|
||||||
|
Engine.Counters.messages = 300;
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
/* Calculates the hack progress for a manual (non-scripted) hack and updates the progress bar/time accordingly */
|
/* Calculates the hack progress for a manual (non-scripted) hack and updates the progress bar/time accordingly */
|
||||||
|
@ -29,7 +29,6 @@ var dialogBoxOpened = false;
|
|||||||
var dialogBoxCount = 0;
|
var dialogBoxCount = 0;
|
||||||
|
|
||||||
dialogBoxCreate = function(txt) {
|
dialogBoxCreate = function(txt) {
|
||||||
console.log("created");
|
|
||||||
var container = document.createElement("div");
|
var container = document.createElement("div");
|
||||||
container.setAttribute("class", "dialog-box-container");
|
container.setAttribute("class", "dialog-box-container");
|
||||||
|
|
||||||
|
@ -29,3 +29,7 @@ function clearEventListeners(elemId) {
|
|||||||
elem.parentNode.replaceChild(newElem, elem);
|
elem.parentNode.replaceChild(newElem, elem);
|
||||||
return newElem;
|
return newElem;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function getRandomInt(min, max) {
|
||||||
|
return Math.floor(Math.random() * (max - min + 1)) + min;
|
||||||
|
}
|
@ -36,7 +36,7 @@ purchaseRamForHomeBoxCreate = function() {
|
|||||||
//Calculate cost
|
//Calculate cost
|
||||||
//Have cost increase by some percentage each time RAM has been upgraded
|
//Have cost increase by some percentage each time RAM has been upgraded
|
||||||
var cost = currentRam * CONSTANTS.BaseCostFor1GBOfRamHome;
|
var cost = currentRam * CONSTANTS.BaseCostFor1GBOfRamHome;
|
||||||
var mult = Math.pow(1.35, numUpgrades);
|
var mult = Math.pow(1.36, numUpgrades);
|
||||||
cost = cost * mult;
|
cost = cost * mult;
|
||||||
|
|
||||||
purchaseRamForHomeBoxSetText("Would you like to purchase additional RAM for your home computer? <br><br>" +
|
purchaseRamForHomeBoxSetText("Would you like to purchase additional RAM for your home computer? <br><br>" +
|
||||||
|
Loading…
Reference in New Issue
Block a user