I think what you are trying to do, is have an object travel on a line described by a vector, and you want the controls to change whether it is moving positively or negatively along the vector.
Now I may have miss understood the question, but if I didn’t here is a 2d example of what I described.
extends Sprite
var direction : int = 0
var axis = Vector2(0.1,0.5)
func _process(delta):
if Input.is_action_pressed("go_north"):
direction = -1
if Input.is_action_pressed("go_south"):
direction = 1
if Input.is_action_pressed("go_stop"):
direction = 0
var velocity = axis * direction
global_translate(velocity)