Hey all,
So I’ve been tasked with building a news ticker. I’m going to explain it all here and add the code at the bottom. The news ticker progresses through 5 seperate frames and has a small delay between frames. I’ve managed to get it to slowly scroll through each frame using a setInterval. The problem lies with the controls. The user needs to be able to pause/play as well as automatically jump to the next frame. I have a feeling the buttons aren’t working due to the way I have the news ticker built (first thing I tell it to do is “stop” so that probably explains why when the pause button says “stop” nothing happens) but I can’t figure out what to change. Any help/suggestions/directions is most welcome. Thanks in advance!
stop();
i = 1;
function Wait() {
i++;
if (i == 7) {
gotoAndPlay(1);
} else {
nextFrame();
}
}
WaitInt = setInterval(Wait, 8000);
infopause_mc.onRelease = function() {
stop();
infopause_mc._visible = false;
infoplay_mc._visible = true;
}
infoplay_mc.onRelease = function() {
play();
infopause_mc._visible = true;
infoplay_mc._visible = false;
}