From 2957b7939fbb3d7c21042559a53e40a4761463c1 Mon Sep 17 00:00:00 2001 From: Chris Danford Date: Thu, 10 Mar 2005 22:54:55 +0000 Subject: [PATCH] mystery -> secret --- stepmania/src/Course.cpp | 20 ++++++++++---------- stepmania/src/Course.h | 4 ++-- stepmania/src/CourseEntryDisplay.cpp | 4 +++- stepmania/src/GameConstantsAndTypes.cpp | 2 +- stepmania/src/GameConstantsAndTypes.h | 2 +- stepmania/src/HelpDisplay.cpp | 2 +- stepmania/src/ScreenOptions.cpp | 2 +- stepmania/src/ScreenSelectMusic.cpp | 6 ++++-- stepmania/src/Trail.cpp | 10 +++++----- stepmania/src/Trail.h | 6 +++--- 10 files changed, 31 insertions(+), 27 deletions(-) diff --git a/stepmania/src/Course.cpp b/stepmania/src/Course.cpp index 93a37b0018..ac830932f6 100644 --- a/stepmania/src/Course.cpp +++ b/stepmania/src/Course.cpp @@ -180,12 +180,12 @@ void Course::LoadFromCRSFile( CString sPath ) } else if( sParams[1] == "*" ) { - new_entry.mystery = true; + new_entry.bSecret = true; new_entry.type = COURSE_ENTRY_RANDOM; } else if( sParams[1].Right(1) == "*" ) { - new_entry.mystery = true; + new_entry.bSecret = true; new_entry.type = COURSE_ENTRY_RANDOM_WITHIN_GROUP; CString sSong = sParams[1]; sSong.Replace( "\\", "/" ); @@ -241,16 +241,16 @@ void Course::LoadFromCRSFile( CString sPath ) } { - /* If "showcourse" or "noshowcourse" is in the list, force new_entry.mystery + /* If "showcourse" or "noshowcourse" is in the list, force new_entry.secret * on or off. */ CStringArray mods; split( sParams[3], ",", mods, true ); for( int j = (int) mods.size()-1; j >= 0 ; --j ) { if( !mods[j].CompareNoCase("showcourse") ) - new_entry.mystery = false; + new_entry.bSecret = false; else if( !mods[j].CompareNoCase("noshowcourse") ) - new_entry.mystery = true; + new_entry.bSecret = true; else if( !mods[j].CompareNoCase("nodifficult") ) new_entry.no_difficult = true; else @@ -496,12 +496,12 @@ void Course::Save( CString sPath, bool bSavingCache ) line += ":"; CString modifiers = entry.modifiers; - bool default_mystery = (entry.type == COURSE_ENTRY_RANDOM || entry.type == COURSE_ENTRY_RANDOM_WITHIN_GROUP); - if( default_mystery != entry.mystery ) + bool default_secret = (entry.type == COURSE_ENTRY_RANDOM || entry.type == COURSE_ENTRY_RANDOM_WITHIN_GROUP); + if( default_secret != entry.bSecret ) { if( modifiers != "" ) modifiers += ","; - modifiers += entry.mystery? "noshowcourse":"showcourse"; + modifiers += entry.bSecret? "noshowcourse":"showcourse"; } if( entry.no_difficult ) @@ -547,7 +547,7 @@ void Course::AutogenEndlessFromGroup( CString sGroupName, Difficulty diff ) e.group_name = sGroupName; e.difficulty = diff; - e.mystery = true; + e.bSecret = true; vector vSongs; SONGMAN->GetSongs( vSongs, e.group_name ); @@ -1014,7 +1014,7 @@ bool Course::GetTrailUnsorted( StepsType st, CourseDifficulty cd, Trail &trail ) te.pSteps = pSteps; te.Modifiers = e.modifiers; te.Attacks = e.attacks; - te.bMystery = e.mystery; + te.bSecret = e.bSecret; te.iLowMeter = low_meter; te.iHighMeter = high_meter; /* If we chose based on meter (not difficulty), then store DIFFICULTY_INVALID, so diff --git a/stepmania/src/Course.h b/stepmania/src/Course.h index 2c70d02074..92767fee3f 100644 --- a/stepmania/src/Course.h +++ b/stepmania/src/Course.h @@ -44,7 +44,7 @@ class CourseEntry { public: CourseEntryType type; - bool mystery; // show "??????" + bool bSecret; // show "??????" Song* pSong; // used in type=fixed CString group_name; // used in type=random_within_group Difficulty difficulty; // = DIFFICULTY_INVALID if no difficulty specified @@ -58,7 +58,7 @@ public: CourseEntry() { type = (CourseEntryType)0; - mystery = false; + bSecret = false; pSong = NULL; group_name = ""; difficulty = DIFFICULTY_INVALID; diff --git a/stepmania/src/CourseEntryDisplay.cpp b/stepmania/src/CourseEntryDisplay.cpp index ba4c4df9c3..7fb491d781 100644 --- a/stepmania/src/CourseEntryDisplay.cpp +++ b/stepmania/src/CourseEntryDisplay.cpp @@ -79,7 +79,7 @@ void CourseEntryDisplay::LoadFromTrailEntry( int iNum, const TrailEntry *tes[NUM if( te == NULL ) return; - if( te->bMystery ) + if( te->bSecret ) { FOREACH_EnabledPlayer(pn) { @@ -96,7 +96,9 @@ void CourseEntryDisplay::LoadFromTrailEntry( int iNum, const TrailEntry *tes[NUM SetDifficulty( pn, ssprintf(iLow==iHigh?"%d":"%d-%d", iLow, iHigh), colorNotes ); } else + { SetDifficulty( pn, "?", SONGMAN->GetDifficultyColor( dc ) ); + } } m_TextBanner.LoadFromString( "??????????", "??????????", "", "", "", "" ); diff --git a/stepmania/src/GameConstantsAndTypes.cpp b/stepmania/src/GameConstantsAndTypes.cpp index c402e66c44..53cdc3bb51 100644 --- a/stepmania/src/GameConstantsAndTypes.cpp +++ b/stepmania/src/GameConstantsAndTypes.cpp @@ -246,7 +246,7 @@ bool DisplayBpms::BpmIsConstant() const return fabsf( GetMin() - GetMax() ) < 0.001f; } -bool DisplayBpms::IsMystery() const +bool DisplayBpms::IsSecret() const { FOREACH_CONST( float, vfBpms, f ) { diff --git a/stepmania/src/GameConstantsAndTypes.h b/stepmania/src/GameConstantsAndTypes.h index 860c43803e..409672df9c 100644 --- a/stepmania/src/GameConstantsAndTypes.h +++ b/stepmania/src/GameConstantsAndTypes.h @@ -328,7 +328,7 @@ struct DisplayBpms float GetMin() const; float GetMax() const; bool BpmIsConstant() const; - bool IsMystery() const; + bool IsSecret() const; vector vfBpms; }; diff --git a/stepmania/src/HelpDisplay.cpp b/stepmania/src/HelpDisplay.cpp index bfb4755500..fb07e37408 100644 --- a/stepmania/src/HelpDisplay.cpp +++ b/stepmania/src/HelpDisplay.cpp @@ -118,7 +118,7 @@ void GenreDisplay::PlayCommand( const CString &sCommandName ) FOREACH_CONST( TrailEntry, pTrail->m_vEntries, e ) { - if( e->bMystery ) + if( e->bSecret ) { m_Artists.push_back( "???" ); m_AltArtists.push_back( "???" ); diff --git a/stepmania/src/ScreenOptions.cpp b/stepmania/src/ScreenOptions.cpp index f567406a31..e7fe8ac235 100644 --- a/stepmania/src/ScreenOptions.cpp +++ b/stepmania/src/ScreenOptions.cpp @@ -338,7 +338,7 @@ CString ScreenOptions::GetExplanationTitle( int iRow ) const pTrail->GetDisplayBpms( bpms ); } - if( bpms.IsMystery() ) + if( bpms.IsSecret() ) sTitle += ssprintf( " (??" "?)" ); /* split so gcc doesn't think this is a trigraph */ else if( bpms.BpmIsConstant() ) sTitle += ssprintf( " (%.0f)", bpms.GetMin() ); diff --git a/stepmania/src/ScreenSelectMusic.cpp b/stepmania/src/ScreenSelectMusic.cpp index 2e55d454ad..c89b9e5ba1 100644 --- a/stepmania/src/ScreenSelectMusic.cpp +++ b/stepmania/src/ScreenSelectMusic.cpp @@ -1641,11 +1641,13 @@ void ScreenSelectMusic::AfterMusicChange() FOREACH_CONST( TrailEntry, pTrail->m_vEntries, e ) { - if( e->bMystery ) + if( e->bSecret ) { m_Artists.push_back( "???" ); m_AltArtists.push_back( "???" ); - } else { + } + else + { m_Artists.push_back( e->pSong->GetDisplayArtist() ); m_AltArtists.push_back( e->pSong->GetTranslitArtist() ); } diff --git a/stepmania/src/Trail.cpp b/stepmania/src/Trail.cpp index d686ddf378..65f78deb45 100644 --- a/stepmania/src/Trail.cpp +++ b/stepmania/src/Trail.cpp @@ -23,7 +23,7 @@ bool TrailEntry::operator== ( const TrailEntry &rhs ) const EQUAL(pSteps) && EQUAL(Modifiers) && EQUAL(Attacks) && - EQUAL(bMystery) && + EQUAL(bSecret) && EQUAL(iLowMeter) && EQUAL(iHighMeter) && EQUAL(dc); @@ -62,7 +62,7 @@ void Trail::SetRadarValues( const RadarValues &rv ) RadarValues Trail::GetRadarValues() const { - if( IsMystery() ) + if( IsSecret() ) { // Don't calculate RadarValues for a non-fixed Course. They values are // worthless because they'll change every time this Trail is @@ -152,7 +152,7 @@ void Trail::GetDisplayBpms( DisplayBpms &AddTo ) { FOREACH_CONST( TrailEntry, m_vEntries, e ) { - if( e->bMystery ) + if( e->bSecret ) { AddTo.Add( -1 ); continue; @@ -177,11 +177,11 @@ void Trail::GetDisplayBpms( DisplayBpms &AddTo ) } } -bool Trail::IsMystery() const +bool Trail::IsSecret() const { FOREACH_CONST( TrailEntry, m_vEntries, e ) { - if( e->bMystery ) + if( e->bSecret ) return true; } return false; diff --git a/stepmania/src/Trail.h b/stepmania/src/Trail.h index 308b1fdff8..6bc46bf5bc 100644 --- a/stepmania/src/Trail.h +++ b/stepmania/src/Trail.h @@ -15,7 +15,7 @@ struct TrailEntry TrailEntry(): pSong(NULL), pSteps(NULL), - bMystery(false), + bSecret(false), iLowMeter(-1), iHighMeter(-1), dc(DIFFICULTY_INVALID) @@ -27,7 +27,7 @@ struct TrailEntry Steps* pSteps; CString Modifiers; AttackArray Attacks; - bool bMystery; + bool bSecret; /* These represent the meter and difficulty used by the course to pick the * steps; if you want the real difficulty and meter, look at pSteps. */ @@ -69,7 +69,7 @@ public: int GetTotalMeter() const; float GetLengthSeconds() const; void GetDisplayBpms( DisplayBpms &AddTo ); - bool IsMystery() const; + bool IsSecret() const; bool ContainsSong( Song* pSong ) const; };