mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2024-12-24 07:02:26 +01:00
added getScriptName
This commit is contained in:
parent
8dba456b65
commit
60cc6e15d5
@ -779,6 +779,12 @@ scriptKill
|
||||
Kills all scripts with the specified filename on the target server specified by *hostname/ip*, regardless of arguments. Returns
|
||||
true if one or more scripts were successfully killed, and false if none were.
|
||||
|
||||
getScriptName
|
||||
^^^^^^^^^^^^^
|
||||
|
||||
.. js:function:: getScriptName()
|
||||
Returns the current script name
|
||||
|
||||
getScriptRam
|
||||
^^^^^^^^^^^^
|
||||
|
||||
|
@ -1994,6 +1994,10 @@ function NetscriptFunctions(workerScript) {
|
||||
}
|
||||
return suc;
|
||||
},
|
||||
getScriptName : function() {
|
||||
if (workerScript.checkingRam) {return 0;}
|
||||
return workerScript.name;
|
||||
},
|
||||
getScriptRam : function (scriptname, ip) {
|
||||
if (workerScript.checkingRam) {
|
||||
if (workerScript.loadedFns.getScriptRam) {
|
||||
|
Loading…
Reference in New Issue
Block a user