This commit is contained in:
Steve Checkoway
2006-06-20 06:28:57 +00:00
parent 72b2e1f2b6
commit 6516e6fceb
+9 -9
View File
@@ -26,16 +26,16 @@ void SMLoader::LoadFromSMTokens(
{ {
out.SetSavedToDisk( true ); // we're loading from disk, so this is by definintion already saved out.SetSavedToDisk( true ); // we're loading from disk, so this is by definintion already saved
TrimLeft(sStepsType); TrimRight(sStepsType); TrimLeft( sStepsType ); TrimRight( sStepsType );
TrimLeft(sDescription); TrimRight(sDescription); TrimLeft( sDescription ); TrimRight( sDescription );
TrimLeft(sDifficulty); TrimRight(sDifficulty); TrimLeft( sDifficulty ); TrimRight( sDifficulty );
// LOG->Trace( "Steps::LoadFromSMTokens()" ); // LOG->Trace( "Steps::LoadFromSMTokens()" );
out.m_StepsType = GameManager::StringToStepsType(sStepsType); out.m_StepsType = GameManager::StringToStepsType( sStepsType );
out.SetDescription(sDescription); out.SetDescription( sDescription );
out.SetDifficulty(StringToDifficulty( sDifficulty )); out.SetDifficulty( StringToDifficulty(sDifficulty) );
// HACK: We used to store SMANIAC as DIFFICULTY_HARD with special description. // HACK: We used to store SMANIAC as DIFFICULTY_HARD with special description.
// Now, it has its own DIFFICULTY_CHALLENGE // Now, it has its own DIFFICULTY_CHALLENGE
@@ -46,18 +46,18 @@ void SMLoader::LoadFromSMTokens(
if( sDescription.CompareNoCase("challenge") == 0 ) if( sDescription.CompareNoCase("challenge") == 0 )
out.SetDifficulty( DIFFICULTY_CHALLENGE ); out.SetDifficulty( DIFFICULTY_CHALLENGE );
out.SetMeter(atoi(sMeter)); out.SetMeter( atoi(sMeter) );
vector<RString> saValues; vector<RString> saValues;
split( sRadarValues, ",", saValues, true ); split( sRadarValues, ",", saValues, true );
if( saValues.size() == NUM_RadarCategory ) if( saValues.size() == NUM_RadarCategory )
{ {
RadarValues v; RadarValues v;
FOREACH_RadarCategory(rc) FOREACH_RadarCategory( rc )
v[rc] = StringToFloat( saValues[rc] ); v[rc] = StringToFloat( saValues[rc] );
out.SetCachedRadarValues( v ); out.SetCachedRadarValues( v );
} }
out.SetSMNoteData(sNoteData); out.SetSMNoteData( sNoteData );
out.TidyUpData(); out.TidyUpData();
} }