04.03.2012, 06:38
Great Job Mate!
Use it like this:
pawn Code:
|
stock SendVoiceMessage(playerid, szMsg[], const szLang[], otherID)
{
new Float: fPos[3];
if(GetPlayerPos(playerid, fPos[0], fPos[1], fPos[2]) && szLang[0] != EOS)
{
static szUrl[60 + 128];
format(szUrl, sizeof(szUrl), "http://translate.google.com/translate_tts?tl=%s&q=%s", szLang, szMsg);
if(PlayAudioStreamForPlayer(otherID, szUrl, fPos[0], fPos[1], fPos[2], MAX_VOICE_RANGE, true))
{
continue;
}
}
}
PlayAudioStreamForPlayer(otherID, szUrl, fPos[0], fPos[1], fPos[2], MAX_VOICE_RANGE, true);
Text_to_speech.pwn(124) : error 017: undefined symbol "PlayAudioStreamForPlayer" Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 1 Error. |