Merge branch 'main' into data-driven

This commit is contained in:
tresabhi committed 2026-09-27 13:11:01 -05:00
commit d8f6a55ee4
2 files changed
+19 -13

No files matched your search

@@ -90,15 +90,21 @@ function Content() {
session.tracking && tankStatsB
? deltaTankStats(session.player.stats, tankStatsB)
.sort((a, b) => b.last_battle_time - a.last_battle_time)
.map((entry) => {
.flatMap((entry) => {
if (!(entry.tank_id in tankDefinitions.tanks)) return [];
const tank = tankDefinitions.tanks[entry.tank_id];
if (!(tank.id in averageDefinitions.averages)) return [];
const average = averageDefinitions.averages[tank.id];
const composite = compositeStats(
{ ...entry.all, battle_life_time: entry.battle_life_time },
average?.mu!,
average.mu!,
);
return { tank, composite };
return [{ tank, composite }];
})
: undefined,
[session.tracking && session.player, tankStatsB],