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

I'm trying to connect two movies with a button

New Here ,
Dec 19, 2019 Dec 19, 2019

I'm a new user to Animate. I've created two animations separately in Animate. One movie that interacts as planned, right up to the point where the user clicks on a button. When that happens, I want movie 1 to stop, and movie 2 to play in its place. I can't seem to make that work.

TOPICS
ActionScript , Code , How to , Import and export
261
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
Explorer ,
Dec 19, 2019 Dec 19, 2019

Hi, Please check below code

root = this;

function myFunction(){

root.movie1.gotoAndStop();

root.movie2.gotoAndPlay();

}

root.mcBtn.addEventListener("click", myFunction);

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
New Here ,
Dec 20, 2019 Dec 20, 2019
LATEST

That might be a good start. I tried, and can't figure out exactly how to use that code in "Actions", or how to make it specific to my movie(s)Screen Shot 2019-12-20 at 1.03.39 PM.png

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