Forum Discussion
Background Music keep playing.
- 2 years ago
Hi everyone!
Good news! I'm happy to share that we just released Storyline 360 (Build 3.81.31200.0), which includes a feature to control the background audio for each slide using triggers to play, pause, or stop the playlist.
This was highly requested, so we hope it serves you in your course creation! If you run into any snags, don't hesitate to contact our team in a support case.
I came up with a solution to pause the background audio for a single slide, and it could potentially be used to end the background audio at the end of the last slide in a module. Not sure about fade out, but you could stop it.
Accessibility controls need to be enabled in the player for this to work.
If you do not want to actually show the accessibility controls:
On the first slide of the course, execute javascript when timeline starts.var link = document.getElementById('settings');
link.style.display = 'none';
link.style.visibility = 'hidden';
On the slide that you want to turn the background music off, execute javascript when timeline starts.var thisVariable = GetPlayer().GetVar("musicOn");
if (thisVariable == 1) {
document.getElementById("backgroundAudio-switch").click();
GetPlayer().SetVar("musicOn",0);
}
On the slide before and after the "turn it off" slide, execute javascript when timeline startsvar thisVariable = GetPlayer().GetVar("musicOn");
if (thisVariable == 0) {
document.getElementById("backgroundAudio-switch").click();
GetPlayer().SetVar("musicOn",1);
}
(this is different than the one above. Copy it very carefully.)
Create a new number variable in the project, name it musicOn
. Default value 1.