Hi! I think i’m late, but anyway.
I’m not so smart to explain in detail how it works, but basically, Roblox engine replicate some character data to server. As i know is CFrame and animations.
So you can just put your code into local script and it’ll work
Edit:
Also recommended to use Animator instead Humanoid to load animations, reasons in this announcement: Deprecating LoadAnimation on Humanoid and AnimationController