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 feaba55 commit c25d689Copy full SHA for c25d689
include/godot_cpp/core/method_ptrcall.hpp
@@ -168,6 +168,9 @@ MAKE_PTRARG_BY_REFERENCE(Variant);
168
template <class T>
169
struct PtrToArg<T *> {
170
_FORCE_INLINE_ static T *convert(const void *p_ptr) {
171
+ if (*((T **)p_ptr) == nullptr) {
172
+ return nullptr;
173
+ }
174
return reinterpret_cast<T *>(godot::internal::gde_interface->object_get_instance_binding(
175
reinterpret_cast<GDExtensionObjectPtr>(const_cast<void *>(p_ptr)),
176
godot::internal::token, &T::___binding_callbacks));
0 commit comments