Humanoid:LoadAnimation() Deprecated

I went to use animations and realized that Humanoid:LoadAnimation is deprecated.
What is the new animation method? I tried searching but I didn’t find anything

https://developer.roblox.com/en-us/api-reference/function/Humanoid/LoadAnimation

1 Like
local player = game.Players.LocalPlayer

local char = player.Character or player.CharacterAdded:Wait()

local Animator = char:WaitForChild("Humanoid"):WaitForChild("Animator")

local animation = Animator:LoadAnimation(where the animation is)

You have to play the animation via the Animator in the character.

3 Likes

I suggest reading this: Animator | Roblox Creator Documentation
For more info, read this: Deprecating LoadAnimation on Humanoid and AnimationController

1 Like