Room contain more than one ceiling

Sorry mate, you don’t have to use python, maybe it was an overkill. Here is the solution with just dynamo:

Capture%202