Hi,i got an idea of an include which i want to make,i just wana ask that is this possible to make an include which enables to play voice messages for players.

For example i made this function: PlayVoiceMessageForPlayer(playerid, message[]);

And i use it like this : PlayVoiceMessageForPlayer(playerid, "Hi im K0P");

And it will speak this message for the player.

Also,is this possible to loop through all the spoken word's sound files (The files will be named according to the word spoken in the file) and find a matching word from the message[] string.Then play the word file?

-EDITED- It is possible, pretty good idea

GOOD IDEA but idk if it will be success or not

Originally Posted by [HLF]Southclaw
Посмотреть сообщение
Very possible!

https://pypi.python.org/pypi/gTTS + https://sampwiki.blast.hk/wiki/PlayAudioStreamForPlayer

You'd either have to write a C++ plugin to do the TTS part, use the exec plugin to run a Python script that uses gTTS or wait for Pawpy to be linux-ready. Then it's just a case of generating an .mp3 of the text-to-speech and returning the filename back to Pawn once it's ready so it can be played with PlayAudioStreamForPlayer (of course you'd need a webserver running on the machine too so the file can be served to players).
Ill do some research on that method as im new to all that stuff (Making plugin,TTS,Pawpy,exec)

Forum Jump:

Users browsing this thread: 1 Guest(s)