I am trying to extract wall orientation values to be usable and compared to other list of point or vector values. See below as an example:
What would be the best way to manage the wall orientation values to be comparable to vector values or vice versa? I can say a way using strings and being nifty with editing and formatting characters but I have a gut feeling there is a much more simpler method. Any ideas?
Hi @Dynamonkey ,
one way to do this is to add one line inside Andreas’s code to convert XYZs to dynamo vectors:
This bug was introduced recently.
You should replace the entire Python code with this:
from Autodesk.Revit.DB import *
wallinstances = UnwrapElement(IN)
vectorlist = list()
for item in wallinstances:
lcurve = item.Location.Curve
if str(lcurve.GetType()) == "Autodesk.Revit.DB.Line":
direction = (lcurve.GetEndPoint(1) - lcurve.GetEndPoint(0)).Normalize()
OUT = vectorlist
I’ll update the node for the next release of Clockwork.
Guys, I am trying to solve “null” return from both nodes, using the latest package from Clockwork
Could you tell me if there is intrinsic problem with the node or maybe that is my configuration ?
Thank you in advnsew does not workdyn.dyn (5.8 KB)
Hi @erlich.denis ,
It looks like Wall.Orientation node still gives out Revit XYZ and not DS vectors. You should replace the code inside the custom node as suggested by Andreas ^
Worked like a charm! Thank you so much!
would you share the nodes that you used for wall.orientation custom node?
Wall.Orientation is from the clockwork package.
For future references, I’ll urge you to create a new thread rather then reviving 2 year old ones. A lot have changed with Dynamo in the past 2 years
I’m still getting this error message when I add the code…
Blockquote Error: ‘;’ is expected> Blockquote
Did I miss any step?
Python code in a Code Block won‘t work. Use a Python Script node…
How do I type it in a python script node?
Sorry if it is a very silly question, but I rather make it
Thank you Andreas