platformerNavigation/Characters/Controller.gd

7 lines
178 B
GDScript
Executable File

extends Node
func _process(delta):
var direction = Input.get_axis("MoveLeft", "MoveRight")
get_parent().move(direction)
get_parent().jump(Input.is_action_pressed("Jump"))