feat: handle EmailItems received during mission
All checks were successful
Build / build (22) (push) Successful in 36s
Build / build (18) (push) Successful in 1m3s
Build / build (20) (push) Successful in 53s
Build / build (18) (pull_request) Successful in 40s
Build / build (20) (pull_request) Successful in 1m1s
Build / build (22) (pull_request) Successful in 53s
All checks were successful
Build / build (22) (push) Successful in 36s
Build / build (18) (push) Successful in 1m3s
Build / build (20) (push) Successful in 53s
Build / build (18) (pull_request) Successful in 40s
Build / build (20) (pull_request) Successful in 1m1s
Build / build (22) (pull_request) Successful in 53s
This commit is contained in:
parent
97b61b51b7
commit
1341b71177
@ -1,4 +1,5 @@
|
|||||||
import {
|
import {
|
||||||
|
ExportEmailItems,
|
||||||
ExportFusionBundles,
|
ExportFusionBundles,
|
||||||
ExportRegions,
|
ExportRegions,
|
||||||
ExportRewards,
|
ExportRewards,
|
||||||
@ -27,7 +28,7 @@ import {
|
|||||||
import { updateQuestKey } from "@/src/services/questService";
|
import { updateQuestKey } from "@/src/services/questService";
|
||||||
import { HydratedDocument } from "mongoose";
|
import { HydratedDocument } from "mongoose";
|
||||||
import { IInventoryChanges } from "@/src/types/purchaseTypes";
|
import { IInventoryChanges } from "@/src/types/purchaseTypes";
|
||||||
import { getLevelKeyRewards, getNode } from "@/src/services/itemDataService";
|
import { convertInboxMessage, getLevelKeyRewards, getNode } from "@/src/services/itemDataService";
|
||||||
import { InventoryDocumentProps, TInventoryDatabaseDocument } from "@/src/models/inventoryModels/inventoryModel";
|
import { InventoryDocumentProps, TInventoryDatabaseDocument } from "@/src/models/inventoryModels/inventoryModel";
|
||||||
import { getEntriesUnsafe } from "@/src/utils/ts-utils";
|
import { getEntriesUnsafe } from "@/src/utils/ts-utils";
|
||||||
import { IEquipmentClient } from "@/src/types/inventoryTypes/commonInventoryTypes";
|
import { IEquipmentClient } from "@/src/types/inventoryTypes/commonInventoryTypes";
|
||||||
@ -156,6 +157,13 @@ export const addMissionInventoryUpdates = (
|
|||||||
inventoryChanges.FusionPoints = fusionPoints;
|
inventoryChanges.FusionPoints = fusionPoints;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
case "EmailItems": {
|
||||||
|
value.forEach(tc => {
|
||||||
|
const emailItem = ExportEmailItems[tc.ItemType];
|
||||||
|
void createMessage(inventory.accountOwnerId.toString(), [convertInboxMessage(emailItem.message)]);
|
||||||
|
});
|
||||||
|
break;
|
||||||
|
}
|
||||||
case "FocusXpIncreases": {
|
case "FocusXpIncreases": {
|
||||||
addFocusXpIncreases(inventory, value);
|
addFocusXpIncreases(inventory, value);
|
||||||
break;
|
break;
|
||||||
|
@ -46,6 +46,7 @@ export type IMissionInventoryUpdateRequest = {
|
|||||||
CrewShipRawSalvage?: ITypeCount[];
|
CrewShipRawSalvage?: ITypeCount[];
|
||||||
CrewShipAmmo?: ITypeCount[];
|
CrewShipAmmo?: ITypeCount[];
|
||||||
BonusMiscItems?: ITypeCount[];
|
BonusMiscItems?: ITypeCount[];
|
||||||
|
EmailItems?: ITypeCount[];
|
||||||
|
|
||||||
SyndicateId?: string;
|
SyndicateId?: string;
|
||||||
SortieId?: string;
|
SortieId?: string;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user