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

How do you link buttons to different scenes ?

Guest
Feb 04, 2013 Feb 04, 2013

Tried to link it and its not working just coming up with errors ?

Any advice ?

TOPICS
ActionScript
439
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

correct answers 1 Correct answer

LEGEND , Feb 04, 2013 Feb 04, 2013

Do you have some reference that told you to use "..." in your code?  Try...

stop();

btnarrow.addEventListener(MouseEvent.MOUSE_DOWN, mouseDownHandler);

function mouseDownHandler(event:MouseEvent):void {

   gotoAndStop(FRAME, "Contents");

}

and FRAME needs to be a variable that either identifies a frame number or a frame label

Translate
LEGEND ,
Feb 04, 2013 Feb 04, 2013

Show the code you are trying to use that is not working.  That will make it easier to see what you tried and why it might not be working.  Also, if you get errors, include the entire error message(s) in your posting.

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
Guest
Feb 04, 2013 Feb 04, 2013

stop();btnarrow.addEventListener(Mouse… mouseDownHandler);function mouseDownHandler(event:MouseEvent):void {

gotoAndStop(FRAME, "Contents");

}

Open Scene, Layer 'actions', Frame 1, Line 31093: Syntax error.

Open Scene, Layer 'actions', Frame 1, Line 31084: Syntax error: expecting rightparen before mouseDownHandler.

Contents, Layer 'Actions', Frame 2, Line 11093: Syntax error.

Contents, Layer 'Actions', Frame 2, Line 11084: Syntax error: expecting rightparen before mouseDownHandler.
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 ,
Feb 04, 2013 Feb 04, 2013
LATEST

Do you have some reference that told you to use "..." in your code?  Try...

stop();

btnarrow.addEventListener(MouseEvent.MOUSE_DOWN, mouseDownHandler);

function mouseDownHandler(event:MouseEvent):void {

   gotoAndStop(FRAME, "Contents");

}

and FRAME needs to be a variable that either identifies a frame number or a frame label

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