Overlapping Sound FX create strange noise

Hello everybody!

I guess this is a common issue but I can´t find a tutorial to help me solve this problem.

The thing is that, in my game, at certain points, lots of enemies are destroyed simultaneously, and because of that a lot of destroy Sound FX play at the same time, which makes a strange noise, like the speakers are about to break x)

The way it works is that each enemy has a Prefab with the SFX attached, and it destroys itself once it has ended playing.

If you know how to solve this problem, please help me.

This is the code:

public class SFX_Instantiation : MonoBehaviour
{
    //SFX

    public AudioClip SFX_ToPlay;

    //DELAY SFX

    public float setDelayTime;
    float delayTimer;
    bool hasPlayed;
   
    private AudioSource source;

    int instanceNum;

    private void Awake()
    {
        source = GetComponent<AudioSource>();
    }

    void Start()
    {
        delayTimer = 0;
        hasPlayed = false;
    }
   
    void Update()
    {
        delayTimer += Time.unscaledDeltaTime;

        if (delayTimer >= setDelayTime && !hasPlayed)
        {
            source.PlayOneShot(SFX_ToPlay, volumeScale: 1);

            hasPlayed = true;
        }

        if (delayTimer >= setDelayTime + 0.1f &&
            source.isPlaying == false)
        {
            Destroy(gameObject);
        }
    }
}

I kind of made a work around!:stuck_out_tongue:

Everytime the sound must play it is a collider that is spawn into the scene and enters trigger with the player.
The player is the sound emitter once the trigger has entered. A bool is set so the sound can only be played after x time.

 private void OnTriggerEnter2D(Collider2D collision)
    {      
        if (collision.CompareTag("SFX_EnemyBreak"))
        {
            if (canPlay)
            {
                source.PlayOneShot(SFX_BallBreak);
                canPlayTimer = 0;
                canPlay = false;
            }           
        }
    }