The Creating a metronome through the precise scheduling of sounds with dspTime recipe demonstrated how to create a metronome by scheduling when sounds play using the AudioSource.PlayScheduled(...) method and the AudioSettings.dspTime value. Another situation when we need to precisely schedule audio start times is to ensure a smooth transition from one music track to another, or to ensure simultaneous music tracks play in time together.
In this recipe, we'll create a simple 4-track 140 bpm music manager that starts playing a new sound after a fixed time – the result of which is that the tracks fit together perfectly, and those that overlap do so in synchronicity:
![](https://static.packt-cdn.com/products/9781788471909/graphics/assets/47e24a71-b907-4ddf-9aab-99df2b36f208.png)