Course::Unload

This commit is contained in:
Glenn Maynard
2004-01-26 20:55:35 +00:00
parent d8212e8d08
commit b9b589cc34
2 changed files with 14 additions and 6 deletions
+13 -6
View File
@@ -39,12 +39,7 @@ const int MAX_BOTTOM_RANGE = 10;
Course::Course()
{
m_bIsAutogen = false;
m_bRepeat = false;
m_bRandomize = false;
// m_bDifficult = false;
m_iLives = -1;
m_iMeter = -1;
Unload();
}
PlayMode Course::GetPlayMode() const
@@ -106,6 +101,8 @@ void Course::LoadFromCRSFile( CString sPath )
{
LOG->Trace( "Course::LoadFromCRSFile( '%s' )", sPath.c_str() );
Unload();
m_sPath = sPath; // save path
MsdFile msd;
@@ -299,6 +296,16 @@ void Course::LoadFromCRSFile( CString sPath )
ignore, ignore, ignore);
}
void Course::Unload()
{
m_bIsAutogen = false;
m_bRepeat = false;
m_bRandomize = false;
m_iLives = -1;
m_iMeter = -1;
m_entries.clear();
m_sPath = m_sName = m_sTranslitName = m_sBannerPath = m_sCDTitlePath = "";
}
void Course::Save()
{
+1
View File
@@ -133,6 +133,7 @@ public:
bool IsFixed() const;
void LoadFromCRSFile( CString sPath );
void Unload();
void Save();
void AutogenEndlessFromGroup( CString sGroupName, vector<Song*> &apSongsInGroup );
void AutogenNonstopFromGroup( CString sGroupName, vector<Song*> &apSongsInGroup );