Make a voice say player's username

I want to have a thing in my game, where a voice (google voice or something like it) say the player’s username, when he wins. “Dav_Jacobs” won the game.

I know scripting and i know how audio works in Roblox, but the problem is that there cant be preset audios to be played, since i want this to be available for all the players.

Basically the question is, how to generate audio from player’s username?

2 Likes

I think the only way would be to use HTTP service to send the winning players name to a webserver that automatically turns the words into TTS audio, then uploads the audio to the Roblox servers, then the audio plays. The issue with this is there could be a huge delay between the http request being sent and then the audio being made, so this really isn’t practical.

The only other way I can think of is making your own TTS system in Lua by reading the players name using string functions, then accessing a phonetic library with all phonetic sounds in the English language and playing them, which would also be very difficult and time consuming since you are basically just creating a TTS in Roblox.

3 Likes

sounds interesting but I feel like adding TTS to a place will get it moderated for its ability to generate inappropriate audio

Very true, there are some combinations of otherwise harmless words, that could sound very inappropriate when used in combination, this would be very problematic.

1 Like

But if i use TTS only for reading player’s usernames, there should be nothing inapropriate, as usernames are moderated, right?

And if i do all of it in a server script, and keep the actual audio with phonetics in server storage, there should be no way of exploiting it, right?

I think a solution to this could be to run the text through one of the text filtering methods before inputting it into the TTS system

1 Like

xDDDD i just wanted to make this for a simple donation system, that for example if player donates 10k robux, his name is announced to everyone. The game isn’t even slightly about donating, and this turned out to be way too complicated :DDDD.

But i will still probably make it when the whole game is ready.

1 Like