Turning off Math.random() after one use? Hi, I currently have a 5 product banner with a randomizer and next/previous buttons. When it launches, it loads one of those frames using the Math.random() command. However, it does it again when either of the next & previous buttons are clicked. Is there any way for me to turn that off after it's been executed once at launch? For example:HTML randomly loads a frame from 1 to 5 (E.g. Frame 3).I'd like the next button to continue in sequential order from there: 3, 4, 5, 1, 2, 3 HTML randomly loads Frame 4.The next button continues sequetionally when clicked: 4,5,1,2,3,4 Here's what I have in Frame 0: var nextFrame = 1;
var totalFrames = 5;
var randomFrame = Math.random()*5;
var lastPicked = randomFrame - 1;
this.next.addEventListener("click", fl_ClickToGoToAndStopAtFrame.bind(this));
function fl_ClickToGoToAndStopAtFrame()
{
nextFrame++;
if (nextFrame > totalFrames) {
nextFrame = 1;
}
this.gotoAndStop(nextFrame);
}
this.previous.addEventListener("click"