cache m_sSongFileName

This commit is contained in:
Glenn Maynard
2003-12-30 02:46:47 +00:00
parent f89940ac02
commit 5ec05b31ba
3 changed files with 52 additions and 42 deletions
+11 -2
View File
@@ -147,7 +147,7 @@ bool SMLoader::LoadFromSMFile( CString sPath, Song &out )
{
int iNumParams = msd.GetNumParams(i);
const MsdFile::value_t &sParams = msd.GetValue(i);
const CString sValueName = sParams[0];
const CString &sValueName = sParams[0];
// handle the data
if( 0==stricmp(sValueName,"TITLE") )
@@ -214,7 +214,16 @@ bool SMLoader::LoadFromSMFile( CString sPath, Song &out )
}
out.m_fLastBeat = (float)atof( sParams[1] );
}
else if( 0==stricmp(sValueName,"SONGFILENAME") )
{
if(!FromCache)
{
LOG->Trace("Ignored #SONGFILENAME (cache only)");
continue;
}
out.m_sSongFileName = sParams[1];
}
else if( 0==stricmp(sValueName,"SAMPLESTART") )
out.m_fMusicSampleStartSeconds = TimeToSeconds( sParams[1] );