Quote from: Crimson Wizard on Mon 25/09/2023 18:03:24However, there may be another solution: use some tool to generate a sound timeline with these levels, put this as a custom data in your game, and use that in script instead. With this no additions to the engine will be necessary.
That is essentially what eri0o suggested, using Rhubarb as the tool to identify when speech is happening in the voice clips and save this in a data file, and TotalLipSync as the script to read the data and control the animation.
Both are perhaps "overkill" in the sense that they do a lot more than is necessary for this particular case, but they should work. (One could make some fairly simple changes to TLS to make it play a looping animation instead of tracking individual frames whenever the mouth isn't closed. Or of course write the code from scratch.)