public void PlaySound() { using (var player = new SoundPlayer(SoundLibrary.GetSoundName())) { player.PlaySync(); } _thread.Join(); }
public void Play() { SoundLibrary.GetSoundName(); _thread = new Thread(PlaySound); _thread.Start(); }