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

How do I make my button continue the rest of an animation after the button starts it?

New Here ,
Oct 17, 2023 Oct 17, 2023

I'm working on a class project right now for a small 2D interactive game. I have an interactive button that makes the character jump over the hole but I can't get the rest of the classic tween of them skating after it to continue playing. Is it something in the code that it is causing it to do that? This is what I have right now. Thank you for the help.

 

this.stop();

this.jumpbtn.addEventListener("click", function (jumpbtn)
{
this.gotoAndPlay(40);
}.bind(this));

 

 

398
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
Community Expert ,
Oct 17, 2023 Oct 17, 2023

Hi.

 

Are the jumping and skating animations in the same timeline?

 

Please let us know.

 

Regards,

JC

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 ,
Oct 17, 2023 Oct 17, 2023

Hi! I'm not sure. I think they are. I added a photo of what it looks like. Layer 4 is the jumping tween.

Keashy13_0-1697586774758.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
Community Expert ,
Oct 17, 2023 Oct 17, 2023

Thanks.

 

If you press Enter/Return in this timeline you can see your character on stage jumping and then skating?

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 ,
Oct 17, 2023 Oct 17, 2023

I have a button that pops up that the user needs to click to trigger the motion tween

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
Community Expert ,
Oct 17, 2023 Oct 17, 2023

I mean while you're editing in Animate. What happens if you press the Play button?

 

image.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
New Here ,
Oct 17, 2023 Oct 17, 2023

When I hit the play button it plays every animation in sync

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
Community Expert ,
Oct 17, 2023 Oct 17, 2023

Do you mind sharing your file by uploading it to a file sharing service (Creative Cloud, Google Drive, Dropbox, WeTransfer...) and then pasting the link here?

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 ,
Oct 17, 2023 Oct 17, 2023
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
Community Expert ,
Oct 17, 2023 Oct 17, 2023
LATEST

Thanks.

 

You have a stop call in frame 40 (41). Just remove it.

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