Do you want to pass
SND_ASYNC
This will make PlaySound return immediately, instead of waiting for the sound to finish the game, which in your case will not, because you are looping. IIRC PlaySound allows you to play only one sound at a time, so it's best to look for a sound library, especially if you're making a game.
In conclusion, for your sample to work:
PlaySound("starwars.wav", NULL, SND_ASYNC|SND_FILENAME|SND_LOOP);
See this
source share