Solution of the audio loop with source code

Is there a way to loop without being affected by clearing the screen? Here is the revised source code.

[[start]]:
squiffy.ui.write('

[[stop audio]]:
document.getElementById("ogg-audio").pause();
document.getElementById("ogg-audio").currentTime=0;
[[play audio]] [[change src]] [[clear the screen]]

[[play audio]]:
document.getElementById("ogg-audio").play();
[[stop audio]] [[change src]] [[clear the screen]]

[[change src]]:
document.getElementById("ogg-audio").loop = false;
document.getElementById("ogg-audio").src = "http://media.textadventures.co.uk/games/6qJLyNxxokqakBDCUdwE2Q/snd_effect.ogg";

[[loop audio]]:
document.getElementById("ogg-audio").loop = true;

[[stop audio]] [[change src]] [[clear the screen]]

[[clear the screen]]:
@clear


This topic is now closed. Topics are closed after 180 days of inactivity.

Support

Forums