-
[CS3] Rewinding only 30 frames?
Hey what would be the best solution in rewinding the main timeline only 30 frames?
so far ive used:
rewindbutton.onRelease = function () {
onEnterFrame = function () {
prevframe ();
}
}
but that makes it rewind all the way back to the beginning of the whole timeline. I would like it to rewind only 30 frames and then stop.
Thanks! (AS2/3, anything goes)
Last edited by Noisepurge; 07-22-2008 at 05:30 AM.
-
Working On An Online RPG
i myself have never used prevframe... but my guess would be to get rid of the onenterframe = function() part to make it only go back one frame, and put a 30 in the prevframe brackets which might make it go back 30... although its untested and i am not sure
otherwise, you could write:
Code:
rewindbutton.onRelease = function() {
count = 0;
onEnterFrame = function() {
if (count <= 30) {
prevframe();
count++;
}
}
}
-
Thanks for the fast reply, and it does work like a charm! Rewinding a timeline in flash seems to be quite a chore, how come it doesn't support a simple "rewind" or "playback" command
Thanks again!
-
Small point, but in both cases, you should delete onEnterFrame; when you finish to prevent the function running indefinitely.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|