15 lines
336 B
GDScript
15 lines
336 B
GDScript
extends Button
|
|
|
|
@export var input_action_name : String
|
|
@export var remap_controller : Node
|
|
|
|
func _ready():
|
|
display_key()
|
|
|
|
func display_key ():
|
|
text = "%s" % InputMap.action_get_events(input_action_name)[0].as_text()
|
|
pass
|
|
|
|
func _on_pressed():
|
|
remap_controller.start_remap(self, input_action_name)
|
|
pass # Replace with function body.
|