2
$\begingroup$

I'm currently working on a rollercoaster track generated from vendor data. I imported the curve with a python script and I'm placing the track elements on it with two objects, one for the tubes and one for the ties. Those elements are then array and curve modified. enter image description here On my curve (which comes from the original track data), each point represents the position of a track tie. What I need to achieve is to place the ties on the points of the curve, which have non-regular spacing between each points. Is there a way I can achieve that automatically (or at least without having to move them all by hand) ? Thanks.

Edit: I also need my ties to stay perpendicular to the curve tilt, which also comes from my initial data-set : enter image description here

My track tubes are set-up with simples array+spline modifiers and they automatically fit that tilt : enter image description here

Edit 2 : Here's a simplified .blend file. https://we.tl/t-6x8JN5OjzX

$\endgroup$

1 Answer 1

2
$\begingroup$

you can do it with geometry nodes like this:

enter image description here

Note: For your case you won't need the resample curve node. The geometry nodes modifier is added to the curve in my example.

update:

if you want to "align" the rotation of instanced objects to the curve you can use this node setup:

enter image description here

** UPDATE **

try this setup here:

enter image description here

result:

enter image description here

I know, in the beginning/end, there is some weird rotation. But this might be caused by your curve...so you should check your curve data.

$\endgroup$
8
  • $\begingroup$ This will need a bit of tweaking (rotation) but it works ! Many thanks :) Is there a way to apply the curve tilt to the ties too ? $\endgroup$
    – male-gal
    Commented Dec 24, 2021 at 12:43
  • $\begingroup$ i updated my answer. If it helped you, please click the checkmark left to my answer. thanks. $\endgroup$
    – Chris
    Commented Dec 24, 2021 at 12:52
  • $\begingroup$ Thanks @Chris, however it isn't able to match the curve's "tilt" (each Spline point has a p.tilt property which I can inspect in edit mode by pressing n) property with that setup. I updated my initial post with a screenshot of what I'm talking about $\endgroup$
    – male-gal
    Commented Dec 24, 2021 at 13:15
  • $\begingroup$ Can u provide blend file so we can try out? $\endgroup$
    – Chris
    Commented Dec 24, 2021 at 13:37
  • $\begingroup$ Just updated my initial answer with it. $\endgroup$
    – male-gal
    Commented Dec 24, 2021 at 13:51

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .