mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2024-12-22 14:12:27 +01:00
Merge pull request #3404 from Chris380/bugfix/3057_hashCost_example_code
Fixed hashCost() example code
This commit is contained in:
commit
aa1ab030a3
4
dist/bitburner.d.ts
vendored
4
dist/bitburner.d.ts
vendored
@ -2101,7 +2101,7 @@ export declare interface Hacknet {
|
||||
* // NS1:
|
||||
* var upgradeName = "Sell for Corporation Funds";
|
||||
* if (hacknet.numHashes() > hacknet.hashCost(upgradeName)) {
|
||||
* hacknet.spendHashes(upgName);
|
||||
* hacknet.spendHashes(upgradeName);
|
||||
* }
|
||||
* ```
|
||||
* @example
|
||||
@ -2109,7 +2109,7 @@ export declare interface Hacknet {
|
||||
* // NS2:
|
||||
* const upgradeName = "Sell for Corporation Funds";
|
||||
* if (ns.hacknet.numHashes() > ns.hacknet.hashCost(upgradeName)) {
|
||||
* ns.hacknet.spendHashes(upgName);
|
||||
* ns.hacknet.spendHashes(upgradeName);
|
||||
* }
|
||||
* ```
|
||||
* @param upgName - Name of the upgrade of Hacknet Node.
|
||||
|
4
src/ScriptEditor/NetscriptDefinitions.d.ts
vendored
4
src/ScriptEditor/NetscriptDefinitions.d.ts
vendored
@ -2618,7 +2618,7 @@ export interface Hacknet {
|
||||
* // NS1:
|
||||
* var upgradeName = "Sell for Corporation Funds";
|
||||
* if (hacknet.numHashes() > hacknet.hashCost(upgradeName)) {
|
||||
* hacknet.spendHashes(upgName);
|
||||
* hacknet.spendHashes(upgradeName);
|
||||
* }
|
||||
* ```
|
||||
* @example
|
||||
@ -2626,7 +2626,7 @@ export interface Hacknet {
|
||||
* // NS2:
|
||||
* const upgradeName = "Sell for Corporation Funds";
|
||||
* if (ns.hacknet.numHashes() > ns.hacknet.hashCost(upgradeName)) {
|
||||
* ns.hacknet.spendHashes(upgName);
|
||||
* ns.hacknet.spendHashes(upgradeName);
|
||||
* }
|
||||
* ```
|
||||
* @param upgName - Name of the upgrade of Hacknet Node.
|
||||
|
Loading…
Reference in New Issue
Block a user