float slope = ( mousePosition.z - mouseStart.z ) / ( mousePosition.x - mouseStart.x );
float degrees = math.atan( slope );
Trigonometric functions operate in radians by default. If you want to find the angle in degrees, you’ll need to convert it yourself;
float degrees = math.degrees (math.atan (slope));