Need help with a piece of Flash Actionscript (3.0)

Discussion in 'Graphics & Multimedia' started by Masteroa, Mar 17, 2010.

  1. #1
    Hey,

    In Actionscript 2.0 I used _root.gotoAndStop(2) in a movie clip to go to the second frame after the movie clip was finished playing. I started using AS 3.0 recently, and when I try to use the code it says "Access of undefined property _root" and "The property _root is no longer supported. The property has been removed. The closest equivalent is the Stage".

    Well, I have no idea how to make this work. What is the best piece of script to replace my old one?


    With kind regards,
    Masteroa

    EDIT:

    I found the solution. People who are struggling with the same problem: use MovieClip(root).gotoAndStop(2);
     
    Last edited: Mar 17, 2010
    Masteroa, Mar 17, 2010 IP