diff --git a/Docs/Changelog_SSCformat.txt b/Docs/Changelog_SSCformat.txt index bf388ed6fc..12cb56d7b8 100644 --- a/Docs/Changelog_SSCformat.txt +++ b/Docs/Changelog_SSCformat.txt @@ -9,6 +9,9 @@ change to JSON, but it is unsure if this will be done. Implement .ssc at your own risk. ________________________________________________________________________________ +[v0.72] - Wolfman2000 +* Have #OFFSET come before #ATTACKS in the Step data. + [v0.71] - Wolfman2000 * Have #ATTACKS work per step as well. diff --git a/Docs/Changelog_sm5.txt b/Docs/Changelog_sm5.txt index 00067dc2d1..330b897df1 100644 --- a/Docs/Changelog_sm5.txt +++ b/Docs/Changelog_sm5.txt @@ -15,6 +15,8 @@ StepMania 5.0 Preview 2 | 201106?? probably going to be better overall. [Wolfman2000] * [TimingData] Preserve the length of time for Speed Segment scaling when using beats. [Wolfman2000] +* [NotesLoader/WriterSSC] #OFFSET is to be before #ATTACKS. This is required if + we pursue beat based attacks and not just second based. [Wolfman2000] 2011/06/26 ---------- diff --git a/Docs/SimfileFormats/ssc_msd5.txt b/Docs/SimfileFormats/ssc_msd5.txt index 0b878925d9..119f61b297 100644 --- a/Docs/SimfileFormats/ssc_msd5.txt +++ b/Docs/SimfileFormats/ssc_msd5.txt @@ -51,6 +51,7 @@ #CREDIT:; // steps-based timingdata +#OFFSET:; #BPMS:; #STOPS:; #DELAYS:; @@ -62,7 +63,6 @@ #FAKES:; #LABELS:; #ATTACKS:; -#OFFSET:; // actual step data #NOTES:; diff --git a/src/NotesLoaderSSC.h b/src/NotesLoaderSSC.h index 3031932841..286a849ab2 100644 --- a/src/NotesLoaderSSC.h +++ b/src/NotesLoaderSSC.h @@ -26,6 +26,8 @@ const float VERSION_RADAR_FAKE = 0.53f; const float VERSION_WARP_SEGMENT = 0.56f; /** @brief The version that formally introduced Split Timing. */ const float VERSION_SPLIT_TIMING = 0.7f; +/** @brief The version that moved the step's Offset higher up. */ +const float VERSION_OFFSET_BEFORE_ATTACK = 0.72f; /** * @brief The SSCLoader handles all of the parsing needed for .ssc files. diff --git a/src/NotesWriterSSC.cpp b/src/NotesWriterSSC.cpp index b682788558..dc9c63a5a2 100644 --- a/src/NotesWriterSSC.cpp +++ b/src/NotesWriterSSC.cpp @@ -317,7 +317,8 @@ static RString GetSSCNoteData( const Song &song, const Steps &in, bool bSavingCa lines.push_back( ssprintf( "#RADARVALUES:%s;", join(",",asRadarValues).c_str() ) ); lines.push_back( ssprintf( "#CREDIT:%s;", SmEscape(in.GetCredit()).c_str() ) ); - + lines.push_back( ssprintf( "#OFFSET:%.6f;", in.m_Timing.m_fBeat0OffsetInSeconds ) ); + GetTimingTags( lines, in.m_Timing ); RString attacks = ""; @@ -332,8 +333,6 @@ static RString GetSSCNoteData( const Song &song, const Steps &in, bool bSavingCa Trim(attacks, ":"); // just in case something screwy happens. lines.push_back( ssprintf( "#ATTACKS:%s;", attacks.c_str())); - lines.push_back( ssprintf( "#OFFSET:%.6f;", in.m_Timing.m_fBeat0OffsetInSeconds ) ); - RString sNoteData; in.GetSMNoteData( sNoteData ); diff --git a/src/Song.cpp b/src/Song.cpp index 72c2001fd4..caf5f08315 100644 --- a/src/Song.cpp +++ b/src/Song.cpp @@ -41,7 +41,7 @@ * @brief The internal version of the cache for StepMania. * * Increment this value to invalidate the current cache. */ -const int FILE_CACHE_VERSION = 184; +const int FILE_CACHE_VERSION = 185; /** @brief How long does a song sample last by default? */ const float DEFAULT_MUSIC_SAMPLE_LENGTH = 12.f; diff --git a/src/Song.h b/src/Song.h index ca490b6294..990e553009 100644 --- a/src/Song.h +++ b/src/Song.h @@ -20,7 +20,7 @@ void FixupPath( RString &path, const RString &sSongPath ); RString GetSongAssetPath( RString sPath, const RString &sSongPath ); /** @brief The version of the .ssc file format. */ -const static float STEPFILE_VERSION_NUMBER = 0.71f; +const static float STEPFILE_VERSION_NUMBER = 0.72f; /** @brief How many edits for this song can each profile have? */ const int MAX_EDITS_PER_SONG_PER_PROFILE = 15;