private void OnBeat(int beatIndex) { // If the step is enabled, play a note if (m_noteIndex == step && m_bIsOn) { m_rowNotes.PlayRow(row, step); } // increment the note index m_noteIndex = (m_noteIndex + 1) % 16; }