Merrill, Jason wrote:
You can project a perpendicular line from the mouse to the
target line and then find the intersection.
uh huh. Still waiting for someone to explain how to do the "constrain"
part. Mike did say, "Using this basic principle you could limit an MC
to a slope based on the _xmouse value." - sounds cool, some code showing
the "limit" part I think is what Eric is after.
right, tbh its probably best to stick to one line of reasoning and follow what
Mike is suggesting as its probably not as complicated :)
actually thinking about it you could just use the dot product to project the
vector from the start point to the mouse onto the drag line then constrain the
result between 0 -> 1. Multiply that number by the drag line vector and add it
to the start point.
not that complicated (not like my previous idea..dont know why i came up with
that..but im sure ive used it before..)
_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com