0
0
mirror of https://github.com/sp-tarkov/server.git synced 2025-02-12 16:10:43 -05:00

Formatting changes

This commit is contained in:
Chomp 2024-11-24 18:33:23 +00:00
parent effcc37e68
commit 967330132f

View File

@ -639,8 +639,8 @@ export class LocationLifecycleService {
const postRaidProfile = request.results.profile;
const preRaidProfileQuestDataClone = this.cloner.clone(pmcProfile.Quests);
// MUST occur BEFORE inventory actions occur
// Player died, quest items presist in the post raid profile
// MUST occur BEFORE inventory actions (setInventory()) occur
// Player died, get quest items they lost for use later
const lostQuestItems = this.profileHelper.getQuestItemsInProfile(postRaidProfile);
// Update inventory
@ -655,12 +655,6 @@ export class LocationLifecycleService {
pmcProfile.Achievements = postRaidProfile.Achievements;
pmcProfile.Quests = this.processPostRaidQuests(postRaidProfile.Quests);
if (isDead && lostQuestItems.length > 0) {
// MUST occur AFTER quests have post raid quest data has been merged
// Player is dead + had quest items, check and fix any broken find item quests
this.checkForAndFixPickupQuestsAfterDeath(sessionId, lostQuestItems, pmcProfile.Quests);
}
// Handle edge case - must occur AFTER processPostRaidQuests()
this.lightkeeperQuestWorkaround(sessionId, postRaidProfile.Quests, preRaidProfileQuestDataClone, pmcProfile);
@ -692,6 +686,12 @@ export class LocationLifecycleService {
this.healthHelper.updateProfileHealthPostRaid(pmcProfile, postRaidProfile.Health, sessionId, isDead);
if (isDead) {
if (lostQuestItems.length > 0) {
// MUST occur AFTER quests have post raid quest data has been merged "processPostRaidQuests()"
// Player is dead + had quest items, check and fix any broken find item quests
this.checkForAndFixPickupQuestsAfterDeath(sessionId, lostQuestItems, pmcProfile.Quests);
}
this.pmcChatResponseService.sendKillerResponse(sessionId, pmcProfile, postRaidProfile.Stats.Eft.Aggressor);
this.inRaidHelper.deleteInventory(pmcProfile, sessionId);