LeChar = game.Workspace.Player1
Mousey = game.Players.LocalPlayer:GetMouse()
Invisible = false
function RemoveStuff()
local Character = LeChar
if Character.Head:FindFirstChild("face")then Character.Head.face:Destroy()end
for a,b in pairs(Character:GetChildren())do if b.ClassName=="Shirt"or b.ClassName=="Pants"or b.ClassName=="Hat"or b.ClassName=="BodyColors"then b:Destroy()end end
for a,b in pairs(Character:GetChildren())do if b.ClassName=="Part"and b.Name~="HumanoidRootPart"then b.BrickColor=BrickColor.new("Institutional white") end end
end
function Invisible()
local Character = LeChar
local Humanoid = Character:FindFirstChild("Humanoid")
for a,b in pairs(Character:GetChildren())do if b.ClassName=="Part"and b.Name~="HumanoidRootPart"then b.Transparency=1 end end
end
function Visible()
local Character = LeChar
local Humanoid = Character:FindFirstChild("Humanoid")
for a,b in pairs(Character:GetChildren())do if b.ClassName=="Part"and b.Name~="HumanoidRootPart"then b.Transparency=0 end end
end
function LeKey(ak)
if ak == "q" then
if Invisible == false then
Invisible = true
Invisible()
elseif Invisible == true then
Invisible = false
Visible()
end
end
end
Mousey.KeyDown:connect(LeKey)
Also they need to improve the title filter on this site. The title would've been shorter and without an unneeded question mark at the end.

2 comments
Title Filter is perfect. Also, we need to know the error if you're getting an error, as well as what you're trying to do.
To be more detailed, I don't get any error. It detects the key perfectly. The function runs perfectly if I call it outside of the KeyDown function. It's like it doesn't want to read the variable or function while in the KeyDown function.