This is a 2AM-lightbulb-moment but, working on a feature for a game where once a player is below a certain amount of health, audio is played which is a request to be healed.
Is there any way using Text to Speech or something similar to say the player’s name along with a string such as “playerName needs healing!” or something? I doubt it would be viable to use but I’m willing to give it a try just for fun.
There used to be something like that in the Epix admin script, if you can find it in there you could probably make your own version based off of that. Otherwise, I am not aware of such a thing.
I believe how the admin scripts did it was they recorded an audio of each letter, and then made exceptions for some words (for example, you = u). If there was no exception for the word then it would just play the letters in the correct sequence. It didn’t sound correct most of the time, however.
This would be relatively easy if we could load in external-source audio… but that will never happen. Alternatively, you could create sounds for certain letters/letter pairing, like “ge” and “et”, separately. when put together they could sound like “get”. I’m sure there’s tutorials for this online, maybe not for lua, though.
For example: https://github.com/westparkcom/Lua-Bing-TTS
Looks like a Lua TTS system using Bing’s TTS API. Plug and play! Just not on Roblox.
Not loading for me. Mind posting a link to the video or file itself? Right Click > Open in New Tab should work.
Also I highly doubt it’s open sourced so, if I don’t find existed resources that do it I probably won’t bother trying to make something from scratch
There’s definitely some free models out there. No idea how they work, and they don’t work very well, but I have definitely seen them.
Not sure why the embedding isn’t working, let me know if it loads for you here
That seems pretty cool actually, Is there any way I’d be able to use this, or easily replicate it? Although the issue is making it smooth and usable so that it is interpreted easily. I just wish we had more external resources to work with.
The pitch of the voice is very interesting also…
The file’s on my desktop at home in Oregon, I’m down in California right now for the internship so I couldn’t give it to you. It’s pretty simple though. And I definitely could’ve made it 100x better if I spent a lot more time on it, but it was just a small project for fun.
But it essentially works by pairing together phonemes. I used the cmu phonetic dictionary for this.
When it receives input, say, “Cheese”, it breaks it into its phonetic parts using HttpService and that dictionary.
Cheese would be
CH IY Z
Alligator would be
AE1 L AH0 G EY2 T ER0
(1 for primary stress, 2 for secondary, 0 for no stress)
The server then tells the client what phonetic parts make up that word and the client runs through the phonemes and plays the corresponding sound. It delays based on some simple punctuation checks, whitespace, etc.
(I recorded with my own voice and uploaded 39 different sounds, one for every phoneme here).
While this works and was certainly pretty cool, anyone serious in the text to speech synthesis world will laugh at you if you told them you made a “synthesizer” by stringing together a bunch of phonemes.
speech synthesis is a MASSIVE field and very daunting if you want to vastly improve quality. I looked a bit into diphone synthesis but it’s way more data to upload and parse and I’m not even sure if it’d be possible on roblox to get anything “better” than this.
Alright, thanks for the help. I probably won’t do this however because it’s something I wanted to do for fun quickly, and besides I don’t have much of a need for it right now. Definitely seems like a good project to work on though.
Confirmed… Still the creepiest thing posted to date on the dev forums
Hey, I was wondering if you are able to upload the TTS Roblox file! It would be great as I’m working on a project with a friend and we need TTS in it, Thanks