I am making a game with character customization, and so that players don't get put in the same area, I have script that clones a new area whenever a player joins, except it only clones it once, and not every time someone joins, I have it set up so that it names the model the player's name once they join, but I'm trying to figure out how to remove a spawn point from the folder that holds the spots where the model can be cloned this is the code.
local AvailableArea = game:GetService("ReplicatedStorage").SpawnPartsForCustomize
local chosenArea = AvailableArea:GetChildren()
local mathClonedArea = chosenArea[math.random(#chosenArea)]
local isAble = mathClonedArea:WaitForChild("IsFilled")
local clonedArea = mathClonedArea:Clone() clonedArea.Parent = workspace

2 comments
Please use Lua Code Blocks so your code is easier to read.
local mathClonedArea = chosenArea[math.random(1,#choseArea)]