Updating documentation and Netscripy syntax highlighting for v0.40.1 community update. Bitrunners now has CranialSignalProcessors 3-5. CyberSec now has Cranial Signal Processors 1-2.

This commit is contained in:
Daniel Xie 2018-08-05 03:37:28 -04:00
parent d1b3fb9b41
commit faa5e807d5
8 changed files with 53 additions and 28 deletions

File diff suppressed because one or more lines are too long

42
dist/vendor.bundle.js vendored

File diff suppressed because one or more lines are too long

@ -311,6 +311,18 @@ getCompanyFavor
This function will return the amount of favor you have at the specified company. This function will return the amount of favor you have at the specified company.
If the company passed in as an argument is invalid, -1 will be returned. If the company passed in as an argument is invalid, -1 will be returned.
getCompanyFavorGain
-------------------
.. js:function:: getCompanyFavorGain(companyName)
:param string companyName: Name of the company. CASE-SENSITIVE
If you are not in BitNode-4, then you must have Level 2 of Source-File 4 in order to use this function.
This function will return the amount of favor you will gain for the specified company
when you reset by installing Augmentations.
checkFactionInvitations checkFactionInvitations
----------------------- -----------------------
@ -386,6 +398,17 @@ getFactionFavor
If you are not in BitNode-4, then you must have Level 2 of Source-File 4 in order to use this function. If you are not in BitNode-4, then you must have Level 2 of Source-File 4 in order to use this function.
This function returns the amount of favor you have for the specified faction. This function returns the amount of favor you have for the specified faction.
getFactionFavorGain
-------------------
.. js:function:: getFactionFavorGain(factionName)
:param string factionName: Name of faction. CASE-SENSITIVE
If you are not in BitNode-4, then you must have Level 2 of Source-File 4 in order to use this function.
This function returns the amount of favor you will gain for the specified faction when you reset by installing Augmentations.
createProgram createProgram
------------- -------------

@ -81,6 +81,7 @@ let NetscriptFunctions =
"gymWorkout|travelToCity|purchaseTor|purchaseProgram|upgradeHomeRam|" + "gymWorkout|travelToCity|purchaseTor|purchaseProgram|upgradeHomeRam|" +
"getUpgradeHomeRamCost|workForCompany|applyToCompany|getCompanyRep|" + "getUpgradeHomeRamCost|workForCompany|applyToCompany|getCompanyRep|" +
"getCompanyFavor|stopAction|getFactionFavor|" + "getCompanyFavor|stopAction|getFactionFavor|" +
"getFavorToDonate|getFactionFavorGain|getCompanyFavorGain|" +
"checkFactionInvitations|joinFaction|workForFaction|getFactionRep|" + "checkFactionInvitations|joinFaction|workForFaction|getFactionRep|" +
"createProgram|commitCrime|getCrimeChance|getOwnedAugmentations|" + "createProgram|commitCrime|getCrimeChance|getOwnedAugmentations|" +
"getOwnedSourceFiles|getAugmentationsFromFaction|" + "getOwnedSourceFiles|getAugmentationsFromFaction|" +

@ -746,7 +746,7 @@ function initAugmentations() {
"Increases the player's hacking skill by 7%.", "Increases the player's hacking skill by 7%.",
prereqs:[AugmentationNames.CranialSignalProcessorsG1] prereqs:[AugmentationNames.CranialSignalProcessorsG1]
}); });
CranialSignalProcessorsG2.addToFactions(["NiteSec"]); CranialSignalProcessorsG2.addToFactions(["CyberSec", "NiteSec"]);
if (augmentationExists(AugmentationNames.CranialSignalProcessorsG2)) { if (augmentationExists(AugmentationNames.CranialSignalProcessorsG2)) {
delete Augmentations[AugmentationNames.CranialSignalProcessorsG2]; delete Augmentations[AugmentationNames.CranialSignalProcessorsG2];
} }
@ -764,7 +764,7 @@ function initAugmentations() {
"Increases the player's hacking skill by 9%.", "Increases the player's hacking skill by 9%.",
prereqs:[AugmentationNames.CranialSignalProcessorsG2] prereqs:[AugmentationNames.CranialSignalProcessorsG2]
}); });
CranialSignalProcessorsG3.addToFactions(["NiteSec", "The Black Hand"]); CranialSignalProcessorsG3.addToFactions(["NiteSec", "The Black Hand", "BitRunners"]);
if (augmentationExists(AugmentationNames.CranialSignalProcessorsG3)) { if (augmentationExists(AugmentationNames.CranialSignalProcessorsG3)) {
delete Augmentations[AugmentationNames.CranialSignalProcessorsG3]; delete Augmentations[AugmentationNames.CranialSignalProcessorsG3];
} }
@ -782,7 +782,7 @@ function initAugmentations() {
"Increases the amount of money the player can inject into servers using grow() by 25%.", "Increases the amount of money the player can inject into servers using grow() by 25%.",
prereqs:[AugmentationNames.CranialSignalProcessorsG3] prereqs:[AugmentationNames.CranialSignalProcessorsG3]
}); });
CranialSignalProcessorsG4.addToFactions(["The Black Hand"]); CranialSignalProcessorsG4.addToFactions(["The Black Hand", "BitRunners"]);
if (augmentationExists(AugmentationNames.CranialSignalProcessorsG4)) { if (augmentationExists(AugmentationNames.CranialSignalProcessorsG4)) {
delete Augmentations[AugmentationNames.CranialSignalProcessorsG4]; delete Augmentations[AugmentationNames.CranialSignalProcessorsG4];
} }

@ -1824,8 +1824,8 @@ Bladeburner.prototype.createOverviewContent = function() {
DomElems.overviewBonusTime = createElement("p", { DomElems.overviewBonusTime = createElement("p", {
innerText: "Bonus time: ", innerText: "Bonus time: ",
display: "inline-block", display: "inline-block",
tooltip: "You gain bonus time while offline or when you're not performing any action. " + tooltip: "You gain bonus time while offline or when the game is inactive (e.g. when the tab is throttled by browser). " +
"Bonus time makes the game progress faster." "Bonus time makes the Bladeburner mechanic progress faster, up to 5x the normal speed."
}); });
DomElems.overviewSkillPoints = createElement("p", {display:"block"}); DomElems.overviewSkillPoints = createElement("p", {display:"block"});

@ -498,6 +498,7 @@ let CONSTANTS = {
"* Accumulated 'bonus' time in Bladeburner is now displayed in the UI (by hydroflame)<br>" + "* Accumulated 'bonus' time in Bladeburner is now displayed in the UI (by hydroflame)<br>" +
"* The Red Pill can now be purchased with negative money (since its supposed to be free) (by hydroflame)<br>" + "* The Red Pill can now be purchased with negative money (since its supposed to be free) (by hydroflame)<br>" +
"* Cranial Signal Processor Augmentations now have the previous generation as a prerequisite. i.e. Cranial Signal Processor - Gen II requires Gen I (by Kline-)<br>" + "* Cranial Signal Processor Augmentations now have the previous generation as a prerequisite. i.e. Cranial Signal Processor - Gen II requires Gen I (by Kline-)<br>" +
"* Terminal now supports semicolon usage (end of command). This allows chaining multiple Terminal commands (by hydroflame)<br>" +
"* Bladeburner Raid operations can no longer be performed if your estimate of Synthoid communities is zero (by hydroflame)<br>" + "* Bladeburner Raid operations can no longer be performed if your estimate of Synthoid communities is zero (by hydroflame)<br>" +
"* The difficulty of BN-12 now scales faster (by hydroflame)<br>" + "* The difficulty of BN-12 now scales faster (by hydroflame)<br>" +
"* Active Scripts UI now shows a RAM Usage bar for each server (by kopelli)<br>" + "* Active Scripts UI now shows a RAM Usage bar for each server (by kopelli)<br>" +

@ -187,7 +187,7 @@ function NetscriptFunctions(workerScript) {
*/ */
const getPurchaseServerRamCostGuard = (ram) => { const getPurchaseServerRamCostGuard = (ram) => {
const guardedRam = Math.round(ram); const guardedRam = Math.round(ram);
if (isNaN(guardedRam) || !powerOfTwo(guardedRam)) { if (isNaN(guardedRam) || !isPowerOfTwo(guardedRam)) {
throw Error("failed due to invalid ram argument. Must be numeric and a power of 2"); throw Error("failed due to invalid ram argument. Must be numeric and a power of 2");
} }