Remove unneeded return value from ProcessBPMs
This commit is contained in:
@@ -235,7 +235,7 @@ void SMLoader::ParseBPMs( vector< pair<float, float> > &out, const RString line,
|
||||
}
|
||||
}
|
||||
|
||||
bool SMLoader::ProcessBPMs( TimingData &out, const vector< pair<float, float> > &vBPMChanges )
|
||||
void SMLoader::ProcessBPMs( TimingData &out, const vector< pair<float, float> > &vBPMChanges )
|
||||
{
|
||||
// prepare storage variables for negative BPMs -> Warps.
|
||||
float negBeat = -1;
|
||||
@@ -286,8 +286,6 @@ bool SMLoader::ProcessBPMs( TimingData &out, const vector< pair<float, float> >
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return bNotEmpty;
|
||||
}
|
||||
|
||||
void SMLoader::ParseStops( vector< pair<float, float> > &out, const RString line, const int rowsPerBeat )
|
||||
|
||||
+2
-3
@@ -79,9 +79,8 @@ struct SMLoader
|
||||
/**
|
||||
* @brief Process the BPM Segments from the string.
|
||||
* @param out the TimingData being modified.
|
||||
* @param vBPMChanges the vector of BPM Changes data.
|
||||
* @return true if there was at least one segment found, false otherwise. */
|
||||
bool ProcessBPMs(TimingData & out,
|
||||
* @param vBPMChanges the vector of BPM Changes data. */
|
||||
void ProcessBPMs(TimingData & out,
|
||||
const vector< pair<float, float> > &vBPMChanges);
|
||||
/**
|
||||
* @brief Parse Stops data from a string.
|
||||
|
||||
@@ -654,8 +654,9 @@ bool SSCLoader::LoadFromSimfile( const RString &sPath, Song &out, bool bFromCach
|
||||
else if( sValueName=="NOTES" || sValueName=="NOTES2" )
|
||||
{
|
||||
// Process timings and convert negative bpms/stops
|
||||
if( SMLoader::ProcessBPMs(stepsTiming, vBPMChanges) )
|
||||
if( !vBPMChanges.empty() )
|
||||
bHasOwnTiming = true;
|
||||
SMLoader::ProcessBPMs(stepsTiming, vBPMChanges);
|
||||
SMLoader::ProcessStops(stepsTiming, vStops);
|
||||
|
||||
state = GETTING_SONG_INFO;
|
||||
@@ -805,8 +806,9 @@ bool SSCLoader::LoadFromSimfile( const RString &sPath, Song &out, bool bFromCach
|
||||
else if( sValueName=="STEPFILENAME" )
|
||||
{
|
||||
// Process timings and convert negative bpms/stops
|
||||
if( SMLoader::ProcessBPMs(stepsTiming, vBPMChanges) )
|
||||
if( !vBPMChanges.empty() )
|
||||
bHasOwnTiming = true;
|
||||
SMLoader::ProcessBPMs(stepsTiming, vBPMChanges);
|
||||
SMLoader::ProcessStops(stepsTiming, vStops);
|
||||
|
||||
state = GETTING_SONG_INFO;
|
||||
@@ -857,7 +859,6 @@ bool SSCLoader::LoadEditFromMsd(const MsdFile &msd,
|
||||
Song* pSong = NULL;
|
||||
Steps* pNewNotes = NULL;
|
||||
bool bSSCFormat = false;
|
||||
bool bHasOwnTiming = false;
|
||||
TimingData stepsTiming;
|
||||
vector< pair<float, float> > vBPMChanges, vStops;
|
||||
|
||||
@@ -1046,13 +1047,12 @@ bool SSCLoader::LoadEditFromMsd(const MsdFile &msd,
|
||||
return true;
|
||||
|
||||
// Process timings and convert negative bpms/stops
|
||||
if( SMLoader::ProcessBPMs(stepsTiming, vBPMChanges) )
|
||||
bHasOwnTiming = true;
|
||||
SMLoader::ProcessBPMs(stepsTiming, vBPMChanges);
|
||||
SMLoader::ProcessStops(stepsTiming, vStops);
|
||||
|
||||
if( bSSCFormat )
|
||||
{
|
||||
if ( bHasOwnTiming )
|
||||
if ( !vBPMChanges.empty() )
|
||||
{
|
||||
pNewNotes->m_Timing = stepsTiming;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user