debugging

This commit is contained in:
Glenn Maynard
2004-04-25 23:22:46 +00:00
parent 08c00bd689
commit b0ca9ef1ea
3 changed files with 9 additions and 2 deletions
+3 -1
View File
@@ -115,17 +115,19 @@ void HighScoreList::AddHighScore( HighScore hs, int &iIndexOut )
vHighScores.erase( vHighScores.begin()+iMaxScores, vHighScores.end() );
}
}
#include "RageLog.h"
const HighScore& HighScoreList::GetTopScore() const
{
if( vHighScores.empty() )
{
LOG->Trace("empty");
static HighScore hs;
hs = HighScore();
return hs;
}
else
{
LOG->Trace("not empty");
return vHighScores[0];
}
}
+3 -1
View File
@@ -330,9 +330,11 @@ HighScoreList& Profile::GetStepsHighScoreList( const Song* pSong, const Steps* p
StepsID stepsID;
stepsID.FromSteps( pSteps );
CHECKPOINT;
HighScoresForASong &hsSong = m_SongHighScores[songID]; // operator[] inserts into map
CHECKPOINT;
HighScoresForASteps &hsSteps = hsSong.m_StepsHighScores[stepsID]; // operator[] inserts into map
CHECKPOINT;
return hsSteps.hs;
}
+3
View File
@@ -1283,9 +1283,12 @@ int Song::GetNumNotesWithGrade( Grade g ) const
{
Steps* pSteps = vNotes[j];
CHECKPOINT;
if( PROFILEMAN->GetMachineProfile()->GetStepsHighScoreList(this,pSteps).GetTopScore().grade == g )
iCount++;
CHECKPOINT;
}
CHECKPOINT;
return iCount;
}