Fixes Node arrays appear as Object arrays in the inspector

(cherry picked from commit 3ebf2264aa)
This commit is contained in:
Nong Van Tinh 2023-04-28 14:27:10 +07:00 committed by Rémi Verschelde
parent 4d7336e70f
commit aa23e6fc5e
No known key found for this signature in database
GPG Key ID: C3336907360768E1

View File

@ -222,7 +222,7 @@ void EditorPropertyArray::update_property() {
String array_type_name = Variant::get_type_name(array_type);
if (array_type == Variant::ARRAY && subtype != Variant::NIL) {
String type_name;
if (subtype == Variant::OBJECT && subtype_hint == PROPERTY_HINT_RESOURCE_TYPE) {
if (subtype == Variant::OBJECT && (subtype_hint == PROPERTY_HINT_RESOURCE_TYPE || subtype_hint == PROPERTY_HINT_NODE_TYPE)) {
type_name = subtype_hint_string;
} else {
type_name = Variant::get_type_name(subtype);