WIP: fix(webui): add steel path completion in completeAllMissions cheat #2288
@ -12,7 +12,8 @@ export const completeAllMissionsController: RequestHandler = async (req, res) =>
|
|||||||
const inventory = await getInventory(accountId);
|
const inventory = await getInventory(accountId);
|
||||||
const MissionRewards: IMissionReward[] = [];
|
const MissionRewards: IMissionReward[] = [];
|
||||||
for (const [tag, node] of Object.entries(ExportRegions)) {
|
for (const [tag, node] of Object.entries(ExportRegions)) {
|
||||||
if (!inventory.Missions.find(x => x.Tag == tag)) {
|
const mission = inventory.Missions.find(x => x.Tag === tag);
|
||||||
|
if (!mission) {
|
||||||
inventory.Missions.push({
|
inventory.Missions.push({
|
||||||
Completes: 1,
|
Completes: 1,
|
||||||
Tier: 1,
|
Tier: 1,
|
||||||
@ -20,9 +21,11 @@ export const completeAllMissionsController: RequestHandler = async (req, res) =>
|
|||||||
});
|
});
|
||||||
|
|
||||||
if (node.missionReward) {
|
if (node.missionReward) {
|
||||||
console.log(node.missionReward);
|
|
||||||
addFixedLevelRewards(node.missionReward, inventory, MissionRewards);
|
addFixedLevelRewards(node.missionReward, inventory, MissionRewards);
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
if (!mission.Tier) mission.Tier = 1;
|
||||||
|
if (!mission.Completes) mission.Completes = 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
for (const reward of MissionRewards) {
|
for (const reward of MissionRewards) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user