OMG, so that's what it was! I did NOT know this!! I usually work with middleware like FMOD and Wwise, so I always double-check check it loops well, and I use Wav, but for this project my team was sharing the files on discord and so a WAV file was too big and ended up using MP3 and did noticed it has a tiny silence gap at the beginning. I thought it was some export problem with my DAW!
Another thing to loop better is to put the tail of the loop at the beginning of it! I do it on FMOD/Wwise, but we didn't use it because they are not the best for browser builds, so that's another thing that also hurts the music from looping seamlessly. Unfortunately, my team wasn't familiar with how to do it only using Unity because it would need to start with the tail-less loop, and then, after playing the tail-included loop, and then loop that.
Thank you so much for sharing this, this is super useful, gotta learn from my mistakes!
Viewing post in MUSIC FEEDBACK - Music composers and enjoyers click here!
Yeah! I'm glad this helps - it's so easy to overlook some of these things when it comes to game jamming. I think even for my own game I didn't double check my entry/exit cues for a couple loops and messed them up. I believe it was the Wwise 2023.1.17. something update (some point.. I'm not sure) they added the feature where you don't have to have the tail baked into the audio file. Nowadays I just export the audio with the tail and dump it into Wwise and let it due its thing with the entry/exit cues. It makes sense that your team used the loop then tailless loop for the music, and I think it works pretty well! I haven't looked too deeply into audio programming directly into Unity, but there's quite a bit of documentation on building your own audio system in Unity. I suggest you look into them, they're really good reads if you want to nerd out a bit with systems (and breaking your game even more before successfully implementing it).