Itoo Software Forum

RailClone => RailClone Pro (*) => Topic started by: SI3457 on April 09, 2016, 08:44:17 PM

Title: Bricks with random length with array 2s
Post by: SI3457 on April 09, 2016, 08:44:17 PM
Hello, i cant understand how to make a vertical brick wall (not a problem if i have to make it planar then rotate it afterwards but even there i cant find how to do) with bricks of different length. Of course, each row, all bricks must have the same height, but id like that in a given row, the length of the brick changes randomly.
I spent hours cant find a way. Even with export random y scale and linking random variable starting at array y row, it does not work. all bricks are different height, but not same height on all the row; perhaps my y is not the railclone y i dont know. i m tired sorry for the syntax...
I seem to have a problem with pivots or something like that. if you could provide a very little example max file that would be great or just a screen capture.... (im on max 2014)

Thanks
Title: Re: Bricks with random length with array 2s
Post by: Paul Roberts on April 11, 2016, 10:54:05 AM
Hello,

Please take a look at the attached file. To randomise the size of the bricks per row I've used the following technique.

1 - Create a transform operator and wire it between the brick and the generator.
2 - Right-click the Transform operator and Export Y Fixed Size
3 - Go to the Transform operator's properties and check Fixed Size
4 - Wire a Random Number node to this input and set the Type to Scene Units and change the Mode to Array Y Row. Set a minimum and maximum height for the bricks.

(http://i.imgur.com/30ubIdO.png)

As for how to create a vertical wall, you have a few options either create it using a single spline for the path and a Y Size parameter, in which case you'll want to use the X Rotation properties to make the wall vertical. Or create it using two splines, and then edit the Y spline to move the wall into a vertical position, or if you want to use X and Y size parameters or a clipping spline, you'll need to rotate the RailClone object itself so that it is vertical .

Please see the attached files for samples of all of the above.

I hope that helps,

Many thanks!

Paul.
Title: Re: Bricks with random length with array 2s
Post by: SI3457 on April 11, 2016, 03:36:36 PM
Thank you very much !!
Why does it not work if i wire the random component directly in to the exported Y fixed size of the segment, and that it has to be made through the transform component  ?
Title: Re: Bricks with random length with array 2s
Post by: Paul Roberts on April 11, 2016, 07:04:25 PM
Hi, I'm glad that helped. Any change to the Segment that uses an expression or random number node has to use a Transform operator. This is due to the internal logic of RailClone and the order of operations. You'll find if you try to connect them directly RailClone will warn you that it may not work.

Thanks,

Paul
Title: Re: Bricks with random length with array 2s
Post by: concrete pixel on June 18, 2021, 09:15:57 PM
This solution was working for me until I needed to deal with the start/end segements. I downloaded the solution you attached in the file, but it appears the start/end are one height, but the default is different now? Did this solution break during the most recent update to railclone?
I attached an image of what the brick walls look like after I opened the file.
Title: Re: Bricks with random length with array 2s
Post by: Rokas on June 21, 2021, 08:07:54 AM
Hi Dan.

I have just downloaded the file and it works correctly here with latest RC version:
(https://i.imgur.com/pZiELDh.png)

Maybe You have modified it somehow ?
Title: Re: Bricks with random length with array 2s
Post by: Dragan on June 21, 2021, 11:18:16 AM
Same here, works just fine.