diff --git a/stepmania/Themes/default/metrics.ini b/stepmania/Themes/default/metrics.ini index 2d35029aa2..0e65529721 100644 --- a/stepmania/Themes/default/metrics.ini +++ b/stepmania/Themes/default/metrics.ini @@ -4308,3 +4308,21 @@ TimerSeconds=0 [Banner] ScrollRandom=1 ScrollRoulette=1 + +[ProfileHtml] +ShowPlayModeArcade=1 +ShowPlayModeNonstop=1 +ShowPlayModeOni=1 +ShowPlayModeEndless=1 +ShowPlayModeBattle=1 +ShowPlayModeRave=1 +ShowRadarRadarCategoryStream=1 +ShowRadarRadarCategoryVoltage=1 +ShowRadarRadarCategoryAir=1 +ShowRadarRadarCategoryFreeze=1 +ShowRadarRadarCategoryChaos=1 +ShowRadarRadarCategoryTaps=1 +ShowRadarRadarCategoryJumps=1 +ShowRadarRadarCategoryHolds=1 +ShowRadarRadarCategoryMines=1 +ShowRadarRadarCategoryHands=1 diff --git a/stepmania/src/GameConstantsAndTypes.cpp b/stepmania/src/GameConstantsAndTypes.cpp index 5dd8b30f30..5945cde5bf 100644 --- a/stepmania/src/GameConstantsAndTypes.cpp +++ b/stepmania/src/GameConstantsAndTypes.cpp @@ -30,6 +30,7 @@ static const CString RadarCategoryNames[NUM_RADAR_CATEGORIES] = { "Hands", }; XToString( RadarCategory ); +XToThemedString( RadarCategory ); static const CString DifficultyNames[NUM_RADAR_CATEGORIES] = { @@ -89,6 +90,7 @@ static const CString PlayModeNames[NUM_PLAY_MODES] = { "Rave", }; XToString( PlayMode ); +XToThemedString( PlayMode ); StringToX( PlayMode ); diff --git a/stepmania/src/GameConstantsAndTypes.h b/stepmania/src/GameConstantsAndTypes.h index a80e6014da..9232eb7eb2 100644 --- a/stepmania/src/GameConstantsAndTypes.h +++ b/stepmania/src/GameConstantsAndTypes.h @@ -60,6 +60,7 @@ enum RadarCategory }; #define FOREACH_RadarCategory( rc ) FOREACH_ENUM( RadarCategory, NUM_RADAR_CATEGORIES, rc ) const CString& RadarCategoryToString( RadarCategory cat ); +CString RadarCategoryToThemedString( RadarCategory cat ); struct RadarValues { @@ -164,6 +165,7 @@ enum PlayMode }; #define FOREACH_PlayMode( pm ) FOREACH_ENUM( PlayMode, NUM_PLAY_MODES, pm ) const CString& PlayModeToString( PlayMode pm ); +CString PlayModeToThemedString( PlayMode pm ); PlayMode StringToPlayMode( const CString& s ); diff --git a/stepmania/src/ProfileHtml.cpp b/stepmania/src/ProfileHtml.cpp index 864ca5607e..d8f88ecba0 100644 --- a/stepmania/src/ProfileHtml.cpp +++ b/stepmania/src/ProfileHtml.cpp @@ -33,9 +33,11 @@ const CString STATS_HTML = "Stats.html"; const CString STYLE_CSS = "Style.css"; -#define TITLE THEME->GetMetric("ProfileHtml","Title") -#define FOOTER THEME->GetMetric("ProfileHtml","Footer") -#define VERIFICATION_TEXT THEME->GetMetric("ProfileHtml","VerificationText") +#define TITLE THEME->GetMetric("ProfileHtml","Title") +#define FOOTER THEME->GetMetric("ProfileHtml","Footer") +#define VERIFICATION_TEXT THEME->GetMetric("ProfileHtml","VerificationText") +#define SHOW_PLAY_MODE(pm) THEME->GetMetric("ProfileHtml","ShowPlayMode"+PlayModeToString(pm)) +#define SHOW_RADAR_CATEGORY(rc) THEME->GetMetric("ProfileHtml","ShowCategory"+RadarCategoryToString(rc)) static int g_Level = 1; @@ -298,7 +300,11 @@ void PrintStatistics( RageFile &f, const Profile *pProfile, CString sTitle, vect { BEGIN_TABLE(4); FOREACH_PlayMode( pm ) - TABLE_LINE2( PlayModeToString(pm), pProfile->m_iNumSongsPlayedByPlayMode[pm] ); + { + if( !SHOW_PLAY_MODE(pm) ) + continue; // skip + TABLE_LINE2( PlayModeToThemedString(pm), pProfile->m_iNumSongsPlayedByPlayMode[pm] ); + } END_TABLE; } PRINT_CLOSE(f); @@ -328,7 +334,7 @@ void PrintStatistics( RageFile &f, const Profile *pProfile, CString sTitle, vect { BEGIN_TABLE(4); FOREACH_Difficulty( dc ) - TABLE_LINE2( DifficultyToString(dc), pProfile->m_iNumSongsPlayedByDifficulty[dc] ); + TABLE_LINE2( DifficultyToThemedString(dc), pProfile->m_iNumSongsPlayedByDifficulty[dc] ); END_TABLE; } PRINT_CLOSE(f); @@ -457,9 +463,9 @@ void PrintPopularity( RageFile &f, const Profile *pProfile, CString sTitle, vect if( iNumTimesPlayed==0 ) continue; // skip CString s; - s += GAMEMAN->NotesTypeToString(pSteps->m_StepsType); + s += GAMEMAN->NotesTypeToThemedString(pSteps->m_StepsType); s += " "; - s += DifficultyToString(pSteps->GetDifficulty()); + s += DifficultyToThemedString(pSteps->GetDifficulty()); TABLE_LINE5(i+1, pSong->GetDisplayMainTitle(), pSong->GetDisplaySubTitle(), s, PrettyPercent(iNumTimesPlayed,iTotalPlays) ); } if( i == 0 ) @@ -614,7 +620,7 @@ void PrintHighScoreListTable( RageFile &f, const HighScoreList& hsl ) const HighScore &hs = hsl.vHighScores[i]; CString sName = ssprintf("#%d",i+1); CString sHSName = hs.sName.empty() ? "????" : hs.sName; - CString sValue = ssprintf("%s, %s, %i, %.2f%%", sHSName.c_str(), GradeToString(hs.grade).c_str(), hs.iScore, hs.fPercentDP*100); + CString sValue = ssprintf("%s, %s, %i, %.2f%%", sHSName.c_str(), GradeToThemedString(hs.grade).c_str(), hs.iScore, hs.fPercentDP*100); TABLE_LINE2( sName.c_str(), sValue ); } END_TABLE; @@ -648,9 +654,9 @@ bool PrintHighScoresForSong( RageFile &f, const Profile *pProfile, Song* pSong ) continue; CString s = - GAMEMAN->NotesTypeToString(pSteps->m_StepsType) + + GAMEMAN->NotesTypeToThemedString(pSteps->m_StepsType) + " - " + - DifficultyToString(pSteps->GetDifficulty()); + DifficultyToThemedString(pSteps->GetDifficulty()); PRINT_OPEN(f, s, true); { PrintHighScoreListTable( f, hsl ); @@ -677,7 +683,7 @@ bool PrintHighScoresForCourse( RageFile &f, const Profile *pProfile, Course* pCo bPrintedAny = true; - PRINT_OPEN(f, GAMEMAN->NotesTypeToString(st)+" - "+CourseDifficultyToString(cd) ); + PRINT_OPEN(f, GAMEMAN->NotesTypeToThemedString(st)+" - "+CourseDifficultyToThemedString(cd) ); { PrintHighScoreListTable( f, hsl ); } @@ -708,7 +714,7 @@ bool PrintGradeTableForStepsType( RageFile &f, const Profile *pProfile, StepsTyp unsigned i; const vector &vpSongs = SONGMAN->GetAllSongs(); - PRINT_OPEN(f, GAMEMAN->NotesTypeToString(st).c_str() ); + PRINT_OPEN(f, GAMEMAN->NotesTypeToThemedString(st).c_str() ); { f.PutLine( "\n" ); @@ -718,7 +724,7 @@ bool PrintGradeTableForStepsType( RageFile &f, const Profile *pProfile, StepsTyp { if( dc == DIFFICULTY_EDIT ) continue; // skip - f.PutLine( ssprintf("", Capitalize(DifficultyToString(dc)).c_str()) ); + f.PutLine( ssprintf("", Capitalize(DifficultyToThemedString(dc)).c_str()) ); } f.PutLine( "" ); @@ -802,9 +808,9 @@ bool PrintInventoryForSong( RageFile &f, const Profile *pProfile, Song* pSong ) if( pSteps->IsAutogen() ) continue; // skip autogen CString s = - GAMEMAN->NotesTypeToString(pSteps->m_StepsType) + + GAMEMAN->NotesTypeToThemedString(pSteps->m_StepsType) + " - " + - DifficultyToString(pSteps->GetDifficulty()); + DifficultyToThemedString(pSteps->GetDifficulty()); PRINT_OPEN(f, s, true); // use poister value as the hash { BEGIN_TABLE(3); @@ -816,7 +822,10 @@ bool PrintInventoryForSong( RageFile &f, const Profile *pProfile, Song* pSong ) BEGIN_TABLE(2); FOREACH_RadarCategory( cat ) { - CString sCat = RadarCategoryToString(cat); + if( !SHOW_RADAR_CATEGORY(cat) ) + continue; // skip + + CString sCat = RadarCategoryToThemedString(cat); float fVal = pSteps->GetRadarValues()[cat]; CString sVal = ssprintf( "%.2f", fVal ); TABLE_LINE2( sCat, sVal );
%s%s