You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
12 lines
358 B
GDScript
12 lines
358 B
GDScript
extends Node3D
|
|
|
|
func _input(event):
|
|
if !event.is_action_type():
|
|
return
|
|
if event.is_pressed():
|
|
SignalManager.input_action_pressed.emit(event)
|
|
elif event.is_released():
|
|
SignalManager.input_action_released.emit(event)
|
|
var input_dir = Input.get_vector("move_left", "move_right", "move_up", "move_down")
|
|
SignalManager.input_action_move.emit(input_dir)
|