basically how do i use the AddAccessories function to put accessories back on a character
I made a script where you press j to take off a mask and get your accessories back that were stored in lighting
When i press j the mask is removed, the hats come but my hats just fall off..
plr = script.Parent.Parent.Parent.Parent
print("Hello world!")
UIS = game:GetService("UserInputService")
UIS.InputBegan:connect(function(input)
if input.KeyCode == Enum.KeyCode.J then
Anim = plr.Character.Humanoid:LoadAnimation(script.Parent.Animation)
Anim:Play()
plr.Character.Mask:Destroy()
for i,v in pairs (game.Lighting:GetChildren()) do
wait()
if v.Name == plr.Name then
for i,v in pairs (v:GetChildren()) do
plr.Character.Humanoid:AddAccessory(v)
end
end
end
end
end)

2 comments
you can't use accessories locally with FE on
@tkddude2 If that were true the whole roblox community would be in trouble in a couple weeks.