mirror of
https://github.com/godotengine/godot.git
synced 2024-11-22 04:06:14 +00:00
Merge pull request #42061 from madmiraal/fix-41743
Fix Bullet prioritised list of Areas a RigidBody is a member of element shift.
This commit is contained in:
commit
3a8a0bc5d3
@ -849,8 +849,8 @@ void RigidBodyBullet::on_enter_area(AreaBullet *p_area) {
|
||||
} else {
|
||||
if (areasWhereIam[i]->get_spOv_priority() > p_area->get_spOv_priority()) {
|
||||
// The position was found, just shift all elements
|
||||
for (int j = i; j < areaWhereIamCount; ++j) {
|
||||
areasWhereIam[j + 1] = areasWhereIam[j];
|
||||
for (int j = areaWhereIamCount; j > i; j--) {
|
||||
areasWhereIam[j] = areasWhereIam[j - 1];
|
||||
}
|
||||
areasWhereIam[i] = p_area;
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user