Warcraft III resources & community, 2003–2006 · archived

Randomizing

4 posts
#1

Randomizing

Can I set a trigger to function randomly. So that if I had a trigger that would create rain, the trigger would occur a seemingly random times?
#2
Yes. This is 100% possible!
But you need variables (Integers)
#3
There's an action to set a made integer to a random number between x and y.
Where x and y are numbers chosen by yourself.
Then every q amount of seconds, run your trigger.

The trigger should be something like:

-Set Rain to a random number between 1 and 3
If/then/else
-If rain is equal to 2
-Then 'make rain'
-Else 'do nothing'

Also can you make it so it sets the variable rain to a random number between lets say 120 and 360, then convert the integer to a real value, and make a trigger that runs every 'your random value' times.
#4
Thank you much :D