extends CharacterBody3D

# need to do:
# direction -> $CharacterBody3D.position.z

func _physics_process(delta: float) -> void:
	var direction = Vector3.ZERO;
	
	if Input.is_action_pressed("moveForward"):
		direction.z -= 1
		#print("forward")
		velocity.z = direction.z;
		move_and_slide();

	if Input.is_action_pressed("moveBackward"):
		direction.z += 1
		velocity.z = direction.z;
		move_and_slide();

	if Input.is_action_pressed("moveLeft"):
		direction.x -= 1;
		velocity.x = direction.x;
		move_and_slide();

	if Input.is_action_pressed("moveRight"):
		direction.x += 1;
		velocity.x = direction.x;
		move_and_slide();
		
	if Input.is_action_pressed("moveJump"):
		direction.y += 1;
		velocity.y = velocity.y;
		move_and_slide();
