Search Issue Tracker

Active

Under Consideration for 6000.5.X

Votes

5

Found in

2022.3.60f1

6000.0.42f1

6000.1.0b9

6000.2.0a6

6000.3.0a1

6000.4.0a1

6000.5.0a1

Issue ID

UUM-100359

Regression

No

MeshCollider does not detect collisions with Capsules and CharacterController when using Physics.ComputePenetration

3D Physics

-

Reproduction steps:
1. Open the attached project "ReproProj"
2. Open the “/Assets/Core/Scenes/TestScene.unity” Scene
3. In Scene view, fly over the Objects to look at them from above
4. In Hierarchy expand Samples > Box > Scale_1x1x1 > Mesh
5. Select every Prefab in Samples > Box > Scale_1x1x1 > Mesh and in Inspector click “Execute“ button
6. Repeat step 5 for every Prefab in Samples > Box > Scale_1x1x1 > Primitive
7. Repeat step 5 for every Prefab in Samples > Box > Scale_4x4x4 > Mesh
8. Repeat step 5 for every Prefab in Samples > Box > Scale_4x4x4 > Primitive
9. Repeat step 5 for every Prefab in Samples > Box > Sector
10. Observe Scene view

Expected result: Prefabs do not exist in the Scene view and are disabled
Actual result: Some Prefabs are still present in the Scene view

Reproducible with: 2022.3.60f1, 6000.0.42f1, 6000.1.0b9, 6000.2.0a6

Testing environment: Windows 10 Enterprise 21H2
Not reproducible on: No other environment tested

Comments (2)

  1. forestrf

    Feb 14, 2026 17:48

    This bug can be worked around by calling the function many times (16 or more) with different positions for either of the two colliders, offsetting it by just a tiny bit on each try. The workaround doesn't always work, but with 16 attempts I have not seen the bug again. That also means increasing the cost by 16 times. For now I'm only doing it if one of the colliders is a capsule and the other is a convex mesh collider, but the bug may be present on other pairs too. I will be doing that until it's hopefully fixed.

  2. forestrf

    Feb 14, 2026 05:38

    ComputePenetration returns true or false sometimes at random.
    While having the function return false when it should be true, as the convex mesh collider and the capsule collider parameters used result in an overlap, add a breakpoing before or after the compute penetration and the result will change.
    If the breakpoint is before ComputePenetration it may return the correct result, or just different values for direction and distance than when not having a breakpoint.

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.