I’ve been banging my head against the (incorrectly generated) wall for a while now and could really use some help.
I’m trying to create walls that follow a line that also curves in the z-direction. Wall.ByCurveAndHeight does not handle this and Wall.ByFace needs a (mass) host face instead of a surface. So I turned to Python and came up with the code below. Problem is, the resulting walls do not follow the z-values used. Sometimes I will get varying top and bottom edges, but not the same as my input.
Anyone have any ideas on whats going wrong or could point me in the direction of a better method?
import clr clr.AddReference('ProtoGeometry') from Autodesk.DesignScript.Geometry import * doc = DocumentManager.Instance.CurrentDBDocument wallpts = IN walls =  TransactionManager.Instance.EnsureInTransaction(doc) for loop in wallpts: profile =  for i in range(len(loop)-1): profile.append(Line.ByStartPointEndPoint(loop[i], loop[i+1]).ToRevitType()) profile.append(Line.ByStartPointEndPoint(loop[-1], loop).ToRevitType()) wall = Wall.Create(doc, profile, True).ToDSType(False) walls.append(wall) TransactionManager.Instance.TransactionTaskDone() OUT = walls