Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

ArgumentError: Error #2108: Scene blue was not found.

Contributor ,
Mar 03, 2016 Mar 03, 2016

i want to go From main timeline to symbol timeline

movieClip_1.addEventListener(MouseEvent.CLICK, fl_ClickToGoToScene);

function fl_ClickToGoToScene(event:MouseEvent):void

{

  MovieClip(this.root).gotoAndPlay(1, "blue");

}

exists.jpg

TOPICS
ActionScript
936
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Mar 03, 2016 Mar 03, 2016

You don't want to use the name of the current scene when you use gotoAndPlay() or gotoAndStop(). Try:

MovieClip(this.root).gotoAndPlay(1);

Using scenes is a very bad practice. It is a remnant from the very early versions of Flash.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Mar 03, 2016 Mar 03, 2016

I replied too quickly. You are editing a symbol, not a scene. In your example "blue" is a movieClip. If that is a movieClip with frames and you have it stopped on a frame and you want it to play through its timeline, then you should be using:

blue.play();

It's difficult to tell, the timeline shows the Library name for the movieClip, but not the instance name. You need to use the instance name, without quotation marks, followed by the command play(); to play the movieClip.

In any case, don't use scenes.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Contributor ,
Mar 03, 2016 Mar 03, 2016

I tried to target a movieclip from inside another movieclip called ball and these dont work!

stop();

movieClip_1.addEventListener(MouseEvent.CLICK, fl_ClickToGoToScene);

function fl_ClickToGoToScene(event:MouseEvent):void

{

MovieClip(root).ballmc.play();

}

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Contributor ,
Mar 03, 2016 Mar 03, 2016

i want gotoandplay symbol timeline from main time line

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Mar 04, 2016 Mar 04, 2016
LATEST

If movieClip_1 and ballmc are both on the same timeline then something like this should work:

movieClip_1.addEventListener(MouseEvent.CLICK, fl_ClickToGoToScene);

function fl_ClickToGoToScene(event:MouseEvent):void

{

this.ballmc.play();

}

MovieClip(root) is not a valid reference in javascript. You can use this.parent to move up a level or exportRoot to get to the base level.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines