Page 1 of 1

... change the seed for random generators?

Posted: Wed Apr 25, 2018 9:01 am
by mrc
Is there a way, maybe through a layer script, to change the seed for random generators like particle distribution, noisy channel etc.?

In my particular case I have set up a particle layer to randomly distribute characters along a street but I would like to try different distributions.

Help!
Marc

Re: ... change the seed for random generators?

Posted: Wed Apr 25, 2018 9:30 am
by hayasidist

Re: ... change the seed for random generators?

Posted: Wed Apr 25, 2018 10:17 am
by mrc
Thank you. I really have to look into and get started with scripting. Don't even know where to put those lines of code.

Marc

Re: ... change the seed for random generators?

Posted: Wed Apr 25, 2018 11:44 am
by hayasidist
if you're interested in writing scripts - this will give you a start.. http://mohoscripting.com/index.php?show ... _structure

Re: ... change the seed for random generators?

Posted: Wed Apr 25, 2018 5:35 pm
by synthsin75
mrc wrote:Thank you. I really have to look into and get started with scripting. Don't even know where to put those lines of code.

Marc
Find "SetRandomSeed" in the particle layer tool, and change the values? Just a guess. I haven't tried it.

Re: ... change the seed for random generators?

Posted: Mon Apr 30, 2018 1:18 pm
by hayasidist
http://www.mediafire.com/file/saufux9il ... rticle.zip

this will do much the same as the "randomise" button on the standard particle layer tool except that it pre-generates a set of random numbers so you can step forwards and backwards through them; and it stores information with the particle layer so that the same set of numbers can be accessed across multiple activations of the tool / moho.

more in the "readme" in the zip.

hope that helps!