Jump to content
Search Community

CirclePath2D - dynamically adding/remove?

swiftmend test
Moderator Tag

Recommended Posts

Is there a simple way to add/remove elements from a CirclePath2D motion path to dynamically increase/decrease the movie clips on the path?

 

I'd basically like only a quarter of the circle visible, which is populated by an array of movie clips - 3-4 would be on-screen at any time, when they go off-screen the next object is placed at the beginning, etc.

 

I've thrown together a basic demo, which is adding the elements to the circle, which goes back/forth as I'd like - but what I need is the ability to support an array of about 30 of these movie clips, with them being added/removed as they hit the borders of that white line.

 

Any tips? I've spent a few hours on it and have not been able to solve it.

 

fla: http://db.tt/2VDygRQ

Link to comment
Share on other sites

Sorry for the delayed response - I was traveling all last week.

 

Anyway, it sounds like you're just trying to tween objects between 0 and 0.25 progress on the CirclePath2D, right? (or maybe between 0.25 and 0.5 or whatever). I wasn't able to download your file because it looks like you deleted it (feel free to post it again so I can review it). In any case, you should be able to just create a PathFollower for each object and then tween its progress value however you please. Make sense?

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