1 Reply Latest reply on Dec 8, 2009 11:57 AM by frist44

    Navigation back to a click point

    frist44

      I have a frame that has some things to click on. If you click on button1, you go to frame1. If you click button2, you go to frame 2.

       

      The problem is that button1 and button2 are on a few different frames, and when you exit frame 1 or frame 2, I don't have a way to know where to go back to.

       

      Here is my click code:

       

      _root.circle1.onPress = function(){
          _root.gotoAndStop("planning");
         
          if (_root.planning._currentframe != 1) {
              _root.planning.onEnterFrame = function(){
                   if(_root.planning._currentframe != 1){
                         _root.planning.prevFrame();
                   } else {
                         delete _root.planning.onEnterFrame;
                   }
              }
          }
          else {
              _root.planning.play();
          }
      }

       

      Here is my return from button1 code:

       

      stop();

       

      _root.ad.close.onPress = function(){
          if (_root.ad._currentframe != 1) {
              _root.ad.onEnterFrame = function(){
                   if(_root.ad._currentframe != 1){
                         _root.ad.prevFrame();
                   } else {
                         delete _root.ad.onEnterFrame;
                         _root.gotoAndStop("??????");   
                   }
              }       
          }
      }