Make terminal not react to hotkeys, unless focused

Closes #8.
This commit is contained in:
blinry 2020-11-10 22:42:43 +01:00
parent 4d97430d44
commit 0e2cacabce

View file

@ -32,6 +32,9 @@ func _ready():
history_position = game.state["history"].size() history_position = game.state["history"].size()
func _input(event): func _input(event):
if not input.has_focus():
return
if game.state["history"].size() > 0: if game.state["history"].size() > 0:
if event.is_action_pressed("ui_up"): if event.is_action_pressed("ui_up"):
if history_position > 0: if history_position > 0: