Do raycasts interact with mesh geometry?

I’ve created an ocean system, and i want to create buoyancy, similar to Deepwoken. Could i use raycasts or do i have to use a different method?

If you are using EditableMesh, there is the :RaycastLocal() method. If you are using skinned mesh, you will have to do math to create your own raycasting algorithm because skinned mesh does not recalculate the collision model. But this is probably the XY Problem and you just need the height of the ocean, which can be extracted from whatever wave algorithm you’re using. Just plug the X and Z coordinate of the boat into the function to get the wave height at specific locations.