From a111a7f6e1b0f96953a0d05001fee69728caea05 Mon Sep 17 00:00:00 2001 From: Chris Danford Date: Sun, 4 Mar 2007 20:55:12 +0000 Subject: [PATCH] When letting SelectMusic choose a Style, don't force that it be set by a proceeding menu. "ALL_STEPS_TYPES_IN_ONE_LIST" is not the best name. It should probably be called "AUTO_SET_STYLE", or something similar. --- stepmania/src/ScreenSelectMusic.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/stepmania/src/ScreenSelectMusic.cpp b/stepmania/src/ScreenSelectMusic.cpp index 7c1c4def3f..8c469a9ad9 100644 --- a/stepmania/src/ScreenSelectMusic.cpp +++ b/stepmania/src/ScreenSelectMusic.cpp @@ -104,6 +104,13 @@ void ScreenSelectMusic::Init() m_TexturePreload.Load( Banner::SongBannerTexture(THEME->GetPathG("Banner","mode")) ); } + if( CommonMetrics::ALL_STEPS_TYPES_IN_ONE_LIST ) + { + vector vst; + GAMEMAN->GetStepsTypesForGame( GAMESTATE->m_pCurGame, vst ); + const Style *pStyle = GAMEMAN->GetFirstCompatibleStyle( GAMESTATE->m_pCurGame, GAMESTATE->GetNumSidesJoined(), vst[0] ); + GAMESTATE->m_pCurStyle.Set( pStyle ); + } if( GAMESTATE->GetCurrentStyle() == NULL ) RageException::Throw( "The Style has not been set. A theme must set the Style before loading ScreenSelectMusic." );