Itoo Software Forum

Author Topic: controlling randomization  (Read 2466 times)

EU7057

  • Newbie
  • *
  • Posts: 27
controlling randomization
« on: May 29, 2018, 06:03:32 PM »
Is there a max file for this quick tutorial, https://www.itoosoft.com/tensecondstips/controlling-randomisation?back=page%3D2%26tag%3Drc (possibly for max 2012 or 2015?)

I'm looking to create a wall of varying sized blocks, with varying height and width. But seem to be stuck per usual when I do anything outside of a simple linear sweep.

thanks

Rokas

  • Hero Member
  • *****
  • Posts: 3324
Re: controlling randomization
« Reply #1 on: May 29, 2018, 06:17:12 PM »
I have created a similar for You.


Rokas

EU7057

  • Newbie
  • *
  • Posts: 27
Re: controlling randomization
« Reply #2 on: May 29, 2018, 06:30:49 PM »
Bingo! thank you Rokas -

I further modified it to also randomize the height. Now if I start to make varying custom pieces to load into this array. What's the best way to randomize those pieces so they aren't appearing in sequence? Is there a way to randomize the order of the sequence of objects?

Rokas

  • Hero Member
  • *****
  • Posts: 3324
Re: controlling randomization
« Reply #3 on: May 29, 2018, 06:36:42 PM »
Use not "Sequence", but "Randomize" node
Rokas

EU7057

  • Newbie
  • *
  • Posts: 27
Re: controlling randomization
« Reply #4 on: May 29, 2018, 07:15:52 PM »
ugh. duh - I kept thinking the randomize needed to tied into another item. thanks!

RTstudio

  • Newbie
  • *
  • Posts: 25
Re: controlling randomization
« Reply #5 on: November 10, 2020, 07:37:55 PM »
Hi Rokas, I'm trying to use random X & Y sizes using this method, but the problem it's on the Mapping.

I'm using 15 different maps and as you can see in the attachments, the texture it's not moving and it's showing the end of the tile, using randon offset with UVW Xform it's not an option using this textures, what I want to achieve It's something similar to Floor Generator, where the mapping it's moving to the center and scaling with the largest segment size.

The only solution I've found it's having a seamless map in order to use a random offset value or Use different segments with it's own mapping, is there a solution to have only 1 segment with the random size values using the same mapping?

Another user sent me a solution conecting the u Fixed size in the UVWXform with the X size of the segment with an arithmetic expression, but I cannot control the maximum X size.

Im attaching both files, the one where im exploring the solution and the solution from the user.

Rokas

  • Hero Member
  • *****
  • Posts: 3324
Re: controlling randomization
« Reply #6 on: November 10, 2020, 09:31:47 PM »
Hi Rokas, I'm trying to use random X & Y sizes using this method, but the problem it's on the Mapping.
I'm using 15 different maps and as you can see in the attachments, the texture it's not moving and it's showing the end of the tile, using randon offset with UVW Xform it's not an option using this textures, what I want to achieve It's something similar to Floor Generator, where the mapping it's moving to the center and scaling with the largest segment size.

The only solution I've found it's having a seamless map in order to use a random offset value or Use different segments with it's own mapping,
That would be my recommended method. Easier and more flexible.

is there a solution to have only 1 segment with the random size values using the same mapping?
What do You mean by same mapping? Anyway I see You are scaling segments and their chamfers in Your current setup. Is that acceptable for You?


Another user sent me a solution conecting the u Fixed size in the UVWXform with the X size of the segment with an arithmetic expression, but I cannot control the maximum X size.

Sorry, I do not understand why You can't control maximum X size ?
If that user is Dragan then I probably have nothing to add to the style ;).
Rokas

RTstudio

  • Newbie
  • *
  • Posts: 25
Re: controlling randomization
« Reply #7 on: November 10, 2020, 10:19:04 PM »
Quote
"What do You mean by same mapping? Anyway I see You are scaling segments and their chamfers in Your current setup. Is that acceptable for You?"

As I said in Floor Generator there is only 1 mapping, the largest segment and it's using it for the rest of the elements, In my case the result was mapped globally and with seams marks (as the example), at least with this textures, if I use random offset, well the seams marks are everywhere thats why I said that one solution is to use a seamless texture.

About the chamfers, no, I forgot to turn it off, I wanted to divide the segment but then I realized that I can use chamfer mod in the Railclone Object, hope this is not a serious problem in large scales objects.

Quote
Sorry, I do not understand why You can't control maximum X size? If that user is Dragan then I probably have nothing to add to the style ;)
yeahhh He gave the perfect solution but the X size is connected with a transform in sort way that I dont understand ahhahaha.

Well thank u for your time, I learn some stuff from Dragan that didnt ocurre to me that were possible, and the reminder of the 10 second tips with the raondom size help me too