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

Roblox Default Animations Failing To Load... Please Help?

Asked by
Scootakip 299 Moderation Voter
7 years ago
local animation = Instance.new("Animation")
animation.AnimationId = "180426354"
local animController = script.Parent.AnimationController
local animTrack = animController:LoadAnimation(animation)

local animation2 = Instance.new("Animation")
animation2.AnimationId = "180435571"
local animController2 = script.Parent.AnimationController2
local animTrack2 = animController2:LoadAnimation(animation2)

I seriously don't understand what the issue is. This used to work, but now it keeps saying that both the animations failed to load. These are the default walking and idle animations that Roblox uses, BTW.

1 answer

Log in to vote
0
Answered by 7 years ago

When loading content You need to follow the string format. Simply putting the id as a string into the animation id will not load the animation.

The common format used is rbxassetid://[asset id].

Example:-

local animation = Instance.new("Animation")
animation.AnimationId = "rbxassetid://180426354"
local animController = script.Parent.AnimationController
local animTrack = animController:LoadAnimation(animation)

local animation2 = Instance.new("Animation")
animation2.AnimationId = "rbxassetid://180435571"
local animController2 = script.Parent.AnimationController2
local animTrack2 = animController2:LoadAnimation(animation2)

I hope this helps.

Ad

Answer this question