-
I thought this was an easy thing to do but I'm lost. can somebody help?!
I have 10 buttons on a frame (eg frame 1) on the main timeline. If the user clicks one of the buttons, the timeline would play (and travel along the timeline) and then stop on a certain frame (eg frame 20). each button will play and stop on a different frame.
How do i do this?
And dare i ask, if it can go backwards too?
thanks
-
okay, say every button plays ten frames from the last, ex: button one goes up to frame 10, button two to frame twenty and so on. give every button this code:
on(release){
play();
var which_button=(whichever button it is)
}
so button one would be:
on(release){
play();
which_button=1;
}
and button two would be:
on(release){
play();
which_button=2;
}
and so forth
on every ten frames (or whichever frames you want it to stop at) write a code detecting which button was pressed. So frame 10, 20, 30 etc... would have this code:
//Frame 10 Code;
//Detects if button one was pressed then stop
if(which_button==1){
stop();
}
//Frame 20 Code;
//Detects if button two was pressed then stop
if(which_button==2){
stop();
}
//Frame 30 Code;
//Detects if button three was pressed then stop
if(which_button==3){
stop();
}
and it goes on like that.
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
|