i wrote the following localscript that goes in startercharacterscripts which is supposed to allow me to walk through walls
wait(2)
if script.Parent.Name == "defaultkid99" then
while true do
wait(4)
local parts workspace:GetChildren()
if parts.Name == workspace.Wall.Name then
parts.CanCollide = false
parts.Transparency = 0.4
else
parts.Transparency = 0.4
parts.CanCollide = true
end
wait(8)
parts.CanCollide = true
parts.Transparency = 0
end
end
however it gives me an error that says attempted to index nil with Name. what can i do to fix this?

1 comment
what is this