mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2024-11-26 01:23:49 +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:
|
* // NS1:
|
||||||
* var upgradeName = "Sell for Corporation Funds";
|
* var upgradeName = "Sell for Corporation Funds";
|
||||||
* if (hacknet.numHashes() > hacknet.hashCost(upgradeName)) {
|
* if (hacknet.numHashes() > hacknet.hashCost(upgradeName)) {
|
||||||
* hacknet.spendHashes(upgName);
|
* hacknet.spendHashes(upgradeName);
|
||||||
* }
|
* }
|
||||||
* ```
|
* ```
|
||||||
* @example
|
* @example
|
||||||
@ -2109,7 +2109,7 @@ export declare interface Hacknet {
|
|||||||
* // NS2:
|
* // NS2:
|
||||||
* const upgradeName = "Sell for Corporation Funds";
|
* const upgradeName = "Sell for Corporation Funds";
|
||||||
* if (ns.hacknet.numHashes() > ns.hacknet.hashCost(upgradeName)) {
|
* 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.
|
* @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:
|
* // NS1:
|
||||||
* var upgradeName = "Sell for Corporation Funds";
|
* var upgradeName = "Sell for Corporation Funds";
|
||||||
* if (hacknet.numHashes() > hacknet.hashCost(upgradeName)) {
|
* if (hacknet.numHashes() > hacknet.hashCost(upgradeName)) {
|
||||||
* hacknet.spendHashes(upgName);
|
* hacknet.spendHashes(upgradeName);
|
||||||
* }
|
* }
|
||||||
* ```
|
* ```
|
||||||
* @example
|
* @example
|
||||||
@ -2626,7 +2626,7 @@ export interface Hacknet {
|
|||||||
* // NS2:
|
* // NS2:
|
||||||
* const upgradeName = "Sell for Corporation Funds";
|
* const upgradeName = "Sell for Corporation Funds";
|
||||||
* if (ns.hacknet.numHashes() > ns.hacknet.hashCost(upgradeName)) {
|
* 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.
|
* @param upgName - Name of the upgrade of Hacknet Node.
|
||||||
|
Loading…
Reference in New Issue
Block a user