Ride on surface of mesh

Hey guys, do you know how it possible to move mesh on face of other custom mesh? May be you have any examples on babylon? Thank you.

It should be like this

original game is here https://play.google.com/store/apps/details?id=io.voodoo.paper3

1 Like

hi. i think there is no simple way to achive this. babylon has recastjs as navigation plugin but recast dont work with not flat surfaces.

1 Like

yes, you can by using FacetData on any mesh : Use Facet Data - Babylon.js Documentation

2 Likes

@jerome you helped me a lot, thank you very much! getClosestFacetAtCoordinates works like a charm.

Babylon.js is ther best of the best :slight_smile: Happy to use this lib.

1 Like