no, but you can fake it. if you add the code below the dotted line to a frame in your flash file, you can use: mc.playF(m,n,fps); /* to play movieclip mc from frame m to frame n at fps frames per second */ --------------------------------------------------- MovieClip.prototype.playF = function(m, n, fps) { if (!var3141592) { var3141592 = 0; playA = new Array(); } this.m = m; this.n = n; this.fps = fps; this.gotoAndStop(this.m); playA[var3141592] = setInterval(playF2, 1000/this.fps, this, var3141592); var3141592++; }; function playF2(mc, ind) { if (mc.m<mc.n) { mc.nextFrame(); } else { mc.prevFrame(); } if (mc._currentFrame == mc.n) { clearInterval(playA[ind]); } updateAfterEvent(); }
Hmm, cant seem to get it to work for me I wanst really sure what to change. I'm kinda a noob anway can u explain what to do with the code a little more please :) Would the fact that I have mx not mx 2004 matter? thx
[quoted text, click to view] "iameatingjam" <webforumsuser@macromedia.com> wrote in message news:d5178v$gvv$1@forums.macromedia.com... > Hmm, cant seem to get it to work for me I wanst really sure what to > change. I'm > kinda a noob anway can u explain what to do with the code a little > more please > :) Would the fact that I have mx not mx 2004 matter? thx
Here's an MX code experiment with adjustable frame rate that I did some time ago... http://members.cox.net/4my5cats/fps/speed.html tralfaz
it only matters that you publish in flash 6 (mx) or better so the setInterval() function is defined. all you need to do is copy and paste the stuff below the dotted line. that code must appear before the function call that uses it, so attach it to frame 1 of the _root timeline and call the code after on frame 1 of the _root timeline or any other frame of the _root timeline or any frame of any other timeline. then to use you must use a movieclips instance name. for example: _root.playF(_root.totalframes,1,12); // to play the _root timeline backwards at 12 fps mc1.playF(33,55,1); // to play mc1 from frame 33 to 55 at 1 fps
Originally posted by: kglad it only matters that you publish in flash 6 (mx) or better so the setInterval() function is defined. all you need to do is copy and paste the stuff below the dotted line. that code must appear before the function call that uses it, so attach it to frame 1 of the _root timeline and call the code after on frame 1 of the _root timeline or any other frame of the _root timeline or any frame of any other timeline. then to use you must use a movieclips instance name. for example: _root.playF(_root.totalframes,1,12); // to play the _root timeline backwards at 12 fps mc1.playF(33,55,1); // to play mc1 from frame 33 to 55 at 1 fps Wahoo, It works! thankyou very much.
Don't see what you're looking for? Try a search.
|