How to make local T = math.random(1,3) draw a new number every minute

So, I have a script that uses math.random (1,3) to choose what the map is going to be for the next round for the game.
The problem, though, is that when it does math.random, it stays on the same number throughout the game and the same map always gets picked.
How do I make it so that the number changes every 59 seconds or so?

Thanks!

Do a while loop. And do it everytime.

local T = 0

while wait(59) do
T = math.random(1,3)
end

2 Likes