I don't know if this is possible: assume I have a bunch of variables and I use a random function to randomly pick one but I want that the same variable won't be picked more than n times, let's say three times.
How would you do it?
Develop games in your browser. Powerful, performant & highly capable.
you could use an Array to do that (open in C3 https://editor.construct.net):