From 053f20be769b5e8dfe76d8ea8a086a07a1b17db9 Mon Sep 17 00:00:00 2001 From: kobewi Date: Mon, 2 Aug 2021 14:15:40 +0200 Subject: Add null check to Tween.bind_node() --- scene/animation/tween.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scene/animation/tween.cpp b/scene/animation/tween.cpp index a57e986877..542011618d 100644 --- a/scene/animation/tween.cpp +++ b/scene/animation/tween.cpp @@ -140,6 +140,8 @@ bool Tween::is_valid() { } Ref Tween::bind_node(Node *p_node) { + ERR_FAIL_NULL_V(p_node, this); + bound_node = p_node->get_instance_id(); is_bound = true; return this; -- cgit v1.2.3