summaryrefslogtreecommitdiff
path: root/modules/gdscript
diff options
context:
space:
mode:
authorMariano Suligoy <marianognu.easyrpg@gmail.com>2020-08-13 19:46:57 -0300
committerMariano Suligoy <marianognu.easyrpg@gmail.com>2020-08-13 19:46:57 -0300
commita8c01df64768e5a010fccf97570c94fc31227dc5 (patch)
tree5810d34ba09eb1dad8704a6145491dd193582e1f /modules/gdscript
parentef607b01377b26b228a949a70fa786f1e005a850 (diff)
Fix GdScript Analyzier not detecting Resource subclass correctly
Diffstat (limited to 'modules/gdscript')
-rw-r--r--modules/gdscript/gdscript_analyzer.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/modules/gdscript/gdscript_analyzer.cpp b/modules/gdscript/gdscript_analyzer.cpp
index 561cdbbda4..768697bd8b 100644
--- a/modules/gdscript/gdscript_analyzer.cpp
+++ b/modules/gdscript/gdscript_analyzer.cpp
@@ -533,6 +533,7 @@ void GDScriptAnalyzer::resolve_class_interface(GDScriptParser::ClassNode *p_clas
break;
case GDScriptParser::DataType::NATIVE:
if (ClassDB::is_parent_class(get_real_class_name(datatype.native_type), "Resource")) {
+ member.variable->export_info.hint = PROPERTY_HINT_RESOURCE_TYPE;
member.variable->export_info.hint_string = get_real_class_name(datatype.native_type);
} else {
push_error(R"(Export type can only be built-in or a resource.)", member.variable);