From 5e434841ec358ae3fefa2356b122c9d62df94179 Mon Sep 17 00:00:00 2001 From: Nathan Franke Date: Sat, 20 Mar 2021 18:48:41 -0500 Subject: [PATCH] Add Root Null Check (cherry picked from commit 3c921ba80177e0b8c24fcad1cde5c903248d385a) --- scene/main/scene_tree.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/scene/main/scene_tree.cpp b/scene/main/scene_tree.cpp index 55973b72d9be..79c071832ed2 100644 --- a/scene/main/scene_tree.cpp +++ b/scene/main/scene_tree.cpp @@ -460,6 +460,7 @@ void SceneTree::input_event(const Ref &p_event) { } void SceneTree::init() { + ERR_FAIL_COND(!root); initialized = true; root->_set_tree(this); MainLoop::init();