View Full Version : Node help. Instance rotation

01-22-2013, 05:33 PM
Hi Guys,

I wonder if I might solicit some help.

I have a grid of instances who's rotation is driven by a texture map. White makes the instance rotate 180 degrees, black rotates 0 degrees.

What I'd like to do is randomize the grid of instances more so that some of them rotate 180 degrees and some rotate -180 degrees. I don't care to control which rotate which way, I just want to randomize it.

Can someone help me with this node flow? How would I assign the negative value to random instances?

Make sense? Thanks for reading.


01-22-2013, 06:01 PM
TrueArt's Node Library has couple Random nodes.
Also LW has some and other 3rd party also.

01-22-2013, 06:10 PM
Thanks. I tried to figure it out for myself and I ended up plugging the ID index into a logic node. "If A greater than B". B was exactly half of the number of instances so I figured half would be greater than and half would be less then.

If true = 1
If false = -1

I plugged that into a multiply node that either multiplied the existing rotation by 1 or -1.

I'm not even sure of this is doing exactly the effect I want, but the results look cool and random so I'm going to roll /w it.


01-23-2013, 01:22 AM