CORPORATION: improve State description (#778)

This commit is contained in:
Caldwell 2023-09-12 07:25:51 +02:00 committed by GitHub
parent bba2ccd83a
commit 624a0a5b02
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 17 additions and 9 deletions

@ -30,6 +30,6 @@ interface CorporationInfo
| [revenue](./bitburner.corporationinfo.revenue.md) | | number | Revenue per second this cycle |
| [sharePrice](./bitburner.corporationinfo.shareprice.md) | | number | Price of the shares |
| [shareSaleCooldown](./bitburner.corporationinfo.sharesalecooldown.md) | | number | Cooldown until shares can be sold again |
| [state](./bitburner.corporationinfo.state.md) | | string | State of the corporation. Possible states are START, PURCHASE, PRODUCTION, EXPORT, SALE. |
| [state](./bitburner.corporationinfo.state.md) | | string | <p>The next state to be processed.</p><p>I.e. when the state is PURCHASE, it means purchasing will occur during the next state transition.</p><p>Possible states are START, PURCHASE, PRODUCTION, EXPORT, SALE.</p> |
| [totalShares](./bitburner.corporationinfo.totalshares.md) | | number | Total number of shares issues by this corporation |

@ -4,7 +4,11 @@
## CorporationInfo.state property
State of the corporation. Possible states are START, PURCHASE, PRODUCTION, EXPORT, SALE.
The next state to be processed.
I.e. when the state is PURCHASE, it means purchasing will occur during the next state transition.
Possible states are START, PURCHASE, PRODUCTION, EXPORT, SALE.
**Signature:**

@ -58,23 +58,23 @@ function WarehouseRoot(props: WarehouseProps): React.ReactElement {
props.rerender();
}
// Current State:
// Next state which will be processed:
let stateText;
switch (division.state) {
case "START":
stateText = "Current state: Preparing...";
stateText = "Next state: Preparing";
break;
case "PURCHASE":
stateText = "Current state: Purchasing materials...";
stateText = "Next state: Purchasing materials";
break;
case "PRODUCTION":
stateText = "Current state: Producing materials and/or products...";
stateText = "Next state: Producing materials and/or products";
break;
case "SALE":
stateText = "Current state: Selling materials and/or products...";
stateText = "Next state: Selling materials and/or products";
break;
case "EXPORT":
stateText = "Current state: Exporting materials and/or products...";
stateText = "Next state: Exporting materials and/or products";
break;
default:
console.error(`Invalid state: ${division.state}`);

@ -7531,7 +7531,11 @@ interface CorporationInfo {
dividendTax: number;
/** Your earnings as a shareholder per second this cycle */
dividendEarnings: number;
/** State of the corporation. Possible states are START, PURCHASE, PRODUCTION, EXPORT, SALE. */
/** The next state to be processed.
*
* I.e. when the state is PURCHASE, it means purchasing will occur during the next state transition.
*
* Possible states are START, PURCHASE, PRODUCTION, EXPORT, SALE. */
state: string;
/** Array of all division names */
divisions: string[];