Jump to content
Search Community

CirclePath2D

Dave211 test
Moderator Tag

Recommended Posts

Is there any way to have the starting y of a line or rectangle follow a circlePath while the ending y of the line remains locked? In other words, creating a pivot like action such as a engine piston or locomotive wheel piston. 

 

I tried rotating the line with additional TweenMax.To, but it does not create exact results.

 

 

post-17182-0-41888000-1384292128_thumb.p

Link to comment
Share on other sites

I would suggest tracking the position of an object that moving in a circular fashion and then just use the drawing API to draw a line from the position of the object that is rotating to a fixed point. 

 

Here is a tutorial (see the first example) http://www.devx.com/webdev/Article/29882 that shows how to connect two moving objects with a line. In your case it seems one point won't be moving.

Link to comment
Share on other sites

I would suggest tracking the position of an object that moving in a circular fashion and then just use the drawing API to draw a line from the position of the object that is rotating to a fixed point. 

 

Here is a tutorial (see the first example) http://www.devx.com/webdev/Article/29882 that shows how to connect two moving objects with a line. In your case it seems one point won't be moving.

Carl,

 

Thanks for the reply. I'll view the tutorial

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