Improve Android controller support
This commit is contained in:
parent
b47f131797
commit
9c89116713
16 changed files with 647 additions and 31 deletions
|
|
@ -194,6 +194,13 @@ func close_chat() -> void:
|
|||
|
||||
|
||||
func _unhandled_input(event: InputEvent) -> void:
|
||||
if event.is_action_pressed("open_chat"):
|
||||
if _opened:
|
||||
close_chat()
|
||||
elif _available:
|
||||
open_chat()
|
||||
get_viewport().set_input_as_handled()
|
||||
return
|
||||
if event is InputEventKey and event.pressed and not event.echo:
|
||||
if event.keycode in [KEY_ENTER, KEY_KP_ENTER]:
|
||||
if _opened:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue