How to play a background music and make it loop?
Currently I’m using this piece of code to make it play the background music:
XNA-C#
SoundEffect bgEffect;
bgEffect = Content.Load<SoundEffect>("EpicUnease");
bgEffect.Play(0.1f, 0.0f, 0.0f);
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
If this is not XNA, you can reference
System.Mediaand do this:For XNA you would do something like this:
For more information, check out this msdn article: http://msdn.microsoft.com/en-us/library/dd940203.aspx