local lplayer = game.Players.LocalPlayer
for k,s in pairs(lplayer) do
if s:isA("Hat") and lplayer:isA("Humanoid") then
s:Destroy()
end
end
I've done this so far, but it's not working, an help?
local lplayer = game.Players.LocalPlayer
for k,s in pairs(lplayer) do
if s:isA("Hat") and lplayer:isA("Humanoid") then
s:Destroy()
end
end
I've done this so far, but it's not working, an help?
Basically all you want to do is loop through the player''s character to find a hat. This is how you will do this:
player = game.Players.LocalPlayer
for i,v in pairs(player.Character:GetChildren())do
if v:IsA("Hat") then
v:Destroy()
wait()
end
end
This will destroy all items that are a hat in the player's character
This discussion is preserved as it was. New answers, comments, and votes are closed.
2 comments
Doesn't work at all. For some strange reason....
Nevermind! Done it! I just need to put a wait(2) So it doesn't auto-regen it instantly!