When my character resets or dies, it will give me an error saying LoadAnimation requires the Humanoid object (TtuNkK.Humanoid) to be a descendant of the game object. I went into dev forums, but none of them have worked for me. I discovered that when I print the parent of the character, it says its nil. Which is strange.. Any solutions for this? The code is in a local script parented to a tool.
local player = game.Players.LocalPlayer
local character = player.Character or player.CharacterAdded:Wait()
IdleAnim = character:WaitForChild("Humanoid"):LoadAnimation(game.ReplicatedStorage.Animations.Combat.CombatldleAnim)

1 comment
Thanks mate! Works fine now!