mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2026-04-17 14:59:16 +02:00
scan doc
This commit is contained in:
@@ -131,7 +131,7 @@ export async function main(ns) {
|
||||
| [relaysmtp(host)](./bitburner.ns.relaysmtp.md) | Runs relaySMTP.exe on a server. |
|
||||
| [rm(name, host)](./bitburner.ns.rm.md) | Delete a file. |
|
||||
| [run(script, numThreads, args)](./bitburner.ns.run.md) | Start another script on the current server. |
|
||||
| [scan(host, hostnames)](./bitburner.ns.scan.md) | Get the list servers connected to a server. |
|
||||
| [scan(host)](./bitburner.ns.scan.md) | Get the list servers connected to a server. |
|
||||
| [scp(files, source, destination)](./bitburner.ns.scp.md) | Copy file between servers. |
|
||||
| [scriptKill(script, host)](./bitburner.ns.scriptkill.md) | Kill all scripts with a filename. |
|
||||
| [scriptRunning(script, host)](./bitburner.ns.scriptrunning.md) | Check if any script with a filename is running. |
|
||||
|
||||
@@ -9,7 +9,7 @@ Get the list servers connected to a server.
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
scan(host: string, hostnames?: boolean): string[];
|
||||
scan(host?: string): string[];
|
||||
```
|
||||
|
||||
## Parameters
|
||||
@@ -17,17 +17,16 @@ scan(host: string, hostnames?: boolean): string[];
|
||||
| Parameter | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| host | string | Hostname of the server to scan. |
|
||||
| hostnames | boolean | Optional boolean specifying whether the function should output hostnames (if true) or IP addresses (if false). |
|
||||
|
||||
<b>Returns:</b>
|
||||
|
||||
string\[\]
|
||||
|
||||
Returns an string of hostnames or IP.
|
||||
Returns an string of hostnames.
|
||||
|
||||
## Remarks
|
||||
|
||||
RAM cost: 0.2 GB
|
||||
|
||||
Returns an array containing the hostnames or IPs of all servers that are one node way from the specified target server. The hostnames/IPs in the returned array are strings.
|
||||
Returns an array containing the hostnames of all servers that are one node way from the specified target server. The hostnames in the returned array are strings.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user