ciribob / DCS-SimpleTextToSpeech

LUA Script adding Text to Speech (and MP3 playback) using SRS in DCS
MIT License
19 stars 6 forks source link

check if STTS is installed and configured before trying to call the executable #10

Open davidp57 opened 8 months ago

davidp57 commented 8 months ago

If the user add the STTS script to a mission and configures it (sets up the directory and port), but somehow the executable itself is not available (was not installed, has been moved, is not accessible by the current user, etc.), then an error pops up and DCS is frozen.

This little change ensures that, the first time STTS is used, it will check if the executable file is actually there. Then, this information is cached for better performance.

davidp57 commented 6 months ago

Hi @ciribob; we detected a bug in a logging statement that crashed the script, and I made a correction.