So I am trying to remove all the accessories from a player when they spawn in/reset their character. This is what I have tried
game.Players.PlayerAdded:Connect(function(player)
player.CharacterAppearanceLoaded:Connect(function(character)
print("CharacterAppearance Loaded")
local humanoid = character:WaitForChild("Humanoid")
humanoid.DisplayDistanceType = Enum.HumanoidDisplayDistanceType.None
humanoid:RemoveAccessories()
OverheadGui = script.OverheadGui:Clone()
OverheadGui.PlayerName.Text = player.Name
if player:IsInGroup(9272476) then
OverheadGui.GroupRank.Text = player:GetRoleInGroup(9272476)
end
OverheadGui.Parent = character:WaitForChild("Head")
end)
end
When I run this it doesn’t do anything. It doesn’t remove any accessories and it doesn’t duplicate the overhead gui. It also doesn’t print anything. I have also tried doing the same approach using player.CharacterAdded but that doesn’t run too. I’m really confused about why this isn’t working. Have I done something wrong? Also the PlayerAdded event IS running as I load in the users data and that works perfectly fine.