I have a hundred buildings (each is grouped, many of them are copies) on the ground floor. I have a terrain and I want to project the buildings onto the terrain.
I tried select model element, but couldn’t select a single group by itself with 1 ID. I tried to get the z point , tried bounding boxes, and dynamo didn’t seem to be updating/running.
I have my setting set to manual but nothing really happens when i press run. I end up having to close dynamo and it gets greyed out in the revit ribbon.
Can you show your graph with the preview bubbled pinned? Really hard to provide help without that.
On a side note;
Why don’t you have your buildings as separate models and link and copy those?
Hi, sorry, i tried a few different methods yesterday but didn’t save anything because nothing seemed to be happening. this was the first thing I tried. My building is a group and I tried selecting it yesterday but was having difficulties. Thanks.
Is the Element.GetLocation node from a package or is it OOTB now.
If it is from a package try using the one from
Clockwork. I think it is Clockwork or maybe GeniusLoci. Can’t remember.
PS
Don’t forget to pin the preview bubbles next time you post a screenshot of your graph after you ran it.
This is a simple example of moving elements of a group onto a surface using Revit. However, a toposolid (terrain) might have more surfaces, so you will need to consider how to select the target surface for each building. (I haven’t worked with toposolids, so I can’t advise on that without some sample data).
Dynamo for Revit
Revit_MoveElementOntoSurface.dyn (24.6 KB)
An alternative is to perform this transformation in Civil 3D, which has more tools for terrain surfaces. You will probably need InfraWorks to coordinate between Revit and Civil 3D, so it depends your software licenses. The workflow would be something like the following:
- Create an InfraWorks model and set the location (or use Model Builder).
- Import the topography and road network (or use Model Builder).
- Import the Revit family of the buildings into InfraWorks.
- Open the InfraWorks model in Civil 3D. (IMPORTAIWMODEL)
- Get the location of all building elements as points (point A).
- Use the Surface.SamplePoint in Dynamo for Civil 3D to find the elevation of the surface for each building element as a point (point B).
- Move the building elements from their respective Point A to Point B.
- Save the as a DWG file.
- Open the DWG using Import CAD in Revit.
I assumed your buildings from Revit will be solids in Civil 3D. This is a simple example of moving all solids in a layer onto a surface using Civil 3D.
Dynamo for Civil 3D
C3D_MoveSolidOntoSurface.dyn (29.9 KB)