hello
ok, what id like to do is set an expression for rotation, so that the amount is determined from a selection of four - 0,90,180,270
if i can make each random choice occur at an equaly spaced amount of time it would be great, but its not essential.
thanks
Arran.
Random choice from 4 values
- lloydalvarez
- Enhancement master
- Posts: 460
- Joined: June 17th, 2004, 9:27 am
- Location: New York City, NY
- Contact:
Code: Select all
fps=5; //interval of change in frames per second
choices = [0,90,180,270]; // enter the values to choose from, you can add more values as long as they are separated by comma
posterizeTime(fps);
r=Math.round(random (0,choices.length-1));
choices[r]
-Lloyd
- lloydalvarez
- Enhancement master
- Posts: 460
- Joined: June 17th, 2004, 9:27 am
- Location: New York City, NY
- Contact:
This is one of those problems that you can actually solve many different ways, but I think this is an efficient and scalable (ie, you can add more values and the expression won't break) solution.
And yes, that's an array
-Lloyd
And yes, that's an array
-Lloyd