function commands.invisible(sender, args)
	local playerinvis = args[1]
	if playerinvis == "me" then
		local character = sender.Character
		local characterClone = character:Clone()
		characterClone.Name = tostring(sender.Name).."'s Character"
		characterClone.Parent = ServerS
		local children = character:GetChildren()
		for _, child in pairs(children) do
			if child:IsA("MeshPart") or child:IsA("Part") then
				child.Transparency = 1
				elseif child:IsA("Accessory") then
					child:Destroy()
			end
		end
	end
end

3 comments

0

please format it correctly

0

Oh. Sorry. I am very sorry!

0

I've edited your post so it should be formatted correctly.