Mesh Line and Random count

Hello,

I have a pretty dumb question about geometry nodes:

Why can’t I use a Random Value node to set the count for a Mesh Line node ?

image

Both are integer values, so why do I get this red error line ? I don’t get it :thinking:

What I’m trying to do is to generate lines at each points of a grid. Each line having a random number of vertices.

Thanks

You trying to plug Field socket (diamont shape) into simple value (round shape) socket. You can convert Random Value to single random value by plugging Integer node into ID of Random value node. But this will not help you, because of second problem: you are creating instances. Instances means same geometry copies, that can vary only in transforms: location, rotation, scale. Geometry in instances remains absolutely same. So you can’t randomize instances easily. Only way now to randomize instances is Repeat Zone. You can follow my video: https://www.youtube.com/watch?v=xyVnszIPHk8&t=1s

@Finally_Free: I’ll send you to my favorite link for people new to GN.

Could be this it the type of thing you’re trying to achieve:

No Repeat Zone required. Just Realize Instances.

Good luck!

@Finally_Free Thanks for the quick answer.
Plugging an integer node into the ID of random value node did the trick.

I knew it was not enough for what I’m trying to achieve, but this first error was puzzling to me.

I’ll have a look at your video to understand to repeat zone.

Cheers.

Thanks @zeroskilz I’ll give a try at your node setup also.