A Flash Developer Resource Site

Results 1 to 2 of 2

Thread: what am I doing wrong?

  1. #1
    Junior Member
    Join Date
    Jun 2000
    Posts
    24

    what am I doing wrong?

    Got a weird problem..

    I have a button inside a movie clip in the first scene, the scene name is called "test"... when you press that button, I want the root movie to go to scene 2 which is named "mainmovie"... I thought the actionscript would be:

    on (release) {
    _root.gotoAndStop("mainmovie", 1);
    }

    But it's not working.. any idea what I'm doing wrong..

    I did find a work around to it... you need to tell the button to go to the _root scene that it's in.. tell it to go to frame 5 for instance.. and in frame 5 there's an actionscript there to go to scene "mainmovie" of the root.. shehshhh.. is there any direct way to a second scene of the main timeline from a button inside a movie clip? Let me know what's up! Thanks.

    Draconis

  2. #2
    Junior Member
    Join Date
    Oct 2002
    Posts
    9
    I think your script will need to tell the _root to switch scenes.. to do this try the following script:

    on (release) {
    tellTarget ("_root") {
    gotoAndStop ("mainmovie", 1);
    }
    }

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center