Go Back   CodingForums.com > :: Client side development > Flash & ActionScript

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 09-15-2011, 04:34 AM   PM User | #1
Varrant
New to the CF scene

 
Join Date: Jul 2011
Location: Chicago, IL
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Varrant is an unknown quantity at this point
Using AS 3 to jump to new frame after 2 MC's have completed

Hello,
I'm rather new to coding and am having trouble on an animation I am working on. I'm using A.S. 3 and I'm trying to make Flash jump to a following frame after 2 separate selectable MC animations have completed. I can get it to work for one(by just adding the gotoAndPlay to the end of the MC itself), but if it's the first MC clicked it would jump ahead without waiting for the other to be clicked.
The instance names of the MC's are "redOff" and "orangeOff". I tried this but it doesn't work for anything, although I don't get any errors either.

This is on my main timeline:

Code:
 if (redOff.currentFrame == 30 && orangeOff.currentFrame == 56) {
          gotoAndPlay("five");
}
Where 30 and 56 are the last frame of the MC respectively, and "five" is the frame label on the main timeline.
I'm thinking I have to have link the MC's to the main timeline somehow, but too new to know. Any help would be greatly appreciated. I have also tried adding an eventlistener for a complete event, but couldn't get that to work either.
Thank You
Varrant is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 03:32 AM.


Advertisement
Log in to turn off these ads.