show PerDifficultyAward in course modes

This commit is contained in:
Chris Danford
2005-04-06 06:12:23 +00:00
parent ea34de2bef
commit ed0959ec32
2 changed files with 184 additions and 189 deletions
+1 -8
View File
@@ -874,7 +874,6 @@ void ScreenEvaluation::CommitScores(
PerDifficultyAward pdaToShowOut[NUM_PLAYERS], PerDifficultyAward pdaToShowOut[NUM_PLAYERS],
PeakComboAward pcaToShowOut[NUM_PLAYERS] ) PeakComboAward pcaToShowOut[NUM_PLAYERS] )
{ {
{
FOREACH_PlayerNumber( pn ) FOREACH_PlayerNumber( pn )
{ {
iPersonalHighScoreIndexOut[pn] = -1; iPersonalHighScoreIndexOut[pn] = -1;
@@ -883,7 +882,6 @@ void ScreenEvaluation::CommitScores(
pdaToShowOut[pn] = PER_DIFFICULTY_AWARD_INVALID; pdaToShowOut[pn] = PER_DIFFICULTY_AWARD_INVALID;
pcaToShowOut[pn] = PEAK_COMBO_AWARD_INVALID; pcaToShowOut[pn] = PEAK_COMBO_AWARD_INVALID;
} }
}
switch( GAMESTATE->m_PlayMode ) switch( GAMESTATE->m_PlayMode )
{ {
@@ -907,7 +905,6 @@ void ScreenEvaluation::CommitScores(
LOG->Trace( "saving stats and high scores" ); LOG->Trace( "saving stats and high scores" );
{
FOREACH_HumanPlayer( p ) FOREACH_HumanPlayer( p )
{ {
// don't save scores if the player is disqualified // don't save scores if the player is disqualified
@@ -981,14 +978,12 @@ void ScreenEvaluation::CommitScores(
ASSERT(0); ASSERT(0);
} }
} }
}
LOG->Trace( "done saving stats and high scores" ); LOG->Trace( "done saving stats and high scores" );
// If both players get a machine high score in the same HighScoreList, // If both players get a machine high score in the same HighScoreList,
// then one player's score may have bumped the other player. Look in // then one player's score may have bumped the other player. Look in
// the HighScoreList and re-get the high score index. // the HighScoreList and re-get the high score index.
{
FOREACH_HumanPlayer( p ) FOREACH_HumanPlayer( p )
{ {
if( iMachineHighScoreIndexOut[p] == -1 ) // no record if( iMachineHighScoreIndexOut[p] == -1 ) // no record
@@ -1032,12 +1027,10 @@ void ScreenEvaluation::CommitScores(
else else
iMachineHighScoreIndexOut[p] = iter - pHSL->vHighScores.begin(); iMachineHighScoreIndexOut[p] = iter - pHSL->vHighScores.begin();
} }
}
LOG->Trace( "hand out awards" ); LOG->Trace( "hand out awards" );
{
FOREACH_HumanPlayer( p ) FOREACH_HumanPlayer( p )
{ {
deque<PerDifficultyAward> &vPdas = GAMESTATE->m_vLastPerDifficultyAwards[p]; deque<PerDifficultyAward> &vPdas = GAMESTATE->m_vLastPerDifficultyAwards[p];
@@ -1048,6 +1041,7 @@ void ScreenEvaluation::CommitScores(
switch( m_Type ) switch( m_Type )
{ {
case stage: case stage:
case course:
// don't give per-difficutly awards if using easy mods // don't give per-difficutly awards if using easy mods
if( !GAMESTATE->IsDisqualified(p) ) if( !GAMESTATE->IsDisqualified(p) )
{ {
@@ -1106,7 +1100,6 @@ void ScreenEvaluation::CommitScores(
LOG->Trace( "done with per combo awards" ); LOG->Trace( "done with per combo awards" );
} }
}
LOG->Trace( "done handing out awards." ); LOG->Trace( "done handing out awards." );
} }
+3 -1
View File
@@ -769,7 +769,7 @@ bool ScreenGameplay::IsLastSong()
{ {
if( GAMESTATE->m_pCurCourse && GAMESTATE->m_pCurCourse->m_bRepeat ) if( GAMESTATE->m_pCurCourse && GAMESTATE->m_pCurCourse->m_bRepeat )
return false; return false;
return GAMESTATE->GetCourseSongIndex()+1 == (int)m_apSongsQueue.size(); // GetCourseSongIndex() is 0-based but size() is not return GAMESTATE->GetCourseSongIndex() >= (int)m_apSongsQueue.size()-1; // GetCourseSongIndex() is 0-based
} }
void ScreenGameplay::SetupSong( PlayerNumber p, int iSongIndex ) void ScreenGameplay::SetupSong( PlayerNumber p, int iSongIndex )
@@ -2135,6 +2135,7 @@ void ScreenGameplay::HandleScreenMessage( const ScreenMessage SM )
// update dancing characters for win / lose // update dancing characters for win / lose
DancingCharacters *Dancers = m_SongBackground.GetDancingCharacters(); DancingCharacters *Dancers = m_SongBackground.GetDancingCharacters();
if( Dancers ) if( Dancers )
{
FOREACH_EnabledPlayer(p) FOREACH_EnabledPlayer(p)
{ {
/* XXX: In battle modes, switch( GAMESTATE->GetStageResult(p) ). */ /* XXX: In battle modes, switch( GAMESTATE->GetStageResult(p) ). */
@@ -2145,6 +2146,7 @@ void ScreenGameplay::HandleScreenMessage( const ScreenMessage SM )
else else
Dancers->Change2DAnimState( p, AS2D_WIN ); // pass anim Dancers->Change2DAnimState( p, AS2D_WIN ); // pass anim
} }
}
/* End round. */ /* End round. */
if( m_DancingState == STATE_OUTRO ) // ScreenGameplay already ended if( m_DancingState == STATE_OUTRO ) // ScreenGameplay already ended