I made this script to make a model's parts go invisible and walk-through, but only the head worked?
function onTouched(hit) local player = game.Players:GetPlayerFromCharacter(hit.Parent) if player then wait(.6) game.Workspace.noob1.Head.Transparency=1 game.Workspace.noob1.Head.CanCollide=false game.Workspace.noob1.LeftLeg.Transparency=1 game.Workspace.noob1.LeftLeg.CanCollide=false game.Workspace.noob1.Rightleg.Transparency=1 game.Workspace.noob1.Rightleg.CanCollide=false game.Workspace.noob1.Torso.Transparency=1 game.Workspace.noob1.Torso.CanCollide=false game.Workspace.noob1.RARM.Transparency=1 game.Workspace.noob1.RARM.CanCollide=false game.Workspace.noob1.LARM.Transparency=1 game.Workspace.noob1.LARM.CanCollide=false end end script.Parent.Touched:connect(onTouched)
function onTouched(hit) local player = game.Players:GetPlayerFromCharacter(hit.Parent) if player then wait(.6) game.Workspace.noob1.Head.Transparency=1 game.Workspace.noob1.Head.CanCollide=false game.Workspace.noob1["Left Arm"].Transparency=1 game.Workspace.noob1["Left Leg"].CanCollide=false game.Workspace.noob1["Right Leg"].Transparency=1 game.Workspace.noob1["Right Leg"].CanCollide=false game.Workspace.noob1.Torso.Transparency=1 game.Workspace.noob1.Torso.CanCollide=false -- I don't know what you mean by anything below this end end script.Parent.Touched:connect(onTouched)
This should work
It won't let you walk through walls.
script.Parent.Touched:connect(function(hit) if hit.Parent then local player = game.Players:GetPlayerFromCharacter(hit.Parent) if player then for i,v in pairs(player.Character:GetChildren()) do if v:IsA("BasePart") then v.Transparency = 1 v.CanCollide = false elseif v:isA("Hat") then v.Handle.Transparency = 1 end end end end end)