24.12.2017, 01:26
Код:
if( !strcmp( cmd, "/admins", true )) { new string[128], MEGAString[2500], adminteext[24], funcao[32], adminsonline = 0; MEGAString[0] = EOS; strcat(MEGAString, "Nome\tCargo\tStatus\tFunção\n"); for(new i = 0; i < MAX_PLAYERS; i++) { if(IsPlayerConnected(i)) { if(aInfo[ i ][ Ajudante ] & aInfo[ i ][ Moderador ] & aInfo[ i ][ Admin ] > 0 ) { if(pInfo[ i ][ AFK ] == 0) adminteext = "{FF0000}Trabalhando"; if(pInfo[ i ][ AFK ] == 1) adminteext = "{00FF00}Ausente"; new AdminName[MAX_PLAYER_NAME]; new smirf[100]; format(smirf, sizeof smirf, PASTA_CONTAS, PlayerName( i )); else if(aInfo[ i ][ Ajudante ] == 1 ) AdminName = "1"; else if(aInfo[ i ][ Moderador ] == 2 ) AdminName = "2"; else if(aInfo[ i ][ Admin ] == 3) AdminName = "3"; else if(aInfo[ i ][ Ajudante ] == 1 ) AdminName = "Ajudante"; else if(aInfo[ i ][ Moderador ] == 2 ) AdminName = "Moderador"; else if(aInfo[ i ][ Admin ] == 3 ) AdminName = "Administrador"; format(string, 128, "%s\t%s\t%s\t%s\n", PlayerName(i), AdminName, adminteext, funcao); strcat(MEGAString, string); adminsonline++; } } } return ShowPlayerDialog(playerid, 0, DIALOG_STYLE_TABLIST_HEADERS, "Administradores Onlines:", MEGAString, "Ok", ""); }
Erros:
Код:
(20338) : error 029: invalid expression, assumed zero
Код:
expected token: ";", but found "if"