Place line family at location of wall

I am wanting to place a family at the same location of a wall.

The idea is that walls will have parameter noting their rating. I can use that parameter to select those walls and have a rated line based family placed at those locations.

I have worked with Dynamo enough now that I think I am working in the right direction with this script, but I think the part I’m missing is providing the location points for the line to be placed.



File Link:
Place rated wall family lines.dyn (25.3 KB)

What would you like?
2D or 3D?

It is just a simple 2d line type family

So, just make a line-based GM, set it up to have an array in it, get the start and endpoints of the wall, and use those points to place your line-based GM.
Maybe have a nested shared Family in the Array which inhabits the Fire Rating (maybe change accordingly too)
Or two nested Divided Paths, with different starting points, or map the spacing to the Fire Ratings value.
Just a few things to try

My plan was to get the start and end points of the wall since the node asks for points. I’m not familiar with how to do that part of the script.
In my searching I saw there was a start point of a curve and an end point of a curve, but that didn’t seem to work for me.

1 Like

So I created a python script to get me the length between the start and end X points. Now I’m not finding a node that will create the family along that length. The ones I have seen create a family at a point, not points.

Any idea of a node that will let me choose the line family, select the model elements, and then create it between 2 points at those elements?

Like this one?
image

I can try this one, but I’m not wanting to make a wall. I just want to generate a 2d line family where an already existing wall is located.

Hello, look on this
https://dictionary.dynamobim.com/#/Revit/Elements/FamilyInstance/Create/ByPointAndLevel
And this for the point on curve
https://dictionary.dynamobim.com/#/Geometry/Curve/Action/PointAtParameter

Cordially
Christian.stan

2 Likes

Thanks, if I have time this weekend I’ll check these out.

1 Like

Clockwork has a DetailComponent.ByCurve node which should resolve this for you.

3 Likes

I will try this out as well. I know in trying some other curve nodes it kept saying that I was feeding it a wall and it was wanting a curve.

So that ended up working for me and I have to say that I am probably the most pumped I’ve been after creating a script. I think this was the first time I actually had an efficiency I wanted to create and couldn’t find a similar script to revise or work from. So this was my first fully from scratch script.

After figuring out that the node worked I incorporated data-shapes UI so I could use it in my toolbar I have made through Pyrevit.

Here are some screenshots of the final product.

Thanks Jacob for the help with the node suggestion!

2 Likes

hello, you can directly connect the Elements.location node to the recommended node of Mr. Jacob directly (your group will be composed of one node)

Cordially
christian.stan

1 Like

I tried feeding the element node directly into the recommended node and it didn’t work. Looks like I need to tell it a starting and ending point.

Jacob,

It dawned on me this morning that the way I am isolating the family is by noting it’s position within the list of all the detail items families.

This could be an issue on other projects in our office when that list length is different, or if you were to add a family item that started with a letter before ‘P’.

Is there a node to select the family using it’s name, that way it works for other projects?

Jacod,

Another couple of questions on some interesting findings once we started using the script.

  1. We noticed that if a wall is continuous, for us it was a below grade parking garage, the script would work on the lower level, but then when you went to the level above it would not place the line family on walls where it was placed on the level below. Just walls that were not selected when using the script on the lower level. Any idea why that is the case?

  2. It seems to only work when you are using an instance parameter as the wall identifier. We tried using a type parameter and it didn’t work. Ideally, a type parameter would be better since we are using this on rated walls so each type will be different. Any idea why it only works with instance parameters?

Thanks!

Hello,
curious, your family has adaptive points?

Otherwise the nodes (Family.ByName / FamilyType.ByName) for your questions

Cordially
christian.stan

@john_pierson