Hi, I don't think pythagoras is involved here.
try: factor = vectorLength/c; coordX = startX + (endX-startX)*factor; coordY = startY + (endY-startY)*factor; greetz JC On Wed, Aug 27, 2008 at 7:00 PM, allandt bik-elliott (thefieldcomic.com) <[EMAIL PROTECTED]> wrote: > hi guys > > I'm doing something wrong in my pythagoras theorum but i'm not seeing what > it is right now > > i'm trying to find out the coordinates for a point on a line. I know the > start x, end x, start y, end y, c length for the line and i know how far > along c the point should be (call it vector length) but i'm a little stumped > as to where to go from there > > the psuedo code for what i've been trying is > > vector x = start x / end x > vector y = start y / end y > train x = (vector x * vector length) + start x > train y = (vector x * vector length) + start y > > I think i have my maths very wrong here - hope you guys can help > > a > _______________________________________________ > Flashcoders mailing list > Flashcoders@chattyfig.figleaf.com > http://chattyfig.figleaf.com/mailman/listinfo/flashcoders > _______________________________________________ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders