Jump to content
Search Community

Shadow problem when rotationY from 90 to 0

jasminej test
Moderator Tag

Recommended Posts

I am working on the 3D flip animation.

 

It works well when I set rotationY from 0 to -90(shadow gets narrow and smaller). But if I use the almost the same code, just change the rotationY from 90 to 0, its not working properly, it looks like the shadow is always the same size of the original object, there is no shadow changing process from small to big.

 

Here is the code:

 

mc1.rotationY = 90;

 

tp2 = new TweenProxy3D(mc1);

tp2.rotationY = 90;

 

TweenMax.to(tp2, 2,

{

rotationY:0,

dropShadowFilter:getShadow(80, 75, 0.5)});

 

Anything wrong in code? Thanks!

Link to comment
Share on other sites

I don't see any obvious errors and I tested your code on my end and it seemed to work fine. Maybe I substituted the wrong values in the wrong places. Make sure you've got the latest version of all the classes and if you're still having trouble, please post a sample FLA that can be published to see the issue.

Link to comment
Share on other sites

I don't see the problem - it seems to be acting the way I'd expect based on your code. What do you mean by "the second flip is not the reverse shadow as the first one"? Your code is tweening to a DropShadowFilter that has a distance of 160, an angle of 75, and an alpha of 0.5 and then you do another tween to the exact same values (so the shadow won't appear to change because it's identical to the previous values). See what I mean? Are you wanting the shadow to return back to the object and fade out? Please explain exactly what you think isn't working properly (maybe I'm missing something obvious).

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...