mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2024-12-20 05:05:47 +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
|
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.
|
true if one or more scripts were successfully killed, and false if none were.
|
||||||
|
|
||||||
|
getScriptName
|
||||||
|
^^^^^^^^^^^^^
|
||||||
|
|
||||||
|
.. js:function:: getScriptName()
|
||||||
|
Returns the current script name
|
||||||
|
|
||||||
getScriptRam
|
getScriptRam
|
||||||
^^^^^^^^^^^^
|
^^^^^^^^^^^^
|
||||||
|
|
||||||
|
@ -1994,6 +1994,10 @@ function NetscriptFunctions(workerScript) {
|
|||||||
}
|
}
|
||||||
return suc;
|
return suc;
|
||||||
},
|
},
|
||||||
|
getScriptName : function() {
|
||||||
|
if (workerScript.checkingRam) {return 0;}
|
||||||
|
return workerScript.name;
|
||||||
|
},
|
||||||
getScriptRam : function (scriptname, ip) {
|
getScriptRam : function (scriptname, ip) {
|
||||||
if (workerScript.checkingRam) {
|
if (workerScript.checkingRam) {
|
||||||
if (workerScript.loadedFns.getScriptRam) {
|
if (workerScript.loadedFns.getScriptRam) {
|
||||||
|
Loading…
Reference in New Issue
Block a user