mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2024-11-27 18:13:52 +01:00
fix bus busy bug
This commit is contained in:
parent
5f2efd94e5
commit
bdf3a53151
@ -77,13 +77,13 @@ export function NetscriptMyrian(): InternalAPI<IMyrian> {
|
|||||||
|
|
||||||
bus.busy = true;
|
bus.busy = true;
|
||||||
return helpers.netscriptDelay(ctx, moveSpeed(bus.moveLvl), true).then(() => {
|
return helpers.netscriptDelay(ctx, moveSpeed(bus.moveLvl), true).then(() => {
|
||||||
|
bus.busy = false;
|
||||||
if (findDevice([x, y])) {
|
if (findDevice([x, y])) {
|
||||||
helpers.log(ctx, () => `[${x}, ${y}] is occupied`);
|
helpers.log(ctx, () => `[${x}, ${y}] is occupied`);
|
||||||
return Promise.resolve(false);
|
return Promise.resolve(false);
|
||||||
}
|
}
|
||||||
bus.x = x;
|
bus.x = x;
|
||||||
bus.y = y;
|
bus.y = y;
|
||||||
bus.busy = false;
|
|
||||||
return Promise.resolve(true);
|
return Promise.resolve(true);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user