nice okay i got that working, but now i have another problem..
im using the same method of lining up cars to lines in my game for the admin cars, so what i did was precalculate an array of angles so that as the ai car moved along and hit certain points it would take up a new angle. the track is "circle" which is made up of lines, and is drawn as a polygon, so if u can imagine that.. lol. the problem here is that if a line has an opposite slope to another line, then the angle will be the same.
so to draw
the angle here is say 30 (degrees) and the car should in theory be facing at (x2,y2) and accelerate that way when it accelerates
here the angle works out (if x1 and y1 become x2 and y2 respectively) to the same as the above example, so im wondering how to get what that angle would be if u took into consideration that the begining angle is zero.
or maybe if i just added that angle value to what ever is was before it hit that line?
thanks alot for any comments or whatever about this.