Merge pull request #1038 from danielyxie/dev

v0.52.1
This commit is contained in:
hydroflame 2021-08-10 21:04:05 -04:00 committed by GitHub
commit 2750eb293a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
94 changed files with 1336 additions and 1632 deletions

File diff suppressed because one or more lines are too long

30
dist/vendor.bundle.js vendored

File diff suppressed because one or more lines are too long

149
dist/vendor.css vendored

@ -11,7 +11,8 @@
padding: 4px 0; padding: 4px 0;
/* Vertical padding around content */ } /* Vertical padding around content */ }
.CodeMirror pre { .CodeMirror pre.CodeMirror-line,
.CodeMirror pre.CodeMirror-line-like {
padding: 0 4px; padding: 0 4px;
/* Horizontal padding of content */ } /* Horizontal padding of content */ }
@ -98,7 +99,7 @@
left: 0; left: 0;
right: 0; right: 0;
top: -50px; top: -50px;
bottom: -20px; bottom: 0;
overflow: hidden; } overflow: hidden; }
.CodeMirror-ruler { .CodeMirror-ruler {
@ -216,11 +217,11 @@ div.CodeMirror span.CodeMirror-nonmatchingbracket {
.CodeMirror-scroll { .CodeMirror-scroll {
overflow: scroll !important; overflow: scroll !important;
/* Things will break if this is overridden */ /* Things will break if this is overridden */
/* 30px is the magic margin used to hide the element's real scrollbars */ /* 50px is the magic margin used to hide the element's real scrollbars */
/* See overflow: hidden in .CodeMirror */ /* See overflow: hidden in .CodeMirror */
margin-bottom: -30px; margin-bottom: -50px;
margin-right: -30px; margin-right: -50px;
padding-bottom: 30px; padding-bottom: 50px;
height: 100%; height: 100%;
outline: none; outline: none;
/* Prevent dragging from highlighting the element */ /* Prevent dragging from highlighting the element */
@ -228,7 +229,7 @@ div.CodeMirror span.CodeMirror-nonmatchingbracket {
.CodeMirror-sizer { .CodeMirror-sizer {
position: relative; position: relative;
border-right: 30px solid transparent; } border-right: 50px solid transparent; }
/* The fake, visible scrollbars. Used to force redraw during scrolling /* The fake, visible scrollbars. Used to force redraw during scrolling
before actual scrolling happens, thus preventing shaking and before actual scrolling happens, thus preventing shaking and
@ -236,7 +237,8 @@ div.CodeMirror span.CodeMirror-nonmatchingbracket {
.CodeMirror-vscrollbar, .CodeMirror-hscrollbar, .CodeMirror-scrollbar-filler, .CodeMirror-gutter-filler { .CodeMirror-vscrollbar, .CodeMirror-hscrollbar, .CodeMirror-scrollbar-filler, .CodeMirror-gutter-filler {
position: absolute; position: absolute;
z-index: 6; z-index: 6;
display: none; } display: none;
outline: none; }
.CodeMirror-vscrollbar { .CodeMirror-vscrollbar {
right: 0; right: 0;
@ -270,7 +272,7 @@ div.CodeMirror span.CodeMirror-nonmatchingbracket {
height: 100%; height: 100%;
display: inline-block; display: inline-block;
vertical-align: top; vertical-align: top;
margin-bottom: -30px; } margin-bottom: -50px; }
.CodeMirror-gutter-wrapper { .CodeMirror-gutter-wrapper {
position: absolute; position: absolute;
@ -300,7 +302,8 @@ div.CodeMirror span.CodeMirror-nonmatchingbracket {
min-height: 1px; min-height: 1px;
/* prevents collapsing before first draw */ } /* prevents collapsing before first draw */ }
.CodeMirror pre { .CodeMirror pre.CodeMirror-line,
.CodeMirror pre.CodeMirror-line-like {
/* Reset some styles that the rest of the page might have set */ /* Reset some styles that the rest of the page might have set */
-moz-border-radius: 0; -moz-border-radius: 0;
-webkit-border-radius: 0; -webkit-border-radius: 0;
@ -321,7 +324,8 @@ div.CodeMirror span.CodeMirror-nonmatchingbracket {
-webkit-font-variant-ligatures: contextual; -webkit-font-variant-ligatures: contextual;
font-variant-ligatures: contextual; } font-variant-ligatures: contextual; }
.CodeMirror-wrap pre { .CodeMirror-wrap pre.CodeMirror-line,
.CodeMirror-wrap pre.CodeMirror-line-like {
word-wrap: break-word; word-wrap: break-word;
white-space: pre-wrap; white-space: pre-wrap;
word-break: normal; } word-break: normal; }
@ -1479,6 +1483,16 @@ span.CodeMirror-selectedtext {
.cm-s-darcula span.cm-special { .cm-s-darcula span.cm-special {
color: #FF9E59; } color: #FF9E59; }
.cm-s-darcula span.cm-matchhighlight {
color: #FFFFFF;
background-color: rgba(50, 89, 48, 0.7);
font-weight: normal; }
.cm-s-darcula span.cm-searching {
color: #FFFFFF;
background-color: rgba(61, 115, 59, 0.7);
font-weight: normal; }
.cm-s-darcula .CodeMirror-cursor { .cm-s-darcula .CodeMirror-cursor {
border-left: 1px solid #A9B7C6; } border-left: 1px solid #A9B7C6; }
@ -2510,7 +2524,7 @@ Ported to CodeMirror by Peter Kroon
color: #999; } color: #999; }
.cm-s-lesser-dark span.cm-link { .cm-s-lesser-dark span.cm-link {
color: #00c; } color: #7070E6; }
.cm-s-lesser-dark span.cm-error { .cm-s-lesser-dark span.cm-error {
color: #9d1e15; } color: #9d1e15; }
@ -2766,103 +2780,105 @@ Ported to CodeMirror by Peter Kroon
color: white !important; } color: white !important; }
/* /*
Name: material
Name: material Author: Mattia Astorino (http://github.com/equinusocio)
Author: Michael Kaminsky (http://github.com/mkaminsky11) Website: https://material-theme.site/
Original material color scheme by Mattia Astorino (https://github.com/equinusocio/material-theme)
*/ */
.cm-s-material.CodeMirror { .cm-s-material.CodeMirror {
background-color: #263238; background-color: #263238;
color: #e9eded; } color: #EEFFFF; }
.cm-s-material .CodeMirror-gutters { .cm-s-material .CodeMirror-gutters {
background: #263238; background: #263238;
color: #537f7e; color: #546E7A;
border: none; } border: none; }
.cm-s-material .CodeMirror-guttermarker, .cm-s-material .CodeMirror-guttermarker-subtle, .cm-s-material .CodeMirror-linenumber { .cm-s-material .CodeMirror-guttermarker,
color: #537f7e; } .cm-s-material .CodeMirror-guttermarker-subtle,
.cm-s-material .CodeMirror-linenumber {
color: #546E7A; }
.cm-s-material .CodeMirror-cursor { .cm-s-material .CodeMirror-cursor {
border-left: 1px solid #f8f8f0; } border-left: 1px solid #FFCC00; }
.cm-s-material div.CodeMirror-selected { .cm-s-material div.CodeMirror-selected {
background: rgba(255, 255, 255, 0.15); } background: rgba(128, 203, 196, 0.2); }
.cm-s-material.CodeMirror-focused div.CodeMirror-selected { .cm-s-material.CodeMirror-focused div.CodeMirror-selected {
background: rgba(255, 255, 255, 0.1); } background: rgba(128, 203, 196, 0.2); }
.cm-s-material .CodeMirror-line::selection, .cm-s-material .CodeMirror-line > span::selection, .cm-s-material .CodeMirror-line > span > span::selection { .cm-s-material .CodeMirror-line::selection,
background: rgba(255, 255, 255, 0.1); } .cm-s-material .CodeMirror-line > span::selection,
.cm-s-material .CodeMirror-line > span > span::selection {
background: rgba(128, 203, 196, 0.2); }
.cm-s-material .CodeMirror-line::-moz-selection, .cm-s-material .CodeMirror-line > span::-moz-selection, .cm-s-material .CodeMirror-line > span > span::-moz-selection { .cm-s-material .CodeMirror-line::-moz-selection,
background: rgba(255, 255, 255, 0.1); } .cm-s-material .CodeMirror-line > span::-moz-selection,
.cm-s-material .CodeMirror-line > span > span::-moz-selection {
background: rgba(128, 203, 196, 0.2); }
.cm-s-material .CodeMirror-activeline-background { .cm-s-material .CodeMirror-activeline-background {
background: rgba(0, 0, 0, 0); } background: rgba(0, 0, 0, 0.5); }
.cm-s-material .cm-keyword { .cm-s-material .cm-keyword {
color: #c792ea; } color: #C792EA; }
.cm-s-material .cm-operator { .cm-s-material .cm-operator {
color: #e9eded; } color: #89DDFF; }
.cm-s-material .cm-variable-2 { .cm-s-material .cm-variable-2 {
color: #80CBC4; } color: #EEFFFF; }
.cm-s-material .cm-variable-3, .cm-s-material .cm-type { .cm-s-material .cm-variable-3,
color: #82B1FF; } .cm-s-material .cm-type {
color: #f07178; }
.cm-s-material .cm-builtin { .cm-s-material .cm-builtin {
color: #DECB6B; } color: #FFCB6B; }
.cm-s-material .cm-atom { .cm-s-material .cm-atom {
color: #F77669; } color: #F78C6C; }
.cm-s-material .cm-number { .cm-s-material .cm-number {
color: #F77669; } color: #FF5370; }
.cm-s-material .cm-def { .cm-s-material .cm-def {
color: #e9eded; } color: #82AAFF; }
.cm-s-material .cm-string { .cm-s-material .cm-string {
color: #C3E88D; } color: #C3E88D; }
.cm-s-material .cm-string-2 { .cm-s-material .cm-string-2 {
color: #80CBC4; } color: #f07178; }
.cm-s-material .cm-comment { .cm-s-material .cm-comment {
color: #546E7A; } color: #546E7A; }
.cm-s-material .cm-variable { .cm-s-material .cm-variable {
color: #82B1FF; } color: #f07178; }
.cm-s-material .cm-tag { .cm-s-material .cm-tag {
color: #80CBC4; } color: #FF5370; }
.cm-s-material .cm-meta { .cm-s-material .cm-meta {
color: #80CBC4; }
.cm-s-material .cm-attribute {
color: #FFCB6B; } color: #FFCB6B; }
.cm-s-material .cm-attribute {
color: #C792EA; }
.cm-s-material .cm-property { .cm-s-material .cm-property {
color: #80CBAE; } color: #C792EA; }
.cm-s-material .cm-qualifier { .cm-s-material .cm-qualifier {
color: #DECB6B; } color: #DECB6B; }
.cm-s-material .cm-variable-3, .cm-s-material .cm-type { .cm-s-material .cm-variable-3,
.cm-s-material .cm-type {
color: #DECB6B; } color: #DECB6B; }
.cm-s-material .cm-tag {
color: #ff5370; }
.cm-s-material .cm-error { .cm-s-material .cm-error {
color: white; color: white;
background-color: #EC5F67; } background-color: #FF5370; }
.cm-s-material .CodeMirror-matchingbracket { .cm-s-material .CodeMirror-matchingbracket {
text-decoration: underline; text-decoration: underline;
@ -3074,13 +3090,6 @@ div.cm-s-mdn-like span.CodeMirror-matchingbracket {
background-image: url(data:image/png;base64,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); } background-image: url(data:image/png;base64,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); }
/* Based on the theme at http://bonsaiden.github.com/JavaScript-Garden */ /* Based on the theme at http://bonsaiden.github.com/JavaScript-Garden */
/*<!--match-->*/
.cm-s-midnight span.CodeMirror-matchhighlight {
background: #494949; }
.cm-s-midnight.CodeMirror-focused span.CodeMirror-matchhighlight {
background: #314D67 !important; }
/*<!--activeline-->*/ /*<!--activeline-->*/
.cm-s-midnight .CodeMirror-activeline-background { .cm-s-midnight .CodeMirror-activeline-background {
background: #253540; } background: #253540; }
@ -3420,7 +3429,7 @@ div.cm-s-mdn-like span.CodeMirror-matchingbracket {
background: #292A2B; background: #292A2B;
color: #E6E6E6; color: #E6E6E6;
line-height: 1.5; line-height: 1.5;
font-family: 'Operator Mono', 'Source Sans Pro', Menlo, Monaco, Consolas, Courier New, monospace; } font-family: 'Operator Mono', 'Source Code Pro', Menlo, Monaco, Consolas, Courier New, monospace; }
.cm-s-panda-syntax .CodeMirror-cursor { .cm-s-panda-syntax .CodeMirror-cursor {
border-color: #ff2c6d; } border-color: #ff2c6d; }
@ -5000,7 +5009,7 @@ http://ethanschoonover.com/solarized/img/solarized-palette.png
color: #AEAEAE; } color: #AEAEAE; }
.cm-s-vibrant-ink .cm-link { .cm-s-vibrant-ink .cm-link {
color: blue; } color: #5656F3; }
.cm-s-vibrant-ink .cm-error { .cm-s-vibrant-ink .cm-error {
border-bottom: 1px solid red; } border-bottom: 1px solid red; }
@ -5305,7 +5314,7 @@ THE SOFTWARE.
.cm-s-zenburn .CodeMirror-cursor { .cm-s-zenburn .CodeMirror-cursor {
border-left: 1px solid white; } border-left: 1px solid white; }
.cm-s-zenburn { .cm-s-zenburn.CodeMirror {
background-color: #3f3f3f; background-color: #3f3f3f;
color: #dcdccc; } color: #dcdccc; }
@ -5487,17 +5496,17 @@ li.CodeMirror-hint-active {
-o-transition: opacity .4s; -o-transition: opacity .4s;
-ms-transition: opacity .4s; } -ms-transition: opacity .4s; }
.CodeMirror-lint-mark-error, .CodeMirror-lint-mark-warning { .CodeMirror-lint-mark {
background-position: left bottom; background-position: left bottom;
background-repeat: repeat-x; } background-repeat: repeat-x; }
.CodeMirror-lint-mark-error {
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAQAAAADCAYAAAC09K7GAAAAAXNSR0IArs4c6QAAAAZiS0dEAP8A/wD/oL2nkwAAAAlwSFlzAAALEwAACxMBAJqcGAAAAAd0SU1FB9sJDw4cOCW1/KIAAAAZdEVYdENvbW1lbnQAQ3JlYXRlZCB3aXRoIEdJTVBXgQ4XAAAAHElEQVQI12NggIL/DAz/GdA5/xkY/qPKMDAwAADLZwf5rvm+LQAAAABJRU5ErkJggg=="); }
.CodeMirror-lint-mark-warning { .CodeMirror-lint-mark-warning {
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAQAAAADCAYAAAC09K7GAAAAAXNSR0IArs4c6QAAAAZiS0dEAP8A/wD/oL2nkwAAAAlwSFlzAAALEwAACxMBAJqcGAAAAAd0SU1FB9sJFhQXEbhTg7YAAAAZdEVYdENvbW1lbnQAQ3JlYXRlZCB3aXRoIEdJTVBXgQ4XAAAAMklEQVQI12NkgIIvJ3QXMjAwdDN+OaEbysDA4MPAwNDNwMCwiOHLCd1zX07o6kBVGQEAKBANtobskNMAAAAASUVORK5CYII="); } background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAQAAAADCAYAAAC09K7GAAAAAXNSR0IArs4c6QAAAAZiS0dEAP8A/wD/oL2nkwAAAAlwSFlzAAALEwAACxMBAJqcGAAAAAd0SU1FB9sJFhQXEbhTg7YAAAAZdEVYdENvbW1lbnQAQ3JlYXRlZCB3aXRoIEdJTVBXgQ4XAAAAMklEQVQI12NkgIIvJ3QXMjAwdDN+OaEbysDA4MPAwNDNwMCwiOHLCd1zX07o6kBVGQEAKBANtobskNMAAAAASUVORK5CYII="); }
.CodeMirror-lint-marker-error, .CodeMirror-lint-marker-warning { .CodeMirror-lint-mark-error {
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAQAAAADCAYAAAC09K7GAAAAAXNSR0IArs4c6QAAAAZiS0dEAP8A/wD/oL2nkwAAAAlwSFlzAAALEwAACxMBAJqcGAAAAAd0SU1FB9sJDw4cOCW1/KIAAAAZdEVYdENvbW1lbnQAQ3JlYXRlZCB3aXRoIEdJTVBXgQ4XAAAAHElEQVQI12NggIL/DAz/GdA5/xkY/qPKMDAwAADLZwf5rvm+LQAAAABJRU5ErkJggg=="); }
.CodeMirror-lint-marker {
background-position: center center; background-position: center center;
background-repeat: no-repeat; background-repeat: no-repeat;
cursor: pointer; cursor: pointer;
@ -5507,17 +5516,17 @@ li.CodeMirror-hint-active {
vertical-align: middle; vertical-align: middle;
position: relative; } position: relative; }
.CodeMirror-lint-message-error, .CodeMirror-lint-message-warning { .CodeMirror-lint-message {
padding-left: 18px; padding-left: 18px;
background-position: top left; background-position: top left;
background-repeat: no-repeat; } background-repeat: no-repeat; }
.CodeMirror-lint-marker-error, .CodeMirror-lint-message-error {
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAHlBMVEW7AAC7AACxAAC7AAC7AAAAAAC4AAC5AAD///+7AAAUdclpAAAABnRSTlMXnORSiwCK0ZKSAAAATUlEQVR42mWPOQ7AQAgDuQLx/z8csYRmPRIFIwRGnosRrpamvkKi0FTIiMASR3hhKW+hAN6/tIWhu9PDWiTGNEkTtIOucA5Oyr9ckPgAWm0GPBog6v4AAAAASUVORK5CYII="); }
.CodeMirror-lint-marker-warning, .CodeMirror-lint-message-warning { .CodeMirror-lint-marker-warning, .CodeMirror-lint-message-warning {
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAANlBMVEX/uwDvrwD/uwD/uwD/uwD/uwD/uwD/uwD/uwD6twD/uwAAAADurwD2tQD7uAD+ugAAAAD/uwDhmeTRAAAADHRSTlMJ8mN1EYcbmiixgACm7WbuAAAAVklEQVR42n3PUQqAIBBFUU1LLc3u/jdbOJoW1P08DA9Gba8+YWJ6gNJoNYIBzAA2chBth5kLmG9YUoG0NHAUwFXwO9LuBQL1giCQb8gC9Oro2vp5rncCIY8L8uEx5ZkAAAAASUVORK5CYII="); } background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAANlBMVEX/uwDvrwD/uwD/uwD/uwD/uwD/uwD/uwD/uwD6twD/uwAAAADurwD2tQD7uAD+ugAAAAD/uwDhmeTRAAAADHRSTlMJ8mN1EYcbmiixgACm7WbuAAAAVklEQVR42n3PUQqAIBBFUU1LLc3u/jdbOJoW1P08DA9Gba8+YWJ6gNJoNYIBzAA2chBth5kLmG9YUoG0NHAUwFXwO9LuBQL1giCQb8gC9Oro2vp5rncCIY8L8uEx5ZkAAAAASUVORK5CYII="); }
.CodeMirror-lint-marker-error, .CodeMirror-lint-message-error {
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAHlBMVEW7AAC7AACxAAC7AAC7AAAAAAC4AAC5AAD///+7AAAUdclpAAAABnRSTlMXnORSiwCK0ZKSAAAATUlEQVR42mWPOQ7AQAgDuQLx/z8csYRmPRIFIwRGnosRrpamvkKi0FTIiMASR3hhKW+hAN6/tIWhu9PDWiTGNEkTtIOucA5Oyr9ckPgAWm0GPBog6v4AAAAASUVORK5CYII="); }
.CodeMirror-lint-marker-multiple { .CodeMirror-lint-marker-multiple {
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAcAAAAHCAMAAADzjKfhAAAACVBMVEUAAAAAAAC/v7914kyHAAAAAXRSTlMAQObYZgAAACNJREFUeNo1ioEJAAAIwmz/H90iFFSGJgFMe3gaLZ0od+9/AQZ0ADosbYraAAAAAElFTkSuQmCC"); background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAcAAAAHCAMAAADzjKfhAAAACVBMVEUAAAAAAAC/v7914kyHAAAAAXRSTlMAQObYZgAAACNJREFUeNo1ioEJAAAIwmz/H90iFFSGJgFMe3gaLZ0od+9/AQZ0ADosbYraAAAAAElFTkSuQmCC");
background-repeat: no-repeat; background-repeat: no-repeat;

@ -15,73 +15,53 @@ of level 3.
List of all Source-Files List of all Source-Files
^^^^^^^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^^^^
+------------------------------------+-------------------------------------------------------------------------------------+ +------------------------------------+-------------------------------------------------------------------------------------+
| BitNode-1: Source Genesis | * Lets the player start with 32 GB of RAM on home computer | | BitNode-1: Source Genesis | * Lets the player start with 32 GB of RAM on home computer. |
| | * Increases all of the player's multipliers by 16%/24%/28% | | | * Increases all of the player's multipliers by 16%/24%/28%. |
+------------------------------------+-------------------------------------------------------------------------------------+ +------------------------------------+-------------------------------------------------------------------------------------+
| BitNode-2: Rise of the Underworld | * Increases the player's crime success rate, crime money, and | | BitNode-2: Rise of the Underworld | * Lets the player create Gangs in other BitNodes (although some |
| | charisma multipliers by 24%/36%/42% | | | BitNodes will disable this mechanic). |
| | * Increases the player's crime success rate, crime money, and |
| | charisma multipliers by 24%/36%/42%. |
+------------------------------------+-------------------------------------------------------------------------------------+ +------------------------------------+-------------------------------------------------------------------------------------+
| BitNode-3: Corporatocracy | * Lets the player create Corporations in other BitNodes (although some | | BitNode-3: Corporatocracy | * Lets the player create Corporations in other BitNodes (although some |
| | BitNodes will disable this mechanic) | | | BitNodes will disable this mechanic). |
| | * Increases the player's charisma and company salary multipliers by 8%/12%/14% | | | * Increases the player's charisma and company salary multipliers by 8%/12%/14%. |
+------------------------------------+-------------------------------------------------------------------------------------+ +------------------------------------+-------------------------------------------------------------------------------------+
| BitNode-4: The Singularity | * Lets the player access and use Netscript Singularity Functions in other BitNodes. | | BitNode-4: The Singularity | * Lets the player access and use Netscript Singularity Functions in other BitNodes. |
| | * Each level of this Source-File opens up more of the Singularity Functions to use | | | * Each level of this Source-File opens up more of the Singularity Functions to use. |
+------------------------------------+-------------------------------------------------------------------------------------+ +------------------------------------+-------------------------------------------------------------------------------------+
| BitNode-5: Artificial Intelligence | * Unlocks :ref:`gameplay_intelligence` | | BitNode-5: Artificial Intelligence | * Unlocks :ref:`gameplay_intelligence`. |
| | * Unlocks :js:func:`getBitNodeMultipliers` Netscript function | | | * Unlocks :js:func:`getBitNodeMultipliers` and :js:func:`getServer` |
| | * Increases all of the player's hacking-related multipliers by 8%/12%/14% | | | Netscript functions, as well as :ref:`netscriptformulas`. |
| | * Increases all of the player's hacking-related multipliers by 8%/12%/14%. |
+------------------------------------+-------------------------------------------------------------------------------------+ +------------------------------------+-------------------------------------------------------------------------------------+
| BitNode-6: Bladeburners | * Unlocks the Bladeburner feature in other BitNodes | | BitNode-6: Bladeburners | * Unlocks the Bladeburner feature in other BitNodes. |
| | * Increases all of the player's level and experience gain rate multipliers for | | | * Increases all of the player's level and experience gain rate multipliers for |
| | combat stats by 8%/12%/14% | | | combat stats by 8%/12%/14%. |
+------------------------------------+-------------------------------------------------------------------------------------+ +------------------------------------+-------------------------------------------------------------------------------------+
| BitNode-7: Bladeburners 2079 | * Allows the player to access the :ref:`netscript_bladeburnerapi` in other BitNodes | | BitNode-7: Bladeburners 2079 | * Allows the player to access the :ref:`netscript_bladeburnerapi` in other BitNodes.|
| | * Increases all of the player's Bladeburner multipliers by 8%/12%/14% | | | * Increases all of the player's Bladeburner multipliers by 8%/12%/14%. |
+------------------------------------+-------------------------------------------------------------------------------------+ +------------------------------------+-------------------------------------------------------------------------------------+
| BitNode-8: Ghost of Wall Street | * Increases the player's hacking growth multiplier by 12%/18%/21% | | BitNode-8: Ghost of Wall Street | * Increases the player's hacking growth multiplier by 12%/18%/21%. |
| | * Level 1 grants permanent access to :ref:`WSE <gameplay_stock_market>` and | | | * Level 1 grants permanent access to :ref:`WSE <gameplay_stock_market>` and |
| | :ref:`TIX API <netscript_tixapi>` | | | :ref:`TIX API <netscript_tixapi>`. |
| | * Level 2 grants permanent access to shorting stocks | | | * Level 2 grants permanent access to shorting stocks. |
| | * Level 3 grants permanent access to use limit/stop orders | | | * Level 3 grants permanent access to use limit/stop orders. |
+------------------------------------+-------------------------------------------------------------------------------------+ +------------------------------------+-------------------------------------------------------------------------------------+
| BitNode-9: Coming Soon | | | BitNode-9: Hacktocracy | * Level 1 permanently unlocks the Hacknet Server in other BitNodes. |
| | * Level 2 lets the player start with 128 GB of RAM on home computer. |
| | * Level 3 grants a highly-upgraded Hacknet Server when entering a new BitNode (it |
| | will be lost after installing augments). |
+------------------------------------+-------------------------------------------------------------------------------------+ +------------------------------------+-------------------------------------------------------------------------------------+
| BitNode-10: Digital Carbon | * Each level of this grants a Duplicate Sleeve. | | BitNode-10: Digital Carbon | * Each level of this grants a Duplicate Sleeve. |
| | * Allows the player to access the :ref:`netscript_sleeveapi` in other BitNodes | | | * Allows the player to access the :ref:`netscript_sleeveapi` in other BitNodes. |
+------------------------------------+-------------------------------------------------------------------------------------+ +------------------------------------+-------------------------------------------------------------------------------------+
| BitNode-11: The Big Crash | * Company favor increases both the player's salary and reputation gain at that | | BitNode-11: The Big Crash | * Company favor increases both the player's salary and reputation gain at that |
| | company by 1% per favor (rather than just the reputation gain) | | | company by 1% per favor (rather than just the reputation gain). |
| | * Increases the player's company salary and reputation gain multipliers by | | | * Increases the player's company salary and reputation gain multipliers by |
| | 24%/36%/42% | | | 32%/48%/56%. |
+------------------------------------+-------------------------------------------------------------------------------------+ +------------------------------------+-------------------------------------------------------------------------------------+
| BitNode-12: The Recursion | * There is no maximum level for this Source-File | | BitNode-12: The Recursion | * There is no maximum level for this Source-File. |
| | * Each level of this Source-File increases all of the player's multipliers by 1%. | | | * Lets the player start with Neuroflux Governor equal to the level of this |
| | * This affect is multiplicative with itself. This means that level N of this | | | Source-File. |
| | Source-File will result in a multiplier of 1.01^N (or 0.99^N for multipliers |
| | that decrease) |
+------------------------------------+-------------------------------------------------------------------------------------+
| | |
+------------------------------------+-------------------------------------------------------------------------------------+
| | |
+------------------------------------+-------------------------------------------------------------------------------------+
| | |
+------------------------------------+-------------------------------------------------------------------------------------+
| | |
+------------------------------------+-------------------------------------------------------------------------------------+
| | |
+------------------------------------+-------------------------------------------------------------------------------------+
| | |
+------------------------------------+-------------------------------------------------------------------------------------+
| | |
+------------------------------------+-------------------------------------------------------------------------------------+
| | |
+------------------------------------+-------------------------------------------------------------------------------------+
| | |
+------------------------------------+-------------------------------------------------------------------------------------+
| | |
+------------------------------------+-------------------------------------------------------------------------------------+
| | |
+------------------------------------+-------------------------------------------------------------------------------------+
| | |
+------------------------------------+-------------------------------------------------------------------------------------+ +------------------------------------+-------------------------------------------------------------------------------------+

@ -3,6 +3,25 @@
Changelog Changelog
========= =========
v0.52.1 - 2021-07-10 bugfixing (hydroflame & community)
-------------------------------------------
**Misc.**
* Fix game crash/corruption when quitting a job while working for it unfocused.
* Fix typo in corporation Market Data.
* Fix typo in docs for hackPercent.
* The tutorial encourages the players to connect to home before creating `n00dles.script`
* The dark web `buy` command now accepts `-1` (one) and `--list` instead of just
`-l`. Helps some confused players.
* Character overview screen no longer hidden on the corporation screen.
* Infiltration difficulty display is now more explicit (It's a big arrow instead
of just one word.)
* Fix wrong ram value in tutorial. (@MageKing17)
* Plenty of augmentation description cleanup (@Kwazygloo)
* Plenty of typo/description fixed (@MageKing17)
* Cleanup description of singularity function on readthedocs (@PurePandemonium)
* Fix bug when autolinking a server while backdooring (@schroederIT)
v0.52.0 - 2021-06-13 Infiltration 2.0 (hydroflame & community) v0.52.0 - 2021-06-13 Infiltration 2.0 (hydroflame & community)
-------------------------------------------------------------- --------------------------------------------------------------

@ -66,7 +66,7 @@ documentation_title = '{0} Documentation'.format(project)
# The short X.Y version. # The short X.Y version.
version = '0.52' version = '0.52'
# The full version, including alpha/beta/rc tags. # The full version, including alpha/beta/rc tags.
release = '0.52.0' release = '0.52.1'
# The language for content autogenerated by Sphinx. Refer to documentation # The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages. # for a list of supported languages.

@ -5,13 +5,16 @@ getBitNodeMultipliers() Netscript Function
:RAM cost: 4 GB :RAM cost: 4 GB
Returns an object containing the current BitNode multipliers. This function If you are not in BitNode-5, then you must have Source-File 5-1 in order to
requires Source-File 5 in order to run. The multipliers are returned in run this function.
decimal forms (e.g. 1.5 instead of 150%). The multipliers represent the
difference between the current BitNode and the original BitNode (BitNode-1). Returns an object containing the current BitNode multipliers. The
For example, if the *CrimeMoney* multiplier has a value of 0.1, then that multipliers are returned in decimal forms (e.g. 1.5 instead of 150%). The
means that committing crimes in the current BitNode will only give 10% of multipliers represent the difference between the current BitNode and the
the money you would have received in BitNode-1. original BitNode (BitNode-1). For example, if the *CrimeMoney* multiplier
has a value of 0.1, then that means that committing crimes in the current
BitNode will only give 10% of the money you would have received in
BitNode-1.
The structure of the returned object is subject to change as BitNode The structure of the returned object is subject to change as BitNode
multipliers get added to the game. Refer to the `source code here multipliers get added to the game. Refer to the `source code here

@ -3,7 +3,7 @@ getServer() Netscript Function
.. js:function:: getServer([hostname]) .. js:function:: getServer([hostname])
:RAM cost: 4 GB :RAM cost: 2 GB
:param string hostname: Hostname of the server, defaults to host server. :param string hostname: Hostname of the server, defaults to host server.
If you are not in BitNode-5, then you must have Source-File 5-1 in order to run this function. If you are not in BitNode-5, then you must have Source-File 5-1 in order to run this function.

@ -7,8 +7,8 @@ brutessh() Netscript Function
:param string hostname: Hostname of the target server. :param string hostname: Hostname of the target server.
Runs the BruteSSH.exe program on the target server. BruteSSH.exe must exist Runs the ``BruteSSH.exe`` program on the target server. ``BruteSSH.exe``
on your home computer. must exist on your home computer.
Examples: Examples:

@ -9,9 +9,3 @@ disableLog() Netscript Function
Disables logging for the given function. Logging can be disabled for Disables logging for the given function. Logging can be disabled for
all functions by passing 'ALL' as the argument. all functions by passing 'ALL' as the argument.
Note that this does not completely remove all logging functionality.
This only stops a function from logging when the function is successful. If
the function fails, it will still log the reason for failure.
Notable functions that cannot have their logs disabled: run, exec, exit

@ -19,9 +19,8 @@ exec() Netscript Function
the :doc:`run<run>` function except that it can be used to run a script on any the :doc:`run<run>` function except that it can be used to run a script on any
server, instead of just the current server. server, instead of just the current server.
.. warning:: Running this function with a ``numThreads`` argument of 0 will return 0 without .. warning:: Running this function with a ``numThreads`` argument of 0 or
running the script. However, running this function with a negative *numThreads* less will cause a runtime error.
argument will cause a runtime error.
The simplest way to use the :doc:`exec<exec>` command is to call it with The simplest way to use the :doc:`exec<exec>` command is to call it with
just the script name and the target server. The following example will try just the script name and the target server. The following example will try

@ -6,3 +6,12 @@ exit() Netscript Function
:RAM cost: 0 GB :RAM cost: 0 GB
Terminates the current script immediately. Terminates the current script immediately.
.. warning:: In :ref:`netscriptjs`, execution may continue past a call to
this function; while some game-related functions (e.g. those with an
``ns.`` prefix) will not function after this function has been called,
there might still be unintended behavior if you assume ``exit`` will
immediately halt execution, like it does in :ref:`netscript1`. To be
safe, you should probably ``return`` from the main function instead
of/in addition to calling ``ns.exit()`` when halting a NetscriptJS
script.

@ -7,17 +7,22 @@ flags() Netscript Function
:param data array of pairs of strings: Flags definition. :param data array of pairs of strings: Flags definition.
:returns: Object containing all the flags that were parsed or default. :returns: Object containing all the flags that were parsed or default.
The flag definition is an array of pairs of values, the first value is the This function allows for a more flexible way of parsing script arguments
name of the flag, the 2nd value is the default value for that flag. than to just pass a fixed list in a fixed order. Options can be given
names, and passed in any order, while having defined default values.
The flag definition is an array of pairs of values: the first value is the
name of the flag, and the 2nd value is the default value for that flag.
The return object is a map containing flag names to the value. It also The return object is a map containing flag names to the value. It also
contains the special field '_' which contains all arguments that were not flags. contains the special field '_', which contains all arguments that were not
flags.
Example: Example:
.. code-block:: javascript .. code-block:: javascript
/* example.script // example.script
var data = flags([ var data = flags([
['delay', 0], // a default number means this flag is a number ['delay', 0], // a default number means this flag is a number
['server', 'foodnstuff'], // a default string means this flag is a string ['server', 'foodnstuff'], // a default string means this flag is a string
@ -25,16 +30,17 @@ flags() Netscript Function
['help', false], // a default boolean means this flag is a boolean ['help', false], // a default boolean means this flag is a boolean
]); ]);
tprint(data); tprint(data);
*/ /*
[home ~/]> run example.script [home ~/]> run example.script
{"_":[],"delay":0,"server":"foodnstuff"} {"_":[],"delay":0,"server":"foodnstuff","exclude":[],"help":false}
[home ~/]> run example.script --delay 3000 [home ~/]> run example.script --delay 3000
{"_":[],"server":"foodnstuff","delay":3000} {"_":[],"server":"foodnstuff","exclude":[],"help":false,"delay":3000}
[home ~/]> run example.script --delay 3000 --server harakiri-sushi [home ~/]> run example.script --delay 3000 --server harakiri-sushi
{"_":[],"delay":3000,"server":"harakiri-sushi"} {"_":[],"exclude":[],"help":false,"delay":3000,"server":"harakiri-sushi"}
[home ~/]> run example.script --delay 3000 --server harakiri-sushi hello world [home ~/]> run example.script --delay 3000 --server harakiri-sushi hello world
{"_":["hello","world"],"delay":3000,"server":"harakiri-sushi"} {"_":["hello","world"],"exclude":[],"help":false,"delay":3000,"server":"harakiri-sushi"}
[home ~/]> run example.script --delay 3000 --server harakiri-sushi hello world --exclude a --exclude b [home ~/]> run example.script --delay 3000 --server harakiri-sushi hello world --exclude a --exclude b
{"_":["hello","world"],"delay":3000,"server":"harakiri-sushi","exclude":["a","b"]} {"_":["hello","world"],"help":false,"delay":3000,"server":"harakiri-sushi","exclude":["a","b"]}
[home ~/]> run example.script --help [home ~/]> run example.script --help
{"_":[],"delay":0,"server":"foodnstuff","exclude":[],"help":true} {"_":[],"delay":0,"server":"foodnstuff","exclude":[],"help":true}
*/

@ -10,7 +10,6 @@ ftpcrack() Netscript Function
Runs the ``FTPCrack.exe`` program on the target server. ``FTPCrack.exe`` Runs the ``FTPCrack.exe`` program on the target server. ``FTPCrack.exe``
must exist on your home computer. must exist on your home computer.
Examples: Examples:
.. code-block:: javascript .. code-block:: javascript

@ -13,7 +13,6 @@ getGrowTime() Netscript Function
The function takes in an optional ``hackLvl`` parameter that can be The function takes in an optional ``hackLvl`` parameter that can be
specified to see what the grow time would be at different hacking levels. specified to see what the grow time would be at different hacking levels.
Example: Example:
.. code-block:: javascript .. code-block:: javascript

@ -11,4 +11,3 @@ getHostname() Netscript Function
.. code-block:: javascript .. code-block:: javascript
getHostname(); // returns: "foodnstuff" getHostname(); // returns: "foodnstuff"

@ -10,89 +10,89 @@ getPlayer() Netscript Function
Returns an object with the Player's stats. The object has the following properties:: Returns an object with the Player's stats. The object has the following properties::
{ {
hacking_skill hacking_skill: Current Hacking skill level
hp hp: Current health points
max_hp max_hp: Maximum health points
strength strength: Current Strength skill level
defense defense: Current Defense skill level
dexterity dexterity: Current Dexterity skill level
agility agility: Current Agility skill level
charisma charisma: Current Charisma skill level
intelligence intelligence: Current Intelligence skill level (from BitNode-5)
hacking_chance_mult hacking_chance_mult: Hacking Chance multiplier (from Source-Files and Augments)
hacking_speed_mult hacking_speed_mult: Hacking Speed multiplier (from Source-Files and Augments)
hacking_money_mult hacking_money_mult: Hacking Money multiplier (from Source-Files and Augments)
hacking_grow_mult hacking_grow_mult: Hacking Growth multiplier (from Source-Files and Augments)
hacking_exp hacking_exp: Current Hacking experience points
strength_exp strength_exp: Current Strength experience points
defense_exp defense_exp: Current Defense experience points
dexterity_exp dexterity_exp: Current Dexterity experience points
agility_exp agility_exp: Current Agility experience points
charisma_exp charisma_exp: Current Charisma experience points
hacking_mult hacking_mult: Hacking Level multiplier (from Source-Files and Augments)
strength_mult strength_mult: Strength Level multiplier (from Source-Files and Augments)
defense_mult defense_mult: Defense Level multiplier (from Source-Files and Augments)
dexterity_mult dexterity_mult: Dexterity Level multiplier (from Source-Files and Augments)
agility_mult agility_mult: Agility Level multiplier (from Source-Files and Augments)
charisma_mult charisma_mult: Charisma Level multiplier (from Source-Files and Augments)
hacking_exp_mult hacking_exp_mult: Hacking Experience multiplier (from Source-Files and Augments)
strength_exp_mult strength_exp_mult: Strength Experience multiplier (from Source-Files and Augments)
defense_exp_mult defense_exp_mult: Defense Experience multiplier (from Source-Files and Augments)
dexterity_exp_mult dexterity_exp_mult: Dexterity Experience multiplier (from Source-Files and Augments)
agility_exp_mult agility_exp_mult: Agility Experience multiplier (from Source-Files and Augments)
charisma_exp_mult charisma_exp_mult: Charisma Experience multiplier (from Source-Files and Augments)
company_rep_mult company_rep_mult: Company reputation gain multiplier (from Source-Files and Augments)
faction_rep_mult faction_rep_mult: Faction reputation gain multiplier (from Source-Files and Augments)
money money: Current money
city city: Name of city you are currently in
location location: Name of the last location visited
crime_money_mult crime_money_mult: Crime money multiplier (from Source-Files and Augments)
crime_success_mult crime_success_mult: Crime success multiplier (from Source-Files and Augments)
isWorking isWorking: Boolean indicating whether the player is currently performing work
workType workType: Name of the kind of work the player is performing
currentWorkFactionName currentWorkFactionName: Name of the faction the player is currently working for
currentWorkFactionDescription currentWorkFactionDescription: Description of the kind of work the player is currently doing
workHackExpGainRate workHackExpGainRate: Amount of Hacking experience the player will gain every cycle (fifth of a second)
workStrExpGainRate workStrExpGainRate: Amount of Strength experience the player will gain every cycle
workDefExpGainRate workDefExpGainRate: Amount of Defense experience the player will gain every cycle
workDexExpGainRate workDexExpGainRate: Amount of Dexterity experience the player will gain every cycle
workAgiExpGainRate workAgiExpGainRate: Amount of Agility experience the player will gain every cycle
workChaExpGainRate workChaExpGainRate: Amount of Charisma experience the player will gain every cycle
workRepGainRate workRepGainRate: Amount of Reputation the player will gain every cycle
workMoneyGainRate workMoneyGainRate: Amount of Money the player will gain every cycle
workMoneyLossRate workMoneyLossRate: Amount of Money the player will lose every cycle
workHackExpGained workHackExpGained: Total Hacking experience gained while working thus far
workStrExpGained workStrExpGained: Total Strength experience gained while working thus far
workDefExpGained workDefExpGained: Total Defense experience gained while working thus far
workDexExpGained workDexExpGained: Total Dexterity experience gained while working thus far
workAgiExpGained workAgiExpGained: Total Agility experience gained while working thus far
workChaExpGained workChaExpGained: Total Charisma experience gained while working thus far
workRepGained workRepGained: Total Reputation gained while working thus far
workMoneyGained workMoneyGained: Total Money gained while working thus far
createProgramName createProgramName: Name of the program the player is currently creating
createProgramReqLvl createProgramReqLvl: Hacking skill required to make that program
className className: Name of the class the player is currently studying
crimeType crimeType: Name of the crime the player last started
work_money_mult work_money_mult: Salary multiplier (from Source-Files and Augments)
hacknet_node_money_mult hacknet_node_money_mult: Hacknet Node production multiplier (from Source-Files and Augments)
hacknet_node_purchase_cost_mult hacknet_node_purchase_cost_mult: Hacknet Node purchase cost multiplier (from Source-Files and Augments)
hacknet_node_ram_cost_mult hacknet_node_ram_cost_mult: Hacknet Node RAM upgrade cost multiplier (from Source-Files and Augments)
hacknet_node_core_cost_mult hacknet_node_core_cost_mult: Hacknet Node Core purchase cost multiplier (from Source-Files and Augments)
hacknet_node_level_cost_mult hacknet_node_level_cost_mult: Hacknet Node level upgrade cost multiplier (from Source-Files and Augments)
hasWseAccount hasWseAccount: Boolean indicating whether the player has a WSE Account
hasTixApiAccess hasTixApiAccess: Boolean indicating whether the player has TIX API Access
has4SData has4SData: Boolean indicating whether the player has 4S Market Data Access
has4SDataTixApi has4SDataTixApi: Boolean indicating whether the player has 4S Market Data TIX API Access
bladeburner_max_stamina_mult bladeburner_max_stamina_mult: Bladeburner Max Stamina multiplier (from Source-Files and Augments)
bladeburner_stamina_gain_mult bladeburner_stamina_gain_mult: Bladeburner Stamina Gain multiplier (from Source-Files and Augments)
bladeburner_success_chance_mult bladeburner_success_chance_mult: Bladeburner Success Chance multiplier (from Source-Files and Augments)
bitNodeN bitNodeN: Current BitNode number
totalPlaytime totalPlaytime: Total amount of time the game has been running, in milliseconds
playtimeSinceLastAug playtimeSinceLastAug: Milliseconds since the last time Augmentations were installed
playtimeSinceLastBitnode playtimeSinceLastBitnode: Milliseconds since this BitNode was started
jobs jobs: A mapping of companies the player works for to the title of the player's job at that company
factions factions: An array of factions the player is currently a member of
tor tor: Boolean indicating whether or not you have a tor router
} }
Example:: Example::

@ -4,7 +4,7 @@ getRunningScript() Netscript Function
.. js:function:: getRunningScript() .. js:function:: getRunningScript()
:RAM cost: 0.3 GB :RAM cost: 0.3 GB
:returns: Script object or null if not found :returns: Script object or null if not found.
The object has the following properties: The object has the following properties:
@ -64,8 +64,8 @@ getRunningScript() Netscript Function
.. js:function:: getRunningScript(pid) .. js:function:: getRunningScript(pid)
:RAM cost: 0.3 GB :RAM cost: 0.3 GB
:param number pid: PID of the script :param number pid: PID of the script.
:returns: Script object or null if not found :returns: Script object or null if not found.
Examples: Examples:
@ -73,13 +73,13 @@ getRunningScript() Netscript Function
getRunningScript(42); // get the script with pid 42. getRunningScript(42); // get the script with pid 42.
.. js:function:: getRunningScript(fn, hostname[, args]) .. js:function:: getRunningScript(fn, hostname[, args...])
:RAM cost: 0.3 GB :RAM cost: 0.3 GB
:param number fn: filename of the target script :param number fn: Filename of the target script.
:param number hostname: hostname of the server running the script :param number hostname: Hostname of the server running the script.
:param number args: arguments to the script. :param number args...: Arguments that the script is running with.
:returns: Script object or null if not found :returns: Script object or null if not found.
Examples: Examples:

@ -15,4 +15,3 @@ getScriptExpGain() Netscript Function
.. note:: A script is uniquely identified by both its name and its .. note:: A script is uniquely identified by both its name and its
arguments. arguments.

@ -9,8 +9,8 @@ getScriptLogs() Netscript Function
:param args...: Arguments to identify which scripts to get logs for :param args...: Arguments to identify which scripts to get logs for
:returns: Array of string, each line being a logged line. Chronological. :returns: Array of string, each line being a logged line. Chronological.
.. note:: There is a maximum number of lines that a script stores in its logs. .. note:: There is a maximum number of lines that a script stores in its logs.
This is configurable in the game's options. This is configurable in the game's options.
If the function is called with no arguments, it will return the current If the function is called with no arguments, it will return the current
script's logs. script's logs.

@ -7,10 +7,10 @@ getServerGrowth() Netscript Function
:param string hostname: Hostname of target server. :param string hostname: Hostname of target server.
:returns: Server growth parameter. :returns: Server growth parameter.
The growth parameter is a number between 1 and 100 affects the percentage by The growth parameter is a number, typically between 1 and 100, that affects
which the server's money is increased when using the :doc:`grow<grow>` the percentage by which the server's money is increased when using the
function. A higher growth parameter will result in a higher percentage :doc:`grow<grow>` function. A higher growth parameter will result in a
increase. higher percentage increase.
Example: Example:

@ -5,10 +5,10 @@ getServerMaxMoney() Netscript Function
:RAM cost: 0.1 GB :RAM cost: 0.1 GB
:param string hostname: Hostname of target server. :param string hostname: Hostname of target server.
:returns: Maximum amount of money that can be available on a server. :returns: Maximum amount of money that can be available on a server.
Example: Example:
.. code-block:: javascript .. code-block:: javascript
getServerMaxMoney('foodnstuff'); // returns: 4000000 getServerMaxMoney('foodnstuff'); // returns: 50000000

@ -3,12 +3,14 @@ getServerRam() Netscript Function
.. js:function:: getServerRam(hostname) .. js:function:: getServerRam(hostname)
.. warning:: This function is deprecated. .. warning:: This function is deprecated. It still functions, but new
scripts should prefer :doc:`getServerMaxRam<getServerMaxRam>`
and :doc:`getServerUsedRam<getServerUsedRam>` instead.
:RAM cost: 0.1 GB :RAM cost: 0.1 GB
:param string hostname: Hostname of target server. :param string hostname: Hostname of target server.
:returns: An array of 2 number, first number is the total RAM, second the :returns: An array of 2 numbers; the first number is the total RAM, and the
used RAM. second is the used RAM.
Returns an array with two elements that gives information about a server's memory (RAM). The first Returns an array with two elements that gives information about a server's memory (RAM). The first
element in the array is the amount of RAM that the server has total (in GB). The second element in element in the array is the amount of RAM that the server has total (in GB). The second element in

@ -6,8 +6,8 @@ httpworm() Netscript Function
:RAM cost: 0.05 GB :RAM cost: 0.05 GB
:param string hostname: Hostname of the target server. :param string hostname: Hostname of the target server.
Runs the HTTPWorm.exe program on the target server. HTTPWorm.exe must exist Runs the ``HTTPWorm.exe`` program on the target server. ``HTTPWorm.exe``
on your home computer. must exist on your home computer.
Example: Example:

@ -6,7 +6,8 @@ nuke() Netscript Function
:RAM cost: 0.05 GB :RAM cost: 0.05 GB
:param string hostname: Hostname of the target server. :param string hostname: Hostname of the target server.
Runs the NUKE.exe program on the target server. NUKE.exe must exist on your home computer. Runs the ``NUKE.exe`` program on the target server. ``NUKE.exe`` must exist
on your home computer.
Example: Example:

@ -6,9 +6,8 @@ relaysmtp() Netscript Function
:RAM cost: 0.05 GB :RAM cost: 0.05 GB
:param string hostname: Hostname of the target server. :param string hostname: Hostname of the target server.
Runs the ``relaySMTP.exe`` program on the target server. ``relaySMTP.exe``
Runs the relaySMTP.exe program on the target server. relaySMTP.exe must must exist on your home computer.
exist on your home computer.
Example: Example:

@ -17,9 +17,8 @@ run() Netscript Function
scripts located on the current server (the server running the script that scripts located on the current server (the server running the script that
calls this function). calls this function).
.. warning:: Running this function with a ``numThreads`` argument of 0 will .. warning:: Running this function with a ``numThreads`` argument of 0 or
return 0 without running the script. However, running this function with less will cause a runtime error.
a negative ``numThreads`` argument will cause a runtime error.
The simplest way to use the :doc:`run<run>` command is to call it with just The simplest way to use the :doc:`run<run>` command is to call it with just
the script name. The following example will run ``foo.script`` the script name. The following example will run ``foo.script``

@ -9,7 +9,7 @@ scp() Netscript Function
Hostname of the source server, which is the server from which the file will be copied. Hostname of the source server, which is the server from which the file will be copied.
This argument is optional and if it's omitted the source will be the current server. This argument is optional and if it's omitted the source will be the current server.
:param string destination: Hostname of the destination server, which is the server to which the file will be copied. :param string destination: Hostname of the destination server, which is the server to which the file will be copied.
:returns: ``true`` is the copy was a success. :returns: ``true`` if the copy was a success.
Copies a script or literature (.lit) file(s) to another server. The Copies a script or literature (.lit) file(s) to another server. The
``files`` argument can be either a string specifying a single file to copy, ``files`` argument can be either a string specifying a single file to copy,

@ -8,7 +8,6 @@ sleep() Netscript Function
Suspends the script for n milliseconds. Suspends the script for n milliseconds.
Example: Example:
.. code-block:: javascript .. code-block:: javascript

@ -16,6 +16,8 @@ spawn() Netscript Function
current one. This function can only be used to run scripts on the local current one. This function can only be used to run scripts on the local
server. server.
.. warning:: Running this function with a ``numThreads`` argument of 0 or
less will cause a runtime error.
Example: Example:

@ -6,8 +6,8 @@ sqlinject() Netscript Function
:RAM cost: 0.05 GB :RAM cost: 0.05 GB
:param string hostname: Hostname of the target server. :param string hostname: Hostname of the target server.
Runs the SQLInject.exe program on the target server. SQLInject.exe must Runs the ``SQLInject.exe`` program on the target server. ``SQLInject.exe``
exist on your home computer. must exist on your home computer.
Example: Example:

@ -44,9 +44,6 @@ tail() Netscript Function
// Open logs from process with id 42 // Open logs from process with id 42
tail(42); tail(42);
// Open logs from process with id 42 on the foodnstuff server
tail(42, "foodnstuff");
.. js:function:: tail() .. js:function:: tail()
:RAM cost: 0 GB :RAM cost: 0 GB

@ -8,7 +8,6 @@ write() Netscript Function
:param string data: Data to write :param string data: Data to write
:param string mode: Defines the write mode. Only valid when writing to text files or scripts. :param string mode: Defines the write mode. Only valid when writing to text files or scripts.
This function can be used to either write data to a port, a text file This function can be used to either write data to a port, a text file
(.txt), or a script (.script, .js, .ns) (.txt), or a script (.script, .js, .ns)

@ -11,8 +11,8 @@ getData() Netscript Function
contract type. contract type.
Get the data associated with the specific Coding Contract. Note that this is Get the data associated with the specific Coding Contract. Note that this is
not the same as the contract's description. This is just the data that not the same as the contract's description; this is just the data that
the contract wants you to act on in order to solve the contract wants you to act on in order to solve.
Example: Example:

@ -8,15 +8,18 @@ calculateExp() Netscript Function
:param number mult: Assume a specific skill multipler (not exp multiplier). :param number mult: Assume a specific skill multipler (not exp multiplier).
:returns: number of exp required to reach given ``skillLevel`` with that multiplier. :returns: number of exp required to reach given ``skillLevel`` with that multiplier.
You must have Source-File 5-1 in order to use this function. If you are not in BitNode-5, then you must have Source-File 5-1 in order to
use this function.
This function calculates the amount of experience needed to reach level the given ``skillLevel``. This function calculates the amount of experience needed to reach the given
``skillLevel``.
Examples: Examples:
.. code-block:: javascript .. code-block:: javascript
nextHacking = getStats().hacking+1; var player = getPlayer();
nextExp = formulas.basic.calculateExp(nextHacking); var nextHacking = player.hacking_skill+1;
missingExp = nextExp - getCharacterInformation().hackingExp; var nextExp = formulas.basic.calculateExp(nextHacking);
var missingExp = nextExp - player.hacking_exp;
tprint("Missing " + missingExp + " to reach next hacking level"); tprint("Missing " + missingExp + " to reach next hacking level");

@ -8,7 +8,8 @@ calculateSkill() Netscript Function
:param number mult: Assume a specific skill multipler (not exp multiplier). :param number mult: Assume a specific skill multipler (not exp multiplier).
:returns: skillLevel that ``exp`` would reach with that multiplier. :returns: skillLevel that ``exp`` would reach with that multiplier.
You must have Source-File 5-1 in order to use this function. If you are not in BitNode-5, then you must have Source-File 5-1 in order to
use this function.
This function calculates the skillLevel that the given amount of ``exp`` would reach. This function calculates the skillLevel that the given amount of ``exp`` would reach.

@ -7,14 +7,18 @@ growPercent() Netscript Function
:param server server: The server that receives the growth. :param server server: The server that receives the growth.
:param number threads: The number of thread that would be used. :param number threads: The number of thread that would be used.
:param player player: The player. :param player player: The player.
:returns: The percentage growth this server would receive with these parameters. :returns: The amount the server's money would be multiplied by with these
parameters.
You must have Source-File 5-1 in order to use this function. If you are not in BitNode-5, then you must have Source-File 5-1 in order to
use this function.
Server can be acquired with the :doc:`getServer<../../advancedfunctions/getServer>` function. Server can be acquired with the :doc:`getServer<../../advancedfunctions/getServer>` function.
Player can be acquired with the :doc:`getPlayer<../../singularityfunctions/getPlayer>` function. Player can be acquired with the :doc:`getPlayer<../../basicfunctions/getPlayer>` function.
This function calculates percentage of growth a server would receive with these parameters. This function calculates the amount of growth, as a multiplier, a server
would receive with these parameters. Despite its name, it does not return
a percentage.
Examples: Examples:

@ -8,10 +8,11 @@ growTime() Netscript Function
:param player player: The player. :param player player: The player.
:returns: The time it takes to grow this server. In seconds. :returns: The time it takes to grow this server. In seconds.
You must have Source-File 5-1 in order to use this function. If you are not in BitNode-5, then you must have Source-File 5-1 in order to
use this function.
Server can be acquired with the :doc:`getServer<../../advancedfunctions/getServer>` function. Server can be acquired with the :doc:`getServer<../../advancedfunctions/getServer>` function.
Player can be acquired with the :doc:`getPlayer<../../singularityfunctions/getPlayer>` function. Player can be acquired with the :doc:`getPlayer<../../basicfunctions/getPlayer>` function.
This function calculates the amount of time it takes to grow a server. This function calculates the amount of time it takes to grow a server.

@ -6,19 +6,20 @@ hackChance() Netscript Function
:RAM cost: 0 GB :RAM cost: 0 GB
:param server server: The server to hack. :param server server: The server to hack.
:param player player: The player. :param player player: The player.
:returns: The change to hack that server. between 0 and 1. :returns: The chance to hack that server, between 0 and 1.
You must have Source-File 5-1 in order to use this function. If you are not in BitNode-5, then you must have Source-File 5-1 in order to
use this function.
Server can be acquired with the :doc:`getServer<../../advancedfunctions/getServer>` function. Server can be acquired with the :doc:`getServer<../../advancedfunctions/getServer>` function.
Player can be acquired with the :doc:`getPlayer<../../singularityfunctions/getPlayer>` function. Player can be acquired with the :doc:`getPlayer<../../basicfunctions/getPlayer>` function.
This function calculates percentage chance to hack a server. This function calculates the probability to successfully hack a server.
Examples: Examples:
.. code-block:: javascript .. code-block:: javascript
server = getServer(); var server = getServer();
server.hackDifficulty = server.minDifficulty; server.hackDifficulty = server.minDifficulty;
tprint(formulas.basic.hackChance(server, getPlayer())); tprint(formulas.basic.hackChance(server, getPlayer()));

@ -8,10 +8,11 @@ hackExp() Netscript Function
:param player player: The player. :param player player: The player.
:returns: The amount of exp that would be acquired if this server were to be hacked. :returns: The amount of exp that would be acquired if this server were to be hacked.
You must have Source-File 5-1 in order to use this function. If you are not in BitNode-5, then you must have Source-File 5-1 in order to
use this function.
Server can be acquired with the :doc:`getServer<../../advancedfunctions/getServer>` function. Server can be acquired with the :doc:`getServer<../../advancedfunctions/getServer>` function.
Player can be acquired with the :doc:`getPlayer<../../singularityfunctions/getPlayer>` function. Player can be acquired with the :doc:`getPlayer<../../basicfunctions/getPlayer>` function.
This function calculates the amount of exp obtained by hacking a server. This function calculates the amount of exp obtained by hacking a server.
@ -19,6 +20,4 @@ hackExp() Netscript Function
.. code-block:: javascript .. code-block:: javascript
server = getServer(); tprint(formulas.basic.hackExp(getServer(), getPlayer()));
server.hackDifficulty = 99.9;
tprint(formulas.basic.hackExp(server, getPlayer()));

@ -6,15 +6,16 @@ hackPercent() Netscript Function
:RAM cost: 0 GB :RAM cost: 0 GB
:param server server: The server to hack. :param server server: The server to hack.
:param player player: The player. :param player player: The player.
:returns: The percentage of money hacked from a servers maximum money. :returns: The percentage of money hacked from the server's money.
You must have Source-File 5-1 in order to use this function. If you are not in BitNode-5, then you must have Source-File 5-1 in order to
use this function.
Server can be acquired with the :doc:`getServer<../../advancedfunctions/getServer>` function. Server can be acquired with the :doc:`getServer<../../advancedfunctions/getServer>` function.
Player can be acquired with the :doc:`getPlayer<../../singularityfunctions/getPlayer>` function. Player can be acquired with the :doc:`getPlayer<../../basicfunctions/getPlayer>` function.
This function calculates the percentage of maximum money hacked from a server. This function calculates the percentage of money hacked from a server.
Multiply this by thread count to know calculate the percentage for more than 1 thread. Multiply this by thread count to calculate the percentage for more than 1 thread.
Examples: Examples:

@ -8,10 +8,11 @@ hackTime() Netscript Function
:param player player: The player. :param player player: The player.
:returns: The time it takes to hack this server. In seconds. :returns: The time it takes to hack this server. In seconds.
You must have Source-File 5-1 in order to use this function. If you are not in BitNode-5, then you must have Source-File 5-1 in order to
use this function.
Server can be acquired with the :doc:`getServer<../../advancedfunctions/getServer>` function. Server can be acquired with the :doc:`getServer<../../advancedfunctions/getServer>` function.
Player can be acquired with the :doc:`getPlayer<../../singularityfunctions/getPlayer>` function. Player can be acquired with the :doc:`getPlayer<../../basicfunctions/getPlayer>` function.
This function calculates the amount of time it takes to hack a server. This function calculates the amount of time it takes to hack a server.

@ -8,10 +8,11 @@ weakenTime() Netscript Function
:param player player: The player. :param player player: The player.
:returns: The time it takes to weaken this server. In seconds. :returns: The time it takes to weaken this server. In seconds.
You must have Source-File 5-1 in order to use this function. If you are not in BitNode-5, then you must have Source-File 5-1 in order to
use this function.
Server can be acquired with the :doc:`getServer<../../advancedfunctions/getServer>` function. Server can be acquired with the :doc:`getServer<../../advancedfunctions/getServer>` function.
Player can be acquired with the :doc:`getPlayer<../../singularityfunctions/getPlayer>` function. Player can be acquired with the :doc:`getPlayer<../../basicfunctions/getPlayer>` function.
This function calculates the amount of time it takes to weaken a server. This function calculates the amount of time it takes to weaken a server.

@ -6,21 +6,28 @@ constants() Netscript Function
:RAM cost: 0 GB :RAM cost: 0 GB
:returns: A structure with various constants related to hacknet nodes. :returns: A structure with various constants related to hacknet nodes.
If you are not in BitNode-5, then you must have Source-File 5-1 in order to
use this function.
Returns an object with the following properties::
{
MoneyGainPerLevel: Multiplied by the node's level to get the node's base income
BaseCost: A multiplier used when buying new nodes or upgrading levels
LevelBaseCost: A multiplier used when upgrading levels
RamBaseCost: A multiplier used when upgrading RAM
CoreBaseCost: A multiplier used when buying additional cores
PurchaseNextMult: The root of an exponent used when buying new nodes
UpgradeLevelMult: The root of an exponent used when upgrading levels
UpgradeRamMult: The root of an exponent used when upgrading RAM
UpgradeCoreMult: The root of an exponent used when buying additional cores
MaxLevel: Maximum level a node can have
MaxRam: Maximum RAM a node can have
MaxCores: Maximum number of cores a node can have
}
Examples: Examples:
.. code-block:: javascript .. code-block:: javascript
{ tprint("Maximum RAM a hacknet node can have: "+formulas.hacknetNodes.constants().MaxRam+" GB.");
MoneyGainPerLevel
BaseCost
LevelBaseCost
RamBaseCost
CoreBaseCost
PurchaseNextMult
UpgradeLevelMult
UpgradeRamMult
UpgradeCoreMult
MaxLevel
MaxRam
MaxCores
}

@ -9,7 +9,8 @@ coreUpgradeCost() Netscript Function
:param number costMult: Aug multiplier that reduces cost. Defaults to ``1``. :param number costMult: Aug multiplier that reduces cost. Defaults to ``1``.
:returns: Money required to go from ``startingCores`` to ``startingCores+extraCores``. :returns: Money required to go from ``startingCores`` to ``startingCores+extraCores``.
You must have Source-File 5-1 in order to use this function. If you are not in BitNode-5, then you must have Source-File 5-1 in order to
use this function.
This function calculates the cost of upgrading cores from any level to any level. This function calculates the cost of upgrading cores from any level to any level.

@ -8,7 +8,8 @@ hacknetNodeCost() Netscript Function
:param number costMult: Aug multiplier that reduces cost. Defaults to ``1``. :param number costMult: Aug multiplier that reduces cost. Defaults to ``1``.
:returns: Money required to buy your ``nodeN`` th node. :returns: Money required to buy your ``nodeN`` th node.
You must have Source-File 5-1 in order to use this function. If you are not in BitNode-5, then you must have Source-File 5-1 in order to
use this function.
This function calculates the cost purchasing a hacknet node. This function calculates the cost purchasing a hacknet node.

@ -9,7 +9,8 @@ levelUpgradeCost() Netscript Function
:param number costMult: Aug multiplier that reduces cost. Defaults to ``1``. :param number costMult: Aug multiplier that reduces cost. Defaults to ``1``.
:returns: Money required to go from ``startingLevel`` to ``startingLevel+extraLevels``. :returns: Money required to go from ``startingLevel`` to ``startingLevel+extraLevels``.
You must have Source-File 5-1 in order to use this function. If you are not in BitNode-5, then you must have Source-File 5-1 in order to
use this function.
This function calculates the cost of upgrading levels from any level to any level. This function calculates the cost of upgrading levels from any level to any level.

@ -9,7 +9,8 @@ moneyGainRate() Netscript Function
:param number core: cores of the node. :param number core: cores of the node.
:returns: Money per second that a node with those stats would gain per second. :returns: Money per second that a node with those stats would gain per second.
You must have Source-File 5-1 in order to use this function. If you are not in BitNode-5, then you must have Source-File 5-1 in order to
use this function.
This function calculates the money rate of a node with the given stats. This function calculates the money rate of a node with the given stats.

@ -11,7 +11,8 @@ ramUpgradeCost() Netscript Function
..note:: ``startingRam`` is the actual amount of ram, not the amount of levels of ram. ..note:: ``startingRam`` is the actual amount of ram, not the amount of levels of ram.
You must have Source-File 5-1 in order to use this function. If you are not in BitNode-5, then you must have Source-File 5-1 in order to
use this function.
This function calculates the cost of upgrading levels from any level to any level. This function calculates the cost of upgrading levels from any level to any level.

@ -9,7 +9,9 @@ cacheUpgradeCost() Netscript Function
:param number costMult: Aug multiplier that reduces cost. Defaults to ``1``. :param number costMult: Aug multiplier that reduces cost. Defaults to ``1``.
:returns: Money required to go from ``startingLevel`` to ``startingLevel+extraLevels``. :returns: Money required to go from ``startingLevel`` to ``startingLevel+extraLevels``.
You must have Source-File 5-1 and Source-File 9-1 in order to use this function. If you are not in BitNode-5, then you must have Source-File 5-1 in order to
use this function. In addition, if you are not in BitNode-9, then you must
have Source-File 9-1 in order to use this function.
This function calculates the cost of upgrading cache from any level to any level. This function calculates the cost of upgrading cache from any level to any level.

@ -6,24 +6,32 @@ constants() Netscript Function
:RAM cost: 0 GB :RAM cost: 0 GB
:returns: A structure with various constants related to hacknet servers. :returns: A structure with various constants related to hacknet servers.
If you are not in BitNode-5, then you must have Source-File 5-1 in order to
use this function. In addition, if you are not in BitNode-9, then you must
have Source-File 9-1 in order to use this function.
Returns an object with the following properties::
{
HashesPerLevel: Multiplied by the server's level to get the server's base income
BaseCost: A multiplier used when buying new nodes or upgrading levels
RamBaseCost: A multiplier used when upgrading RAM
CoreBaseCost: A multiplier used when buying additional cores
CacheBaseCost: A multiplier used when upgrading cache
PurchaseMult: The root of an exponent used when buying new servers
UpgradeLevelMult: The root of an exponent used when upgrading levels
UpgradeRamMult: The root of an exponent used when upgrading RAM
UpgradeCoreMult: The root of an exponent used when buying additional cores
UpgradeCacheMult: The root of an exponent used when upgrading cache
MaxServers: Maximum number of hacknet servers you can own
MaxLevel: Maximum level a server can have
MaxRam: Maximum RAM a server can have
MaxCores: Maximum number of cores a server can have
MaxCache: Maximum cache a server can have
}
Examples: Examples:
.. code-block:: javascript .. code-block:: javascript
{ tprint("Maximum RAM a hacknet server can have: "+formulas.hacknetServers.constants().MaxRam+" GB");
HashesPerLevel
BaseCost
RamBaseCost
CoreBaseCost
CacheBaseCost
PurchaseMult
UpgradeLevelMult
UpgradeRamMult
UpgradeCoreMult
UpgradeCacheMult
MaxServers
MaxLevel
MaxRam
MaxCores
MaxCache
}

@ -9,7 +9,9 @@ coreUpgradeCost() Netscript Function
:param number costMult: Aug multiplier that reduces cost. Defaults to ``1``. :param number costMult: Aug multiplier that reduces cost. Defaults to ``1``.
:returns: Money required to go from ``startingCores`` to ``startingCores+extraCores``. :returns: Money required to go from ``startingCores`` to ``startingCores+extraCores``.
You must have Source-File 5-1 and Source-File 9-1 in order to use this function. If you are not in BitNode-5, then you must have Source-File 5-1 in order to
use this function. In addition, if you are not in BitNode-9, then you must
have Source-File 9-1 in order to use this function.
This function calculates the cost of upgrading cores from any level to any level. This function calculates the cost of upgrading cores from any level to any level.

@ -8,7 +8,9 @@ hacknetServerCost() Netscript Function
:param number costMult: Aug multiplier that reduces cost. Defaults to ``1``. :param number costMult: Aug multiplier that reduces cost. Defaults to ``1``.
:returns: Money required to buy your ``serverN`` th node. :returns: Money required to buy your ``serverN`` th node.
You must have Source-File 5-1 and Source-File 9-1 in order to use this function. If you are not in BitNode-5, then you must have Source-File 5-1 in order to
use this function. In addition, if you are not in BitNode-9, then you must
have Source-File 9-1 in order to use this function.
This function calculates the cost purchasing a hacknet node. This function calculates the cost purchasing a hacknet node.

@ -10,7 +10,9 @@ hashGainRate() Netscript Function
:param number core: cores of the server. :param number core: cores of the server.
:returns: Money per second that a server with those stats would gain per second. :returns: Money per second that a server with those stats would gain per second.
You must have Source-File 5-1 and Source-File 9-1 in order to use this function. If you are not in BitNode-5, then you must have Source-File 5-1 in order to
use this function. In addition, if you are not in BitNode-9, then you must
have Source-File 9-1 in order to use this function.
This function calculates the hash rate of a server with the given stats. This function calculates the hash rate of a server with the given stats.
@ -19,7 +21,7 @@ hashGainRate() Netscript Function
.. code-block:: javascript .. code-block:: javascript
server = hacknet.getNodeStats(1); server = hacknet.getNodeStats(1);
currentRate = formulas.hacknetNodes.hashGainRate(server.level, 0, server.ram, server.cores); currentRate = formulas.hacknetServers.hashGainRate(server.level, 0, server.ram, server.cores);
levelRate = formulas.hacknetNodes.hashGainRate(server.level+1, 0, server.ram, server.cores); levelRate = formulas.hacknetServers.hashGainRate(server.level+1, 0, server.ram, server.cores);
ramRate = formulas.hacknetNodes.hashGainRate(server.level, 0, server.ram*2, server.cores); ramRate = formulas.hacknetServers.hashGainRate(server.level, 0, server.ram*2, server.cores);
coresRate = formulas.hacknetNodes.hashGainRate(server.level, 0, server.ram, server.cores+1); coresRate = formulas.hacknetServers.hashGainRate(server.level, 0, server.ram, server.cores+1);

@ -8,7 +8,9 @@ hashUpgradeCost() Netscript Function
:param number level: Level of the upgrade. :param number level: Level of the upgrade.
:returns: Amount of Hash. :returns: Amount of Hash.
You must have Source-File 5-1 and Source-File 9-1 in order to use this function. If you are not in BitNode-5, then you must have Source-File 5-1 in order to
use this function. In addition, if you are not in BitNode-9, then you must
have Source-File 9-1 in order to use this function.
This function calculates amount of Hash require to buy level ``level`` of upgrade ``upgName``. This function calculates amount of Hash require to buy level ``level`` of upgrade ``upgName``.

@ -9,7 +9,9 @@ levelUpgradeCost() Netscript Function
:param number costMult: Aug multiplier that reduces cost. Defaults to ``1``. :param number costMult: Aug multiplier that reduces cost. Defaults to ``1``.
:returns: Money required to go from ``startingLevel`` to ``startingLevel+extraLevels``. :returns: Money required to go from ``startingLevel`` to ``startingLevel+extraLevels``.
You must have Source-File 5-1 and Source-File 9-1 in order to use this function. If you are not in BitNode-5, then you must have Source-File 5-1 in order to
use this function. In addition, if you are not in BitNode-9, then you must
have Source-File 9-1 in order to use this function.
This function calculates the cost of upgrading levels from any level to any level. This function calculates the cost of upgrading levels from any level to any level.

@ -11,7 +11,9 @@ ramUpgradeCost() Netscript Function
..note:: ``startingRam`` is the actual amount of ram, not the amount of levels of ram. ..note:: ``startingRam`` is the actual amount of ram, not the amount of levels of ram.
You must have Source-File 5-1 and Source-File 9-1 in order to use this function. If you are not in BitNode-5, then you must have Source-File 5-1 in order to
use this function. In addition, if you are not in BitNode-9, then you must
have Source-File 9-1 in order to use this function.
This function calculates the cost of upgrading levels from any level to any level. This function calculates the cost of upgrading levels from any level to any level.

@ -8,15 +8,19 @@ Netscript Formulas Functions
The formulas API allow you to gain insight into the inner workings of the game. The formulas API allow you to gain insight into the inner workings of the game.
These functions will allow you to make more informed decision. These functions will allow you to make more informed decision.
All of these function cost 0 GB of ram to use. All these function require The formulas API is unlocked in BitNode-5. If you are in BitNode-5, you will
Source-File 5-1 but some additionally need another source file level 1 to use. automatically gain access to this API. Otherwise, you must have Source-File 5-1
in order to use this API in other BitNodes. Additionally, some functions need
another source file level 1 to use.
All of these function cost 0 GB of ram to use.
basic formulas basic formulas
-------------- --------------
These functions are under the ``formulas.basic.`` name space and available as These functions are under the ``formulas.basic.`` name space and available as
soon as you acquire Source-File 5-1 soon as you enter BitNode-5 or acquire Source-File 5-1.
.. toctree:: .. toctree::
calculateSkill() <formulasapi/basic/calculateSkill> calculateSkill() <formulasapi/basic/calculateSkill>
@ -34,7 +38,7 @@ hacknetNodes formulas
--------------------- ---------------------
These functions are under the ``formulas.hacknetNodes.`` namespace and available as These functions are under the ``formulas.hacknetNodes.`` namespace and available as
soon as you acquire Source-File 5-1. soon as you enter BitNode-5 or acquire Source-File 5-1.
.. toctree:: .. toctree::
hacknetNodeCost() <formulasapi/hacknetNodes/hacknetNodeCost> hacknetNodeCost() <formulasapi/hacknetNodes/hacknetNodeCost>
@ -48,7 +52,8 @@ hacknetServers formulas
----------------------- -----------------------
These functions are under the ``formulas.hacknetServers.`` namespace. These functions are under the ``formulas.hacknetServers.`` namespace.
These functions require Source-File 5-1 and Source-File 9-1 to be invoked. These functions require either being in BitNode-5 or having Source-File 5-1, and
also require either being in BitNode-9 or having Source-File 9-1 to be invoked.
.. toctree:: .. toctree::
hacknetServerCost() <formulasapi/hacknetServers/hacknetServerCost> hacknetServerCost() <formulasapi/hacknetServers/hacknetServerCost>

@ -159,18 +159,21 @@ importing other NetscriptJS scripts::
this.args = params.args ? params.args : []; this.args = params.args ? params.args : [];
} }
ScriptJob.prototype.run = async function(ns) { ScriptJob.prototype.run = function(ns) {
let runArgs = [this.fn, this.threads].concat(this.args); let runArgs = [this.fn, this.threads].concat(this.args);
await ns.run.apply(this, runArgs); if (!ns.run.apply(this, runArgs)) {
throw new Error("Unable to run " + this.fn + " on " +ns.getHostname());
}
tprintColored("Running " + this.fn + " on " + ns.getHostname(), "blue"); tprintColored("Running " + this.fn + " on " + ns.getHostname(), "blue");
} }
ScriptJob.prototype.exec = async function(ns, target) { ScriptJob.prototype.exec = function(ns, target) {
ns.scp(this.fn, target); ns.scp(this.fn, target);
let execArgs = [this.fn, target, this.threads].concat(this.args); let execArgs = [this.fn, target, this.threads].concat(this.args);
await ns.exec.apply(this, execArgs); if (!ns.exec.apply(this, execArgs)) {
throw new Error("Unable to execute " + this.fn + " on " + target);
}
tprintColored("Executing " + this.fn + " on " + target, "blue"); tprintColored("Executing " + this.fn + " on " + target, "blue");
} }
@ -182,8 +185,8 @@ importing other NetscriptJS scripts::
threads: 1, threads: 1,
args: ["foodnstuff"] args: ["foodnstuff"]
}); });
await job.run(ns); job.run(ns);
await job.exec(ns, "foodnstuff"); job.exec(ns, "foodnstuff");
} catch (e) { } catch (e) {
ns.tprint("Exception thrown in scriptScheduler.ns: " + e); ns.tprint("Exception thrown in scriptScheduler.ns: " + e);
} }

@ -3,21 +3,16 @@
Netscript Singularity Functions Netscript Singularity Functions
=============================== ===============================
The Singularity Functions are a special set of Netscript functions. These functions allow you to control .. warning:: This page contains spoilers for the game.
many additional aspects of the game through scripts, such as working for factions/companies, purchasing/installing Augmentations,
and creating programs. The Singularity Functions are a special set of Netscript functions that allow the player to control additional aspects of the game such as working for factions/companies, purchasing/installing Augmentations, and creating programs.
The Singularity Functions are **not** immediately available to the player and must be unlocked later in the game. The Singularity Functions are **not** immediately available to the player and must be unlocked later in the game.
.. warning:: This page contains spoilers for the game The player has access to all of these functions while in BitNode-4. Completing BitNode-4 and gaining its source-file unlocks certain Singularity Functions for use in other BitNodes, with all functions accessible at level 3.
The Singularity Functions are unlocked in BitNode-4. If you are in BitNode-4, then you will automatically have access to all of these functions.
You can use the Singularity Functions in other BitNodes if and only if you have the Source-File for BitNode-4 (aka Source-File 4). Each level of
Source-File 4 will open up additional Singularity Functions that you can use in other BitNodes. If your Source-File 4 is upgraded all the way to
level 3, then you will be able to access all of the Singularity Functions.
.. toctree:: .. toctree::
:caption: Functions: :caption: Level 1 Functions
universityCourse() <singularityfunctions/universityCourse> universityCourse() <singularityfunctions/universityCourse>
gymWorkout() <singularityfunctions/gymWorkout> gymWorkout() <singularityfunctions/gymWorkout>
@ -30,6 +25,10 @@ level 3, then you will be able to access all of the Singularity Functions.
installBackdoor() <singularityfunctions/installBackdoor> installBackdoor() <singularityfunctions/installBackdoor>
hospitalize() <singularityfunctions/hospitalize> hospitalize() <singularityfunctions/hospitalize>
isBusy() <singularityfunctions/isBusy> isBusy() <singularityfunctions/isBusy>
.. toctree::
:caption: Level 2 Functions
stopAction() <singularityfunctions/stopAction> stopAction() <singularityfunctions/stopAction>
upgradeHomeRam() <singularityfunctions/upgradeHomeRam> upgradeHomeRam() <singularityfunctions/upgradeHomeRam>
getUpgradeHomeRamCost() <singularityfunctions/getUpgradeHomeRamCost> getUpgradeHomeRamCost() <singularityfunctions/getUpgradeHomeRamCost>
@ -44,6 +43,10 @@ level 3, then you will be able to access all of the Singularity Functions.
getFactionRep() <singularityfunctions/getFactionRep> getFactionRep() <singularityfunctions/getFactionRep>
getFactionFavor() <singularityfunctions/getFactionFavor> getFactionFavor() <singularityfunctions/getFactionFavor>
getFactionFavorGain() <singularityfunctions/getFactionFavorGain> getFactionFavorGain() <singularityfunctions/getFactionFavorGain>
.. toctree::
:caption: Level 3 Functions
donateToFaction() <singularityfunctions/donateToFaction> donateToFaction() <singularityfunctions/donateToFaction>
createProgram() <singularityfunctions/createProgram> createProgram() <singularityfunctions/createProgram>
commitCrime() <singularityfunctions/commitCrime> commitCrime() <singularityfunctions/commitCrime>

1906
package-lock.json generated

File diff suppressed because it is too large Load Diff

@ -33,6 +33,7 @@
"loader-runner": "^2.3.0", "loader-runner": "^2.3.0",
"loader-utils": "^1.1.0", "loader-utils": "^1.1.0",
"memory-fs": "~0.4.1", "memory-fs": "~0.4.1",
"node-sass": "^6.0.1",
"normalize.css": "^8.0.0", "normalize.css": "^8.0.0",
"numeral": "2.0.6", "numeral": "2.0.6",
"react": "^16.8.3", "react": "^16.8.3",
@ -76,7 +77,6 @@
"mkdirp": "^0.5.1", "mkdirp": "^0.5.1",
"mocha": "^6.1.4", "mocha": "^6.1.4",
"mochapack": "^1.1.1", "mochapack": "^1.1.1",
"node-sass": "^5.0.0",
"null-loader": "^1.0.0", "null-loader": "^1.0.0",
"raw-loader": "~0.5.0", "raw-loader": "~0.5.0",
"sass-loader": "^7.0.3", "sass-loader": "^7.0.3",
@ -126,5 +126,5 @@
"watch": "webpack --watch --mode production", "watch": "webpack --watch --mode production",
"watch:dev": "webpack --watch --mode development" "watch:dev": "webpack --watch --mode development"
}, },
"version": "0.52.0" "version": "0.52.1"
} }

@ -41,7 +41,7 @@ function getRandomBonus() {
description: "Increases the player's hacking chance by 25%.<br>" + description: "Increases the player's hacking chance by 25%.<br>" +
"Increases the player's hacking speed by 10%.<br>" + "Increases the player's hacking speed by 10%.<br>" +
"Increases the amount of money the player's gains from hacking by 25%.<br>" + "Increases the amount of money the player's gains from hacking by 25%.<br>" +
"Increases the amount of money the player can inject into servers using grow() by 10%.", "Improves grow() by 10%.",
}, },
{ {
bonuses: { bonuses: {
@ -54,13 +54,13 @@ function getRandomBonus() {
{ {
bonuses: { bonuses: {
strength_mult: 1.25, strength_mult: 1.25,
strength_exp_mult: 1.5, strength_exp_mult: 2,
defense_mult: 1.25, defense_mult: 1.25,
defense_exp_mult: 1.5, defense_exp_mult: 2,
dexterity_mult: 1.25, dexterity_mult: 1.25,
dexterity_exp_mult: 1.5, dexterity_exp_mult: 2,
agility_mult: 1.25, agility_mult: 1.25,
agility_exp_mult: 1.5, agility_exp_mult: 2,
}, },
description: "Increases all of the player's combat stats by 25%.<br>" + description: "Increases all of the player's combat stats by 25%.<br>" +
"Increases all of the player's combat stat experience gain rate by 100%.", "Increases all of the player's combat stat experience gain rate by 100%.",
@ -158,9 +158,8 @@ function initAugmentations() {
const Targeting1 = new Augmentation({ const Targeting1 = new Augmentation({
name:AugmentationNames.Targeting1, moneyCost:1.5e7, repCost:5e3, name:AugmentationNames.Targeting1, moneyCost:1.5e7, repCost:5e3,
info:"This cranial implant is embedded within the player's inner ear structure and optic nerves. It regulates and enhances the user's " + info:"A cranial implant that is embedded within the inner ear structures and optic nerves. It regulates " +
"balance and hand-eye coordination. It is also capable of augmenting reality by projecting digital information " + "and enhances balance and hand-eye coordination.<br><br>" +
"directly onto the retina. These enhancements allow the player to better lock-on and keep track of enemies.<br><br>" +
"This augmentation increases the player's dexterity by 10%.", "This augmentation increases the player's dexterity by 10%.",
dexterity_mult: 1.1, dexterity_mult: 1.1,
}); });
@ -173,8 +172,8 @@ function initAugmentations() {
const Targeting2 = new Augmentation({ const Targeting2 = new Augmentation({
name:AugmentationNames.Targeting2, moneyCost:4.25e7, repCost:8.75e3, name:AugmentationNames.Targeting2, moneyCost:4.25e7, repCost:8.75e3,
info:"This is an upgrade of the Augmented Targeting I cranial implant, which is capable of augmenting reality " + info:"This upgraded version of the 'Augmented Targeting' implant is capable of augmenting " +
"and enhances the user's balance and hand-eye coordination.<br><br>" + "reality by digitally displaying weaknesses and vital signs of threats.<br><br>" +
"This augmentation increases the player's dexterity by 20%.", "This augmentation increases the player's dexterity by 20%.",
prereqs:[AugmentationNames.Targeting1], prereqs:[AugmentationNames.Targeting1],
dexterity_mult: 1.2, dexterity_mult: 1.2,
@ -188,8 +187,8 @@ function initAugmentations() {
const Targeting3 = new Augmentation({ const Targeting3 = new Augmentation({
name:AugmentationNames.Targeting3, moneyCost:1.15e8, repCost:2.75e4, name:AugmentationNames.Targeting3, moneyCost:1.15e8, repCost:2.75e4,
info:"This is an upgrade of the Augmented Targeting II cranial implant, which is capable of augmenting reality " + info:"The latest version of the 'Augmented Targeting' implant adds the ability to " +
"and enhances the user's balance and hand-eye coordination.<br><br>" + "lock-on and track threats.<br><br>" +
"This augmentation increases the player's dexterity by 30%.", "This augmentation increases the player's dexterity by 30%.",
prereqs:[AugmentationNames.Targeting2], prereqs:[AugmentationNames.Targeting2],
dexterity_mult: 1.3, dexterity_mult: 1.3,
@ -203,8 +202,8 @@ function initAugmentations() {
const SyntheticHeart = new Augmentation({ const SyntheticHeart = new Augmentation({
name:AugmentationNames.SyntheticHeart, moneyCost:2.875e9, repCost:7.5e5, name:AugmentationNames.SyntheticHeart, moneyCost:2.875e9, repCost:7.5e5,
info:"This advanced artificial heart, created from plasteel and graphene, is capable of pumping more blood " + info:"This advanced artificial heart, created from plasteel and graphene, is capable of pumping blood " +
"at much higher efficiencies than a normal human heart.<br><br>" + "more efficiently than an organic heart.<br><br>" +
"This augmentation increases the player's agility and strength by 50%.", "This augmentation increases the player's agility and strength by 50%.",
agility_mult: 1.5, agility_mult: 1.5,
strength_mult: 1.5, strength_mult: 1.5,
@ -234,8 +233,8 @@ function initAugmentations() {
const CombatRib1 = new Augmentation({ const CombatRib1 = new Augmentation({
name:AugmentationNames.CombatRib1, repCost:7.5e3, moneyCost:2.375e7, name:AugmentationNames.CombatRib1, repCost:7.5e3, moneyCost:2.375e7,
info:"The human body's ribs are replaced with artificial ribs that automatically and continuously release cognitive " + info:"The rib cage is augmented to continuously release boosters into the bloodstream " +
"and performance-enhancing drugs into the bloodstream, improving the user's abilities in combat.<br><br>" + "which increase the oxygen-carrying capacity of blood.<br><br>" +
"This augmentation increases the player's strength and defense by 10%.", "This augmentation increases the player's strength and defense by 10%.",
strength_mult: 1.1, strength_mult: 1.1,
defense_mult: 1.1, defense_mult: 1.1,
@ -249,8 +248,8 @@ function initAugmentations() {
const CombatRib2 = new Augmentation({ const CombatRib2 = new Augmentation({
name:AugmentationNames.CombatRib2, repCost:1.875e4, moneyCost:6.5e7, name:AugmentationNames.CombatRib2, repCost:1.875e4, moneyCost:6.5e7,
info:"This is an upgrade to the Combat Rib I augmentation, and is capable of releasing even more potent combat-enhancing " + info:"An upgraded version of the 'Combat Rib' augmentation that adds potent stimulants which " +
"drugs into the bloodstream.<br><br>" + "improve focus and endurance while decreasing reaction time and fatigue.<br><br>" +
"This augmentation increases the player's strength and defense by 14%.", "This augmentation increases the player's strength and defense by 14%.",
prereqs:[AugmentationNames.CombatRib1], prereqs:[AugmentationNames.CombatRib1],
strength_mult: 1.14, strength_mult: 1.14,
@ -265,8 +264,8 @@ function initAugmentations() {
const CombatRib3 = new Augmentation({ const CombatRib3 = new Augmentation({
name:AugmentationNames.CombatRib3, repCost:3.5e4, moneyCost:1.2e8, name:AugmentationNames.CombatRib3, repCost:3.5e4, moneyCost:1.2e8,
info:"This is an upgrade to the Combat Rib II augmentation, and is capable of releasing even more potent combat-enhancing " + info:"The latest version of the 'Combat Rib' augmentation releases advanced anabolic steroids that " +
"drugs into the bloodstream.<br><br>" + "improve muscle mass and physical performance while being safe and free of side effects.<br><br>" +
"This augmentation increases the player's strength and defense by 18%.", "This augmentation increases the player's strength and defense by 18%.",
prereqs:[AugmentationNames.CombatRib2], prereqs:[AugmentationNames.CombatRib2],
strength_mult: 1.18, strength_mult: 1.18,
@ -281,8 +280,8 @@ function initAugmentations() {
const NanofiberWeave = new Augmentation({ const NanofiberWeave = new Augmentation({
name:AugmentationNames.NanofiberWeave, repCost:3.75e4, moneyCost:1.25e8, name:AugmentationNames.NanofiberWeave, repCost:3.75e4, moneyCost:1.25e8,
info:"Synthetic nanofibers are woven into the skin's extracellular matrix using electrospinning. " + info:"Synthetic nanofibers are woven into the skin's extracellular matrix using electrospinning, " +
"This improves the skin's ability to regenerate itself and protect the body from external stresses and forces.<br><br>" + "which improves its regenerative and extracellular homeostasis abilities.<br><br>" +
"This augmentation increases the player's strength and defense by 20%.", "This augmentation increases the player's strength and defense by 20%.",
strength_mult: 1.2, strength_mult: 1.2,
defense_mult: 1.2, defense_mult: 1.2,
@ -314,7 +313,7 @@ function initAugmentations() {
const WiredReflexes = new Augmentation({ const WiredReflexes = new Augmentation({
name:AugmentationNames.WiredReflexes, repCost:1.25e3, moneyCost:2.5e6, name:AugmentationNames.WiredReflexes, repCost:1.25e3, moneyCost:2.5e6,
info:"Synthetic nerve-enhancements are injected into all major parts of the somatic nervous system, " + info:"Synthetic nerve-enhancements are injected into all major parts of the somatic nervous system, " +
"supercharging the body's ability to send signals through neurons. This results in increased reflex speed.<br><br>" + "supercharging the spread of neural signals and increasing reflex speed.<br><br>" +
"This augmentation increases the player's agility and dexterity by 5%.", "This augmentation increases the player's agility and dexterity by 5%.",
agility_mult: 1.05, agility_mult: 1.05,
dexterity_mult: 1.05, dexterity_mult: 1.05,
@ -328,8 +327,8 @@ function initAugmentations() {
const GrapheneBoneLacings = new Augmentation({ const GrapheneBoneLacings = new Augmentation({
name:AugmentationNames.GrapheneBoneLacings, repCost:1.125e6, moneyCost:4.25e9, name:AugmentationNames.GrapheneBoneLacings, repCost:1.125e6, moneyCost:4.25e9,
info:"A graphene-based material is grafted and fused into the user's bones, significantly increasing " + info:"Graphene is grafted and fused into the skeletal structure, " +
"their density and tensile strength.<br><br>" + "enhancing bone density and tensile strength.<br><br>" +
"This augmentation increases the player's strength and defense by 70%.", "This augmentation increases the player's strength and defense by 70%.",
strength_mult: 1.7, strength_mult: 1.7,
defense_mult: 1.7, defense_mult: 1.7,
@ -342,10 +341,10 @@ function initAugmentations() {
const BionicSpine = new Augmentation({ const BionicSpine = new Augmentation({
name:AugmentationNames.BionicSpine, repCost:4.5e4, moneyCost:1.25e8, name:AugmentationNames.BionicSpine, repCost:4.5e4, moneyCost:1.25e8,
info:"An artificial spine created from plasteel and carbon fibers that completely replaces the organic spine. " + info:"The spine is reconstructed using plasteel and carbon fibers. " +
"Not only is the Bionic Spine physically stronger than a human spine, but it is also capable of digitally " + "It is now capable of stimulating and regulating neural signals " +
"stimulating and regulating the neural signals that are sent and received by the spinal cord. This results in " + "passing through the spinal cord, improving senses and reaction speed. " +
"greatly improved senses and reaction speeds.<br><br>" + "The 'Bionic Spine' also interfaces with all other 'Bionic' implants.<br><br>" +
"This augmentation increases all of the player's combat stats by 15%.", "This augmentation increases all of the player's combat stats by 15%.",
strength_mult: 1.15, strength_mult: 1.15,
defense_mult: 1.15, defense_mult: 1.15,
@ -361,8 +360,8 @@ function initAugmentations() {
const GrapheneBionicSpine = new Augmentation({ const GrapheneBionicSpine = new Augmentation({
name:AugmentationNames.GrapheneBionicSpine, repCost:1.625e6, moneyCost:6e9, name:AugmentationNames.GrapheneBionicSpine, repCost:1.625e6, moneyCost:6e9,
info:"An upgrade to the Bionic Spine augmentation. It fuses the implant with an advanced graphene " + info:"An upgrade to the 'Bionic Spine' augmentation. The spine is fused with graphene " +
"material to make it much stronger and lighter.<br><br>" + "which enhances durability and supercharges all body functions.<br><br>" +
"This augmentation increases all of the player's combat stats by 60%.", "This augmentation increases all of the player's combat stats by 60%.",
prereqs:[AugmentationNames.BionicSpine], prereqs:[AugmentationNames.BionicSpine],
strength_mult: 1.6, strength_mult: 1.6,
@ -378,7 +377,7 @@ function initAugmentations() {
const BionicLegs = new Augmentation({ const BionicLegs = new Augmentation({
name:AugmentationNames.BionicLegs, repCost:1.5e5, moneyCost:3.75e8, name:AugmentationNames.BionicLegs, repCost:1.5e5, moneyCost:3.75e8,
info:"Cybernetic legs created from plasteel and carbon fibers that completely replace the user's organic legs.<br><br>" + info:"Cybernetic legs, created from plasteel and carbon fibers, enhance running speed.<br><br>" +
"This augmentation increases the player's agility by 60%.", "This augmentation increases the player's agility by 60%.",
agility_mult: 1.6, agility_mult: 1.6,
}); });
@ -391,8 +390,8 @@ function initAugmentations() {
const GrapheneBionicLegs = new Augmentation({ const GrapheneBionicLegs = new Augmentation({
name:AugmentationNames.GrapheneBionicLegs, repCost:7.5e5, moneyCost:4.5e9, name:AugmentationNames.GrapheneBionicLegs, repCost:7.5e5, moneyCost:4.5e9,
info:"An upgrade to the Bionic Legs augmentation. It fuses the implant with an advanced graphene " + info:"An upgrade to the 'Bionic Legs' augmentation. The legs are fused " +
"material to make it much stronger and lighter.<br><br>" + "with graphene, greatly enhancing jumping ability.<br><br>" +
"This augmentation increases the player's agility by 150%.", "This augmentation increases the player's agility by 150%.",
prereqs: [AugmentationNames.BionicLegs], prereqs: [AugmentationNames.BionicLegs],
agility_mult: 2.5, agility_mult: 2.5,
@ -798,7 +797,7 @@ function initAugmentations() {
"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 amount of money the player can inject into servers using grow() by 25%.", "Improves grow() by 25%.",
prereqs:[AugmentationNames.CranialSignalProcessorsG3], prereqs:[AugmentationNames.CranialSignalProcessorsG3],
hacking_speed_mult: 1.02, hacking_speed_mult: 1.02,
hacking_money_mult: 1.2, hacking_money_mult: 1.2,
@ -819,7 +818,7 @@ function initAugmentations() {
"This augmentation:<br>" + "This augmentation:<br>" +
"Increases the player's hacking skill by 30%.<br>" + "Increases the player's hacking skill by 30%.<br>" +
"Increases the amount of money the player gains from hacking by 25%.<br>" + "Increases the amount of money the player gains from hacking by 25%.<br>" +
"Increases the amount of money the player can inject into servers using grow() by 75%.", "Improves grow() by 75%.",
prereqs:[AugmentationNames.CranialSignalProcessorsG4], prereqs:[AugmentationNames.CranialSignalProcessorsG4],
hacking_mult: 1.3, hacking_mult: 1.3,
hacking_money_mult: 1.25, hacking_money_mult: 1.25,
@ -1250,7 +1249,7 @@ function initAugmentations() {
const LuminCloaking2 = new Augmentation({ const LuminCloaking2 = new Augmentation({
name:AugmentationNames.LuminCloaking2, repCost:5e3, moneyCost:3e7, name:AugmentationNames.LuminCloaking2, repCost:5e3, moneyCost:3e7,
info:"This is a more advanced version of the LuminCloaking-V2 augmentation. This skin implant " + info:"This is a more advanced version of the LuminCloaking-V1 augmentation. This skin implant " +
"reinforces the skin with highly-advanced synthetic cells. These " + "reinforces the skin with highly-advanced synthetic cells. These " +
"cells, when powered, are capable of not only bending light but also of bending heat, " + "cells, when powered, are capable of not only bending light but also of bending heat, " +
"making the user more resilient as well as stealthy.<br><br>" + "making the user more resilient as well as stealthy.<br><br>" +
@ -1487,7 +1486,7 @@ function initAugmentations() {
"Even though it contains no weapons, the advanced tungsten titanium " + "Even though it contains no weapons, the advanced tungsten titanium " +
"alloy increases the users strength to unbelievable levels. The augmentation " + "alloy increases the users strength to unbelievable levels. The augmentation " +
"gets more powerful over time for seemingly no reason.<br><br>" + "gets more powerful over time for seemingly no reason.<br><br>" +
"This augmentation increases the player's strength by 270%.", "This augmentation increases the player's strength by 170%.",
strength_mult: 2.70, strength_mult: 2.70,
}); });
HydroflameLeftArm.addToFactions(["NWO"]); HydroflameLeftArm.addToFactions(["NWO"]);

@ -111,8 +111,8 @@ BitNodes["BitNode5"] = new BitNode(5, "Artificial Intelligence", "Posthuman",
"gaining Intelligence experience is much slower than other stats, and it is also hidden (you won't know " + "gaining Intelligence experience is much slower than other stats, and it is also hidden (you won't know " +
"when you gain experience and how much). Higher Intelligence levels will boost your production for many actions " + "when you gain experience and how much). Higher Intelligence levels will boost your production for many actions " +
"in the game. <br><br>" + "in the game. <br><br>" +
"In addition, this Source-File will unlock the getBitNodeMultipliers() Netscript function, " + "In addition, this Source-File will unlock the getBitNodeMultipliers() and getServer() Netscript functions, " +
"and will also raise all of your hacking-related multipliers by:<br><br>" + "as well as the formulas API, and will also raise all of your hacking-related multipliers by:<br><br>" +
"Level 1: 8%<br>" + "Level 1: 8%<br>" +
"Level 2: 12%<br>" + "Level 2: 12%<br>" +
"Level 3: 14%"); "Level 3: 14%");

@ -23,7 +23,7 @@ export const CorporationUnlockUpgrades: IMap<any[]> = {
"3": [3, 5e9, "Market Data - Competition", "3": [3, 5e9, "Market Data - Competition",
"Mine and analyze market data to determine how much competition there is on the market " + "Mine and analyze market data to determine how much competition there is on the market " +
"for all resources. The competition attribute, which affects sales, will be displayed for " + "for all resources. The competition attribute, which affects sales, will be displayed for " +
"for every material and product."], "every material and product."],
"4": [4, 10e9, "VeChain", "4": [4, 10e9, "VeChain",
"Use AI and blockchain technology to identify where you can improve your supply chain systems. " + "Use AI and blockchain technology to identify where you can improve your supply chain systems. " +
"This upgrade will allow you to view a wide array of useful statistics about your " + "This upgrade will allow you to view a wide array of useful statistics about your " +

@ -35,7 +35,7 @@ export function executeDarkwebTerminalCommand(commandArray: string[]): void {
return; return;
} }
const arg = commandArray[1]; const arg = commandArray[1];
if (arg == "-l") { if (arg == "-l" || arg == "-1" || arg == "--list") {
listAllDarkwebItems(); listAllDarkwebItems();
} else { } else {
buyDarkwebItem(arg); buyDarkwebItem(arg);

@ -21,6 +21,25 @@ function diffStr(d: number): string {
return "impossible"; return "impossible";
} }
function arrowPart(color: string, length: number): JSX.Element {
let arrow = "";
if(length <= 0) length = 0;
else if(length > 13) length = 13;
else {
length--;
arrow = ">";
}
return <span style={{color: color}}>{"=".repeat(length)}{arrow}{" ".repeat(13-arrow.length-length)}</span>
}
function coloredArrow(difficulty: number): JSX.Element {
if(difficulty === 0) {
return <span style={{color: 'white'}}>{'>'}{" ".repeat(38)}</span>
} else {
return <>{arrowPart('white', difficulty*13)}{arrowPart('orange', (difficulty-1)*13)}{arrowPart('red', (difficulty-2)*13)}</>
}
}
export function Intro(props: IProps): React.ReactElement { export function Intro(props: IProps): React.ReactElement {
return (<> return (<>
<Grid container spacing={3}> <Grid container spacing={3}>
@ -28,7 +47,13 @@ export function Intro(props: IProps): React.ReactElement {
<h1>Infiltrating {props.Location}</h1> <h1>Infiltrating {props.Location}</h1>
</Grid> </Grid>
<Grid item xs={10}> <Grid item xs={10}>
<h2>Difficulty: {diffStr(props.Difficulty)}, Maximum level: {props.MaxLevel}</h2> <h2>Maximum level: {props.MaxLevel}</h2>
</Grid>
<Grid item xs={10}>
<pre>[{coloredArrow(props.Difficulty)}]</pre>
<pre> ^ ^ ^ ^</pre>
<pre> Trivial Normal Hard Impossible</pre>
</Grid> </Grid>
<Grid item xs={10}> <Grid item xs={10}>
<p>Infiltration is a series of short minigames that get <p>Infiltration is a series of short minigames that get

@ -259,7 +259,7 @@ function iTutorialEvaluateStep() {
Engine.loadTerminalContent(); Engine.loadTerminalContent();
iTutorialSetText("Hacking is the core mechanic of the game and is necessary for progressing. However, " + iTutorialSetText("Hacking is the core mechanic of the game and is necessary for progressing. However, " +
"you don't want to be hacking manually the entire time. You can automate your hacking " + "you don't want to be hacking manually the entire time. You can automate your hacking " +
"by writing scripts!<br><br>To create a new script or edit an existing one, you can use the <code class='interactive-tutorial-command'>nano</code> " + "by writing scripts!<br><br>First go to your home server with the <code class='interactive-tutorial-command'>home</code> command.<br><br>To create a new script or edit an existing one, you can use the <code class='interactive-tutorial-command'>nano</code> " +
"command. Scripts must end with the <code class='interactive-tutorial-command'>.script</code> extension. Let's make a script now by " + "command. Scripts must end with the <code class='interactive-tutorial-command'>.script</code> extension. Let's make a script now by " +
"entering <code class='interactive-tutorial-command'>nano n00dles.script</code> after the hack command finishes running (Sidenote: Pressing ctrl + c" + "entering <code class='interactive-tutorial-command'>nano n00dles.script</code> after the hack command finishes running (Sidenote: Pressing ctrl + c" +
" will end a command like hack early)"); " will end a command like hack early)");
@ -288,7 +288,7 @@ function iTutorialEvaluateStep() {
break; break;
case iTutorialSteps.TerminalRunScript: case iTutorialSteps.TerminalRunScript:
Engine.loadTerminalContent(); Engine.loadTerminalContent();
iTutorialSetText("We have 16GB of free RAM on this machine, which is enough to run our " + iTutorialSetText("We have 4GB of free RAM on this machine, which is enough to run our " +
"script. Let's run our script using <code class='interactive-tutorial-command'>run n00dles.script</code>."); "script. Let's run our script using <code class='interactive-tutorial-command'>run n00dles.script</code>.");
nextBtn.style.display = "none"; // next step triggered by terminal commmand nextBtn.style.display = "none"; // next step triggered by terminal commmand
break; break;

@ -441,10 +441,3 @@ export const LocationsMetadata: IConstructorParams[] = [
types: [LocationType.StockMarket], types: [LocationType.StockMarket],
}, },
]; ];
(function(){
for(const loc of LocationsMetadata) {
if(!loc || !loc.infiltrationData) continue
console.log(loc.infiltrationData.startingSecurityLevel+2);
}
})();

@ -1785,6 +1785,7 @@ export function getNextCompanyPosition(company, entryPosType) {
} }
export function quitJob(company) { export function quitJob(company) {
this.isWorking = false;
this.companyName = ""; this.companyName = "";
delete this.jobs[company]; delete this.jobs[company];
} }

@ -26,7 +26,8 @@ SourceFiles["SourceFile5"] = new SourceFile(5, "This Source-File grants a specia
"gaining Intelligence experience is much slower than other stats, and it is also hidden (you won't " + "gaining Intelligence experience is much slower than other stats, and it is also hidden (you won't " +
"know when you gain experience and how much). Higher Intelligence levels will boost your production " + "know when you gain experience and how much). Higher Intelligence levels will boost your production " +
"for many actions in the game. In addition, this Source-File will unlock the getBitNodeMultipliers() " + "for many actions in the game. In addition, this Source-File will unlock the getBitNodeMultipliers() " +
"Netscript function, and will raise all of your hacking-related multipliers by:<br><br> " + "and getServer() Netscript functions, as well as the formulas API, and will raise all of your " +
"hacking-related multipliers by:<br><br> " +
"Level 1: 8%<br>" + "Level 1: 8%<br>" +
"Level 2: 12%<br>" + "Level 2: 12%<br>" +
"Level 3: 14%"); "Level 3: 14%");

@ -1993,7 +1993,7 @@ let Terminal = {
(function() { (function() {
var hostname = links[i].innerHTML.toString(); var hostname = links[i].innerHTML.toString();
links[i].onclick = function() { links[i].onclick = function() {
if (Terminal.analyzeFlag || Terminal.hackFlag) {return;} if (Terminal.analyzeFlag || Terminal.hackFlag || Terminal.backdoorFlag) {return;}
Terminal.connectToServer(hostname); Terminal.connectToServer(hostname);
} }
}());// Immediate invocation }());// Immediate invocation

@ -458,7 +458,6 @@ const Engine = {
loadCorporationContent: function() { loadCorporationContent: function() {
if (Player.corporation instanceof Corporation) { if (Player.corporation instanceof Corporation) {
Engine.hideAllContent(); Engine.hideAllContent();
document.getElementById("character-overview-wrapper").style.visibility = "hidden";
routing.navigateTo(Page.Corporation); routing.navigateTo(Page.Corporation);
Player.corporation.createUI(); Player.corporation.createUI();
} }