We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9ae37ac commit 44a1a7dCopy full SHA for 44a1a7d
1 file changed
src/variant/variant.cpp
@@ -528,6 +528,9 @@ Variant::operator PackedVector4Array() const {
528
529
Object *Variant::get_validated_object() const {
530
#if GODOT_VERSION_MINOR >= 4
531
+ if (get_type() != OBJECT) {
532
+ return nullptr;
533
+ }
534
return ObjectDB::get_instance(operator ObjectID());
535
#else
536
// Note: This isn't actually validated, but we can't do any better in Godot 4.3 or earlier.
0 commit comments