allow freeing steps from a specific profile
This commit is contained in:
@@ -185,7 +185,7 @@ void GameState::Reset()
|
||||
FOREACH_PlayerNumber( pn )
|
||||
PROFILEMAN->UnloadProfile( pn );
|
||||
|
||||
SONGMAN->FreeAllLoadedFromProfiles();
|
||||
SONGMAN->FreeAllLoadedFromProfile();
|
||||
SONGMAN->UpdateBest();
|
||||
SONGMAN->UpdateShuffled();
|
||||
|
||||
@@ -385,7 +385,7 @@ void GameState::EndGame()
|
||||
// MEMCARDMAN->FlushAndReset();
|
||||
CHECKPOINT;
|
||||
|
||||
SONGMAN->FreeAllLoadedFromProfiles();
|
||||
SONGMAN->FreeAllLoadedFromProfile();
|
||||
|
||||
// make sure we don't execute EndGame twice.
|
||||
m_timeGameStarted.SetZero();
|
||||
|
||||
@@ -1214,12 +1214,12 @@ void SongManager::LoadEditsFromDir( const CString &sDir, ProfileSlot slot )
|
||||
}
|
||||
}
|
||||
|
||||
void SongManager::FreeAllLoadedFromProfiles()
|
||||
void SongManager::FreeAllLoadedFromProfile( ProfileSlot slot )
|
||||
{
|
||||
for( unsigned s=0; s<m_pSongs.size(); s++ )
|
||||
{
|
||||
Song* pSong = m_pSongs[s];
|
||||
pSong->FreeAllLoadedFromProfile();
|
||||
pSong->FreeAllLoadedFromProfile( slot );
|
||||
}
|
||||
|
||||
// After freeing some Steps pointers, the cache will be invalid.
|
||||
|
||||
@@ -37,7 +37,7 @@ public:
|
||||
void LoadAllFromProfile( ProfileSlot s ); // songs, edits
|
||||
void LoadEditsFromDir( const CString &sDir, ProfileSlot slot );
|
||||
int GetNumStepsLoadedFromProfile();
|
||||
void FreeAllLoadedFromProfiles();
|
||||
void FreeAllLoadedFromProfile( ProfileSlot slot = PROFILE_SLOT_INVALID );
|
||||
|
||||
void LoadGroupSymLinks( CString sDir, CString sGroupFolder );
|
||||
|
||||
|
||||
Reference in New Issue
Block a user