summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <rverschelde@gmail.com>2020-07-06 19:16:51 +0200
committerGitHub <noreply@github.com>2020-07-06 19:16:51 +0200
commitb5a73c9e5c9ddb45b14424fb787fea67f695a85b (patch)
tree7d5969f52d95fdb4b9927c1ea7d7e9bcd1922691
parentf8c066e97eec9c936d5e809328144d7af21acd0d (diff)
parenta615d359e86de1739c5049d5552fb734e82fed09 (diff)
Merge pull request #40157 from madmiraal/fix-39765
Clear a Bullet Area's overlappingObjects vector when removing an area from a space.
-rw-r--r--modules/bullet/area_bullet.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/modules/bullet/area_bullet.cpp b/modules/bullet/area_bullet.cpp
index 79d8e252f0..e5e5f81d2a 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