Railway on revit dynamo

Hello, for a while now I have been using dynamo. I want to model a railway track via dynamo but I have been stuck for a few days because I can’t generate the geometry. I would like to know please if it is possible to have help. I’ll put the script capture for you for a better analysis. Thank you

Hi there,

Not sure if this is what you wanted but different strategy from my point of view.
This script is still pretty basic though.
Depending on the curve strategy, the green grouped set of nodes can definitely be revised.
If you intend on size parametric control, the thickening curve can be updated.
As for segment length controls, that can also be improved to have a finer control over the length between every point.


I believe structuring your logic pathway can help a lot in the long run, best to make it a habit so it sticks from the beginning.
Hope that helps.

1 Like

Instead of a Curve.PointAtParameter and then playing connect the dots, I would recommend using a Curve.CoordinateSystemAtSegmentLength on the ‘center’ curve. Then build a single rail tie at the origin, and use a Geometry.Transform node to move the origin rail tie into position at each coordinate system.

The rails themselves would likely be best built by way of a sweep along the center curve, or on offset curves built from the center curve.

2 Likes

Sounds like a great plan!
Rarely explored the geometry creation side of dynamo so pro tips are always appreciated :slight_smile:
Another method I believe is to pair this script up with an adaptive family producing the rails at every start and end point. It would go a long way if this intended result has to be a revit project.

1 Like

Thank you for your different feedbacks and your sharing. I’ll take the time to explore all the aspects you’ve recommended to me and I’m sure it will work. I am grateful to you

1 Like

Hi @freddyetien2015 here is a way with nornal at parameter i normally use if not coordinatesystem at parameter…and we have many ways for import to revit, familytype by geometry, family instance by geometry, directshape etc…but try play around with it…

Revit_IJ5HkCh3GQ
track test.dyn (85.5 KB)

3 Likes