Voice stealing when the same note is pressed

How about overriding the Synthesiser::noteOn method so it does roughly the same thing except removes the following lines of code:

            // If hitting a note that's still ringing, stop it first (it could be
        // still playing because of the sustain or sostenuto pedal).
        for (auto* voice : voices)
            if (voice->getCurrentlyPlayingNote() == midiNoteNumber && voice->isPlayingChannel (midiChannel))
                stopVoice (voice, 1.0f, true);
1 Like