Jump to content
Search Community

GSAP with Animate CC 2019 - scale and scaleX/scaleY not working?

Yes! test
Moderator Tag

Warning: Please note

This thread was started before GSAP 3 was released. Some information, especially the syntax, may be out of date for GSAP 3. Please see the GSAP 3 migration guide and release notes for more information about how to update the code to GSAP 3's syntax. 

Recommended Posts

I'm unable to get any scaling to happen using GSAP in an html5 environment in Animate CC 2019. 

I'm trying the following:  TweenMax.to(this.s1, 2.5, {delay: 0.25, scale:2, alpha:1});
Alpha works correctly, but not scale, it does not scale.

Also scaleX and scale Y is not working, I tried the following:  TweenMax.to(this.s1, 2.5, {delay: 0.25, scaleX:2, scaleY:2, alpha:1});  Again the alpha works, but the element does not scale. 

How do I get GSAP to scale movieclips in Animate CC 2019? 
 

Thanks.

Link to comment
Share on other sites

your little star is in a big square. the registration point is like 300 pixels to the left of the star shape.

the scale gets applied from the top left corner of that big square. the star gets moved offstage very quickly during the scale.

 

change your stage to 800px wide and use this code:

TweenMax.to(this.s1, 2.5, {delay: d+=0.25, scaleX:2, scaleY:2, alpha:1});
 

you'll see it works fine. 

 

 

 

you should edit your symbol so that the star doesn't have all those wasted empty pixels around it and set the transformation point accordingly.

 

https://prnt.sc/pptdjd

 

also easeljs items do not have a scale property.

 

  • Like 2
Link to comment
Share on other sites

Thank you. Excellent answer. There's a reason for the images / pngs / mc's being the way they are with all the empty space.  I just changed the registration point and now they're working fine. Much appreciated.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...