Room Number to element

Hello everyone,

First of all: I am new to Dynamo.

I am trying to write the room numbers of MEP-rooms into a parameter ‘Kommentare’ of elements.
Using my current I manage to identify the objects in the MEP rooms using BoundingBox.Contains.

Using the downstream blocks for list formatting, I get a list with all room numbers for which an intersection between the element and the MEP-room was found.

Problem: The order of the room numbers does not correspond to that of the element, so that incorrect room numbers are written to the element.

Presumption: The ID of the element is lost at some point in my script, so that the assignment no longer exists at the end.

Question: Does anyone know the problem or an alternative solution?

Shouldn’t you fix the null first?

Hi @k.kaest i dont recommend use boundingboxes for rooms or spaces…just use the ootb “is point inside space” node

Thanks for the feedback.

Basically, the script runs, which can now also be seen on the new screenshot. As described, only the assignment of the room numbers to the elements does not work correctly.

Thanks for the tip.

If I see this correctly, ‘Space.IsPointInsideSpace’ also only returns a boolean, so I would get the same result. Or maybe you have an example for me how it could work?

yes true ,gives boolean…the issue with boundingboexs is these XY aligned…if you share your rvt, i can try :wink: PS i like Mepover is in space node it gives elements

2 Likes

If the Elements are Loadable Familes you can use Room Calculation Point function.

yes but not all mep components have calculation pointl, ex. accesories

Filter the list of spaces by each list in the list of lists of booleans using a List.FilterByBoolMask node rather than the formula node.

An example workflow (one of my standard training things which I had handy):

1 Like

I know. Thats why i said IF ;).

I agree with @sovitek that using BoundingBoxes isn’t the best
something like :point_down: this should work(?) for BoundingBoxes.

Most important part :point_down:.

yeah @k.kaest here you have it :wink: probably sometimes need translate the point in z so we are sure it hits the space, depends

Thank you very much, unfortunately the script does not work as I had hoped. Space.IsPoint does not return true.

Check your lacing and list levels for that node and several thereafter. I noted this in the groups for the sample I posted (see the smaller text).

Thank you very much for the help! It works!

1 Like