diff --git a/stepmania/src/NoteData.cpp b/stepmania/src/NoteData.cpp index f7d2463eac..36c646330d 100644 --- a/stepmania/src/NoteData.cpp +++ b/stepmania/src/NoteData.cpp @@ -415,8 +415,8 @@ int NoteData::GetNumTapNotes( float fStartBeat, float fEndBeat ) const int iEndIndex = BeatToNoteRow( fEndBeat ); /* Clamp to known-good ranges. */ - iStartIndex = clamp( iStartIndex, 0, GetMaxRow()-1 ); - iEndIndex = clamp( iEndIndex, 0, GetMaxRow()-1 ); + iStartIndex = max( iStartIndex, 0 ); + iEndIndex = min( iEndIndex, GetMaxRow()-1 ); for( int t=0; t