mirror of
https://github.com/JHDev2006/Super-Mario-Bros.-Remastered-Public.git
synced 2025-10-21 23:18:11 +00:00
alr, multiple inputs are DONE
This commit is contained in:
@@ -74,6 +74,7 @@ func load_inputs() -> void:
|
||||
idx += 1
|
||||
else:
|
||||
bind_value_to_event(i, value, 0)
|
||||
i.update_value()
|
||||
|
||||
func bind_value_to_event(input_node, value, idx := 0) -> void:
|
||||
var event: InputEvent = null
|
||||
@@ -852,6 +853,7 @@ type = 1
|
||||
[node name="Pause" parent="PanelContainer/MarginContainer/VBoxContainer/Controller" groups=["Options"] instance=ExtResource("9_ksnto")]
|
||||
layout_mode = 2
|
||||
settings_category = "controller"
|
||||
can_bind_escape = true
|
||||
action_names = ["pause"]
|
||||
title = "PAUSE"
|
||||
type = 1
|
||||
|
@@ -3,6 +3,7 @@ extends HBoxContainer
|
||||
|
||||
@export var settings_category := "video"
|
||||
@export var selected := false
|
||||
@export var can_bind_escape := false
|
||||
|
||||
@export var action_names := [""]
|
||||
@export var title := ""
|
||||
@@ -90,10 +91,10 @@ func _input(event: InputEvent) -> void:
|
||||
if event.is_pressed() == false:
|
||||
return
|
||||
|
||||
#if event is InputEventKey:
|
||||
#if event.as_text_physical_keycode() == "Escape":
|
||||
#cancel_remap()
|
||||
#return
|
||||
if event is InputEventKey and not can_bind_escape:
|
||||
if event.as_text_physical_keycode() == "Escape":
|
||||
map_event_to_action(null, current_binding_idx)
|
||||
return
|
||||
|
||||
if type == 0 and event is InputEventKey:
|
||||
map_event_to_action(event, current_binding_idx)
|
||||
|
Reference in New Issue
Block a user