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

Animating simbol on mask layer

New Here ,
Nov 19, 2022 Nov 19, 2022

Why isn't the symbol animated if I mask the layer on which the symbol is located?

1.4K
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

Community Expert , Nov 19, 2022 Nov 19, 2022

clear your cache.  here's that example: https://www.kglad.com/Files/forums/test.html

 

using this code:

 

this.stop();
this.c.addEventListener("click",f.bind(this));

function f(e){
this.s.play();
}

 

 

if you still have trouble, upload your fla to a file server and post a link

Translate
Community Expert ,
Nov 19, 2022 Nov 19, 2022

masking won't change the animation in other layers, masked or not.

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 ,
Nov 19, 2022 Nov 19, 2022

I turned the square into a symbol that changes shape when the button is clicked.
But after I put the "Mask" option on the layer where the square is, there is no animation after clicking on the button.
Why, who knows?

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 ,
Nov 19, 2022 Nov 19, 2022

your mask is interfering with the mouse interaction, not the animation 

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 ,
Nov 19, 2022 Nov 19, 2022

Okay,
How do I make the symbol start playing an animation as a mask that changes size?

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 ,
Nov 19, 2022 Nov 19, 2022

To clarify: to make the symbol start playing animation as a mask - after the mouse clicks on a separate button.

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 ,
Nov 19, 2022 Nov 19, 2022

i don't know how you could be having a problem.  here's a masked movieclip (s) that triggers the main timeline to play when it's clicked.

 

https://www.kglad.com/Files/forums/test.html

 

// this is the code

this.stop();
this.s.addEventListener("click",f.bind(this));

function f(e){
this.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
New Here ,
Nov 19, 2022 Nov 19, 2022

Thanks for the example!
But I have a different problem:
Clicking on the button (separate from the symbol) should trigger a change in the symbol's shape. And this doesn't happen as soon as I mask the layer on which the symbol is located.

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 ,
Nov 19, 2022 Nov 19, 2022

clear your cache.  here's that example: https://www.kglad.com/Files/forums/test.html

 

using this code:

 

this.stop();
this.c.addEventListener("click",f.bind(this));

function f(e){
this.s.play();
}

 

 

if you still have trouble, upload your fla to a file server and post a link

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 ,
Nov 19, 2022 Nov 19, 2022

In this video I explain how to use a graphic symbol as a mask.

https://youtu.be/V_svCnCa9v4


____
2D vector animator since 2000 & PhD
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 ,
Nov 21, 2022 Nov 21, 2022
LATEST

Show us a screenshot so we can better understand what you're doing. 

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