Can we please have a proper way to load animations without having to play them?

As a Roblox developer, it is currently too hard to properly load animations with out having to play them, as Preload/PreloadAsync do not work

Normally, if i want to properly load an animation so its ready to be played, i would have to have a separate humanoid model hidden in the map somewhere, that is then constantly playing an animation, so its preloaded and ready for use. But if i do not do this, and i play the animation for the first time, the animation will not play straight away, due to the animation not being preloaded.

I suggest having a function for the AnimationTrack class that preloads the animation, something like;
AnimationTrack:PreloadAnimation()

If Roblox is able to address this issue, it would improve my development experience because i wont have to play an animation in order to load it properly.

31 Likes

This issue is quite bothersome. I can see why people create their own animation systems. This doesn’t only apply to animations, I also see it all the time with sounds, and occasionally images as well (although the latter at least is not a big issue).

Here are a few example use cases where having assets be properly loaded is important:

  • You are making a gameplay action that has some reliance on an animation in a game, such as throwing a grenade or doing an attack with a weapon. When making these you have to find ways to allow for the animation to be out of sync with the action, as they cannot be relied upon to load in time for the action (if you forced them to stay in sync, an action would be delayed by however long it takes the animation to load when you play it). It also just looks ugly when you do an action and then play the animation with a delay (grenade gets thrown, and then 5 seconds later your character starts waving their arms!).

  • Adding sound feedback to actions, especially when those sounds are played at a high-frequency (like shooting an automatic gun, or footsteps). To resolve this issue in my own games I typically create a pool of sounds with same SoundId and then play them in a cycle (deleting the Sound objects will “unload” the sounds so they cannot be used instantaneously the next time). This is a pretty wasteful technique however, and often will end up creating (and keeping) hundreds of sounds after a while of playing – and it still doesn’t solve this problem 100% of the time.

  • Doing things with the length of an animation or sound e.g. Animation Loading Issue

Please let us ACTUALLY preload things, with guaranteed correct information (e.g. read-only properties like length of an animation or sound) and no delay in using the content.

It’s very frustrating and seems needlessly limiting when we already have an API that is supposed to do this stuff.

8 Likes