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

Is there a way to make the animation endless?

Asked by
neoG457 315 Moderation Voter
9 years ago
local id = "http://www.roblox.com/Asset?ID=272852444" --Change to your anim id
local animation = Instance.new("Animation")
animation.AnimationId = id
local controller = Instance.new("AnimationController")
controller.Parent = script.Parent
local animTrack = controller:LoadAnimation(animation)
animTrack:Play()

I have this animation but I want it to be able to play endlessly, like an idle animation but can't be beaten by the priority system. Is it even possible?

1 answer

Log in to vote
1
Answered by
Perci1 4988 Trusted Moderation Voter Community Moderator
9 years ago

Yes, but you have to do it when you're creating the animation. In the editor, you'll notice a looping toggle in the upper right hand corner. Just enabled this.

Of course, you could continuously call Play(), but this isn't a good idea when the looping is already built into the system. If you have your animations saved, then it's a simple matter to load it again and enable the looping.

0
Thanks neoG457 315 — 9y
Ad

Answer this question