When using CannonJSPlugin, raycasts are wavering between true and false when determining intersections.
Playground without CannonJSPlugin
(consistently detects if player standing on object): https://www.babylonjs-playground.com/#3EDS3A#34
Playground with CannonJSPlugin
(inconsistently detects if player standing on object): https://www.babylonjs-playground.com/#3EDS3A#35
The raycast is implemented the same in both Playgrounds. It’s a RayHelper
starting from the bottom of the player (blue box) with length 0.1
.
Note: For some reason, in both Playgrounds, the raycast has no problem determining whether the player (blue box) is standing on the white ground.
Could someone please shed light on why the raycast in the CannonJSPlugin
Playground is wavering between true and false when determining intersections? Thank you