Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- new Ouvintes[33] = 0;
- if(dialogid == DialogMusicas)
- {
- if(response)
- {
- if(listitem == 0) // RÁDIOS
- {
- for(new j = 0; j < sizeof(Radios); j++)
- {
- Ouvintes[j] = 0;
- }
- new output[1624] = EOS;
- for(new i; i < GetMaxPlayers(); i++)
- {
- if(IsPlayerConnected(i))
- {
- if(OuvindoRadio[i] == true)
- {
- for(new j = 0; j < sizeof(Radios); j++)
- {
- if(!strcmp(Radios[j][0], RadioNome[i], true))
- {
- Ouvintes[j] ++;
- }
- }
- }
- }
- }
- new string[200];
- strcat(output, "{FFFFFF}Radio\t{FFFFFF}Ouvintes\n");
- for(new j = 0; j < sizeof(Radios); j++)
- {
- if(Ouvintes[j] == 0)
- {
- format(string, sizeof(string), "%dº- %s\t 0\n", j+1, Radios[j][0]), strcat(output, string);
- }
- else
- {
- format(string, sizeof(string), "%dº- %s\t{FFFF00} %d\n", j+1, Radios[j][0], Ouvintes[j]), strcat(output, string);
- }
- }
- ShowPlayerDialog(playerid, DialogMusicas4, DIALOG_STYLE_TABLIST_HEADERS, "{FFFFFF}Rádios disponíveis", output, "{FFFFFF}Selecionar", "{FFFFFF}Voltar");
- }
- else if(listitem == 1) /// PARAR RÁDIOS
- {
- PlayerPlaySound(playerid, 1085, 0, 0, 0);
- StopAudioStreamForPlayer(playerid);
- StopAudioStreamForPlayer(playerid);
- SendClientMessage(playerid,0x88AA62AA,"A rádio que você estava ouvindo foi desativada com sucesso.");
- StopAudioStreamForPlayer(playerid);
- OuvindoRadio[playerid] = false;
- RadioNome[playerid] = "N/A";
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment