Help with Animator

Hello,
So I recently discovered that the :LoadAnimation() is now deprecated, however, I’m having trouble understanding how to use it.

I assume this is what I do if I’m using it in a LocalScript?

local animator = Instance.new('Animator',player.Character)
animator:LoadAnimation(workspace.CrawlAnimation)

But how would I play the animation, there is no animator:Play()?

There is always the developer reference API with a really neat code sample to save the day.

For that you can use the animation track returned by the load animation like in the code sample and it should work.

local animator = Instance.new('Animator',player.Character)
local crawlAnimation = animator:LoadAnimation(workspace.CrawlAnimation)
crawlAnimation:Play()