Okay guys, this is the code:
# Get player input
var x_axis = Input.get_axis("left", "right")
var y_axis = Input.get_axis("up","down")
if x_axis != 0:
y_axis = 0
if y_axis != 0:
x_axis = 0
var input := Vector2 (x_axis, y_axis)
# Move player
if input != Vector2.ZERO:
position += input * speed * delta
animation_controller(input)
else:
$Anim.play("RESET")
move_and_slide()```
This kinda restricts the player to move in a 4 way direction only, with the added bug of the movement code getting overwritten by the left / right keys if im pressing down or up, and the opposite not happening (the player will stay walking left / right even if i press up or down)