Solved

**Urgent** Navigation

Posted on 2004-10-13
7
155 Views
Last Modified: 2010-04-03
When the user clicks a link from the navigation, it will load a movie into the STAGE, to the right of the NAVIGATION.  Once the movie is done playing, a button will appear in the movie that will say " Click here to play the next section".  When/if the user clicks that button, it will UNLOAD the current movie and then LOAD the new movie.  But it also has to HIGHLIGHT the next link in the NAVIGATION, this is the part that I am stuck on.

All of my code is on the individual buttons that are within a few MC's, I am assigning a GLOBAL VARIABLE.  If anyone knows of a different way to accomplish this, I am all ears.  

Also if you have any other questions, please psot them and I will respond ASAP, (usually within minutes).


http://www.jasonkoscho.com

Thanks
MTB007
0
Comment
Question by:mtb007
  • 4
  • 3
7 Comments
 
LVL 4

Expert Comment

by:onFocus
ID: 12302431
Hello!
I think that you should give instance names for your movieClips:

In test2.fla:
For Navigation BackgroundMOV give instance name: nav_mc
For Inner Animation MOV give instance name: inner_mc

Open test.fla
write the following script for your Next button
on(release){
      _parent.nav_mc.inner_mc.navBTN.gotoAndStop("navOff");
      _parent.nav_mc.inner_mc.tipsBTN.gotoAndStop("tipsOn");
}

0
 
LVL 1

Author Comment

by:mtb007
ID: 12318757
The problem with doing that is the Rollover State.  If I control it this way, when the button is in the ON STATE, and then you rollvoer it, it will automatically go to the ROLLOFF STATE.  Does this make sence?  
0
 
LVL 4

Accepted Solution

by:
onFocus earned 500 total points
ID: 12321747
Hi
You should use _root instead _global for your currentStep variable.
So:
1. For your Navigation button:
on (rollOut) {
        //if(_global.currentStep!=1)_parent.navBTN.gotoAndPlay("navOff");
      if(_root.currentStep!=1)_parent.navBTN.gotoAndPlay("navOff");
}
on (release) {
      _root.currentStep=1;
      //_global.currentStep=1;
      ...
}


2. For your Tips&tricks button:
on (rollOut) {
        //if(_global.currentStep!=2)_parent.tipsBTN.gotoAndPlay("tipsOff");
      if(_root.currentStep!=2)_parent.tipsBTN.gotoAndPlay("tipsOff");      
}
on (release) {
        //_global.currentStep=2;
      _root.currentStep=2;
      ...
}

3. The same for Help button

4. Next button in Test.fla:
on(release){
      _parent.nav_mc.inner_mc.navBTN.gotoAndStop("navOff");
      _parent.nav_mc.inner_mc.tipsBTN.gotoAndStop("tipsOn");
      _root.currentStep=2;
}
0
Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

 
LVL 1

Author Comment

by:mtb007
ID: 12402773
I tried that, and it does the same thing.  It will load the next movie, but the link state does not change. It will only change when you roll over it.  It then resets and shows the correct state.
0
 
LVL 4

Expert Comment

by:onFocus
ID: 12425691
I don't know why it doesn't work for you.
With the above script I haven't problems with the over state of buttons.
If you want download my version:

www.venomgun.hit.bg/navigation_02.zip
0
 
LVL 1

Author Comment

by:mtb007
ID: 12426025
Yeah, im not sure what is different.  I looked at what you have and it is EXACTLY what i have.  Im going to play around with it tongiht.  Ill get back to you on it though.

Thanks
Again.
0
 
LVL 1

Author Comment

by:mtb007
ID: 12886525
Sorry it took so long, I forgot about this. ;) Thanks!
0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

Introduction This article is primarily concerned with ActionScript 3 and generally specific to AVM2.  Most suggestions would apply to ActionScript 2 as well, and I've noted those tips that differ between AS2 and AS3. With the advent of ActionS…
I come across a lot of question about how to access things in the document class from a movieclip, or accessing something from a movieclip in the document class. It took me a while to figure this out but once I did it makes life so much easier. …
The goal of the tutorial is to teach the user how to how to record live broadcast.
The goal of the tutorial is to teach the user what frame rate is, how to control it and what effect it has on the video.

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now