Get floor thickness into beam parameter

Hello, guys,
I have a question, is it possible to create a dynamo script that helps me get the thickness of each floor near the beams and get those thicknesses into a parameter I know how to put them in a parameter but which nodes help me get the floors that are near the beams thank you in advance.

hello, if you recover the edges of the upper faces (filter via vectors) of the elements of beams and slabs then you intersect and filter by line you will have the elements in contact then you can recover the thicknesses

edit:after reflection with this custom node from M. T. Mahon, it will go faster (take a good look at the remark on tolerance) and fully optimized.


Get the location curve of the beam.
Create normals in both directions
Create surface from the curve and the normals
Check if any of the two surfaces intersect with any floors
If it does take the floor thickness and set the parameter to it.

Try it and come back when you have dynamo graph to show