Basic Trigonometry Isn't Working Correctly In Python
For a bit of background, this is the game I'm trying to draw in an isometric style. I'm just trying to get the correct calculations instead of doing it in a hacky way, but one part
Solution 1:
As stated in the comments you need to convert to radians which can be done with the
math.radians()
function. So in practice you would end with something like
height = 2 * sin(math.radians(iso_angle)) * grid_length
width = 2 * cos(math.radians(iso_angle)) * grid_length
Post a Comment for "Basic Trigonometry Isn't Working Correctly In Python"