Place Familys automatically on Room-Ceiling

Hey there,

I am pretty new in working with Dynamo and I am trying to automate a Process which usually would take plenty of Time. What I want to do is:

-Get all the Rooms <50m² in a Project
-Place an Element in the middle of the Room on the Ceiling (Element will be a Lamp or something like that) if the Room is <50m²

In order to be able to do this, I have to work with the Room Height (i guess?), but i can’t manage to get it done.

What i currently have is this:

So right now, i am able to select a Level in my Project and place a Family Type (its a Television right now, but don’t mind that) in the middle of the Room. The Element gets placed on the Floor though, which would not really make sense for a Lamp:grinning:.

I also did not manage to find a way to get All Elements of the Project, I did try to get all Elements by Category but did not manage to get the right Blocks working with them in the further Process ( like i did here with the Polygon stuff). This is no Major Problem, but i’d like to 100% automate this Process in the End.

Any Help is appreciated,

Thanks

Hi @GulioSev

I would use categories (ceilings)
all elements of category
filter by area
get face of ceiling
get the middle
Springs.FamilyInstanceByFace

1 Like

Hey thanks for that, aren’t Ceilings located also on other Places like “Floors” or something, i’d like to put the Elements only inside a Room.

I would enable 3D room calculations and use a room.boundaries node which will give you the floors, walls, and ceilings which define the limits of the room. The largest ceiling element is likely the one to host to, but if you have decorative ceiling planes (coffers, soffits, etc) you’ll have some issues.

2 Likes

@m.rijsmus How would you Filter by Area, cant find anything on that?

@jacob.small Yes, but for whatever Reason i get this Result:

How am i supposed to get the Celings out of that List?

1 Like

@m.rijsmus Thanks for that. I tried solving it by filtering for the Rooms, but it got really messy:

. The Reason for that is that i wanted to filter for the Rooms first filter for the Ceilings inside of those Rooms and place a Family on those Ceilings.

After i tried your way im getting this:


if i compare it to mine solution, shouldnt the amount of ceilings <50 and rooms be the same?

If you have a ceiling in every room, yes, but what if you have 2 ceilings in a room, or none? :slight_smile:

@m.rijsmus Well this kinda makes sense, i guess i have to figure out that later. Got any idea how the rest of those: get face of ceiling,get the middle,Springs.FamilyInstanceByFace could be solved with Dynamo?

@GulioSev

The credo here on the forum is: we don’t do the work for you, show us what you have already tried.

2 Likes

I would first purge your nulls data (which likely means you’re missing a bounding element btw) and then run a List.FilterByBoolMask using the name of each element’s category to reduce the object list to only ceilings. Watch lacing and lost levels as they will matter here.

1 Like

@m.rijsmus @jacob.small Yes, you are right on that. So it got kinda complicated and messy, so i tried solving it with coordinates/points of the Room. Unfortunately i got 3 different results on 3 different Familys i placed :neutral_face: . The Dynamo Blocks are on all 3 cases the same, the only thing that changes is the Family i chose to place.

No1: Here you can see that the Lamps got placed on the Ground, with Z-value not beeing 0. There are also only 8 Lamps displayed in the Rooms on Floor 1 and not on Floor2, but on the Dynamo-Script you can see 16 Lamps placed(FamilyInstance.ByPoint)

No2: Different Lamp, different Placement :smile: . Here we can see, that at least, all of the 16 Lamps got placed, but for whatever Reason they are floating midair/outside of the Hotel.

No3: The Tv-Bonus Package :grin:. Here we can see that the right Number of TV got placed, but not bellow the ceilling but on it. From all 3 attempts this is the one which is most likely going into the right dirrection. I still have to figure out how to flip the TV so it will be hanging from the ceiling.

I dont get how i can get 3 different Results with 3 Familys, i dont think the Familys are corrupted(?) or something, but cant find a way to explain that. I mean the “Dynamo-Script” (?) is in all attempts the same (except the Family ofc).

Thanks for sticking with me Guys.

I think that if you open the family you can find the origin of that family, this is the point dynamo uses to place the family in the project. Probably the geometry (extrusions) inside the family are with an offset to the origin and therefore seem to be floating.

1 Like

@m.rijsmus You are right:elevation

The Elevation on Lamp1 is not editable, so the Z-Parameter did not get passed. That’s why it got placed on the Ground. Seems like Lamp2 is broken too, should not have downloaded some random Familys from the Web :sweat_smile:. Now i have to figure out how to flip the Family and will probably be done.

Hi @GulioSev

Try using Family.InstanceByFace node instead:

3 Likes

@Kulkul Hey, thanks for that. This is what i get after trying it out:
asdasdfg

The Elements you select on your first Node, are the Rooms, or the Ceiling? The two Nodes after FamilyInstance.ByFace are not necessary, right?

Hi Kulkul,

I am following and checking you post and solved items. I am excited, surprised and amazed every time I browse in your Profile. Thank you for all the scripts and Tips. “Ask and you will be given”

Regards,
Greg

2 Likes

Hi @gregorio.palermo

You’re Welcome!

Hi Kulkul,
Could you please share this script, it will be very useful for me
Thanks

Hi @naturalnature

Please start a new topic, this one is too old