mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2026-04-23 17:53:00 +02:00
NETSCRIPT: A minorly breaking change around script launch, and refactoring. (#1213)
This commit is contained in:
@@ -1,12 +1,12 @@
|
||||
import { NSFull } from "../NetscriptFunctions";
|
||||
import { AutocompleteData } from "@nsdefs";
|
||||
import type { NSFull } from "../NetscriptFunctions";
|
||||
import type { AutocompleteData, ScriptArg } from "@nsdefs";
|
||||
|
||||
// The object portion of this type is not runtime information, it's only to ensure type validation
|
||||
// And make it harder to overwrite a url with a random non-url string.
|
||||
export type ScriptURL = string & { __type: "ScriptURL" };
|
||||
|
||||
export interface ScriptModule {
|
||||
main?: (ns: NSFull) => unknown;
|
||||
main?: (ns: NSFull, ...args: ScriptArg[]) => unknown;
|
||||
autocomplete?: (data: AutocompleteData, flags: string[]) => unknown;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user