It is possible in AutoPlay Media Studio to have music playing in the background of your application.
To allow the user to turn off this music if they wish:
1. Create a button.
2. On this button's On Click event, insert the following code:
This example assumes the background music in your application is playing in channel CHANNEL_BACKGROUND. When the user clicks the button, the background music will pause if it was playing, and play if it was paused.
To allow the user to turn off this music if they wish:
1. Create a button.
2. On this button's On Click event, insert the following code:
Code:
Audio.TogglePlay(CHANNEL_BACKGROUND);