Radar branch: update SSC version number in cache.

This commit is contained in:
Jason Felds
2011-02-28 00:12:13 -05:00
parent 97d2112fae
commit 59558d0e32
4 changed files with 8 additions and 5 deletions
+1
View File
@@ -928,6 +928,7 @@ bool SSCLoader::LoadFromSSCFile( const RString &sPath, Song &out, bool bFromCach
}
}
}
out.m_fVersion = STEPFILE_VERSION_NUMBER;
return true;
}
+1 -1
View File
@@ -47,7 +47,7 @@ static RString BackgroundChangeToString( const BackgroundChange &bgc )
* @param out the Song in question. */
static void WriteGlobalTags( RageFile &f, const Song &out )
{
f.PutLine( ssprintf( "#VERSION:%.2f;", out.m_fVersion ) );
f.PutLine( ssprintf( "#VERSION:%.2f;", STEPFILE_VERSION_NUMBER ) );
f.PutLine( ssprintf( "#TITLE:%s;", SmEscape(out.m_sMainTitle).c_str() ) );
f.PutLine( ssprintf( "#SUBTITLE:%s;", SmEscape(out.m_sSubTitle).c_str() ) );
f.PutLine( ssprintf( "#ARTIST:%s;", SmEscape(out.m_sArtist).c_str() ) );
+2 -3
View File
@@ -36,8 +36,7 @@
#include <set>
#include <float.h>
/** @brief The version of the .ssc file format. */
const static float VERSION_NUMBER = 0.53f;
/**
* @brief The internal version of the cache for StepMania.
*
@@ -66,7 +65,7 @@ Song::Song()
m_ForegroundChanges = AutoPtrCopyOnWrite<VBackgroundChange>(new VBackgroundChange);
m_LoadedFromProfile = ProfileSlot_Invalid;
m_fVersion = VERSION_NUMBER;
m_fVersion = STEPFILE_VERSION_NUMBER;
m_fMusicSampleStartSeconds = -1;
m_fMusicSampleLengthSeconds = DEFAULT_MUSIC_SAMPLE_LENGTH;
m_fMusicLengthSeconds = 0;
+4 -1
View File
@@ -16,6 +16,9 @@ class StepsID;
struct lua_State;
struct BackgroundChange;
/** @brief The version of the .ssc file format. */
const static float STEPFILE_VERSION_NUMBER = 0.53f;
/** @brief How many edits for this song can each profile have? */
const int MAX_EDITS_PER_SONG_PER_PROFILE = 5;
/** @brief How many edits for this song can be available? */
@@ -73,7 +76,7 @@ public:
~Song();
void Reset();
void DetachSteps();
/**
* @brief Load a song from the chosen directory.
*