Checking Which Direction A Player Moves

Is there a way to check the angle instead of the number?

The way i do this is

if player is not shift locked / Mousebehaviour is set to locked Then it is always front
else

if w key then front
if s key then Back
if a key then Left
if d key then Right

that is how i do my dashes

js do it from the camera

you dont need to use the hrp