Trying to rename every part in sync like "Part1" , "Part2" ...
parts = script.Parent:GetChildren()
for i=1, #parts +1 do
parts.Name = "Part" .. i
end
Trying to rename every part in sync like "Part1" , "Part2" ...
parts = script.Parent:GetChildren()
for i=1, #parts +1 do
parts.Name = "Part" .. i
end
local Num=0
for i,v in pairs(workspace:GetChildren()) do
if v:IsA("BasePart") and v.Name~="Terrain" then
Num=Num+1
v.Name="Part"..Num
end
end
parts = game.Workspace:GetChildren()--This get all the Child that are Workspace
for i,v in pairs (parts) do
v.Name = "Part" .. i
wait(1)
end
game.Workspace.part = game.Workspace.Part1
part.Name = ("Name")
Just do that for Part2 as well.
This discussion is preserved as it was. New answers, comments, and votes are closed.
3 comments
If It works then Please accept my answer and if you want me to explain how it work just ask.
Didnt work
I check it and it worked fine.