Okay, I’ve come to a new solution.
I collect the model curves in a similar manner to what is describe in this thread:
The script that I called ID collector looks as follows:
For anyone who might be somewhat inexperienced with Dynamo and Python like me, the script takes in i.e. floor elements, deletes the element, stores the IDs of the elements which are deleted as a result of the floor being deleted (the modelcurves of the floor being some of them), and then rolls back the deletion. The output is then the IDs of all the elements connected to the floor.
I still use the Spring Element Sketch Collector to collect the curves, because as Viktor mentioned, it works as expected, when ‘fetchModelCurves’ is set to false. But I could also just as well collect the geometry from the model curves.
The reason that I don’t use the method that Kulkul introduced, of extracting the geometry of the top surface, is that I get a mismatch between the boundary curves and the model lines if there is i.e. af shaft opening breaking the border of the floor. But if you just need the actual geometric border of the floor, this method will probably be the way to go.
After I collect both the outline curve of the floor and all the model curves, I compare the midpoints of the curves an the geometry of the modellines. This way I both pick out the model curves which corespond to the outline (and not the openings), and I sort the model curves in the same order as the outline curves.
This was a lot of text - but I have attached a dynamo script, for anyone who might be interested.
Floor opening cut issue - new method.dyn (35.6 KB)
Floor opening cut issue.rvt (412 KB)