Make scav regenerate later after death to not persist old data, causing stale kills to appear on death.
This commit is contained in:
parent
eac3c7e226
commit
026ff4d929
@ -382,14 +382,9 @@ export class LocationLifecycleService {
|
|||||||
isDead: boolean,
|
isDead: boolean,
|
||||||
request: IEndLocalRaidRequestData,
|
request: IEndLocalRaidRequestData,
|
||||||
): void {
|
): void {
|
||||||
// Scav died, regen scav loadout and reset timer
|
|
||||||
if (isDead) {
|
|
||||||
this.playerScavGenerator.generate(sessionId);
|
|
||||||
}
|
|
||||||
|
|
||||||
scavProfile.Info.Level = request.results.profile.Info.Level;
|
scavProfile.Info.Level = request.results.profile.Info.Level;
|
||||||
scavProfile.Skills = request.results.profile.Skills;
|
scavProfile.Skills = request.results.profile.Skills;
|
||||||
scavProfile.Stats.Eft = request.results.profile.Stats.Eft;
|
scavProfile.Stats = request.results.profile.Stats;
|
||||||
scavProfile.Encyclopedia = request.results.profile.Encyclopedia;
|
scavProfile.Encyclopedia = request.results.profile.Encyclopedia;
|
||||||
scavProfile.TaskConditionCounters = request.results.profile.TaskConditionCounters;
|
scavProfile.TaskConditionCounters = request.results.profile.TaskConditionCounters;
|
||||||
scavProfile.SurvivorClass = request.results.profile.SurvivorClass;
|
scavProfile.SurvivorClass = request.results.profile.SurvivorClass;
|
||||||
@ -418,6 +413,11 @@ export class LocationLifecycleService {
|
|||||||
// Remove skill fatigue values
|
// Remove skill fatigue values
|
||||||
this.resetSkillPointsEarnedDuringRaid(scavProfile.Skills.Common);
|
this.resetSkillPointsEarnedDuringRaid(scavProfile.Skills.Common);
|
||||||
|
|
||||||
|
// Scav died, regen scav loadout and reset timer
|
||||||
|
if (isDead) {
|
||||||
|
this.playerScavGenerator.generate(sessionId);
|
||||||
|
}
|
||||||
|
|
||||||
// Update last played property
|
// Update last played property
|
||||||
pmcProfile.Info.LastTimePlayedAsSavage = this.timeUtil.getTimestamp();
|
pmcProfile.Info.LastTimePlayedAsSavage = this.timeUtil.getTimestamp();
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user