How to array into multiple curves? (GH) – GH for Mac


Hello,

I do not know anything about GH, and I’m trying to build a simple script which:

– takes 2 input curves, divides them by an x number
– connect the divided lines

then, array a sphere on all those created lines.

I can do the first part, but I cannot do the array part.

Where am I wrong?

Thanks.

Hi Andrea,

I think the assumption that you’re making is that ArrayCrv will move your geometry to the start of the curve – right now it’s applying 33 ArrayCurves, but because it’s using the same sphere and all the curves are parallel – every array is being generated in the same place.

You need to either create your sphere in the places you want them to array FROM

OR

Maybe the simpler option is to work out how to generate the BasePoints of the spheres on the curves you want and generate the spheres in the right place instead of arraying them at all

-Sash

See attached:

LinesAndBalls.gh (8.4 KB)

BTW: BEFORE attempting anything in GH try to master the way that deals with data: The basic collection is called List (a dynamic thing (size) – as opposed to Array (fixed size) – that allows you to access items by index). Now … what happens if you have nested Lists? Enter the DataTree (“kinda” a Dictionary of Lists – add some ” ” more). 99.999% of the issues exposed here are – the one or the other way – related with poor (or none) knowledge of these things.



Source link

Leave a Comment