retrieve time in fillSummary.

This commit is contained in:
Christoph Oelckers 2023-10-01 11:59:35 +02:00
parent 4dcf0fd3c4
commit ee07ae35aa
12 changed files with 20 additions and 25 deletions

View file

@ -41,6 +41,7 @@
#include "gamecontrol.h"
#include "raze_sound.h"
#include "zstring.h"
#include "statistics.h"
FString gSkillNames[MAXSKILLS];
int gDefaultVolume = 0, gDefaultSkill = 1;
@ -263,3 +264,14 @@ MapRecord* SetupUserMap(const char* boardfilename, const char *defaultmusic)
else map->music = defaultmusic;
return map;
}
void MapLocals::fillSummary(SummaryInfo& sum)
{
sum.kills = kills.got;
sum.maxkills = kills.max;
sum.secrets = secrets.got;
sum.maxsecrets = std::max(secrets.got, secrets.max); // If we found more than there are, increase the total. Blood's secret maintenance is too broken to get right.
sum.supersecrets = superSecrets.got;
sum.time = PlayClock;
// todo: centralize the remaining info as well.
}