10.07.2012, 20:23
Код:
else if (PlayerU2B[playerid] == 2) { if(strfind(string, ".mp3", true)) { for(new i = 0; i < MAX_PLAYERS; i++) { if(IsPlayerConnected(i)) { PlayAudioStreamForPlayer(i, inputtext); } } new sendername[128]; GetPlayerName(playerid, sendername, sizeof(sendername)); format(string, sizeof(string), "%s has donated to charity and has selected to play an mp3 file to all players on the server [/stopmp3 to stop the playback]", sendername); SendClientMessageToAll(COLOR_YELLOW, string); } else { SendClientMessage(playerid, COLOR_YELLOW, "This Audio URL will not work. Please enter another. Make sure it has .mp3 on the end of the URL"); ShowPlayerDialog(playerid,U2BDIAG+1,DIALOG_STYLE_INPUT,WHOMADETHIS,"Paste the mp3 link you want to play for the whole server:","Play","Cancel"); } }
Thanks