mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-11-28 15:02:01 +00:00
- fixed: The current level's statistics should not be updated when not actually playing.
- added a STAT display for the game statistics info. SVN r2833 (trunk)
This commit is contained in:
parent
9a8a446840
commit
7dcf9b4738
1 changed files with 8 additions and 1 deletions
|
@ -400,6 +400,8 @@ static void StoreLevelStats()
|
|||
{
|
||||
unsigned int i;
|
||||
|
||||
if (gamestate != GS_LEVEL) return;
|
||||
|
||||
if (!(level.flags2&LEVEL2_NOSTATISTICS)) // don't consider maps that were excluded from statistics
|
||||
{
|
||||
for(i=0;i<LevelData.Size();i++)
|
||||
|
@ -592,7 +594,7 @@ FString GetStatString()
|
|||
|
||||
CCMD(printstats)
|
||||
{
|
||||
StoreLevelStats(); // Get the current level's current results.
|
||||
StoreLevelStats(); // Refresh the current level's results.
|
||||
Printf("%s", GetStatString());
|
||||
}
|
||||
|
||||
|
@ -604,3 +606,8 @@ CCMD(finishgame)
|
|||
G_ExitLevel (0, false);
|
||||
}
|
||||
|
||||
ADD_STAT(statistics)
|
||||
{
|
||||
StoreLevelStats(); // Refresh the current level's results.
|
||||
return GetStatString();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue