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

KinematicCharacterController: early break in move_shape in case of no update. #424

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

PieroV
Copy link
Contributor

@PieroV PieroV commented Dec 4, 2022

Hi! I think the while in move_shape could be early-broken if no improvement is done in an iteration: if I understand correctly, if the character has not moved in an iteration, it will not in the next one, too.
However, all the collision queries will be run, consuming time.
But I am not sure this makes sense, since kinematic_friction_translation is also updated during iterations.

@PieroV
Copy link
Contributor Author

PieroV commented Dec 11, 2022

@sebcrozet hi, you asked me to send a simple example of the problem that patch should solve on Discord, so here it is 🙂 : simpletest.zip.

Please notice also that I would expect grounded to become true eventually, but it does not (both with and without my patch). Maybe I can open an issue for that, unless I found a way to solve the problem.

If no movements are performed in an iteration of move_shape, early
break, instead of trying to repeat it again.
@Vrixyz Vrixyz added 2D The issue is specifically about the 2D version of Rapier. A-Dynamics P-Low D-Difficult labels May 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2D The issue is specifically about the 2D version of Rapier. A-Dynamics D-Difficult P-Low
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants