ROBLOX Weathering Script

Hello, I’m CrunchyRBLX
I’m trying to achieve working rain in roblox
I do have a script but i do need help


while wait(.01) do

local rainpart = game.ReplicatedStorage.RainPart.RainPart:Clone()

rainpart.Parent = game.Workspace.RainPart

rainpart.Position =,500),500,math.random(-200,500))

rainpart.CanCollide = false



What I need is so it stops, and then it loops. But I need a math.random script so it is a different time period

Examples of what time periods

1: 50
2: 300
3: 500

Can anoyone help me??

You can have a list of the values, then iterate through them and wait the designated time.

I need help for it to stop at a peroid of time, then for it to loop the script