goto -> fake infinite.
This commit is contained in:
@@ -1722,13 +1722,16 @@ void NoteDataUtil::InsertIntelligentTaps(
|
|||||||
int iTrackOfNoteLater = -1;
|
int iTrackOfNoteLater = -1;
|
||||||
inout.GetTapFirstNonEmptyTrack( iRowLater, iTrackOfNoteLater );
|
inout.GetTapFirstNonEmptyTrack( iRowLater, iTrackOfNoteLater );
|
||||||
int iTrackOfNoteToAdd = 0;
|
int iTrackOfNoteToAdd = 0;
|
||||||
|
|
||||||
|
for (;;)
|
||||||
|
{
|
||||||
if( bSkippy &&
|
if( bSkippy &&
|
||||||
iTrackOfNoteEarlier != iTrackOfNoteLater ) // Don't make skips on the same note
|
iTrackOfNoteEarlier != iTrackOfNoteLater ) // Don't make skips on the same note
|
||||||
{
|
{
|
||||||
if( bEarlierHasNonEmptyTrack )
|
if( bEarlierHasNonEmptyTrack )
|
||||||
{
|
{
|
||||||
iTrackOfNoteToAdd = iTrackOfNoteEarlier;
|
iTrackOfNoteToAdd = iTrackOfNoteEarlier;
|
||||||
goto done_looking_for_track_to_add;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1736,24 +1739,25 @@ void NoteDataUtil::InsertIntelligentTaps(
|
|||||||
if( abs(iTrackOfNoteEarlier-iTrackOfNoteLater) >= 2 )
|
if( abs(iTrackOfNoteEarlier-iTrackOfNoteLater) >= 2 )
|
||||||
{
|
{
|
||||||
iTrackOfNoteToAdd = min(iTrackOfNoteEarlier,iTrackOfNoteLater)+1;
|
iTrackOfNoteToAdd = min(iTrackOfNoteEarlier,iTrackOfNoteLater)+1;
|
||||||
goto done_looking_for_track_to_add;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
// try to choose a track just to the left
|
// try to choose a track just to the left
|
||||||
if( min(iTrackOfNoteEarlier,iTrackOfNoteLater)-1 >= 0 )
|
if( min(iTrackOfNoteEarlier,iTrackOfNoteLater)-1 >= 0 )
|
||||||
{
|
{
|
||||||
iTrackOfNoteToAdd = min(iTrackOfNoteEarlier,iTrackOfNoteLater)-1;
|
iTrackOfNoteToAdd = min(iTrackOfNoteEarlier,iTrackOfNoteLater)-1;
|
||||||
goto done_looking_for_track_to_add;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
// try to choose a track just to the right
|
// try to choose a track just to the right
|
||||||
if( max(iTrackOfNoteEarlier,iTrackOfNoteLater)+1 < inout.GetNumTracks() )
|
if( max(iTrackOfNoteEarlier,iTrackOfNoteLater)+1 < inout.GetNumTracks() )
|
||||||
{
|
{
|
||||||
iTrackOfNoteToAdd = max(iTrackOfNoteEarlier,iTrackOfNoteLater)+1;
|
iTrackOfNoteToAdd = max(iTrackOfNoteEarlier,iTrackOfNoteLater)+1;
|
||||||
goto done_looking_for_track_to_add;
|
break;
|
||||||
|
}
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
done_looking_for_track_to_add:
|
|
||||||
inout.SetTapNote(iTrackOfNoteToAdd, iRowToAdd, TAP_ADDITION_TAP);
|
inout.SetTapNote(iTrackOfNoteToAdd, iRowToAdd, TAP_ADDITION_TAP);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user