[ScreenHowToPlay] Allow themers to use either .ssc or .sm files.
(update comment on ScreenGameplaySyncMachine)
This commit is contained in:
@@ -15,7 +15,8 @@ sm-ssc v1.2.3 | 201103??
|
|||||||
|
|
||||||
20110302
|
20110302
|
||||||
--------
|
--------
|
||||||
* [ScreenGameplaySyncMachine] Allow themes to use either .ssc or .sm files. [AJ]
|
* [ScreenGameplaySyncMachine] Allow themers to use either .ssc or .sm files. [AJ]
|
||||||
|
* [ScreenHowToPlay] Allow themers to use either .ssc or .sm files. [AJ]
|
||||||
|
|
||||||
20110301
|
20110301
|
||||||
--------
|
--------
|
||||||
|
|||||||
@@ -20,7 +20,7 @@ void ScreenGameplaySyncMachine::Init()
|
|||||||
AdjustSync::ResetOriginalSyncData();
|
AdjustSync::ResetOriginalSyncData();
|
||||||
|
|
||||||
RString sFile = THEME->GetPathO("ScreenGameplaySyncMachine","music");
|
RString sFile = THEME->GetPathO("ScreenGameplaySyncMachine","music");
|
||||||
// Allow themers to use .ssc and .sm files. -aj
|
// Allow themers to use either a .ssc or .sm file for this. -aj
|
||||||
if(sFile.Right(4) == ".ssc")
|
if(sFile.Right(4) == ".ssc")
|
||||||
SSCLoader::LoadFromSSCFile( sFile, m_Song );
|
SSCLoader::LoadFromSSCFile( sFile, m_Song );
|
||||||
else
|
else
|
||||||
|
|||||||
@@ -133,17 +133,19 @@ void ScreenHowToPlay::Init()
|
|||||||
ActorUtil::LoadAllCommandsAndSetXY( m_pLifeMeterBar, m_sName );
|
ActorUtil::LoadAllCommandsAndSetXY( m_pLifeMeterBar, m_sName );
|
||||||
m_pLifeMeterBar->FillForHowToPlay( NUM_W2S, NUM_MISSES );
|
m_pLifeMeterBar->FillForHowToPlay( NUM_W2S, NUM_MISSES );
|
||||||
|
|
||||||
// Allow themers to use .ssc and .sm files. -aj
|
// Allow themers to use either a .ssc or .sm file for this. -aj
|
||||||
bool bLoadedSSCFile = SSCLoader::LoadFromSSCFile( THEME->GetPathO(m_sName, "steps"), m_Song, false );
|
RString sStepsPath = THEME->GetPathO(m_sName, "steps");
|
||||||
if( !bLoadedSSCFile )
|
if( sPath.Right(4) == ".ssc" )
|
||||||
SMLoader::LoadFromSMFile( THEME->GetPathO(m_sName, "steps"), m_Song, false );
|
SSCLoader::LoadFromSSCFile( sStepsPath, m_Song, false );
|
||||||
|
else
|
||||||
|
SMLoader::LoadFromSMFile( sStepsPath, m_Song, false );
|
||||||
m_Song.AddAutoGenNotes();
|
m_Song.AddAutoGenNotes();
|
||||||
|
|
||||||
const Style* pStyle = GAMESTATE->GetCurrentStyle();
|
const Style* pStyle = GAMESTATE->GetCurrentStyle();
|
||||||
|
|
||||||
Steps *pSteps = SongUtil::GetStepsByDescription( &m_Song, pStyle->m_StepsType, "" );
|
Steps *pSteps = SongUtil::GetStepsByDescription( &m_Song, pStyle->m_StepsType, "" );
|
||||||
// todo: make StepsType human readable. -aj
|
// todo: make StepsType human readable. -aj
|
||||||
ASSERT_M( pSteps != NULL, ssprintf("StepsType %i is NULL", pStyle->m_StepsType) );
|
ASSERT_M( pSteps != NULL, "No playable steps for ScreenHowToPlay" );
|
||||||
|
|
||||||
NoteData tempNoteData;
|
NoteData tempNoteData;
|
||||||
pSteps->GetNoteData( tempNoteData );
|
pSteps->GetNoteData( tempNoteData );
|
||||||
|
|||||||
Reference in New Issue
Block a user