I have a building tower that contain nested link of typical story that is repeated (40 times) with rotation in each level,
is there a way to rotate each link instance in given angle?
You mean something like this?
yes i want to copy sites from the link
i don’t have the Python script, but at least you know it can be done
maybe some one can recreate it or you can ask the maker of the YT movie
hi, you have to make a list of angles for each instance, so if you have a list of 40 link instance, you have to make a list of 40 angles
and use this python script to rotate
import clr clr.AddReference('RevitServices') import RevitServices from RevitServices.Persistence import DocumentManager from RevitServices.Transactions import TransactionManager clr.AddReference("RevitAPI") import Autodesk from Autodesk.Revit.DB import * clr.AddReference('RevitNodes') import Revit clr.ImportExtensions(Revit.GeometryConversion) link = UnwrapElement(IN) axis = UnwrapElement(IN) angle = UnwrapElement(IN) axises= for j in axis: axises.append(j.ToRevitType()) doc = DocumentManager.Instance.CurrentDBDocument TransactionManager.Instance.EnsureInTransaction(doc) for l,ax,a in zip(link,axises,angle): Autodesk.Revit.DB.ElementTransformUtils.RotateElement(doc, l.Id, ax, a) TransactionManager.Instance.TransactionTaskDone() OUT = link
Hi, thank u !
what about axis input? which node a r recommend to use?
in your case Z-Axis node, but you should also repeat it 40 time using list.cycle,
or modify the python in this line to be like this
Autodesk.Revit.DB.ElementTransformUtils.RotateElement(doc, l.Id, axis, a)
Is it possible to modify this script for DWG links (ImportInstances)?
Any help would be appreciated. Here is a link to the post I made for this topic:
Rotate Import Instance
is it works for plan regions?