返回提交历史
Modified
src/controllers/api/inventoryController.ts
+9
-3
Deleted
static/fixed_responses/allMissions.json
+0
-1542
XFEstudio/XFESpaceNinjaServer
fix: automatically populate regions for unlockAllMissions (#587)
b0b2d9f6
代码差异
2 个文件
+9
-1545
@@ -4,11 +4,10 @@ import { toInventoryResponse } from "@/src/helpers/inventoryHelpers";
4
4
import { Inventory } from "@/src/models/inventoryModels/inventoryModel";
5
5
import { config } from "@/src/services/configService";
6
6
import allDialogue from "@/static/fixed_responses/allDialogue.json";
7
import allMissions from "@/static/fixed_responses/allMissions.json";
8
7
import { ILoadoutDatabase } from "@/src/types/saveLoadoutTypes";
9
8
import { IShipInventory, equipmentKeys } from "@/src/types/inventoryTypes/inventoryTypes";
10
9
import { IPolarity, ArtifactPolarity } from "@/src/types/inventoryTypes/commonInventoryTypes";
11
import { ExportCustoms, ExportFlavour, ExportKeys, ExportResources } from "warframe-public-export-plus";
10
import { ExportCustoms, ExportFlavour, ExportKeys, ExportRegions, ExportResources } from "warframe-public-export-plus";
12
11
13
12
// eslint-disable-next-line @typescript-eslint/no-misused-promises
14
13
const inventoryController: RequestHandler = async (request, response) => {
@@ -54,7 +53,14 @@ const inventoryController: RequestHandler = async (request, response) => {
54
53
}
55
54
56
55
if (config.unlockAllMissions) {
57
inventoryResponse.Missions = allMissions;
56
inventoryResponse.Missions = [];
57
for (const tag of Object.keys(ExportRegions)) {
58
inventoryResponse.Missions.push({
59
Completes: 1,
60
Tier: 1,
61
Tag: tag
62
});
63
}
58
64
addString(inventoryResponse.NodeIntrosCompleted, "TeshinHardModeUnlocked");
59
65
}
60
66