Hello, Im still new to adobe animate and I wish I could get assistance on how to solve this problem.
I created three different scene and I want the buttons that I created on Scene 1 be able to navigate to Scene 2 and Scene 3. So I click on the button , choose action script To go to Scene and play and input the scene number I want the button to navigate. However it not working and I keep getting errors. Is there anything I can do to solve this? And what could I miss here?
Really appreciate for any help !
It's probably because your second scene has only one frame and you're using gotoAndPlay. So when you click the button the navigation immediately go forth and back.
To solve this, put a stop method in the first frame of the second scene or use gotoAndStop.
Please let us know.
Thanks! I just put some frames on Scene 2 then run the code Go to Scene and Play. However encountered an error with the lines below :
ArgumentError: Error #2108: Scene Scene 2 was not found.
what could be the problem and is there I should not miss to properly run this?
It's not finding "Scene 2".
Do you mind showing your Scene panel (Shift + F2)?
And how are you testing your movie?
here my scene panel
and I test the scene by clicking Test Scene .
I try to run the "Test" only but it run to other scenes and I still figure out how to put the stop(); since there's many layers and I don't know which frames to put the action script stop();
i put my .fla here in case it not visible in the screenshot . I hope this is okay
Very thankful because you have helped a lot in this!
Here it is:
You need to use the defaul Test command (Ctrl/Cmd + Enter). If you use the Test Scene command, only the current scene will be exported.
I hope it helps.
Omg thanks sm a million thanks ! Im very happy it finally works. Spent hours to figure out this and you really help me on this. Even prepare the other buttons ..Thanks sm! Im really troubling you in this. May this year lots of good things happen to you.
I see the code now and will study on it 🙂
Thought I need to redo things from start since my friends said I should do frames instead of by scene..
Awesome! You're welcome!
Scenes are really not recommended for most cases, but for the level of complexity your project has so far, I think you'll be OK.
Copy link to clipboard
This is pretty cool.