All of these replies are an awkward way of doing this. The reason it isn’t random is because every time the game is started, the seed is the same. To fix this, try this instead:
math.randomseed(time() * tick()) local randomNumber = math.random(1, 2)
Thank you very much fir understanding the situation
Here’s the post you’re looking for: