add input function
This commit is contained in:
parent
0fe5cca646
commit
53780532bf
|
@ -37,3 +37,13 @@ func _ready() -> void:
|
|||
pieces_row.append(piece)
|
||||
|
||||
pieces.append(pieces_row)
|
||||
|
||||
func _input(event):
|
||||
if event.is_action_pressed("ui_up"):
|
||||
print("up")
|
||||
if event.is_action_pressed("ui_down"):
|
||||
print("down")
|
||||
if event.is_action_pressed("ui_left"):
|
||||
print("left")
|
||||
if event.is_action_pressed("ui_right"):
|
||||
print("right")
|
||||
|
|
Loading…
Reference in a new issue