2022-10-21 17:16:00 +02:00
|
|
|
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
|
|
|
|
|
|
[Home](./index.md) > [bitburner](./bitburner.md) > [Hacknet](./bitburner.hacknet.md) > [getHashUpgrades](./bitburner.hacknet.gethashupgrades.md)
|
|
|
|
|
|
|
|
## Hacknet.getHashUpgrades() method
|
|
|
|
|
|
|
|
Get the list of hash upgrades
|
|
|
|
|
2023-02-11 19:18:50 +01:00
|
|
|
**Signature:**
|
2022-10-21 17:16:00 +02:00
|
|
|
|
|
|
|
```typescript
|
|
|
|
getHashUpgrades(): string[];
|
|
|
|
```
|
2023-02-11 19:18:50 +01:00
|
|
|
**Returns:**
|
2022-10-21 17:16:00 +02:00
|
|
|
|
|
|
|
string\[\]
|
|
|
|
|
|
|
|
An array containing the available upgrades
|
|
|
|
|
|
|
|
## Remarks
|
|
|
|
|
|
|
|
RAM cost: 0 GB
|
|
|
|
|
|
|
|
This function is only applicable for Hacknet Servers (the upgraded version of a Hacknet Node).
|
|
|
|
|
|
|
|
Returns the list of all available hash upgrades that can be used in the spendHashes function.
|
|
|
|
|
|
|
|
## Example 1
|
|
|
|
|
|
|
|
|
|
|
|
```ts
|
|
|
|
// NS1:
|
|
|
|
var upgrades = hacknet.getHashUpgrades(); // ["Sell for Money","Sell for Corporation Funds",...]
|
|
|
|
```
|
|
|
|
|
|
|
|
## Example 2
|
|
|
|
|
|
|
|
|
|
|
|
```ts
|
|
|
|
// NS2:
|
|
|
|
const upgrades = ns.hacknet.getHashUpgrades(); // ["Sell for Money","Sell for Corporation Funds",...]
|
|
|
|
```
|
|
|
|
|