Designing a game for any laptop:
I want to play 2 sounds at the same time! A background music and a sound when pressing on a button!
Using System.Media
won't allow me to play 2 sounds together. For background music, I used the following:
SoundPlayer sp = new SoundPlayer(@"..\..\bin\debug\tribal dance.wav");
sp.Play;
If I played another SoundPlayer
, the previous one stops!
I want the background music to keep playing until the form is closed! And at the same time, if a button is clicked, another sound will be played with the music!
I also tried added the Windows Media Player to the toolbox and used it (allowing me 2 play 2 sounds at same time). That works fine but the path will give an error if I put it (@""..\..\bin\debug\tribal dance.wav");
and I need to put it that way in order to be read by any computer.
Any suggestions?