The title may be a bit confusing, but let's take the default Baseplate for example. Let's say the Baseplate's size is (512, 20, 512). The position is (0,0,0). When I try to position a part randomly onto that baseplate, I find it hard to think of how to do it. Say if I do position a part to 0,0,0; it would only be in the MIDDLE of it. How do I find the amount of studs within? I've accomplished this by taking the locations of the X and Z of the ends, but I just want to do all of that in a script. Confused? Comment
Script:
function snow()
while wait() do
-- got here try 1
a = game.Lighting.Part:clone()
print('cloned')
for i,v in pairs(game.Workspace:GetChildren()) do
if v.Name == "Baseplate" then
a.Position = Vector3.new(math.random(-257,257), 200, math.random(-254,254))
end
end
game.Workspace["Snow Script"].Script:clone().Parent = a
a.Parent = Workspace
a.Script.Disabled = false
print('set')
end
end
snow()
