0
0
mirror of https://github.com/sp-tarkov/server.git synced 2025-02-13 09:50:43 -05:00

Resolve issue where most bonuses are cleared on wall completion (!412)

- Resolves issue where the player stash template ends up being reset to base, resulting in an incorrect stash size calculation

Co-authored-by: DrakiaXYZ <565558+TheDgtl@users.noreply.github.com>
Reviewed-on: SPT/Server#412
Co-authored-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
Co-committed-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
This commit is contained in:
DrakiaXYZ 2024-09-21 08:56:04 +00:00 committed by chomp
parent 71711f0c0d
commit 5217f7caed

View File

@ -231,11 +231,10 @@ export class HideoutController {
} }
// Cleanup temporary fuel usage buffs from mopping floor if wall is complete as it would result in too many bonuses // Cleanup temporary fuel usage buffs from mopping floor if wall is complete as it would result in too many bonuses
// TODO: Clean up all buffs from mopping floor.
if (profileHideoutArea.type === HideoutAreas.EMERGENCY_WALL && profileHideoutArea.level === 6) { if (profileHideoutArea.type === HideoutAreas.EMERGENCY_WALL && profileHideoutArea.level === 6) {
// Get everything except specific fuel consumption buffs // Get everything except specific fuel consumption buffs
pmcData.Bonuses = pmcData.Bonuses.filter( pmcData.Bonuses = pmcData.Bonuses.filter(
(bonus) => bonus.type !== BonusType.FUEL_CONSUMPTION && bonus.value >= -10 && bonus.value <= 0, (bonus) => bonus.type !== BonusType.FUEL_CONSUMPTION || (bonus.value >= -10 && bonus.value <= 0),
); );
} }