I loaded two songs in the game, but you can only hear the first song that plays, when you try to change the song, the first song starts to play again.
Song menu,inGame;
protected override void LoadContent()
{
spriteBatch = new SpriteBatch(GraphicsDevice);
menu = Content.Load<Song>("Music/menu");
inGame = Content.Load<Song>("Music/level1");
}
protected override void Update(GameTime gameTime)
{
if (GamePad.GetState(PlayerIndex.One).Buttons.Back == ButtonState.Pressed || Keyboard.GetState().IsKeyDown(Keys.Escape))
MediaPlayer.Stop();
if (GamePad.GetState(PlayerIndex.One).Buttons.A == ButtonState.Pressed)
MediaPlayer.Play(menu);
if (GamePad.GetState(PlayerIndex.One).Buttons.B == ButtonState.Pressed)
MediaPlayer.Play(inGame);
base.Update(gameTime);
}