Better implementation of angles and rotations