From 62a6a7754b53c6e2884e7d3781577d20e7628063 Mon Sep 17 00:00:00 2001 From: Chris Danford Date: Wed, 13 Aug 2003 04:48:06 +0000 Subject: [PATCH] Fill in Steps::m_sDescription automatically if missing. --- stepmania/src/NotesLoaderKSF.cpp | 2 ++ stepmania/src/Song.cpp | 2 ++ stepmania/src/Steps.cpp | 5 +++++ 3 files changed, 9 insertions(+) diff --git a/stepmania/src/NotesLoaderKSF.cpp b/stepmania/src/NotesLoaderKSF.cpp index 1a0c057830..76fe1e086f 100644 --- a/stepmania/src/NotesLoaderKSF.cpp +++ b/stepmania/src/NotesLoaderKSF.cpp @@ -208,6 +208,8 @@ bool KSFLoader::LoadFromKSFFile( const CString &sPath, Steps &out, const Song &s out.SetNoteData(¬edata); + out.TidyUpData(); + return true; } diff --git a/stepmania/src/Song.cpp b/stepmania/src/Song.cpp index 26d196cd59..77251bc08c 100644 --- a/stepmania/src/Song.cpp +++ b/stepmania/src/Song.cpp @@ -778,7 +778,9 @@ void Song::TidyUpData() } for( i=0; iCompress(); + } } void Song::TranslateTitles() diff --git a/stepmania/src/Steps.cpp b/stepmania/src/Steps.cpp index 4ea1b95a03..b26e1125e0 100644 --- a/stepmania/src/Steps.cpp +++ b/stepmania/src/Steps.cpp @@ -145,6 +145,11 @@ void Steps::TidyUpData() default: ASSERT(0); } } + + if( m_sDescription.empty() ) + { + m_sDescription = Capitalize( DifficultyToString(m_Difficulty) ); + } } void Steps::Decompress() const