Message 1 of 3
Rebar CreateFromCurvesAndShape hook orientation issue
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
IList<Curve> curves1 = new List<Curve>();
Curve curve1 = Line.CreateBound(eleCenter[0] + forward.Negate() + sideForward, eleCenter[1] + forward + sideForward);
curves1.Add(curve1);
IList<Curve> curves2 = new List<Curve>();
Curve curve2 = Line.CreateBound(eleCenter[0] + forward.Negate() + sideForward + XYZ.BasisZ * spacing, eleCenter[1] + forward + sideForward + XYZ.BasisZ * spacing);
curves2.Add(curve2);
rebar1 = Rebar.CreateFromCurvesAndShape(doc,
shape,
barType,
hook90, hook135,
hostElement, XYZ.BasisZ, curves1,
rebarHookOrientation, rebarHookOrientation);
rebar2 = Rebar.CreateFromCurvesAndShape(doc,
shape,
barType,
hook135, hook90,
hostElement, XYZ.BasisZ, curves2,
rebarHookOrientation, rebarHookOrientation);
currently i'm using RevitAPI to create column rebar, to make it more accurate with construction site, i'm trying to make tie object staggered, like image below
the C# code works fine in this revit project, but when i opened new other project, the result become weird.
as below,
when i debuged, i found the more weird thing, the red rebar project (which i thought works fine,) the two rebar actually have same start hook angle and end hook angle, which is out of my exception!