From a615d359e86de1739c5049d5552fb734e82fed09 Mon Sep 17 00:00:00 2001 From: Marcel Admiraal Date: Mon, 6 Jul 2020 12:00:53 +0100 Subject: [PATCH] Clear a Bullet Area's overlappingObjects vector when removing an area from a space. --- modules/bullet/area_bullet.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/modules/bullet/area_bullet.cpp b/modules/bullet/area_bullet.cpp index 79d8e252f01..e5e5f81d2af 100644 --- a/modules/bullet/area_bullet.cpp +++ b/modules/bullet/area_bullet.cpp @@ -174,6 +174,7 @@ void AreaBullet::reload_body() { void AreaBullet::set_space(SpaceBullet *p_space) { // Clear the old space if there is one if (space) { + overlappingObjects.clear(); isScratched = false; // Remove this object form the physics world