The function to calculate the direction of a 2D vector is often called "atan2". Scratch doesn't have this function so a workaround is required. A common use case for it is making a sprite point towards a specific coordinate. I have discovered that the commonly-used workaround has an edge case that produces the wrong result. Floating point numbers support "negative zero" as a value and this has a different result when used in division: x/0 = Infinity (when x is positive) x/-0 = -Infinity (when x is positive) This project demonstrates the issues with the ring of lines, each representing a different vector being tested. They all should be pointing outwards. Those at ±0 have been visually offset by a few pixels for clarity. I have found that adding 0 to the divisor will fix it, as it causes negative zero to become positive, without changing any other number. See inside the project where there are some backpackable custom blocks in the first sprite. You do not need to credit me for any of it although you might want to link back to this project to explain why there is a seemingly useless addition of 0 in the script. Note that this issue is harder to encounter on TurboWarp. This project actually works fine there due to how TurboWarp handles values. --- Forum BBCode: (([atan v] of ((y) / ((x) + (0)))) + ((180) * <(x) < [0]>)) swap the x and y vars if you want Scratch's bearings define point towards (x) (y) point in direction (([atan v] of (((x) - (x position)) / (((y) - (y position)) + (0)))) + ((180) * <(y) < (y position)>)) --- Relevant articles: https://en.wikipedia.org/wiki/Double-precision_floating-point_format https://en.wikipedia.org/wiki/Atan2