hello i have a probleme i knew that function return one value, but how to return all values ?
function GetAllHumanoidRootPart()
for _, basePart in workspace:GetDescendants() do
if basePart:IsA("BasePart") then
if basePart.Name == "HumanoidRootPart" and basePart ~= humanoidRootPart then
return basePart
end
end
end
end
local hit = GetAllHumanoidRootPart()
print(hit.Parent)
local list = {}
for _, basePart in workspace:GetDescendants() do
if basePart:IsA("BasePart") then
if basePart.Name == "HumanoidRootPart" and basePart ~= humanoidRootPart then
table.insert(list, basePart)
end
end
end
return list