Question
Easy question for all you ActionScript wizzkids!
I have created the following Actionscript to control a 'Next
Question' button. The idea is that it will choose a random frame to
link to in the current scene (Part2).
nextQ_btn.onRelease = function (){
gotoAndStop("Part2", n);
n = Math.random()*1+3;
}
At the moment, when I click the 'Next Question' button, nothing happens. What's up with my script? My programming knowledge is very limited and this is just about all that it can manage!
The button works when I take out the n variable and put in a frame number manually.
nextQ_btn.onRelease = function (){
gotoAndStop("Part2", n);
n = Math.random()*1+3;
}
At the moment, when I click the 'Next Question' button, nothing happens. What's up with my script? My programming knowledge is very limited and this is just about all that it can manage!
The button works when I take out the n variable and put in a frame number manually.