From a82a66ee7c5d9c050edbb6632a090f4222cf8162 Mon Sep 17 00:00:00 2001 From: Danny McGill <63943484+Ninjaboi8175@users.noreply.github.com> Date: Wed, 23 Oct 2024 07:17:12 -0500 Subject: [PATCH] Fixed root type failing to change if user provides a global class inherited from another global class. Find the inherited native class (built-in) of the user provided global class (GDScript) by recursively checking up its inheritance chain until a valid native class is found. Previously it was only checking the class directly extended from it which could be another global class. Importing expects a native class for _internal_instantiate() to work. --- editor/import/3d/resource_importer_scene.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/editor/import/3d/resource_importer_scene.cpp b/editor/import/3d/resource_importer_scene.cpp index cb348f713c1..d971e00805f 100644 --- a/editor/import/3d/resource_importer_scene.cpp +++ b/editor/import/3d/resource_importer_scene.cpp @@ -3022,7 +3022,9 @@ Error ResourceImporterScene::import(const String &p_source_file, const String &p Ref