Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

How to make a wait where the wait time is randomized between x and y?

example wait(x-y) Something that would act like that

1 answer

✓ Accepted answer

math.random() will give you a random number, evenly distributed between 0 and 1.

Thus 10 * math.random() is evenly distributed between 0 and 10.

15 + 10 * math.random() is evenly distributed between 15 and 15+10=25.

In general x + (y - x) * math.random() is evenly distributed between x and y.

This discussion is preserved as it was. New answers, comments, and votes are closed.