One source of "jerkyness" may have been identified
Created by: tamlin-mike
Repro: Start a new game, run 30-or-so m.
Starting a new game in a debug build, while running under a profiler, I found out some lua script loaded a bunch of audio files - most if not all completely unrelated to the area I entered, and definitely not somethign expected to be played within the next seconds.
This made me realize the audio subsystem needs at least one, and maybe two, new functions.
- preload. This one should be obvious. What may not be obvious is that it should run in another thread (think WorkItem's).
- play_ambience. If added, this one should use the same preload (or even WorkQueue) mechanism, to not lock up the main game pointlessly.