AO's forming a line from one object to another?
G'day all. I have some dragable objects in my app, and I also have a little 'marker' object. I need a line of these little marker objects from one dragable object to another.
Sounds simple enough, but when the user drags one of the dragable objects to a new position, I need the line of markers to follow - so that they're still forming a line from the origin (point A) to the new destination (point B). I'm afraid I don't have the mathematical knowledge to pull off a stunt like that! [crazy]
Any takers? :)
Re: AO's forming a line from one object to another?
If the line you want is straight then the expression below can be used:
Set Marker X Position to:
X( "1" )+((X( "2" )-X( "1" ))/(NumberofMarkers+1))*Number( "Marker" )
Set Marker Y Position to:
Y( "1" )+((Y( "2" )-Y( "1" ))/(NumberofMarkers+1))*Number( "Marker" )