Mabye someone over here can explain to me what am i doing wrong...This is after reading a lot of articles over the net and doing what say said over there...and not working....
My problem is that i am developing a nice little game with a background music and explosion sound, for the explosion i know i need to use threads or my music stops when the first one happens, I am using threads but it is stops....
Here is my code....it is very simple, but i guess that there is a mistake over there....
This is the GLOBAL decleration in the *.h file:
UINT CMonstersThread(LPVOID Param);
This is the thread function in the *.cpp file:
UINT CMonstersThread(LPVOID Param) { PlaySoundA("sounds\expl06.wav", NULL, SND_ASYNC); AfxEndThread(0); return FALSE; }
This is the call for the thread every time a "friendly" get hit, (in the same *.cpp file):
AfxBeginThread(CMonstersThread,NULL,THREAD_PRIORITY_NORMAL,0,0,NULL);
That is all my code.....And from what i got over the web, It sould work...but isn't doing what it sould....
10x in advance,
Erez