when i press the button it just crashes
script.Parent.MouseButton1Click:Connect(function()
local name = game.Players.LocalPlayer.Name
local children = workspace.buythings:GetChildren()
local nr = 1
local onr = 0
for i = 1, #children do
local child = children[i]
local newz = script.Parent.Parent.Empty:Clone()
newz.Text = child.Name
newz.Position = UDim2.new(0,0,0,onr)
script.Parent.Parent.CanvasSize = UDim2.new(0,0,0,onr)
newz.Parent = script.Parent.Parent
nr=nr+.5
onr=onr+50
wait(.1)
end
end)
