feat: implement awakening quest completion (/api/giveStartingGear) #977

Closed
neon wants to merge 3 commits from neon/SpaceNinjaServer:starting-gear into main
Showing only changes of commit 605905c880 - Show all commits

View File

@ -20,11 +20,6 @@ export const giveStartingGearController: RequestHandler = async (req, res) => {
const dataJSON = getJSONfromString<IStartingGearClient>(String(req.body));
await addKeyChainItems(inventory, {
KeyChain: "/Lotus/Types/Keys/VorsPrize/VorsPrizeQuestKeyChain",
ChainStage: 0
});
for (const key of Object.keys(dataJSON) as Array<keyof IStartingGearClient>) {
Review

this should not be here, the game handles trigger items itself.

this should not be here, the game handles trigger items itself.
Review

if youre talking about missionInventoryUpdate, then no. the awakening quest doesnt call that. this is why it needs to be done here.

if youre talking about missionInventoryUpdate, then no. the awakening quest doesnt call that. this is why it needs to be done here.
Review

if youre talking about missionInventoryUpdate, then no. the awakening quest doesnt call that. this is why it needs to be done here.

What mission inventory update?
I marked the line addKeychain Items, this is not meant to be done here.

> if youre talking about missionInventoryUpdate, then no. the awakening quest doesnt call that. this is why it needs to be done here. What mission inventory update? I marked the line addKeychain Items, this is not meant to be done here.
Review

Where else would u do it?

Where else would u do it?
Review

Not at all, because, as I said "the game handles trigger items itself."

Not at all, because, as I said "the game handles trigger items itself."
Review

try it without but it didnt work for me

try it without but it didnt work for me
switch (key) {
// This is the only gear we receive as the rest will come from future quests
@ -49,6 +44,11 @@ export const giveStartingGearController: RequestHandler = async (req, res) => {
}
}
await addKeyChainItems(inventory, {
KeyChain: "/Lotus/Types/Keys/VorsPrize/VorsPrizeQuestKeyChain",
ChainStage: 0
});
addConsumables(inventory, [{ ItemCount: 1, ItemType: "/Lotus/Types/Restoratives/LisetAutoHack" }]);
if (!config.unlockAllFlavourItems) {
inventory.FlavourItems.push([