Original Post
Hi Ive some code that looks like this it is collision code for balls: // x, y = length between centers // xv0, xv0, yv1, yv1 = velocity vectors for ball0 and ball1 length = BIOS_Sqrt(x*x+y*y); normal_x = x / length; normal_y = y / length; a = DotProduct(normal_x, normal_y, xDiff, yDiff); xn = normal_x * a; yn = normal_y * a; xv0 += xn; yv0 += yn; xv1 -= xn; yv1 -= yn; Its works amazing but I want to do it with polar coordinates angle and length intead of x, y for the speed. Is it possible to do?? or do Ive to convert first to x,y and then back to angle,length? If it is possible please give me a hint on how to do it Thanks in advance