Skip to main content
Participant
April 25, 2018
Question

gotoandStop gotoAndPlay inside nested movieclip timeline

  • April 25, 2018
  • 2 replies
  • 1310 views

Hi all

Since adobe flash cc to adobe animate 2018 , there isn't method to go to specific frame by type code inside Movieclip timeline

if i have MovieClip named inMC inside Movieclip named mainMC

in inMC I have 10 frames of tween

in mainMC I have 10 frames  in frame 5, i add script

this.stop();

this.inMC.gotoAndStop(4);

the inMC still played, I want to note I can hide inMC if I typed  this.inMC.visible=false;!!!!

if I put gotoAndStop code in event click , Movieclip will stop , how to add this code to run immediately on timeline code

    This topic has been closed for replies.

    2 replies

    Colin Holgate
    Inspiring
    April 25, 2018

    It would happen if you do that as soon as you get to the main timeline frame, because unlike Flash Player 10 and later, the movieclip doesn't yet exist. You might have had the same problem in Flash Player 9.

    A different approach would be to use a window variable. This would work:

    inMCframe = 4; //in the main timeline

    this.gotoAndStop(inMCframe);//in the timeline of inMC

    mhdeyaAuthor
    Participant
    April 25, 2018

    How inMC doesn't yet exist? ,if I traced it by console I can find movieclip, also I can do transformation and visible and all properties ???

    if I used last version of createjs framework from EASElJS , the movie stopped

    why adobe use 2015.11.26 version not last version of createJS

    Colin Holgate
    Inspiring
    April 25, 2018

    inMC exists enough to set its location and visibility, but its internal timeline isn't initialized yet.

    The later version of CreateJS includes some features that Animate doesn't yet support. That may be why they're stuck on the 2015 version.

    kglad
    Community Expert
    Community Expert
    April 25, 2018

    is this an html5/canvas project?

    what happens to inMC when your mainMC reaches its frame 5?

    mhdeyaAuthor
    Participant
    April 25, 2018

    yes it's html5/canvas

    inMC will play in loop