From 3375b9cb4b34995d99c41aaecbb91b70fcda45b5 Mon Sep 17 00:00:00 2001 From: nrbdev Date: Thu, 20 Feb 2025 12:18:32 -0500 Subject: [PATCH] chore: use giveKeyChainMessage to send messages --- src/services/inventoryService.ts | 48 +++++++------------------------- 1 file changed, 10 insertions(+), 38 deletions(-) diff --git a/src/services/inventoryService.ts b/src/services/inventoryService.ts index cd793afd2..6b26641c9 100644 --- a/src/services/inventoryService.ts +++ b/src/services/inventoryService.ts @@ -47,11 +47,11 @@ import { ExportWeapons, TStandingLimitBin } from "warframe-public-export-plus"; -import { createMessage } from "./inboxService"; import { createShip } from "./shipService"; import { creditBundles, fusionBundles } from "@/src/services/missionInventoryUpdateService"; import { IKeyChainRequest } from "@/src/controllers/api/giveKeyChainTriggeredItemsController"; import { toOid } from "../helpers/inventoryHelpers"; +import { giveKeyChainMessage } from "./questService"; export const createInventory = async ( accountOwnerId: Types.ObjectId, @@ -81,43 +81,15 @@ export const createInventory = async ( ]; // Give Darvo items that would be given after completing vors prize - await createMessage(String(accountOwnerId), [ - { - sub: "/Lotus/Language/G1Quests/Beginner_Growth_Inbox_Title", - sndr: "/Lotus/Language/Menu/Mailbox_WarframeSender", - msg: "/Lotus/Language/G1Quests/Beginner_Growth_Inbox_Desc", - icon: "/Lotus/Interface/Icons/Npcs/Lotus_d.png", - transmission: "/Lotus/Sounds/Dialog/VorsPrize/DLisetPostAssassinate110Lotus", - highPriority: true, - r: false - }, - { - sub: "/Lotus/Language/Inbox/DarvoWeaponCraftingMessageBTitle", - sndr: "/Lotus/Language/Bosses/Darvo", - msg: "/Lotus/Language/Inbox/DarvoWeaponCraftingMessageBDesc", - icon: "/Lotus/Interface/Icons/Npcs/Darvo.png", - countedAtt: [ - { - ItemCount: 1, - ItemType: "/Lotus/Types/Recipes/Weapons/BurstonRifleBlueprint" - }, - { - ItemCount: 1, - ItemType: "/Lotus/Types/Items/MiscItems/Morphic" - }, - { - ItemCount: 400, - ItemType: "/Lotus/Types/Items/MiscItems/PolymerBundle" - }, - { - ItemCount: 150, - ItemType: "/Lotus/Types/Items/MiscItems/AlloyPlate" - } - ], - highPriority: true, - r: false - } - ]); + await giveKeyChainMessage(inventory, String(accountOwnerId), { + KeyChain: "/Lotus/Types/Keys/VorsPrize/VorsPrizeQuestKeyChain", + ChainStage: 7 /* a.k.a { "title": "/Lotus/Language/G1Quests/Beginner_Growth_Inbox_Title", "body": "/Lotus/Language/G1Quests/Beginner_Growth_Inbox_Desc" } */ + }); + + await giveKeyChainMessage(inventory, String(accountOwnerId), { + KeyChain: "/Lotus/Types/Keys/VorsPrize/VorsPrizeQuestKeyChain", + ChainStage: 6 /* a.k.a { "title": "/Lotus/Language/Inbox/DarvoWeaponCraftingMessageBTitle", "body": "/Lotus/Language/Inbox/DarvoWeaponCraftingMessageBDesc" } */ + }); // const vorsPrizeRewards = [ // // Vor's Prize rewards