From 5fc7993dff66fe7919d51f9cd81311e929401a5b Mon Sep 17 00:00:00 2001 From: Sage Pointer Date: Wed, 19 Jan 2022 02:47:51 +0200 Subject: [PATCH 1/6] Remove console spamming from CalculateShareMult --- src/NetworkShare/Share.tsx | 1 - 1 file changed, 1 deletion(-) diff --git a/src/NetworkShare/Share.tsx b/src/NetworkShare/Share.tsx index c761063d0..d0fe2ba84 100644 --- a/src/NetworkShare/Share.tsx +++ b/src/NetworkShare/Share.tsx @@ -8,6 +8,5 @@ export function StartSharing(threads: number): () => void { } export function CalculateShareMult(): number { - console.log(`${sharePower} => ${CSM(sharePower)}`); return CSM(sharePower); } From c5bf58a3eb7a13c8c3f1dfe94c462dcd6f1d370a Mon Sep 17 00:00:00 2001 From: Meowdoleon Date: Wed, 19 Jan 2022 13:58:15 -0500 Subject: [PATCH 2/6] Declaring the script variable in the NS2 example Small change to declares the script variable in the NS2 example. --- markdown/bitburner.ns.ps.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/markdown/bitburner.ns.ps.md b/markdown/bitburner.ns.ps.md index af92330e3..6ef602e19 100644 --- a/markdown/bitburner.ns.ps.md +++ b/markdown/bitburner.ns.ps.md @@ -48,7 +48,7 @@ for (let i = 0; i < scripts.length; ++i) { ```ts // NS2: const ps = ns.ps("home"); -for (script of ps) { +for (let script of ps) { ns.tprint(`${script.filename} ${ps[i].threads}`); ns.tprint(script.args); } From 81db1b0a97e91ba71e97f3e9b4d6e805ecb76563 Mon Sep 17 00:00:00 2001 From: Johnny Urosevic Date: Wed, 19 Jan 2022 13:00:59 -0800 Subject: [PATCH 3/6] Change "import" to "important" --- src/Literature/Literatures.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Literature/Literatures.ts b/src/Literature/Literatures.ts index 44b9ab873..755cd33f8 100644 --- a/src/Literature/Literatures.ts +++ b/src/Literature/Literatures.ts @@ -19,7 +19,7 @@ export const Literatures: IMap = {}; "money on a server, and grow() increases the amount of money on a server by some percentage (multiplicatively)

" + "-Because hack() and grow() work by percentages, they are more effective if the target server has a high amount of money. " + "Therefore, you should try to increase the amount of money on a server (using grow()) to a certain amount before hacking it. Two " + - "import Netscript functions for this are getServerMoneyAvailable() and getServerMaxMoney()

" + + "important Netscript functions for this are getServerMoneyAvailable() and getServerMaxMoney()

" + "-Keep security level low. Security level affects everything when hacking. Two important Netscript functions " + "for this are getServerSecurityLevel() and getServerMinSecurityLevel()

" + "-Purchase additional servers by visiting 'Alpha Enterprises' in the city. They are relatively cheap " + From b63bb3f1e640808c243a8e7150e24416663696ae Mon Sep 17 00:00:00 2001 From: Joe <37256060+JosephDavidTalbot@users.noreply.github.com> Date: Wed, 19 Jan 2022 15:26:10 -0600 Subject: [PATCH 4/6] Fixed the Coding Contracts docs formatting The table wasn't displaying, and one of the lines was out of place. This should probably fix it. --- doc/source/basicgameplay/codingcontracts.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/source/basicgameplay/codingcontracts.rst b/doc/source/basicgameplay/codingcontracts.rst index f4f653250..00feb7eba 100644 --- a/doc/source/basicgameplay/codingcontracts.rst +++ b/doc/source/basicgameplay/codingcontracts.rst @@ -113,7 +113,7 @@ The list contains the name of (i.e. the value returned by | | | to any position from i to i+n. | | | | | | | | Assuming you are initially positioned at the start of the array, determine | -| | | whether you are able to reach the last index of the array. | +| | | whether you are able to reach the last index of the array. | +------------------------------------+------------------------------------------------------------------------------------------+ | Merge Overlapping Intervals | | Given an array of intervals, merge all overlapping intervals. An interval | | | | is an array with two numbers, where the first number is always less than | From 5952f0188532fb8cb82fbed085d0c3eb0685f092 Mon Sep 17 00:00:00 2001 From: Joe <37256060+JosephDavidTalbot@users.noreply.github.com> Date: Wed, 19 Jan 2022 15:34:48 -0600 Subject: [PATCH 5/6] Fixed Coding Contract Documentation The table wasn't displaying. Put a misplaced | back where it should be. Should work fine now. --- doc/source/basicgameplay/codingcontracts.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/source/basicgameplay/codingcontracts.rst b/doc/source/basicgameplay/codingcontracts.rst index f4f653250..00feb7eba 100644 --- a/doc/source/basicgameplay/codingcontracts.rst +++ b/doc/source/basicgameplay/codingcontracts.rst @@ -113,7 +113,7 @@ The list contains the name of (i.e. the value returned by | | | to any position from i to i+n. | | | | | | | | Assuming you are initially positioned at the start of the array, determine | -| | | whether you are able to reach the last index of the array. | +| | | whether you are able to reach the last index of the array. | +------------------------------------+------------------------------------------------------------------------------------------+ | Merge Overlapping Intervals | | Given an array of intervals, merge all overlapping intervals. An interval | | | | is an array with two numbers, where the first number is always less than | From 6e908814db14b46049def8c38491974f3974458c Mon Sep 17 00:00:00 2001 From: Martin Fournier Date: Thu, 20 Jan 2022 06:50:19 -0500 Subject: [PATCH 6/6] Add game version in document.title Also add [dev] prefix when in development mode. --- src/ui/LoadingScreen.tsx | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/src/ui/LoadingScreen.tsx b/src/ui/LoadingScreen.tsx index 5b3147f9c..2b73fb734 100644 --- a/src/ui/LoadingScreen.tsx +++ b/src/ui/LoadingScreen.tsx @@ -30,6 +30,13 @@ export function LoadingScreen(): React.ReactElement { const [show, setShow] = useState(false); const [loaded, setLoaded] = useState(false); + const version = `v${CONSTANTS.VersionString} (${hash()})`; + if (process.env.NODE_ENV === "development") { + document.title = `[dev] Bitburner ${version}`; + } else { + document.title = `Bitburner ${version}`; + } + useEffect(() => { const id = setTimeout(() => { if (!loaded) setShow(true); @@ -70,9 +77,7 @@ export function LoadingScreen(): React.ReactElement { - - Loading Bitburner v{CONSTANTS.VersionString} ({hash()}) - + Loading Bitburner {version} {show && (