clean up presisting of settings to Profile

persist PreferredCourseDifficulty
This commit is contained in:
Chris Danford
2004-03-13 22:18:09 +00:00
parent 22a82cad8e
commit 7a32af8c5e
15 changed files with 62 additions and 90 deletions
+3 -3
View File
@@ -86,7 +86,7 @@ bool ModeChoice::DescribesCurrentMode( PlayerNumber pn ) const
return false;
if( m_pCharacter && GAMESTATE->m_pCurCharacters[pn] != m_pCharacter )
return false;
if( m_CourseDifficulty != COURSE_DIFFICULTY_INVALID && GAMESTATE->m_CourseDifficulty[pn] != m_CourseDifficulty )
if( m_CourseDifficulty != COURSE_DIFFICULTY_INVALID && GAMESTATE->m_PreferredCourseDifficulty[pn] != m_CourseDifficulty )
return false;
return true;
@@ -322,10 +322,10 @@ void ModeChoice::Apply( PlayerNumber pn ) const
GAMESTATE->m_pCurCharacters[pn] = m_pCharacter;
if( m_CourseDifficulty != COURSE_DIFFICULTY_INVALID )
{
GAMESTATE->m_CourseDifficulty[pn] = m_CourseDifficulty;
GAMESTATE->m_PreferredCourseDifficulty[pn] = m_CourseDifficulty;
if( PREFSMAN->m_bLockCourseDifficulties )
for( int p = 0; p < NUM_PLAYERS; ++p )
GAMESTATE->m_CourseDifficulty[p] = GAMESTATE->m_CourseDifficulty[pn];
GAMESTATE->m_PreferredCourseDifficulty[p] = GAMESTATE->m_PreferredCourseDifficulty[pn];
}
// HACK: Set life type to BATTERY just once here so it happens once and