Jump to content
GreenSock

mkg14

object rotates as it appears to move away from viewer in space

Moderator Tag

Recommended Posts

Hello,

 

I am trying to rotate a 2D star three or four consecutive times on its y-axis, and while the rotation is happening the star is moving away from the viewer in space. Essentially the star is larger as the animation begins because it's closer to the viewer, and as it rotates it gets smaller because it's moving away from the viewer in space. Hopefully this makes sense.

 

In terms of creating the rotation effect, I've tried the ShortRotationPlugin, but that causes the star looks a little warped as it rotates.

 

Any help would be appreciated. Thanks in advance!

Link to comment
Share on other sites

Not really sure I understand the question. 

If you can post a very simple sample fla of what you need help with I will take a look. Be sure to zip it first.

 

thanks

Link to comment
Share on other sites

Hi Carl,

 

Thanks for your reply. A former coworker helped me with the solution, but if you have the time do you know of a way to achieve the same effect? See the attached swf file. The solution I was given is very complicated and utilizes an external coding package that my former coworker wrote, otherwise I would also post the native files.

 

Thanks for your help!

 

rotatingStar.swf.zip

Link to comment
Share on other sites

this should give a similar effect

 

import com.greensock.*;
import com.greensock.easing.*;


TweenLite.to(star, 4, {rotationY:900, ease:Linear.easeNone, scaleX:0.2, scaleY:0.2});
TweenLite.to(star, 1, {alpha:0, delay:3});

http://greensock.com/forums-support-files/star3D.html

Link to comment
Share on other sites

Thank you! That works perfectly and the code is very simple and straightforward.

  • Like 1
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.
×