I'm trying to make a script that makes the player disappear when "E" is pressed on the keyboard. The parts are disappearing but at different times. Here's the full script:
local player = game:GetService("Players").LocalPlayer.Character:GetChildren()
local userinput = game:GetService("UserInputService")
userinput.InputBegan:Connect(function(key)
for i, v in pairs(player) do
if key.KeyCode == Enum.KeyCode.E then
for i = 1,10 do
v.Transparency = v.Transparency + 0.1
wait(0.001)
end
end
end
end)
By the way, I'm not sure how to get the accessories and face to disappear.

5 comments
What do you means? Your script wasn't have any code to make parts dissapear but the part just dissapered..? How...?
And it's disaperred at different time (Illuminati song)
Even if you'd coded it correctly, I don't see the point of fading out your own character on the client. You realize that all the other players will still see you, right? These changes won't replicate to the server.
I don't really need to show it on the other players' screens, but it would be nice to. Could you tell me how to do that?
it's been a year. i've found out how to replicate said changes to the server a whileee ago. wow.