polyglot
Programmer
- Nov 28, 2007
- 11
Hello-
I have a question. I am new to programming, Flash, and actionscript - so bear with me. I am trying to create a game with 3 different levels of difficulty. To do so, I need to create a movie clip with three different frame rates (essentially - three different movie clips). I got a great script somewhere to enable me to do this. It goes in the first frame of the movie clip whose frame rate is to be adjusted. Here it is:
function timelineFaster() {
nextFrame();
updateAfterEvent();
}
var tweenFaster:Number = setInterval(timelineFaster, 42);
(The "42" in the last line can be adjusted to make the timeline go faster or slower). Anyway - my question/problem is this: When I put this code in the first frame of my movie clip, the movie clip no longer loops. Can anyone send me the code I need to add to this frame that will allow the movie clip to loop? I believe this is probably an easy fix, but as I said - I am a babe in the woods when it comes to Flash, actionscript, and programming. I hope someone can post/send the code I need to force my movie clip to loop. Thanks!
Monica
I have a question. I am new to programming, Flash, and actionscript - so bear with me. I am trying to create a game with 3 different levels of difficulty. To do so, I need to create a movie clip with three different frame rates (essentially - three different movie clips). I got a great script somewhere to enable me to do this. It goes in the first frame of the movie clip whose frame rate is to be adjusted. Here it is:
function timelineFaster() {
nextFrame();
updateAfterEvent();
}
var tweenFaster:Number = setInterval(timelineFaster, 42);
(The "42" in the last line can be adjusted to make the timeline go faster or slower). Anyway - my question/problem is this: When I put this code in the first frame of my movie clip, the movie clip no longer loops. Can anyone send me the code I need to add to this frame that will allow the movie clip to loop? I believe this is probably an easy fix, but as I said - I am a babe in the woods when it comes to Flash, actionscript, and programming. I hope someone can post/send the code I need to force my movie clip to loop. Thanks!
Monica