+ 2
How can I use two functions at the same time?
Example: while (a > 1) { PlaySound(TEXT("1.wav"), NULL, SND_ASYNC; } PlaySound is a Windows.h function, it's used to play .wav sounds. I want to use a song as my game's background music, but I don't know another way to make it play infinitely without using while. But, if I use while, the program just don't keeps executing while the music don't stop. I know there is multi-thread in C++, but I don't know how can I use it. Sorry for the bad English, I'm Brazilian. Thanks!
2 ответов
+ 1
Thanks! I'll search more about it.
+ 1
Just as a note: xDarks code requires C++11.