mirror of
https://github.com/sp-tarkov/modules.git
synced 2025-02-13 01:30:45 -05:00
Fixed client error when accessing inventory during raid start as PMC
This commit is contained in:
parent
694ce6ee0f
commit
35f82f50fa
@ -26,14 +26,16 @@ namespace SPT.Custom.Patches
|
|||||||
public static void PatchPreFix(ref IEnumerable<QuestDataClass> quests)
|
public static void PatchPreFix(ref IEnumerable<QuestDataClass> quests)
|
||||||
{
|
{
|
||||||
var gameWorld = Singleton<GameWorld>.Instance;
|
var gameWorld = Singleton<GameWorld>.Instance;
|
||||||
if (gameWorld != null)
|
if (gameWorld?.MainPlayer?.Location != "hideout"
|
||||||
|
&& gameWorld?.MainPlayer?.Fraction == ETagStatus.Scav)
|
||||||
{
|
{
|
||||||
if (gameWorld.MainPlayer?.Location != "hideout" && gameWorld.MainPlayer?.Fraction == ETagStatus.Scav)
|
var pmcQuests = PatchConstants.BackEndSession.Profile?.QuestsData;
|
||||||
|
var scavQuests = PatchConstants.BackEndSession.ProfileOfPet?.QuestsData;
|
||||||
|
if (pmcQuests != null && scavQuests != null)
|
||||||
{
|
{
|
||||||
var pmcQuests = PatchConstants.BackEndSession.Profile.QuestsData;
|
|
||||||
var scavQuests = PatchConstants.BackEndSession.ProfileOfPet.QuestsData;
|
|
||||||
quests = pmcQuests.Concat(scavQuests);
|
quests = pmcQuests.Concat(scavQuests);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user