mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2024-12-27 16:37:33 +01:00
Adds dev options to set server cash to zero.
This commit is contained in:
parent
ea0be338e1
commit
7baacf4e1b
@ -71,6 +71,20 @@ export function Servers(): React.ReactElement {
|
||||
}
|
||||
}
|
||||
|
||||
function minMoney(): void {
|
||||
const s = GetServer(server);
|
||||
if (s === null) return;
|
||||
if (!(s instanceof Server)) return;
|
||||
s.moneyAvailable = 0;
|
||||
}
|
||||
|
||||
function minAllMoney(): void {
|
||||
for (const s of GetAllServers()) {
|
||||
if (!(s instanceof Server)) return;
|
||||
s.moneyAvailable = 0;
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
<Accordion TransitionProps={{ unmountOnExit: true }}>
|
||||
<AccordionSummary expandIcon={<ExpandMoreIcon />}>
|
||||
@ -119,6 +133,12 @@ export function Servers(): React.ReactElement {
|
||||
<td>
|
||||
<Typography>Money:</Typography>
|
||||
</td>
|
||||
<td>
|
||||
<Button onClick={minMoney}>Min one</Button>
|
||||
</td>
|
||||
<td>
|
||||
<Button onClick={minAllMoney}>Min all</Button>
|
||||
</td>
|
||||
<td>
|
||||
<Button onClick={maxMoney}>Max one</Button>
|
||||
</td>
|
||||
|
Loading…
Reference in New Issue
Block a user