1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-19 14:31:59 +00:00

Improved code that handles collision shapes, fixes #21945

This commit is contained in:
Andrea Catania
2018-10-06 16:50:10 +02:00
parent 5328dcb7bb
commit 7d681274f8
10 changed files with 126 additions and 161 deletions

View File

@@ -65,7 +65,8 @@ btCollisionShape *ShapeBullet::prepare(btCollisionShape *p_btShape) const {
void ShapeBullet::notifyShapeChanged() {
for (Map<ShapeOwnerBullet *, int>::Element *E = owners.front(); E; E = E->next()) {
static_cast<ShapeOwnerBullet *>(E->key())->on_shape_changed(this);
ShapeOwnerBullet *owner = static_cast<ShapeOwnerBullet *>(E->key());
owner->shape_changed(owner->find_shape(this));
}
}