rerearrange

This commit is contained in:
Glenn Maynard
2004-06-04 01:17:46 +00:00
parent 33a16651d6
commit 5676372659
+26 -26
View File
@@ -98,6 +98,26 @@ void DifficultyMeter::Load()
Unset();
}
void DifficultyMeter::SetFromGameState( PlayerNumber pn )
{
if( GAMESTATE->IsCourseMode() )
{
const Trail* pTrail = GAMESTATE->m_pCurTrail[pn];
if( pTrail )
SetFromTrail( pTrail );
else
SetFromCourseDifficulty( GAMESTATE->m_PreferredCourseDifficulty[pn] );
}
else
{
const Steps* pSteps = GAMESTATE->m_pCurSteps[pn];
if( pSteps )
SetFromSteps( pSteps );
else
SetFromDifficulty( GAMESTATE->m_PreferredDifficulty[pn] );
}
}
void DifficultyMeter::SetFromSteps( const Steps* pSteps )
{
if( pSteps == NULL )
@@ -149,24 +169,13 @@ void DifficultyMeter::SetFromDifficulty( Difficulty dc )
SetDifficulty( DifficultyToString( dc ) );
}
void DifficultyMeter::SetFromGameState( PlayerNumber pn )
void DifficultyMeter::SetFromCourseDifficulty( CourseDifficulty cd )
{
if( GAMESTATE->IsCourseMode() )
{
Trail* pTrail = GAMESTATE->m_pCurTrail[pn];
if( pTrail )
SetFromTrail( pTrail );
else
SetFromCourseDifficulty( GAMESTATE->m_PreferredCourseDifficulty[pn] );
}
else
{
Steps* pSteps = GAMESTATE->m_pCurSteps[pn];
if( pSteps )
SetFromSteps( pSteps );
else
SetFromDifficulty( GAMESTATE->m_PreferredDifficulty[pn] );
}
m_textFeet.SetEffectNone();
if( FEET_IS_DIFFICULTY_COLOR )
m_textFeet.SetDiffuse( RageColor(0.8f,0.8f,0.8f,1) );
SetFromMeterAndDifficulty( 0, DIFFICULTY_BEGINNER );
SetDifficulty( CourseDifficultyToString( cd ) );
}
void DifficultyMeter::SetFromMeterAndDifficulty( int iMeter, Difficulty dc )
@@ -221,12 +230,3 @@ void DifficultyMeter::SetDifficulty( CString diff )
if( SHOW_METER )
COMMAND( m_textMeter, "Set" + Capitalize(diff) );
}
void DifficultyMeter::SetFromCourseDifficulty( CourseDifficulty cd )
{
m_textFeet.SetEffectNone();
if( FEET_IS_DIFFICULTY_COLOR )
m_textFeet.SetDiffuse( RageColor(0.8f,0.8f,0.8f,1) );
SetFromMeterAndDifficulty( 0, DIFFICULTY_BEGINNER );
SetDifficulty( CourseDifficultyToString( cd ) );
}