btw im new hehe help me please
function onTouch(part) local human = part.Parent:findFirstChild("Humanoid") if human ~= nil then part.Parent:findFirstChild("Torso").Transparency = 0 part.Parent:findFirstChild("Left Arm").Transparency = 0 part.Parent:findFirstChild("Right Arm").Transparency = 0 part.Parent:findFirstChild("Left Leg").Transparency = 0 part.Parent:findFirstChild("Right Leg").Transparency = 0 part.Parent:findFirstChild("Head").Transparency = 0 end end script.Parent.Touched:connect(onTouch)
local CharacterName = "Xapelize" -- Set this to the player name you want to hide game:GetService("Players").PlayerAdded:Connect(function(player) player.CharacterAppearanceLoaded:Connect(function(character) wait(0.5) -- Some debug if character.Name == CharacterName then -- Detect if it's the PlayerName for _, DetectingPart in pairs(game.Workspace:WaitForChild("Xapelize"):GetChildren()) do -- Get everything on your character if DetectingPart:IsA("Accessory") then -- If it's accessory DetectingPart.Parent = game:GetService("ServerStorage") -- Set the parent to ServerStorage (stores accessory inside it so you can get it back anytime) print(DetectingPart.Name .." is an accessory") elseif DetectingPart:IsA("MeshPart") or DetectingPart:IsA("Part") then -- The reason why is there part is because Head is a Part DetectingPart.Transparency = 1 -- Hide it print(DetectingPart.Name .." is a mesh part") else -- Neither Accessory nor MeshPart nor Part print(DetectingPart.Name .." is neither accessory nor mesh part, it's a ".. DetectingPart.ClassName) -- Print some stuff end if DetectingPart:IsA("Part") and DetectingPart.Name == "Head" then -- If the DetectingPart is head for _, DetectingChildrenHead in pairs(DetectingPart:GetChildren()) do -- Get the children of Head if DetectingChildrenHead:IsA("Decal") then -- If it's a decal (face) DetectingChildrenHead.Transparency = 1 -- Hide face end end end end print("Character".. CharacterName .." is invisible") else print(player.Name .." is not ".. CharacterName) end end) end)