Revit Dynamo — Insert Plumbing Sleeves

Slava Krel
4 min readDec 23, 2020

--

After my previous post I’ve decided to make another one on the Plumbing topic. Placing sleeves was one of the biggest issues I struggled with in the past while working on coordination projects. It is pretty time consuming task in general, but it can be even more excruciating when you have to move the pipes around during coordination. Here I wanted to share my approach on how to stream line the sleeve placing process using Dynamo.

Full definition

Preparation

  1. Here I’m using a 3rd party node, so to get this script to work you need to download the latest version of Archi-Lab package.
  2. Make sure you have the sleeve family you want to use in your Revit project. I want to give you a little tip here — use a sleeve family that can automatically oriented per the plumbing pipes you are working with.

Let’s build this script and figure out how it works

Step 1. We would normally start with “Categories” node to get all elements of a given Category. But not every Revit file have the same Categories. Why would you want to load all of the MEP Categories into your model. Because models don’t always have the same Categories, the dropdown node, that contains a list of them, doesn’t always display they same items, in the same order if it was opened in a different file. In order to resolve that potential issue here is what we’re going to start with:

Also add Family Types node and find the sleeve family you want to be used.

Step 2. Filtering out “vertical” vs “horizontal” pipes is quite simple — I’m going to check its Slope parameter. If we are dealing with a pipe that has no Slope then we know this pipe is vertical. No custom nodes needed here. If you are new to Dynamo it might be a good idea to save this portion of the script in a separate location. I’m using these five nodes very often.

Step 3. To get Floors from the linked background file we are going to use Select.GetDocuments node. This is a standard procedure except for the Get All Elements From Linked Model node from Archi-Lab package. According to the name, this node allows us to collect all floors from the linked model.

Step 4. Next stop — we are going to intersect Floors and Vertical Pipes.

We want to filter out only Pipes that go through Floors, so we can place a sleeve on them. We can use List.IsEmpty node here, since the result of the Geometry.Intersect will be all Empty List if there was nothing that intersected with our Pipes.

Step 5. Finally we clean up our list of nulls, and empty lists, and get our intersection points as Solid.Centroid. This node give us X, Y, and Z which we are going to use as an insertion point for the sleeves.

To place the sleeve family into the model we are going to use FamilyInstance.ByPoint default node.

Ending

After the script successfully completed you should be able to see the sleeves inserted into the slab as it shown on the picture below.

Thank you for reading. I hope you find this post helpful. Feel free to download the script from my GitHub.

--

--