A Flash Developer Resource Site

Results 1 to 6 of 6

Thread: reversing a movie clip in Mx

  1. #1
    Junior Member
    Join Date
    Mar 2002
    Posts
    11

    reversing a movie clip in Mx

    Hi all,

    I was wondering if anyone knew of a way to reverse a movie clip in flash MX? I basically want the movie clip I have imported into flash to go forward and backward.

    thanks,
    VW

  2. #2
    Flash Video Moderator Wheels's Avatar
    Join Date
    Dec 2000
    Location
    Minneapolis
    Posts
    1,590
    Code:
    button_mc.onPress = function(){
       this.onEnterFrame = function(){
          your_mc.gotoAndStop(_currentframe-1);
          }
    }
    //
    button_mc.onRelease=function(){
       this.onEnterFrame=null;
    }

  3. #3
    Junior Member
    Join Date
    Mar 2002
    Posts
    11

    thanks for the info

    I think I should have been more clear. Now I can use the code you gave me for another project.

    For this current project. The Background is a movie clip and all I need it to do is loop over playing forward and backward.


    Sorry for the confusion

    VW

  4. #4
    Flash Video Moderator Wheels's Avatar
    Join Date
    Dec 2000
    Location
    Minneapolis
    Posts
    1,590
    So on the last frame place this:
    Code:
    stop();
    this.onEnterFrame=function(){
       gotoAndStop(_currentFrame-1);
    }
    On the first frame:
    Code:
    this.onEnterFrame=null;
    play();

  5. #5
    Junior Member
    Join Date
    Mar 2002
    Posts
    11

    Ah! So!

    thanks oh great wise flash one! I take it

    VW

  6. #6
    Flash Video Moderator Wheels's Avatar
    Join Date
    Dec 2000
    Location
    Minneapolis
    Posts
    1,590
    Your welcome!

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