Hi guys,
I’ve made a script to straighten slightly-off-axis walls based on one piece of wall orientation.
The script is working pretty well on those pieces of wall that don’t have any door or other elements hosted on them.
Any idea to let these elements move according with wall new rotation keeping their initial placement?
I’ve already extracted door’s start location, found the parameter along the curve and mapped them back on the final wall location (rotated).
Hi Daan,
as far as I can notice the problem is that the new position of the wall instance has been set by Element.GetLocation > Rotate > Element.SetLocation.
Once the wall is rotated the hosted elements should move accordingly (if u try to do it manully using the UI there’s definitely no problem).
If you try instead to do it with dynamo, hosted elements move from their original position and in the best case they just move a little (few centimeters), in the worst they just come out of the host so that Revit ask you to address those issues getting rid of those elements or going back.
I don’t think FamilyInstance.SetLocation works, first of all because I am working with system families as Walls. That node should work only for component families. The correct one is Element.SetLocation.
Anyway I think the problem is inside the workflow rather than the nodes,