mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2026-04-22 17:23:00 +02:00
API: Add ns.renderTail (#1815)
This commit is contained in:
@@ -566,6 +566,17 @@ export const ns: InternalAPI<NSFull> = {
|
||||
|
||||
LogBoxEvents.emit(runningScriptObj);
|
||||
},
|
||||
renderTail:
|
||||
(ctx) =>
|
||||
(_pid = ctx.workerScript.scriptRef.pid) => {
|
||||
const pid = helpers.number(ctx, "pid", _pid);
|
||||
const runningScriptObj = helpers.getRunningScript(ctx, pid);
|
||||
if (runningScriptObj == null) {
|
||||
helpers.log(ctx, () => helpers.getCannotFindRunningScriptErrorMessage(pid));
|
||||
return;
|
||||
}
|
||||
runningScriptObj.tailProps?.rerender();
|
||||
},
|
||||
moveTail:
|
||||
(ctx) =>
|
||||
(_x, _y, _pid = ctx.workerScript.scriptRef.pid) => {
|
||||
|
||||
Reference in New Issue
Block a user