diff --git a/stepmania/src/ScreenEz2SelectMusic.cpp b/stepmania/src/ScreenEz2SelectMusic.cpp index 974ac12762..1e9c1c29bf 100644 --- a/stepmania/src/ScreenEz2SelectMusic.cpp +++ b/stepmania/src/ScreenEz2SelectMusic.cpp @@ -476,25 +476,25 @@ void ScreenEz2SelectMusic::MusicChanged() SortNotesArrayByDifficulty( m_arrayNotes[pn] ); } - for( int p=0; pIsPlayerEnabled( PlayerNumber(p) ) ) + if( !GAMESTATE->IsPlayerEnabled( PlayerNumber(pn) ) ) continue; - for( unsigned i=0; iGetDifficulty() == GAMESTATE->m_PreferredDifficulty[p] ) + if( m_arrayNotes[pn][i]->GetDifficulty() == GAMESTATE->m_PreferredDifficulty[pn] ) { - m_iSelection[p] = i; + m_iSelection[pn] = i; break; } } - m_iSelection[p] = clamp( m_iSelection[p], 0, int(m_arrayNotes[p].size()) ) ; + m_iSelection[pn] = clamp( m_iSelection[pn], 0, int(m_arrayNotes[pn].size()) ) ; } - for( p=0; p