From the course: Advanced Revit and Dynamo for Interior Design

Place corner guard families

From the course: Advanced Revit and Dynamo for Interior Design

Start my 1-month free trial

Place corner guard families

- [Narrator] In Dynamo open the PlaceFamily_start.dyn. At the start of the workspace click change on the select model element node. And make sure to tab select the corridor inside of your Revit project. Click run and then this less than node, we have our list of true or false statements. The true statements are where we want to place a corner guard. I'm going to right click on the canvas and search for the all indices of node. I'll use this node to pull the index value of any true statements. I'm going to wire the var output from the less than node to the list input of all indices of. Now I'm going to right click on the canvas and add a boolean node. I'm going to set the boolean to true and wire the input for items. I'll set the list to use levels and look at level 2 because my list is at the second level. Now when I click run up you get a list of index values that can use to pull the endpoint of our lines. I'm going to right click on the canvas and search for the GetItemAtIndex node. I'm going to wire the output from our old indices of node to the index on the input of GetItemAtIndex. Now if I pan back in our workspace there's the curve endpoint node. I'm going to wire the point output from the curved endpoint to the list input of GetitemAtindex. I'm going to set my node to look at level two. And I'll set my lace into longest. Now when I click run I have a list of ten points. These points are the locations where I'd like to place my corner guard family. If I look at the preview inside of Dynamo you can see a list of all of the points. That's because the other nodes still have their previews turned on. If I select the GetitematIndex node and tell it to show labels it'll place a label at each of the points in this list. When I look at the list you can see I am correctly identifying the outside corners around the room while ignoring the inside corners that wouldn't receive a corner guard. Now I can use the family instance at point node where I can place a family at a specified point. I'm going to wire the points from my list of GetItematIndex to the point input on family instances by point. Inside of Revit from the insert tab click load family and load the corner guard family from the exercise files. Now I'm going to search for the family type selector. And in the drop down I'm going to pick the corner guard family that we just loaded. Now if I wire family type output to family type input on the family type by point node I can click run and you can see I've placed ten corner guard families. If I look inside of Revit you'll see the corner guards are placed at the corners. While they're not rotated correctly we are still able to place the corners around the room at all of the outside corners while ignoring any of the inside corners.

Contents