I tried using math.random(), but i got a error message, here's the code I used:
local CTorso = Clone:FindFirstChild("UpperTorso") or Clone:FindFirstChild("Torso") if Map:FindFirstChild("Min") and Map:FindFirstChild("Max") then local Min = Map:FindFirstChild("Min") local Max =Map:FindFirstChild("Max") CTorso.CFrame = CFrame.new(math.random(Max.Position.X,Min.Position.X), math.random(Max.Position.Y,Min.Position.Y)+5,math.random(Max.Position.Z,Min.Position.Z)) else error("Min/Max Is Missing From Map") break end
Add this to the top of your script.
Max = 150.Studs.Length Min = 25.Studs.Length local CTorso = Clone:FindFirstChild("UpperTorso")