I am trying to make it so that also when you join the size of the part goes up.
local leaf = script.Parent -- 'leaf' is a part
game.Players.PlayerAdded:connect(function()
leaf.Size = math.random(5-10), 1, math.random(5-7) -- error on this line
end)

2 comments
Is 'leaf' a Part or a GUI?
Leaf is a part