Adventure Game Studio

AGS Support => Advanced Technical Forum => Topic started by: Akril15 on Wed 12/08/2020 22:49:46

Title: Preventing stuttering from large animations (SOLVED)
Post by: Akril15 on Wed 12/08/2020 22:49:46
I'm working on a hi-res game in AGS 3.4.0 that's going to have rooms with large animations in it (at times with sprites up to 400x900 with around 45 frames in a loop). Not surprisingly, this occasionally causes a lot of animations to stutter when I test the game, and the music is definitely going to stutter as well whenever I get around to adding it. I've seen a few different methods to get around these issues discussed on the forums, but I'm just wondering which way works the best.

(I was able to solve a stuttering issue with a large animation in a much smaller game by making a non-blocking version of the animation play very quickly just offscreen when its room was loaded, but I'm not sure the same trick will work here, given how many more graphics I'm working with.)
Title: Re: Preventing stuttering from large animations
Post by: Crimson Wizard on Wed 12/08/2020 23:15:29
The method you mentioned is the only way to precache animation in AGS 3.4.0.

Music stuttering may be resolved by using a threaded audio, in 3.4.0 it can only be turned on by manually adding
Quote
[sound]
threaded=1
in acsetup.cfg. The downside of this will be that music will no longer be reliably synced with game ticks.

Other that this, cutting sprites as much as possible may improve perfomance. I.e. if in your animation there are parts that change often and parts that don't change (often), then you may try split objects and animate dynamic parts in sync.
Title: Re: Preventing stuttering from large animations
Post by: Akril15 on Fri 14/08/2020 16:37:44
Okay, that seems simple enough. Thanks for the help!