I have two sound files:
- Sound A is an 18-second intro designed to play once.
- Sound B is a 1-minute loop track
I would like to play sound A once, then as soon as sound A is finished, immediately start Sound B and continue the Sound B cycle until I stop it. This is supposed to be cyclical urban music in an RPG.
I tried to do this in code using only SoundEffect, but there is a tiny but noticeable gap between the end of sound A and the start of sound B. Even if I put the control code while watching Sound A SoundEffectInstance.State in update (), I could not run Sound B is exactly when Sound A ends so that it is seamless.
I would prefer to use SoundEffect because I can upload WMA files rather than get stuck with WAV in XACT.
source
share