Search Issue Tracker
By Design
Votes
0
Found in
2021.1.0a10
2021.2
2022.1
Issue ID
1356625
Regression
Yes
Character clips through colliders when forcing two rigidbodies against each other from 2021.1.0a10
Steps to reproduce:
1. Open the attached project
2. Open scene
3. Enter Play mode
4. Try to move the character against the moving platform
Expected results: Character keeps running against the platform without clipping through the ground
Actual results: Character starts to clip through the ground
Reproducible with: 2021.1.0a10, 2021.1.15f1, 2021.2.0b6, 2022.1.0a5
Not reproducible with: 2020.3.14f1, 2021.1.0a9
Notes:
- Reproducible on MacOS, Windows
- On Windows this issue reproduces in all supported streams (2019.4-2022.1)
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Addressables content build fails but the Player build is successful when building a development build
- Out-of-bounds memory access with multiple CanvasRenderers under a Canvas when using Mesh API
- Inspector tries to access file after it was deleted when the file was locked in Inspector window
- Changing Transform values in Search window Inspector loses focus while dragging and stopping mouse without releasing dragging action
- VFX Graph Debug Info overlaps the "Initialize" block debug info by default
Resolution Note:
The platform (Kinematic Rigidbody) is moved using the Animator, which teleports the transform each frame. When you teleport two colliders using transform modifications on top of each other like this, there may be violent depenetration or other undefined behaviours when PhysX tries to separate them. The correct course of action would be to use Rigidbody.MovePosition for the platform, which takes into account the collisions and should be much more stable.
Alternatively, one can utilize "Animation.animatePhysics" if using legacy animations or "Animator.updateMode" set to "AnimatePhysics" to greatly reduce, if not circumvent the issue entirely and still use the Animator to move a kinematic RigidBody.
Also helps to decrease the depenetration velocity for the bodies, or increasing the solver iteration count in Physics Project Settings