Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Bullet prioritised list of Areas a RigidBody is a member of element shift. #42061

Merged
merged 1 commit into from
Sep 15, 2020

Conversation

madmiraal
Copy link
Contributor

Currently, when shifting the elements in the prioritised list of Areas a RigidBody is intersecting with, the shifting is done in the wrong order. Therefore, all elements past the insertion point are replaced with the element at the insertion point. This effectively removes Areas from the list of Areas a body is intersecting with. In addition, it doesn't trigger updates to the Area Space Override modifiers when the RigidBody leaves the missing Area.

This PR reverses the order the elements are shifted to correctly shift the elements.

Fixes #41743.

Copy link
Contributor

@AndreaCatania AndreaCatania left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks good, thanks.

@akien-mga akien-mga merged commit 3a8a0bc into godotengine:master Sep 15, 2020
@akien-mga
Copy link
Member

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

RigidBodies can exit Areas with space_overrides without their gravity vectors being reset
3 participants