Humanoid description not working?

So I have been testing out humanoid description, but it does not seem to work? I have this in a server script located in ServerScriptService, any help, theres no output errors.

local function onPlayerAdded(player)

if player:WaitForChild("stats"):WaitForChild("Gender").Value == 2 then

local humanoid = player.Character and player.Character:FindFirstChild("Humanoid")

if humanoid then

local descriptionClone = humanoid:GetAppliedDescription()

descriptionClone.Torso = 376532000

descriptionClone.LeftArm = 376530220

descriptionClone.RightArm = 376531012

descriptionClone.LeftLeg = 376531300

descriptionClone.RightLeg = 376531703

humanoid:ApplyDescription(descriptionClone)

end

end

end

game.Players.PlayerAdded:Connect(onPlayerAdded)

I don’t know whether it’s intentional or not that you’re lacking a CharacterAdded event to apply the HumanoidDescription to the character, but I’ll overlook that.

What is happening (or could be) is that the appearance isn’t loading fast enough and gets overwritten internally while the character is being constructed. It’s best that you first wait for the appearance to load via Player.CharacterAppearanceLoaded before you apply the description.

So I fixed it, made it work, but for some reason, when I die, my ragdoll does not work, any I can still equip tools like I am alive. Heres solution.

game:GetService("Players").PlayerAdded:Connect(function(player)

player.CharacterAppearanceLoaded:Connect(function(character)

wait(0.5)

if player:WaitForChild("stats"):WaitForChild("Gender").Value == 2 then

local humanoid = player.Character and player.Character:FindFirstChild("Humanoid")

if humanoid then

local descriptionClone = humanoid:GetAppliedDescription()

descriptionClone.Torso = 376532000

descriptionClone.LeftArm = 376530220

descriptionClone.RightArm = 376531012

descriptionClone.LeftLeg = 376531300

descriptionClone.RightLeg = 376531703

humanoid:ApplyDescription(descriptionClone)

end

end

end)

end)

That’s a different problem altogether that doesn’t seem related to this code. Please open a new thread for a different problem. If it’s related, more information will be required.

Well all of this didn’t happen before, the rag doll worked and characters wouldn’t play animations when equipping stuff, etc. now it does.