summaryrefslogtreecommitdiff
path: root/scene/2d/physics_body_2d.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'scene/2d/physics_body_2d.cpp')
-rw-r--r--scene/2d/physics_body_2d.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/scene/2d/physics_body_2d.cpp b/scene/2d/physics_body_2d.cpp
index d42bd6adaf..d1fe5caf7e 100644
--- a/scene/2d/physics_body_2d.cpp
+++ b/scene/2d/physics_body_2d.cpp
@@ -1544,7 +1544,7 @@ Object *KinematicCollision2D::get_local_shape() const {
Object *KinematicCollision2D::get_collider() const {
- if (collision.collider) {
+ if (collision.collider.is_valid()) {
return ObjectDB::get_instance(collision.collider);
}
@@ -1608,7 +1608,7 @@ void KinematicCollision2D::_bind_methods() {
}
KinematicCollision2D::KinematicCollision2D() {
- collision.collider = 0;
+
collision.collider_shape = 0;
collision.local_shape = 0;
owner = NULL;