Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Why does the output say the animation failed to load?

Asked by
obcdino 113
9 years ago

I have a script that changes the jump animation ID to a custom one, but the output says the animation failed to load. Anyone know why?

Jump ID Changer script:

game.Players.PlayerAdded:connect(function(plr)
    wait(1)
    plr.Character.Animate.jump.JumpAnim.AnimationId = "http://www.roblox.com/asset/?id=324035309"
end)

1 answer

Log in to vote
1
Answered by
Tigerism 220 Moderation Voter
9 years ago

Use LoadAnimation()

Note: put the new animation inside this script and call it "Animation". Code:

game.Players.PlayerAdded:connect(function(plr)
    repeat wait() until plr and plr.Character --better than a wait()
    plr.Character.Humanoid:LoadAnimation(script.Animation)
end)
Ad

Answer this question