A Flash Developer Resource Site

Results 1 to 4 of 4

Thread: Button Script

  1. #1
    Junior Member
    Join Date
    Jan 2004
    Location
    Finland
    Posts
    5

    Button Script

    I am using Flash MX 2004. I have created a movie that has a movie clip on the first frame which plays through and stops. There is a button in the movie clip that says "Enter" and I would like to have it go to the next part of the movie beginning on frame 2 but can't seem to get it to work. I've tried action script for "next frame" and "go to and play" but nothing seems to happen. What am I missing? Or should I count the number of frames in the "movie clip" and add that to the whole movie? Its confusing. Any help would be appreciated. Thanks in advance. The movie .fla is posted.

  2. #2
    eveningtidemusic.com tristankelley's Avatar
    Join Date
    Jul 2003
    Posts
    377
    Since you are calling on the main timeline from inside an MC you need to use '_root' to define your path.

    something like

    Code:
    on (release) {
    	_root.gotoAndPlay(2);
    }

  3. #3
    Member
    Join Date
    Jan 2004
    Posts
    33
    Maybe its a problem with your paths? You want the root timeline to go to frame 2?

    code:
    on(release){
    _root.gotoAndPlay(2)
    }


  4. #4
    Junior Member
    Join Date
    Jan 2004
    Location
    Finland
    Posts
    5

    THANKS!!!

    That did the trick and I learned something new. I really appreciate the help!!!

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