A wrapper function for ns.exec which uses ns.scp to ensure the script is present and up-to-date on the target host.
A Netscript context.
The script to be executed.
The host the script is to be executed on.
The number of threads with which the script is to be executed.
The arguments with which the script is to be executed.
0
if ns.exec failed somehow.-1
if the script doesn't exist.-2
if the target host doesn't exist.-3
if the thread count is too low.-4
if there isn't enough ram on the target host.-5
if the thread count is a non-integer.-6
if the script is already running.-7
if ns.scp
fails for some reason.Generated using TypeDoc
A library for executing Bitburner scripts on remote hosts, without needing to worry about whether or not the script is present on the remote host.