Revert "API: Add types for parameters of gym-university-bladeburner API (#1591)" (#1592)

This reverts commit da8870ed79.
This commit is contained in:
David Walker
2024-08-16 13:45:54 -07:00
committed by GitHub
parent da8870ed79
commit 79bb0d289a
65 changed files with 468 additions and 1044 deletions
+6 -6
View File
@@ -5,8 +5,8 @@ import { MenuItem, Select, SelectChangeEvent } from "@mui/material";
import { Player } from "@player";
import {
BladeburnerActionType,
BladeburnerContractName,
BladeActionType,
BladeContractName,
CityName,
FactionName,
FactionWorkType,
@@ -96,19 +96,19 @@ function possibleFactions(sleeve: Sleeve): string[] {
});
}
function possibleContracts(sleeve: Sleeve): BladeburnerContractName[] | ["------"] {
function possibleContracts(sleeve: Sleeve): BladeContractName[] | ["------"] {
const bb = Player.bladeburner;
if (bb === null) {
return ["------"];
}
let contracts = Object.values(BladeburnerContractName);
let contracts = Object.values(BladeContractName);
for (const otherSleeve of Player.sleeves) {
if (sleeve === otherSleeve) {
continue;
}
if (
otherSleeve.currentWork?.type === SleeveWorkType.BLADEBURNER &&
otherSleeve.currentWork.actionId.type === BladeburnerActionType.Contract
otherSleeve.currentWork.actionId.type === BladeActionType.contract
) {
const w = otherSleeve.currentWork;
contracts = contracts.filter((x) => x != w.actionId.name);
@@ -262,7 +262,7 @@ function getABC(sleeve: Sleeve): [string, string, string] {
return ["Work for Faction", work.factionName, workNames[work.factionWorkType] ?? ""];
}
case SleeveWorkType.BLADEBURNER:
if (work.actionId.type === BladeburnerActionType.Contract) {
if (work.actionId.type === BladeActionType.contract) {
return ["Perform Bladeburner Actions", "Take on contracts", work.actionId.name];
}
return ["Perform Bladeburner Actions", work.actionId.name, "------"];