[z1887] Improve a few functions related to Angle calculation

Signed-off-by: Schmoozerd <schmoozerd@scriptdev2.com>

(cleaned version of 51d4890)

(based on commit [s1460] - 036849e)