Fix: Pressing keys after editor starts result in errors printed.

"scene/main/node.cpp:1748 - Parameter "p_node" is null."
This commit is contained in:
Serhii Snitsaruk 2023-08-23 16:32:02 +02:00
parent a7d86c5356
commit f489744755
1 changed files with 1 additions and 1 deletions

View File

@ -983,7 +983,7 @@ void LimboAIEditor::shortcut_input(const Ref<InputEvent> &p_event) {
// * Local shortcuts.
if (!(has_focus() || is_ancestor_of(get_viewport()->gui_get_focus_owner()))) {
if (!(has_focus() || get_viewport()->gui_get_focus_owner() == nullptr || is_ancestor_of(get_viewport()->gui_get_focus_owner()))) {
return;
}