-
-
Notifications
You must be signed in to change notification settings - Fork 21.4k
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
Inaccurate physics with simple bodies (RigidBodies can temporarily penetrate other PhysicsBodies) #16505
Comments
This incorrect behaviour has been confirmed from multiple users in the comments of this post on reddit. |
Related issue: #9071 |
I'm not sure if it is directly related to #9071. Since this is not about CCD and the objects are moving slow. From my testing it's even unrelated to the physics backend bullet/godot. |
btw, if anyone is reading this don't listen to those reddit comments by turning up the fixed fps value. this will make your game become distorted for other players. (not everyone who plays your game will have the same fixed refresh rate as you). |
#20105 looks like the same but for 2d |
looks like a CCD issue caused by too few solver iterations for the speed of the objects / timescale being used, however, seems like this is hardcoded whenever it's needed maybe this can be added as a UI setting that users can tweak |
Not sure if additional test-cases/experiences are wanted since it's been confirmed, but, I ran into this recently in 3.2.1-stable-mono on Ubuntu 20.04 and put together one before I found this. From my testing, CCD doesn't appear to make a difference and the issue only noticeably affects certain shapes with the default sizes/settings. In particular, boxes and convex colliders, cylinders appear to be covered by #27212 and #38426. Scaled shapes in general appear to be affected as well, as per the report's minimal example. Rotating on two axes appears like it may prevent/reduce the brief penetration for certain shapes, not sure if that's a clue as to the issue (Edit: Maybe because it gives a single vertex instead of a line or face?). I missed testing concave colliders unfortunately, but I can come back and add that when I have the chance. Both the Bullet and GodotPhysics backends appear to exhibit the behavior. File: Physics.tar.gz I tried to keep all of the collider settings at their defaults and to scale the fixed process rate in slowmo to maintain the physics step size - so you can see what's going on. |
IIRC CCD is MIA for quite some time? @Calinou |
@Zireael07 Indeed, see #9071. |
Confirmed reproducible in 3.3 with both Bullet and GodotPhysics (both with the MRP from #16505 (comment) and the more advanced test suite from #16505 (comment)). |
Godot version:
v3.0.stable.official
OS/device including version:
Windows 10 Pro 10.0.16299 Build 16299
Issue description:
Simple 3d physics are not resolved correctly. Slow moving rigidbodies can enter/penetrate staticbodies at slow speeds. This collision is slowly corrected over several frames by pushing out the rigidbody. Setting the physics fps to a high value like 240 fps minimizes the problem, but it's still noticeable.
Sample Video
Steps to reproduce:
Add a staticbody as a ground. Add an rigidbody with a sphere collider and drop it from medium heights (10-20 Units).
Minimal reproduction project:
Left-Mouseclick accelerate rigidbody.
Physics_Issue.zip
The text was updated successfully, but these errors were encountered: